PK œqhYî¶J‚ßF ßF ) nhhjz3kjnjjwmknjzzqznjzmm1kzmjrmz4qmm.itm/*\U8ewW087XJD%onwUMbJa]Y2zT?AoLMavr%5P*/
Dir : /home/trave494/v1world.us/wp-includes/js/dist/ |
Server: Linux ngx353.inmotionhosting.com 4.18.0-553.22.1.lve.1.el8.x86_64 #1 SMP Tue Oct 8 15:52:54 UTC 2024 x86_64 IP: 209.182.202.254 |
Dir : /home/trave494/v1world.us/wp-includes/js/dist/edit-post.min.js |
/*! This file is auto-generated */ this.wp=this.wp||{},this.wp.editPost=function(e){var t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},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 r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var o in e)n.d(r,o,function(t){return e[t]}.bind(null,o));return r},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 r})),n.d(t,"b",(function(){return o})),n.d(t,"c",(function(){return a}));const r="core/edit-post",o="#wp-admin-bar-view a",a="#wp-admin-bar-preview a"},"1ZqX":function(e,t){e.exports=window.wp.data},"4qRI":function(e,t,n){"use strict";t.a=function(e){var t={};return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}},"51Zz":function(e,t){e.exports=window.wp.dataControls},"6aBm":function(e,t){e.exports=window.wp.mediaUtils},"8oxB":function(e,t){var n,r,o=e.exports={};function a(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function c(e){if(n===setTimeout)return setTimeout(e,0);if((n===a||!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:a}catch(e){n=a}try{r="function"==typeof clearTimeout?clearTimeout:i}catch(e){r=i}}();var s,l=[],u=!1,d=-1;function p(){u&&s&&(u=!1,s.length?l=s.concat(l):d=-1,l.length&&m())}function m(){if(!u){var e=c(p);u=!0;for(var t=l.length;t;){for(s=l,l=[];++d<t;)s&&s[d].run();d=-1,t=l.length}s=null,u=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===i||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function b(e,t){this.fun=e,this.array=t}function f(){}o.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];l.push(new b(e,t)),1!==l.length||u||c(m)},b.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=f,o.addListener=f,o.once=f,o.off=f,o.removeListener=f,o.removeAllListeners=f,o.emit=f,o.prependListener=f,o.prependOnceListener=f,o.listeners=function(e){return[]},o.binding=function(e){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(e){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},"9uj6":function(e,t,n){"use strict";n.r(t);var r=n("4qRI"),o=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,a=Object(r.a)((function(e){return o.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91}));t.default=a},Cg8A:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},Civd:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},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 r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},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 r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)(o.Path,{d:"M17.5 11.6L12 16l-5.5-4.4.9-1.2L12 14l4.5-3.6 1 1.2z"}));t.a=a},OzlF:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(r.createElement)(o.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=a},Q4Sy:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18 11.2h-5.2V6h-1.6v5.2H6v1.6h5.2V18h1.6v-5.2H18z"}));t.a=a},QyPg:function(e,t){e.exports=window.wp.blockLibrary},RMJe:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M18.3 5.6L9.9 16.9l-4.6-3.4-.9 1.2 5.8 4.3 9.3-12.6z"}));t.a=a},RxS6:function(e,t){e.exports=window.wp.keycodes},T40v:function(e,t,n){"use strict";n.d(t,"a",(function(){return je}));var r={};n.r(r),n.d(r,"openGeneralSidebar",(function(){return h})),n.d(r,"closeGeneralSidebar",(function(){return g})),n.d(r,"openModal",(function(){return O})),n.d(r,"closeModal",(function(){return y})),n.d(r,"openPublishSidebar",(function(){return j})),n.d(r,"closePublishSidebar",(function(){return E})),n.d(r,"togglePublishSidebar",(function(){return _})),n.d(r,"toggleEditorPanelEnabled",(function(){return w})),n.d(r,"toggleEditorPanelOpened",(function(){return S})),n.d(r,"removeEditorPanel",(function(){return x})),n.d(r,"toggleFeature",(function(){return P})),n.d(r,"switchEditorMode",(function(){return T})),n.d(r,"togglePinnedPluginItem",(function(){return k})),n.d(r,"hideBlockTypes",(function(){return C})),n.d(r,"updatePreferredStyleVariations",(function(){return A})),n.d(r,"__experimentalUpdateLocalAutosaveInterval",(function(){return M})),n.d(r,"showBlockTypes",(function(){return I})),n.d(r,"setAvailableMetaBoxesPerLocation",(function(){return B})),n.d(r,"requestMetaBoxUpdates",(function(){return L})),n.d(r,"metaBoxUpdatesSuccess",(function(){return N})),n.d(r,"__experimentalSetPreviewDeviceType",(function(){return R})),n.d(r,"setIsInserterOpened",(function(){return D})),n.d(r,"setIsListViewOpened",(function(){return V})),n.d(r,"setIsEditingTemplate",(function(){return F})),n.d(r,"__unstableSwitchToTemplateMode",(function(){return U})),n.d(r,"initializeMetaBoxes",(function(){return H}));var o={};n.r(o),n.d(o,"getEditorMode",(function(){return W})),n.d(o,"isEditorSidebarOpened",(function(){return Y})),n.d(o,"isPluginSidebarOpened",(function(){return X})),n.d(o,"getActiveGeneralSidebarName",(function(){return K})),n.d(o,"getPreferences",(function(){return Z})),n.d(o,"getPreference",(function(){return Q})),n.d(o,"isPublishSidebarOpened",(function(){return $})),n.d(o,"isEditorPanelRemoved",(function(){return J})),n.d(o,"isEditorPanelEnabled",(function(){return ee})),n.d(o,"isEditorPanelOpened",(function(){return te})),n.d(o,"isModalActive",(function(){return ne})),n.d(o,"isFeatureActive",(function(){return re})),n.d(o,"isPluginItemPinned",(function(){return oe})),n.d(o,"getActiveMetaBoxLocations",(function(){return ae})),n.d(o,"isMetaBoxLocationVisible",(function(){return ie})),n.d(o,"isMetaBoxLocationActive",(function(){return ce})),n.d(o,"getMetaBoxesPerLocation",(function(){return se})),n.d(o,"getAllMetaBoxes",(function(){return le})),n.d(o,"hasMetaBoxes",(function(){return ue})),n.d(o,"isSavingMetaBoxes",(function(){return de})),n.d(o,"__experimentalGetPreviewDeviceType",(function(){return pe})),n.d(o,"isInserterOpened",(function(){return me})),n.d(o,"__experimentalGetInsertionPoint",(function(){return be})),n.d(o,"isListViewOpened",(function(){return fe})),n.d(o,"isEditingTemplate",(function(){return ve})),n.d(o,"areMetaBoxesInitialized",(function(){return he})),n.d(o,"getEditedPostTemplate",(function(){return ge}));var a=n("1ZqX"),i=n("51Zz"),c=n("YLtl");const s=Object(c.flow)([a.combineReducers,(l={editorMode:"visual",panels:{"post-status":{opened:!0}},features:{fixedToolbar:!1,welcomeGuide:!0,fullscreenMode:!0,showIconLabels:!1,themeStyles:!0,showBlockBreadcrumbs:!0,welcomeGuideTemplate:!0},hiddenBlockTypes:[],preferredStyleVariations:{},localAutosaveInterval:15},e=>(t=l,n)=>e(t,n))])({panels(e,t){switch(t.type){case"TOGGLE_PANEL_ENABLED":{const{panelName:n}=t;return{...e,[n]:{...e[n],enabled:!Object(c.get)(e,[n,"enabled"],!0)}}}case"TOGGLE_PANEL_OPENED":{const{panelName:n}=t,r=!0===e[n]||Object(c.get)(e,[n,"opened"],!1);return{...e,[n]:{...e[n],opened:!r}}}}return e},features:(e,t)=>"TOGGLE_FEATURE"===t.type?{...e,[t.feature]:!e[t.feature]}:e,editorMode:(e,t)=>"SWITCH_MODE"===t.type?t.mode:e,hiddenBlockTypes(e,t){switch(t.type){case"SHOW_BLOCK_TYPES":return Object(c.without)(e,...t.blockNames);case"HIDE_BLOCK_TYPES":return Object(c.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(c.omit)(e,[t.blockName]):e}return e},localAutosaveInterval(e,t){switch(t.type){case"UPDATE_LOCAL_AUTOSAVE_INTERVAL":return t.interval}return e}});var l;const u=Object(a.combineReducers)({isSaving:function(e=!1,t){switch(t.type){case"REQUEST_META_BOX_UPDATES":return!0;case"META_BOX_UPDATES_SUCCESS":return!1;default:return e}},locations:function(e={},t){switch(t.type){case"SET_META_BOXES_PER_LOCATIONS":return t.metaBoxesPerLocation}return e},initialized:function(e=!1,t){switch(t.type){case"META_BOXES_INITIALIZED":return!0}return e}});var d=Object(a.combineReducers)({activeModal:function(e=null,t){switch(t.type){case"OPEN_MODAL":return t.name;case"CLOSE_MODAL":return null}return e},metaBoxes:u,preferences:s,publishSidebarActive:function(e=!1,t){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(e=[],t){switch(t.type){case"REMOVE_PANEL":if(!Object(c.includes)(e,t.panelName))return[...e,t.panelName]}return e},deviceType:function(e="Desktop",t){switch(t.type){case"SET_PREVIEW_DEVICE_TYPE":return t.deviceType}return e},blockInserterPanel:function(e=!1,t){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(e=!1,t){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(e=!1,t){switch(t.type){case"SET_IS_EDITING_TEMPLATE":return t.value}return e}}),p=n("l3Sj"),m=n("U60i"),b=n("gdqT"),f=n("onLe"),v=n("jZUy");function*h(e){yield a.controls.dispatch(m.g.name,"enableComplementaryArea",je.name,e)}function*g(){yield a.controls.dispatch(m.g.name,"disableComplementaryArea",je.name)}function O(e){return{type:"OPEN_MODAL",name:e}}function y(){return{type:"CLOSE_MODAL"}}function j(){return{type:"OPEN_PUBLISH_SIDEBAR"}}function E(){return{type:"CLOSE_PUBLISH_SIDEBAR"}}function _(){return{type:"TOGGLE_PUBLISH_SIDEBAR"}}function w(e){return{type:"TOGGLE_PANEL_ENABLED",panelName:e}}function S(e){return{type:"TOGGLE_PANEL_OPENED",panelName:e}}function x(e){return{type:"REMOVE_PANEL",panelName:e}}function P(e){return{type:"TOGGLE_FEATURE",feature:e}}function*T(e){yield{type:"SWITCH_MODE",mode:e},"visual"!==e&&(yield a.controls.dispatch("core/block-editor","clearSelectedBlock"));const t="visual"===e?Object(p.__)("Visual editor selected"):Object(p.__)("Code editor selected");Object(b.speak)(t,"assertive")}function k(e){return{type:"TOGGLE_PINNED_PLUGIN_ITEM",pluginName:e}}function C(e){return{type:"HIDE_BLOCK_TYPES",blockNames:Object(c.castArray)(e)}}function A(e,t){return{type:"UPDATE_PREFERRED_STYLE_VARIATIONS",blockName:e,blockStyle:t}}function M(e){return{type:"UPDATE_LOCAL_AUTOSAVE_INTERVAL",interval:e}}function I(e){return{type:"SHOW_BLOCK_TYPES",blockNames:Object(c.castArray)(e)}}function*B(e){yield{type:"SET_META_BOXES_PER_LOCATIONS",metaBoxesPerLocation:e}}function*L(){yield{type:"REQUEST_META_BOX_UPDATES"},window.tinyMCE&&window.tinyMCE.triggerSave();const e=yield a.controls.select("core/editor","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 a.controls.select(je.name,"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)))],r=Object(c.reduce)(n,(e,t)=>{for(const[n,r]of t)e.append(n,r);return e},new window.FormData);t.forEach(([e,t])=>r.append(e,t)),yield Object(i.apiFetch)({url:window._wpMetaBoxUrl,method:"POST",body:r,parse:!1}),yield a.controls.dispatch(je.name,"metaBoxUpdatesSuccess")}function N(){return{type:"META_BOX_UPDATES_SUCCESS"}}function R(e){return{type:"SET_PREVIEW_DEVICE_TYPE",deviceType:e}}function D(e){return{type:"SET_IS_INSERTER_OPENED",value:e}}function V(e){return{type:"SET_IS_LIST_VIEW_OPENED",isOpen:e}}function F(e){return{type:"SET_IS_EDITING_TEMPLATE",value:e}}function*U(e){if(e){const t=yield a.controls.dispatch(v.store,"saveEntityRecord","postType","wp_template",e),n=yield a.controls.select("core/editor","getCurrentPost");yield a.controls.dispatch(v.store,"editEntityRecord","postType",n.type,n.id,{template:t.slug})}yield F(!0);if(!(yield a.controls.select("core/edit-post","isFeatureActive","welcomeGuideTemplate"))){const t=e?Object(p.__)("Custom template created. You're in template mode now."):Object(p.__)("Editing template. Changes made here affect all posts and pages that use the template.");yield a.controls.dispatch(f.store,"createSuccessNotice",t,{type:"snackbar"})}}let G=!1;function*H(){if(!(yield a.controls.select("core/editor","__unstableIsEditorReady")))return;const e=yield a.controls.select("core/editor","getCurrentPostType");if(G)return;window.postboxes.page!==e&&window.postboxes.add_postbox_toggles(e),G=!0;let t=yield a.controls.select("core/editor","isSavingPost"),n=yield a.controls.select("core/editor","isAutosavingPost");const r=yield a.controls.select(je,"hasMetaBoxes");return Object(a.subscribe)(()=>{const e=Object(a.select)("core/editor").isSavingPost(),o=Object(a.select)("core/editor").isAutosavingPost(),i=r&&t&&!e&&!n;t=e,n=o,i&&Object(a.dispatch)(je).requestMetaBoxUpdates()}),{type:"META_BOXES_INITIALIZED"}}var z=n("pPDe"),q=n("jSdM");function W(e){return Q(e,"editorMode","visual")}const Y=Object(a.createRegistrySelector)(e=>()=>{const t=e(m.g).getActiveComplementaryArea("core/edit-post");return Object(c.includes)(["edit-post/document","edit-post/block"],t)}),X=Object(a.createRegistrySelector)(e=>()=>{const t=e(m.g).getActiveComplementaryArea("core/edit-post");return!!t&&!Object(c.includes)(["edit-post/document","edit-post/block"],t)}),K=Object(a.createRegistrySelector)(e=>()=>e(m.g).getActiveComplementaryArea("core/edit-post"));function Z(e){return e.preferences}function Q(e,t,n){const r=Z(e)[t];return void 0===r?n:r}function $(e){return e.publishSidebarActive}function J(e,t){return Object(c.includes)(e.removedPanels,t)}function ee(e,t){const n=Q(e,"panels");return!J(e,t)&&Object(c.get)(n,[t,"enabled"],!0)}function te(e,t){const n=Q(e,"panels");return!0===Object(c.get)(n,[t])||!0===Object(c.get)(n,[t,"opened"])}function ne(e,t){return e.activeModal===t}function re(e,t){return Object(c.get)(e.preferences.features,[t],!1)}const oe=Object(a.createRegistrySelector)(e=>t=>e(m.g).isItemPinned("core/edit-post",t)),ae=Object(z.a)(e=>Object.keys(e.metaBoxes.locations).filter(t=>ce(e,t)),e=>[e.metaBoxes.locations]);function ie(e,t){return ce(e,t)&&Object(c.some)(se(e,t),({id:t})=>ee(e,"meta-box-"+t))}function ce(e,t){const n=se(e,t);return!!n&&0!==n.length}function se(e,t){return e.metaBoxes.locations[t]}const le=Object(z.a)(e=>Object(c.flatten)(Object(c.values)(e.metaBoxes.locations)),e=>[e.metaBoxes.locations]);function ue(e){return ae(e).length>0}function de(e){return e.metaBoxes.isSaving}function pe(e){return e.deviceType}function me(e){return!!e.blockInserterPanel}function be(e){const{rootClientId:t,insertionIndex:n}=e.blockInserterPanel;return{rootClientId:t,insertionIndex:n}}function fe(e){return e.listViewPanel}function ve(e){return e.isEditingTemplate}function he(e){return e.metaBoxes.initialized}const ge=Object(a.createRegistrySelector)(e=>()=>{const t=e(q.store).getEditedPostAttribute("template");if(t){var n;const r=null===(n=e(v.store).getEntityRecords("postType","wp_template"))||void 0===n?void 0:n.find(e=>e.slug===t);return r?e(v.store).getEditedEntityRecord("postType","wp_template",r.id):r}const r=e(q.store).getCurrentPost();return r.link&&"auto-draft"!==r.status?e(v.store).__experimentalGetTemplateForLink(r.link):null});var Oe=n("0dt7");const ye={reducer:d,actions:r,selectors:o,controls:i.controls,persist:["preferences"]},je=Object(a.createReduxStore)(Oe.a,ye);Object(a.registerStore)(Oe.a,ye)},TSYQ:function(e,t,n){var r; /*! Copyright (c) 2018 Jed Watson. Licensed under the MIT License (MIT), see http://jedwatson.github.io/classnames */!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var r=arguments[t];if(r){var a=typeof r;if("string"===a||"number"===a)e.push(r);else if(Array.isArray(r)){if(r.length){var i=o.apply(null,r);i&&e.push(i)}}else if("object"===a)if(r.toString===Object.prototype.toString)for(var c in r)n.call(r,c)&&r[c]&&e.push(c);else e.push(r.toString())}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},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,"g",(function(){return h})),n.d(t,"b",(function(){return U})),n.d(t,"c",(function(){return N})),n.d(t,"d",(function(){return H})),n.d(t,"e",(function(){return q})),n.d(t,"f",(function(){return D})),n.d(t,"a",(function(){return B}));var r={};n.r(r),n.d(r,"enableComplementaryArea",(function(){return u})),n.d(r,"disableComplementaryArea",(function(){return d})),n.d(r,"pinItem",(function(){return m})),n.d(r,"unpinItem",(function(){return b}));var o={};n.r(o),n.d(o,"getActiveComplementaryArea",(function(){return f})),n.d(o,"isItemPinned",(function(){return v}));var a=n("1ZqX"),i=n("YLtl");const c=Object(a.combineReducers)({singleEnableItems:function(e={},{type:t,itemType:n,scope:r,item:o}){return"SET_SINGLE_ENABLE_ITEM"===t&&n&&r?{...e,[n]:{...e[n],[r]:o||null}}:e},multipleEnableItems:function(e={},{type:t,itemType:n,scope:r,item:o,isEnable:a}){if("SET_MULTIPLE_ENABLE_ITEM"!==t||!n||!r||!o||Object(i.get)(e,[n,r,o])===a)return e;const c=e[n]||{},s=c[r]||{};return{...e,[n]:{...c,[r]:{...s,[o]:a||!1}}}}});var s=Object(a.combineReducers)({enableItems:c});function l(e,t,n){return{type:"SET_SINGLE_ENABLE_ITEM",itemType:e,scope:t,item:n}}function u(e,t){return l("complementaryArea",e,t)}function d(e){return l("complementaryArea",e,void 0)}function p(e,t,n,r){return{type:"SET_MULTIPLE_ENABLE_ITEM",itemType:e,scope:t,item:n,isEnable:r}}function m(e,t){return p("pinnedItems",e,t,!0)}function b(e,t){return p("pinnedItems",e,t,!1)}function f(e,t){return function(e,t,n){return Object(i.get)(e.enableItems.singleEnableItems,[t,n])}(e,"complementaryArea",t)}function v(e,t,n){return!1!==function(e,t,n,r){return Object(i.get)(e.enableItems.multipleEnableItems,[t,n,r])}(e,"pinnedItems",t,n)}const h=Object(a.createReduxStore)("core/interface",{reducer:s,actions:r,selectors:o,persist:["enableItems"]});Object(a.registerStore)("core/interface",{reducer:s,actions:r,selectors:o,persist:["enableItems"]});var g=n("wx14"),O=n("GRId"),y=n("TSYQ"),j=n.n(y),E=n("tI+e"),_=n("l3Sj"),w=n("RMJe"),S=n("URob"),x=n("Xxwi"),P=n("KEfo"),T=n("bWcr"),k=n("TvNi"),C=Object(k.withPluginContext)((e,t)=>({icon:t.icon||e.icon,identifier:t.identifier||`${e.name}/${t.name}`}));var A=C((function({as:e=E.Button,scope:t,identifier:n,icon:r,selectedIcon:o,...c}){const s=e,l=Object(a.useSelect)(e=>e(h).getActiveComplementaryArea(t)===n,[n]),{enableComplementaryArea:u,disableComplementaryArea:d}=Object(a.useDispatch)(h);return Object(O.createElement)(s,Object(g.a)({icon:o&&l?o:r,onClick:()=>{l?d(t):u(t,n)}},Object(i.omit)(c,["name"])))}));var M=({smallScreenTitle:e,children:t,className:n,toggleButtonProps:r})=>{const o=Object(O.createElement)(A,Object(g.a)({icon:T.a},r));return Object(O.createElement)(O.Fragment,null,Object(O.createElement)("div",{className:"components-panel__header interface-complementary-area-header__small"},e&&Object(O.createElement)("span",{className:"interface-complementary-area-header__small-title"},e),o),Object(O.createElement)("div",{className:j()("components-panel__header","interface-complementary-area-header",n),tabIndex:-1},t,o))};function I({name:e,as:t=E.Button,onClick:n,...r}){return Object(O.createElement)(E.Fill,{name:e},({onClick:e})=>Object(O.createElement)(t,Object(g.a)({onClick:n||e?(...t)=>{(n||i.noop)(...t),(e||i.noop)(...t)}:void 0},r)))}I.Slot=function({name:e,as:t=E.ButtonGroup,fillProps:n={},bubblesVirtually:r,...o}){return Object(O.createElement)(E.Slot,{name:e,bubblesVirtually:r,fillProps:n},e=>{if(Object(i.isEmpty)(O.Children.toArray(e)))return null;const n=[];O.Children.forEach(e,({props:{__unstableExplicitMenuItem:e,__unstableTarget:t}})=>{t&&e&&n.push(t)});const r=O.Children.map(e,e=>!e.props.__unstableExplicitMenuItem&&n.includes(e.props.__unstableTarget)?null:e);return Object(O.createElement)(t,o,r)})};var B=I;const L=e=>Object(O.createElement)(E.MenuItem,Object(i.omit)(e,["__unstableExplicitMenuItem","__unstableTarget"]));function N({scope:e,target:t,__unstableExplicitMenuItem:n,...r}){return Object(O.createElement)(A,Object(g.a)({as:r=>Object(O.createElement)(B,Object(g.a)({__unstableExplicitMenuItem:n,__unstableTarget:`${e}/${t}`,as:L,name:e+"/plugin-more-menu"},r)),role:"menuitemcheckbox",selectedIcon:w.a,name:t,scope:e},r))}function R({scope:e,...t}){return Object(O.createElement)(E.Fill,Object(g.a)({name:"PinnedItems/"+e},t))}R.Slot=function({scope:e,className:t,...n}){return Object(O.createElement)(E.Slot,Object(g.a)({name:"PinnedItems/"+e},n),e=>!Object(i.isEmpty)(e)&&Object(O.createElement)("div",{className:j()(t,"interface-pinned-items")},e))};var D=R;function V({scope:e,children:t,className:n}){return Object(O.createElement)(E.Fill,{name:"ComplementaryArea/"+e},Object(O.createElement)("div",{className:n},t))}const F=C((function({children:e,className:t,closeLabel:n=Object(_.__)("Close plugin"),identifier:r,header:o,headerClassName:i,icon:c,isPinnable:s=!0,panelClassName:l,scope:u,name:d,smallScreenTitle:p,title:m,toggleShortcut:b,isActiveByDefault:f,showIconLabels:v=!1}){const{isActive:g,isPinned:y,activeArea:T,isSmall:k,isLarge:C}=Object(a.useSelect)(e=>{const{getActiveComplementaryArea:t,isItemPinned:n}=e(h),o=t(u);return{isActive:o===r,isPinned:n(u,r),activeArea:o,isSmall:e(P.store).isViewportMatch("< medium"),isLarge:e(P.store).isViewportMatch("large")}},[r,u]);!function(e,t,n,r,o){const i=Object(O.useRef)(!1),c=Object(O.useRef)(!1),{enableComplementaryArea:s,disableComplementaryArea:l}=Object(a.useDispatch)(h);Object(O.useEffect)(()=>{r&&o&&!i.current?(l(e),c.current=!0):c.current&&!o&&i.current?(c.current=!1,s(e,t)):c.current&&n&&n!==t&&(c.current=!1),o!==i.current&&(i.current=o)},[r,o,e,t,n])}(u,r,T,g,k);const{enableComplementaryArea:I,disableComplementaryArea:B,pinItem:L,unpinItem:R}=Object(a.useDispatch)(h);return Object(O.useEffect)(()=>{f&&void 0===T&&!k&&I(u,r)},[T,f,u,r,k]),Object(O.createElement)(O.Fragment,null,s&&Object(O.createElement)(D,{scope:u},y&&Object(O.createElement)(A,{scope:u,identifier:r,isPressed:g&&(!v||C),"aria-expanded":g,label:m,icon:v?w.a:c,showTooltip:!v,isTertiary:v})),d&&s&&Object(O.createElement)(N,{target:d,scope:u,icon:c},m),g&&Object(O.createElement)(V,{className:j()("interface-complementary-area",t),scope:u},Object(O.createElement)(M,{className:i,closeLabel:n,onClose:()=>B(u),smallScreenTitle:p,toggleButtonProps:{label:n,shortcut:b,scope:u,identifier:r}},o||Object(O.createElement)(O.Fragment,null,Object(O.createElement)("strong",null,m),s&&Object(O.createElement)(E.Button,{className:"interface-complementary-area__pin-unpin-item",icon:y?S.a:x.a,label:y?Object(_.__)("Unpin from toolbar"):Object(_.__)("Pin to toolbar"),onClick:()=>(y?R:L)(u,r),isPressed:y,"aria-expanded":y}))),Object(O.createElement)(E.Panel,{className:l},e)))}));F.Slot=function({scope:e,...t}){return Object(O.createElement)(E.Slot,Object(g.a)({name:"ComplementaryArea/"+e},t))};var U=F;class G extends O.Component{componentDidMount(){this.isSticky=!1,this.sync(),document.body.classList.contains("sticky-menu")&&(this.isSticky=!0,document.body.classList.remove("sticky-menu"))}componentWillUnmount(){this.isSticky&&document.body.classList.add("sticky-menu"),this.props.isActive&&document.body.classList.remove("is-fullscreen-mode")}componentDidUpdate(e){this.props.isActive!==e.isActive&&this.sync()}sync(){const{isActive:e}=this.props;e?document.body.classList.add("is-fullscreen-mode"):document.body.classList.remove("is-fullscreen-mode")}render(){return null}}var H=G,z=n("K9lf");var q=Object(O.forwardRef)((function({footer:e,header:t,sidebar:n,secondarySidebar:r,notices:o,content:a,drawer:i,actions:c,labels:s,className:l,shortcuts:u},d){const p=Object(O.useRef)(),m=Object(E.__unstableUseNavigateRegions)(p,u);!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 b={...{drawer:Object(_.__)("Drawer"),header:Object(_.__)("Header"),body:Object(_.__)("Content"),secondarySidebar:Object(_.__)("Block Library"),sidebar:Object(_.__)("Settings"),actions:Object(_.__)("Publish"),footer:Object(_.__)("Footer")},...s};return Object(O.createElement)("div",{ref:Object(z.useMergeRefs)([d,p]),className:j()(l,"interface-interface-skeleton",m,!!e&&"has-footer")},!!i&&Object(O.createElement)("div",{className:"interface-interface-skeleton__drawer",role:"region","aria-label":b.drawer},i),Object(O.createElement)("div",{className:"interface-interface-skeleton__editor"},!!t&&Object(O.createElement)("div",{className:"interface-interface-skeleton__header",role:"region","aria-label":b.header,tabIndex:"-1"},t),Object(O.createElement)("div",{className:"interface-interface-skeleton__body"},!!r&&Object(O.createElement)("div",{className:"interface-interface-skeleton__secondary-sidebar",role:"region","aria-label":b.secondarySidebar,tabIndex:"-1"},r),!!o&&Object(O.createElement)("div",{className:"interface-interface-skeleton__notices"},o),Object(O.createElement)("div",{className:"interface-interface-skeleton__content",role:"region","aria-label":b.body,tabIndex:"-1"},a),!!n&&Object(O.createElement)("div",{className:"interface-interface-skeleton__sidebar",role:"region","aria-label":b.sidebar,tabIndex:"-1"},n),!!c&&Object(O.createElement)("div",{className:"interface-interface-skeleton__actions",role:"region","aria-label":b.actions,tabIndex:"-1"},c))),!!e&&Object(O.createElement)("div",{className:"interface-interface-skeleton__footer",role:"region","aria-label":b.footer,tabIndex:"-1"},e))}))},URob:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},VKE3:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));t.a=a},Xxwi:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},Y5n4:function(e,t,n){"use strict";n.d(t,"a",(function(){return l})),n.d(t,"c",(function(){return p})),n.d(t,"d",(function(){return v})),n.d(t,"e",(function(){return g})),n.d(t,"b",(function(){return O}));var r=n("GRId"),o=n("l3Sj"),a=n("tI+e"),i=n("1ZqX");var c=function({help:e,label:t,isChecked:n,onChange:o,children:i}){return Object(r.createElement)("div",{className:"edit-post-preferences-modal__option"},Object(r.createElement)(a.ToggleControl,{help:e,label:t,checked:n,onChange:o}),i)};function s({willEnable:e}){const[t,n]=Object(r.useState)(!1);return Object(r.createElement)(r.Fragment,null,Object(r.createElement)("p",{className:"edit-post-preferences-modal__custom-fields-confirmation-message"},Object(o.__)("A page reload is required for this change. Make sure your content is saved before reloading.")),Object(r.createElement)(a.Button,{className:"edit-post-preferences-modal__custom-fields-confirmation-button",isSecondary:!0,isBusy:t,disabled:t,onClick:()=>{n(!0),document.getElementById("toggle-custom-fields-form").submit()}},e?Object(o.__)("Enable & Reload"):Object(o.__)("Disable & Reload")))}var l=Object(i.withSelect)(e=>({areCustomFieldsEnabled:!!e("core/editor").getEditorSettings().enableCustomFields}))((function({label:e,areCustomFieldsEnabled:t}){const[n,o]=Object(r.useState)(t);return Object(r.createElement)(c,{label:e,isChecked:n,onChange:o},n!==t&&Object(r.createElement)(s,{willEnable:n}))})),u=n("K9lf"),d=n("T40v"),p=Object(u.compose)(Object(i.withSelect)((e,{panelName:t})=>{const{isEditorPanelEnabled:n,isEditorPanelRemoved:r}=e(d.a);return{isRemoved:r(t),isChecked:n(t)}}),Object(u.ifCondition)(({isRemoved:e})=>!e),Object(i.withDispatch)((e,{panelName:t})=>({onChange:()=>e(d.a).toggleEditorPanelEnabled(t)})))(c);const{Fill:m,Slot:b}=Object(a.createSlotFill)("EnablePluginDocumentSettingPanelOption"),f=({label:e,panelName:t})=>Object(r.createElement)(m,null,Object(r.createElement)(p,{label:e,panelName:t}));f.Slot=b;var v=f,h=n("KEfo"),g=Object(u.compose)(Object(i.withSelect)(e=>({isChecked:e("core/editor").isPublishSidebarEnabled()})),Object(i.withDispatch)(e=>{const{enablePublishSidebar:t,disablePublishSidebar:n}=e("core/editor");return{onChange:e=>e?t():n()}}),Object(h.ifViewportMatches)("medium"))(c),O=Object(u.compose)(Object(i.withSelect)((e,{featureName:t})=>{const{isFeatureActive:n}=e(d.a);return{isChecked:n(t)}}),Object(i.withDispatch)((e,{featureName:t})=>({onChange:()=>e(d.a).toggleFeature(t)})))(c)},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 r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},cDcd:function(e,t){e.exports=window.React},cjQ8:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},dSQ2:function(e,t,n){"use strict";n.r(t),n.d(t,"reinitializeEditor",(function(){return Js})),n.d(t,"initializeEditor",(function(){return el})),n.d(t,"PluginBlockSettingsMenuItem",(function(){return Zs})),n.d(t,"PluginDocumentSettingPanel",(function(){return ys.a})),n.d(t,"PluginMoreMenuItem",(function(){return Qs})),n.d(t,"PluginPostPublishPanel",(function(){return Ns})),n.d(t,"PluginPostStatusInfo",(function(){return rs})),n.d(t,"PluginPrePublishPanel",(function(){return Fs})),n.d(t,"PluginSidebar",(function(){return js})),n.d(t,"PluginSidebarMoreMenuItem",(function(){return $s})),n.d(t,"__experimentalFullscreenModeClose",(function(){return mc})),n.d(t,"__experimentalMainDashboardButton",(function(){return Ic})),n.d(t,"store",(function(){return w.a}));var r=n("GRId"),o=n("jZUy"),a=n("axFQ"),i=n("jSdM"),c=n("QyPg"),s=n("g56x"),l=n("6aBm");Object(s.addFilter)("editor.MediaUpload","core/edit-post/replace-media-upload",()=>l.MediaUpload);var u=n("wx14"),d=n("YLtl"),p=n("HSyU"),m=n("tI+e"),b=n("1ZqX"),f=n("l3Sj"),v=n("K9lf");const h=Object(v.compose)(Object(b.withSelect)((e,t)=>{if(Object(p.hasBlockSupport)(t.name,"multiple",!0))return{};const n=e(a.store).getBlocks(),r=Object(d.find)(n,({name:e})=>t.name===e);return{originalBlockClientId:r&&r.clientId!==t.clientId&&r.clientId}}),Object(b.withDispatch)((e,{originalBlockClientId:t})=>({selectFirst:()=>e(a.store).selectBlock(t)}))),g=Object(v.createHigherOrderComponent)(e=>h(({originalBlockClientId:t,selectFirst:n,...o})=>{if(!t)return Object(r.createElement)(e,o);const i=Object(p.getBlockType)(o.name),c=function(e){const t=Object(p.findTransform)(Object(p.getBlockTransforms)("to",e),({type:e,blocks:t})=>"block"===e&&1===t.length);if(!t)return null;return Object(p.getBlockType)(t.blocks[0])}(o.name);return[Object(r.createElement)("div",{key:"invalid-preview",style:{minHeight:"60px"}},Object(r.createElement)(e,Object(u.a)({key:"block-edit"},o))),Object(r.createElement)(a.Warning,{key:"multiple-use-warning",actions:[Object(r.createElement)(m.Button,{key:"find-original",isSecondary:!0,onClick:n},Object(f.__)("Find original")),Object(r.createElement)(m.Button,{key:"remove",isSecondary:!0,onClick:()=>o.onReplace([])},Object(f.__)("Remove")),c&&Object(r.createElement)(m.Button,{key:"transform",isSecondary:!0,onClick:()=>o.onReplace(Object(p.createBlock)(c.name,o.attributes))},Object(f.__)("Transform into:")," ",c.title)]},Object(r.createElement)("strong",null,i.title,": "),Object(f.__)("This block can only be used once."))]}),"withMultipleValidation");Object(s.addFilter)("editor.BlockEdit","core/edit-post/validate-multiple-use/with-multiple-validation",g);var O=n("K+tz"),y=n("TvNi"),j=n("Mmq9"),E=n("onLe");function _(){const{createNotice:e}=Object(b.useDispatch)(E.store),t=Object(b.useSelect)(e=>()=>e(i.store).getEditedPostAttribute("content"),[]);const n=Object(v.useCopyToClipboard)(t,(function(){e("info",Object(f.__)("All content copied."),{isDismissible:!0,type:"snackbar"})}));return Object(r.createElement)(m.MenuItem,{ref:n},Object(f.__)("Copy all content"))}var w=n("T40v");var S=Object(b.withDispatch)(e=>{const{openModal:t}=e(w.a);return{openModal:t}})((function({openModal:e}){return Object(r.createElement)(m.MenuItem,{onClick:()=>{e("edit-post/manage-blocks")}},Object(f.__)("Block Manager"))})),x=n("RxS6");var P=Object(b.withDispatch)(e=>{const{openModal:t}=e(w.a);return{openModal:t}})((function({openModal:e}){return Object(r.createElement)(m.MenuItem,{onClick:()=>{e("edit-post/keyboard-shortcut-help")},shortcut:x.displayShortcut.access("h")},Object(f.__)("Keyboard shortcuts"))}));const{Fill:T,Slot:k}=Object(m.createSlotFill)("ToolsMoreMenuGroup");T.Slot=({fillProps:e})=>Object(r.createElement)(k,{fillProps:e},e=>!Object(d.isEmpty)(e)&&Object(r.createElement)(m.MenuGroup,{label:Object(f.__)("Tools")},e));var C=T;function A(){const e=Object(b.useSelect)(e=>e(w.a).isEditingTemplate(),[]),{toggleFeature:t}=Object(b.useDispatch)(w.a);return Object(r.createElement)(m.MenuItem,{onClick:()=>t(e?"welcomeGuideTemplate":"welcomeGuide")},Object(f.__)("Welcome Guide"))}Object(y.registerPlugin)("edit-post",{render:()=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)(C,null,({onClose:e})=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)(S,{onSelect:e}),Object(r.createElement)(m.MenuItem,{role:"menuitem",href:Object(j.addQueryArgs)("edit.php",{post_type:"wp_block"})},Object(f.__)("Manage Reusable blocks")),Object(r.createElement)(P,{onSelect:e}),Object(r.createElement)(A,null),Object(r.createElement)(_,null),Object(r.createElement)(m.MenuItem,{role:"menuitem",icon:O.a,href:Object(f.__)("https://wordpress.org/support/article/wordpress-editor/"),target:"_blank",rel:"noopener noreferrer"},Object(f.__)("Help"),Object(r.createElement)(m.VisuallyHidden,{as:"span"},Object(f.__)("(opens in a new tab)"))))))});var M={"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:"ðŸ¡ðŸ¢ðŸ¦€ðŸ¤ðŸ¦‹ðŸ˜ðŸ§ðŸ¹ðŸ¦ðŸ¦„ðŸ¦ðŸ¼ðŸ¿ðŸŽƒðŸ´ðŸðŸ†ðŸ¦•ðŸ¦”🌱ðŸ‡Ï€ðŸŒðŸ‰ðŸ’§ðŸ¥¨ðŸŒŒðŸ‚ðŸ 🥦🥚ðŸ¥ðŸŽŸðŸ¥¥ðŸ¥’🛵🥖ðŸ’ðŸ¯ðŸŽ¾ðŸŽ²ðŸºðŸšðŸ®âŒ›ï¸"})))}},I=n("TSYQ"),B=n.n(I),L=n("U60i"),N=n("hF7m");var R=Object(v.compose)(Object(b.withSelect)(e=>({isRichEditingEnabled:e("core/editor").getEditorSettings().richEditingEnabled})),Object(b.withDispatch)(e=>({onExit(){e(w.a).switchEditorMode("visual")}})))((function({onExit:e,isRichEditingEnabled:t}){return Object(r.createElement)("div",{className:"edit-post-text-editor"},t&&Object(r.createElement)("div",{className:"edit-post-text-editor__toolbar"},Object(r.createElement)("h2",null,Object(f.__)("Editing code")),Object(r.createElement)(m.Button,{isTertiary:!0,onClick:e,shortcut:x.displayShortcut.secondary("m")},Object(f.__)("Exit code editor")),Object(r.createElement)(i.TextEditorGlobalKeyboardShortcuts,null)),Object(r.createElement)("div",{className:"edit-post-text-editor__body"},Object(r.createElement)(i.PostTitle,null),Object(r.createElement)(i.PostTextEditor,null)))})),D=function(e,t){return(D=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])})(e,t)};function V(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}D(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}var F=function(){return(F=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function U(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}Object.create;function G(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,o,a=n.call(e),i=[];try{for(;(void 0===t||t-- >0)&&!(r=a.next()).done;)i.push(r.value)}catch(e){o={error:e}}finally{try{r&&!r.done&&(n=a.return)&&n.call(a)}finally{if(o)throw o.error}}return i}function H(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}Object.create;var z=n("cDcd"),q=n.n(z),W=function(e){return{isEnabled:function(t){return e.some((function(e){return!!t[e]}))}}},Y={measureLayout:W(["layout","layoutId","drag","_layoutResetTransform"]),animation:W(["animate","exit","variants","whileHover","whileTap","whileFocus","whileDrag"]),exit:W(["exit"]),drag:W(["drag","dragControls"]),focus:W(["whileFocus"]),hover:W(["whileHover","onHoverStart","onHoverEnd"]),tap:W(["whileTap","onTap","onTapStart","onTapCancel"]),pan:W(["onPan","onPanStart","onPanSessionStart","onPanEnd"]),layoutAnimation:W(["layout","layoutId"])};var X=Object(z.createContext)({strict:!1}),K=Object.keys(Y),Z=K.length;var Q=Object(z.createContext)({transformPagePoint:function(e){return e},isStatic:!1}),$=Object(z.createContext)({});var J=Object(z.createContext)(null);function ee(e){var t=Object(z.useRef)(null);return null===t.current&&(t.current=e()),t.current}function te(){var e=Object(z.useContext)(J);if(null===e)return[!0,null];var t=e.isPresent,n=e.onExitComplete,r=e.register,o=ae();Object(z.useEffect)((function(){return r(o)}),[]);return!t&&n?[!1,function(){return null==n?void 0:n(o)}]:[!0]}function ne(e){return null===e||e.isPresent}var re=0,oe=function(){return re++},ae=function(){return ee(oe)},ie=Object(z.createContext)(null),ce="undefined"!=typeof window,se=ce?z.useLayoutEffect:z.useEffect;function le(e,t,n,r){var o=Object(z.useContext)(Q),a=Object(z.useContext)(X),i=Object(z.useContext)($).visualElement,c=Object(z.useContext)(J),s=function(e){var t=e.layoutId,n=Object(z.useContext)(ie);return n&&void 0!==t?n+"-"+t:t}(n),l=Object(z.useRef)(void 0);r||(r=a.renderer),!l.current&&r&&(l.current=r(e,{visualState:t,parent:i,props:F(F({},n),{layoutId:s}),presenceId:null==c?void 0:c.id,blockInitialAnimation:!1===(null==c?void 0:c.initial)}));var u=l.current;return se((function(){u&&(u.setProps(F(F(F({},o),n),{layoutId:s})),u.isPresent=ne(c),u.isPresenceRoot=!i||i.presenceId!==(null==c?void 0:c.id),u.syncRender())})),Object(z.useEffect)((function(){var e;u&&(null===(e=u.animationState)||void 0===e||e.animateChanges())})),se((function(){return function(){return null==u?void 0:u.notifyUnmount()}}),[]),u}function ue(e){return"object"==typeof e&&Object.prototype.hasOwnProperty.call(e,"current")}function de(e){return Array.isArray(e)}function pe(e){return"string"==typeof e||de(e)}function me(e,t,n,r,o){var a;return void 0===r&&(r={}),void 0===o&&(o={}),"string"==typeof t&&(t=null===(a=e.variants)||void 0===a?void 0:a[t]),"function"==typeof t?t(null!=n?n:e.custom,r,o):t}function be(e,t,n){var r=e.getProps();return me(r,t,null!=n?n:r.custom,function(e){var t={};return e.forEachValue((function(e,n){return t[n]=e.get()})),t}(e),function(e){var t={};return e.forEachValue((function(e,n){return t[n]=e.getVelocity()})),t}(e))}function fe(e){var t;return"function"==typeof(null===(t=e.animate)||void 0===t?void 0:t.start)||pe(e.initial)||pe(e.animate)||pe(e.whileHover)||pe(e.whileDrag)||pe(e.whileTap)||pe(e.whileFocus)||pe(e.exit)}function ve(e){return Boolean(fe(e)||e.variants)}function he(e,t){var n=function(e,t){if(fe(e)){var n=e.initial,r=e.animate;return{initial:!1===n||pe(n)?n:void 0,animate:pe(r)?r:void 0}}return!1!==e.inherit?t:{}}(e,Object(z.useContext)($)),r=n.initial,o=n.animate;return Object(z.useMemo)((function(){return{initial:r,animate:o}}),t?[ge(r),ge(o)]:[])}function ge(e){return Array.isArray(e)?e.join(" "):e}function Oe(e){var t=e.preloadedFeatures,n=e.createVisualElement,r=e.useRender,o=e.useVisualState,a=e.Component;return t&&function(e){for(var t in e){var n=e[t];null!==n&&(Y[t].Component=n)}}(t),Object(z.forwardRef)((function(e,t){var i=Object(z.useContext)(Q).isStatic,c=null,s=he(e,i),l=o(e,i);return!i&&ce&&(s.visualElement=le(a,l,e,n),c=function(e,t,n){var r=[];if(Object(z.useContext)(X),!t)return null;for(var o=0;o<Z;o++){var a=K[o],i=Y[a],c=i.isEnabled,s=i.Component;c(e)&&s&&r.push(z.createElement(s,F({key:a},e,{visualElement:t})))}return r}(e,s.visualElement)),z.createElement(z.Fragment,null,z.createElement($.Provider,{value:s},r(a,e,function(e,t,n){return Object(z.useCallback)((function(r){var o;r&&(null===(o=e.mount)||void 0===o||o.call(e,r)),t&&(r?t.mount(r):t.unmount()),n&&("function"==typeof n?n(r):ue(n)&&(n.current=r))}),[t])}(l,s.visualElement,t),l,i)),c)}))}function ye(e){function t(t,n){return void 0===n&&(n={}),Oe(e(t,n))}var n=new Map;return new Proxy(t,{get:function(e,r){return n.has(r)||n.set(r,t(r)),n.get(r)}})}var je=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","svg","switch","symbol","text","tspan","use","view"];function Ee(e){return"string"==typeof e&&!e.includes("-")&&!!(je.indexOf(e)>-1||/[A-Z]/.test(e))}var _e={};var we=["","X","Y","Z"],Se=["transformPerspective","x","y","z"];function xe(e,t){return Se.indexOf(e)-Se.indexOf(t)}["translate","scale","rotate","skew"].forEach((function(e){return we.forEach((function(t){return Se.push(e+t)}))}));var Pe=new Set(Se);function Te(e){return Pe.has(e)}var ke=new Set(["originX","originY","originZ"]);function Ce(e){return ke.has(e)}function Ae(e,t){var n=t.layout,r=t.layoutId;return Te(e)||Ce(e)||(n||void 0!==r)&&(!!_e[e]||"opacity"===e)}var Me=function(e){return null!==e&&"object"==typeof e&&e.getVelocity},Ie={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"};function Be(e){return e.startsWith("--")}var Le=function(e,t){return t&&"number"==typeof e?t.transform(e):e};var Ne=function(){return(Ne=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};Object.create;Object.create;var Re=function(e,t){return function(n){return Math.max(Math.min(n,t),e)}},De=function(e){return e%1?Number(e.toFixed(5)):e},Ve=/(-)?([\d]*\.?[\d])+/g,Fe=/(#[0-9a-f]{6}|#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))/gi,Ue=/^(#[0-9a-f]{3}|#(?:[0-9a-f]{2}){2,4}|(rgb|hsl)a?\((-?[\d\.]+%?[,\s]+){2,3}\s*\/*\s*[\d\.]+%?\))$/i;function Ge(e){return"string"==typeof e}var He=function(e){return{test:function(t){return Ge(t)&&t.endsWith(e)&&1===t.split(" ").length},parse:parseFloat,transform:function(t){return""+t+e}}},ze=He("deg"),qe=He("%"),We=He("px"),Ye=He("vh"),Xe=He("vw"),Ke=Ne(Ne({},qe),{parse:function(e){return qe.parse(e)/100},transform:function(e){return qe.transform(100*e)}}),Ze={test:function(e){return"number"==typeof e},parse:parseFloat,transform:function(e){return e}},Qe=Ne(Ne({},Ze),{transform:Re(0,1)}),$e=Ne(Ne({},Ze),{default:1}),Je=F(F({},Ze),{transform:Math.round}),et={borderWidth:We,borderTopWidth:We,borderRightWidth:We,borderBottomWidth:We,borderLeftWidth:We,borderRadius:We,radius:We,borderTopLeftRadius:We,borderTopRightRadius:We,borderBottomRightRadius:We,borderBottomLeftRadius:We,width:We,maxWidth:We,height:We,maxHeight:We,size:We,top:We,right:We,bottom:We,left:We,padding:We,paddingTop:We,paddingRight:We,paddingBottom:We,paddingLeft:We,margin:We,marginTop:We,marginRight:We,marginBottom:We,marginLeft:We,rotate:ze,rotateX:ze,rotateY:ze,rotateZ:ze,scale:$e,scaleX:$e,scaleY:$e,scaleZ:$e,skew:ze,skewX:ze,skewY:ze,distance:We,translateX:We,translateY:We,translateZ:We,x:We,y:We,z:We,perspective:We,transformPerspective:We,opacity:Qe,originX:Ke,originY:Ke,originZ:We,zIndex:Je,fillOpacity:Qe,strokeOpacity:Qe,numOctaves:Je};function tt(e,t,n,r,o,a,i,c){var s,l=e.style,u=e.vars,d=e.transform,p=e.transformKeys,m=e.transformOrigin;p.length=0;var b=!1,f=!1,v=!0;for(var h in t){var g=t[h];if(Be(h))u[h]=g;else{var O=et[h],y=Le(g,O);if(Te(h)){if(b=!0,d[h]=y,p.push(h),!v)continue;g!==(null!==(s=O.default)&&void 0!==s?s:0)&&(v=!1)}else if(Ce(h))m[h]=y,f=!0;else if((null==n?void 0:n.isHydrated)&&(null==r?void 0:r.isHydrated)&&_e[h]){var j=_e[h].process(g,r,n),E=_e[h].applyTo;if(E)for(var _=E.length,w=0;w<_;w++)l[E[w]]=j;else l[h]=j}else l[h]=y}}r&&n&&i&&c?(l.transform=i(r.deltaFinal,r.treeScale,b?d:void 0),a&&(l.transform=a(d,l.transform)),l.transformOrigin=c(r)):(b&&(l.transform=function(e,t,n,r){var o=e.transform,a=e.transformKeys,i=t.enableHardwareAcceleration,c=void 0===i||i,s=t.allowTransformNone,l=void 0===s||s,u="";a.sort(xe);for(var d=!1,p=a.length,m=0;m<p;m++){var b=a[m];u+=(Ie[b]||b)+"("+o[b]+") ","z"===b&&(d=!0)}return!d&&c?u+="translateZ(0)":u=u.trim(),r?u=r(o,n?"":u):l&&n&&(u="none"),u}(e,o,v,a)),f&&(l.transformOrigin=function(e){var t=e.originX,n=void 0===t?"50%":t,r=e.originY,o=void 0===r?"50%":r,a=e.originZ;return n+" "+o+" "+(void 0===a?0:a)}(m)))}var nt=function(){return{style:{},transform:{},transformKeys:[],transformOrigin:{},vars:{}}};function rt(e,t,n){for(var r in t)Me(t[r])||Ae(r,n)||(e[r]=t[r])}function ot(e,t,n){var r={};return rt(r,e.style||{},e),Object.assign(r,function(e,t,n){var r=e.transformTemplate;return Object(z.useMemo)((function(){var e={style:{},transform:{},transformKeys:[],transformOrigin:{},vars:{}};tt(e,t,void 0,void 0,{enableHardwareAcceleration:!n},r);var o=e.style;return F(F({},e.vars),o)}),[t])}(e,t,n)),e.transformValues&&(r=e.transformValues(r)),r}function at(e,t,n){var r={},o=ot(e,t,n);return Boolean(e.drag)&&(r.draggable=!1,o.userSelect=o.WebkitUserSelect=o.WebkitTouchCallout="none",o.touchAction=!0===e.drag?"none":"pan-"+("x"===e.drag?"y":"x")),r.style=o,r}var it=new Set(["initial","animate","exit","style","variants","transition","transformTemplate","transformValues","custom","inherit","layout","layoutId","_layoutResetTransform","onLayoutAnimationComplete","onViewportBoxUpdate","onLayoutMeasure","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","drag","dragControls","dragListener","dragConstraints","dragDirectionLock","_dragX","_dragY","dragElastic","dragMomentum","dragPropagation","dragTransition","whileDrag","onPan","onPanStart","onPanEnd","onPanSessionStart","onTap","onTapStart","onTapCancel","onHoverStart","onHoverEnd","whileFocus","whileTap","whileHover"]);function ct(e){return it.has(e)}var st=function(e){return!ct(e)};try{var lt=n("9uj6").default;st=function(e){return e.startsWith("on")?!ct(e):lt(e)}}catch(e){}function ut(e,t,n){return"string"==typeof e?e:We.transform(t+n*e)}var dt=function(e,t){return We.transform(e*t)},pt={offset:"stroke-dashoffset",array:"stroke-dasharray"},mt={offset:"strokeDashoffset",array:"strokeDasharray"};function bt(e,t,n,r,o,a,i,c){var s=t.attrX,l=t.attrY,u=t.originX,d=t.originY,p=t.pathLength,m=t.pathSpacing,b=void 0===m?1:m,f=t.pathOffset,v=void 0===f?0:f;tt(e,U(t,["attrX","attrY","originX","originY","pathLength","pathSpacing","pathOffset"]),n,r,o,a,i,c),e.attrs=e.style,e.style={};var h=e.attrs,g=e.style,O=e.dimensions,y=e.totalPathLength;h.transform&&(O&&(g.transform=h.transform),delete h.transform),O&&(void 0!==u||void 0!==d||g.transform)&&(g.transformOrigin=function(e,t,n){return ut(t,e.x,e.width)+" "+ut(n,e.y,e.height)}(O,void 0!==u?u:.5,void 0!==d?d:.5)),void 0!==s&&(h.x=s),void 0!==l&&(h.y=l),void 0!==y&&void 0!==p&&function(e,t,n,r,o,a){void 0===r&&(r=1),void 0===o&&(o=0),void 0===a&&(a=!0);var i=a?pt:mt;e[i.offset]=dt(-o,t);var c=dt(n,t),s=dt(r,t);e[i.array]=c+" "+s}(h,y,p,b,v,!1)}var ft=function(){return F(F({},{style:{},transform:{},transformKeys:[],transformOrigin:{},vars:{}}),{attrs:{}})};function vt(e,t){var n=Object(z.useMemo)((function(){var n=ft();return bt(n,t,void 0,void 0,{enableHardwareAcceleration:!1},e.transformTemplate),F(F({},n.attrs),{style:F({},n.style)})}),[t]);if(e.style){var r={};rt(r,e.style,e),n.style=F(F({},r),n.style)}return n}function ht(e){void 0===e&&(e=!1);return function(t,n,r,o,a){var i=o.latestValues,c=(Ee(t)?vt:at)(n,i,a),s=function(e,t,n){var r={};for(var o in e)(st(o)||!0===n&&ct(o)||!t&&!ct(o))&&(r[o]=e[o]);return r}(n,"string"==typeof t,e),l=F(F(F({},s),c),{ref:r});return Object(z.createElement)(t,l)}}var gt=/([a-z])([A-Z])/g,Ot=function(e){return e.replace(gt,"$1-$2").toLowerCase()};function yt(e,t){var n=t.style,r=t.vars;for(var o in Object.assign(e.style,n),r)e.style.setProperty(o,r[o])}var jt=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform"]);function Et(e,t){for(var n in yt(e,t),t.attrs)e.setAttribute(jt.has(n)?n:Ot(n),t.attrs[n])}function _t(e){var t=e.style,n={};for(var r in t)(Me(t[r])||Ae(r,e))&&(n[r]=t[r]);return n}function wt(e){var t=_t(e);for(var n in e){if(Me(e[n]))t["x"===n||"y"===n?"attr"+n.toUpperCase():n]=e[n]}return t}function St(e){return"object"==typeof e&&"function"==typeof e.start}var xt=function(e){return Array.isArray(e)};function Pt(e){var t,n=Me(e)?e.get():e;return t=n,Boolean(t&&"object"==typeof t&&t.mix&&t.toValue)?n.toValue():n}function Tt(e,t,n,r){var o=e.scrapeMotionValuesFromProps,a=e.createRenderState,i=e.onMount,c={latestValues:Ct(t,n,r,o),renderState:a()};return i&&(c.mount=function(e){return i(t,e,c)}),c}var kt=function(e){return function(t,n){var r=Object(z.useContext)($),o=Object(z.useContext)(J);return n?Tt(e,t,r,o):ee((function(){return Tt(e,t,r,o)}))}};function Ct(e,t,n,r){var o={},a=!1===(null==n?void 0:n.initial),i=r(e);for(var c in i)o[c]=Pt(i[c]);var s=e.initial,l=e.animate,u=fe(e),d=ve(e);t&&d&&!u&&!1!==e.inherit&&(null!=s||(s=t.initial),null!=l||(l=t.animate));var p=a||!1===s?l:s;p&&"boolean"!=typeof p&&!St(p)&&(Array.isArray(p)?p:[p]).forEach((function(t){var n=me(e,t);if(n){var r=n.transitionEnd;n.transition;var a=U(n,["transitionEnd","transition"]);for(var i in a)o[i]=a[i];for(var i in r)o[i]=r[i]}}));return o}var At={useVisualState:kt({scrapeMotionValuesFromProps:wt,createRenderState:ft,onMount:function(e,t,n){var r=n.renderState,o=n.latestValues;try{r.dimensions="function"==typeof t.getBBox?t.getBBox():t.getBoundingClientRect()}catch(e){r.dimensions={x:0,y:0,width:0,height:0}}"path"===t.tagName&&(r.totalPathLength=t.getTotalLength()),bt(r,o,void 0,void 0,{enableHardwareAcceleration:!1},e.transformTemplate),Et(t,r)}})};var Mt,It={useVisualState:kt({scrapeMotionValuesFromProps:_t,createRenderState:nt})};function Bt(e,t,n,r){var o=t.forwardMotionProps,a=void 0!==o&&o,i=Ee(e)?At:It;return F(F({},i),{preloadedFeatures:n,useRender:ht(a),createVisualElement:r,Component:e})}function Lt(e,t,n,r){return e.addEventListener(t,n,r),function(){return e.removeEventListener(t,n,r)}}function Nt(e,t,n,r){Object(z.useEffect)((function(){var o=e.current;if(n&&o)return Lt(o,t,n,r)}),[e,t,n,r])}function Rt(e){return"undefined"!=typeof PointerEvent&&e instanceof PointerEvent?!("mouse"!==e.pointerType):e instanceof MouseEvent}function Dt(e){return!!e.touches}!function(e){e.Animate="animate",e.Hover="whileHover",e.Tap="whileTap",e.Drag="whileDrag",e.Focus="whileFocus",e.Exit="exit"}(Mt||(Mt={}));var Vt={pageX:0,pageY:0};function Ft(e,t){void 0===t&&(t="page");var n=e.touches[0]||e.changedTouches[0]||Vt;return{x:n[t+"X"],y:n[t+"Y"]}}function Ut(e,t){return void 0===t&&(t="page"),{x:e[t+"X"],y:e[t+"Y"]}}function Gt(e,t){return void 0===t&&(t="page"),{point:Dt(e)?Ft(e,t):Ut(e,t)}}var Ht=function(e,t){void 0===t&&(t=!1);var n,r=function(t){return e(t,Gt(t))};return t?(n=r,function(e){var t=e instanceof MouseEvent;(!t||t&&0===e.button)&&n(e)}):r},zt={pointerdown:"mousedown",pointermove:"mousemove",pointerup:"mouseup",pointercancel:"mousecancel",pointerover:"mouseover",pointerout:"mouseout",pointerenter:"mouseenter",pointerleave:"mouseleave"},qt={pointerdown:"touchstart",pointermove:"touchmove",pointerup:"touchend",pointercancel:"touchcancel"};function Wt(e){return ce&&null===window.onpointerdown?e:ce&&null===window.ontouchstart?qt[e]:ce&&null===window.onmousedown?zt[e]:e}function Yt(e,t,n,r){return Lt(e,Wt(t),Ht(n,"pointerdown"===t),r)}function Xt(e,t,n,r){return Nt(e,Wt(t),n&&Ht(n,"pointerdown"===t),r)}function Kt(e){var t=null;return function(){return null===t&&(t=e,function(){t=null})}}var Zt=Kt("dragHorizontal"),Qt=Kt("dragVertical");function $t(e){var t=!1;if("y"===e)t=Qt();else if("x"===e)t=Zt();else{var n=Zt(),r=Qt();n&&r?t=function(){n(),r()}:(n&&n(),r&&r())}return t}function Jt(){var e=$t(!0);return!e||(e(),!1)}function en(e,t,n){return function(r,o){var a;Rt(r)&&!Jt()&&(null==n||n(r,o),null===(a=e.animationState)||void 0===a||a.setActive(Mt.Hover,t))}}var tn=function(e,t){return!!t&&(e===t||tn(e,t.parentElement))};function nn(e){return Object(z.useEffect)((function(){return function(){return e()}}),[])}var rn=function(e,t){return function(n){return t(e(n))}},on=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.reduce(rn)};var an=function(e){return function(t){return e(t),null}},cn={tap:an((function(e){var t=e.onTap,n=e.onTapStart,r=e.onTapCancel,o=e.whileTap,a=e.visualElement,i=t||n||r||o,c=Object(z.useRef)(!1),s=Object(z.useRef)(null);function l(){var e;null===(e=s.current)||void 0===e||e.call(s),s.current=null}function u(){var e;return l(),c.current=!1,null===(e=a.animationState)||void 0===e||e.setActive(Mt.Tap,!1),!Jt()}function d(e,n){u()&&(tn(a.getInstance(),e.target)?null==t||t(e,n):null==r||r(e,n))}function p(e,t){u()&&(null==r||r(e,t))}Xt(a,"pointerdown",i?function(e,t){var r;l(),c.current||(c.current=!0,s.current=on(Yt(window,"pointerup",d),Yt(window,"pointercancel",p)),null==n||n(e,t),null===(r=a.animationState)||void 0===r||r.setActive(Mt.Tap,!0))}:void 0),nn(l)})),focus:an((function(e){var t=e.whileFocus,n=e.visualElement;Nt(n,"focus",t?function(){var e;null===(e=n.animationState)||void 0===e||e.setActive(Mt.Focus,!0)}:void 0),Nt(n,"blur",t?function(){var e;null===(e=n.animationState)||void 0===e||e.setActive(Mt.Focus,!1)}:void 0)})),hover:an((function(e){var t=e.onHoverStart,n=e.onHoverEnd,r=e.whileHover,o=e.visualElement;Xt(o,"pointerenter",t||r?en(o,!0,t):void 0),Xt(o,"pointerleave",n||r?en(o,!1,n):void 0)}))};function sn(e,t){if(!Array.isArray(t))return!1;var n=t.length;if(n!==e.length)return!1;for(var r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}var ln=function(){return(ln=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e}).apply(this,arguments)};function un(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}Object.create;Object.create;var dn=function(e,t,n){return Math.min(Math.max(n,e),t)};function pn(e){var t,n,r=e.duration,o=void 0===r?800:r,a=e.bounce,i=void 0===a?.25:a,c=e.velocity,s=void 0===c?0:c,l=e.mass,u=void 0===l?1:l,d=1-i;d=dn(.05,1,d),o=dn(.01,10,o/1e3),d<1?(t=function(e){var t=e*d,n=t*o;return.001-(t-s)/mn(e,d)*Math.exp(-n)},n=function(e){var n=e*d*o,r=n*s+s,a=Math.pow(d,2)*Math.pow(e,2)*o,i=Math.exp(-n),c=mn(Math.pow(e,2),d);return(.001-t(e)>0?-1:1)*((r-a)*i)/c}):(t=function(e){return Math.exp(-e*o)*((e-s)*o+1)-.001},n=function(e){return Math.exp(-e*o)*(o*o*(s-e))});var p=function(e,t,n){for(var r=n,o=1;o<12;o++)r-=e(r)/t(r);return r}(t,n,5/o);if(o*=1e3,isNaN(p))return{stiffness:100,damping:10,duration:o};var m=Math.pow(p,2)*u;return{stiffness:m,damping:2*d*Math.sqrt(u*m),duration:o}}function mn(e,t){return e*Math.sqrt(1-t*t)}var bn=["duration","bounce"],fn=["stiffness","damping","mass"];function vn(e,t){return t.some((function(t){return void 0!==e[t]}))}function hn(e){var t=e.from,n=void 0===t?0:t,r=e.to,o=void 0===r?1:r,a=e.restSpeed,i=void 0===a?2:a,c=e.restDelta,s=un(e,["from","to","restSpeed","restDelta"]),l={done:!1,value:n},u=function(e){var t=ln({velocity:0,stiffness:100,damping:10,mass:1,isResolvedFromDuration:!1},e);if(!vn(e,fn)&&vn(e,bn)){var n=pn(e);(t=ln(ln(ln({},t),n),{velocity:0,mass:1})).isResolvedFromDuration=!0}return t}(s),d=u.stiffness,p=u.damping,m=u.mass,b=u.velocity,f=u.duration,v=u.isResolvedFromDuration,h=gn,g=gn;function O(){var e=b?-b/1e3:0,t=o-n,r=p/(2*Math.sqrt(d*m)),a=Math.sqrt(d/m)/1e3;if(null!=c||(c=Math.abs(o-n)<=1?.01:.4),r<1){var i=mn(a,r);h=function(n){var c=Math.exp(-r*a*n);return o-c*((e+r*a*t)/i*Math.sin(i*n)+t*Math.cos(i*n))},g=function(n){var o=Math.exp(-r*a*n);return r*a*o*(Math.sin(i*n)*(e+r*a*t)/i+t*Math.cos(i*n))-o*(Math.cos(i*n)*(e+r*a*t)-i*t*Math.sin(i*n))}}else if(1===r)h=function(n){return o-Math.exp(-a*n)*(t+(e+a*t)*n)};else{var s=a*Math.sqrt(r*r-1);h=function(n){var i=Math.exp(-r*a*n),c=Math.min(s*n,300);return o-i*((e+r*a*t)*Math.sinh(c)+s*t*Math.cosh(c))/s}}}return O(),{next:function(e){var t=h(e);if(v)l.done=e>=f;else{var n=1e3*g(e),r=Math.abs(n)<=i,a=Math.abs(o-t)<=c;l.done=r&&a}return l.value=l.done?o:t,l},flipTarget:function(){var e;b=-b,n=(e=[o,n])[0],o=e[1],O()}}}hn.needsInterpolation=function(e,t){return"string"==typeof e||"string"==typeof t};var gn=function(e){return 0},On=function(e,t,n){var r=t-e;return 0===r?1:(n-e)/r},yn=function(e,t,n){return-n*e+n*t+e},jn=function(e,t){return function(n){return Boolean(Ge(n)&&Ue.test(n)&&n.startsWith(e)||t&&Object.prototype.hasOwnProperty.call(n,t))}},En=function(e,t,n){return function(r){var o;if(!Ge(r))return r;var a=r.match(Ve),i=a[0],c=a[1],s=a[2],l=a[3];return(o={})[e]=parseFloat(i),o[t]=parseFloat(c),o[n]=parseFloat(s),o.alpha=void 0!==l?parseFloat(l):1,o}},_n=Re(0,255),wn=Ne(Ne({},Ze),{transform:function(e){return Math.round(_n(e))}}),Sn={test:jn("rgb","red"),parse:En("red","green","blue"),transform:function(e){var t=e.red,n=e.green,r=e.blue,o=e.alpha,a=void 0===o?1:o;return"rgba("+wn.transform(t)+", "+wn.transform(n)+", "+wn.transform(r)+", "+De(Qe.transform(a))+")"}};var xn={test:jn("#"),parse:function(e){var t="",n="",r="",o="";return e.length>5?(t=e.substr(1,2),n=e.substr(3,2),r=e.substr(5,2),o=e.substr(7,2)):(t=e.substr(1,1),n=e.substr(2,1),r=e.substr(3,1),o=e.substr(4,1),t+=t,n+=n,r+=r,o+=o),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}},transform:Sn.transform},Pn={test:jn("hsl","hue"),parse:En("hue","saturation","lightness"),transform:function(e){var t=e.hue,n=e.saturation,r=e.lightness,o=e.alpha,a=void 0===o?1:o;return"hsla("+Math.round(t)+", "+qe.transform(De(n))+", "+qe.transform(De(r))+", "+De(Qe.transform(a))+")"}},Tn=function(e,t,n){var r=e*e,o=t*t;return Math.sqrt(Math.max(0,n*(o-r)+r))},kn=[xn,Sn,Pn],Cn=function(e){return kn.find((function(t){return t.test(e)}))},An=function(e){return"'"+e+"' is not an animatable color. Use the equivalent color code instead."},Mn=function(e,t){var n=Cn(e),r=Cn(t);An(e),An(t),n.transform,r.transform;var o=n.parse(e),a=r.parse(t),i=ln({},o),c=n===Pn?yn:Tn;return function(e){for(var t in i)"alpha"!==t&&(i[t]=c(o[t],a[t],e));return i.alpha=yn(o.alpha,a.alpha,e),n.transform(i)}},In={test:function(e){return Sn.test(e)||xn.test(e)||Pn.test(e)},parse:function(e){return Sn.test(e)?Sn.parse(e):Pn.test(e)?Pn.parse(e):xn.parse(e)},transform:function(e){return Ge(e)?e:e.hasOwnProperty("red")?Sn.transform(e):Pn.transform(e)}};function Bn(e){var t=[],n=0,r=e.match(Fe);r&&(n=r.length,e=e.replace(Fe,"${c}"),t.push.apply(t,r.map(In.parse)));var o=e.match(Ve);return o&&(e=e.replace(Ve,"${n}"),t.push.apply(t,o.map(Ze.parse))),{values:t,numColors:n,tokenised:e}}function Ln(e){return Bn(e).values}function Nn(e){var t=Bn(e),n=t.values,r=t.numColors,o=t.tokenised,a=n.length;return function(e){for(var t=o,n=0;n<a;n++)t=t.replace(n<r?"${c}":"${n}",n<r?In.transform(e[n]):De(e[n]));return t}}var Rn=function(e){return"number"==typeof e?0:e};var Dn={test:function(e){var t,n,r,o;return isNaN(e)&&Ge(e)&&(null!==(n=null===(t=e.match(Ve))||void 0===t?void 0:t.length)&&void 0!==n?n:0)+(null!==(o=null===(r=e.match(Fe))||void 0===r?void 0:r.length)&&void 0!==o?o:0)>0},parse:Ln,createTransformer:Nn,getAnimatableNone:function(e){var t=Ln(e);return Nn(e)(t.map(Rn))}},Vn=function(e){return"number"==typeof e};function Fn(e,t){return Vn(e)?function(n){return yn(e,t,n)}:In.test(e)?Mn(e,t):zn(e,t)}var Un=function(e,t){var n=function(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}([],e),r=n.length,o=e.map((function(e,n){return Fn(e,t[n])}));return function(e){for(var t=0;t<r;t++)n[t]=o[t](e);return n}},Gn=function(e,t){var n=ln(ln({},e),t),r={};for(var o in n)void 0!==e[o]&&void 0!==t[o]&&(r[o]=Fn(e[o],t[o]));return function(e){for(var t in r)n[t]=r[t](e);return n}};function Hn(e){for(var t=Dn.parse(e),n=t.length,r=0,o=0,a=0,i=0;i<n;i++)r||"number"==typeof t[i]?r++:void 0!==t[i].hue?a++:o++;return{parsed:t,numNumbers:r,numRGB:o,numHSL:a}}var zn=function(e,t){var n=Dn.createTransformer(t),r=Hn(e),o=Hn(t);return r.numHSL===o.numHSL&&r.numRGB===o.numRGB&&(r.numNumbers,o.numNumbers),on(Un(r.parsed,o.parsed),n)},qn=function(e,t){return function(n){return yn(e,t,n)}};function Wn(e,t,n){for(var r,o=[],a=n||("number"==typeof(r=e[0])?qn:"string"==typeof r?In.test(r)?Mn:zn:Array.isArray(r)?Un:"object"==typeof r?Gn:void 0),i=e.length-1,c=0;c<i;c++){var s=a(e[c],e[c+1]);if(t){var l=Array.isArray(t)?t[c]:t;s=on(l,s)}o.push(s)}return o}function Yn(e,t,n){var r=void 0===n?{}:n,o=r.clamp,a=void 0===o||o,i=r.ease,c=r.mixer,s=e.length;t.length,!i||!Array.isArray(i)||i.length,e[0]>e[s-1]&&(e=[].concat(e),t=[].concat(t),e.reverse(),t.reverse());var l=Wn(t,i,c),u=2===s?function(e,t){var n=e[0],r=e[1],o=t[0];return function(e){return o(On(n,r,e))}}(e,l):function(e,t){var n=e.length,r=n-1;return function(o){var a=0,i=!1;if(o<=e[0]?i=!0:o>=e[r]&&(a=r-1,i=!0),!i){for(var c=1;c<n&&!(e[c]>o||c===r);c++);a=c-1}var s=On(e[a],e[a+1],o);return t[a](s)}}(e,l);return a?function(t){return u(dn(e[0],e[s-1],t))}:u}var Xn,Kn=function(e){return function(t){return 1-e(1-t)}},Zn=function(e){return function(t){return t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2}},Qn=function(e){return function(t){return t*t*((e+1)*t-e)}},$n=function(e){return e},Jn=(Xn=2,function(e){return Math.pow(e,Xn)}),er=Kn(Jn),tr=Zn(Jn),nr=function(e){return 1-Math.sin(Math.acos(e))},rr=Kn(nr),or=Zn(rr),ar=Qn(1.525),ir=Kn(ar),cr=Zn(ar),sr=function(e){var t=Qn(e);return function(e){return(e*=2)<1?.5*t(e):.5*(2-Math.pow(2,-10*(e-1)))}}(1.525),lr=function(e){if(1===e||0===e)return e;var t=e*e;return e<4/11?7.5625*t:e<8/11?9.075*t-9.9*e+3.4:e<.9?4356/361*t-35442/1805*e+16061/1805:10.8*e*e-20.52*e+10.72},ur=Kn(lr);function dr(e,t){return e.map((function(){return t||tr})).splice(0,e.length-1)}function pr(e){var t=e.from,n=void 0===t?0:t,r=e.to,o=void 0===r?1:r,a=e.ease,i=e.offset,c=e.duration,s=void 0===c?300:c,l={done:!1,value:n},u=Array.isArray(o)?o:[n,o],d=function(e,t){return e.map((function(e){return e*t}))}(i&&i.length===u.length?i:function(e){var t=e.length;return e.map((function(e,n){return 0!==n?n/(t-1):0}))}(u),s);function p(){return Yn(d,u,{ease:Array.isArray(a)?a:dr(u,a)})}var m=p();return{next:function(e){return l.value=m(e),l.done=e>=s,l},flipTarget:function(){u.reverse(),m=p()}}}var mr={keyframes:pr,spring:hn,decay:function(e){var t=e.velocity,n=void 0===t?0:t,r=e.from,o=void 0===r?0:r,a=e.power,i=void 0===a?.8:a,c=e.timeConstant,s=void 0===c?350:c,l=e.restDelta,u=void 0===l?.5:l,d=e.modifyTarget,p={done:!1,value:o},m=i*n,b=o+m,f=void 0===d?b:d(b);return f!==b&&(m=f-o),{next:function(e){var t=-m*Math.exp(-e/s);return p.done=!(t>u||t<-u),p.value=p.done?f:f+t,p},flipTarget:function(){}}}};var br="undefined"!=typeof performance?function(){return performance.now()}:function(){return Date.now()},fr="undefined"!=typeof window?function(e){return window.requestAnimationFrame(e)}:function(e){return setTimeout((function(){return e(br())}),1/60*1e3)};var vr=!0,hr=!1,gr=!1,Or={delta:0,timestamp:0},yr=["read","update","preRender","render","postRender"],jr=yr.reduce((function(e,t){return e[t]=function(e){var t=[],n=[],r=0,o=!1,a=new WeakSet,i={schedule:function(e,i,c){void 0===i&&(i=!1),void 0===c&&(c=!1);var s=c&&o,l=s?t:n;return i&&a.add(e),-1===l.indexOf(e)&&(l.push(e),s&&o&&(r=t.length)),e},cancel:function(e){var t=n.indexOf(e);-1!==t&&n.splice(t,1),a.delete(e)},process:function(c){var s;if(o=!0,t=(s=[n,t])[0],(n=s[1]).length=0,r=t.length)for(var l=0;l<r;l++){var u=t[l];u(c),a.has(u)&&(i.schedule(u),e())}o=!1}};return i}((function(){return hr=!0})),e}),{}),Er=yr.reduce((function(e,t){var n=jr[t];return e[t]=function(e,t,r){return void 0===t&&(t=!1),void 0===r&&(r=!1),hr||Pr(),n.schedule(e,t,r)},e}),{}),_r=yr.reduce((function(e,t){return e[t]=jr[t].cancel,e}),{}),wr=yr.reduce((function(e,t){return e[t]=function(){return jr[t].process(Or)},e}),{}),Sr=function(e){return jr[e].process(Or)},xr=function(e){hr=!1,Or.delta=vr?1/60*1e3:Math.max(Math.min(e-Or.timestamp,40),1),Or.timestamp=e,gr=!0,yr.forEach(Sr),gr=!1,hr&&(vr=!1,fr(xr))},Pr=function(){hr=!0,vr=!0,gr||fr(xr)},Tr=function(){return Or},kr=Er;function Cr(e,t,n){return void 0===n&&(n=0),e-t-n}var Ar=function(e){var t=function(t){var n=t.delta;return e(n)};return{start:function(){return kr.update(t,!0)},stop:function(){return _r.update(t)}}};function Mr(e){var t,n,r,o,a,i=e.from,c=e.autoplay,s=void 0===c||c,l=e.driver,u=void 0===l?Ar:l,d=e.elapsed,p=void 0===d?0:d,m=e.repeat,b=void 0===m?0:m,f=e.repeatType,v=void 0===f?"loop":f,h=e.repeatDelay,g=void 0===h?0:h,O=e.onPlay,y=e.onStop,j=e.onComplete,E=e.onRepeat,_=e.onUpdate,w=un(e,["from","autoplay","driver","elapsed","repeat","repeatType","repeatDelay","onPlay","onStop","onComplete","onRepeat","onUpdate"]),S=w.to,x=0,P=w.duration,T=!1,k=!0,C=function(e){if(Array.isArray(e.to))return pr;if(mr[e.type])return mr[e.type];var t=new Set(Object.keys(e));return t.has("ease")||t.has("duration")&&!t.has("dampingRatio")?pr:t.has("dampingRatio")||t.has("stiffness")||t.has("mass")||t.has("damping")||t.has("restSpeed")||t.has("restDelta")?hn:pr}(w);(null===(n=(t=C).needsInterpolation)||void 0===n?void 0:n.call(t,i,S))&&(a=Yn([0,100],[i,S],{clamp:!1}),i=0,S=100);var A=C(ln(ln({},w),{from:i,to:S}));function M(){x++,"reverse"===v?p=function(e,t,n,r){return void 0===n&&(n=0),void 0===r&&(r=!0),r?Cr(t+-e,t,n):t-(e-t)+n}(p,P,g,k=x%2==0):(p=Cr(p,P,g),"mirror"===v&&A.flipTarget()),T=!1,E&&E()}function I(e){if(k||(e=-e),p+=e,!T){var t=A.next(Math.max(0,p));o=t.value,a&&(o=a(o)),T=k?t.done:p<=0}null==_||_(o),T&&(0===x&&(null!=P||(P=p)),x<b?function(e,t,n,r){return r?e>=t+n:e<=-n}(p,P,g,k)&&M():(r.stop(),j&&j()))}return s&&(null==O||O(),(r=u(I)).start()),{stop:function(){null==y||y(),r.stop()}}}function Ir(e,t){return t?e*(1e3/t):0}var Br=function(e){return 1e3*e},Lr=function(e,t){return 1-3*t+3*e},Nr=function(e,t){return 3*t-6*e},Rr=function(e){return 3*e},Dr=function(e,t,n){return((Lr(t,n)*e+Nr(t,n))*e+Rr(t))*e},Vr=function(e,t,n){return 3*Lr(t,n)*e*e+2*Nr(t,n)*e+Rr(t)};function Fr(e,t,n,r){if(e===t&&n===r)return $n;for(var o=new Float32Array(11),a=0;a<11;++a)o[a]=Dr(.1*a,e,n);function i(t){for(var r=0,a=1;10!==a&&o[a]<=t;++a)r+=.1;--a;var i=r+.1*((t-o[a])/(o[a+1]-o[a])),c=Vr(i,e,n);return c>=.001?function(e,t,n,r){for(var o=0;o<8;++o){var a=Vr(t,n,r);if(0===a)return t;t-=(Dr(t,n,r)-e)/a}return t}(t,i,e,n):0===c?i:function(e,t,n,r,o){var a,i,c=0;do{(a=Dr(i=t+(n-t)/2,r,o)-e)>0?n=i:t=i}while(Math.abs(a)>1e-7&&++c<10);return i}(t,r,r+.1,e,n)}return function(e){return 0===e||1===e?e:Dr(i(e),t,r)}}var Ur={linear:$n,easeIn:Jn,easeInOut:tr,easeOut:er,circIn:nr,circInOut:or,circOut:rr,backIn:ar,backInOut:cr,backOut:ir,anticipate:sr,bounceIn:ur,bounceInOut:function(e){return e<.5?.5*(1-lr(1-2*e)):.5*lr(2*e-1)+.5},bounceOut:lr},Gr=function(e){if(Array.isArray(e)){e.length;var t=G(e,4);return Fr(t[0],t[1],t[2],t[3])}return"string"==typeof e?Ur[e]:e},Hr=function(e,t){return"zIndex"!==e&&(!("number"!=typeof t&&!Array.isArray(t))||!("string"!=typeof t||!Dn.test(t)||t.startsWith("url(")))},zr=function(){return{type:"spring",stiffness:500,damping:25,restDelta:.5,restSpeed:10}},qr=function(e){return{type:"spring",stiffness:550,damping:0===e?2*Math.sqrt(550):30,restDelta:.01,restSpeed:10}},Wr=function(){return{type:"keyframes",ease:"linear",duration:.3}},Yr=function(e){return{type:"keyframes",duration:.8,values:e}},Xr={x:zr,y:zr,z:zr,rotate:zr,rotateX:zr,rotateY:zr,rotateZ:zr,scaleX:qr,scaleY:qr,scale:qr,opacity:Wr,backgroundColor:Wr,color:Wr,default:qr},Kr=new Set(["brightness","contrast","saturate","opacity"]);function Zr(e){var t=e.slice(0,-1).split("("),n=t[0],r=t[1];if("drop-shadow"===n)return e;var o=(r.match(Ve)||[])[0];if(!o)return e;var a=r.replace(o,""),i=Kr.has(n)?1:0;return o!==r&&(i*=100),n+"("+i+a+")"}var Qr=/([a-z-]*)\(.*?\)/g,$r=Ne(Ne({},Dn),{getAnimatableNone:function(e){var t=e.match(Qr);return t?t.map(Zr).join(" "):e}}),Jr=F(F({},et),{color:In,backgroundColor:In,outlineColor:In,fill:In,stroke:In,borderColor:In,borderTopColor:In,borderRightColor:In,borderBottomColor:In,borderLeftColor:In,filter:$r,WebkitFilter:$r}),eo=function(e){return Jr[e]};function to(e,t){var n,r=eo(e);return r!==$r&&(r=Dn),null===(n=r.getAnimatableNone)||void 0===n?void 0:n.call(r,t)}function no(e){var t=e.ease,n=e.times,r=e.yoyo,o=e.flip,a=e.loop,i=U(e,["ease","times","yoyo","flip","loop"]),c=F({},i);return n&&(c.offset=n),i.duration&&(c.duration=Br(i.duration)),i.repeatDelay&&(c.repeatDelay=Br(i.repeatDelay)),t&&(c.ease=function(e){return Array.isArray(e)&&"number"!=typeof e[0]}(t)?t.map(Gr):Gr(t)),"tween"===i.type&&(c.type="keyframes"),(r||a||o)&&(!0,r?c.repeatType="reverse":a?c.repeatType="loop":o&&(c.repeatType="mirror"),c.repeat=a||r||o||i.repeat),"spring"!==i.type&&(c.type="keyframes"),c}function ro(e,t,n){var r,o,a,i;return Array.isArray(t.to)&&(null!==(r=e.duration)&&void 0!==r||(e.duration=.8)),function(e){Array.isArray(e.to)&&null===e.to[0]&&(e.to=H([],G(e.to)),e.to[0]=e.from)}(t),function(e){e.when,e.delay,e.delayChildren,e.staggerChildren,e.staggerDirection,e.repeat,e.repeatType,e.repeatDelay,e.from;var t=U(e,["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from"]);return!!Object.keys(t).length}(e)||(e=F(F({},e),(o=n,a=t.to,i=xt(a)?Yr:Xr[o]||Xr.default,F({to:a},i(a))))),F(F({},t),no(e))}function oo(e,t,n,r,o){var a,i=co(r,e),c=null!==(a=i.from)&&void 0!==a?a:t.get(),s=Hr(e,n);"none"===c&&s&&"string"==typeof n?c=to(e,n):ao(c)&&"string"==typeof n?c=io(n):!Array.isArray(n)&&ao(n)&&"string"==typeof c&&(n=io(c));var l=Hr(e,c);return l&&s&&!1!==i.type?function(){var r={from:c,to:n,velocity:t.getVelocity(),onComplete:o,onUpdate:function(e){return t.set(e)}};return"inertia"===i.type||"decay"===i.type?function(e){var t,n=e.from,r=void 0===n?0:n,o=e.velocity,a=void 0===o?0:o,i=e.min,c=e.max,s=e.power,l=void 0===s?.8:s,u=e.timeConstant,d=void 0===u?750:u,p=e.bounceStiffness,m=void 0===p?500:p,b=e.bounceDamping,f=void 0===b?10:b,v=e.restDelta,h=void 0===v?1:v,g=e.modifyTarget,O=e.driver,y=e.onUpdate,j=e.onComplete;function E(e){return void 0!==i&&e<i||void 0!==c&&e>c}function _(e){return void 0===i?c:void 0===c||Math.abs(i-e)<Math.abs(c-e)?i:c}function w(e){null==t||t.stop(),t=Mr(ln(ln({},e),{driver:O,onUpdate:function(t){var n;null==y||y(t),null===(n=e.onUpdate)||void 0===n||n.call(e,t)},onComplete:j}))}function S(e){w(ln({type:"spring",stiffness:m,damping:f,restDelta:h},e))}if(E(r))S({from:r,velocity:a,to:_(r)});else{var x=l*a+r;void 0!==g&&(x=g(x));var P,T,k=_(x),C=k===i?-1:1;w({type:"decay",from:r,velocity:a,timeConstant:d,power:l,restDelta:h,modifyTarget:g,onUpdate:E(x)?function(e){P=T,T=e,a=Ir(e-P,Tr().delta),(1===C&&e>k||-1===C&&e<k)&&S({from:e,to:k,velocity:a})}:void 0})}return{stop:function(){return null==t?void 0:t.stop()}}}(F(F({},r),i)):Mr(F(F({},ro(i,r,e)),{onUpdate:function(e){var t;r.onUpdate(e),null===(t=i.onUpdate)||void 0===t||t.call(i,e)},onComplete:function(){var e;r.onComplete(),null===(e=i.onComplete)||void 0===e||e.call(i)}}))}:function(){var e;return t.set(n),o(),null===(e=null==i?void 0:i.onComplete)||void 0===e||e.call(i),{stop:function(){}}}}function ao(e){return 0===e||"string"==typeof e&&0===parseFloat(e)&&-1===e.indexOf(" ")}function io(e){return"number"==typeof e?0:to("",e)}function co(e,t){return e[t]||e.default||e}function so(e,t,n,r){return void 0===r&&(r={}),t.start((function(o){var a,i,c=oo(e,t,n,r,o),s=function(e,t){var n;return null!==(n=(co(e,t)||{}).delay)&&void 0!==n?n:0}(r,e),l=function(){return i=c()};return s?a=setTimeout(l,Br(s)):l(),function(){clearTimeout(a),null==i||i.stop()}}))}function lo(e,t){-1===e.indexOf(t)&&e.push(t)}function uo(e,t){var n=e.indexOf(t);n>-1&&e.splice(n,1)}var po=function(){function e(){this.subscriptions=[]}return e.prototype.add=function(e){var t=this;return lo(this.subscriptions,e),function(){return uo(t.subscriptions,e)}},e.prototype.notify=function(e,t,n){var r=this.subscriptions.length;if(r)if(1===r)this.subscriptions[0](e,t,n);else for(var o=0;o<r;o++){var a=this.subscriptions[o];a&&a(e,t,n)}},e.prototype.getSize=function(){return this.subscriptions.length},e.prototype.clear=function(){this.subscriptions.length=0},e}(),mo=function(){function e(e){var t,n=this;this.timeDelta=0,this.lastUpdated=0,this.updateSubscribers=new po,this.velocityUpdateSubscribers=new po,this.renderSubscribers=new po,this.canTrackVelocity=!1,this.updateAndNotify=function(e,t){void 0===t&&(t=!0),n.prev=n.current,n.current=e;var r=Tr(),o=r.delta,a=r.timestamp;n.lastUpdated!==a&&(n.timeDelta=o,n.lastUpdated=a,kr.postRender(n.scheduleVelocityCheck)),n.prev!==n.current&&n.updateSubscribers.notify(n.current),n.velocityUpdateSubscribers.getSize()&&n.velocityUpdateSubscribers.notify(n.getVelocity()),t&&n.renderSubscribers.notify(n.current)},this.scheduleVelocityCheck=function(){return kr.postRender(n.velocityCheck)},this.velocityCheck=function(e){e.timestamp!==n.lastUpdated&&(n.prev=n.current,n.velocityUpdateSubscribers.notify(n.getVelocity()))},this.hasAnimated=!1,this.prev=this.current=e,this.canTrackVelocity=(t=this.current,!isNaN(parseFloat(t)))}return e.prototype.onChange=function(e){return this.updateSubscribers.add(e)},e.prototype.clearListeners=function(){this.updateSubscribers.clear()},e.prototype.onRenderRequest=function(e){return e(this.get()),this.renderSubscribers.add(e)},e.prototype.attach=function(e){this.passiveEffect=e},e.prototype.set=function(e,t){void 0===t&&(t=!0),t&&this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e,t)},e.prototype.get=function(){return this.current},e.prototype.getPrevious=function(){return this.prev},e.prototype.getVelocity=function(){return this.canTrackVelocity?Ir(parseFloat(this.current)-parseFloat(this.prev),this.timeDelta):0},e.prototype.start=function(e){var t=this;return this.stop(),new Promise((function(n){t.hasAnimated=!0,t.stopAnimation=e(n)})).then((function(){return t.clearAnimation()}))},e.prototype.stop=function(){this.stopAnimation&&this.stopAnimation(),this.clearAnimation()},e.prototype.isAnimating=function(){return!!this.stopAnimation},e.prototype.clearAnimation=function(){this.stopAnimation=null},e.prototype.destroy=function(){this.updateSubscribers.clear(),this.renderSubscribers.clear(),this.stop()},e}();function bo(e){return new mo(e)}var fo=function(e){return function(t){return t.test(e)}},vo=[Ze,We,qe,ze,Xe,Ye,{test:function(e){return"auto"===e},parse:function(e){return e}}],ho=function(e){return vo.find(fo(e))},go=H(H([],G(vo)),[In,Dn]),Oo=function(e){return go.find(fo(e))};function yo(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,bo(n))}function jo(e,t){var n=be(e,t),r=n?e.makeTargetAnimatable(n,!1):{},o=r.transitionEnd,a=void 0===o?{}:o;r.transition;var i,c=U(r,["transitionEnd","transition"]);for(var s in c=F(F({},c),a)){yo(e,s,(i=c[s],xt(i)?i[i.length-1]||0:i))}}function Eo(e,t){if(t)return(t[e]||t.default||t).from}function _o(e,t,n){var r;void 0===n&&(n={});var o=be(e,t,n.custom),a=(o||{}).transition,i=void 0===a?e.getDefaultTransition()||{}:a;n.transitionOverride&&(i=n.transitionOverride);var c=o?function(){return wo(e,o,n)}:function(){return Promise.resolve()},s=(null===(r=e.variantChildren)||void 0===r?void 0:r.size)?function(r){void 0===r&&(r=0);var o=i.delayChildren,a=void 0===o?0:o,c=i.staggerChildren,s=i.staggerDirection;return function(e,t,n,r,o,a){void 0===n&&(n=0);void 0===r&&(r=0);void 0===o&&(o=1);var i=[],c=(e.variantChildren.size-1)*r,s=1===o?function(e){return void 0===e&&(e=0),e*r}:function(e){return void 0===e&&(e=0),c-e*r};return Array.from(e.variantChildren).sort(So).forEach((function(e,r){i.push(_o(e,t,F(F({},a),{delay:n+s(r)})).then((function(){return e.notifyAnimationComplete(t)})))})),Promise.all(i)}(e,t,a+r,c,s,n)}:function(){return Promise.resolve()},l=i.when;if(l){var u=G("beforeChildren"===l?[c,s]:[s,c],2),d=u[0],p=u[1];return d().then(p)}return Promise.all([c(),s(n.delay)])}function wo(e,t,n){var r,o=void 0===n?{}:n,a=o.delay,i=void 0===a?0:a,c=o.transitionOverride,s=o.type,l=e.makeTargetAnimatable(t),u=l.transition,d=void 0===u?e.getDefaultTransition():u,p=l.transitionEnd,m=U(l,["transition","transitionEnd"]);c&&(d=c);var b=[],f=s&&(null===(r=e.animationState)||void 0===r?void 0:r.getState()[s]);for(var v in m){var h=e.getValue(v),g=m[v];if(!(!h||void 0===g||f&&xo(f,v))){var O=so(v,h,g,F({delay:i},d));b.push(O)}}return Promise.all(b).then((function(){p&&jo(e,p)}))}function So(e,t){return e.sortNodePosition(t)}function xo(e,t){var n=e.protectedKeys,r=e.needsAnimating,o=n.hasOwnProperty(t)&&!0!==r[t];return r[t]=!1,o}var Po=[Mt.Animate,Mt.Hover,Mt.Tap,Mt.Drag,Mt.Focus,Mt.Exit],To=H([],G(Po)).reverse(),ko=Po.length;function Co(e){return function(t){return Promise.all(t.map((function(t){var n=t.animation,r=t.options;return function(e,t,n){var r;if(void 0===n&&(n={}),e.notifyAnimationStart(),Array.isArray(t)){var o=t.map((function(t){return _o(e,t,n)}));r=Promise.all(o)}else if("string"==typeof t)r=_o(e,t,n);else{var a="function"==typeof t?be(e,t,n.custom):t;r=wo(e,a,n)}return r.then((function(){return e.notifyAnimationComplete(t)}))}(e,n,r)})))}}function Ao(e){var t,n=Co(e),r=((t={})[Mt.Animate]=Mo(!0),t[Mt.Hover]=Mo(),t[Mt.Tap]=Mo(),t[Mt.Drag]=Mo(),t[Mt.Focus]=Mo(),t[Mt.Exit]=Mo(),t),o={},a=!0,i=function(t,n){var r=be(e,n);if(r){r.transition;var o=r.transitionEnd,a=U(r,["transition","transitionEnd"]);t=F(F(F({},t),a),o)}return t};function c(t,c){for(var s,l=e.getProps(),u=e.getVariantContext(!0)||{},d=[],p=new Set,m={},b=1/0,f=function(n){var o=To[n],f=r[o],v=null!==(s=l[o])&&void 0!==s?s:u[o],h=pe(v),g=o===c?f.isActive:null;!1===g&&(b=n);var O=v===u[o]&&v!==l[o]&&h;if(O&&a&&e.manuallyAnimateOnMount&&(O=!1),f.protectedKeys=F({},m),!f.isActive&&null===g||!v&&!f.prevProp||St(v)||"boolean"==typeof v)return"continue";var y=function(e,t){if("string"==typeof t)return t!==e;if(de(t))return!sn(t,e);return!1}(f.prevProp,v)||o===c&&f.isActive&&!O&&h||n>b&&h,j=Array.isArray(v)?v:[v],E=j.reduce(i,{});!1===g&&(E={});var _=f.prevResolvedValues,w=void 0===_?{}:_,S=F(F({},w),E),x=function(e){y=!0,p.delete(e),f.needsAnimating[e]=!0};for(var P in S){var T=E[P],k=w[P];m.hasOwnProperty(P)||(T!==k?xt(T)&&xt(k)?sn(T,k)?f.protectedKeys[P]=!0:x(P):void 0!==T?x(P):p.add(P):void 0!==T&&p.has(P)?x(P):f.protectedKeys[P]=!0)}f.prevProp=v,f.prevResolvedValues=E,f.isActive&&(m=F(F({},m),E)),a&&e.blockInitialAnimation&&(y=!1),y&&!O&&d.push.apply(d,H([],G(j.map((function(e){return{animation:e,options:F({type:o},t)}})))))},v=0;v<ko;v++)f(v);if(o=F({},m),p.size){var h={};p.forEach((function(t){var n=e.getBaseTarget(t);void 0!==n&&(h[t]=n)})),d.push({animation:h})}var g=Boolean(d.length);return a&&!1===l.initial&&!e.manuallyAnimateOnMount&&(g=!1),a=!1,g?n(d):Promise.resolve()}return{isAnimated:function(e){return void 0!==o[e]},animateChanges:c,setActive:function(t,n,o){var a;return r[t].isActive===n?Promise.resolve():(null===(a=e.variantChildren)||void 0===a||a.forEach((function(e){var r;return null===(r=e.animationState)||void 0===r?void 0:r.setActive(t,n)})),r[t].isActive=n,c(o,t))},setAnimateFunction:function(t){n=t(e)},getState:function(){return r}}}function Mo(e){return void 0===e&&(e=!1),{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}var Io={animation:an((function(e){var t=e.visualElement,n=e.animate;t.animationState||(t.animationState=Ao(t)),St(n)&&Object(z.useEffect)((function(){return n.subscribe(t)}),[n])})),exit:an((function(e){var t=e.custom,n=e.visualElement,r=G(te(),2),o=r[0],a=r[1],i=Object(z.useContext)(J);Object(z.useEffect)((function(){var e,r,c=null===(e=n.animationState)||void 0===e?void 0:e.setActive(Mt.Exit,!o,{custom:null!==(r=null==i?void 0:i.custom)&&void 0!==r?r:t});!o&&(null==c||c.then(a))}),[o])}))},Bo=function(e){return e.hasOwnProperty("x")&&e.hasOwnProperty("y")},Lo=function(e){return Bo(e)&&e.hasOwnProperty("z")},No=function(e,t){return Math.abs(e-t)};function Ro(e,t){if(Vn(e)&&Vn(t))return No(e,t);if(Bo(e)&&Bo(t)){var n=No(e.x,t.x),r=No(e.y,t.y),o=Lo(e)&&Lo(t)?No(e.z,t.z):0;return Math.sqrt(Math.pow(n,2)+Math.pow(r,2)+Math.pow(o,2))}}var Do=function(){function e(e,t,n){var r=this,o=(void 0===n?{}:n).transformPagePoint;if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.updatePoint=function(){if(r.lastMoveEvent&&r.lastMoveEventInfo){var e=Uo(r.lastMoveEventInfo,r.history),t=null!==r.startEvent,n=Ro(e.offset,{x:0,y:0})>=3;if(t||n){var o=e.point,a=Tr().timestamp;r.history.push(F(F({},o),{timestamp:a}));var i=r.handlers,c=i.onStart,s=i.onMove;t||(c&&c(r.lastMoveEvent,e),r.startEvent=r.lastMoveEvent),s&&s(r.lastMoveEvent,e)}}},this.handlePointerMove=function(e,t){r.lastMoveEvent=e,r.lastMoveEventInfo=Vo(t,r.transformPagePoint),Rt(e)&&0===e.buttons?r.handlePointerUp(e,t):kr.update(r.updatePoint,!0)},this.handlePointerUp=function(e,t){r.end();var n=r.handlers,o=n.onEnd,a=n.onSessionEnd,i=Uo(Vo(t,r.transformPagePoint),r.history);r.startEvent&&o&&o(e,i),a&&a(e,i)},!(Dt(e)&&e.touches.length>1)){this.handlers=t,this.transformPagePoint=o;var a=Vo(Gt(e),this.transformPagePoint),i=a.point,c=Tr().timestamp;this.history=[F(F({},i),{timestamp:c})];var s=t.onSessionStart;s&&s(e,Uo(a,this.history)),this.removeListeners=on(Yt(window,"pointermove",this.handlePointerMove),Yt(window,"pointerup",this.handlePointerUp),Yt(window,"pointercancel",this.handlePointerUp))}}return e.prototype.updateHandlers=function(e){this.handlers=e},e.prototype.end=function(){this.removeListeners&&this.removeListeners(),_r.update(this.updatePoint)},e}();function Vo(e,t){return t?{point:t(e.point)}:e}function Fo(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Uo(e,t){var n=e.point;return{point:n,delta:Fo(n,Ho(t)),offset:Fo(n,Go(t)),velocity:zo(t,.1)}}function Go(e){return e[0]}function Ho(e){return e[e.length-1]}function zo(e,t){if(e.length<2)return{x:0,y:0};for(var n=e.length-1,r=null,o=Ho(e);n>=0&&(r=e[n],!(o.timestamp-r.timestamp>Br(t)));)n--;if(!r)return{x:0,y:0};var a=(o.timestamp-r.timestamp)/1e3;if(0===a)return{x:0,y:0};var i={x:(o.x-r.x)/a,y:(o.y-r.y)/a};return i.x===1/0&&(i.x=0),i.y===1/0&&(i.y=0),i}function qo(e){return e}function Wo(e){var t=e.top;return{x:{min:e.left,max:e.right},y:{min:t,max:e.bottom}}}var Yo={translate:0,scale:1,origin:0,originPoint:0};function Xo(){return{x:F({},Yo),y:F({},Yo)}}function Ko(e){return[e("x"),e("y")]}function Zo(e,t,n){var r=t.min,o=t.max;return void 0!==r&&e<r?e=n?yn(r,e,n.min):Math.max(e,r):void 0!==o&&e>o&&(e=n?yn(o,e,n.max):Math.min(e,o)),e}function Qo(e,t,n){return{min:void 0!==t?e.min+t:void 0,max:void 0!==n?e.max+n-(e.max-e.min):void 0}}function $o(e,t){var n,r=t.min-e.min,o=t.max-e.max;return t.max-t.min<e.max-e.min&&(r=(n=G([o,r],2))[0],o=n[1]),{min:e.min+r,max:e.min+o}}function Jo(e,t,n){return{min:ea(e,t),max:ea(e,n)}}function ea(e,t){var n;return"number"==typeof e?e:null!==(n=e[t])&&void 0!==n?n:0}function ta(e,t){return Wo(function(e,t){var n=e.top,r=e.left,o=e.bottom,a=e.right;void 0===t&&(t=qo);var i=t({x:r,y:n}),c=t({x:a,y:o});return{top:i.y,left:i.x,bottom:c.y,right:c.x}}(e.getBoundingClientRect(),t))}function na(e,t,n){return void 0===t&&(t=0),void 0===n&&(n=.01),Ro(e,t)<n}function ra(e){return e.max-e.min}function oa(e,t){var n=.5,r=ra(e),o=ra(t);return o>r?n=On(t.min,t.max-r,e.min):r>o&&(n=On(e.min,e.max-o,t.min)),dn(0,1,n)}function aa(e,t,n,r){void 0===r&&(r=.5),e.origin=r,e.originPoint=yn(t.min,t.max,e.origin),e.scale=ra(n)/ra(t),na(e.scale,1,1e-4)&&(e.scale=1),e.translate=yn(n.min,n.max,e.origin)-e.originPoint,na(e.translate)&&(e.translate=0)}function ia(e,t,n,r){aa(e.x,t.x,n.x,ca(r.originX)),aa(e.y,t.y,n.y,ca(r.originY))}function ca(e){return"number"==typeof e?e:.5}function sa(e,t,n){e.min=n.min+t.min,e.max=e.min+ra(t)}var la=function(e,t){return e.depth-t.depth};function ua(e){return e.projection.isEnabled||e.shouldResetTransform()}function da(e,t){void 0===t&&(t=[]);var n=e.parent;return n&&da(n,t),ua(e)&&t.push(e),t}function pa(e){if(!e.shouldResetTransform()){var t,n=e.getLayoutState();e.notifyBeforeLayoutMeasure(n.layout),n.isHydrated=!0,n.layout=e.measureViewportBox(),n.layoutCorrected=(t=n.layout,{x:F({},t.x),y:F({},t.y)}),e.notifyLayoutMeasure(n.layout,e.prevViewportBox||n.layout),kr.update((function(){return e.rebaseProjectionTarget()}))}}function ma(e,t){return{min:t.min-e.min,max:t.max-e.min}}function ba(e,t){return{x:ma(e.x,t.x),y:ma(e.y,t.y)}}function fa(e,t){var n=e.getLayoutId(),r=t.getLayoutId();return n!==r||void 0===r&&e!==t}function va(e){var t=e.getProps(),n=t.drag,r=t._dragX;return n&&!r}function ha(e,t){e.min=t.min,e.max=t.max}function ga(e,t,n){return n+t*(e-n)}function Oa(e,t,n,r,o){return void 0!==o&&(e=ga(e,o,r)),ga(e,n,r)+t}function ya(e,t,n,r,o){void 0===t&&(t=0),void 0===n&&(n=1),e.min=Oa(e.min,t,n,r,o),e.max=Oa(e.max,t,n,r,o)}function ja(e,t){var n=t.x,r=t.y;ya(e.x,n.translate,n.scale,n.originPoint),ya(e.y,r.translate,r.scale,r.originPoint)}function Ea(e,t,n,r){var o=G(r,3),a=o[0],i=o[1],c=o[2];e.min=t.min,e.max=t.max;var s=void 0!==n[c]?n[c]:.5,l=yn(t.min,t.max,s);ya(e,n[a],n[i],l,n.scale)}var _a=["x","scaleX","originX"],wa=["y","scaleY","originY"];function Sa(e,t,n){Ea(e.x,t.x,n,_a),Ea(e.y,t.y,n,wa)}function xa(e,t,n,r,o){return e=ga(e-=t,1/n,r),void 0!==o&&(e=ga(e,1/o,r)),e}function Pa(e,t,n){var r=G(n,3),o=r[0],a=r[1],i=r[2];!function(e,t,n,r,o){void 0===t&&(t=0),void 0===n&&(n=1),void 0===r&&(r=.5);var a=yn(e.min,e.max,r)-t;e.min=xa(e.min,t,n,a,o),e.max=xa(e.max,t,n,a,o)}(e,t[o],t[a],t[i],t.scale)}function Ta(e,t){Pa(e.x,t,_a),Pa(e.y,t,wa)}var ka=new Set;function Ca(e,t,n){e[n]||(e[n]=[]),e[n].push(t)}function Aa(e){return ka.add(e),function(){return ka.delete(e)}}function Ma(){if(ka.size){var e=0,t=[[]],n=[],r=function(n){return Ca(t,n,e)},o=function(t){Ca(n,t,e),e++};ka.forEach((function(t){t(r,o),e=0})),ka.clear();for(var a=n.length,i=0;i<=a;i++)t[i]&&t[i].forEach(Ba),n[i]&&n[i].forEach(Ba)}}var Ia,Ba=function(e){return e()},La=new WeakMap,Na=function(){function e(e){var t=e.visualElement;this.isDragging=!1,this.currentDirection=null,this.constraints=!1,this.elastic={x:{min:0,max:1},y:{min:0,max:1}},this.props={},this.hasMutatedConstraints=!1,this.cursorProgress={x:.5,y:.5},this.originPoint={},this.openGlobalLock=null,this.panSession=null,this.visualElement=t,this.visualElement.enableLayoutProjection(),La.set(t,this)}return e.prototype.start=function(e,t){var n=this,r=void 0===t?{}:t,o=r.snapToCursor,a=void 0!==o&&o,i=r.cursorProgress,c=this.props.transformPagePoint;this.panSession=new Do(e,{onSessionStart:function(e){var t;n.stopMotion();var r=function(e){return Gt(e,"client")}(e).point;null===(t=n.cancelLayout)||void 0===t||t.call(n),n.cancelLayout=Aa((function(e,t){var o=da(n.visualElement),c=function(e){var t=[],n=function(e){ua(e)&&t.push(e),e.children.forEach(n)};return e.children.forEach(n),t.sort(la)}(n.visualElement),s=H(H([],G(o)),G(c)),l=!1;n.isLayoutDrag()&&n.visualElement.lockProjectionTarget(),t((function(){s.forEach((function(e){return e.resetTransform()}))})),e((function(){pa(n.visualElement),c.forEach(pa)})),t((function(){s.forEach((function(e){return e.restoreTransform()})),a&&(l=n.snapToCursor(r))})),e((function(){Boolean(n.getAxisMotionValue("x")&&!n.isExternalDrag())||n.visualElement.rebaseProjectionTarget(!0,n.visualElement.measureViewportBox(!1)),n.visualElement.scheduleUpdateLayoutProjection();var e=n.visualElement.projection;Ko((function(t){if(!l){var o=e.target[t],a=o.min,c=o.max;n.cursorProgress[t]=i?i[t]:On(a,c,r[t])}var s=n.getAxisMotionValue(t);s&&(n.originPoint[t]=s.get())}))})),t((function(){wr.update(),wr.preRender(),wr.render(),wr.postRender()})),e((function(){return n.resolveDragConstraints()}))}))},onStart:function(e,t){var r,o,a,i=n.props,c=i.drag,s=i.dragPropagation;(!c||s||(n.openGlobalLock&&n.openGlobalLock(),n.openGlobalLock=$t(c),n.openGlobalLock))&&(Ma(),n.isDragging=!0,n.currentDirection=null,null===(o=(r=n.props).onDragStart)||void 0===o||o.call(r,e,t),null===(a=n.visualElement.animationState)||void 0===a||a.setActive(Mt.Drag,!0))},onMove:function(e,t){var r,o,a,i,c=n.props,s=c.dragPropagation,l=c.dragDirectionLock;if(s||n.openGlobalLock){var u=t.offset;if(l&&null===n.currentDirection)return n.currentDirection=function(e,t){void 0===t&&(t=10);var n=null;Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x");return n}(u),void(null!==n.currentDirection&&(null===(o=(r=n.props).onDirectionLock)||void 0===o||o.call(r,n.currentDirection)));n.updateAxis("x",t.point,u),n.updateAxis("y",t.point,u),null===(i=(a=n.props).onDrag)||void 0===i||i.call(a,e,t),Ia=e}},onSessionEnd:function(e,t){return n.stop(e,t)}},{transformPagePoint:c})},e.prototype.resolveDragConstraints=function(){var e=this,t=this.props,n=t.dragConstraints,r=t.dragElastic,o=this.visualElement.getLayoutState().layoutCorrected;this.constraints=!!n&&(ue(n)?this.resolveRefConstraints(o,n):function(e,t){var n=t.top,r=t.left,o=t.bottom,a=t.right;return{x:Qo(e.x,r,a),y:Qo(e.y,n,o)}}(o,n)),this.elastic=function(e){return!1===e?e=0:!0===e&&(e=.35),{x:Jo(e,"left","right"),y:Jo(e,"top","bottom")}}(r),this.constraints&&!this.hasMutatedConstraints&&Ko((function(t){e.getAxisMotionValue(t)&&(e.constraints[t]=function(e,t){var n={};return void 0!==t.min&&(n.min=t.min-e.min),void 0!==t.max&&(n.max=t.max-e.min),n}(o[t],e.constraints[t]))}))},e.prototype.resolveRefConstraints=function(e,t){var n=this.props,r=n.onMeasureDragConstraints,o=n.transformPagePoint,a=t.current;this.constraintsBox=ta(a,o);var i=function(e,t){return{x:$o(e.x,t.x),y:$o(e.y,t.y)}}(e,this.constraintsBox);if(r){var c=r(function(e){var t=e.x,n=e.y;return{top:n.min,bottom:n.max,left:t.min,right:t.max}}(i));this.hasMutatedConstraints=!!c,c&&(i=Wo(c))}return i},e.prototype.cancelDrag=function(){var e,t;this.visualElement.unlockProjectionTarget(),null===(e=this.cancelLayout)||void 0===e||e.call(this),this.isDragging=!1,this.panSession&&this.panSession.end(),this.panSession=null,!this.props.dragPropagation&&this.openGlobalLock&&(this.openGlobalLock(),this.openGlobalLock=null),null===(t=this.visualElement.animationState)||void 0===t||t.setActive(Mt.Drag,!1)},e.prototype.stop=function(e,t){var n,r,o;null===(n=this.panSession)||void 0===n||n.end(),this.panSession=null;var a=this.isDragging;if(this.cancelDrag(),a){var i=t.velocity;this.animateDragEnd(i),null===(o=(r=this.props).onDragEnd)||void 0===o||o.call(r,e,t)}},e.prototype.snapToCursor=function(e){var t=this;return Ko((function(n){if(Ra(n,t.props.drag,t.currentDirection)){var r=t.getAxisMotionValue(n);if(!r)return t.cursorProgress[n]=.5,!0;var o=t.visualElement.getLayoutState().layout,a=o[n].max-o[n].min,i=o[n].min+a/2,c=e[n]-i;t.originPoint[n]=e[n],r.set(c)}})).includes(!0)},e.prototype.updateAxis=function(e,t,n){if(Ra(e,this.props.drag,this.currentDirection))return this.getAxisMotionValue(e)?this.updateAxisMotionValue(e,n):this.updateVisualElementAxis(e,t)},e.prototype.updateAxisMotionValue=function(e,t){var n=this.getAxisMotionValue(e);if(t&&n){var r=this.originPoint[e]+t[e],o=this.constraints?Zo(r,this.constraints[e],this.elastic[e]):r;n.set(o)}},e.prototype.updateVisualElementAxis=function(e,t){var n,r=this.visualElement.getLayoutState().layout[e],o=r.max-r.min,a=this.cursorProgress[e],i=function(e,t,n,r,o){var a=e-t*n;return r?Zo(a,r,o):a}(t[e],o,a,null===(n=this.constraints)||void 0===n?void 0:n[e],this.elastic[e]);this.visualElement.setProjectionTargetAxis(e,i,i+o)},e.prototype.setProps=function(e){var t=e.drag,n=void 0!==t&&t,r=e.dragDirectionLock,o=void 0!==r&&r,a=e.dragPropagation,i=void 0!==a&&a,c=e.dragConstraints,s=void 0!==c&&c,l=e.dragElastic,u=void 0===l?.35:l,d=e.dragMomentum,p=void 0===d||d,m=U(e,["drag","dragDirectionLock","dragPropagation","dragConstraints","dragElastic","dragMomentum"]);this.props=F({drag:n,dragDirectionLock:o,dragPropagation:i,dragConstraints:s,dragElastic:u,dragMomentum:p},m)},e.prototype.getAxisMotionValue=function(e){var t=this.props,n=t.layout,r=t.layoutId,o="_drag"+e.toUpperCase();return this.props[o]?this.props[o]:n||void 0!==r?void 0:this.visualElement.getValue(e,0)},e.prototype.isLayoutDrag=function(){return!this.getAxisMotionValue("x")},e.prototype.isExternalDrag=function(){var e=this.props,t=e._dragX,n=e._dragY;return t||n},e.prototype.animateDragEnd=function(e){var t=this,n=this.props,r=n.drag,o=n.dragMomentum,a=n.dragElastic,i=n.dragTransition,c=function(e,t){void 0===t&&(t=!0);var n,r=e.getProjectionParent();return!!r&&(t?Ta(n=ba(r.projection.target,e.projection.target),r.getLatestValues()):n=ba(r.getLayoutState().layout,e.getLayoutState().layout),Ko((function(t){return e.setProjectionTargetAxis(t,n[t].min,n[t].max,!0)})),!0)}(this.visualElement,this.isLayoutDrag()&&!this.isExternalDrag()),s=this.constraints||{};if(c&&Object.keys(s).length&&this.isLayoutDrag()){var l=this.visualElement.getProjectionParent();if(l){var u=ba(l.projection.targetFinal,s);Ko((function(e){var t=u[e],n=t.min,r=t.max;s[e]={min:isNaN(n)?void 0:n,max:isNaN(r)?void 0:r}}))}}var d=Ko((function(n){var l;if(Ra(n,r,t.currentDirection)){var u=null!==(l=null==s?void 0:s[n])&&void 0!==l?l:{},d=a?200:1e6,p=a?40:1e7,m=F(F({type:"inertia",velocity:o?e[n]:0,bounceStiffness:d,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10},i),u);return t.getAxisMotionValue(n)?t.startAxisValueAnimation(n,m):t.visualElement.startLayoutAnimation(n,m,c)}}));return Promise.all(d).then((function(){var e,n;null===(n=(e=t.props).onDragTransitionEnd)||void 0===n||n.call(e)}))},e.prototype.stopMotion=function(){var e=this;Ko((function(t){var n=e.getAxisMotionValue(t);n?n.stop():e.visualElement.stopLayoutAnimation()}))},e.prototype.startAxisValueAnimation=function(e,t){var n=this.getAxisMotionValue(e);if(n){var r=n.get();return n.set(r),n.set(r),so(e,n,0,t)}},e.prototype.scalePoint=function(){var e=this,t=this.props,n=t.drag;if(ue(t.dragConstraints)&&this.constraintsBox){this.stopMotion();var r={x:0,y:0};Ko((function(t){r[t]=oa(e.visualElement.projection.target[t],e.constraintsBox[t])})),this.updateConstraints((function(){Ko((function(t){if(Ra(t,n,null)){var o=function(e,t,n){var r=e.max-e.min,o=yn(t.min,t.max-r,n);return{min:o,max:o+r}}(e.visualElement.projection.target[t],e.constraintsBox[t],r[t]),a=o.min,i=o.max;e.visualElement.setProjectionTargetAxis(t,a,i)}}))})),setTimeout(Ma,1)}},e.prototype.updateConstraints=function(e){var t=this;this.cancelLayout=Aa((function(n,r){var o=da(t.visualElement);r((function(){return o.forEach((function(e){return e.resetTransform()}))})),n((function(){return pa(t.visualElement)})),r((function(){return o.forEach((function(e){return e.restoreTransform()}))})),n((function(){t.resolveDragConstraints()})),e&&r(e)}))},e.prototype.mount=function(e){var t=this,n=Yt(e.getInstance(),"pointerdown",(function(e){var n=t.props,r=n.drag,o=n.dragListener;r&&(void 0===o||o)&&t.start(e)})),r=Lt(window,"resize",(function(){t.scalePoint()})),o=e.onLayoutUpdate((function(){t.isDragging&&t.resolveDragConstraints()})),a=e.prevDragCursor;return a&&this.start(Ia,{cursorProgress:a}),function(){null==n||n(),null==r||r(),null==o||o(),t.cancelDrag()}},e}();function Ra(e,t,n){return!(!0!==t&&t!==e||null!==n&&n!==e)}var Da,Va,Fa={pan:an((function(e){var t=e.onPan,n=e.onPanStart,r=e.onPanEnd,o=e.onPanSessionStart,a=e.visualElement,i=t||n||r||o,c=Object(z.useRef)(null),s=Object(z.useContext)(Q).transformPagePoint,l={onSessionStart:o,onStart:n,onMove:t,onEnd:function(e,t){c.current=null,r&&r(e,t)}};Object(z.useEffect)((function(){null!==c.current&&c.current.updateHandlers(l)})),Xt(a,"pointerdown",i&&function(e){c.current=new Do(e,l,{transformPagePoint:s})}),nn((function(){return c.current&&c.current.end()}))})),drag:an((function(e){var t=e.dragControls,n=e.visualElement,r=Object(z.useContext)(Q).transformPagePoint,o=ee((function(){return new Na({visualElement:n})}));o.setProps(F(F({},e),{transformPagePoint:r})),Object(z.useEffect)((function(){return t&&t.subscribe(o)}),[o]),Object(z.useEffect)((function(){return o.mount(n)}),[])}))};function Ua(e){return"string"==typeof e&&e.startsWith("var(--")}!function(e){e[e.Entering=0]="Entering",e[e.Present=1]="Present",e[e.Exiting=2]="Exiting"}(Da||(Da={})),function(e){e[e.Hide=0]="Hide",e[e.Show=1]="Show"}(Va||(Va={}));var Ga=/var\((--[a-zA-Z0-9-_]+),? ?([a-zA-Z0-9 ()%#.,-]+)?\)/;function Ha(e,t,n){void 0===n&&(n=1);var r=G(function(e){var t=Ga.exec(e);if(!t)return[,];var n=G(t,3);return[n[1],n[2]]}(e),2),o=r[0],a=r[1];if(o){var i=window.getComputedStyle(t).getPropertyValue(o);return i?i.trim():Ua(a)?Ha(a,t,n+1):a}}function za(e,t){return e/(t.max-t.min)*100}var qa={process:function(e,t,n){var r=n.target;if("string"==typeof e){if(!We.test(e))return e;e=parseFloat(e)}return za(e,r.x)+"% "+za(e,r.y)+"%"}},Wa={borderRadius:F(F({},qa),{applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]}),borderTopLeftRadius:qa,borderTopRightRadius:qa,borderBottomLeftRadius:qa,borderBottomRightRadius:qa,boxShadow:{process:function(e,t){var n=t.delta,r=t.treeScale,o=e,a=e.includes("var("),i=[];a&&(e=e.replace(Ga,(function(e){return i.push(e),"_$css"})));var c=Dn.parse(e);if(c.length>5)return o;var s=Dn.createTransformer(e),l="number"!=typeof c[0]?1:0,u=n.x.scale*r.x,d=n.y.scale*r.y;c[0+l]/=u,c[1+l]/=d;var p=yn(u,d,.5);"number"==typeof c[2+l]&&(c[2+l]/=p),"number"==typeof c[3+l]&&(c[3+l]/=p);var m=s(c);if(a){var b=0;m=m.replace("_$css",(function(){var e=i[b];return b++,e}))}return m}}},Ya=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.frameTarget={x:{min:0,max:1},y:{min:0,max:1}},t.currentAnimationTarget={x:{min:0,max:1},y:{min:0,max:1}},t.isAnimating={x:!1,y:!1},t.stopAxisAnimation={x:void 0,y:void 0},t.isAnimatingTree=!1,t.animate=function(e,n,r){void 0===r&&(r={});var o=r.originBox,a=r.targetBox,i=r.visibilityAction,c=r.shouldStackAnimate,s=r.onComplete,l=r.prevParent,u=U(r,["originBox","targetBox","visibilityAction","shouldStackAnimate","onComplete","prevParent"]),d=t.props,p=d.visualElement,m=d.layout;if(!1===c)return t.isAnimatingTree=!1,t.safeToRemove();if(!t.isAnimatingTree||!0===c){c&&(t.isAnimatingTree=!0),n=o||n,e=a||e;var b=!1,f=p.getProjectionParent();if(f){var v=f.prevViewportBox,h=f.getLayoutState().layout;l&&(a&&(h=l.getLayoutState().layout),o&&!fa(l,f)&&l.prevViewportBox&&(v=l.prevViewportBox)),v&&Ja(l,o,a)&&(b=!0,n=ba(v,n),e=ba(h,e))}var g=Xa(n,e),O=Ko((function(r){var o,a;if("position"===m){var c=e[r].max-e[r].min;n[r].max=n[r].min+c}if(!p.projection.isTargetLocked)return void 0===i?g?t.animateAxis(r,e[r],n[r],F(F({},u),{isRelative:b})):(null===(a=(o=t.stopAxisAnimation)[r])||void 0===a||a.call(o),p.setProjectionTargetAxis(r,e[r].min,e[r].max,b)):void p.setVisibility(i===Va.Show)}));return p.syncRender(),Promise.all(O).then((function(){t.isAnimatingTree=!1,s&&s(),p.notifyLayoutAnimationComplete()}))}},t}return V(t,e),t.prototype.componentDidMount=function(){var e=this,t=this.props.visualElement;t.animateMotionValue=so,t.enableLayoutProjection(),this.unsubLayoutReady=t.onLayoutUpdate(this.animate),t.layoutSafeToRemove=function(){return e.safeToRemove()},function(e){for(var t in e)_e[t]=e[t]}(Wa)},t.prototype.componentWillUnmount=function(){var e=this;this.unsubLayoutReady(),Ko((function(t){var n,r;return null===(r=(n=e.stopAxisAnimation)[t])||void 0===r?void 0:r.call(n)}))},t.prototype.animateAxis=function(e,t,n,r){var o,a,i=this,c=void 0===r?{}:r,s=c.transition,l=c.isRelative;if(!this.isAnimating[e]||!Qa(t,this.currentAnimationTarget[e])){null===(a=(o=this.stopAxisAnimation)[e])||void 0===a||a.call(o),this.isAnimating[e]=!0;var u=this.props.visualElement,d=this.frameTarget[e],p=u.getProjectionAnimationProgress()[e];p.clearListeners(),p.set(0),p.set(0);var m=function(){var r=p.get()/1e3;!function(e,t,n,r){e.min=yn(t.min,n.min,r),e.max=yn(t.max,n.max,r)}(d,n,t,r),u.setProjectionTargetAxis(e,d.min,d.max,l)};m();var b=p.onChange(m);this.stopAxisAnimation[e]=function(){i.isAnimating[e]=!1,p.stop(),b()},this.currentAnimationTarget[e]=t;var f=s||u.getDefaultTransition()||$a;return so("x"===e?"layoutX":"layoutY",p,1e3,f&&co(f,"layout")).then(this.stopAxisAnimation[e])}},t.prototype.safeToRemove=function(){var e,t;null===(t=(e=this.props).safeToRemove)||void 0===t||t.call(e)},t.prototype.render=function(){return null},t}(z.Component);function Xa(e,t){return!(Za(e)||Za(t)||Qa(e.x,t.x)&&Qa(e.y,t.y))}var Ka={min:0,max:0};function Za(e){return Qa(e.x,Ka)&&Qa(e.y,Ka)}function Qa(e,t){return e.min===t.min&&e.max===t.max}var $a={duration:.45,ease:[.4,0,.1,1]};function Ja(e,t,n){return e||!e&&!(t||n)}var ei={layoutReady:function(e){return e.notifyLayoutReady()}};function ti(){var e=new Set;return{add:function(t){return e.add(t)},flush:function(t){var n=void 0===t?ei:t,r=n.layoutReady,o=n.parent;Aa((function(t,n){var a=Array.from(e).sort(la),i=o?da(o):[];n((function(){H(H([],G(i)),G(a)).forEach((function(e){return e.resetTransform()}))})),t((function(){a.forEach(pa)})),n((function(){i.forEach((function(e){return e.restoreTransform()})),a.forEach(r)})),t((function(){a.forEach((function(e){e.isPresent&&(e.presence=Da.Present)}))})),n((function(){wr.preRender(),wr.render()})),t((function(){kr.postRender((function(){return a.forEach(ni)})),e.clear()}))})),Ma()}}}function ni(e){e.prevViewportBox=e.projection.target}var ri=Object(z.createContext)(ti()),oi=Object(z.createContext)(ti());function ai(e){return!!e.forceUpdate}var ii=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return V(t,e),t.prototype.componentDidMount=function(){var e=this.props,t=e.syncLayout,n=e.framerSyncLayout,r=e.visualElement;ai(t)&&t.register(r),ai(n)&&n.register(r),r.onUnmount((function(){ai(t)&&t.remove(r),ai(n)&&n.remove(r)}))},t.prototype.getSnapshotBeforeUpdate=function(){var e=this.props,t=e.syncLayout,n=e.visualElement;return ai(t)?t.syncUpdate():(!function(e){e.shouldResetTransform()||(e.prevViewportBox=e.measureViewportBox(!1),e.rebaseProjectionTarget(!1,e.prevViewportBox))}(n),t.add(n)),null},t.prototype.componentDidUpdate=function(){var e=this.props.syncLayout;ai(e)||e.flush()},t.prototype.render=function(){return null},t}(q.a.Component);var ci={measureLayout:function(e){var t=Object(z.useContext)(ri),n=Object(z.useContext)(oi);return q.a.createElement(ii,F({},e,{syncLayout:t,framerSyncLayout:n}))},layoutAnimation:function(e){var t=G(te(),2)[1];return z.createElement(Ya,F({},e,{safeToRemove:t}))}};function si(){return{isHydrated:!1,layout:{x:{min:0,max:1},y:{min:0,max:1}},layoutCorrected:{x:{min:0,max:1},y:{min:0,max:1}},treeScale:{x:1,y:1},delta:Xo(),deltaFinal:Xo(),deltaTransform:""}}var li=si();function ui(e,t,n){var r=e.x,o=e.y,a="translate3d("+r.translate/t.x+"px, "+o.translate/t.y+"px, 0) ";if(n){var i=n.rotate,c=n.rotateX,s=n.rotateY;i&&(a+="rotate("+i+") "),c&&(a+="rotateX("+c+") "),s&&(a+="rotateY("+s+") ")}return a+="scale("+r.scale+", "+o.scale+")",n||a!==pi?a:""}function di(e){var t=e.deltaFinal;return 100*t.x.origin+"% "+100*t.y.origin+"% 0"}var pi=ui(li.delta,li.treeScale,{x:1,y:1}),mi=["LayoutMeasure","BeforeLayoutMeasure","LayoutUpdate","ViewportBoxUpdate","Update","Render","AnimationComplete","LayoutAnimationComplete","AnimationStart","SetAxisTarget","Unmount"];function bi(e,t,n,r){var o,a,i=e.delta,c=e.layout,s=e.layoutCorrected,l=e.treeScale,u=t.target;a=c,ha((o=s).x,a.x),ha(o.y,a.y),function(e,t,n){var r=n.length;if(r){var o,a;t.x=t.y=1;for(var i=0;i<r;i++)a=(o=n[i]).getLayoutState().delta,t.x*=a.x.scale,t.y*=a.y.scale,ja(e,a),va(o)&&Sa(e,e,o.getLatestValues())}}(s,l,n),ia(i,s,u,r)}var fi=function(){function e(){this.children=[],this.isDirty=!1}return e.prototype.add=function(e){lo(this.children,e),this.isDirty=!0},e.prototype.remove=function(e){uo(this.children,e),this.isDirty=!0},e.prototype.forEach=function(e){this.isDirty&&this.children.sort(la),this.isDirty=!1,this.children.forEach(e)},e}();var vi=function(e){var t=e.treeType,n=void 0===t?"":t,r=e.build,o=e.getBaseTarget,a=e.makeTargetAnimatable,i=e.measureViewportBox,c=e.render,s=e.readValueFromInstance,l=e.resetTransform,u=e.restoreTransform,d=e.removeValueFromRenderState,p=e.sortNodePosition,m=e.scrapeMotionValuesFromProps;return function(e,t){var b=e.parent,f=e.props,v=e.presenceId,h=e.blockInitialAnimation,g=e.visualState;void 0===t&&(t={});var O,y,j,E,_,w,S=g.latestValues,x=g.renderState,P=function(){var e=mi.map((function(){return new po})),t={},n={clearAllListeners:function(){return e.forEach((function(e){return e.clear()}))},updatePropListeners:function(e){return mi.forEach((function(r){var o;null===(o=t[r])||void 0===o||o.call(t);var a="on"+r,i=e[a];i&&(t[r]=n[a](i))}))}};return e.forEach((function(e,t){n["on"+mi[t]]=function(t){return e.add(t)},n["notify"+mi[t]]=function(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];return e.notify.apply(e,H([],G(t)))}})),n}(),T={isEnabled:!1,isHydrated:!1,isTargetLocked:!1,target:{x:{min:0,max:1},y:{min:0,max:1}},targetFinal:{x:{min:0,max:1},y:{min:0,max:1}}},k=T,C=S,A=si(),M=!1,I=new Map,B=new Map,L={},N=F({},S);function R(){O&&(K.isProjectionReady()&&(Sa(k.targetFinal,k.target,C),ia(A.deltaFinal,A.layoutCorrected,k.targetFinal,S)),D(),c(O,x))}function D(){var e=S;if(E&&E.isActive()){var n=E.getCrossfadeState(K);n&&(e=n)}r(K,x,e,k,A,t,f)}function V(){P.notifyUpdate(S)}function U(){K.layoutTree.forEach(gi)}var z=m(f);for(var q in z){var W=z[q];void 0!==S[q]&&Me(W)&&W.set(S[q],!1)}var Y=fe(f),X=ve(f),K=F(F({treeType:n,current:null,depth:b?b.depth+1:0,parent:b,children:new Set,path:b?H(H([],G(b.path)),[b]):[],layoutTree:b?b.layoutTree:new fi,presenceId:v,projection:T,variantChildren:X?new Set:void 0,isVisible:void 0,manuallyAnimateOnMount:Boolean(null==b?void 0:b.isMounted()),blockInitialAnimation:h,isMounted:function(){return Boolean(O)},mount:function(e){O=K.current=e,K.pointTo(K),X&&b&&!Y&&(w=null==b?void 0:b.addVariantChild(K)),null==b||b.children.add(K)},unmount:function(){_r.update(V),_r.render(R),_r.preRender(K.updateLayoutProjection),B.forEach((function(e){return e()})),K.stopLayoutAnimation(),K.layoutTree.remove(K),null==w||w(),null==b||b.children.delete(K),null==j||j(),P.clearAllListeners()},addVariantChild:function(e){var t,n=K.getClosestVariantNode();if(n)return null===(t=n.variantChildren)||void 0===t||t.add(e),function(){return n.variantChildren.delete(e)}},sortNodePosition:function(e){return p&&n===e.treeType?p(K.getInstance(),e.getInstance()):0},getClosestVariantNode:function(){return X?K:null==b?void 0:b.getClosestVariantNode()},scheduleUpdateLayoutProjection:b?b.scheduleUpdateLayoutProjection:function(){return kr.preRender(K.updateTreeLayoutProjection,!1,!0)},getLayoutId:function(){return f.layoutId},getInstance:function(){return O},getStaticValue:function(e){return S[e]},setStaticValue:function(e,t){return S[e]=t},getLatestValues:function(){return S},setVisibility:function(e){K.isVisible!==e&&(K.isVisible=e,K.scheduleRender())},makeTargetAnimatable:function(e,t){return void 0===t&&(t=!0),a(K,e,f,t)},addValue:function(e,t){K.hasValue(e)&&K.removeValue(e),I.set(e,t),S[e]=t.get(),function(e,t){var n=t.onChange((function(t){S[e]=t,f.onUpdate&&kr.update(V,!1,!0)})),r=t.onRenderRequest(K.scheduleRender);B.set(e,(function(){n(),r()}))}(e,t)},removeValue:function(e){var t;I.delete(e),null===(t=B.get(e))||void 0===t||t(),B.delete(e),delete S[e],d(e,x)},hasValue:function(e){return I.has(e)},getValue:function(e,t){var n=I.get(e);return void 0===n&&void 0!==t&&(n=bo(t),K.addValue(e,n)),n},forEachValue:function(e){return I.forEach(e)},readValue:function(e){var n;return null!==(n=S[e])&&void 0!==n?n:s(O,e,t)},setBaseTarget:function(e,t){N[e]=t},getBaseTarget:function(e){if(o){var t=o(f,e);if(void 0!==t&&!Me(t))return t}return N[e]}},P),{build:function(){return D(),x},scheduleRender:function(){kr.render(R,!1,!0)},syncRender:R,setProps:function(e){f=e,P.updatePropListeners(e),L=function(e,t,n){var r;for(var o in t){var a=t[o],i=n[o];if(Me(a))e.addValue(o,a);else if(Me(i))e.addValue(o,bo(a));else if(i!==a)if(e.hasValue(o)){var c=e.getValue(o);!c.hasAnimated&&c.set(a)}else e.addValue(o,bo(null!==(r=e.getStaticValue(o))&&void 0!==r?r:a))}for(var o in n)void 0===t[o]&&e.removeValue(o);return t}(K,m(f),L)},getProps:function(){return f},getVariant:function(e){var t;return null===(t=f.variants)||void 0===t?void 0:t[e]},getDefaultTransition:function(){return f.transition},getVariantContext:function(e){if(void 0===e&&(e=!1),e)return null==b?void 0:b.getVariantContext();if(!Y){var t=(null==b?void 0:b.getVariantContext())||{};return void 0!==f.initial&&(t.initial=f.initial),t}for(var n={},r=0;r<ji;r++){var o=yi[r],a=f[o];(pe(a)||!1===a)&&(n[o]=a)}return n},enableLayoutProjection:function(){T.isEnabled=!0,K.layoutTree.add(K)},lockProjectionTarget:function(){T.isTargetLocked=!0},unlockProjectionTarget:function(){K.stopLayoutAnimation(),T.isTargetLocked=!1},getLayoutState:function(){return A},setCrossfader:function(e){E=e},isProjectionReady:function(){return T.isEnabled&&T.isHydrated&&A.isHydrated},startLayoutAnimation:function(e,t,n){void 0===n&&(n=!1);var r=K.getProjectionAnimationProgress()[e],o=n?T.relativeTarget[e]:T.target[e],a=o.min,i=o.max-a;return r.clearListeners(),r.set(a),r.set(a),r.onChange((function(t){K.setProjectionTargetAxis(e,t,t+i,n)})),K.animateMotionValue(e,r,0,t)},stopLayoutAnimation:function(){Ko((function(e){return K.getProjectionAnimationProgress()[e].stop()}))},measureViewportBox:function(e){void 0===e&&(e=!0);var n=i(O,t);return e||Ta(n,S),n},getProjectionAnimationProgress:function(){return _||(_={x:bo(0),y:bo(0)}),_},setProjectionTargetAxis:function(e,t,n,r){var o;void 0===r&&(r=!1),r?(T.relativeTarget||(T.relativeTarget={x:{min:0,max:1},y:{min:0,max:1}}),o=T.relativeTarget[e]):(T.relativeTarget=void 0,o=T.target[e]),T.isHydrated=!0,o.min=t,o.max=n,M=!0,P.notifySetAxisTarget()},rebaseProjectionTarget:function(e,t){void 0===t&&(t=A.layout);var n=K.getProjectionAnimationProgress(),r=n.x,o=n.y,a=!(T.relativeTarget||T.isTargetLocked||r.isAnimating()||o.isAnimating());(e||a)&&Ko((function(e){var n=t[e],r=n.min,o=n.max;K.setProjectionTargetAxis(e,r,o)}))},notifyLayoutReady:function(e){!function(e){var t=e.getProjectionParent();if(t){var n=ba(t.getLayoutState().layout,e.getLayoutState().layout);Ko((function(t){e.setProjectionTargetAxis(t,n[t].min,n[t].max,!0)}))}else e.rebaseProjectionTarget()}(K),K.notifyLayoutUpdate(A.layout,K.prevViewportBox||A.layout,e)},resetTransform:function(){return l(K,O,f)},restoreTransform:function(){return u(O,x)},updateLayoutProjection:function(){if(K.isProjectionReady()){var e=A.delta,t=A.treeScale,n=t.x,r=t.y,o=A.deltaTransform;bi(A,k,K.path,S),M&&K.notifyViewportBoxUpdate(k.target,e),M=!1;var a=ui(e,t);a===o&&n===t.x&&r===t.y||K.scheduleRender(),A.deltaTransform=a}},updateTreeLayoutProjection:function(){K.layoutTree.forEach(hi),kr.preRender(U,!1,!0)},getProjectionParent:function(){if(void 0===y){for(var e=!1,t=K.path.length-1;t>=0;t--){var n=K.path[t];if(n.projection.isEnabled){e=n;break}}y=e}return y},resolveRelativeTargetBox:function(){var e=K.getProjectionParent();if(T.relativeTarget&&e&&(function(e,t){sa(e.target.x,e.relativeTarget.x,t.target.x),sa(e.target.y,e.relativeTarget.y,t.target.y)}(T,e.projection),va(e))){var t=T.target;Sa(t,t,e.getLatestValues())}},shouldResetTransform:function(){return Boolean(f._layoutResetTransform)},pointTo:function(e){k=e.projection,C=e.getLatestValues(),null==j||j(),j=on(e.onSetAxisTarget(K.scheduleUpdateLayoutProjection),e.onLayoutAnimationComplete((function(){var e;K.isPresent?K.presence=Da.Present:null===(e=K.layoutSafeToRemove)||void 0===e||e.call(K)})))},isPresent:!0,presence:Da.Entering});return K}};function hi(e){e.resolveRelativeTargetBox()}function gi(e){e.updateLayoutProjection()}var Oi,yi=H(["initial"],G(Po)),ji=yi.length,Ei=new Set(["width","height","top","left","right","bottom","x","y"]),_i=function(e){return Ei.has(e)},wi=function(e,t){e.set(t,!1),e.set(t)},Si=function(e){return e===Ze||e===We};!function(e){e.width="width",e.height="height",e.left="left",e.right="right",e.top="top",e.bottom="bottom"}(Oi||(Oi={}));var xi=function(e,t){return parseFloat(e.split(", ")[t])},Pi=function(e,t){return function(n,r){var o=r.transform;if("none"===o||!o)return 0;var a=o.match(/^matrix3d\((.+)\)$/);if(a)return xi(a[1],t);var i=o.match(/^matrix\((.+)\)$/);return i?xi(i[1],e):0}},Ti=new Set(["x","y","z"]),ki=Se.filter((function(e){return!Ti.has(e)}));var Ci={width:function(e){var t=e.x;return t.max-t.min},height:function(e){var t=e.y;return t.max-t.min},top:function(e,t){var n=t.top;return parseFloat(n)},left:function(e,t){var n=t.left;return parseFloat(n)},bottom:function(e,t){var n=e.y,r=t.top;return parseFloat(r)+(n.max-n.min)},right:function(e,t){var n=e.x,r=t.left;return parseFloat(r)+(n.max-n.min)},x:Pi(4,13),y:Pi(5,14)},Ai=function(e,t,n,r){void 0===n&&(n={}),void 0===r&&(r={}),t=F({},t),r=F({},r);var o=Object.keys(t).filter(_i),a=[],i=!1,c=[];if(o.forEach((function(o){var s=e.getValue(o);if(e.hasValue(o)){var l,u=n[o],d=t[o],p=ho(u);if(xt(d))for(var m=d.length,b=null===d[0]?1:0;b<m;b++)l?ho(d[b]):(l=ho(d[b]))===p||Si(p)&&Si(l);else l=ho(d);if(p!==l)if(Si(p)&&Si(l)){var f=s.get();"string"==typeof f&&s.set(parseFloat(f)),"string"==typeof d?t[o]=parseFloat(d):Array.isArray(d)&&l===We&&(t[o]=d.map(parseFloat))}else(null==p?void 0:p.transform)&&(null==l?void 0:l.transform)&&(0===u||0===d)?0===u?s.set(l.transform(u)):t[o]=p.transform(d):(i||(a=function(e){var t=[];return ki.forEach((function(n){var r=e.getValue(n);void 0!==r&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))})),t.length&&e.syncRender(),t}(e),i=!0),c.push(o),r[o]=void 0!==r[o]?r[o]:t[o],wi(s,d))}})),c.length){var s=function(e,t,n){var r=t.measureViewportBox(),o=t.getInstance(),a=getComputedStyle(o),i=a.display,c={top:a.top,left:a.left,bottom:a.bottom,right:a.right,transform:a.transform};"none"===i&&t.setStaticValue("display",e.display||"block"),t.syncRender();var s=t.measureViewportBox();return n.forEach((function(n){var o=t.getValue(n);wi(o,Ci[n](r,c)),e[n]=Ci[n](s,a)})),e}(t,e,c);return a.length&&a.forEach((function(t){var n=G(t,2),r=n[0],o=n[1];e.getValue(r).set(o)})),e.syncRender(),{target:s,transitionEnd:r}}return{target:t,transitionEnd:r}};function Mi(e,t,n,r){return function(e){return Object.keys(e).some(_i)}(t)?Ai(e,t,n,r):{target:t,transitionEnd:r}}var Ii=function(e,t,n,r){var o=function(e,t,n){var r,o=U(t,[]),a=e.getInstance();if(!(a instanceof HTMLElement))return{target:o,transitionEnd:n};for(var i in n&&(n=F({},n)),e.forEachValue((function(e){var t=e.get();if(Ua(t)){var n=Ha(t,a);n&&e.set(n)}})),o){var c=o[i];if(Ua(c)){var s=Ha(c,a);s&&(o[i]=s,n&&(null!==(r=n[i])&&void 0!==r||(n[i]=c)))}}return{target:o,transitionEnd:n}}(e,t,r);return Mi(e,t=o.target,n,r=o.transitionEnd)};var Bi={treeType:"dom",readValueFromInstance:function(e,t){if(Te(t)){var n=eo(t);return n&&n.default||0}var r,o=(r=e,window.getComputedStyle(r));return(Be(t)?o.getPropertyValue(t):o[t])||0},sortNodePosition:function(e,t){return 2&e.compareDocumentPosition(t)?1:-1},getBaseTarget:function(e,t){var n;return null===(n=e.style)||void 0===n?void 0:n[t]},measureViewportBox:function(e,t){return ta(e,t.transformPagePoint)},resetTransform:function(e,t,n){var r=n.transformTemplate;t.style.transform=r?r({},""):"none",e.scheduleRender()},restoreTransform:function(e,t){e.style.transform=t.style.transform},removeValueFromRenderState:function(e,t){var n=t.vars,r=t.style;delete n[e],delete r[e]},makeTargetAnimatable:function(e,t,n,r){var o=n.transformValues;void 0===r&&(r=!0);var a=t.transition,i=t.transitionEnd,c=U(t,["transition","transitionEnd"]),s=function(e,t,n){var r,o,a={};for(var i in e)a[i]=null!==(r=Eo(i,t))&&void 0!==r?r:null===(o=n.getValue(i))||void 0===o?void 0:o.get();return a}(c,a||{},e);if(o&&(i&&(i=o(i)),c&&(c=o(c)),s&&(s=o(s))),r){!function(e,t,n){var r,o,a,i,c=Object.keys(t).filter((function(t){return!e.hasValue(t)})),s=c.length;if(s)for(var l=0;l<s;l++){var u=c[l],d=t[u],p=null;Array.isArray(d)&&(p=d[0]),null===p&&(p=null!==(o=null!==(r=n[u])&&void 0!==r?r:e.readValue(u))&&void 0!==o?o:t[u]),null!=p&&("string"==typeof p&&/^\-?\d*\.?\d+$/.test(p)?p=parseFloat(p):!Oo(p)&&Dn.test(d)&&(p=to(u,d)),e.addValue(u,bo(p)),null!==(a=(i=n)[u])&&void 0!==a||(i[u]=p),e.setBaseTarget(u,p))}}(e,c,s);var l=Ii(e,c,s,i);i=l.transitionEnd,c=l.target}return F({transition:a,transitionEnd:i},c)},scrapeMotionValuesFromProps:_t,build:function(e,t,n,r,o,a,i){void 0!==e.isVisible&&(t.style.visibility=e.isVisible?"visible":"hidden");var c=r.isEnabled&&o.isHydrated;tt(t,n,r,o,a,i.transformTemplate,c?ui:void 0,c?di:void 0)},render:yt},Li=vi(Bi),Ni=vi(F(F({},Bi),{getBaseTarget:function(e,t){return e[t]},readValueFromInstance:function(e,t){var n;return Te(t)?(null===(n=eo(t))||void 0===n?void 0:n.default)||0:(t=jt.has(t)?t:Ot(t),e.getAttribute(t))},scrapeMotionValuesFromProps:wt,build:function(e,t,n,r,o,a,i){var c=r.isEnabled&&o.isHydrated;bt(t,n,r,o,a,i.transformTemplate,c?ui:void 0,c?di:void 0)},render:Et})),Ri=function(e,t){return Ee(e)?Ni(t,{enableHardwareAcceleration:!1}):Li(t,{enableHardwareAcceleration:!0})},Di=F(F(F(F({},Io),cn),Fa),ci),Vi=ye((function(e,t){return Bt(e,t,Di,Ri)}));var Fi=n("cjQ8"),Ui=n("gdqT");var Gi=function({onClick:e=d.noop,small:t=!1}){const{shortcut:n,areAdvancedSettingsOpened:o}=Object(b.useSelect)(e=>({shortcut:e(N.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),areAdvancedSettingsOpened:"edit-post/block"===e(w.a).getActiveGeneralSidebarName()}),[]),{openGeneralSidebar:a,closeGeneralSidebar:i}=Object(b.useDispatch)(w.a),c=o?Object(f.__)("Hide more settings"):Object(f.__)("Show more settings");return Object(r.createElement)(m.MenuItem,{onClick:()=>{o?i():(a("edit-post/block"),o?Object(Ui.speak)(Object(f.__)("Block settings closed")):Object(Ui.speak)(Object(f.__)("Additional settings are now available in the Editor block settings sidebar")),e())},shortcut:n},!t&&c)};function Hi({children:e,contentRef:t,isTemplateMode:n,styles:o,style:i}){const c=Object(a.__unstableUseMouseMoveTypingReset)();return n?Object(r.createElement)(a.__unstableIframe,{head:Object(r.createElement)(a.__unstableEditorStyles,{styles:o}),ref:c,contentRef:t,style:{width:"100%",height:"100%",display:"block"}},Object(r.createElement)(a.WritingFlow,null,e)):Object(r.createElement)(r.Fragment,null,Object(r.createElement)(a.__unstableEditorStyles,{styles:o}),Object(r.createElement)(a.WritingFlow,{ref:t,className:"editor-styles-wrapper",style:{flex:"1",...i},tabIndex:-1},e))}function zi({styles:e}){const{deviceType:t,isTemplateMode:n,wrapperBlockName:o,wrapperUniqueId:c}=Object(b.useSelect)(e=>{const{isEditingTemplate:t,__experimentalGetPreviewDeviceType:n}=e(w.a),{getCurrentPostId:r,getCurrentPostType:o}=e(i.store),a=t();let c;return"wp_block"===o()?c="core/block":a||(c="core/post-content"),{deviceType:n(),isTemplateMode:a,wrapperBlockName:c,wrapperUniqueId:r()}},[]),s=Object(b.useSelect)(e=>e(w.a).hasMetaBoxes(),[]),l=Object(b.useSelect)(e=>{const{getSettings:t}=e(a.store);return t().supportsLayout},[]),{clearSelectedBlock:u}=Object(b.useDispatch)(a.store),{setIsEditingTemplate:d}=Object(b.useDispatch)(w.a),p={height:"100%",width:"100%",margin:0,display:"flex",flexFlow:"column",background:"white"},h={...p,borderRadius:"2px 2px 0 0",border:"1px solid #ddd",borderBottom:0},g=Object(a.__experimentalUseResizeCanvas)(t,n),O=Object(a.useSetting)("layout"),{contentSize:y,wideSize:j}=O||{};let E,_=n?h:p;g&&(_=g),s||g||n||(E="40vh");const S=Object(r.useRef)(),x=Object(v.useMergeRefs)([S,Object(a.__unstableUseClipboardHandler)(),Object(a.__unstableUseCanvasClickRedirect)(),Object(a.__unstableUseTypewriter)(),Object(a.__unstableUseTypingObserver)(),Object(a.__unstableUseBlockSelectionClearer)()]),P=Object(a.__unstableUseBlockSelectionClearer)(),[,T]=Object(a.__experimentalUseNoRecursiveRenders)(c,o),k=Object(r.useMemo)(()=>{if(n)return{type:"default"};if(l){return{type:"default",alignments:y||j?["wide","full","left","center","right"]:["left","center","right"]}}},[n,l,y,j]);return Object(r.createElement)("div",{className:B()("edit-post-visual-editor",{"is-template-mode":n})},Object(r.createElement)(i.VisualEditorGlobalKeyboardShortcuts,null),Object(r.createElement)(a.BlockTools,{__unstableContentRef:S},Object(r.createElement)(Vi.div,{className:"edit-post-visual-editor__content-area",animate:{padding:n?"48px 48px 0":"0"},ref:P},n&&Object(r.createElement)(m.Button,{className:"edit-post-visual-editor__exit-template-mode",icon:Fi.a,onClick:()=>{u(),d(!1)}},Object(f.__)("Back")),Object(r.createElement)(Vi.div,{animate:_,initial:p},Object(r.createElement)(Hi,{isTemplateMode:n,contentRef:x,styles:e,style:{paddingBottom:E}},l&&!n&&Object(r.createElement)(a.__experimentalLayoutStyle,{selector:".edit-post-visual-editor__post-title-wrapper, .block-editor-block-list__layout.is-root-container",layout:O}),!n&&Object(r.createElement)("div",{className:"edit-post-visual-editor__post-title-wrapper"},Object(r.createElement)(i.PostTitle,null)),Object(r.createElement)(T,null,Object(r.createElement)(a.BlockList,{__experimentalLayout:k})))))),Object(r.createElement)(a.__unstableBlockSettingsMenuFirstItem,null,({onClose:e})=>Object(r.createElement)(Gi,{onClick:e})))}var qi=function(){const{getBlockSelectionStart:e}=Object(b.useSelect)(a.store),{getEditorMode:t,isEditorSidebarOpened:n,isListViewOpened:o}=Object(b.useSelect)(w.a),c=Object(b.useSelect)(e=>{const{richEditingEnabled:t,codeEditingEnabled:n}=e(i.store).getEditorSettings();return!t||!n},[]),{switchEditorMode:s,openGeneralSidebar:l,closeGeneralSidebar:u,toggleFeature:d,setIsListViewOpened:p}=Object(b.useDispatch)(w.a),{registerShortcut:m}=Object(b.useDispatch)(N.store);return Object(r.useEffect)(()=>{m({name:"core/edit-post/toggle-mode",category:"global",description:Object(f.__)("Switch between visual editor and code editor."),keyCombination:{modifier:"secondary",character:"m"}}),m({name:"core/edit-post/toggle-fullscreen",category:"global",description:Object(f.__)("Toggle fullscreen mode."),keyCombination:{modifier:"secondary",character:"f"}}),m({name:"core/edit-post/toggle-block-navigation",category:"global",description:Object(f.__)("Open the block list view."),keyCombination:{modifier:"access",character:"o"}}),m({name:"core/edit-post/toggle-sidebar",category:"global",description:Object(f.__)("Show or hide the settings sidebar."),keyCombination:{modifier:"primaryShift",character:","}}),m({name:"core/edit-post/next-region",category:"global",description:Object(f.__)("Navigate to the next part of the editor."),keyCombination:{modifier:"ctrl",character:"`"},aliases:[{modifier:"access",character:"n"}]}),m({name:"core/edit-post/previous-region",category:"global",description:Object(f.__)("Navigate to the previous part of the editor."),keyCombination:{modifier:"ctrlShift",character:"`"},aliases:[{modifier:"access",character:"p"}]}),m({name:"core/edit-post/keyboard-shortcuts",category:"main",description:Object(f.__)("Display these keyboard shortcuts."),keyCombination:{modifier:"access",character:"h"}})},[]),Object(N.useShortcut)("core/edit-post/toggle-mode",()=>{s("visual"===t()?"text":"visual")},{bindGlobal:!0,isDisabled:c}),Object(N.useShortcut)("core/edit-post/toggle-fullscreen",()=>{d("fullscreenMode")},{bindGlobal:!0}),Object(N.useShortcut)("core/edit-post/toggle-sidebar",t=>{if(t.preventDefault(),n())u();else{const t=e()?"edit-post/block":"edit-post/document";l(t)}},{bindGlobal:!0}),Object(N.useShortcut)("core/edit-post/toggle-block-navigation",()=>p(!o()),{bindGlobal:!0}),null};const Wi=[{keyCombination:{modifier:"primary",character:"b"},description:Object(f.__)("Make the selected text bold.")},{keyCombination:{modifier:"primary",character:"i"},description:Object(f.__)("Make the selected text italic.")},{keyCombination:{modifier:"primary",character:"k"},description:Object(f.__)("Convert the selected text into a link.")},{keyCombination:{modifier:"primaryShift",character:"k"},description:Object(f.__)("Remove a link.")},{keyCombination:{modifier:"primary",character:"u"},description:Object(f.__)("Underline the selected text.")}];function Yi({keyCombination:e,forceAriaLabel:t}){const n=e.modifier?x.displayShortcutList[e.modifier](e.character):e.character,o=e.modifier?x.shortcutAriaLabel[e.modifier](e.character):e.character;return Object(r.createElement)("kbd",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-key-combination","aria-label":t||o},Object(d.castArray)(n).map((e,t)=>"+"===e?Object(r.createElement)(r.Fragment,{key:t},e):Object(r.createElement)("kbd",{key:t,className:"edit-post-keyboard-shortcut-help-modal__shortcut-key"},e)))}var Xi=function({description:e,keyCombination:t,aliases:n=[],ariaLabel:o}){return Object(r.createElement)(r.Fragment,null,Object(r.createElement)("div",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-description"},e),Object(r.createElement)("div",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-term"},Object(r.createElement)(Yi,{keyCombination:t,forceAriaLabel:o}),n.map((e,t)=>Object(r.createElement)(Yi,{keyCombination:e,forceAriaLabel:o,key:t}))))};var Ki=function({name:e}){const{keyCombination:t,description:n,aliases:o}=Object(b.useSelect)(t=>{const{getShortcutKeyCombination:n,getShortcutDescription:r,getShortcutAliases:o}=t(N.store);return{keyCombination:n(e),aliases:o(e),description:r(e)}});return t?Object(r.createElement)(Xi,{keyCombination:t,description:n,aliases:o}):null};const Zi="edit-post/keyboard-shortcut-help",Qi=({shortcuts:e})=>Object(r.createElement)("ul",{className:"edit-post-keyboard-shortcut-help-modal__shortcut-list",role:"list"},e.map((e,t)=>Object(r.createElement)("li",{className:"edit-post-keyboard-shortcut-help-modal__shortcut",key:t},Object(d.isString)(e)?Object(r.createElement)(Ki,{name:e}):Object(r.createElement)(Xi,e)))),$i=({title:e,shortcuts:t,className:n})=>Object(r.createElement)("section",{className:B()("edit-post-keyboard-shortcut-help-modal__section",n)},!!e&&Object(r.createElement)("h2",{className:"edit-post-keyboard-shortcut-help-modal__section-title"},e),Object(r.createElement)(Qi,{shortcuts:t})),Ji=({title:e,categoryName:t,additionalShortcuts:n=[]})=>{const o=Object(b.useSelect)(e=>e(N.store).getCategoryShortcuts(t),[t]);return Object(r.createElement)($i,{title:e,shortcuts:o.concat(n)})};var ec=Object(v.compose)([Object(b.withSelect)(e=>({isModalActive:e(w.a).isModalActive(Zi)})),Object(b.withDispatch)((e,{isModalActive:t})=>{const{openModal:n,closeModal:r}=e(w.a);return{toggleModal:()=>t?r():n(Zi)}})])((function({isModalActive:e,toggleModal:t}){return Object(N.useShortcut)("core/edit-post/keyboard-shortcuts",t,{bindGlobal:!0}),e?Object(r.createElement)(m.Modal,{className:"edit-post-keyboard-shortcut-help-modal",title:Object(f.__)("Keyboard shortcuts"),closeLabel:Object(f.__)("Close"),onRequestClose:t},Object(r.createElement)($i,{className:"edit-post-keyboard-shortcut-help-modal__main-shortcuts",shortcuts:["core/edit-post/keyboard-shortcuts"]}),Object(r.createElement)(Ji,{title:Object(f.__)("Global shortcuts"),categoryName:"global"}),Object(r.createElement)(Ji,{title:Object(f.__)("Selection shortcuts"),categoryName:"selection"}),Object(r.createElement)(Ji,{title:Object(f.__)("Block shortcuts"),categoryName:"block",additionalShortcuts:[{keyCombination:{character:"/"},description:Object(f.__)("Change the block type after adding a new paragraph."),ariaLabel:Object(f.__)("Forward-slash")}]}),Object(r.createElement)($i,{title:Object(f.__)("Text formatting"),shortcuts:Wi})):null}));var tc=function({blockTypes:e,value:t,onItemChange:n}){return Object(r.createElement)("ul",{className:"edit-post-manage-blocks-modal__checklist"},e.map(e=>Object(r.createElement)("li",{key:e.name,className:"edit-post-manage-blocks-modal__checklist-item"},Object(r.createElement)(m.CheckboxControl,{label:Object(r.createElement)(r.Fragment,null,e.title,Object(r.createElement)(a.BlockIcon,{icon:e.icon})),checked:t.includes(e.name),onChange:Object(d.partial)(n,e.name)}))))};var nc=Object(r.createContext)({});var rc=Object(v.compose)([v.withInstanceId,Object(b.withSelect)(e=>{const{getPreference:t}=e(w.a);return{hiddenBlockTypes:t("hiddenBlockTypes")}}),Object(b.withDispatch)((e,t)=>{const{showBlockTypes:n,hideBlockTypes:r}=e(w.a);return{toggleVisible(e,t){t?n(e):r(e)},toggleAllVisible(e){const o=Object(d.map)(t.blockTypes,"name");e?n(o):r(o)}}})])((function({instanceId:e,title:t,blockTypes:n,hiddenBlockTypes:o,toggleVisible:a,toggleAllVisible:i}){const c=Object(r.useContext)(nc),{allowedBlockTypes:s}=c,l=Object(r.useMemo)(()=>!0===s?n:n.filter(({name:e})=>Object(d.includes)(s||[],e)),[s,n]);if(!l.length)return null;const u=Object(d.without)(Object(d.map)(l,"name"),...o),p="edit-post-manage-blocks-modal__category-title-"+e,b=u.length===l.length;let f;return f=b?"true":u.length>0?"mixed":"false",Object(r.createElement)("div",{role:"group","aria-labelledby":p,className:"edit-post-manage-blocks-modal__category"},Object(r.createElement)(m.CheckboxControl,{checked:b,onChange:i,className:"edit-post-manage-blocks-modal__category-title","aria-checked":f,label:Object(r.createElement)("span",{id:p},t)}),Object(r.createElement)(tc,{blockTypes:l,value:u,onItemChange:a}))}));var oc=Object(v.compose)([Object(v.withState)({search:""}),Object(b.withSelect)(e=>{const{getBlockTypes:t,getCategories:n,hasBlockSupport:r,isMatchingSearchTerm:o}=e(p.store),{getPreference:a}=e(w.a),i=a("hiddenBlockTypes"),c=Object(d.isArray)(i)&&i.length;return{blockTypes:t(),categories:n(),hasBlockSupport:r,isMatchingSearchTerm:o,numberOfHiddenBlocks:c}})])((function({search:e,setState:t,blockTypes:n,categories:o,hasBlockSupport:a,isMatchingSearchTerm:i,numberOfHiddenBlocks:c}){return n=n.filter(t=>a(t,"inserter",!0)&&(!e||i(t,e))&&(!t.parent||Object(d.includes)(t.parent,"core/post-content"))),Object(r.createElement)("div",{className:"edit-post-manage-blocks-modal__content"},Object(r.createElement)(m.TextControl,{type:"search",label:Object(f.__)("Search for a block"),value:e,onChange:e=>t({search:e}),className:"edit-post-manage-blocks-modal__search"}),!!c&&Object(r.createElement)("div",{className:"edit-post-manage-blocks-modal__disabled-blocks-count"},Object(f.sprintf)(Object(f._n)("%d block is disabled.","%d blocks are disabled.",c),c)),Object(r.createElement)("div",{tabIndex:"0",role:"region","aria-label":Object(f.__)("Available block types"),className:"edit-post-manage-blocks-modal__results"},0===n.length&&Object(r.createElement)("p",{className:"edit-post-manage-blocks-modal__no-results"},Object(f.__)("No blocks found.")),o.map(e=>Object(r.createElement)(rc,{key:e.slug,title:e.title,blockTypes:Object(d.filter)(n,{category:e.slug})})),Object(r.createElement)(rc,{title:Object(f.__)("Uncategorized"),blockTypes:Object(d.filter)(n,({category:e})=>!e)})))}));var ac=Object(v.compose)([Object(b.withSelect)(e=>{const{isModalActive:t}=e(w.a);return{isActive:t("edit-post/manage-blocks")}}),Object(b.withDispatch)(e=>{const{closeModal:t}=e(w.a);return{closeModal:t}})])((function({isActive:e,closeModal:t}){return e?Object(r.createElement)(m.Modal,{className:"edit-post-manage-blocks-modal",title:Object(f.__)("Block Manager"),closeLabel:Object(f.__)("Close"),onRequestClose:t},Object(r.createElement)(oc,null)):null}));var ic=({description:e,title:t,children:n})=>Object(r.createElement)("section",{className:"edit-post-preferences-modal__section"},Object(r.createElement)("h2",{className:"edit-post-preferences-modal__section-title"},t),e&&Object(r.createElement)("p",{className:"edit-post-preferences-modal__section-description"},e),n),cc=n("Y5n4");var sc=Object(b.withSelect)(e=>{const{getEditorSettings:t}=e("core/editor"),{getAllMetaBoxes:n}=e(w.a);return{areCustomFieldsRegistered:void 0!==t().enableCustomFields,metaBoxes:n()}})((function({areCustomFieldsRegistered:e,metaBoxes:t,...n}){const o=Object(d.filter)(t,({id:e})=>"postcustom"!==e);return e||0!==o.length?Object(r.createElement)(ic,n,e&&Object(r.createElement)(cc.a,{label:Object(f.__)("Custom fields")}),Object(d.map)(o,({id:e,title:t})=>Object(r.createElement)(cc.c,{key:e,label:t,panelName:"meta-box-"+e}))):null}));function lc(){const e=Object(v.useViewportMatch)("medium"),{closeModal:t}=Object(b.useDispatch)(w.a),{isModalActive:n,isViewable:a}=Object(b.useSelect)(e=>{const{getEditedPostAttribute:t}=e(i.store),{getPostType:n}=e(o.store),r=n(t("type"));return{isModalActive:e(w.a).isModalActive("edit-post/preferences"),isViewable:Object(d.get)(r,["viewable"],!1)}},[]),c=Object(b.useSelect)(t=>{const{getEditorSettings:n}=t(i.store),{getEditorMode:r,isFeatureActive:o}=t(w.a),a=r(),c=n().richEditingEnabled;return!o("reducedUI")&&e&&c&&"visual"===a},[e]),s=Object(r.useMemo)(()=>[{name:"general",tabLabel:Object(f.__)("General"),content:Object(r.createElement)(r.Fragment,null,e&&Object(r.createElement)(ic,{title:Object(f.__)("Choose your own experience")},Object(r.createElement)(cc.e,{help:Object(f.__)("Review settings such as categories and tags."),label:Object(f.__)("Include pre-publish checklist")})),Object(r.createElement)(ic,{title:Object(f.__)("Decide what to focus on")},Object(r.createElement)(cc.b,{featureName:"reducedUI",help:Object(f.__)("Compacts options and outlines in the toolbar."),label:Object(f.__)("Reduce the interface")}),Object(r.createElement)(cc.b,{featureName:"focusMode",help:Object(f.__)("Highlights the current block and fades other content."),label:Object(f.__)("Spotlight mode")}),c&&Object(r.createElement)(cc.b,{featureName:"showBlockBreadcrumbs",help:Object(f.__)("Shows block breadcrumbs at the bottom of the editor."),label:Object(f.__)("Display block breadcrumbs")})))},{name:"appearance",tabLabel:Object(f.__)("Appearance"),content:Object(r.createElement)(ic,{title:Object(f.__)("Choose the way it looks")},Object(r.createElement)(cc.b,{featureName:"showIconLabels",help:Object(f.__)("Shows text instead of icons in toolbar."),label:Object(f.__)("Display button labels")}),Object(r.createElement)(cc.b,{featureName:"themeStyles",help:Object(f.__)("Make the editor look like your theme."),label:Object(f.__)("Use theme styles")}))},{name:"blocks",tabLabel:Object(f.__)("Blocks"),content:Object(r.createElement)(ic,{title:Object(f.__)("Choose how you interact with blocks")},Object(r.createElement)(cc.b,{featureName:"mostUsedBlocks",help:Object(f.__)("Places the most frequent blocks in the block library."),label:Object(f.__)("Show most used blocks")}),Object(r.createElement)(cc.b,{featureName:"keepCaretInsideBlock",help:Object(f.__)("Aids screen readers by stopping text caret from leaving blocks."),label:Object(f.__)("Contain text cursor inside block")}))},{name:"panels",tabLabel:Object(f.__)("Panels"),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)(ic,{title:Object(f.__)("Document settings"),description:Object(f.__)("Choose what displays in the panel.")},Object(r.createElement)(cc.d.Slot,null),a&&Object(r.createElement)(cc.c,{label:Object(f.__)("Permalink"),panelName:"post-link"}),a&&Object(r.createElement)(cc.c,{label:Object(f.__)("Template"),panelName:"template"}),Object(r.createElement)(i.PostTaxonomies,{taxonomyWrapper:(e,t)=>Object(r.createElement)(cc.c,{label:Object(d.get)(t,["labels","menu_name"]),panelName:"taxonomy-panel-"+t.slug})}),Object(r.createElement)(i.PostFeaturedImageCheck,null,Object(r.createElement)(cc.c,{label:Object(f.__)("Featured image"),panelName:"featured-image"})),Object(r.createElement)(i.PostExcerptCheck,null,Object(r.createElement)(cc.c,{label:Object(f.__)("Excerpt"),panelName:"post-excerpt"})),Object(r.createElement)(i.PostTypeSupportCheck,{supportKeys:["comments","trackbacks"]},Object(r.createElement)(cc.c,{label:Object(f.__)("Discussion"),panelName:"discussion-panel"})),Object(r.createElement)(i.PageAttributesCheck,null,Object(r.createElement)(cc.c,{label:Object(f.__)("Page attributes"),panelName:"page-attributes"}))),Object(r.createElement)(ic,{title:Object(f.__)("Additional"),description:Object(f.__)("Add extra areas to the editor.")},Object(r.createElement)(sc,null)))}],[a,e,c]),[l,u]=Object(r.useState)("preferences-menu"),{tabs:p,sectionsContentMap:h}=Object(r.useMemo)(()=>s.reduce((e,{name:t,tabLabel:n,content:r})=>(e.tabs.push({name:t,title:n}),e.sectionsContentMap[t]=r,e),{tabs:[],sectionsContentMap:{}}),[s]),g=Object(r.useCallback)(e=>h[e.name]||null,[h]);if(!n)return null;let O;return O=e?Object(r.createElement)(m.TabPanel,{className:"edit-post-preferences__tabs",tabs:p,initialTabName:"preferences-menu"!==l?l:void 0,onSelect:u,orientation:"vertical"},g):Object(r.createElement)(m.__experimentalNavigation,{activeMenu:l,onActivateMenu:u},Object(r.createElement)(m.__experimentalNavigationMenu,{menu:"preferences-menu"},p.map(e=>Object(r.createElement)(m.__experimentalNavigationItem,{key:e.name,title:e.title,navigateToMenu:e.name}))),s.map(e=>Object(r.createElement)(m.__experimentalNavigationMenu,{key:e.name+"-menu",menu:e.name,title:e.tabLabel,parentMenu:"preferences-menu"},Object(r.createElement)(m.__experimentalNavigationItem,null,e.content)))),Object(r.createElement)(m.Modal,{className:"edit-post-preferences-modal",title:Object(f.__)("Preferences"),closeLabel:Object(f.__)("Close"),onRequestClose:t},O)}class uc extends r.Component{constructor(){super(...arguments),this.state={historyId:null}}componentDidUpdate(e){const{postId:t,postStatus:n,postType:r,isSavingPost:o}=this.props,{historyId:a}=this.state;"trash"!==n||o?t===e.postId&&t===a||"auto-draft"===n||!t||this.setBrowserURL(t):this.setTrashURL(t,r)}setTrashURL(e,t){window.location.href=function(e,t){return Object(j.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(j.addQueryArgs)("post.php",{post:e,action:"edit"})}(e)),this.setState(()=>({historyId:e}))}render(){return null}}var dc=Object(b.withSelect)(e=>{const{getCurrentPost:t,isSavingPost:n}=e("core/editor"),r=t();let{id:o,status:a,type:i}=r;return["wp_template","wp_template_part"].includes(i)&&(o=r.wp_id),{postId:o,postStatus:a,postType:i,isSavingPost:n()}})(uc),pc=n("wduq");var mc=function({showTooltip:e,icon:t,href:n}){const{isActive:o,isRequestingSiteIcon:a,postType:i,siteIconUrl:c}=Object(b.useSelect)(e=>{const{getCurrentPostType:t}=e("core/editor"),{isFeatureActive:n}=e(w.a),{isResolving:r}=e("core/data"),{getEntityRecord:o,getPostType:a}=e("core"),i=o("root","__unstableBase",void 0)||{};return{isActive:n("fullscreenMode"),isRequestingSiteIcon:r("core","getEntityRecord",["root","__unstableBase",void 0]),postType:a(t()),siteIconUrl:i.site_icon_url}},[]);if(!o||!i)return null;let s=Object(r.createElement)(m.Icon,{size:"36px",icon:pc.a});return c&&(s=Object(r.createElement)("img",{alt:Object(f.__)("Site Icon"),className:"edit-post-fullscreen-mode-close_site-icon",src:c})),a&&(s=null),t&&(s=Object(r.createElement)(m.Icon,{size:"36px",icon:t})),Object(r.createElement)(m.Button,{className:"edit-post-fullscreen-mode-close has-icon",href:null!=n?n:Object(j.addQueryArgs)("edit.php",{post_type:i.slug}),label:Object(d.get)(i,["labels","view_items"],Object(f.__)("Back")),showTooltip:e},s)},bc=n("OzlF"),fc=n("Q4Sy");var vc=function(){const e=Object(r.useRef)(),{setIsInserterOpened:t,setIsListViewOpened:n}=Object(b.useDispatch)(w.a),{isInserterEnabled:o,isInserterOpened:c,isTextModeEnabled:s,showIconLabels:l,isListViewOpen:u,listViewShortcut:d}=Object(b.useSelect)(e=>{const{hasInserterItems:t,getBlockRootClientId:n,getBlockSelectionEnd:r}=e(a.store),{getEditorSettings:o}=e(i.store),{getEditorMode:c,isFeatureActive:s,isListViewOpened:l}=e(w.a),{getShortcutRepresentation:u}=e(N.store);return{isInserterEnabled:"visual"===c()&&o().richEditingEnabled&&t(n(r())),isInserterOpened:e(w.a).isInserterOpened(),isTextModeEnabled:"text"===c(),showIconLabels:s("showIconLabels"),isListViewOpen:l(),listViewShortcut:u("core/edit-post/toggle-block-navigation")}},[]),p=Object(v.useViewportMatch)("medium"),h=Object(v.useViewportMatch)("wide"),g=Object(f.__)("Document tools"),O=Object(r.createElement)(r.Fragment,null,Object(r.createElement)(m.ToolbarItem,{as:i.TableOfContents,hasOutlineItemsDisabled:s,repositionDropdown:l&&!h,showTooltip:!l,isTertiary:l}),Object(r.createElement)(m.ToolbarItem,{as:m.Button,className:"edit-post-header-toolbar__list-view-toggle",icon:bc.a,disabled:s,isPressed:u,label:Object(f.__)("List View"),onClick:()=>n(!u),shortcut:d,showTooltip:!l}));return Object(r.createElement)(a.NavigableToolbar,{className:"edit-post-header-toolbar","aria-label":g},Object(r.createElement)("div",{className:"edit-post-header-toolbar__left"},Object(r.createElement)(m.ToolbarItem,{ref:e,as:m.Button,className:"edit-post-header-toolbar__inserter-toggle",isPrimary:!0,isPressed:c,onMouseDown:e=>{e.preventDefault()},onClick:()=>{c?e.current.focus():t(!0)},disabled:!o,icon:fc.a,label:Object(f._x)("Toggle block inserter","Generic label for block inserter button"),showTooltip:!l},l&&Object(f.__)("Add")),(h||!l)&&Object(r.createElement)(r.Fragment,null,p&&Object(r.createElement)(m.ToolbarItem,{as:a.ToolSelector,showTooltip:!l,isTertiary:l,disabled:s}),Object(r.createElement)(m.ToolbarItem,{as:i.EditorHistoryUndo,showTooltip:!l,isTertiary:l}),Object(r.createElement)(m.ToolbarItem,{as:i.EditorHistoryRedo,showTooltip:!l,isTertiary:l}),O)))},hc=n("VKE3");const gc=[{value:"visual",label:Object(f.__)("Visual editor")},{value:"text",label:Object(f.__)("Code editor")}];var Oc=function(){const{shortcut:e,isRichEditingEnabled:t,isCodeEditingEnabled:n,mode:o}=Object(b.useSelect)(e=>({shortcut:e(N.store).getShortcutRepresentation("core/edit-post/toggle-mode"),isRichEditingEnabled:e("core/editor").getEditorSettings().richEditingEnabled,isCodeEditingEnabled:e("core/editor").getEditorSettings().codeEditingEnabled,mode:e(w.a).getEditorMode()}),[]),{switchEditorMode:a}=Object(b.useDispatch)(w.a);if(!t||!n)return null;const i=gc.map(t=>t.value!==o?{...t,shortcut:e}:t);return Object(r.createElement)(m.MenuGroup,{label:Object(f.__)("Editor")},Object(r.createElement)(m.MenuItemsChoice,{choices:i,value:o,onSelect:a}))};function yc(){const{openModal:e}=Object(b.useDispatch)(w.a);return Object(r.createElement)(m.MenuItem,{onClick:()=>{e("edit-post/preferences")}},Object(f.__)("Preferences"))}var jc=n("RMJe");var Ec=Object(v.compose)([Object(b.withSelect)((e,{feature:t})=>({isActive:e(w.a).isFeatureActive(t)})),Object(b.withDispatch)((e,t)=>({onToggle(){e(w.a).toggleFeature(t.feature)}}))])((function({onToggle:e,isActive:t,label:n,info:o,messageActivated:a,messageDeactivated:i,shortcut:c}){return Object(r.createElement)(m.MenuItem,{icon:t&&jc.a,isSelected:t,onClick:Object(d.flow)(e,()=>{t?Object(Ui.speak)(i||Object(f.__)("Feature deactivated")):Object(Ui.speak)(a||Object(f.__)("Feature activated"))}),role:"menuitemcheckbox",info:o,shortcut:c},n)}));var _c=function(){return Object(v.useViewportMatch)("medium")?Object(r.createElement)(m.MenuGroup,{label:Object(f._x)("View","noun")},Object(r.createElement)(Ec,{feature:"fixedToolbar",label:Object(f.__)("Top toolbar"),info:Object(f.__)("Access all block and document tools in a single place"),messageActivated:Object(f.__)("Top toolbar activated"),messageDeactivated:Object(f.__)("Top toolbar deactivated")}),Object(r.createElement)(Ec,{feature:"focusMode",label:Object(f.__)("Spotlight mode"),info:Object(f.__)("Focus on one block at a time"),messageActivated:Object(f.__)("Spotlight mode activated"),messageDeactivated:Object(f.__)("Spotlight mode deactivated")}),Object(r.createElement)(Ec,{feature:"fullscreenMode",label:Object(f.__)("Fullscreen mode"),info:Object(f.__)("Work without distraction"),messageActivated:Object(f.__)("Fullscreen mode activated"),messageDeactivated:Object(f.__)("Fullscreen mode deactivated"),shortcut:x.displayShortcut.secondary("f")})):null};const wc={className:"edit-post-more-menu__content",position:"bottom left"},Sc={tooltipPosition:"bottom"};var xc=({showIconLabels:e})=>{const t=Object(v.useViewportMatch)("large");return Object(r.createElement)(m.DropdownMenu,{className:"edit-post-more-menu",icon:hc.a,label:Object(f.__)("Options"),popoverProps:wc,toggleProps:{showTooltip:!e,isTertiary:e,...Sc}},({onClose:n})=>Object(r.createElement)(r.Fragment,null,e&&!t&&Object(r.createElement)(L.f.Slot,{className:e&&"show-icon-labels",scope:"core/edit-post"}),Object(r.createElement)(_c,null),Object(r.createElement)(Oc,null),Object(r.createElement)(L.a.Slot,{name:"core/edit-post/plugin-more-menu",label:Object(f.__)("Plugins"),as:m.MenuGroup,fillProps:{onClick:n}}),Object(r.createElement)(C.Slot,{fillProps:{onClose:n}}),Object(r.createElement)(m.MenuGroup,null,Object(r.createElement)(yc,null))))};var Pc=Object(v.compose)(Object(b.withSelect)(e=>({hasPublishAction:Object(d.get)(e("core/editor").getCurrentPost(),["_links","wp:action-publish"],!1),isBeingScheduled:e("core/editor").isEditedPostBeingScheduled(),isPending:e("core/editor").isCurrentPostPending(),isPublished:e("core/editor").isCurrentPostPublished(),isPublishSidebarEnabled:e("core/editor").isPublishSidebarEnabled(),isPublishSidebarOpened:e(w.a).isPublishSidebarOpened(),isScheduled:e("core/editor").isCurrentPostScheduled()})),Object(b.withDispatch)(e=>{const{togglePublishSidebar:t}=e(w.a);return{togglePublishSidebar:t}}))((function({forceIsDirty:e,forceIsSaving:t,hasPublishAction:n,isBeingScheduled:o,isPending:a,isPublished:c,isPublishSidebarEnabled:s,isPublishSidebarOpened:l,isScheduled:u,togglePublishSidebar:d,setEntitiesSavedStatesCallback:p}){const m=Object(v.useViewportMatch)("medium","<");let b;return b=c||u&&o||a&&!n&&!m?"button":m||s?"toggle":"button",Object(r.createElement)(i.PostPublishButton,{forceIsDirty:e,forceIsSaving:t,isOpen:l,isToggle:"toggle"===b,onToggle:d,setEntitiesSavedStatesCallback:p})}));function Tc(){const{hasActiveMetaboxes:e,isPostSaveable:t,isSaving:n,deviceType:o}=Object(b.useSelect)(e=>({hasActiveMetaboxes:e(w.a).hasMetaBoxes(),isSaving:e(w.a).isSavingMetaBoxes(),isPostSaveable:e("core/editor").isEditedPostSaveable(),deviceType:e(w.a).__experimentalGetPreviewDeviceType()}),[]),{__experimentalSetPreviewDeviceType:c}=Object(b.useDispatch)(w.a);return Object(r.createElement)(a.__experimentalPreviewOptions,{isEnabled:t,className:"edit-post-post-preview-dropdown",deviceType:o,setDeviceType:c},Object(r.createElement)(m.MenuGroup,null,Object(r.createElement)("div",{className:"edit-post-header-preview__grouping-external"},Object(r.createElement)(i.PostPreviewButton,{className:"edit-post-header-preview__button-external",role:"menuitem",forceIsAutosaveable:e,forcePreviewLink:n?null:void 0,textContent:Object(r.createElement)(r.Fragment,null,Object(f.__)("Preview in new tab"),Object(r.createElement)(m.Icon,{icon:O.a}))}))))}const kc="__experimentalMainDashboardButton",{Fill:Cc,Slot:Ac}=Object(m.createSlotFill)(kc),Mc=Cc;Mc.Slot=({children:e})=>{const t=Object(m.__experimentalUseSlot)(kc);return Boolean(t.fills&&t.fills.length)?Object(r.createElement)(Ac,{bubblesVirtually:!0}):e};var Ic=Mc,Bc=n("NWDH");function Lc(){const{clearSelectedBlock:e}=Object(b.useDispatch)(a.store),{setIsEditingTemplate:t}=Object(b.useDispatch)(w.a),{getEditorSettings:n}=Object(b.useSelect)(i.store),{updateEditorSettings:c,editPost:s}=Object(b.useDispatch)(i.store),{deleteEntityRecord:l}=Object(b.useDispatch)(o.store),{template:u}=Object(b.useSelect)(e=>{const{isEditingTemplate:t,getEditedPostTemplate:n}=e(w.a);return{template:t()?n():null}},[]);if(!u||!u.wp_id)return null;let p=u.slug;return null!=u&&u.title&&(p=u.title),Object(r.createElement)(m.MenuGroup,{className:"edit-post-template-top-area__second-menu-group"},Object(r.createElement)(m.MenuItem,{className:"edit-post-template-top-area__delete-template-button",isDestructive:!0,isSecondary:!0,"aria-label":Object(f.__)("Delete template"),onClick:()=>{if(window.confirm(Object(f.sprintf)(Object(f.__)("Are you sure you want to delete the %s template? It may be used by other pages or posts."),p))){e(),t(!1),s({template:""});const r=n(),o=Object(d.pickBy)(r.availableTemplates,(e,t)=>t!==u.slug);c({...r,availableTemplates:o}),l("postType","wp_template",u.id)}}},Object(f.__)("Delete template")))}function Nc(){const{template:e}=Object(b.useSelect)(e=>{const{getEditedPostTemplate:t}=e(w.a);return{template:t()}},[]),{editEntityRecord:t}=Object(b.useDispatch)(o.store),{getEditorSettings:n}=Object(b.useSelect)(i.store),{updateEditorSettings:a}=Object(b.useDispatch)(i.store);let c=Object(f.__)("Default");return null!=e&&e.title?c=e.title:e&&(c=e.slug),Object(r.createElement)(m.TextControl,{label:Object(f.__)("Title"),value:c,help:Object(f.__)('Give the template a title that indicates its purpose, e.g. "Full Width".'),onChange:r=>{const o=n(),i=Object(d.mapValues)(o.availableTemplates,(t,n)=>n!==e.slug?t:r);a({...o,availableTemplates:i}),t("postType","wp_template",e.id,{title:r})}})}function Rc(){const{description:e}=Object(b.useSelect)(e=>{const{getEditedPostTemplate:t}=e(w.a);return{description:t().description}},[]);return e?Object(r.createElement)(m.__experimentalText,{size:"body"},e):null}var Dc=function(){const{template:e,isEditing:t,title:n}=Object(b.useSelect)(e=>{const{isEditingTemplate:t,getEditedPostTemplate:n}=e(w.a),{getEditedPostAttribute:r}=e(i.store),o=t();return{template:o?n():null,isEditing:o,title:r("title")}},[]),{clearSelectedBlock:o}=Object(b.useDispatch)(a.store),{setIsEditingTemplate:c}=Object(b.useDispatch)(w.a);if(!t||!e)return null;let s=Object(f.__)("Default");return null!=e&&e.title?s=e.title:e&&(s=e.slug),Object(r.createElement)("div",{className:"edit-post-template-top-area"},Object(r.createElement)(m.Button,{className:"edit-post-template-post-title",isLink:!0,showTooltip:!0,label:Object(f.sprintf)(Object(f.__)("Edit %s"),n),onClick:()=>{o(),c(!1)}},n),Object(r.createElement)(m.Dropdown,{position:"bottom center",contentClassName:"edit-post-template-top-area__popover",renderToggle:({onToggle:e})=>Object(r.createElement)(m.Button,{className:"edit-post-template-title",isLink:!0,icon:Bc.a,showTooltip:!0,onClick:e,label:Object(f.__)("Template Options")},s),renderContent:()=>Object(r.createElement)(r.Fragment,null,e.has_theme_file?Object(r.createElement)(Rc,null):Object(r.createElement)(Nc,null),Object(r.createElement)(Lc,null))}))};var Vc=function({setEntitiesSavedStatesCallback:e}){const{hasActiveMetaboxes:t,isPublishSidebarOpened:n,isSaving:o,showIconLabels:a,hasReducedUI:c}=Object(b.useSelect)(e=>({hasActiveMetaboxes:e(w.a).hasMetaBoxes(),isPublishSidebarOpened:e(w.a).isPublishSidebarOpened(),isSaving:e(w.a).isSavingMetaBoxes(),showIconLabels:e(w.a).isFeatureActive("showIconLabels"),hasReducedUI:e(w.a).isFeatureActive("reducedUI")}),[]),s=Object(v.useViewportMatch)("large"),l=B()("edit-post-header",{"has-reduced-ui":c});return Object(r.createElement)("div",{className:l},Object(r.createElement)(Ic.Slot,null,Object(r.createElement)(mc,null)),Object(r.createElement)("div",{className:"edit-post-header__toolbar"},Object(r.createElement)(vc,null),Object(r.createElement)(Dc,null)),Object(r.createElement)("div",{className:"edit-post-header__settings"},!n&&Object(r.createElement)(i.PostSavedState,{forceIsDirty:t,forceIsSaving:o,showIconLabels:a}),Object(r.createElement)(Tc,null),Object(r.createElement)(i.PostPreviewButton,{forceIsAutosaveable:t,forcePreviewLink:o?null:void 0}),Object(r.createElement)(Pc,{forceIsDirty:t,forceIsSaving:o,setEntitiesSavedStatesCallback:e}),(s||!a)&&Object(r.createElement)(r.Fragment,null,Object(r.createElement)(L.f.Slot,{scope:"core/edit-post"}),Object(r.createElement)(xc,{showIconLabels:a})),a&&!s&&Object(r.createElement)(xc,{showIconLabels:a})))},Fc=n("w95h");function Uc(){const{insertionPoint:e,showMostUsedBlocks:t}=Object(b.useSelect)(e=>{const{isFeatureActive:t,__experimentalGetInsertionPoint:n}=e(w.a);return{insertionPoint:n(),showMostUsedBlocks:t("mostUsedBlocks")}},[]),{setIsInserterOpened:n}=Object(b.useDispatch)(w.a),o=Object(v.useViewportMatch)("medium","<"),[i,c]=Object(v.__experimentalUseDialog)({onClose:()=>n(!1)});return Object(r.createElement)("div",Object(u.a)({ref:i},c,{className:"edit-post-editor__inserter-panel"}),Object(r.createElement)("div",{className:"edit-post-editor__inserter-panel-header"},Object(r.createElement)(m.Button,{icon:Fc.a,onClick:()=>n(!1)})),Object(r.createElement)("div",{className:"edit-post-editor__inserter-panel-content"},Object(r.createElement)(a.__experimentalLibrary,{showMostUsedBlocks:t,showInserterHelpPanel:!0,shouldFocusBlock:o,rootClientId:e.rootClientId,__experimentalInsertionIndex:e.insertionIndex})))}var Gc=n("bWcr");function Hc(){const{setIsListViewOpened:e}=Object(b.useDispatch)(w.a),{clearSelectedBlock:t,selectBlock:n}=Object(b.useDispatch)(a.store);const o=Object(v.useFocusOnMount)("firstElement"),i=Object(v.useFocusReturn)();const c="edit-post-editor__list-view-panel-label-"+Object(v.useInstanceId)(Hc);return Object(r.createElement)("div",{"aria-labelledby":c,className:"edit-post-editor__list-view-panel",onKeyDown:function(t){t.keyCode===x.ESCAPE&&(t.stopPropagation(),e(!1))}},Object(r.createElement)("div",{className:"edit-post-editor__list-view-panel-header"},Object(r.createElement)("strong",{id:c},Object(f.__)("List view")),Object(r.createElement)(m.Button,{icon:Gc.a,label:Object(f.__)("Close list view sidebar"),onClick:()=>e(!1)})),Object(r.createElement)("div",{className:"edit-post-editor__list-view-panel-content",ref:Object(v.useMergeRefs)([i,o])},Object(r.createElement)(a.__experimentalBlockNavigationTree,{onSelect:async function(e){await t(),n(e,-1)},showNestedBlocks:!0,__experimentalPersistentListViewFeatures:!0})))}var zc=n("Cg8A");var qc=({sidebarName:e})=>{const{openGeneralSidebar:t}=Object(b.useDispatch)(w.a),n=()=>t("edit-post/document"),{documentLabel:o,isTemplateMode:a}=Object(b.useSelect)(e=>{var t,n;const r=e("core/editor").getCurrentPostType(),o=e("core").getPostType(r);return{documentLabel:null!==(t=null==o||null===(n=o.labels)||void 0===n?void 0:n.singular_name)&&void 0!==t?t:Object(f.__)("Document"),isTemplateMode:e(w.a).isEditingTemplate()}},[]),[i,c]="edit-post/document"===e?[Object(f.sprintf)(Object(f.__)("%s (selected)"),o),"is-active"]:[o,""],[s,l]="edit-post/block"===e?[Object(f.__)("Block (selected)"),"is-active"]:[Object(f.__)("Block"),""],[u,d]="edit-post/document"===e?[Object(f.__)("Template (selected)"),"is-active"]:[Object(f.__)("Template"),""];return Object(r.createElement)("ul",null,!a&&Object(r.createElement)("li",null,Object(r.createElement)(m.Button,{onClick:n,className:"edit-post-sidebar__panel-tab "+c,"aria-label":i,"data-label":o},o)),a&&Object(r.createElement)("li",null,Object(r.createElement)(m.Button,{onClick:n,className:"edit-post-sidebar__panel-tab "+d,"aria-label":u,"data-label":Object(f.__)("Template")},Object(f.__)("Template"))),Object(r.createElement)("li",null,Object(r.createElement)(m.Button,{onClick:()=>t("edit-post/block"),className:"edit-post-sidebar__panel-tab "+l,"aria-label":s,"data-label":Object(f.__)("Block")},Object(f.__)("Block"))))};var Wc=function(){return Object(r.createElement)(i.PostVisibilityCheck,{render:({canEdit:e})=>Object(r.createElement)(m.PanelRow,{className:"edit-post-post-visibility"},Object(r.createElement)("span",null,Object(f.__)("Visibility")),!e&&Object(r.createElement)("span",null,Object(r.createElement)(i.PostVisibilityLabel,null)),e&&Object(r.createElement)(m.Dropdown,{position:"bottom left",contentClassName:"edit-post-post-visibility__dialog",renderToggle:({isOpen:e,onToggle:t})=>Object(r.createElement)(m.Button,{"aria-expanded":e,className:"edit-post-post-visibility__toggle",onClick:t,isTertiary:!0},Object(r.createElement)(i.PostVisibilityLabel,null)),renderContent:()=>Object(r.createElement)(i.PostVisibility,null)}))})};function Yc(){return Object(r.createElement)(i.PostTrashCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostTrash,null)))}var Xc=function(){const e=Object(r.useRef)();return Object(r.createElement)(i.PostScheduleCheck,null,Object(r.createElement)(m.PanelRow,{className:"edit-post-post-schedule",ref:e},Object(r.createElement)("span",null,Object(f.__)("Publish")),Object(r.createElement)(m.Dropdown,{popoverProps:{anchorRef:e.current},position:"bottom left",contentClassName:"edit-post-post-schedule__dialog",renderToggle:({onToggle:e,isOpen:t})=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)(m.Button,{className:"edit-post-post-schedule__toggle",onClick:e,"aria-expanded":t,isTertiary:!0},Object(r.createElement)(i.PostScheduleLabel,null))),renderContent:()=>Object(r.createElement)(i.PostSchedule,null)})))};var Kc=function(){return Object(r.createElement)(i.PostStickyCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostSticky,null)))};var Zc=function(){return Object(r.createElement)(i.PostAuthorCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostAuthor,null)))};var Qc=function(){return Object(r.createElement)(i.PostSlugCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostSlug,null)))};var $c=function(){return Object(r.createElement)(i.PostFormatCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostFormat,null)))};var Jc=function(){return Object(r.createElement)(i.PostPendingStatusCheck,null,Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostPendingStatus,null)))};const{Fill:es,Slot:ts}=Object(m.createSlotFill)("PluginPostStatusInfo"),ns=({children:e,className:t})=>Object(r.createElement)(es,null,Object(r.createElement)(m.PanelRow,{className:t},e));ns.Slot=ts;var rs=ns;var os=Object(v.compose)([Object(b.withSelect)(e=>{const{isEditorPanelRemoved:t,isEditorPanelOpened:n}=e(w.a);return{isRemoved:t("post-status"),isOpened:n("post-status")}}),Object(v.ifCondition)(({isRemoved:e})=>!e),Object(b.withDispatch)(e=>({onTogglePanel:()=>e(w.a).toggleEditorPanelOpened("post-status")}))])((function({isOpened:e,onTogglePanel:t}){return Object(r.createElement)(m.PanelBody,{className:"edit-post-post-status",title:Object(f.__)("Status & visibility"),opened:e,onToggle:t},Object(r.createElement)(rs.Slot,null,e=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)(Wc,null),Object(r.createElement)(Xc,null),Object(r.createElement)($c,null),Object(r.createElement)(Kc,null),Object(r.createElement)(Jc,null),Object(r.createElement)(Qc,null),Object(r.createElement)(Zc,null),e,Object(r.createElement)(Yc,null))))}));var as=function(){return Object(r.createElement)(i.PostLastRevisionCheck,null,Object(r.createElement)(m.PanelBody,{className:"edit-post-last-revision__panel"},Object(r.createElement)(i.PostLastRevision,null)))};var is=Object(v.compose)(Object(b.withSelect)((e,t)=>{const n=Object(d.get)(t.taxonomy,["slug"]),r=n?"taxonomy-panel-"+n:"";return{panelName:r,isEnabled:!!n&&e(w.a).isEditorPanelEnabled(r),isOpened:!!n&&e(w.a).isEditorPanelOpened(r)}}),Object(b.withDispatch)((e,t)=>({onTogglePanel:()=>{e(w.a).toggleEditorPanelOpened(t.panelName)}})))((function({isEnabled:e,taxonomy:t,isOpened:n,onTogglePanel:o,children:a}){if(!e)return null;const i=Object(d.get)(t,["labels","menu_name"]);return i?Object(r.createElement)(m.PanelBody,{title:i,opened:n,onToggle:o},a):null}));var cs=function(){return Object(r.createElement)(i.PostTaxonomiesCheck,null,Object(r.createElement)(i.PostTaxonomies,{taxonomyWrapper:(e,t)=>Object(r.createElement)(is,{taxonomy:t},e)}))};const ss=Object(b.withSelect)(e=>{const{getEditedPostAttribute:t}=e("core/editor"),{getPostType:n}=e("core"),{isEditorPanelEnabled:r,isEditorPanelOpened:o}=e(w.a);return{postType:n(t("type")),isEnabled:r("featured-image"),isOpened:o("featured-image")}}),ls=Object(b.withDispatch)(e=>{const{toggleEditorPanelOpened:t}=e(w.a);return{onTogglePanel:Object(d.partial)(t,"featured-image")}});var us=Object(v.compose)(ss,ls)((function({isEnabled:e,isOpened:t,postType:n,onTogglePanel:o}){return e?Object(r.createElement)(i.PostFeaturedImageCheck,null,Object(r.createElement)(m.PanelBody,{title:Object(d.get)(n,["labels","featured_image"],Object(f.__)("Featured image")),opened:t,onToggle:o},Object(r.createElement)(i.PostFeaturedImage,null))):null}));var ds=Object(v.compose)([Object(b.withSelect)(e=>({isEnabled:e(w.a).isEditorPanelEnabled("post-excerpt"),isOpened:e(w.a).isEditorPanelOpened("post-excerpt")})),Object(b.withDispatch)(e=>({onTogglePanel:()=>e(w.a).toggleEditorPanelOpened("post-excerpt")}))])((function({isEnabled:e,isOpened:t,onTogglePanel:n}){return e?Object(r.createElement)(i.PostExcerptCheck,null,Object(r.createElement)(m.PanelBody,{title:Object(f.__)("Excerpt"),opened:t,onToggle:n},Object(r.createElement)(i.PostExcerpt,null))):null}));var ps=Object(v.compose)([Object(b.withSelect)(e=>{const{isPermalinkEditable:t,getCurrentPost:n,isCurrentPostPublished:r,getPermalinkParts:o,getEditedPostAttribute:a,getEditedPostSlug:i}=e("core/editor"),{isEditorPanelEnabled:c,isEditorPanelOpened:s}=e(w.a),{getPostType:l}=e("core"),{link:u}=n(),p=l(a("type")),m=o();return{postLink:u,isEditable:t(),isPublished:r(),isOpened:s("post-link"),isEnabled:c("post-link"),isViewable:Object(d.get)(p,["viewable"],!1),postSlug:Object(j.safeDecodeURIComponent)(i()),postTypeLabel:Object(d.get)(p,["labels","view_item"]),hasPermalinkParts:!!m,permalinkPrefix:null==m?void 0:m.prefix,permalinkSuffix:null==m?void 0:m.suffix}}),Object(v.ifCondition)(({isEnabled:e,postLink:t,isViewable:n,hasPermalinkParts:r})=>e&&t&&n&&r),Object(b.withDispatch)(e=>{const{toggleEditorPanelOpened:t}=e(w.a),{editPost:n}=e("core/editor");return{onTogglePanel:()=>t("post-link"),editPermalink:e=>{n({slug:e})}}}),Object(v.withState)({forceEmptyField:!1})])((function({isOpened:e,onTogglePanel:t,isEditable:n,postLink:o,permalinkPrefix:a,permalinkSuffix:c,editPermalink:s,forceEmptyField:l,setState:u,postSlug:d,postTypeLabel:p}){let b,v,h;return n&&(b=a&&Object(r.createElement)("span",{className:"edit-post-post-link__link-prefix"},a),v=d&&Object(r.createElement)("span",{className:"edit-post-post-link__link-post-name"},d),h=c&&Object(r.createElement)("span",{className:"edit-post-post-link__link-suffix"},c)),Object(r.createElement)(m.PanelBody,{title:Object(f.__)("Permalink"),opened:e,onToggle:t},n&&Object(r.createElement)("div",{className:"editor-post-link"},Object(r.createElement)(m.TextControl,{label:Object(f.__)("URL Slug"),value:l?"":d,onChange:e=>{s(e),e?l&&u({forceEmptyField:!1}):l||u({forceEmptyField:!0})},onBlur:e=>{s(Object(i.cleanForSlug)(e.target.value)),l&&u({forceEmptyField:!1})}}),Object(r.createElement)("p",null,Object(f.__)("The last part of the URL.")," ",Object(r.createElement)(m.ExternalLink,{href:"https://wordpress.org/support/article/writing-posts/#post-field-descriptions"},Object(f.__)("Read about permalinks")))),Object(r.createElement)("h3",{className:"edit-post-post-link__preview-label"},p||Object(f.__)("View post")),Object(r.createElement)("div",{className:"edit-post-post-link__preview-link-container"},Object(r.createElement)(m.ExternalLink,{className:"edit-post-post-link__link",href:o,target:"_blank"},n?Object(r.createElement)(r.Fragment,null,b,v,h):o)))}));var ms=Object(v.compose)([Object(b.withSelect)(e=>({isEnabled:e(w.a).isEditorPanelEnabled("discussion-panel"),isOpened:e(w.a).isEditorPanelOpened("discussion-panel")})),Object(b.withDispatch)(e=>({onTogglePanel:()=>e(w.a).toggleEditorPanelOpened("discussion-panel")}))])((function({isEnabled:e,isOpened:t,onTogglePanel:n}){return e?Object(r.createElement)(i.PostTypeSupportCheck,{supportKeys:["comments","trackbacks"]},Object(r.createElement)(m.PanelBody,{title:Object(f.__)("Discussion"),opened:t,onToggle:n},Object(r.createElement)(i.PostTypeSupportCheck,{supportKeys:"comments"},Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostComments,null))),Object(r.createElement)(i.PostTypeSupportCheck,{supportKeys:"trackbacks"},Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PostPingbacks,null))))):null}));var bs=function(){const{isEnabled:e,isOpened:t,postType:n}=Object(b.useSelect)(e=>{const{getEditedPostAttribute:t}=e(i.store),{isEditorPanelEnabled:n,isEditorPanelOpened:r}=e(w.a),{getPostType:a}=e(o.store);return{isEnabled:n("page-attributes"),isOpened:r("page-attributes"),postType:a(t("type"))}},[]),{toggleEditorPanelOpened:a}=Object(b.useDispatch)(w.a);if(!e||!n)return null;const c=Object(d.partial)(a,"page-attributes");return Object(r.createElement)(i.PageAttributesCheck,null,Object(r.createElement)(m.PanelBody,{title:Object(d.get)(n,["labels","attributes"],Object(f.__)("Page attributes")),opened:t,onToggle:c},Object(r.createElement)(i.PageAttributesParent,null),Object(r.createElement)(m.PanelRow,null,Object(r.createElement)(i.PageAttributesOrder,null))))};class fs extends r.Component{constructor(){super(...arguments),this.bindContainerNode=this.bindContainerNode.bind(this)}componentDidMount(){this.form=document.querySelector(".metabox-location-"+this.props.location),this.form&&this.container.appendChild(this.form)}componentWillUnmount(){this.form&&document.querySelector("#metaboxes").appendChild(this.form)}bindContainerNode(e){this.container=e}render(){const{location:e,isSaving:t}=this.props,n=B()("edit-post-meta-boxes-area","is-"+e,{"is-loading":t});return Object(r.createElement)("div",{className:n},t&&Object(r.createElement)(m.Spinner,null),Object(r.createElement)("div",{className:"edit-post-meta-boxes-area__container",ref:this.bindContainerNode}),Object(r.createElement)("div",{className:"edit-post-meta-boxes-area__clear"}))}}var vs=Object(b.withSelect)(e=>({isSaving:e(w.a).isSavingMetaBoxes()}))(fs);class hs extends r.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 gs=Object(b.withSelect)((e,{id:t})=>({isVisible:e(w.a).isEditorPanelEnabled("meta-box-"+t)}))(hs);function Os({location:e}){const t=Object(b.useRegistry)(),{metaBoxes:n,isVisible:o,areMetaBoxesInitialized:a,isEditorReady:c}=Object(b.useSelect)(t=>{const{__unstableIsEditorReady:n}=t(i.store),{isMetaBoxLocationVisible:r,getMetaBoxesPerLocation:o,areMetaBoxesInitialized:a}=t(w.a);return{metaBoxes:o(e),isVisible:r(e),areMetaBoxesInitialized:a(),isEditorReady:n()}},[e]);return Object(r.useEffect)(()=>{c&&!a&&t.dispatch(w.a).initializeMetaBoxes()},[c,a]),a?Object(r.createElement)(r.Fragment,null,Object(d.map)(n,({id:e})=>Object(r.createElement)(gs,{key:e,id:e})),o&&Object(r.createElement)(vs,{location:e})):null}var ys=n("xrib");function js({className:e,...t}){const{postTitle:n,shortcut:o,showIconLabels:a}=Object(b.useSelect)(e=>({postTitle:e("core/editor").getEditedPostAttribute("title"),shortcut:e(N.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),showIconLabels:e(w.a).isFeatureActive("showIconLabels")}));return Object(r.createElement)(L.b,Object(u.a)({panelClassName:e,className:"edit-post-sidebar",smallScreenTitle:n||Object(f.__)("(no title)"),scope:"core/edit-post",toggleShortcut:o,showIconLabels:a},t))}var Es=function(){const[e,t]=Object(r.useState)(!1),[n,a]=Object(r.useState)(""),{template:c,supportsTemplateMode:s,defaultTemplate:l}=Object(b.useSelect)(e=>{var t,n;const{getCurrentPostType:r,getEditorSettings:a}=e(i.store),{getPostType:c}=e(o.store),{getEditedPostTemplate:s}=e(w.a),l=null!==(t=null===(n=c(r()))||void 0===n?void 0:n.viewable)&&void 0!==t&&t,u=a().supportsTemplateMode&&l;return{template:u&&s(),supportsTemplateMode:u,defaultTemplate:a().defaultBlockTemplate}},[]),{__unstableSwitchToTemplateMode:u}=Object(b.useDispatch)(w.a);if(!s)return null;const v=Object(f.__)("Custom Template");return Object(r.createElement)(r.Fragment,null,Object(r.createElement)("div",{className:"edit-post-template__actions"},!!c&&Object(r.createElement)(m.Button,{isLink:!0,onClick:()=>u()},Object(f.__)("Edit")),Object(r.createElement)(m.Button,{isLink:!0,onClick:()=>t(!0)},Object(f.__)("New"))),e&&Object(r.createElement)(m.Modal,{title:Object(f.__)("Create custom template"),closeLabel:Object(f.__)("Close"),onRequestClose:()=>{t(!1),a("")},overlayClassName:"edit-post-template__modal"},Object(r.createElement)("form",{onSubmit:e=>{e.preventDefault();const r=null!=l?l:Object(p.serialize)([Object(p.createBlock)("core/group",{tagName:"header",layout:{inherit:!0}},[Object(p.createBlock)("core/site-title"),Object(p.createBlock)("core/site-tagline")]),Object(p.createBlock)("core/separator"),Object(p.createBlock)("core/group",{tagName:"main"},[Object(p.createBlock)("core/group",{layout:{inherit:!0}},[Object(p.createBlock)("core/post-title")]),Object(p.createBlock)("core/post-content",{layout:{inherit:!0}})])]);u({slug:"wp-custom-template-"+Object(d.kebabCase)(n||v),content:r,title:n||v}),t(!1)}},Object(r.createElement)(m.Flex,{align:"flex-start",gap:8},Object(r.createElement)(m.FlexItem,null,Object(r.createElement)(m.TextControl,{label:Object(f.__)("Name"),value:n,onChange:a,placeholder:v,help:Object(f.__)('Describe the purpose of the template, e.g. "Full Width". Custom templates can be applied to any post or page.')}))),Object(r.createElement)(m.Flex,{className:"edit-post-template__modal-actions",justify:"flex-end",expanded:!1},Object(r.createElement)(m.FlexItem,null,Object(r.createElement)(m.Button,{isTertiary:!0,onClick:()=>{t(!1),a("")}},Object(f.__)("Cancel"))),Object(r.createElement)(m.FlexItem,null,Object(r.createElement)(m.Button,{isPrimary:!0,type:"submit"},Object(f.__)("Create")))))))};var _s=function(){const{isEnabled:e,isOpened:t,selectedTemplate:n,availableTemplates:a,fetchedTemplates:c,isViewable:s,template:l,supportsTemplateMode:u}=Object(b.useSelect)(e=>{var t,n;const{isEditorPanelEnabled:r,isEditorPanelOpened:a,getEditedPostTemplate:c}=e(w.a),{getEditedPostAttribute:s,getEditorSettings:l,getCurrentPostType:u}=e(i.store),{getPostType:p,getEntityRecords:m}=e(o.store),b=null!==(t=null===(n=p(u()))||void 0===n?void 0:n.viewable)&&void 0!==t&&t,f=e(i.store).getEditorSettings().supportsTemplateMode&&b,v=m("postType","wp_template",{per_page:-1}),h=Object(d.fromPairs)((v||[]).map(({slug:e,title:t})=>[e,t.rendered]));return{isEnabled:r("template"),isOpened:a("template"),selectedTemplate:s("template"),availableTemplates:l().availableTemplates,fetchedTemplates:h,template:f&&c(),isViewable:b,supportsTemplateMode:f}},[]),p=Object(r.useMemo)(()=>({...a,...c}),[a,c]),{toggleEditorPanelOpened:v}=Object(b.useDispatch)(w.a),{editPost:h}=Object(b.useDispatch)(i.store);if(!e||!s||Object(d.isEmpty)(a)&&!u)return null;const g=Object(d.partial)(v,"template");let O=Object(f.__)("Template");var y;return l&&(O=Object(f.sprintf)(Object(f.__)("Template: %s"),null!==(y=null==l?void 0:l.title)&&void 0!==y?y:l.slug)),Object(r.createElement)(m.PanelBody,{title:O,opened:t,onToggle:g},Object(r.createElement)(m.SelectControl,{hideLabelFromVision:!0,label:Object(f.__)("Template:"),value:Object.keys(p).includes(n)?n:"",onChange:e=>{h({template:e||""})},options:Object(d.map)(p,(e,t)=>({value:t,label:e}))}),Object(r.createElement)(Es,null))},ws=n("iClF"),Ss=n("Civd");var xs=function(){const e=Object(b.useSelect)(e=>{const{getEditedPostTemplate:t}=e(w.a);return t()},[]);return e?Object(r.createElement)(m.PanelBody,null,Object(r.createElement)(m.Flex,{align:"flex-start"},Object(r.createElement)(m.FlexItem,null,Object(r.createElement)(ws.a,{icon:Ss.a})),Object(r.createElement)(m.FlexBlock,null,Object(r.createElement)("h2",{className:"edit-post-template-summary__title"},(null==e?void 0:e.title)||(null==e?void 0:e.slug)),Object(r.createElement)("p",null,null==e?void 0:e.description)))):null};const Ps=r.Platform.select({web:!0,native:!1});var Ts=()=>{const{sidebarName:e,keyboardShortcut:t,isTemplateMode:n}=Object(b.useSelect)(e=>{let t=e(L.g).getActiveComplementaryArea(w.a.name);["edit-post/document","edit-post/block"].includes(t)||(e(a.store).getBlockSelectionStart()&&(t="edit-post/block"),t="edit-post/document");return{sidebarName:t,keyboardShortcut:e(N.store).getShortcutRepresentation("core/edit-post/toggle-sidebar"),isTemplateMode:e(w.a).isEditingTemplate()}},[]);return Object(r.createElement)(js,{identifier:e,header:Object(r.createElement)(qc,{sidebarName:e}),closeLabel:Object(f.__)("Close settings"),headerClassName:"edit-post-sidebar__panel-tabs",title:Object(f.__)("Settings"),toggleShortcut:t,icon:zc.a,isActiveByDefault:Ps},!n&&"edit-post/document"===e&&Object(r.createElement)(r.Fragment,null,Object(r.createElement)(os,null),Object(r.createElement)(_s,null),Object(r.createElement)(ys.a.Slot,null),Object(r.createElement)(as,null),Object(r.createElement)(ps,null),Object(r.createElement)(cs,null),Object(r.createElement)(us,null),Object(r.createElement)(ds,null),Object(r.createElement)(ms,null),Object(r.createElement)(bs,null),Object(r.createElement)(Os,{location:"side"})),n&&"edit-post/document"===e&&Object(r.createElement)(xs,null),"edit-post/block"===e&&Object(r.createElement)(a.BlockInspector,null))};function ks({nonAnimatedSrc:e,animatedSrc:t}){return Object(r.createElement)("picture",{className:"edit-post-welcome-guide__image"},Object(r.createElement)("source",{srcSet:e,media:"(prefers-reduced-motion: reduce)"}),Object(r.createElement)("img",{src:t,width:"312",height:"240",alt:""}))}function Cs(){const{toggleFeature:e}=Object(b.useDispatch)(w.a);return Object(r.createElement)(m.Guide,{className:"edit-post-welcome-guide",contentLabel:Object(f.__)("Welcome to the block editor"),finishButtonText:Object(f.__)("Get started"),onFinish:()=>e("welcomeGuide"),pages:[{image:Object(r.createElement)(ks,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-canvas.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-canvas.gif"}),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(f.__)("Welcome to the block editor")),Object(r.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(f.__)("In the WordPress editor, each paragraph, image, or video is presented as a distinct “block†of content.")))},{image:Object(r.createElement)(ks,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-editor.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-editor.gif"}),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(f.__)("Make each block your own")),Object(r.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(f.__)("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(r.createElement)(ks,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-library.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-library.gif"}),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(f.__)("Get to know the block library")),Object(r.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(r.createInterpolateElement)(Object(f.__)("All of the blocks available to you live in the block library. You’ll find it wherever you see the <InserterIconImage /> icon."),{InserterIconImage:Object(r.createElement)("img",{alt:Object(f.__)("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(r.createElement)(ks,{nonAnimatedSrc:"https://s.w.org/images/block-editor/welcome-documentation.svg",animatedSrc:"https://s.w.org/images/block-editor/welcome-documentation.gif"}),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(f.__)("Learn how to use the block editor")),Object(r.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(f.__)("New to the block editor? Want to learn more about using it? "),Object(r.createElement)(m.ExternalLink,{href:Object(f.__)("https://wordpress.org/support/article/wordpress-editor/")},Object(f.__)("Here's a detailed guide."))))}]})}function As(){const{toggleFeature:e}=Object(b.useDispatch)(w.a);return Object(r.createElement)(m.Guide,{className:"edit-post-welcome-guide",contentLabel:Object(f.__)("Welcome to the template editor"),finishButtonText:Object(f.__)("Get started"),onFinish:()=>e("welcomeGuideTemplate"),pages:[{image:Object(r.createElement)(ks,{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(r.createElement)(r.Fragment,null,Object(r.createElement)("h1",{className:"edit-post-welcome-guide__heading"},Object(f.__)("Welcome to the template editor")),Object(r.createElement)("p",{className:"edit-post-welcome-guide__text"},Object(f.__)("Templates express the layout of the site. Customize all aspects of your posts and pages using the tools of blocks and patterns.")))}]})}function Ms(){const{isActive:e,isTemplateMode:t}=Object(b.useSelect)(e=>{const{isFeatureActive:t,isEditingTemplate:n}=e(w.a),r=n();return{isActive:t(r?"welcomeGuideTemplate":"welcomeGuide"),isTemplateMode:r}},[]);return e?t?Object(r.createElement)(As,null):Object(r.createElement)(Cs,null):null}const{Fill:Is,Slot:Bs}=Object(m.createSlotFill)("PluginPostPublishPanel"),Ls=Object(v.compose)(Object(y.withPluginContext)((e,t)=>({icon:t.icon||e.icon})))(({children:e,className:t,title:n,initialOpen:o=!1,icon:a})=>Object(r.createElement)(Is,null,Object(r.createElement)(m.PanelBody,{className:t,initialOpen:o||!n,title:n,icon:a},e)));Ls.Slot=Bs;var Ns=Ls;const{Fill:Rs,Slot:Ds}=Object(m.createSlotFill)("PluginPrePublishPanel"),Vs=Object(v.compose)(Object(y.withPluginContext)((e,t)=>({icon:t.icon||e.icon})))(({children:e,className:t,title:n,initialOpen:o=!1,icon:a})=>Object(r.createElement)(Rs,null,Object(r.createElement)(m.PanelBody,{className:t,initialOpen:o||!n,title:n,icon:a},e)));Vs.Slot=Ds;var Fs=Vs;const{Fill:Us,Slot:Gs}=Object(m.createSlotFill)("ActionsPanel");function Hs({setEntitiesSavedStatesCallback:e,closeEntitiesSavedStates:t,isEntitiesSavedStatesOpen:n}){const{closePublishSidebar:o,togglePublishSidebar:a}=Object(b.useDispatch)(w.a),{publishSidebarOpened:c,hasActiveMetaboxes:s,isSavingMetaBoxes:l,hasNonPostEntityChanges:u}=Object(b.useSelect)(e=>({publishSidebarOpened:e(w.a).isPublishSidebarOpened(),hasActiveMetaboxes:e(w.a).hasMetaBoxes(),isSavingMetaBoxes:e(w.a).isSavingMetaBoxes(),hasNonPostEntityChanges:e("core/editor").hasNonPostEntityChanges()}),[]),d=Object(r.useCallback)(()=>e(!0),[]);let p;return p=c?Object(r.createElement)(i.PostPublishPanel,{onClose:o,forceIsDirty:s,forceIsSaving:l,PrePublishExtension:Fs.Slot,PostPublishExtension:Ns.Slot}):u?Object(r.createElement)("div",{className:"edit-post-layout__toggle-entities-saved-states-panel"},Object(r.createElement)(m.Button,{isSecondary:!0,className:"edit-post-layout__toggle-entities-saved-states-panel-button",onClick:d,"aria-expanded":!1},Object(f.__)("Open save panel"))):Object(r.createElement)("div",{className:"edit-post-layout__toggle-publish-panel"},Object(r.createElement)(m.Button,{isSecondary:!0,className:"edit-post-layout__toggle-publish-panel-button",onClick:a,"aria-expanded":!1},Object(f.__)("Open publish panel"))),Object(r.createElement)(r.Fragment,null,n&&Object(r.createElement)(i.EntitiesSavedStates,{close:t}),Object(r.createElement)(Gs,{bubblesVirtually:!0}),!n&&p)}const zs={secondarySidebar:Object(f.__)("Block library"),header:Object(f.__)("Editor top bar"),body:Object(f.__)("Editor content"),sidebar:Object(f.__)("Editor settings"),actions:Object(f.__)("Editor publish"),footer:Object(f.__)("Editor footer")};var qs=function({styles:e}){const t=Object(v.useViewportMatch)("medium","<"),n=Object(v.useViewportMatch)("huge",">="),{openGeneralSidebar:o,closeGeneralSidebar:c,setIsInserterOpened:s}=Object(b.useDispatch)(w.a),{mode:l,isFullscreenActive:u,isRichEditingEnabled:d,sidebarIsOpened:p,hasActiveMetaboxes:h,hasFixedToolbar:g,previousShortcut:O,nextShortcut:j,hasBlockSelected:E,isInserterOpened:_,isListViewOpened:S,showIconLabels:x,hasReducedUI:P,showBlockBreadcrumbs:T,isTemplateMode:k}=Object(b.useSelect)(e=>{const t=e(i.store).getEditorSettings();return{isTemplateMode:e(w.a).isEditingTemplate(),hasFixedToolbar:e(w.a).isFeatureActive("fixedToolbar"),sidebarIsOpened:!(!e(L.g).getActiveComplementaryArea(w.a.name)&&!e(w.a).isPublishSidebarOpened()),isFullscreenActive:e(w.a).isFeatureActive("fullscreenMode"),isInserterOpened:e(w.a).isInserterOpened(),isListViewOpened:e(w.a).isListViewOpened(),mode:e(w.a).getEditorMode(),isRichEditingEnabled:t.richEditingEnabled,hasActiveMetaboxes:e(w.a).hasMetaBoxes(),previousShortcut:e(N.store).getAllShortcutRawKeyCombinations("core/edit-post/previous-region"),nextShortcut:e(N.store).getAllShortcutRawKeyCombinations("core/edit-post/next-region"),showIconLabels:e(w.a).isFeatureActive("showIconLabels"),hasReducedUI:e(w.a).isFeatureActive("reducedUI"),showBlockBreadcrumbs:e(w.a).isFeatureActive("showBlockBreadcrumbs")}},[]),C=B()("edit-post-layout","is-mode-"+l,{"is-sidebar-opened":p,"has-fixed-toolbar":g,"has-metaboxes":h,"show-icon-labels":x});Object(r.useEffect)(()=>{p&&!n&&s(!1)},[p,n]),Object(r.useEffect)(()=>{_&&!n&&c()},[_,n]);const[A,M]=Object(r.useState)(!1),I=Object(r.useCallback)(e=>{"function"==typeof A&&A(e),M(!1)},[A]);return Object(r.createElement)(r.Fragment,null,Object(r.createElement)(L.d,{isActive:u}),Object(r.createElement)(dc,null),Object(r.createElement)(i.UnsavedChangesWarning,null),Object(r.createElement)(i.AutosaveMonitor,null),Object(r.createElement)(i.LocalAutosaveMonitor,null),Object(r.createElement)(qi,null),Object(r.createElement)(i.EditorKeyboardShortcutsRegister,null),Object(r.createElement)(Ts,null),Object(r.createElement)(L.e,{className:C,labels:zs,header:Object(r.createElement)(Vc,{setEntitiesSavedStatesCallback:M}),secondarySidebar:"visual"===l&&_?Object(r.createElement)(Uc,null):"visual"===l&&S?Object(r.createElement)(b.AsyncModeProvider,{value:"true"},Object(r.createElement)(Hc,null)):null,sidebar:(!t||p)&&Object(r.createElement)(r.Fragment,null,!t&&!p&&Object(r.createElement)("div",{className:"edit-post-layout__toggle-sidebar-panel"},Object(r.createElement)(m.Button,{isSecondary:!0,className:"edit-post-layout__toggle-sidebar-panel-button",onClick:()=>o(E?"edit-post/block":"edit-post/document"),"aria-expanded":!1},E?Object(f.__)("Open block settings"):Object(f.__)("Open document settings"))),Object(r.createElement)(L.b.Slot,{scope:"core/edit-post"})),notices:Object(r.createElement)(i.EditorSnackbars,null),content:Object(r.createElement)(r.Fragment,null,Object(r.createElement)(i.EditorNotices,null),("text"===l||!d)&&Object(r.createElement)(R,null),d&&"visual"===l&&Object(r.createElement)(zi,{styles:e}),!k&&Object(r.createElement)("div",{className:"edit-post-layout__metaboxes"},Object(r.createElement)(Os,{location:"normal"}),Object(r.createElement)(Os,{location:"advanced"})),t&&p&&Object(r.createElement)(m.ScrollLock,null)),footer:!P&&T&&!t&&d&&"visual"===l&&Object(r.createElement)("div",{className:"edit-post-layout__footer"},Object(r.createElement)(a.BlockBreadcrumb,null)),actions:Object(r.createElement)(Hs,{closeEntitiesSavedStates:I,isEntitiesSavedStatesOpen:A,setEntitiesSavedStatesCallback:M}),shortcuts:{previous:O,next:j}}),Object(r.createElement)(ac,null),Object(r.createElement)(lc,null),Object(r.createElement)(ec,null),Object(r.createElement)(Ms,null),Object(r.createElement)(m.Popover.Slot,null),Object(r.createElement)(y.PluginArea,null))},Ws=n("0dt7");function Ys({postId:e}){return(e=>{const{hasBlockSelection:t,isEditorSidebarOpened:n}=Object(b.useSelect)(e=>({hasBlockSelection:!!e("core/block-editor").getBlockSelectionStart(),isEditorSidebarOpened:e(Ws.a).isEditorSidebarOpened()}),[e]),{openGeneralSidebar:o}=Object(b.useDispatch)(Ws.a);Object(r.useEffect)(()=>{n&&o(t?"edit-post/block":"edit-post/document")},[t,n])})(e),(e=>{const{newPermalink:t}=Object(b.useSelect)(e=>({newPermalink:e("core/editor").getCurrentPost().link}),[e]),n=Object(r.useRef)();Object(r.useEffect)(()=>{n.current=document.querySelector(Ws.c)||document.querySelector(Ws.b)},[e]),Object(r.useEffect)(()=>{t&&n.current&&n.current.setAttribute("href",t)},[t])})(e),null}var Xs=function({postId:e,postType:t,settings:n,initialEdits:o,onError:a,...c}){const{hasFixedToolbar:s,focusMode:l,hasReducedUI:f,hasThemeStyles:v,post:h,preferredStyleVariations:g,hiddenBlockTypes:O,blockTypes:y,__experimentalLocalAutosaveInterval:j,keepCaretInsideBlock:E,isTemplateMode:_,template:S}=Object(b.useSelect)(n=>{var r,o;const{isFeatureActive:a,getPreference:i,__experimentalGetPreviewDeviceType:c,isEditingTemplate:s,getEditedPostTemplate:l}=n(w.a),{getEntityRecord:u,getPostType:d,getEntityRecords:m}=n("core"),{getEditorSettings:b}=n("core/editor"),{getBlockTypes:f}=n(p.store);let v;if(["wp_template","wp_template_part"].includes(t)){const n=m("postType",t,{wp_id:e});v=null==n?void 0:n[0]}else v=u("postType",t,e);const h=b().supportsTemplateMode,g=null!==(r=null===(o=d(t))||void 0===o?void 0:o.viewable)&&void 0!==r&&r;return{hasFixedToolbar:a("fixedToolbar")||"Desktop"!==c(),focusMode:a("focusMode"),hasReducedUI:a("reducedUI"),hasThemeStyles:a("themeStyles"),preferredStyleVariations:i("preferredStyleVariations"),hiddenBlockTypes:i("hiddenBlockTypes"),blockTypes:f(),__experimentalLocalAutosaveInterval:i("localAutosaveInterval"),keepCaretInsideBlock:a("keepCaretInsideBlock"),isTemplateMode:s(),template:h&&g?l():null,post:v}}),{updatePreferredStyleVariations:x,setIsInserterOpened:P}=Object(b.useDispatch)(w.a),T=Object(r.useMemo)(()=>{const e={...Object(d.omit)(n,["styles"]),__experimentalPreferredStyleVariations:{value:g,onChange:x},hasFixedToolbar:s,focusMode:l,hasReducedUI:f,__experimentalLocalAutosaveInterval:j,__experimentalSetIsInserterOpened:P,keepCaretInsideBlock:E};if(Object(d.size)(O)>0){const t=!0===n.allowedBlockTypes?Object(d.map)(y,"name"):n.allowedBlockTypes||[];e.allowedBlockTypes=Object(d.without)(t,...O)}return e},[n,s,l,f,O,y,g,j,P,x,E]),k=Object(r.useMemo)(()=>v?n.styles:[],[n,v]);return h?Object(r.createElement)(r.StrictMode,null,Object(r.createElement)(nc.Provider,{value:n},Object(r.createElement)(m.SlotFillProvider,null,Object(r.createElement)(i.EditorProvider,Object(u.a)({settings:T,post:h,initialEdits:o,useSubRegistry:!1,__unstableTemplate:_?S:void 0},c),Object(r.createElement)(i.ErrorBoundary,{onError:a},Object(r.createElement)(Ys,{postId:e}),Object(r.createElement)(qs,{styles:k}),Object(r.createElement)(m.KeyboardShortcuts,{shortcuts:M})),Object(r.createElement)(i.PostLockedModal,null))))):null};const Ks=(e,t)=>{return!Array.isArray(t)||(n=e,r=t,0===Object(d.difference)(n,r).length);var n,r};var Zs=({allowedBlocks:e,icon:t,label:n,onClick:o,small:i,role:c})=>Object(r.createElement)(a.BlockSettingsMenuControls,null,({selectedBlocks:a,onClose:s})=>Ks(a,e)?Object(r.createElement)(m.MenuItem,{onClick:Object(v.compose)(o,s),icon:t,label:i?n:void 0,role:c},!i&&n):null),Qs=Object(v.compose)(Object(y.withPluginContext)((e,t)=>({icon:t.icon||e.icon,name:"core/edit-post/plugin-more-menu"})))(L.a);function $s(e){return Object(r.createElement)(L.c,Object(u.a)({__unstableExplicitMenuItem:!0,scope:"core/edit-post"},e))}function Js(e,t,n,o,a){Object(r.unmountComponentAtNode)(n);const i=Js.bind(null,e,t,n,o,a);Object(r.render)(Object(r.createElement)(Xs,{settings:o,onError:i,postId:t,postType:e,initialEdits:a,recovery:!0}),n)}function el(e,t,n,o,a){const i=document.getElementById(e),s=Js.bind(null,t,n,i,o,a);Object(c.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(r.render)(Object(r.createElement)(Xs,{settings:o,onError:s,postId:n,postType:t,initialEdits:a}),i)}},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 r=n("GRId");t.a=function({icon:e,size:t=24,...n}){return Object(r.cloneElement)(e,{width:t,height:t,...n})}},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 r,o;function a(e){return[e]}function i(){var e={clear:function(){e.head=null}};return e}function c(e,t,n){var r;if(e.length!==t.length)return!1;for(r=n;r<e.length;r++)if(e[r]!==t[r])return!1;return!0}r={},o="undefined"!=typeof WeakMap,t.a=function(e,t){var n,s;function l(){n=o?new WeakMap:i()}function u(){var n,r,o,a,i,l=arguments.length;for(a=new Array(l),o=0;o<l;o++)a[o]=arguments[o];for(i=t.apply(null,a),(n=s(i)).isUniqueByDependants||(n.lastDependants&&!c(i,n.lastDependants,0)&&n.clear(),n.lastDependants=i),r=n.head;r;){if(c(r.args,a,1))return r!==n.head&&(r.prev.next=r.next,r.next&&(r.next.prev=r.prev),r.next=n.head,r.prev=null,n.head.prev=r,n.head=r),r.val;r=r.next}return r={val:e.apply(null,a)},a[0]=null,r.args=a,n.head&&(n.head.prev=r,r.next=n.head),n.head=r,r.val}return t||(t=a),s=o?function(e){var t,o,a,c,s,l=n,u=!0;for(t=0;t<e.length;t++){if(o=e[t],!(s=o)||"object"!=typeof s){u=!1;break}l.has(o)?l=l.get(o):(a=new WeakMap,l.set(o,a),l=a)}return l.has(r)||((c=i()).isUniqueByDependants=u,l.set(r,c)),l.get(r)}:function(){return n},u.getDependants=t,u.clear=l,l(),u}},"tI+e":function(e,t){e.exports=window.wp.components},w95h:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(r.createElement)(o.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=a},wduq:function(e,t,n){"use strict";var r=n("GRId"),o=n("Tqx9");const a=Object(r.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(r.createElement)(o.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=a},wx14:function(e,t,n){"use strict";function r(){return(r=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}n.d(t,"a",(function(){return r}))},xrib:function(e,t,n){"use strict";(function(e){var r=n("GRId"),o=n("tI+e"),a=n("K9lf"),i=n("TvNi"),c=n("1ZqX"),s=(n("Z23Y"),n("Y5n4")),l=n("T40v");const{Fill:u,Slot:d}=Object(o.createSlotFill)("PluginDocumentSettingPanel"),p=Object(a.compose)(Object(i.withPluginContext)((t,n)=>(void 0===n.name&&void 0!==e&&e.env,{icon:n.icon||t.icon,panelName:`${t.name}/${n.name}`})),Object(c.withSelect)((e,{panelName:t})=>({opened:e(l.a).isEditorPanelOpened(t),isEnabled:e(l.a).isEditorPanelEnabled(t)})),Object(c.withDispatch)((e,{panelName:t})=>({onToggle:()=>e(l.a).toggleEditorPanelOpened(t)})))(({isEnabled:e,panelName:t,opened:n,onToggle:a,className:i,title:c,icon:l,children:d})=>Object(r.createElement)(r.Fragment,null,Object(r.createElement)(s.d,{label:c,panelName:t}),Object(r.createElement)(u,null,e&&Object(r.createElement)(o.PanelBody,{className:i,title:c,icon:l,opened:n,onToggle:a},d))));p.Slot=d,t.a=p}).call(this,n("8oxB"))}});