sirius-press/wordpress/wp-includes/js/dist/editor.min.js

558 lines
1.5 MiB
JavaScript
Raw Normal View History

/*! This file is auto-generated */
(function() {
"use strict";var wp;(wp||={}).editor=(()=>{var wNe=Object.create;var Tk=Object.defineProperty;var _Ne=Object.getOwnPropertyDescriptor;var SNe=Object.getOwnPropertyNames;var xNe=Object.getPrototypeOf,CNe=Object.prototype.hasOwnProperty;var ra=(e=>typeof require<"u"?require:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof require<"u"?require:t)[r]}):e)(function(e){if(typeof require<"u")return require.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')});var Qe=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports),Yr=(e,t)=>{for(var r in t)Tk(e,r,{get:t[r],enumerable:!0})},nZ=(e,t,r,o)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of SNe(t))!CNe.call(e,n)&&n!==r&&Tk(e,n,{get:()=>t[n],enumerable:!(o=_Ne(t,n))||o.enumerable});return e};var a=(e,t,r)=>(r=e!=null?wNe(xNe(e)):{},nZ(t||!e||!e.__esModule?Tk(r,"default",{value:e,enumerable:!0}):r,e)),ENe=e=>nZ(Tk({},"__esModule",{value:!0}),e);var Y=Qe((kdt,iZ)=>{iZ.exports=window.wp.data});var ae=Qe((Rdt,sZ)=>{sZ.exports=window.wp.coreData});var U=Qe((Adt,aZ)=>{aZ.exports=window.wp.element});var Ce=Qe((Idt,lZ)=>{lZ.exports=window.wp.compose});var zn=Qe((Odt,cZ)=>{cZ.exports=window.wp.hooks});var be=Qe((Ndt,uZ)=>{uZ.exports=window.wp.blockEditor});var Pt=Qe((Bdt,vZ)=>{vZ.exports=window.wp.blocks});var cn=Qe((jdt,bZ)=>{bZ.exports=window.wp.date});var vo=Qe((zdt,yZ)=>{yZ.exports=window.wp.url});var qa=Qe((Hdt,wZ)=>{wZ.exports=window.wp.deprecated});var Lt=Qe((Udt,_Z)=>{_Z.exports=window.wp.preferences});var _e=Qe((Ydt,TZ)=>{TZ.exports=window.wp.primitives});var T=Qe((qdt,PZ)=>{PZ.exports=window.ReactJSXRuntime});var xf=Qe((Cht,kZ)=>{kZ.exports=window.wp.privateApis});var h8=Qe((Mht,OZ)=>{OZ.exports=window.wp.styleEngine});var j=Qe((Yht,VZ)=>{VZ.exports=window.wp.i18n});var y2=Qe((qht,BZ)=>{"use strict";BZ.exports=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var o,n,i;if(Array.isArray(t)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t instanceof Map&&r instanceof Map){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;for(n of t.entries())if(!e(n[1],r.get(n[0])))return!1;return!0}if(t instanceof Set&&r instanceof Set){if(t.size!==r.size)return!1;for(n of t.entries())if(!r.has(n[0]))return!1;return!0}if(ArrayBuffer.isView(t)&&ArrayBuffer.isView(r)){if(o=t.length,o!=r.length)return!1;for(n=o;n--!==0;)if(t[n]!==r[n])return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(i=Object.keys(t),o=i.length,o!==Object.keys(r).length)return!1;for(n=o;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,i[n]))return!1;for(n=o;n--!==0;){var s=i[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}});var w2=Qe((Zht,HZ)=>{"use strict";var dMe=function(t){return fMe(t)&&!pMe(t)};function fMe(e){return!!e&&typeof e=="object"}function pMe(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||gMe(e)}var mMe=typeof Symbol=="function"&&Symbol.for,hMe=mMe?Symbol.for("react.element"):60103;function gMe(e){return e.$$typeof===hMe}function vMe(e){return Array.isArray(e)?[]:{}}function O1(e,t){return t.clone!==!1&&t.isMergeableObject(e)?b0(vMe(e),e,t):e}function bMe(e,t,r){return e.concat(t).map(function(o){return O1(o,r)})}function yMe(e,t){if(!t.customMerge)return b0;var r=t.customMerge(e);return typeof r=="function"?r:b0}function wMe(e){return Object.getOwnPropertySymbols?Object.getOwnPropertySymbols(e).filter(function(t){return Object.propertyIsEnumerable.call(e,t)}):[]}function jZ(e){return Object.keys(e).concat(wMe(e))}function zZ(e,t){try{return t in e}catch{return!1}}function _Me(e,t){return zZ(e,t)&&!(Object.hasOwnProperty.call(e,t)&&Object.propertyIsEnumerable.call(e,t))}function SMe(e,t,r){var o={};return r.isMergeableObject(e)&&jZ(e).forEach(function(n){o[n]=O1(e[n],r)}),jZ(t).forEach
<svg
xmlns:xlink="http://www.w3.org/1999/xlink"
viewBox="0 0 0 0"
width="0"
height="0"
focusable="false"
role="none"
aria-hidden="true"
style="visibility: hidden; position: absolute; left: -9999px; overflow: hidden;"
>
<defs>
<filter id="${e}">
<!--
Use sRGB instead of linearRGB so transparency looks correct.
Use perceptual brightness to convert to grayscale.
-->
<feColorMatrix color-interpolation-filters="sRGB" type="matrix" values=" .299 .587 .114 0 0 .299 .587 .114 0 0 .299 .587 .114 0 0 .299 .587 .114 0 0 "></feColorMatrix>
<!-- Use sRGB instead of linearRGB to be consistent with how CSS gradients work. -->
<feComponentTransfer color-interpolation-filters="sRGB">
<feFuncR type="table" tableValues="${r.r.join(" ")}"></feFuncR>
<feFuncG type="table" tableValues="${r.g.join(" ")}"></feFuncG>
<feFuncB type="table" tableValues="${r.b.join(" ")}"></feFuncB>
<feFuncA type="table" tableValues="${r.a.join(" ")}"></feFuncA>
</feComponentTransfer>
<!-- Re-mask the image with the original transparency since the feColorMatrix above loses that information. -->
<feComposite in2="SourceGraphic" operator="in"></feComposite>
</filter>
</defs>
</svg>`}function ym(e){return e.replace(/([a-z])([A-Z])/g,"$1-$2").replace(/([0-9])([a-zA-Z])/g,"$1-$2").replace(/([a-zA-Z])([0-9])/g,"$1-$2").replace(/[\s_]+/g,"-").toLowerCase()}function E8(e){if(!e)return;let t=e.match(/var:preset\|spacing\|(.+)/);return t?`var(--wp--preset--spacing--${t[1]})`:e}function DMe(e){if(!e)return null;let t=typeof e=="string";return{top:t?e:e?.top,left:t?e:e?.left}}function T8(e,t="0"){let r=DMe(e);if(!r)return null;let o=E8(r?.top)||t,n=E8(r?.left)||t;return o===n?o:`${o} ${n}`}var sX={backgroundSize:"cover",backgroundPosition:"50% 50%"};function aX(e){if(!e||!e?.backgroundImage?.url)return;let t;return e?.backgroundSize||(t={backgroundSize:sX.backgroundSize}),e?.backgroundSize==="contain"&&!e?.backgroundPosition&&(t={backgroundPosition:sX.backgroundPosition}),t}var lX={default:{name:"default",slug:"flow",className:"is-layout-flow",baseStyles:[{selector:" > .alignleft",rules:{float:"left","margin-inline-start":"0","margin-inline-end":"2em"}},{selector:" > .alignright",rules:{float:"right","margin-inline-start":"2em","margin-inline-end":"0"}},{selector:" > .aligncenter",rules:{"margin-left":"auto !important","margin-right":"auto !important"}}],spacingStyles:[{selector:" > :first-child",rules:{"margin-block-start":"0"}},{selector:" > :last-child",rules:{"margin-block-end":"0"}},{selector:" > *",rules:{"margin-block-start":null,"margin-block-end":"0"}}]},constrained:{name:"constrained",slug:"constrained",className:"is-layout-constrained",baseStyles:[{selector:" > .alignleft",rules:{float:"left","margin-inline-start":"0","margin-inline-end":"2em"}},{selector:" > .alignright",rules:{float:"right","margin-inline-start":"2em","margin-inline-end":"0"}},{selector:" > .aligncenter",rules:{"margin-left":"auto !important","margin-right":"auto !important"}},{selector:" > :where(:not(.alignleft):not(.alignright):not(.alignfull))",rules:{"max-width":"var(--wp--style--global--content-size)","margin-left":"auto !important","margin-right":"auto !important"}},{selector:" > .alignwide",rules:{"max-width":"var(--wp--style--global--wide-size)"}}],spacingStyles:[{selector:" > :first-child",rules:{"margin-block-start":"0"}},{selector:" > :last-child",rules:{"margin-block-end":"0"}},{selector:" > *",rules:{"margin-block-start":null,"margin-block-end":"0"}}]},flex:{name:"flex",slug:"flex",className:"is-layout-flex",displayMode:"flex",baseStyles:[{selector:"",rules:{"flex-wrap":"wrap","align-items":"center"}},{selector:" > :is(*, div)",rules:{margin:"0"}}],spacingStyles:[{selector:"",rules:{gap:null}}]},grid:{name:"grid",slug:"grid",className:"is-layout-grid",displayMode:"grid",baseStyles:[{selector:" > :is(*, div)",rules:{margin:"0"}}],spacingStyles:[{selector:"",rules:{gap:null}}]}};var cX={mobile:"480px",tablet:"782px"},uX=/^(\d+|\d*\.\d+)(px|em|rem)$/,LMe=16;function VMe(e){return"mobile"in e||"tablet"in e}function BMe(e){return!e||typeof e!="object"?{}:VMe(e)?e:e.settings?.viewport??{}}function jMe(e){return typeof e=="string"&&uX.test(e.trim())}function P8(e){if(typeof e=="number")return e;if(typeof e!="string")return;let t=e.trim().match(uX);if(!t)return;let r=Number.parseFloat(t[1]);return t[2]==="px"?r:r*LMe}function k8(e){let t=BMe(e),r={},o={};Object.keys(cX).forEach(l=>{let c=l,u=t[c],d=P8(u);d!==void 0&&jMe(u)&&(r[c]=u.trim(),o[c]=d)});let n=Object.keys(r);if(!n.length)return{...cX};if(n.length===1)return r;let i=r.mobile,s=r.tablet;return o.mobile>=o.tablet?{mobile:i}:{mobile:i,tablet:s}}function F1(e){let t=k8(e),r={};return t.mobile&&(r["@mobile"]=`@media (width <= ${t.mobile})`),t.tablet&&(r["@tablet"]=t.mobile?`@media (${t.mobile} < width <= ${t.tablet})`:`@media (width <= ${t.tablet})`),r}var zMe={button:"wp-element-button",caption:"wp-element-caption"},HMe={__experimentalBorder:"border",color:"color",dimensions:"dimensions",spacing:"spacing",typography:"typography"},pX={"core/button":[":hover",":focus",":focus-visible",":active"],"core/navigation-link":[":hover",":focus",":focus-visible",":active"]},UMe={link:[":link",":any-link",":visited",":hover",":focus",":focus-visible",":active"],button:["
.has-global-padding { padding-right: var(--wp--style--root--padding-right); padding-left: var(--wp--style--root--padding-left); }
.has-global-padding > .alignfull { margin-right: calc(var(--wp--style--root--padding-right) * -1); margin-left: calc(var(--wp--style--root--padding-left) * -1); }
.has-global-padding :where(:not(.alignfull.is-layout-flow) > .has-global-padding:not(.wp-block-block, .alignfull)) { padding-right: 0; padding-left: 0; }
.has-global-padding :where(:not(.alignfull.is-layout-flow) > .has-global-padding:not(.wp-block-block, .alignfull)) > .alignfull { margin-left: 0; margin-right: 0;
`),v+="}"),l.blockStyles){let b=F1(e);u.forEach(_=>{if(_.isStyleVariation&&!l.variationStyles)return;let y=JMe(_,b);[_,...y,...dX(_),...y.flatMap(dX)].forEach(w=>{v+=o3e(w,{tree:c,useRootPaddingAlign:f,disableLayoutStyles:n,hasBlockGapSupport:r,hasFallbackGapSupport:o,disableRootPadding:i})})})}if(l.layoutStyles&&(v=v+".wp-site-blocks > .alignleft { float: left; margin-right: 2em; }",v=v+".wp-site-blocks > .alignright { float: right; margin-left: 2em; }",v=v+".wp-site-blocks > .aligncenter { justify-content: center; margin-left: auto; margin-right: auto; }"),l.blockGap&&r){let b=T8(c?.styles?.spacing?.blockGap)||"0.5em";v=v+`:root :where(.wp-site-blocks) > * { margin-block-start: ${b}; margin-block-end: 0; }`,v=v+":root :where(.wp-site-blocks) > :first-child { margin-block-start: 0; }",v=v+":root :where(.wp-site-blocks) > :last-child { margin-block-end: 0; }"}return l.presets&&d.forEach(({selector:b,presets:_})=>{(Lu===b||A1===b)&&(b="");let y=WMe(b,_);y.length>0&&(v+=y)}),v};function i3e(e,t){return A8(e,t).flatMap(({presets:o})=>GMe(o))}var s3e=(e,t)=>{if(e?.selectors&&Object.keys(e.selectors).length>0)return e.selectors;let r={root:t};return Object.entries(HMe).forEach(([o,n])=>{let i=y0(e,o);i&&(r[n]=i)}),r},a3e=(e,t)=>{let{getBlockStyles:r}=(0,fX.select)(Li.store),o={};return e.forEach(n=>{let i=n.name,s=y0(n);if(!s)return;let l=y0(n,"filter.duotone");if(!l){let h=y0(n),g=(0,Li.getBlockSupport)(n,"color.__experimentalDuotone",!1);typeof g=="string"&&h&&(l=Tc(h,g))}let c=!!n?.supports?.layout||!!n?.supports?.__experimentalLayout,u=n?.supports?.spacing?.blockGap?.__experimentalDefault,d=r(i),f={};d?.forEach(h=>{let g=t?`-${t}`:"",v=`${h.name}${g}`,b=v8(v,s);f[v]=b});let m=s3e(n,s);o[i]={duotoneSelector:l??void 0,fallbackGapValue:u,featureSelectors:Object.keys(m).length?m:void 0,hasLayoutSupport:c,name:i,selector:s,styleVariationSelectors:d?.length?f:void 0}}),o};function l3e(e){let t=e.styles?.blocks,r=t?.["core/separator"];return r&&r.color?.background&&!r.color?.text&&!r.border?.color?{...e,styles:{...e.styles,blocks:{...t,"core/separator":{...r,color:{...r.color,text:r.color?.background}}}}}:e}function hX(e,t){let r="";return!e||e.trim()===""||e.split("&").forEach(n=>{if(!n||n.trim()==="")return;if(!n.includes("{"))r+=`:root :where(${t}){${n.trim()}}`;else{let s=n.replace("}","").split("{");if(s.length!==2)return;let[l,c]=s,u=l.match(/([>+~\s]*::[a-zA-Z-]+)/),d=u?u[1]:"",f=u?l.replace(d,"").trim():l.trim(),m;f===""?m=t:m=l.startsWith(" ")?Tc(t,f):b2(t,f),r+=`:root :where(${m})${d}{${c.trim()}}`}}),r}function wv(e={},t=[],r={}){let{hasBlockGapSupport:o,hasFallbackGapSupport:n,disableLayoutStyles:i=!1,disableRootPadding:s=!1,styleOptions:l={}}=r,c=t.length>0?t:(0,Li.getBlockTypes)(),u=vv(e,"spacing.blockGap"),d=o??u!==null,f=n??!d;if(!e?.styles||!e?.settings)return[[],{}];let m=l3e(e),h=a3e(c),g=r3e(m,h),v=n3e(m,h,d,f,i,s,l),b=i3e(m,h),_=[{css:g,isGlobalStyles:!0},{css:v,isGlobalStyles:!0},{css:m?.styles?.css??"",isGlobalStyles:!0},{assets:b,__unstableType:"svgs",isGlobalStyles:!0}];return c.forEach(y=>{let w=m?.styles?.blocks?.[y.name];if(w?.css){let{featureSelectors:S}=h[y.name],x=typeof S=="object"?S?.css:void 0,C;typeof x=="string"?C=x:typeof x=="object"&&(C=x?.root);let A=C??h[y.name].selector;_.push({css:hX(w.css,A),isGlobalStyles:!0})}}),[_,m.settings]}function P2(e,t,r,{resolveRefs:o=!0}={}){if(!e?.styles?.blocks?.[t]?.variations?.[r])return;let n=s=>{Object.keys(s).forEach(l=>{let c=s[l];if(typeof c=="object"&&c!==null)if(c.ref!==void 0)if(typeof c.ref!="string"||c.ref.trim()==="")delete s[l];else{let u=Ht(e,c.ref);u!=null?s[l]=u:delete s[l]}else n(c),Object.keys(c).length===0&&delete s[l]})},i=JSON.parse(JSON.stringify(e.styles.blocks[t].variations[r]));return o&&n(i),i}var N8="default";function yX(e){let t=e?.viewport,r=e?.pseudoState;return(!t||t===N8)&&(!r||r===N8)}function c3e(e){return yX(e)?[]:[e.viewport,e.pseudoState].filter(t=>!!t&&t!==N8)}function u3e(e,t){let r=c3e(t);return r.length?Ht(e,r):e}var d3e=new Set(["blocks","variations","css"]),I8=Object.freeze({value:{},sources:{}}),f3e={root:{l
`)}catch{return""}}var{getViewportBreakpoints:TX,getViewportBreakpointValueInPixels:L1}=q(Vu),w3e={Tablet:"tablet",Mobile:"mobile"},_3e="Desktop",PX="Tablet",S3e="Mobile",x3e=1,R2={Desktop:"default",Tablet:"@tablet",Mobile:"@mobile"};function A2(e,t){let r=L1(e),o=TX(t);return r&&r<=L1(o.mobile)?S3e:r&&r<=L1(o.tablet)?PX:_3e}function kX(e,t){let r=w3e[e];if(!r)return;let o=TX(t),n=L1(o[r]);if(n===void 0)return;let i=0;e===PX&&(i=L1(o.mobile)??0);let s=Math.min(x3e,(n-i)/2);return n-s}var j1={},C3e=(0,Jt.createRegistrySelector)(e=>()=>e(yo.store).hasUndo()),E3e=(0,Jt.createRegistrySelector)(e=>()=>e(yo.store).hasRedo());function RX(e){return Tn(e).status==="auto-draft"}function AX(e){return"content"in z1(e)}var I2=(0,Jt.createRegistrySelector)(e=>t=>{let r=oa(t),o=na(t);return e(yo.store).hasEditsForEntityRecord("postType",r,o)}),T3e=(0,Jt.createRegistrySelector)(e=>t=>{let r=e(yo.store).__experimentalGetDirtyEntityRecords(),{type:o,id:n}=Tn(t);return r.some(i=>i.kind!=="postType"||i.name!==o||i.key!==n)});function P3e(e){return!I2(e)&&RX(e)}var Tn=(0,Jt.createRegistrySelector)(e=>t=>{let r=na(t),o=oa(t),n=e(yo.store).getRawEntityRecord("postType",o,r);return n||j1});function oa(e){return e.postType}function na(e){return e.postId}function k3e(e){return e.templateId}function F8(e){return Tn(e)._links?.["version-history"]?.[0]?.count??0}function R3e(e){return Tn(e)._links?.["predecessor-version"]?.[0]?.id??null}var z1=(0,Jt.createRegistrySelector)(e=>t=>{let r=oa(t),o=na(t);return e(yo.store).getEntityRecordEdits("postType",r,o)||j1});function V1(e,t){switch(t){case"type":return oa(e);case"id":return na(e);default:let r=Tn(e);if(!r.hasOwnProperty(t))break;return Pk(r[t])}}var A3e=(0,Jt.createSelector)((e,t)=>{let r=z1(e);return r.hasOwnProperty(t)?{...V1(e,t),...r[t]}:V1(e,t)},(e,t)=>[V1(e,t),z1(e)[t]]);function oo(e,t){if(t==="content")return H1(e);let r=z1(e);return r.hasOwnProperty(t)?SZ.has(t)?A3e(e,t):r[t]:V1(e,t)}var IX=(0,Jt.createRegistrySelector)(e=>(t,r)=>{if(!CZ.includes(r)&&r!=="preview_link")return;let o=oa(t),n=na(t),i=e(yo.store).getCurrentUser()?.id,s=e(yo.store).getAutosave(o,n,i);if(s)return Pk(s[r])});function I3e(e){return oo(e,"status")==="private"?"private":oo(e,"password")?"password":"public"}function O3e(e){return Tn(e).status==="pending"}function D8(e,t){let r=t||Tn(e);return["publish","private"].indexOf(r.status)!==-1||r.status==="future"&&!(0,w0.isInTheFuture)(new Date(Number((0,w0.getDate)(r.date))-j4))}function N3e(e){return Tn(e).status==="future"&&!D8(e)}function M3e(e){let t=Tn(e);return t.type===kl?I2(e):I2(e)||["publish","private","future"].indexOf(t.status)===-1}function OX(e){return _0(e)?!1:!!oo(e,"title")||!!oo(e,"excerpt")||!NX(e)}var NX=(0,Jt.createRegistrySelector)(e=>t=>{let r=na(t),o=oa(t),n=e(yo.store).getEditedEntityRecord("postType",o,r);if(typeof n.content!="function")return!n.content;let i=oo(t,"blocks");if(i.length===0)return!0;if(i.length>1)return!1;let s=i[0].name;return s!==(0,xm.getDefaultBlockName)()&&s!==(0,xm.getFreeformContentHandlerName)()?!1:!H1(t)}),F3e=(0,Jt.createRegistrySelector)(e=>t=>{if(!OX(t)||DX(t))return!1;let r=oa(t);if(!e(yo.store).getPostType(r)?.supports?.autosave)return!1;let n=na(t),i=e(yo.store).hasFetchedAutosaves(r,n),s=e(yo.store).getCurrentUser()?.id,l=e(yo.store).getAutosave(r,n,s);return i?!l||AX(t)?!0:["title","excerpt","meta"].some(c=>Pk(l[c])!==oo(t,c)):!1});function D3e(e){let t=oo(e,"date"),r=new Date(Number((0,w0.getDate)(t))-j4);return(0,w0.isInTheFuture)(r)}function L3e(e){let t=oo(e,"date"),r=oo(e,"modified"),o=Tn(e).status;return o==="draft"||o==="auto-draft"||o==="pending"?t===r||t===null:!1}function V3e(e){return!!e.deleting.pending}function _0(e){return!!e.saving.pending}var B3e=(0,Jt.createRegistrySelector)(e=>t=>{let r=e(yo.store).__experimentalGetEntitiesBeingSaved(),{type:o,id:n}=Tn(t);return r.some(i=>i.kind!=="postType"||i.name!==o||i.key!==n)}),j3e=(0,Jt.createRegistrySelector)(e=>t=>{let r=oa(t),o=na(t);return!e(yo.store).getLastEntitySaveError("postType",r,o)}),z3e=(0,Jt.createRegistrySelector)(e=>t=>{let r=oa(t),o=na(t)
&[data-orientation=vertical]{border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));box-sizing:border-box}}.a5fd8814f195aa5e__tab{align-items:center;background:transparent;border:none;border-radius:0;box-shadow:none;color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);cursor:var(--wpds-cursor-control,pointer);display:flex;flex:1 0 auto;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-md,13px);font-weight:400;line-height:1.2;outline:none;padding:0;position:relative;white-space:nowrap;z-index:1;&[data-disabled]{color:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d);cursor:default;@media (forced-colors:active){color:GrayText}}&:not([data-disabled]):is(:hover,:focus-visible){color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}&:after{border-radius:var(--wpds-border-radius-sm,2px);opacity:0;outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));pointer-events:none;position:absolute;z-index:-1;@media not (prefers-reduced-motion){transition:opacity .1s linear}}&:focus-visible:after{opacity:1}[data-orientation=horizontal] &{height:48px;padding-inline:var(--wpds-dimension-padding-lg,16px);scroll-margin:24px;&:after{content:"";inset:var(--wpds-dimension-padding-md,12px)}}._59228b5227f38a99__is-minimal-variant[data-orientation=horizontal] &{padding-inline:0;&:after{inset-inline:round(up,var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)),1px)}}[data-orientation=vertical] &{min-height:var(--wpds-dimension-size-lg,40px);padding:var(--wpds-dimension-padding-sm,8px) var(--wpds-dimension-padding-md,12px)}[data-orientation=vertical][data-select-on-move=false] &:after{content:"";inset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}._5dfc77e6edd345d4__tab-children{align-items:center;display:flex;flex-grow:1;[data-orientation=horizontal] &{justify-content:center}[data-orientation=vertical] &{justify-content:start}}._4a20e969d15e5ac1__tab-chevron{flex-shrink:0;margin-inline-end:calc(var(--wpds-dimension-gap-xs, 4px)*-1);opacity:0;[data-orientation=horizontal] &{display:none}[role=tab]:is([aria-selected=true],:focus-visible,:hover) &{opacity:1}@media not (prefers-reduced-motion){[data-select-on-move=true]
[role=tab]:is([aria-selected=true])
&{transition:opacity .15s linear .15s}}&:dir(rtl){rotate:180deg}}}}`);var TC={tablist:"_7313adbc8a112e90__tablist","is-overflowing-first":"_9f2ac729c68a735a__is-overflowing-first","is-overflowing-last":"_81c799c1f3cdd261__is-overflowing-last","is-minimal-variant":"_59228b5227f38a99__is-minimal-variant",indicator:"_1c37dcfaa1ad8cda__indicator",tab:"a5fd8814f195aa5e__tab","tab-children":"_5dfc77e6edd345d4__tab-children","tab-chevron":"_4a20e969d15e5ac1__tab-chevron"},noe=1,aoe=(0,Vv.forwardRef)(function({children:t,variant:r="default",className:o,activateOnFocus:n,...i},s){let[l,c]=(0,Vv.useState)(null),[u,d]=(0,Vv.useState)({first:!1,last:!1,isScrolling:!1});(0,Vv.useEffect)(()=>{if(!l)return;let m=()=>{let{scrollWidth:y,clientWidth:w,scrollLeft:S}=l,x=Math.max(y-w,0),A=(l.dir||(typeof window<"u"?window.getComputedStyle(l).direction:"ltr"))==="rtl"&&S<0?-S:S,P={first:A>noe,last:A<x-noe,isScrolling:y>w};d(R=>R.first===P.first&&R.last===P.last&&R.isScrolling===P.isScrolling?R:P)},h=new ResizeObserver(m),g=()=>{h.disconnect(),h.observe(l),l.querySelectorAll('[role="tab"]').forEach(y=>h.observe(y))},v=new MutationObserver(g);v.observe(l,{childList:!0,subtree:!0});let b=!1,_=()=>{b||(requestAnimationFrame(()=>{m(),b=!1}),b=!0)};return l.addEventListener("scroll",_,{passive:!0}),g(),m(),()=>{l.removeEventListener("scroll",_),h.disconnect(),v.disconnect()}},[l]);let f=(0,ioe.useMergeRefs)([s,m=>c(m)]);return(0,nI.jsxs)(Lc.List,{ref:f,activateOnFocus:n,"data-select-on-move":n?"true":"false",className:J(TC.tablist,u.first&&TC["is-overflowing-first"],u.last&&TC["is-overflowing-last"],TC[`is-${r}-variant`],o),...i,tabIndex:i.tabIndex??(u.isScrolling?-1:void 0),children:[t,(0,nI.jsx)(Lc.Indicator,{className:TC.indicator})]})});var doe=a(U(),1);var Ui=a(U(),1);var PC=a(T(),1),iI=!1,yj=iI?(0,Ui.createContext)(null):null;function FBe(){let e=(0,Ui.useContext)(yj);(0,Ui.useEffect)(()=>{if(e)return e.registerTab()},[e])}function DBe(){}var loe=iI?FBe:DBe;function LBe(){let e=(0,Ui.useContext)(yj);(0,Ui.useEffect)(()=>{if(e)return e.registerPanel()},[e])}function VBe(){}var coe=iI?LBe:VBe;function BBe({children:e}){let t=(0,Ui.useRef)(0),r=(0,Ui.useRef)(0),o=Kre(()=>{let l=t.current,c=r.current;if(l!==c)throw new Error(`Tabs: Tab/Panel count mismatch (${l} Tabs, ${c} Panels). Each Tab must be associated with exactly one Panel. Mismatched or missing associations can break screen reader navigation and violate WAI-ARIA Tabs pattern requirements.`)}),n=(0,Ui.useCallback)(()=>(t.current+=1,o(),()=>{t.current-=1,o()}),[o]),i=(0,Ui.useCallback)(()=>(r.current+=1,o(),()=>{r.current-=1,o()}),[o]),s=(0,Ui.useMemo)(()=>({registerTab:n,registerPanel:i}),[n,i]);return(0,PC.jsx)(yj.Provider,{value:s,children:e})}function jBe({children:e}){return(0,PC.jsx)(PC.Fragment,{children:e})}var uoe=iI?BBe:jBe;var moe=a(T(),1),wj="data-wp-hash";function _j(){let e=globalThis;return e.__wpStyleRuntime||(e.__wpStyleRuntime={documents:new Map,styles:new Map,injectedStyles:new WeakMap},typeof document<"u"&&HBe(document)),e.__wpStyleRuntime}function zBe(e,t){if(!e.head)return!1;for(let r of e.head.querySelectorAll(`style[${wj}]`))if(r.getAttribute(wj)===t)return!0;return!1}function foe(e,t,r){if(!e.head)return;let o=_j(),n=o.injectedStyles.get(e);if(n||(n=new Set,o.injectedStyles.set(e,n)),n.has(t))return;if(zBe(e,t)){n.add(t);return}let i=e.createElement("style");i.setAttribute(wj,t),i.appendChild(e.createTextNode(r)),e.head.appendChild(i),n.add(t)}function HBe(e){let t=_j();t.documents.set(e,(t.documents.get(e)??0)+1);for(let[r,o]of t.styles)foe(e,r,o);return()=>{let r=t.documents.get(e);if(r!==void 0){if(r<=1){t.documents.delete(e);return}t.documents.set(e,r-1)}}}function poe(e,t){let r=_j();r.styles.set(e,t);for(let o of r.documents.keys())foe(o,e,t)}typeof process>"u",poe("af6d9984a6","._6defc79820e382c6__button{box-sizing:var(--_gcd-button-box-sizing,border-box);font-family:var(--_gcd-button-font-family,inherit);font-size:var(--_gcd-button-font-size,inherit);font-weight:var(--_gcd-button-font-weight,inherit)}.d2cff2e5dea83bd1__input{box-sizing:var(--_gcd-inp
&[data-orientation=vertical]{border:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));box-sizing:border-box}}.a5fd8814f195aa5e__tab{align-items:center;background:transparent;border:none;border-radius:0;box-shadow:none;color:var(--wpds-color-foreground-interactive-neutral,#1e1e1e);cursor:var(--wpds-cursor-control,pointer);display:flex;flex:1 0 auto;font-family:var(--wpds-typography-font-family-body,-apple-system,system-ui,"Segoe UI","Roboto","Oxygen-Sans","Ubuntu","Cantarell","Helvetica Neue",sans-serif);font-size:var(--wpds-typography-font-size-md,13px);font-weight:400;line-height:1.2;outline:none;padding:0;position:relative;white-space:nowrap;z-index:1;&[data-disabled]{color:var(--wpds-color-foreground-interactive-neutral-disabled,#8d8d8d);cursor:default;@media (forced-colors:active){color:GrayText}}&:not([data-disabled]):is(:hover,:focus-visible){color:var(--wpds-color-foreground-interactive-neutral-active,#1e1e1e)}&:after{border-radius:var(--wpds-border-radius-sm,2px);opacity:0;outline:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)) solid var(--wpds-color-stroke-focus,var(--wp-admin-theme-color,#3858e9));pointer-events:none;position:absolute;z-index:-1;@media not (prefers-reduced-motion){transition:opacity .1s linear}}&:focus-visible:after{opacity:1}[data-orientation=horizontal] &{height:48px;padding-inline:var(--wpds-dimension-padding-lg,16px);scroll-margin:24px;&:after{content:"";inset:var(--wpds-dimension-padding-md,12px)}}._59228b5227f38a99__is-minimal-variant[data-orientation=horizontal] &{padding-inline:0;&:after{inset-inline:round(up,var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px)),1px)}}[data-orientation=vertical] &{min-height:var(--wpds-dimension-size-lg,40px);padding:var(--wpds-dimension-padding-sm,8px) var(--wpds-dimension-padding-md,12px)}[data-orientation=vertical][data-select-on-move=false] &:after{content:"";inset:var(--wpds-border-width-focus,var(--wp-admin-border-width-focus,2px))}}._5dfc77e6edd345d4__tab-children{align-items:center;display:flex;flex-grow:1;[data-orientation=horizontal] &{justify-content:center}[data-orientation=vertical] &{justify-content:start}}._4a20e969d15e5ac1__tab-chevron{flex-shrink:0;margin-inline-end:calc(var(--wpds-dimension-gap-xs, 4px)*-1);opacity:0;[data-orientation=horizontal] &{display:none}[role=tab]:is([aria-selected=true],:focus-visible,:hover) &{opacity:1}@media not (prefers-reduced-motion){[data-select-on-move=true]
[role=tab]:is([aria-selected=true])
&{transition:opacity .15s linear .15s}}&:dir(rtl){rotate:180deg}}}}`);var xj={tablist:"_7313adbc8a112e90__tablist","is-overflowing-first":"_9f2ac729c68a735a__is-overflowing-first","is-overflowing-last":"_81c799c1f3cdd261__is-overflowing-last","is-minimal-variant":"_59228b5227f38a99__is-minimal-variant",indicator:"_1c37dcfaa1ad8cda__indicator",tab:"a5fd8814f195aa5e__tab","tab-children":"_5dfc77e6edd345d4__tab-children","tab-chevron":"_4a20e969d15e5ac1__tab-chevron"},woe=(0,boe.forwardRef)(function({className:t,children:r,...o},n){return loe(),(0,kC.jsxs)(Lc.Tab,{ref:n,className:J(xj.tab,t),...o,children:[(0,kC.jsx)("span",{className:xj["tab-children"],children:r}),(0,kC.jsx)(Nf,{icon:hr,className:xj["tab-chevron"]})]})});var Vc=a(T(),1),{PATTERN_TYPES:KBe}=un(Soe.privateApis);function xoe({item:e}){let t=(0,_oe.__)("This pattern cannot be edited.");return(0,Vc.jsx)(Y1,{item:e,className:"fields-field__pattern-title",children:e.type===KBe.theme&&(0,Vc.jsxs)(Vc.Fragment,{children:[(0,Vc.jsx)(Yt,{children:t}),(0,Vc.jsxs)(Ze.Root,{children:[(0,Vc.jsx)(Ze.Trigger,{render:(0,Vc.jsx)(En,{icon:gB,size:24})}),(0,Vc.jsx)(Ze.Popup,{children:t})]})]})})}var ZBe={type:"text",id:"title",label:(0,Tj.__)("Title"),placeholder:(0,Tj.__)("No title"),getValue:({item:e})=>ft(e),render:xoe,enableHiding:!1,enableGlobalSearch:!0,filterBy:!1},RC=ZBe;var Pj=a(Nt(),1),kj=a(j(),1);var Eoe=a(T(),1);function Coe(e){return typeof e.excerpt=="string"?(0,Pj.decodeEntities)(e.excerpt):(0,Pj.decodeEntities)(e.excerpt?.raw||"")}var XBe={id:"excerpt",type:"text",label:(0,kj.__)("Description"),placeholder:(0,kj.__)("Add a description"),getValue:({item:e})=>Coe(e),render:({item:e})=>{let t=Coe(e);return t?(0,Eoe.jsx)(Ss,{children:t}):null},Edit:{control:"textarea",rows:4},enableSorting:!1,enableHiding:!1,filterBy:!1,enableGlobalSearch:!0},Rj=XBe;var Bv=a(j(),1),Poe=a(Ml(),1);var koe=a(T(),1),{PATTERN_SYNC_TYPES:tw,PATTERN_TYPES:QBe}=un(Poe.privateApis),Toe=[{value:tw.full,label:(0,Bv._x)("Synced","pattern (singular)"),description:(0,Bv.__)("Patterns that are kept in sync across the site.")},{value:tw.unsynced,label:(0,Bv._x)("Not synced","pattern (singular)"),description:(0,Bv.__)("Patterns that can be changed freely without affecting the site.")}];function JBe(e){return e.type&&e.type!==QBe.user||e.meta?.wp_pattern_sync_status===tw.unsynced?tw.unsynced:e.wp_pattern_sync_status||tw.full}var $Be={id:"sync-status",type:"text",label:(0,Bv.__)("Sync status"),readOnly:!0,enableSorting:!1,enableHiding:!0,elements:Toe,filterBy:{operators:["is"],isPrimary:!0},render:({item:e})=>{let t=JBe(e);return(0,koe.jsx)("span",{className:`fields-field__pattern-sync-status fields-field__pattern-sync-status-${t}`,children:Toe.find(({value:r})=>r===t)?.label})}},Aj=$Be;var bz=a(j(),1);var Tr=a(G(),1),qv=a(sI(),1),mz=a(ae(),1),qC=a(Y(),1),Kr=a(U(),1),Es=a(j(),1),hz=a(Nt(),1);var Ane=a(Nl(),1),fw=a(Ef(),1),Ine=a(It(),1);var Oj=IC(),pt=e=>AC(e,Oj),Nj=IC();pt.write=e=>AC(e,Nj);var aI=IC();pt.onStart=e=>AC(e,aI);var Mj=IC();pt.onFrame=e=>AC(e,Mj);var Fj=IC();pt.onFinish=e=>AC(e,Fj);var rw=[];pt.setTimeout=(e,t)=>{let r=pt.now()+t,o=()=>{let i=rw.findIndex(s=>s.cancel==o);~i&&rw.splice(i,1),Um-=~i?1:0},n={time:r,handler:e,cancel:o};return rw.splice(Aoe(r),0,n),Um+=1,Ioe(),n};var Aoe=e=>~(~rw.findIndex(t=>t.time>e)||~rw.length);pt.cancel=e=>{aI.delete(e),Mj.delete(e),Fj.delete(e),Oj.delete(e),Nj.delete(e)};pt.sync=e=>{Ij=!0,pt.batchedUpdates(e),Ij=!1};pt.throttle=e=>{let t;function r(){try{e(...t)}finally{t=null}}function o(...n){t=n,pt.onStart(r)}return o.handler=e,o.cancel=()=>{aI.delete(r),t=null},o};var Dj=typeof window<"u"?window.requestAnimationFrame:()=>{};pt.use=e=>Dj=e;pt.now=typeof performance<"u"?()=>performance.now():Date.now;pt.batchedUpdates=e=>e();pt.catch=console.error;pt.frameLoop="always";pt.advance=()=>{pt.frameLoop!=="demand"?console.warn("Cannot call the manual advancement of rafz whilst frameLoop is not set as demand"):Noe()};var Hm=-1,Um=0,Ij=!1;function AC(e,t){Ij?(t.delete(e),e(0)):(t.add(e),Ioe())}function Ioe(){Hm<0&&(Hm=0,pt.frameLoop!=="demand"&&Dj(Ooe))}f
`,ve.start??ve.text.length,ve.end??ve.text.length))});return de.addEventListener("keydown",pe),()=>de.removeEventListener("keydown",pe)},[_,u]),K=(0,Lh.useRefEffect)(de=>{if(!C)return;let pe=gWe(O)(de),$=vWe(O)(de);function oe(fe){if(fe.inputType!=="insertText"&&fe.type!=="compositionend")return;let{formatTypes:ve,getValue:Oe,onChange:ee}=B.current,ne=Oe(),ce=ve.reduce((re,{__unstableInputRule:ie})=>ie?ie(re):re,ne);ce!==ne&&ee({...ce,activeFormats:ne.activeFormats})}return de.addEventListener("input",oe),de.addEventListener("compositionend",oe),()=>{pe(),$(),de.removeEventListener("input",oe),de.removeEventListener("compositionend",oe)}},[C]),{ref:Z,...Q}=(0,o_.__unstableUseAutocompleteProps)({completers:w,record:M,onChange:V,onReplace:()=>{}}),ue=(0,Lh.useRefEffect)(de=>{y&&!u&&de.focus()},[y,u]),te=(0,Lh.useMergeRefs)([F,P,K,W,ue,Z]);return(0,Dh.jsx)("div",{...k,onFocus:de=>{A(!0),k.onFocus(de)},children:(0,Dh.jsxs)(o_.SlotFillProvider,{children:[(0,Dh.jsx)(dWe,{label:e,id:n,className:J("dataviews-controls__richtext",s),placeholder:o,hideLabelFromVision:l,help:c,disabled:u,required:d,markWhenOptional:f,customValidity:m,value:M.text,"aria-multiline":!_,...Q,ref:te}),C&&!u&&(0,Dh.jsx)(mWe.Provider,{value:N,children:(0,Dh.jsx)(hWe.Provider,{value:R,children:(0,Dh.jsx)(jfe,{value:M,onChange:V,onFocus:L,formatTypes:D,forwardedRef:P,isVisible:!0})})})]})})}var Hfe=a(T(),1);function Ufe({data:e,field:t,onChange:r,hideLabelFromVision:o,markWhenOptional:n,config:i,validity:s}){let{className:l,clientId:c,allowedFormats:u,disableFormats:d,withoutInteractiveFormatting:f,preserveWhiteSpace:m,disableLineBreaks:h}=i||{},g=t.isDisabled({item:e,field:t}),{label:v,placeholder:b,description:_,id:y,setValue:w,isValid:S}=t,x=t.getValue({item:e})??"",C=(0,zfe.useCallback)(A=>r(w({item:e,value:A})),[e,r,w]);return(0,Hfe.jsx)(G5,{label:v,value:x,onChange:C,placeholder:b,id:y,hideLabelFromVision:o,help:_,disabled:g,required:!!S.required,markWhenOptional:n,customValidity:wr(S,s),className:l,clientId:c,allowedFormats:u,disableFormats:d,withoutInteractiveFormatting:f,preserveWhiteSpace:m,disableLineBreaks:h})}var n_=a(G(),1),Wfe=a(U(),1);var Y5=a(T(),1),{ValidatedToggleGroupControl:yWe}=_t(n_.privateApis);function Gfe({data:e,field:t,onChange:r,hideLabelFromVision:o,markWhenOptional:n,validity:i}){let{getValue:s,setValue:l,isValid:c}=t,u=t.isDisabled({item:e,field:t}),d=s({item:e}),f=(0,Wfe.useCallback)(v=>r(l({item:e,value:v})),[e,r,l]),{elements:m,isLoading:h}=Zn({elements:t.elements,getElements:t.getElements});if(h)return(0,Y5.jsx)(n_.Spinner,{});if(m.length===0)return null;let g=m.find(v=>v.value===d);return(0,Y5.jsx)(yWe,{required:!!t.isValid?.required,markWhenOptional:n,customValidity:wr(c,i),isBlock:!0,label:t.label,help:g?.description||t.description,onChange:f,value:d,hideLabelFromVision:o,children:m.map(v=>(0,Y5.jsx)(n_.__experimentalToggleGroupControlOption,{label:v.label,value:v.value,disabled:u},v.value))})}var q5=a(G(),1),K5=a(U(),1);var zE=a(T(),1),{ValidatedFormTokenField:wWe}=_t(q5.privateApis);function Yfe({data:e,field:t,onChange:r,hideLabelFromVision:o,markWhenOptional:n,validity:i}){let{label:s,placeholder:l,description:c,getValue:u,setValue:d,isValid:f}=t,m=u({item:e}),h=t.isDisabled({item:e,field:t}),{elements:g,isLoading:v}=Zn({elements:t.elements,getElements:t.getElements}),b=(0,K5.useMemo)(()=>Array.isArray(m)?m.map(y=>g?.find(S=>S.value===y)||{value:y,label:y}):[],[m,g]),_=(0,K5.useCallback)(y=>{let w=y.map(S=>typeof S=="object"&&"value"in S?S.value:S);r(d({item:e,value:w}))},[r,d,e]);return v?(0,zE.jsx)(q5.Spinner,{}):(0,zE.jsx)(wWe,{required:!!f?.required,markWhenOptional:n,customValidity:wr(f,i),label:o?void 0:s,value:b,onChange:_,placeholder:l,suggestions:g?.map(y=>y.value),disabled:h,__experimentalValidateInput:y=>t.isValid?.elements&&g?g.some(w=>w.value===y||w.label===y):!0,__experimentalExpandOnFocus:g&&g.length>0,help:c??(t.isValid?.elements?"":void 0),displayTransform:y=>typeof y=="object"&&"label"in y?y.label:typeof y=="string"&&g&&g.find(S=>S.value===y)?.label||y,__experimentalRenderItem:({item:y})=>{if(type
body{
padding: ${m}px;
min-height:${Math.round(b)}px;
display:flex;
}
.is-root-container {
width: ${100/f}%;
transform: scale(${f});
transform-origin: top left;
}
${c}
`}]})})})},Uve=wZe;var Wve=a(G(),1),Gve=a(T(),1);function Uo({children:e,level:t=2}){return(0,Gve.jsx)(Wve.__experimentalHeading,{className:"global-styles-ui-subtitle",level:t,children:e})}var bn=a(T(),1),_Ze={backgroundSize:"cover",backgroundPosition:"50% 50%"};function hT(e){if(!e)return e;let t=e.color||e.width;if(!e.style&&t)return{...e,style:"solid"};if(!(e.style&&!t))return e}function SZe(e){return e&&((0,Kb.__experimentalHasSplitBorders)(e)?{top:hT(e.top),right:hT(e.right),bottom:hT(e.bottom),left:hT(e.left)}:hT(e))}var{useHasDimensionsPanel:xZe,useHasTypographyPanel:CZe,useHasBorderPanel:EZe,useSettingsForBlockElement:TZe,useHasColorPanel:PZe,useHasFiltersPanel:kZe,useHasImageSettingsPanel:RZe,useHasBackgroundPanel:AZe,BackgroundPanel:IZe,BorderPanel:OZe,ColorPanel:NZe,TypographyPanel:MZe,DimensionsPanel:FZe,FiltersPanel:DZe,ImageSettingsPanel:LZe,AdvancedPanel:VZe}=Tt(qve.privateApis);function BZe({name:e,variation:t,selectedViewport:r,showResponsiveStateControls:o=!0,showBlockStateControls:n=!0}){let{user:i,merged:s,onChange:l}=(0,$c.useContext)(on),c=[];t&&(c=["variations",t].concat(c));let u=c.join("."),[d,f]=(0,$c.useState)("default"),[m,h]=(0,$c.useState)("default"),g=r??d,v=s.settings?.viewport,b=(0,$c.useMemo)(()=>dve(v),[v]),_=g==="default"||b.some(ee=>ee.value===g)?g:"default",y=(0,$c.useMemo)(()=>uve(e),[e]),w=[_,m].filter(ee=>ee!=="default").join("."),S=w.length>0,[x,C]=qe(u,e,"user",!1,S?w:void 0),[A]=qe(u,e,"merged",!1,S?w:void 0),[P]=Le("",e,"user"),[R,N]=Le("",e),k=TZe(R,e),E=(0,Yve.getBlockType)(e),M=!1;k?.spacing?.blockGap&&E?.supports?.spacing?.blockGap&&(E?.supports?.spacing?.__experimentalSkipSerialization===!0||E?.supports?.spacing?.__experimentalSkipSerialization?.some?.(ee=>ee==="blockGap"))&&(M=!0);let V=!1;k?.dimensions?.aspectRatio&&e==="core/group"&&(V=!0);let F=(0,$c.useMemo)(()=>{let ee=structuredClone(k);return M&&(ee.spacing.blockGap=!1),V&&(ee.dimensions.aspectRatio=!1),ee},[k,M,V]),D=mT(e),z=AZe(F),L=CZe(F),O=PZe(F),B=EZe(F),W=xZe(F),Z=kZe(F)&&_==="default",Q=RZe(e,P,F),ue=!!D?.length&&!t&&!S,{canEditCSS:te}=(0,Kve.useSelect)(ee=>{let{getEntityRecord:ne,__experimentalGetCurrentGlobalStylesId:ce}=ee(Zve.store),re=ce();return{canEditCSS:!!(re?ne("root","globalStyles",re):void 0)?._links?.["wp:action-edit-css"]}},[]),de=t?D.find(ee=>ee.name===t):null,pe=(0,$c.useMemo)(()=>({...A,layout:F.layout}),[A,F.layout]),$=(0,$c.useMemo)(()=>({...x,layout:P.layout}),[x,P.layout]),oe=ee=>{let ne={...ee};delete ne.layout,C(ne),ee.layout!==P.layout&&N({...P,layout:ee.layout})},fe=ee=>{N(ee===void 0?{...R,lightbox:void 0}:{...R,lightbox:{...R.lightbox,...ee}})},ve=ee=>{let{settings:ne,...ce}=ee;if(ne?.typography){let re=[u,w].filter(Boolean).join("."),ie=I1(i,re,ce,e);ie=k1(ie,"typography",{...P.typography,...ne.typography},e),l(ie)}else C(ce)},Oe=ee=>{if(!ee?.border){C(ee);return}let{radius:ne,...ce}=ee.border,re=SZe(ce),ie=(0,Kb.__experimentalHasSplitBorders)(re)?{color:null,style:null,width:null,...re}:{top:re,right:re,bottom:re,left:re};C({...ee,border:{...ie,radius:ne}})};return(0,bn.jsxs)(bn.Fragment,{children:[(0,bn.jsx)(sr,{title:t?de?.label:E?.title,viewportStates:b,pseudoStates:n?y:[],selectedViewport:_,selectedPseudoState:m,onChangeViewport:o?f:void 0,onChangePseudoState:h,showResponsiveStateControls:o}),(0,bn.jsx)(Uve,{name:e,variation:t,selectedViewport:_,selectedState:S?w:"default",stateStyles:S?A:void 0,viewportSettings:v}),ue&&(0,bn.jsx)("div",{className:"global-styles-ui-screen-variations",children:(0,bn.jsxs)(Kb.__experimentalVStack,{spacing:3,children:[(0,bn.jsx)(Uo,{children:(0,T_.__)("Style Variations")}),(0,bn.jsx)(Mve,{name:e})]})}),L&&(0,bn.jsx)(MZe,{inheritedValue:A,value:x,onChange:ve,settings:F,isGlobalStyles:!S,showInheritanceLabelIndicators:!1}),z&&(0,bn.jsx)(IZe,{inheritedValue:A,value:x,onChange:C,settings:F,defaultValues:_Ze,showInheritanceLabelIndicators:!1}),Z&&(0,bn.jsx)(DZe,{inheritedValue:pe,value:$,onChange:C,settings:F,includeLayoutControls:!0,showInheritanceLabelIndicators:!1}),W&&(0,bn.jsx)(FZe,{inheritedValue:pe,value:$,onChange:oe,settings:F,inclu
`),new E("",d,""),new E("",l,"]"),new E("",l," for "),new E("",x,""),new E("",u,""),new E("",l," a "),new E("",l," that "),new E(" ",_,""),new E("",l,". "),new E(".",l,""),new E(" ",l,", "),new E("",C,""),new E("",l," with "),new E("",l,"'"),new E("",l," from "),new E("",l," by "),new E("",A,""),new E("",P,""),new E(" the ",l,""),new E("",f,""),new E("",l,". The "),new E("",y,""),new E("",l," on "),new E("",l," as "),new E("",l," is "),new E("",g,""),new E("",c,"ing "),new E("",l,`
`),new E("",l,":"),new E(" ",l,". "),new E("",l,"ed "),new E("",k,""),new E("",R,""),new E("",h,""),new E("",l,"("),new E("",_,", "),new E("",v,""),new E("",l," at "),new E("",l,"ly "),new E(" the ",l," of "),new E("",m,""),new E("",b,""),new E(" ",_,", "),new E("",_,'"'),new E(".",l,"("),new E("",y," "),new E("",_,'">'),new E("",l,'="'),new E(" ",l,"."),new E(".com/",l,""),new E(" the ",l," of the "),new E("",_,"'"),new E("",l,". This "),new E("",l,","),new E(".",l," "),new E("",_,"("),new E("",_,"."),new E("",l," not "),new E(" ",l,'="'),new E("",l,"er "),new E(" ",y," "),new E("",l,"al "),new E(" ",y,""),new E("",l,"='"),new E("",y,'"'),new E("",_,". "),new E(" ",l,"("),new E("",l,"ful "),new E(" ",_,". "),new E("",l,"ive "),new E("",l,"less "),new E("",y,"'"),new E("",l,"est "),new E(" ",_,"."),new E("",y,'">'),new E(" ",l,"='"),new E("",_,","),new E("",l,"ize "),new E("",y,"."),new E("\xC2\xA0",l,""),new E(" ",l,","),new E("",_,'="'),new E("",y,'="'),new E("",l,"ous "),new E("",y,", "),new E("",_,"='"),new E(" ",_,","),new E(" ",y,'="'),new E(" ",y,", "),new E("",y,","),new E("",y,"("),new E("",y,". "),new E(" ",y,"."),new E("",y,"='"),new E(" ",y,". "),new E(" ",_,'="'),new E(" ",y,"='"),new E(" ",_,"='")];i.kTransforms=M,i.kNumTransforms=M.length;function V(F,D){return F[D]<192?(F[D]>=97&&F[D]<=122&&(F[D]^=32),1):F[D]<224?(F[D+1]^=32,2):(F[D+2]^=5,3)}i.transformDictionaryWord=function(F,D,z,L,O){var B=M[O].prefix,W=M[O].suffix,K=M[O].transform,Z=K<w?0:K-(w-1),Q=0,ue=D,te;Z>L&&(Z=L);for(var de=0;de<B.length;)F[D++]=B[de++];for(z+=Z,L-=Z,K<=b&&(L-=K),Q=0;Q<L;Q++)F[D++]=s.dictionary[z+Q];if(te=D-L,K===_)V(F,te);else if(K===y)for(;L>0;){var pe=V(F,te);te+=pe,L-=pe}for(var $=0;$<W.length;)F[D++]=W[$++];return D-ue}},{"./dictionary":6}],12:[function(o,n,i){n.exports=o("./dec/decode").BrotliDecompressBuffer},{"./dec/decode":3}]},{},[12])(12)})();var PM=(e=>typeof ra<"u"?ra:typeof Proxy<"u"?new Proxy(e,{get:(t,r)=>(typeof ra<"u"?ra:t)[r]}):e)(function(e){if(typeof ra<"u")return ra.apply(this,arguments);throw Error('Dynamic require of "'+e+'" is not supported')}),Nbe=(function(){var e,t,r;return(function(){function o(n,i,s){function l(d,f){if(!i[d]){if(!n[d]){var m=typeof PM=="function"&&PM;if(!f&&m)return m(d,!0);if(c)return c(d,!0);var h=new Error("Cannot find module '"+d+"'");throw h.code="MODULE_NOT_FOUND",h}var g=i[d]={exports:{}};n[d][0].call(g.exports,function(v){var b=n[d][1][v];return l(b||v)},g,g.exports,o,n,i,s)}return i[d].exports}for(var c=typeof PM=="function"&&PM,u=0;u<s.length;u++)l(s[u]);return l}return o})()({1:[function(o,n,i){"use strict";var s=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function l(d,f){return Object.prototype.hasOwnProperty.call(d,f)}i.assign=function(d){for(var f=Array.prototype.slice.call(arguments,1);f.length;){var m=f.shift();if(m){if(typeof m!="object")throw new TypeError(m+"must be non-object");for(var h in m)l(m,h)&&(d[h]=m[h])}}return d},i.shrinkBuf=function(d,f){return d.length===f?d:d.subarray?d.subarray(0,f):(d.length=f,d)};var c={arraySet:function(d,f,m,h,g){if(f.subarray&&d.subarray){d.set(f.subarray(m,m+h),g);return}for(var v=0;v<h;v++)d[g+v]=f[m+v]},flattenChunks:function(d){var f,m,h,g,v,b;for(h=0,f=0,m=d.length;f<m;f++)h+=d[f].length;for(b=new Uint8Array(h),g=0,f=0,m=d.length;f<m;f++)v=d[f],b.set(v,g),g+=v.length;return b}},u={arraySet:function(d,f,m,h,g){for(var v=0;v<h;v++)d[g+v]=f[m+v]},flattenChunks:function(d){return[].concat.apply([],d)}};i.setTyped=function(d){d?(i.Buf8=Uint8Array,i.Buf16=Uint16Array,i.Buf32=Int32Array,i.assign(i,c)):(i.Buf8=Array,i.Buf16=Array,i.Buf32=Array,i.assign(i,u))},i.setTyped(s)},{}],2:[function(o,n,i){"use strict";var s=o("./common"),l=!0,c=!0;try{String.fromCharCode.apply(null,[0])}catch{l=!1}try{String.fromCharCode.apply(null,new Uint8Array(1))}catch{c=!1}for(var u=new s.Buf8(256),d=0;d<256;d++)u[d]=d>=252?6:d>=248?5:d>=240?4:d>=224?3:d>=192?2:1;u[254]=u[254]=1,i.string2buf=function(m){var h,g,v,b,_,y=m.length,w=0;for(b=0;b<y;b++)g=m.charCodeAt(b),(g&64512)===55296&&b+1<y&&(v=m.charCodeAt(b+1),(v&64512)===5
@font-face {
font-family: "${e}";
${i.join(`
`)}
src: url("${t}") format("${o}");
}`,globalThis.document.head.appendChild(n),n}var _Xe=[0,1,0,0],SXe=[79,84,84,79],xXe=[119,79,70,70],CXe=[119,79,70,50];function RM(e,t){if(e.length===t.length){for(let r=0;r<e.length;r++)if(e[r]!==t[r])return;return!0}}function EXe(e){let t=[e.getUint8(0),e.getUint8(1),e.getUint8(2),e.getUint8(3)];if(RM(t,_Xe)||RM(t,SXe))return"SFNT";if(RM(t,xXe))return"WOFF";if(RM(t,CXe))return"WOFF2"}function TXe(e){if(!e.ok)throw new Error(`HTTP ${e.status} - ${e.statusText}`);return e}var IM=class extends nXe{constructor(e,t={}){super(),this.name=e,this.options=t,this.metrics=!1}get src(){return this.__src}set src(e){this.__src=e,(async()=>(globalThis.document&&!this.options.skipStyleSheet&&await wXe(this.name,e,this.options),this.loadFont(e)))()}async loadFont(e,t){fetch(e).then(r=>TXe(r)&&r.arrayBuffer()).then(r=>this.fromDataBuffer(r,t||e)).catch(r=>{let o=new kM("error",r,`Failed to load font at ${t||e}`);this.dispatch(o),this.onerror&&this.onerror(o)})}async fromDataBuffer(e,t){this.fontData=new DataView(e);let r=EXe(this.fontData);if(!r)throw new Error(`${t} is either an unsupported font format, or not a font at all.`);await this.parseBasicData(r);let o=new kM("load",{font:this});this.dispatch(o),this.onload&&this.onload(o)}async parseBasicData(e){return bXe().then(t=>(e==="SFNT"&&(this.opentype=new lXe(this,this.fontData,t)),e==="WOFF"&&(this.opentype=new uXe(this,this.fontData,t)),e==="WOFF2"&&(this.opentype=new pXe(this,this.fontData,t)),this.opentype))}getGlyphId(e){return this.opentype.tables.cmap.getGlyphId(e)}reverse(e){return this.opentype.tables.cmap.reverse(e)}supports(e){return this.getGlyphId(e)!==0}supportsVariation(e){return this.opentype.tables.cmap.supportsVariation(e)!==!1}measureText(e,t=16){if(this.__unloaded)throw new Error("Cannot measure text: font was unloaded. Please reload before calling measureText()");let r=document.createElement("div");r.textContent=e,r.style.fontFamily=this.name,r.style.fontSize=`${t}px`,r.style.color="transparent",r.style.background="transparent",r.style.top="0",r.style.left="0",r.style.position="absolute",document.body.appendChild(r);let o=r.getBoundingClientRect();document.body.removeChild(r);let n=this.opentype.tables["OS/2"];return o.fontSize=t,o.ascender=n.sTypoAscender,o.descender=n.sTypoDescender,o}unload(){if(this.styleElement.parentNode){this.styleElement.parentNode.removeElement(this.styleElement);let e=new kM("unload",{font:this});this.dispatch(e),this.onunload&&this.onunload(e)}this._unloaded=!0}load(){if(this.__unloaded){delete this.__unloaded,document.head.appendChild(this.styleElement);let e=new kM("load",{font:this});this.dispatch(e),this.onload&&this.onload(e)}}};globalThis.Font=IM;var Sp=class extends Eo{constructor(e,t,r){super(e),this.plaformID=t,this.encodingID=r}},PXe=class extends Sp{constructor(e,t,r){super(e,t,r),this.format=0,this.length=e.uint16,this.language=e.uint16,this.glyphIdArray=[...new Array(256)].map(o=>e.uint8)}supports(e){return e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 0. only supports(id) is implemented.")),0<=e&&e<=255}reverse(e){return console.warn("reverse not implemented for cmap subtable format 0"),{}}getSupportedCharCodes(){return[{start:1,end:256}]}},kXe=class extends Sp{constructor(e,t,r){super(e,t,r),this.format=2,this.length=e.uint16,this.language=e.uint16,this.subHeaderKeys=[...new Array(256)].map(s=>e.uint16);let o=Math.max(...this.subHeaderKeys),n=e.currentPosition;ze(this,"subHeaders",()=>(e.currentPosition=n,[...new Array(o)].map(s=>new RXe(e))));let i=n+o*8;ze(this,"glyphIndexArray",()=>(e.currentPosition=i,[...new Array(o)].map(s=>e.uint16)))}supports(e){e.charCodeAt&&(e=-1,console.warn("supports(character) not implemented for cmap subtable format 2. only supports(id) is implemented."));let t=e&&255,r=e&&65280,o=this.subHeaders[r],n=this.subHeaders[o],i=n.firstCode,s=i+n.entryCount;return i<=t&&t<=s}reverse(e){return console.warn("reverse not implemented for cmap subtable format 2"),{}}getSupportedCharCodes(e=!1){return e?this.subHeaders.map(t=>({firstCode:t.firstCode,last
`))&&(t=t.trim()),(!o.newlineIsToken||!r.includes(`
`))&&(r=r.trim())):o.ignoreNewlineAtEof&&!o.newlineIsToken&&(t.endsWith(`
`)&&(t=t.slice(0,-1)),r.endsWith(`
`)&&(r=r.slice(0,-1))),super.equals(t,r,o)}},Mtt=new OG;function pwe(e,t,r){return Mtt.diff(e,t,r)}function Ftt(e,t){t.stripTrailingCr&&(e=e.replace(/\r\n/g,`
`));let r=[],o=e.split(/(\n|\r\n)/);o[o.length-1]||o.pop();for(let n=0;n<o.length;n++){let i=o[n];n%2&&!t.newlineIsToken?r[r.length-1]+=i:r.push(i)}return r}var NG=class extends nc{tokenize(t){return t.slice()}join(t){return t}removeEmpty(t){return t}},mwe=new NG;function FT(e,t,r){return mwe.diff(e,t,r)}var MG=a(gwe(),1),s3=a(Pt(),1),Dn=a(vd(),1),Oa=a(j(),1);var J_=a(j(),1),i3=a(vd(),1),ic={removed:"revision-diff-removed-desc",added:"revision-diff-added-desc",formatAdded:"revision-diff-format-added-desc",formatRemoved:"revision-diff-format-removed-desc",formatChanged:"revision-diff-format-changed-desc"},vwe=[{name:"revision/diff-removed",title:(0,J_.__)("Removed"),tagName:"del",className:"revision-diff-removed"},{name:"revision/diff-added",title:(0,J_.__)("Added"),tagName:"ins",className:"revision-diff-added"},{name:"revision/diff-format-added",title:(0,J_.__)("Format added"),tagName:"mark",className:"revision-diff-format-added"},{name:"revision/diff-format-removed",title:(0,J_.__)("Format removed"),tagName:"mark",className:"revision-diff-format-removed"},{name:"revision/diff-format-changed",title:(0,J_.__)("Format changed"),tagName:"mark",className:"revision-diff-format-changed"}];function bwe(){for(let e of vwe)(0,i3.registerFormatType)(e.name,{...e,attributes:{"aria-describedby":"aria-describedby"},edit:()=>null})}function ywe(){for(let e of vwe)(0,i3.unregisterFormatType)(e.name)}var{parseRawBlock:Swe}=q(s3.privateApis);function wwe(e){return e.blockName===null&&(!e.innerHTML||!e.innerHTML.trim())}function _we(e){return e==null?"":typeof e=="object"?JSON.stringify(e,null,2):String(e)}function Dtt(e,t){if(!e&&!t)return 1;if(!e||!t)return 0;let r=new Intl.Segmenter(void 0,{granularity:"word"}),o=/[\p{L}\p{N}]/u,n=d=>{let f=[];for(let{segment:m,isWordLike:h}of r.segment(d))(h||o.test(m))&&f.push(m);return f},i=n(e),s=n(t);if(i.length===0&&s.length===0)return 1;let l=new Set(i),c=0;for(let d of s)l.has(d)&&c++;let u=Math.max(i.length,s.length);return u>0?c/u:0}function Ltt(e){let t=[],r=[];if(e.forEach((d,f)=>{let m=d.__revisionDiffStatus?.status;m==="removed"?t.push({block:d,index:f}):m==="added"&&r.push({block:d,index:f})}),t.length===0||r.length===0)return e;let o=new Set,n=new Set,i=new Map,s=.5,l=new Map;for(let d of r){let f=d.block.blockName;l.has(f)||l.set(f,[]),l.get(f).push(d)}let c=new Map;for(let d of t){let f=d.block.blockName;c.has(f)||c.set(f,[]),c.get(f).push(d)}let u=-1;for(let d of t){let f=l.get(d.block.blockName)||[],m=c.get(d.block.blockName)||[],h=f.filter(v=>!i.has(v.index)&&v.index>u);if(h.length===0)continue;let g=null;if(m.length===1&&h.length===1){let v=h[0],b=JSON.stringify(d.block.attrs)===JSON.stringify(v.block.attrs);(!((d.block.innerHTML||"")===(v.block.innerHTML||""))||!b)&&(g=v)}else{let v=0;for(let b of h){let _=Dtt(d.block.innerHTML||"",b.block.innerHTML||""),y=JSON.stringify(d.block.attrs)===JSON.stringify(b.block.attrs);_>v&&_>s&&(_<1||!y)&&(v=_,g=b)}}if(g){u=g.index;let v={...g.block,__revisionDiffStatus:{status:"modified"},__previousRawBlock:d.block},b=Math.min(d.index,g.index),_=Math.max(d.index,g.index),y=!1;for(let w=b+1;w<_;w++){let S=e[w].__revisionDiffStatus?.status;if(S===void 0){y=!0;break}if(S==="added"&&!n.has(w)){y=!0;break}}y?(i.set(g.index,v),o.add(d.index)):(i.set(d.index,v),n.add(g.index))}}return e.map((d,f)=>o.has(f)||n.has(f)?null:i.has(f)?i.get(f):d).filter(Boolean)}function xwe(e,t){e=e.filter(u=>!wwe(u)),t=t.filter(u=>!wwe(u));let r=u=>JSON.stringify({name:u.blockName,attrs:u.attrs,html:(u.innerContent||[]).filter(d=>d!==null&&d.trim()!=="")}),o=e.map(r),n=t.map(r),i=FT(n,o),s=[],l=0,c=0;for(let u of i)if(u.added)for(let d=0;d<u.count;d++)s.push({...e[l++],__revisionDiffStatus:{status:"added"}});else if(u.removed)for(let d=0;d<u.count;d++)s.push({...t[c++],__revisionDiffStatus:{status:"removed"}});else for(let d=0;d<u.count;d++){let f=e[l++],m=t[c++],h=xwe(f.innerBlocks||[],m.innerBlocks||[]);s.push({...f,innerBlocks:h})}return Ltt(s)}function Vtt(e,t,r,o){let n=e[r]||[],i=t[o]||[];if(n.length!==i.length)return!0;for(let s of n)if(!i.find(c=>c.type===s.type&&
.is-root-container {
display: flow-root;
}
`,sSe=`
body {
position: relative;
padding: 32px !important;
}
${mnt}
.editor-style-book__examples {
max-width: 1200px;
margin: 0 auto;
}
.editor-style-book__example {
max-width: 900px;
border-radius: 2px;
cursor: var(--wpds-cursor-control, pointer);
display: flex;
flex-direction: column;
gap: 40px;
padding: 16px;
width: 100%;
box-sizing: border-box;
scroll-margin-top: 32px;
scroll-margin-bottom: 32px;
margin: 0 auto 40px auto;
}
.editor-style-book__example.is-selected {
box-shadow: 0 0 0 1px var(--wp-components-color-accent, var(--wp-admin-theme-color, #007cba));
}
.editor-style-book__example.is-disabled-example {
pointer-events: none;
}
.editor-style-book__example:focus:not(:disabled) {
box-shadow: 0 0 0 var(--wp-admin-border-width-focus) var(--wp-components-color-accent, var(--wp-admin-theme-color, #007cba));
outline: 3px solid transparent;
}
.editor-style-book__duotone-example > div:first-child {
display: flex;
aspect-ratio: 16 / 9;
grid-row: span 1;
grid-column: span 2;
}
.editor-style-book__duotone-example img {
width: 100%;
height: 100%;
object-fit: cover;
}
.editor-style-book__duotone-example > div:not(:first-child) {
height: 20px;
border: 1px solid color-mix( in srgb, currentColor 10%, transparent );
}
.editor-style-book__color-example {
border: 1px solid color-mix( in srgb, currentColor 10%, transparent );
}
.editor-style-book__subcategory-title,
.editor-style-book__example-title {
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
font-size: 13px;
font-weight: normal;
line-height: normal;
margin: 0;
text-align: left;
padding-top: 8px;
border-top: 1px solid color-mix( in srgb, currentColor 10%, transparent );
color: color-mix( in srgb, currentColor 60%, transparent );
}
.editor-style-book__subcategory-title {
font-size: 16px;
margin-bottom: 40px;
padding-bottom: 8px;
}
.editor-style-book__example-preview {
width: 100%;
}
.editor-style-book__example-preview .block-editor-block-list__insertion-point,
.editor-style-book__example-preview .block-list-appender {
display: none;
}
:where(.is-root-container > .wp-block:first-child) {
margin-top: 0;
}
:where(.is-root-container > .wp-block:last-child) {
margin-bottom: 0;
}
`;var aSe=a(Pt(),1);function KT(e,t){if(!e?.slug||!t?.length)return;let r=e?.subcategories??[];if(r.length)return r.reduce((s,l)=>{let c=KT(l,t);return c&&(s.subcategories||(s.subcategories=[]),s.subcategories=[...s.subcategories,c]),s},{title:e.title,slug:e.slug});let o=e?.blocks||[],n=e?.exclude||[],i=t.filter(s=>!n.includes(s.name)&&(s.category===e.slug||o.includes(s.name)));if(i.length)return{title:e.title,slug:e.slug,examples:i}}function cY(){let e=[...I3,...lY].map(({slug:o})=>o),r=(0,aSe.getCategories)().filter(({slug:o})=>!e.includes(o));return[...lY,...r]}var qd=a(j(),1),Ei=a(Pt(),1);var lSe=a(G(),1),O3=a(be(),1),uY=a(T(),1),hnt=({colors:e,type:t,templateColumns:r="1fr 1fr",itemHeight:o="52px"})=>e?(0,uY.jsx)(lSe.__experimentalGrid,{templateColumns:r,rowGap:8,columnGap:16,children:e.map(n=>{let i=t==="gradients"?(0,O3.__experimentalGetGradientClass)(n.slug):(0,O3.getColorClassName)("background-color",n.slug),s=J("editor-style-book__color-example",i);return(0,uY.jsx)("div",{className:s,style:{height:o}},n.slug)})}):null,dY=hnt;var fY=a(G(),1),yy=a(T(),1),gnt=({duotones:e})=>e?(0,yy.jsx)(fY.__experimentalGrid,{columns:2,rowGap:16,columnGap:16,children:e.map(t=>(0,yy.jsxs)(fY.__experimentalGrid,{className:"editor-style-book__duotone-example",columns:2,rowGap:8,columnGap:8,children:[(0,yy.jsx)("div",{children:(0,yy.jsx)("img",{alt:`Duotone example: ${t.slug}`,src:"https://s.w.org/images/core/5.3/MtBlanc1.jpg",style:{filter:`url(#wp-duotone-${t.slug})`}})}),t.colors.map(r=>(0,yy.jsx)("div",{className:"editor-style-book__color-example",style:{backgroundColor:r}},r))]},t.slug))}):null,cSe=gnt;var N3=a(T(),1);function vnt(e){if(!e)return[];let t=[];return uS.forEach(r=>{let o=e[r.type],n=Array.isArray(o)?o.find(i=>i.slug===r.origin):void 0;if(n?.[r.type]){let i={name:r.slug,title:r.title,category:"colors"};r.type==="duotones"?(i.content=(0,N3.jsx)(cSe,{duotones:n[r.type]}),t.push(i)):(i.content=(0,N3.jsx)(dY,{colors:n[r.type],type:r.type}),t.push(i))}}),t}function bnt(e){let t=[],r=Array.isArray(e?.colors)?e.colors.find(i=>i.slug==="theme"):void 0;if(r){let i={name:"theme-colors",title:(0,qd.__)("Colors"),category:"overview",content:(0,N3.jsx)(dY,{colors:r.colors,type:"colors",templateColumns:"repeat(auto-fill, minmax( 200px, 1fr ))",itemHeight:"32px"})};t.push(i)}let o=[];if((0,Ei.getBlockType)("core/heading")){let i=(0,Ei.createBlock)("core/heading",{content:(0,qd.__)("AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz0123456789X{(\u2026)},.-<>?!*&:/A@HELFO\u2122\xA9"),level:1});o.push(i)}if((0,Ei.getBlockType)("core/paragraph")){let i=(0,Ei.createBlock)("core/paragraph",{content:(0,qd.__)("A paragraph in a website refers to a distinct block of text that is used to present and organize information. It is a fundamental unit of content in web design and is typically composed of a group of related sentences or thoughts focused on a particular topic or idea. Paragraphs play a crucial role in improving the readability and user experience of a website. They break down the text into smaller, manageable chunks, allowing readers to scan the content more easily.")}),s=(0,Ei.createBlock)("core/paragraph",{content:(0,qd.__)("Additionally, paragraphs help structure the flow of information and provide logical breaks between different concepts or pieces of information. In terms of formatting, paragraphs in websites are commonly denoted by a vertical gap or indentation between each block of text. This visual separation helps visually distinguish one paragraph from another, creating a clear and organized layout that guides the reader through the content smoothly.")});if((0,Ei.getBlockType)("core/group")){let l=(0,Ei.createBlock)("core/group",{layout:{type:"grid",columnCount:2,minimumColumnWidth:"12rem"},style:{spacing:{blockGap:"1.5rem"}}},[i,s]);o.push(l)}else o.push(i)}return o.length&&t.push({name:"typography",title:(0,qd.__)("Typography"),category:"overview",blocks:o}),["core/image","core/separator","core/buttons","core/pullquote","core/search"].forEach(i=>{let s=(0,Ei.getBlockType)(i);if(s&&s.example){let l={name:i,title:s.tit
<style>
body {
margin: 0;
}
.editor-post-preview-button__interstitial-message {
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
height: 100vh;
width: 100vw;
}
@-webkit-keyframes paint {
0% {
stroke-dashoffset: 0;
}
}
@-moz-keyframes paint {
0% {
stroke-dashoffset: 0;
}
}
@-o-keyframes paint {
0% {
stroke-dashoffset: 0;
}
}
@keyframes paint {
0% {
stroke-dashoffset: 0;
}
}
.editor-post-preview-button__interstitial-message svg {
width: 192px;
height: 192px;
stroke: #555d66;
stroke-width: 0.75;
}
.editor-post-preview-button__interstitial-message svg .outer,
.editor-post-preview-button__interstitial-message svg .inner {
stroke-dasharray: 280;
stroke-dashoffset: 280;
-webkit-animation: paint 1.5s ease infinite alternate;
-moz-animation: paint 1.5s ease infinite alternate;
-o-animation: paint 1.5s ease infinite alternate;
animation: paint 1.5s ease infinite alternate;
}
p {
text-align: center;
font-family: -apple-system, system-ui, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}
</style>
`,e=(0,pEe.applyFilters)("editor.PostPreview.interstitialMarkup",e),e}function ast(e,t){e.write(t),e.title=(0,jy.__)("Generating preview\u2026"),e.close()}async function lst(e){try{return e.document}catch{}e.location="about:blank";let t=1e3,r=50,o=Date.now()+t;do{await new Promise(n=>setTimeout(n,r));try{return e.document}catch{}}while(Date.now()<o);return null}async function cst(e){let t=await lst(e);t&&ast(t,sst())}function hEe({forceIsAutosaveable:e,onPreview:t}){let{postId:r,currentPostLink:o,previewLink:n,isSaveable:i,isViewable:s}=(0,cF.useSelect)(f=>{let m=f(I),v=f(mEe.store).getPostType(m.getCurrentPostType("type"))?.viewable??!1;return v?{postId:m.getCurrentPostId(),currentPostLink:m.getCurrentPostAttribute("link"),previewLink:m.getEditedPostPreviewLink(),isSaveable:m.isEditedPostSaveable(),isViewable:v}:{isViewable:v}},[]),{__unstableSaveForPreview:l}=(0,cF.useDispatch)(I);if(!s)return null;let c=`wp-preview-${r}`;return{href:n||o,target:c,disabled:!i,onClick:async f=>{f.preventDefault();let m=window.open("",c);m.focus(),await cst(m);let h=await l({forceIsAutosaveable:e});m.location=h,t?.()}}}function gEe({forceIsAutosaveable:e,onPreview:t}){let r=hEe({forceIsAutosaveable:e,onPreview:t});return r?(0,Va.jsx)(Yp.MenuItem,{icon:gs,...r,children:(0,jy.__)("Preview in new tab")}):null}function LS({className:e,textContent:t,forceIsAutosaveable:r,role:o,onPreview:n}){let i=hEe({forceIsAutosaveable:r,onPreview:n});return i?(0,Va.jsx)(Yp.Button,{variant:e?void 0:"tertiary",className:e||"editor-post-preview",role:o,size:"compact",accessibleWhenDisabled:!0,...i,children:t||(0,Va.jsxs)(Va.Fragment,{children:[(0,jy._x)("Preview","imperative verb"),(0,Va.jsx)(Yt,{render:(0,Va.jsx)("span",{}),children:(0,jy.__)("(opens in a new tab)")})]})}):null}var wEe=a(G(),1),dF=a(Y(),1);var Ng=a(j(),1),vEe=a(Y(),1),bEe=a(Ce(),1);function uF(){let e=(0,bEe.useViewportMatch)("medium","<"),{isPublished:t,isBeingScheduled:r,isSaving:o,isPublishing:n,hasPublishAction:i,isAutosaving:s,hasNonPostEntityChanges:l,postStatusHasChanged:c,postStatus:u,isPostSavingLocked:d}=(0,vEe.useSelect)(f=>{let{isCurrentPostPublished:m,isEditedPostBeingScheduled:h,isSavingPost:g,isPublishingPost:v,getCurrentPost:b,isAutosavingPost:_,getPostEdits:y,getEditedPostAttribute:w}=f(I);return{isPublished:m(),isBeingScheduled:h(),isSaving:g(),isPublishing:v(),hasPublishAction:b()._links?.["wp:action-publish"]??!1,isAutosaving:_(),hasNonPostEntityChanges:f(I).hasNonPostEntityChanges(),isPostSavingLocked:f(I).isPostSavingLocked(),postStatusHasChanged:!!y()?.status,postStatus:w("status")}},[]);return n?(0,Ng.__)("Publishing\u2026"):(t||r)&&o&&!s?(0,Ng.__)("Saving\u2026"):i?l&&!d||t||c&&!["future","publish"].includes(u)||!c&&u==="future"?(0,Ng.__)("Save"):r?(0,Ng.__)("Schedule"):(0,Ng.__)("Publish"):e?(0,Ng.__)("Publish"):(0,Ng.__)("Submit for Review")}var sq=a(T(),1),yEe=()=>{};function ust({forceIsDirty:e,isOpen:t,isToggle:r,onSubmit:o=yEe,onToggle:n,setEntitiesSavedStatesCallback:i}){let{hasPublishAction:s,isBeingScheduled:l,isPostSavingLocked:c,isPublishable:u,isPublished:d,isSaveable:f,isSaving:m,isAutoSaving:h,visibility:g,hasNonPostEntityChanges:v,isSavingNonPostEntityChanges:b,postStatus:_,postStatusHasChanged:y,postType:w,postId:S}=(0,dF.useSelect)(z=>{let L=z(I);return{isSaving:L.isSavingPost(),isAutoSaving:L.isAutosavingPost(),isBeingScheduled:L.isEditedPostBeingScheduled(),visibility:L.getEditedPostVisibility(),isSaveable:L.isEditedPostSaveable(),isPostSavingLocked:L.isPostSavingLocked(),isPublishable:L.isEditedPostPublishable(),isPublished:L.isCurrentPostPublished(),hasPublishAction:!!L.getCurrentPost()?._links?.["wp:action-publish"],postType:L.getCurrentPostType(),postId:L.getCurrentPostId(),postStatus:L.getEditedPostAttribute("status"),postStatusHasChanged:L.getPostEdits()?.status,hasNonPostEntityChanges:L.hasNonPostEntityChanges(),isSavingNonPostEntityChanges:L.isSavingNonPostEntityChanges()}},[]),{editPost:x,savePost:C}=(0,dF.useDispatch)(I),A=z=>{x({status:z},{undoIgnore:!0}),C()},P=z=>(...L)=>{if(v&&i){let O=B=>{B&&B.some(W=>W.kind==="postType"&&W.name==
.editor-avatar {
position: relative;
display: inline-flex;
align-items: center;
border-radius: ${$q};
flex-shrink: 0;
box-shadow: 0 0 0 var(--wp-admin-border-width-focus, 2px) ${Yg}, ${YD};
}
.editor-avatar__image {
box-sizing: border-box;
position: relative;
width: ${eK};
height: ${eK};
border-radius: ${$q};
border: 0;
background-color: var(--wp-admin-theme-color, #3858e9);
overflow: hidden;
overflow: clip;
flex-shrink: 0;
font-size: 0;
color: ${Yg};
}
.is-small > .editor-avatar__image {
width: ${tK};
height: ${tK};
}
.has-avatar-border-color > .editor-avatar__image {
border: var(--wp-admin-border-width-focus, 2px) solid var(--editor-avatar-outline-color);
background-clip: padding-box;
}
.has-avatar-border-color > .editor-avatar__image::after {
content: "";
position: absolute;
inset: 0;
border-radius: inherit;
box-shadow: inset 0 0 0 var(--wp-admin-border-width-focus, 2px) ${Yg};
pointer-events: none;
z-index: 1;
}
.editor-avatar__img {
position: absolute;
inset: 0;
width: 100%;
height: 100%;
object-fit: cover;
border-radius: inherit;
opacity: 0;
}
.has-src > .editor-avatar__image > .editor-avatar__img {
opacity: 1;
}
.editor-avatar:not(.has-src) > .editor-avatar__image {
display: flex;
align-items: center;
justify-content: center;
font-size: ${e2e};
font-weight: ${oK};
border: 0;
background-clip: border-box;
}
.editor-avatar:not(.has-src) > .editor-avatar__image::after {
content: none;
}
.editor-avatar:not(.has-src).has-avatar-border-color > .editor-avatar__image {
background-color: var(--editor-avatar-outline-color);
}
.editor-avatar__name {
font-size: ${t2e};
font-weight: ${oK};
line-height: ${r2e};
color: var(--editor-avatar-name-color, ${Yg});
min-width: 0;
padding-bottom: 2px; /* $grid-unit-05 / 2 */
overflow: hidden;
opacity: 0;
white-space: nowrap;
transition: opacity 0.15s cubic-bezier(0.15, 0, 0.15, 1);
}
.editor-avatar.is-badge {
display: inline-grid;
grid-template-columns: min-content 0fr;
column-gap: 0;
padding-inline-end: 0;
background-color: var(--wp-admin-theme-color, #3858e9);
transition:
grid-template-columns 0.3s cubic-bezier(0.15, 0, 0.15, 1),
column-gap 0.3s cubic-bezier(0.15, 0, 0.15, 1),
padding-inline-end 0.3s cubic-bezier(0.15, 0, 0.15, 1);
}
.editor-avatar.is-badge:hover {
grid-template-columns: min-content 1fr;
column-gap: ${qD};
padding-inline-end: ${KD};
transition-timing-function: cubic-bezier(0.85, 0, 0.85, 1);
}
.editor-avatar.is-badge:hover .editor-avatar__name {
opacity: 1;
transition-timing-function: cubic-bezier(0.85, 0, 0.85, 1);
}
.editor-avatar.is-badge.has-avatar-border-color {
background-color: var(--editor-avatar-outline-color);
}
@media (prefers-reduced-motion: reduce) {
.editor-avatar.is-badge,
.editor-avatar__name {
transition: none;
}
}
`;var n2e=`
.block-canvas-cover {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
pointer-events: none;
z-index: 20000;
}
.block-canvas-cover .collaborators-overlay-full {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
}
.block-canvas-cover .collaborators-overlay-fixed {
position: fixed;
width: 100%;
height: 100%;
}
.collaborators-overlay-user {
position: absolute;
}
/* Cursor lines render below avatar labels across all users. The parent
.collaborators-overlay-user has no z-index so it does not create a
stacking context \u2014 children participate in the shared overlay context. */
.collaborators-overlay-user-cursor {
position: absolute;
z-index: 0;
width: ${$Re};
border-radius: ${rK};
outline: ${rK} solid ${Yg};
box-shadow: ${YD};
animation: collaborators-overlay-cursor-blink 1s infinite;
}
.collaborators-overlay-selection-rect {
position: absolute;
opacity: 0.15;
pointer-events: none;
border-radius: 2px;
}
/* Overlay-specific positioning applied to the Avatar cursor label. */
.collaborators-overlay-user-label.editor-avatar {
position: absolute;
z-index: 1;
transform: translate(-11px, -100%);
margin-top: -${qD};
pointer-events: auto;
overflow: visible;
width: max-content;
}
/* Avatar positioned above a highlighted block as a label. */
.collaborators-overlay-block-label.editor-avatar {
position: absolute;
z-index: 1;
transform: translateY(calc(-100% - ${KD}));
pointer-events: auto;
overflow: visible;
width: max-content;
}
@keyframes collaborators-overlay-cursor-blink {
0%, 45% { opacity: 1; }
55%, 95% { opacity: 0; }
100% { opacity: 1; }
}
.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-cursor {
animation: collaborators-overlay-cursor-highlight 0.6s ease-in-out 3;
}
.collaborators-overlay-cursor-highlighted .collaborators-overlay-user-label {
animation: collaborators-overlay-label-highlight 0.6s ease-in-out 3;
}
@keyframes collaborators-overlay-cursor-highlight {
0%, 100% {
transform: scale(1);
filter: drop-shadow(0 0 0 transparent);
}
50% {
transform: scale(1.2);
filter: drop-shadow(0 0 8px currentColor);
}
}
@keyframes collaborators-overlay-label-highlight {
0%, 100% {
transform: translate(-11px, -100%) scale(1);
filter: drop-shadow(0 0 0 transparent);
}
50% {
transform: translate(-11px, -100%) scale(1.1);
filter: drop-shadow(0 0 6px currentColor);
}
}
.block-editor-block-list__block.is-collaborator-selected:not(:focus)::after {
content: "";
position: absolute;
pointer-events: none;
top: 0;
right: 0;
bottom: 0;
left: 0;
outline-color: var(--collaborator-outline-color);
outline-style: solid;
outline-width: calc(var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));
outline-offset: calc(-1 * var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1));
box-shadow: inset 0 0 0 calc((var(--wp-admin-border-width-focus) / var(--wp-block-editor-iframe-zoom-out-scale, 1)) + 0.5px) rgba(${Yg}, 0.7);
z-index: 1;
}
@media (prefers-reduced-motion: reduce) {
.collaborators-overlay-user-label,
.collaborators-overlay-user-cursor {
animation: none;
}
}
`;function i2e(e,t){let r=null,o=()=>{try{e()}catch{}r=setTimeout(o,t)};return r=setTimeout(o,t),()=>{r&&clearTimeout(r)}}var iK=a(ae(),1),Sx=a(U(),1);var _x=a(U(),1);function ZD(e){let[t,r]=(0,_x.useState)(0),o=(0,_x.useRef)(null),n=(0,_x.useCallback)(()=>(o.current&&clearTimeout(o.current),o.current=setTimeout(()=>{r(i=>i+1)},e),()=>{o.current&&clearTimeout(o.current)}),[e]);return[t,n]}var{useActiveCollaborators:rct,useResolvedSelection:oct}=q(iK.privateApis),{SelectionType:nct}=q(iK.privateApis);function s2e(e,t,r,o,n){let i=(0,Sx.useRef)(new Set),s=rct(r??null,o??null),l=oct(r??null,o??null),[c,u]=(0,Sx.useState)([]),[d,f]=ZD(n);return(0,Sx.useEffect)(()=>{if(!t){u([]);return}let m=i.current,h=new Set,g=s.filter(y=>{let w=y.editorState?.selection?.type===nct.WholeBlock;return!y.isMe&&w}).map(y=>{let w;try{({localClientId:w}=l(y.editorState?.selection))}catch{return null}return w?{blockId:w,color:y.isMe?"var(--wp-admin-theme-color)":za(y.collaboratorInfo.id),userName:y.collaboratorInfo.name,avatarUrl:tm(y.collaboratorInfo.avatar_urls)}:null}).filter(y=>!y||h.has(y.blockId)?!1:(h.add(y.blockId),!0)),v=new Set(g.map(y=>y.blockId));for(let y of m)if(!v.has(y)){let w=nK(t,y);w&&(w.classList.remove("is-collaborator-selected"),w.style.removeProperty("--collaborator-outline-color")),m.delete(y)}let b=[],_=e?.getBoundingClientRect()??null;return g.forEach(y=>{let{color:w,blockId:S,userName:x,avatarUrl:C}=y,A=nK(t,S);if(A&&(A.classList.add("is-collaborator-selected"),A.style.setProperty("--collaborator-outline-color",w),m.add(S),_)){let P=A.getBoundingClientRect();b.push({blockId:S,userName:x,avatarUrl:C,color:w,x:P.left-_.left,y:P.top-_.top})}}),u(b),()=>{for(let y of m){let w=nK(t,y);w&&(w.classList.remove("is-collaborator-selected"),w.style.removeProperty("--collaborator-outline-color"))}m.clear()}},[s,t,e,d,l]),{highlights:c,rerenderHighlightsAfterDelay:f}}var nK=(e,t)=>e.querySelector(`[data-block="${t}"]`);var aK=a(ae(),1),f2e=a(Y(),1),$D=a(U(),1),p2e=a(Lt(),1);var u2e=a(ae(),1);var ict=500,XD=(e,t,r,o)=>e===null||!t?null:sct(t,e,r,o)??null,sct=(e,t,r,o)=>{let{node:n,offset:i}=sK(e,t,r),s=r.createRange();try{s.setStart(n,i)}catch{return null}s.collapse(!0);let l=s.getBoundingClientRect(),c=e.getBoundingClientRect(),u=0,d=0;l.x===0&&l.y===0&&l.width===0&&l.height===0?(u=c.left-o.left,d=c.top-o.top):(u=l.left-o.left,d=l.top-o.top);let f=l.height;if(f===0){let m=r.defaultView??window;f=parseInt(m.getComputedStyle(e).lineHeight,10)||c.height}return{x:u,y:d,height:f}},QD=(e,t,r,o,n)=>{let i=t,s=r;i>s&&([i,s]=[s,i]);let l=sK(e,i,o),c=sK(e,s,o),u=o.createRange();try{u.setStart(l.node,l.offset),u.setEnd(c.node,c.offset)}catch{return null}let d=u.getClientRects(),f=[];for(let m of d){if(m.width===0&&m.height===0)continue;let h=m.left-n.left,g=m.top-n.top;f.some(b=>b.x===h&&b.y===g&&b.width===m.width&&b.height===m.height)||f.push({x:h,y:g,width:m.width,height:m.height})}return f.length>0?f:null},a2e=(e,t,r)=>{let o=t.createRange();o.selectNodeContents(e);let n=o.getClientRects(),i=[];for(let s of n)s.width===0&&s.height===0||i.push({x:s.left-r.left,y:s.top-r.top,width:s.width,height:s.height});if(i.length===0){let s=e.getBoundingClientRect();s.width>0&&s.height>0&&i.push({x:s.left-r.left,y:s.top-r.top,width:s.width,height:s.height})}return i},l2e=(e,t,r)=>{let o=r.querySelectorAll("[data-block]"),n=-1,i=-1;for(let l=0;l<o.length;l++){let c=o[l].getAttribute("data-block");c===e&&(n=l),c===t&&(i=l)}if(n===-1||i===-1)return[];n>i&&([n,i]=[i,n]);let s=[];for(let l=n+1;l<i;l++)s.push(o[l]);return s},sK=(e,t,r)=>{let o=r.createTreeWalker(e,NodeFilter.SHOW_TEXT|NodeFilter.SHOW_ELEMENT),n=0,i=null,s=null,l=1;for(;s=o.nextNode();){if(l++,l>ict)return i?{node:i,offset:0}:{node:e,offset:0};let c=s.nodeValue?.length??0;if(s.nodeType===Node.ELEMENT_NODE)if(s.nodeName==="BR"){if(n+1>=t){let u=o.nextNode();return u?.nodeType===Node.TEXT_NODE?{node:u,offset:0}:i?{node:i,offset:i.nodeValue?.length??0}:{node:e,offset:0}}n+=1;continue}else continue;if(c!==0){if(n+c>=t)return{node:s,offset:t-n};n+=c,s.nodeType===Node.TEXT_NODE&&(i=s)}}return i&&i.n
.is-root-container.alignwide:where(.is-layout-flow) > :not(.alignleft):not(.alignright) { max-width: var(--wp--style--global--wide-size);}
.is-root-container.alignfull { max-width: none; margin-left: auto; margin-right: auto;}
.is-root-container.alignfull:where(.is-layout-flow) > :not(.alignleft):not(.alignright) { max-width: none;}`,ue=[kk,Mi,Fu].includes(h),te=ue&&!g&&!n&&!C||b,de=h===kk&&g,[pe,$]=X2e(!g&&i==="post-only"&&!m),fe=te&&_&&R?.height>0&&R?.width>yK?Nct(_,R):"100%",ve="display:flex;align-items:center;justify-content:center;",Oe=b&&!ue?"min-height:100vh;":"",ee=(0,Sl.useMemo)(()=>[...v??[],{css:`:where(.block-editor-iframe__body){display:flow-root;}.is-root-container{display:flow-root;${te||de?"min-height:0!important;":""}}
${$||""}
${te?`.block-editor-iframe__html{background:var(--wp-editor-canvas-background);min-height:100vh;${ve}}.block-editor-iframe__body{width:100%;${Oe}}`:""}${de?`.block-editor-iframe__body{${ve}padding:var(--wp--style--block-gap,2em);}`:""}`}],[v,te,ve,Oe,de,$]),ne=(0,pc.__unstableUseTypewriter)();return r=(0,Tx.useMergeRefs)([A,r,i==="post-only"?ne:null,Ict({isEnabled:i==="template-locked"}),W2e({isEnabled:i==="template-locked"}),Y2e(),pe,J2e()]),(0,di.jsxs)("div",{ref:k,className:J("editor-visual-editor","edit-post-visual-editor",o,{"has-vertical-padding":f||b,"has-horizontal-padding":f||te}),children:[(0,di.jsx)(oAe,{}),(0,di.jsx)(fS,{enableResizing:te,width:te&&_?_+"px":"100%",height:fe,children:(0,di.jsxs)(Act,{shouldIframe:!0,contentRef:r,styles:ee,height:"100%",iframeProps:{...t,style:t?.style},children:[x&&!S&&i==="post-only"&&!m&&(0,di.jsxs)(di.Fragment,{children:[(0,di.jsx)(yL,{selector:".editor-visual-editor__post-title-wrapper",layout:E}),(0,di.jsx)(yL,{selector:".block-editor-block-list__layout.is-root-container",layout:K}),D&&(0,di.jsx)(yL,{css:Q}),O&&(0,di.jsx)(yL,{layout:B,css:O})]}),i==="post-only"&&!m&&(0,di.jsx)("div",{className:J("editor-visual-editor__post-title-wrapper","edit-post-visual-editor__post-title-wrapper",{"has-global-padding":w}),contentEditable:!1,style:{marginTop:"4rem"},children:(0,di.jsx)(cD,{ref:Z})}),(0,di.jsxs)(pc.RecursionProvider,{blockName:c,uniqueId:u,children:[(0,di.jsx)(pc.BlockList,{className:J("is-"+d.toLowerCase()+"-preview",i!=="post-only"||m?"wp-site-blocks":`${L} wp-block-post-content`,{"has-global-padding":i==="post-only"&&!m&&w}),layout:W,dropZoneElement:A.current?.parentNode,__unstableDisableDropZone:i==="template-locked"}),i==="template-locked"&&(0,di.jsx)(z2e,{contentRef:A})]})]})})]})}var _L=Mct;var xl=a(U(),1),SL=a(Ce(),1),aAe=a(Y(),1),xL=a(be(),1),QP=a(j(),1);var Qg=a(T(),1),{useBlockElementRef:Fct}=q(xL.privateApis);function lAe(e){let t=[];for(let r of e)r.__revisionDiffStatus?.status&&t.push({clientId:r.clientId,status:r.__revisionDiffStatus.status}),r.innerBlocks?.length&&t.push(...lAe(r.innerBlocks));return t}var sAe={added:(0,QP.__)("Go to added block"),removed:(0,QP.__)("Go to removed block"),modified:(0,QP.__)("Go to modified block")};function wK(e){if(!e)return null;let t=e.ownerDocument,r=t.documentElement.scrollHeight,o=e.getBoundingClientRect(),n=t.documentElement.scrollTop;return{top:(o.top+n)/r*100,height:o.height/r*100}}function Dct({clientId:e,status:t,subscribe:r}){let o=(0,xl.useRef)();Fct(e,o);let[n,i]=(0,xl.useState)(()=>wK(o.current));return(0,xl.useEffect)(()=>r(()=>{i(wK(o.current))}),[r]),(0,xl.useEffect)(()=>{i(wK(o.current))},[t]),n?(0,Qg.jsxs)(Ze.Root,{children:[(0,Qg.jsx)(Ze.Trigger,{render:(0,Qg.jsx)("button",{className:`revision-diff-marker is-${t}`,style:{top:`${n.top}%`,height:`${Math.max(n.height,.5)}%`},onClick:()=>o.current?.focus(),"aria-label":sAe[t]})}),(0,Qg.jsx)(Ze.Popup,{children:sAe[t]})]}):null}function cAe(){let[e,t]=(0,xl.useState)(!1),r=(0,xl.useRef)(new Set),o=(0,aAe.useSelect)(l=>l(xL.store).getBlocks(),[]),n=(0,xl.useMemo)(()=>lAe(o),[o]),i=(0,xl.useCallback)(l=>(r.current.add(l),()=>r.current.delete(l)),[]),s=(0,SL.useRefEffect)(l=>{let{ownerDocument:c}=l,{defaultView:u}=c,d=new u.ResizeObserver(()=>{r.current.forEach(f=>f())});return d.observe(c.body),()=>{d.disconnect()}},[]);return[(0,SL.useMergeRefs)([s,t]),(0,Qg.jsx)("div",{className:"revision-diff-markers",role:"navigation","aria-label":(0,QP.__)("Document changes"),children:e&&n.map(({clientId:l,status:c})=>(0,Qg.jsx)(Dct,{clientId:l,status:c,subscribe:i},l))},"diff-markers")]}var ho=a(T(),1),{usePrivateStyleOverride:uAe,PrivateBlockContext:dAe}=q(pAe.privateApis),Lct=`
<svg
xmlns="http://www.w3.org/2000/svg"
viewBox="0 0 0 0"
width="0"
height="0"
focusable="false"
role="none"
aria-hidden="true"
style="visibility: hidden; position: absolute; left: -9999px; overflow: hidden;"
>
<defs>
<filter id="revision-removed-filter" x="0" y="0" width="100%" height="100%">
<!-- Desaturate and add red tint -->
<feColorMatrix type="matrix"
values="0.5 0.3 0.2 0 0.15
0.2 0.2 0.1 0 0
0.2 0.2 0.1 0 0
0 0 0 0.8 0"/>
</filter>
</defs>
</svg>
`,Vct=`
.is-revision-added {
box-shadow: inset 0 0 0 9999px color-mix(in srgb, currentColor 5%, #00a32a 15%), 0 0 0 4px color-mix(in srgb, currentColor 5%, #00a32a 15%);
outline: 3px solid #00a32a;
outline-offset: 2px;
}
.is-revision-removed,
.revision-diff-removed {
text-decoration: line-through;
filter: url(#revision-removed-filter);
}
.is-revision-removed {
outline: 3px dashed #d63638;
outline-offset: 2px;
}
.is-revision-modified {
outline: 3px dotted #9a7000 !important;
outline-offset: 2px;
}
.revision-diff-added {
background-color: color-mix(in srgb, currentColor 5%, #00a32a 15%);
text-decoration: none;
}
/* Reset UA <mark> styles so format markers keep the same look as before. */
mark.revision-diff-format-added,
mark.revision-diff-format-removed,
mark.revision-diff-format-changed {
background: transparent;
color: inherit;
padding: 0;
}
.revision-diff-format-added {
text-decoration: underline wavy color-mix(in srgb, currentColor 30%, #00a32a 70%);
text-decoration-thickness: 2px;
}
.revision-diff-format-removed {
text-decoration: underline wavy color-mix(in srgb, currentColor 20%, #d63638 80%);
text-decoration-thickness: 2px;
}
.revision-diff-format-changed {
text-decoration: underline wavy color-mix(in srgb, currentColor 30%, #dba617 70%);
text-decoration-thickness: 2px;
}
`;function Bct(e,t){switch(e){case"added":return(0,Cl.sprintf)((0,Cl.__)("Added block: %s"),t);case"removed":return(0,Cl.sprintf)((0,Cl.__)("Removed block: %s"),t);case"modified":return(0,Cl.sprintf)((0,Cl.__)("Modified block: %s"),t)}}function jct({status:e,name:t,attributes:r,children:o}){let n=(0,CL.useContext)(dAe),i=(0,_K.useSelect)(s=>{let{getActiveBlockVariation:l,getBlockType:c}=s(hAe.store);return l(t,r)?.title??c(t)?.title},[t,r]);return(0,ho.jsx)(dAe.Provider,{value:{...n,ariaLabel:i?Bct(e,i):void 0},children:o})}function zct(e){return function(r){let{block:o,className:n,name:i,attributes:s}=r,l=o?.__revisionDiffStatus?.status,c=J(n,{"is-revision-added":l==="added","is-revision-removed":l==="removed","is-revision-modified":l==="modified"});return l?(0,ho.jsx)(jct,{status:l,name:i,attributes:s,children:(0,ho.jsx)(e,{...r,className:c})}):(0,ho.jsx)(e,{...r,className:c})}}var Hct="editor/revisions-canvas/withRevisionDiffClasses";(0,mAe.addFilter)("editor.BlockListBlock",Hct,zct);function Uct({showDiff:e}){return uAe({css:e?Vct:""}),uAe({assets:e?Lct:"",__unstableType:"svgs"}),null}function Wct(){return(0,ho.jsxs)(Yt,{children:[(0,ho.jsx)("span",{id:ic.removed,children:(0,Cl.__)("Removed")}),(0,ho.jsx)("span",{id:ic.added,children:(0,Cl.__)("Added")}),(0,ho.jsx)("span",{id:ic.formatAdded,children:(0,Cl.__)("Format added")}),(0,ho.jsx)("span",{id:ic.formatRemoved,children:(0,Cl.__)("Format removed")}),(0,ho.jsx)("span",{id:ic.formatChanged,children:(0,Cl.__)("Format changed")})]})}function Gct({showDiff:e}){let[t,r]=cAe();return(0,ho.jsxs)(ho.Fragment,{children:[e&&(0,ho.jsx)(Wct,{}),(0,ho.jsx)(_L,{contentRef:t}),e&&r]})}function SK(){(0,CL.useEffect)(()=>(bwe(),()=>{ywe()}),[]);let{revision:e,showDiff:t}=(0,_K.useSelect)(r=>{let{getCurrentRevision:o,isShowingRevisionDiff:n}=q(r(I));return{revision:o(),showDiff:n()}},[]);return e?(0,ho.jsxs)(ho.Fragment,{children:[(0,ho.jsx)(Uct,{showDiff:t}),(0,ho.jsx)("div",{className:"editor-revisions-canvas__content",children:(0,ho.jsx)(Gct,{showDiff:t})})]}):(0,ho.jsx)("div",{className:"editor-revisions-canvas__loading",children:(0,ho.jsx)(fAe.Spinner,{})})}var TL=a(Y(),1),EL=a(U(),1),mc=a(j(),1),gAe=a(It(),1),vAe=a(ae(),1),bAe=a(Lt(),1);var{useOnCollaboratorJoin:Yct,useOnCollaboratorLeave:qct,useOnPostSave:Kct}=q(vAe.privateApis),xK={COLLAB_POST_UPDATED:"collab-post-updated",COLLAB_USER_ENTERED:"collab-user-entered",COLLAB_USER_EXITED:"collab-user-exited"},CK=["publish","private","future"];function Zct(e,t,r){return r?(0,mc.sprintf)((0,mc.__)("Post published by %s."),e):CK.includes(t)?(0,mc.sprintf)((0,mc.__)("Post updated by %s."),e):(0,mc.sprintf)((0,mc.__)("Draft saved by %s."),e)}function yAe(e,t){let{postStatus:r,isCollaborationEnabled:o,showJoinNotifications:n,showLeaveNotifications:i,showPostSaveNotifications:s}=(0,TL.useSelect)(y=>{let{getCurrentPostAttribute:w,isCollaborationEnabledForCurrentPost:S}=q(y(I)),x=C=>y(bAe.store).get("core",C)??!0;return{postStatus:w("status"),isCollaborationEnabled:S(),showJoinNotifications:x("showCollaborationJoinNotifications"),showLeaveNotifications:x("showCollaborationLeaveNotifications"),showPostSaveNotifications:x("showCollaborationPostSaveNotifications")}},[]),{createNotice:l}=(0,TL.useDispatch)(gAe.store),c=o&&n,u=o&&i,d=o&&s,f=y=>y?[e,t]:[null,null],[m,h]=f(c),[g,v]=f(u),[b,_]=f(d);Yct(m,h,(0,EL.useCallback)((y,w)=>{c&&(w&&y.collaboratorInfo.enteredAt<w.collaboratorInfo.enteredAt||l("info",(0,mc.sprintf)((0,mc.__)("%s has joined the post."),y.collaboratorInfo.name),{id:`${xK.COLLAB_USER_ENTERED}-${y.collaboratorInfo.id}`,type:"snackbar",isDismissible:!1}))},[l,c])),qct(g,v,(0,EL.useCallback)(y=>{u&&l("info",(0,mc.sprintf)((0,mc.__)("%s has left the post."),y.collaboratorInfo.name),{id:`${xK.COLLAB_USER_EXITED}-${y.collaboratorInfo.id}`,type:"snackbar",isDismissible:!1})},[l,u])),Kct(b,_,(0,EL.useCallback)((y,w,S)=>{if(!d||!r)return;let x=y.postStatus??r??"draft",C=S?.postStatus??r,A=!(C&&CK.includes(C))&&CK.includes(x),P=Zct(w.collaboratorInfo.name,x,A);l("info",P,{id:`${xK.COLLAB_POST_UPDATED}-${w.collaboratorInfo.id}`,type:"s
/*! Bundled license information:
use-sync-external-store/cjs/use-sync-external-store-shim.production.js:
(**
* @license React
* use-sync-external-store-shim.production.js
*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js:
(**
* @license React
* use-sync-external-store-shim/with-selector.production.js
*
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*)
autosize/dist/autosize.js:
(*!
autosize 4.0.2
license: MIT
http://www.jacklmoore.com/autosize
*)
is-plain-object/dist/is-plain-object.mjs:
(*!
* is-plain-object <https://github.com/jonschlinkert/is-plain-object>
*
* Copyright (c) 2014-2017, Jon Schlinkert.
* Released under the MIT License.
*)
*/
(window.wp ||= {}).editor = wp.editor;
})();