/*! This file is auto-generated */ this.wp=this.wp||{},this.wp.blockLibrary=function(e){var t={};function n(o){if(t[o])return t[o].exports;var r=t[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=e,n.c=t,n.d=function(e,t,o){n.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},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 o=Object.create(null);if(n.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)n.d(o,r,function(t){return e[t]}.bind(null,r));return o},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="K51g")}({"+WrK":function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(o.createElement)(r.Path,{d:"M21.3 10.8l-5.6-5.6c-.7-.7-1.8-.7-2.5 0l-5.6 5.6c-.7.7-.7 1.8 0 2.5l5.6 5.6c.3.3.8.5 1.2.5s.9-.2 1.2-.5l5.6-5.6c.8-.7.8-1.9.1-2.5zm-1 1.4l-5.6 5.6c-.1.1-.3.1-.4 0l-5.6-5.6c-.1-.1-.1-.3 0-.4l5.6-5.6s.1-.1.2-.1.1 0 .2.1l5.6 5.6c.1.1.1.3 0 .4zm-16.6-.4L10 5.5l-1-1-6.3 6.3c-.7.7-.7 1.8 0 2.5L9 19.5l1.1-1.1-6.3-6.3c-.2 0-.2-.2-.1-.3z"}));t.a=a},"//kF":function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(o.createElement)(r.Path,{fillRule:"evenodd",d:"M18 5.5h-8v8h8.5V6a.5.5 0 00-.5-.5zm-9.5 8h-3V6a.5.5 0 01.5-.5h2.5v8zM6 4h12a2 2 0 012 2v12a2 2 0 01-2 2H6a2 2 0 01-2-2V6a2 2 0 012-2z"}));t.a=a},"1CF3":function(e,t){e.exports=window.wp.dom},"1Yn1":function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(o.createElement)(r.Path,{d:"M20.8 10.7l-4.3-4.3-1.1 1.1 4.3 4.3c.1.1.1.3 0 .4l-4.3 4.3 1.1 1.1 4.3-4.3c.7-.8.7-1.9 0-2.6zM4.2 11.8l4.3-4.3-1-1-4.3 4.3c-.7.7-.7 1.8 0 2.5l4.3 4.3 1.1-1.1-4.3-4.3c-.2-.1-.2-.3-.1-.4z"}));t.a=a},"1ZqX":function(e,t){e.exports=window.wp.data},"1iEr":function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(o.createElement)(r.Path,{d:"M10.6 6L9.4 7l4.6 5-4.6 5 1.2 1 5.4-6z"}));t.a=a},"2gm7":function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(o.createElement)(r.Path,{d:"M14.6 7l-1.2-1L8 12l5.4 6 1.2-1-4.6-5z"}));t.a=a},"4eJC":function(e,t,n){e.exports=function(e,t){var n,o,r=0;function a(){var a,l,c=n,i=arguments.length;e:for(;c;){if(c.args.length===arguments.length){for(l=0;ll?(n=a/l,c=100,i=Math.round(c/n)):(n=l/a,i=100,c=Math.round(i/n)),(c>a||i>l||c<10||i<10)&&(c=a,i=l)),{srcLeft:o,srcTop:r,srcWidth:a,srcHeight:l,destWidth:c,destHeight:i}}},{key:"_simpleAlgorithm",value:function(e,t,n){for(var o=0,r=0,a=0,l=0,c=0,i=0;io?-1:n===o?0:1}))[0],5),d=m[0],b=m[1],p=m[2],g=m[3],h=m[4];return g?[Math.round(d/g),Math.round(b/g),Math.round(p/g),Math.round(g/h)]:[0,0,0,0]}},{key:"_bindImageEvents",value:function(e,t,n){var o=this,r=(n=n||{})&&n.data,a=this._getDefaultColor(n),l=function(){s(),t.call(e,o.getColor(e,n),r)},c=function(){s(),t.call(e,o._prepareResult(a,new Error("Image error")),r)},i=function(){s(),t.call(e,o._prepareResult(a,new Error("Image abort")),r)},s=function(){e.removeEventListener("load",l),e.removeEventListener("error",c),e.removeEventListener("abort",i)};e.addEventListener("load",l),e.addEventListener("error",c),e.addEventListener("abort",i)}},{key:"_prepareResult",value:function(e,t){var n=e.slice(0,3),o=[].concat(n,e[3]/255),r=this._isDark(e);return{error:t,value:e,rgb:"rgb("+n.join(",")+")",rgba:"rgba("+o.join(",")+")",hex:this._arrayToHex(n),hexa:this._arrayToHex(e),isDark:r,isLight:!r}}},{key:"_getOriginalSize",value:function(e){return e instanceof HTMLImageElement?{width:e.naturalWidth,height:e.naturalHeight}:e instanceof HTMLVideoElement?{width:e.videoWidth,height:e.videoHeight}:{width:e.width,height:e.height}}},{key:"_toHex",value:function(e){var t=e.toString(16);return 1===t.length?"0"+t:t}},{key:"_arrayToHex",value:function(e){return"#"+e.map(this._toHex).join("")}},{key:"_isDark",value:function(e){return(299*e[0]+587*e[1]+114*e[2])/1e3<128}},{key:"_makeCanvas",value:function(){return"undefined"==typeof window?new OffscreenCanvas(1,1):document.createElement("canvas")}}])&&e(o.prototype,r),a&&e(o,a),n}()}()},FqII:function(e,t){e.exports=window.wp.date},G8mJ:function(e,t,n){"use strict";var o=n("GRId"),r=n("Tqx9");const a=Object(o.createElement)(r.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(o.createElement)(r.Path,{d:"M18.5 10.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},JREk:function(e,t){e.exports=window.wp.serverSideRender},K51g:function(e,t,n){"use strict";n.r(t),n.d(t,"__experimentalGetCoreBlocks",(function(){return Np})),n.d(t,"registerCoreBlocks",(function(){return Pp})),n.d(t,"__experimentalRegisterExperimentalCoreBlocks",(function(){return zp}));var o={};n.r(o),n.d(o,"metadata",(function(){return Se})),n.d(o,"name",(function(){return Be})),n.d(o,"settings",(function(){return Te}));var r={};n.r(r),n.d(r,"metadata",(function(){return Je})),n.d(r,"name",(function(){return Qe})),n.d(r,"settings",(function(){return Ye}));var a={};n.r(a),n.d(a,"metadata",(function(){return vt})),n.d(a,"name",(function(){return Ot})),n.d(a,"settings",(function(){return jt}));var l={};n.r(l),n.d(l,"metadata",(function(){return St})),n.d(l,"name",(function(){return Bt})),n.d(l,"settings",(function(){return Tt}));var c={};n.r(c),n.d(c,"metadata",(function(){return Rt})),n.d(c,"name",(function(){return Lt})),n.d(c,"settings",(function(){return Vt}));var i={};n.r(i),n.d(i,"metadata",(function(){return Ft})),n.d(i,"name",(function(){return Dt})),n.d(i,"settings",(function(){return Gt}));var s={};n.r(s),n.d(s,"metadata",(function(){return $t})),n.d(s,"name",(function(){return Zt})),n.d(s,"settings",(function(){return Kt}));var u={};n.r(u),n.d(u,"metadata",(function(){return en})),n.d(u,"name",(function(){return tn})),n.d(u,"settings",(function(){return nn}));var m={};n.r(m),n.d(m,"metadata",(function(){return ln})),n.d(m,"name",(function(){return cn})),n.d(m,"settings",(function(){return sn}));var d={};n.r(d),n.d(d,"metadata",(function(){return kn})),n.d(d,"name",(function(){return wn})),n.d(d,"settings",(function(){return En}));var b={};n.r(b),n.d(b,"metadata",(function(){return Jn})),n.d(b,"name",(function(){return Qn})),n.d(b,"settings",(function(){return Yn}));var p={};n.r(p),n.d(p,"metadata",(function(){return Mo})),n.d(p,"name",(function(){return Ro})),n.d(p,"settings",(function(){return Lo}));var g={};n.r(g),n.d(g,"metadata",(function(){return Jo})),n.d(g,"name",(function(){return Qo})),n.d(g,"settings",(function(){return Yo}));var h={};n.r(h),n.d(h,"metadata",(function(){return Ar})),n.d(h,"name",(function(){return Hr})),n.d(h,"settings",(function(){return Fr}));var v={};n.r(v),n.d(v,"metadata",(function(){return Zr})),n.d(v,"name",(function(){return Kr})),n.d(v,"settings",(function(){return Jr}));var O={};n.r(O),n.d(O,"metadata",(function(){return ga})),n.d(O,"name",(function(){return ha})),n.d(O,"settings",(function(){return va}));var j={};n.r(j),n.d(j,"metadata",(function(){return ya})),n.d(j,"name",(function(){return fa})),n.d(j,"settings",(function(){return _a}));var y={};n.r(y),n.d(y,"metadata",(function(){return Ma})),n.d(y,"name",(function(){return Ra})),n.d(y,"settings",(function(){return La}));var f={};n.r(f),n.d(f,"metadata",(function(){return Aa})),n.d(f,"name",(function(){return Ha})),n.d(f,"settings",(function(){return Fa}));var _={};n.r(_),n.d(_,"metadata",(function(){return Ja})),n.d(_,"name",(function(){return Qa})),n.d(_,"settings",(function(){return Ya}));var k={};n.r(k),n.d(k,"metadata",(function(){return ml})),n.d(k,"name",(function(){return dl})),n.d(k,"settings",(function(){return bl}));var w={};n.r(w),n.d(w,"metadata",(function(){return gl})),n.d(w,"name",(function(){return hl})),n.d(w,"settings",(function(){return vl}));var E={};n.r(E),n.d(E,"metadata",(function(){return Rl})),n.d(E,"name",(function(){return Ll})),n.d(E,"settings",(function(){return Vl}));var C={};n.r(C),n.d(C,"metadata",(function(){return Fl})),n.d(C,"name",(function(){return Dl})),n.d(C,"settings",(function(){return Gl}));var x={};n.r(x),n.d(x,"metadata",(function(){return $l})),n.d(x,"name",(function(){return Zl})),n.d(x,"settings",(function(){return Kl}));var S={};n.r(S),n.d(S,"metadata",(function(){return Pc})),n.d(S,"name",(function(){return zc})),n.d(S,"settings",(function(){return Ic}));var B={};n.r(B),n.d(B,"metadata",(function(){return Ac})),n.d(B,"name",(function(){return Hc})),n.d(B,"settings",(function(){return Fc}));var T={};n.r(T),n.d(T,"metadata",(function(){return ni})),n.d(T,"name",(function(){return oi})),n.d(T,"settings",(function(){return ri}));var N={};n.r(N),n.d(N,"metadata",(function(){return bi})),n.d(N,"name",(function(){return pi})),n.d(N,"settings",(function(){return gi}));var P={};n.r(P),n.d(P,"metadata",(function(){return Oi})),n.d(P,"name",(function(){return ji})),n.d(P,"settings",(function(){return yi}));var z={};n.r(z),n.d(z,"metadata",(function(){return _i})),n.d(z,"name",(function(){return ki})),n.d(z,"settings",(function(){return wi}));var I={};n.r(I),n.d(I,"metadata",(function(){return Ii})),n.d(I,"name",(function(){return Mi})),n.d(I,"settings",(function(){return Ri}));var M={};n.r(M),n.d(M,"metadata",(function(){return $i})),n.d(M,"name",(function(){return Zi})),n.d(M,"settings",(function(){return Ki}));var R={};n.r(R),n.d(R,"metadata",(function(){return Yi})),n.d(R,"name",(function(){return Xi})),n.d(R,"settings",(function(){return es}));var L={};n.r(L),n.d(L,"metadata",(function(){return os})),n.d(L,"name",(function(){return rs})),n.d(L,"settings",(function(){return as}));var V={};n.r(V),n.d(V,"metadata",(function(){return bs})),n.d(V,"name",(function(){return ps})),n.d(V,"settings",(function(){return gs}));var A={};n.r(A),n.d(A,"metadata",(function(){return Os})),n.d(A,"name",(function(){return js})),n.d(A,"settings",(function(){return ys}));var H={};n.r(H),n.d(H,"metadata",(function(){return _s})),n.d(H,"name",(function(){return ks})),n.d(H,"settings",(function(){return ws}));var F={};n.r(F),n.d(F,"metadata",(function(){return Ps})),n.d(F,"name",(function(){return zs})),n.d(F,"settings",(function(){return Is}));var D={};n.r(D),n.d(D,"metadata",(function(){return As})),n.d(D,"name",(function(){return Hs})),n.d(D,"settings",(function(){return Fs}));var G={};n.r(G),n.d(G,"metadata",(function(){return Us})),n.d(G,"name",(function(){return Ws})),n.d(G,"settings",(function(){return $s}));var q={};n.r(q),n.d(q,"metadata",(function(){return Js})),n.d(q,"name",(function(){return Qs})),n.d(q,"settings",(function(){return Ys}));var U={};n.r(U),n.d(U,"metadata",(function(){return eu})),n.d(U,"name",(function(){return tu})),n.d(U,"settings",(function(){return nu}));var W={};n.r(W),n.d(W,"metadata",(function(){return au})),n.d(W,"name",(function(){return lu})),n.d(W,"settings",(function(){return cu}));var $={};n.r($),n.d($,"metadata",(function(){return pu})),n.d($,"name",(function(){return gu})),n.d($,"settings",(function(){return hu}));var Z={};n.r(Z),n.d(Z,"metadata",(function(){return Lu})),n.d(Z,"name",(function(){return Vu})),n.d(Z,"settings",(function(){return Au}));var K={};n.r(K),n.d(K,"metadata",(function(){return qu})),n.d(K,"name",(function(){return Uu})),n.d(K,"settings",(function(){return Wu}));var J={};n.r(J),n.d(J,"metadata",(function(){return Ku})),n.d(J,"name",(function(){return Ju})),n.d(J,"settings",(function(){return Qu}));var Q={};n.r(Q),n.d(Q,"metadata",(function(){return em})),n.d(Q,"name",(function(){return tm})),n.d(Q,"settings",(function(){return nm}));var Y={};n.r(Y),n.d(Y,"metadata",(function(){return am})),n.d(Y,"name",(function(){return lm})),n.d(Y,"settings",(function(){return cm}));var X={};n.r(X),n.d(X,"metadata",(function(){return bm})),n.d(X,"name",(function(){return pm})),n.d(X,"settings",(function(){return gm}));var ee={};n.r(ee),n.d(ee,"metadata",(function(){return fm})),n.d(ee,"name",(function(){return _m})),n.d(ee,"settings",(function(){return km}));var te={};n.r(te),n.d(te,"metadata",(function(){return xm})),n.d(te,"name",(function(){return Sm})),n.d(te,"settings",(function(){return Bm}));var ne={};n.r(ne),n.d(ne,"metadata",(function(){return Nm})),n.d(ne,"name",(function(){return Pm})),n.d(ne,"settings",(function(){return zm}));var oe={};n.r(oe),n.d(oe,"metadata",(function(){return Fm})),n.d(oe,"name",(function(){return Dm})),n.d(oe,"settings",(function(){return Gm}));var re={};n.r(re),n.d(re,"metadata",(function(){return Zm})),n.d(re,"name",(function(){return Km})),n.d(re,"settings",(function(){return Jm}));var ae={};n.r(ae),n.d(ae,"metadata",(function(){return ed})),n.d(ae,"name",(function(){return td})),n.d(ae,"settings",(function(){return nd}));var le={};n.r(le),n.d(le,"metadata",(function(){return ld})),n.d(le,"name",(function(){return cd})),n.d(le,"settings",(function(){return id}));var ce={};n.r(ce),n.d(ce,"metadata",(function(){return md})),n.d(ce,"name",(function(){return dd})),n.d(ce,"settings",(function(){return bd}));var ie={};n.r(ie),n.d(ie,"metadata",(function(){return jd})),n.d(ie,"name",(function(){return yd})),n.d(ie,"settings",(function(){return fd}));var se={};n.r(se),n.d(se,"metadata",(function(){return Bd})),n.d(se,"name",(function(){return Td})),n.d(se,"settings",(function(){return Nd}));var ue={};n.r(ue),n.d(ue,"metadata",(function(){return Vd})),n.d(ue,"name",(function(){return Ad})),n.d(ue,"settings",(function(){return Hd}));var me={};n.r(me),n.d(me,"metadata",(function(){return Gd})),n.d(me,"name",(function(){return qd})),n.d(me,"settings",(function(){return Ud}));var de={};n.r(de),n.d(de,"metadata",(function(){return Ob})),n.d(de,"name",(function(){return jb})),n.d(de,"settings",(function(){return yb}));var be={};n.r(be),n.d(be,"metadata",(function(){return _b})),n.d(be,"name",(function(){return kb})),n.d(be,"settings",(function(){return wb}));var pe={};n.r(pe),n.d(pe,"metadata",(function(){return Ub})),n.d(pe,"name",(function(){return Wb})),n.d(pe,"settings",(function(){return $b}));var ge={};n.r(ge),n.d(ge,"metadata",(function(){return Kb})),n.d(ge,"name",(function(){return Jb})),n.d(ge,"settings",(function(){return Qb}));var he={};n.r(he),n.d(he,"metadata",(function(){return tp})),n.d(he,"name",(function(){return np})),n.d(he,"settings",(function(){return op}));var ve={};n.r(ve),n.d(ve,"metadata",(function(){return cp})),n.d(ve,"name",(function(){return ip})),n.d(ve,"settings",(function(){return sp}));var Oe={};n.r(Oe),n.d(Oe,"metadata",(function(){return xp})),n.d(Oe,"name",(function(){return Sp})),n.d(Oe,"settings",(function(){return Bp}));var je=n("HSyU"),ye=n("GRId"),fe=n("Tqx9");var _e=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M19 6.2h-5.9l-.6-1.1c-.3-.7-1-1.1-1.8-1.1H5c-1.1 0-2 .9-2 2v11.8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8.2c0-1.1-.9-2-2-2zm.5 11.6c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h5.8c.2 0 .4.1.4.3l1 2H19c.3 0 .5.2.5.5v9.5zM8 12.8h8v-1.5H8v1.5zm0 3h8v-1.5H8v1.5z"})),ke=n("tI+e"),we=n("l3Sj"),Ee=n("axFQ"),Ce=n("JREk"),xe=n.n(Ce);const Se={apiVersion:2,name:"core/archives",title:"Archives",category:"widgets",description:"Display a monthly archive of your posts.",textdomain:"default",attributes:{displayAsDropdown:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1}},supports:{align:!0,html:!1},editorStyle:"wp-block-archives-editor"},{name:Be}=Se,Te={icon:_e,example:{},edit:function({attributes:e,setAttributes:t}){const{showPostCounts:n,displayAsDropdown:o}=e;return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Archives settings")},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Display as dropdown"),checked:o,onChange:()=>t({displayAsDropdown:!o})}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show post counts"),checked:n,onChange:()=>t({showPostCounts:!n})}))),Object(ye.createElement)("div",Object(Ee.useBlockProps)(),Object(ye.createElement)(ke.Disabled,null,Object(ye.createElement)(xe.a,{block:"core/archives",attributes:e}))))}};var Ne=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M17.7 4.3c-1.2 0-2.8 0-3.8 1-.6.6-.9 1.5-.9 2.6V14c-.6-.6-1.5-1-2.5-1C8.6 13 7 14.6 7 16.5S8.6 20 10.5 20c1.5 0 2.8-1 3.3-2.3.5-.8.7-1.8.7-2.5V7.9c0-.7.2-1.2.5-1.6.6-.6 1.8-.6 2.8-.6h.3V4.3h-.4z"})),Pe=[{attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{align:!0},save({attributes:e}){const{autoplay:t,caption:n,loop:o,preload:r,src:a}=e;return Object(ye.createElement)("figure",null,Object(ye.createElement)("audio",{controls:"controls",src:a,autoPlay:t,loop:o,preload:r}),!Ee.RichText.isEmpty(n)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:n}))}}],ze=n("xTGt"),Ie=n("1ZqX");const Me=[{ratio:"2.33",className:"wp-embed-aspect-21-9"},{ratio:"2.00",className:"wp-embed-aspect-18-9"},{ratio:"1.78",className:"wp-embed-aspect-16-9"},{ratio:"1.33",className:"wp-embed-aspect-4-3"},{ratio:"1.00",className:"wp-embed-aspect-1-1"},{ratio:"0.56",className:"wp-embed-aspect-9-16"},{ratio:"0.50",className:"wp-embed-aspect-1-2"}];var Re=n("YLtl"),Le=n("A/WM"),Ve=n.n(Le),Ae=n("4eJC"),He=n.n(Ae);const{name:Fe}={apiVersion:2,name:"core/embed",title:"Embed",category:"embed",description:"Add a block that displays content pulled from other sites, like Twitter or YouTube.",textdomain:"default",attributes:{url:{type:"string"},caption:{type:"string",source:"html",selector:"figcaption"},type:{type:"string"},providerNameSlug:{type:"string"},allowResponsive:{type:"boolean",default:!0},responsive:{type:"boolean",default:!1},previewable:{type:"boolean",default:!0}},supports:{align:!0},editorStyle:"wp-block-embed-editor",style:"wp-block-embed"},De=e=>e&&e.includes('class="wp-embedded-content"'),Ge=(e,t={})=>{var n;const{preview:o,attributes:r={}}=e,{url:a,providerNameSlug:l,type:c,...i}=r;if(!a||!Object(je.getBlockType)(Fe))return;const s=(e=>{var t;return null===(t=Object(je.getBlockVariations)(Fe))||void 0===t?void 0:t.find(({patterns:t})=>((e,t=[])=>t.some(t=>e.match(t)))(e,t))})(a),u="wordpress"===l||"wp-embed"===c;if(!u&&s&&(s.attributes.providerNameSlug!==l||!l))return Object(je.createBlock)(Fe,{url:a,...i,...s.attributes});const m=null===(n=Object(je.getBlockVariations)(Fe))||void 0===n?void 0:n.find(({name:e})=>"wordpress"===e);return m&&o&&De(o.html)&&!u?Object(je.createBlock)(Fe,{url:a,...m.attributes,...t}):void 0},qe=e=>{if(!e)return e;const t=Me.reduce((e,{className:t})=>(e[t]=!1,e),{"wp-has-aspect-ratio":!1});return Ve()(e,t)};function Ue(e,t,n=!0){if(!n)return qe(t);const o=document.implementation.createHTMLDocument("");o.body.innerHTML=e;const r=o.body.querySelector("iframe");if(r&&r.height&&r.width){const e=(r.width/r.height).toFixed(2);for(let n=0;n=o.ratio){return e-o.ratio>.1?qe(t):Ve()(qe(t),o.className,"wp-has-aspect-ratio")}}}return t}const We=He()((e,t,n,o,r=!0)=>{if(!e)return{};const a={};let{type:l="rich"}=e;const{html:c,provider_name:i}=e,s=Object(Re.kebabCase)((i||t).toLowerCase());return De(c)&&(l="wp-embed"),(c||"photo"===l)&&(a.type=l,a.providerNameSlug=s),a.className=Ue(c,n,o&&r),a}),$e=["audio"];var Ze=Object(ke.withNotices)((function({attributes:e,noticeOperations:t,setAttributes:n,onReplace:o,isSelected:r,noticeUI:a,insertBlocksAfter:l}){const{id:c,autoplay:i,caption:s,loop:u,preload:m,src:d}=e,b=Object(Ee.useBlockProps)(),p=Object(Ie.useSelect)(e=>{const{getSettings:t}=e(Ee.store);return t().mediaUpload},[]);function g(e){return t=>{n({[e]:t})}}function h(e){if(e!==d){const t=Ge({attributes:{url:e}});if(void 0!==t)return void o(t);n({src:e,id:void 0})}}function v(e){t.removeAllNotices(),t.createErrorNotice(e)}function O(e){e&&e.url?n({src:e.url,id:e.id}):n({src:void 0,id:void 0})}return Object(ye.useEffect)(()=>{if(!c&&Object(ze.isBlobURL)(d)){const e=Object(ze.getBlobByURL)(d);e&&p({filesList:[e],onFileChange:([{id:e,url:t}])=>{n({id:e,src:t})},onError:e=>{n({src:void 0,id:void 0}),t.createErrorNotice(e)},allowedTypes:$e})}},[]),d?Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,{group:"other"},Object(ye.createElement)(Ee.MediaReplaceFlow,{mediaId:c,mediaURL:d,allowedTypes:$e,accept:"audio/*",onSelect:O,onSelectURL:h,onError:v})),Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Audio settings")},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Autoplay"),onChange:g("autoplay"),checked:i,help:function(e){return e?Object(we.__)("Autoplay may cause usability issues for some users."):null}}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Loop"),onChange:g("loop"),checked:u}),Object(ye.createElement)(ke.SelectControl,{label:Object(we._x)("Preload","noun; Audio block parameter"),value:m||"",onChange:e=>n({preload:e||void 0}),options:[{value:"",label:Object(we.__)("Browser default")},{value:"auto",label:Object(we.__)("Auto")},{value:"metadata",label:Object(we.__)("Metadata")},{value:"none",label:Object(we._x)("None",'"Preload" value')}]}))),Object(ye.createElement)("figure",b,Object(ye.createElement)(ke.Disabled,{isDisabled:!r},Object(ye.createElement)("audio",{controls:"controls",src:d})),(!Ee.RichText.isEmpty(s)||r)&&Object(ye.createElement)(Ee.RichText,{tagName:"figcaption","aria-label":Object(we.__)("Audio caption text"),placeholder:Object(we.__)("Add caption"),value:s,onChange:e=>n({caption:e}),inlineToolbar:!0,__unstableOnSplitAtEnd:()=>l(Object(je.createBlock)("core/paragraph"))}))):Object(ye.createElement)("div",b,Object(ye.createElement)(Ee.MediaPlaceholder,{icon:Object(ye.createElement)(Ee.BlockIcon,{icon:Ne}),onSelect:O,onSelectURL:h,accept:"audio/*",allowedTypes:$e,value:e,notices:a,onError:v}))}));var Ke={from:[{type:"files",isMatch:e=>1===e.length&&0===e[0].type.indexOf("audio/"),transform(e){const t=e[0];return Object(je.createBlock)("core/audio",{src:Object(ze.createBlobURL)(t)})}},{type:"shortcode",tag:"audio",attributes:{src:{type:"string",shortcode:({named:{src:e,mp3:t,m4a:n,ogg:o,wav:r,wma:a}})=>e||t||n||o||r||a},loop:{type:"string",shortcode:({named:{loop:e}})=>e},autoplay:{type:"string",shortcode:({named:{autoplay:e}})=>e},preload:{type:"string",shortcode:({named:{preload:e}})=>e}}}]};const Je={apiVersion:2,name:"core/audio",title:"Audio",category:"media",description:"Embed a simple audio player.",keywords:["music","sound","podcast","recording"],textdomain:"default",attributes:{src:{type:"string",source:"attribute",selector:"audio",attribute:"src"},caption:{type:"string",source:"html",selector:"figcaption"},id:{type:"number"},autoplay:{type:"boolean",source:"attribute",selector:"audio",attribute:"autoplay"},loop:{type:"boolean",source:"attribute",selector:"audio",attribute:"loop"},preload:{type:"string",source:"attribute",selector:"audio",attribute:"preload"}},supports:{anchor:!0,align:!0},editorStyle:"wp-block-audio-editor",style:"wp-block-audio"},{name:Qe}=Je,Ye={icon:Ne,example:{attributes:{src:"https://upload.wikimedia.org/wikipedia/commons/d/dd/Armstrong_Small_Step.ogg"}},transforms:Ke,deprecated:Pe,edit:Ze,save:function({attributes:e}){const{autoplay:t,caption:n,loop:o,preload:r,src:a}=e;return a&&Object(ye.createElement)("figure",Ee.useBlockProps.save(),Object(ye.createElement)("audio",{controls:"controls",src:a,autoPlay:t,loop:o,preload:r}),!Ee.RichText.isEmpty(n)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:n}))}};var Xe=n("oMoS"),et=n("TSYQ"),tt=n.n(et),nt=n("K9lf");const ot=e=>{if(!Object(Re.isObject)(e)||Array.isArray(e))return e;const t=Object(Re.pickBy)(Object(Re.mapValues)(e,ot),Re.identity);return Object(Re.isEmpty)(t)?void 0:t};var rt=ot,at=function(e){var t,n;if(null==e||null===(t=e.style)||void 0===t||null===(n=t.typography)||void 0===n||!n.fontFamily)return e;const o=Object(Re.cloneDeep)(e),r=o.style.typography.fontFamily.split("|").pop();return delete o.style.typography.fontFamily,o.style=rt(o.style),{...o,fontFamily:r}};const lt=e=>{var t,n,o;const{borderRadius:r,...a}=e,l=[r,null===(t=a.style)||void 0===t||null===(n=t.border)||void 0===n?void 0:n.radius].find(e=>"number"==typeof e&&0!==e);return l?{...a,style:{...a.style,border:{...null===(o=a.style)||void 0===o?void 0:o.border,radius:l+"px"}}}:a},ct=e=>{if(!e.customTextColor&&!e.customBackgroundColor&&!e.customGradient)return e;const t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),e.customGradient&&(t.color.gradient=e.customGradient),{...Object(Re.omit)(e,["customTextColor","customBackgroundColor","customGradient"]),style:t}},it=e=>ct(Object(Re.omit)({...e,customTextColor:e.textColor&&"#"===e.textColor[0]?e.textColor:void 0,customBackgroundColor:e.color&&"#"===e.color[0]?e.color:void 0},["color","textColor"])),st={url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"}};var ut=[{attributes:{url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},width:{type:"number"}},supports:{anchor:!0,align:!0,alignWide:!1,color:{__experimentalSkipSerialization:!0,gradients:!0},typography:{fontSize:!0,__experimentalFontFamily:!0},reusable:!1,spacing:{__experimentalSkipSerialization:!0,padding:["horizontal","vertical"],__experimentalDefaultControls:{padding:!0}},__experimentalBorder:{radius:!0,__experimentalSkipSerialization:!0},__experimentalSelector:".wp-block-button__link"},save({attributes:e,className:t}){var n,o;const{fontSize:r,linkTarget:a,rel:l,style:c,text:i,title:s,url:u,width:m}=e;if(!i)return null;const d=Object(Ee.__experimentalGetBorderClassesAndStyles)(e),b=Object(Ee.__experimentalGetColorClassesAndStyles)(e),p=Object(Ee.__experimentalGetSpacingClassesAndStyles)(e),g=tt()("wp-block-button__link",b.className,d.className,{"no-border-radius":0===(null==c||null===(n=c.border)||void 0===n?void 0:n.radius)}),h={...d.style,...b.style,...p.style},v=tt()(t,{["has-custom-width wp-block-button__width-"+m]:m,"has-custom-font-size":r||(null==c||null===(o=c.typography)||void 0===o?void 0:o.fontSize)});return Object(ye.createElement)("div",Ee.useBlockProps.save({className:v}),Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:g,href:u,title:s,style:h,value:i,target:a,rel:l}))},migrate:at,isEligible({style:e}){var t;return null==e||null===(t=e.typography)||void 0===t?void 0:t.fontFamily}},{supports:{anchor:!0,align:!0,alignWide:!1,color:{__experimentalSkipSerialization:!0,gradients:!0},typography:{fontSize:!0,__experimentalFontFamily:!0},reusable:!1,__experimentalSelector:".wp-block-button__link"},attributes:{...st,linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},width:{type:"number"}},isEligible({style:e}){var t;return"number"==typeof(null==e||null===(t=e.border)||void 0===t?void 0:t.radius)},save({attributes:e,className:t}){var n,o,r;const{fontSize:a,linkTarget:l,rel:c,style:i,text:s,title:u,url:m,width:d}=e;if(!s)return null;const b=null==i||null===(n=i.border)||void 0===n?void 0:n.radius,p=Object(Ee.__experimentalGetColorClassesAndStyles)(e),g=tt()("wp-block-button__link",p.className,{"no-border-radius":0===(null==i||null===(o=i.border)||void 0===o?void 0:o.radius)}),h={borderRadius:b||void 0,...p.style},v=tt()(t,{["has-custom-width wp-block-button__width-"+d]:d,"has-custom-font-size":a||(null==i||null===(r=i.typography)||void 0===r?void 0:r.fontSize)});return Object(ye.createElement)("div",Ee.useBlockProps.save({className:v}),Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:g,href:m,title:u,style:h,value:s,target:l,rel:c}))},migrate:Object(nt.compose)(at,lt)},{supports:{anchor:!0,align:!0,alignWide:!1,color:{__experimentalSkipSerialization:!0},reusable:!1,__experimentalSelector:".wp-block-button__link"},attributes:{...st,linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},style:{type:"object"},width:{type:"number"}},save({attributes:e,className:t}){const{borderRadius:n,linkTarget:o,rel:r,text:a,title:l,url:c,width:i}=e,s=Object(Ee.__experimentalGetColorClassesAndStyles)(e),u=tt()("wp-block-button__link",s.className,{"no-border-radius":0===n}),m={borderRadius:n?n+"px":void 0,...s.style},d=tt()(t,{["has-custom-width wp-block-button__width-"+i]:i});return Object(ye.createElement)("div",Ee.useBlockProps.save({className:d}),Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:u,href:c,title:l,style:m,value:a,target:o,rel:r}))},migrate:Object(nt.compose)(at,lt)},{supports:{anchor:!0,align:!0,alignWide:!1,color:{__experimentalSkipSerialization:!0},reusable:!1,__experimentalSelector:".wp-block-button__link"},attributes:{...st,linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},style:{type:"object"},width:{type:"number"}},save({attributes:e,className:t}){const{borderRadius:n,linkTarget:o,rel:r,text:a,title:l,url:c,width:i}=e,s=Object(Ee.__experimentalGetColorClassesAndStyles)(e),u=tt()("wp-block-button__link",s.className,{"no-border-radius":0===n}),m={borderRadius:n?n+"px":void 0,...s.style},d=tt()(t,{["has-custom-width wp-block-button__width-"+i]:i});return Object(ye.createElement)("div",Ee.useBlockProps.save({className:d}),Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:u,href:c,title:l,style:m,value:a,target:o,rel:r}))},migrate:Object(nt.compose)(at,lt)},{supports:{align:!0,alignWide:!1,color:{gradients:!0}},attributes:{...st,linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},style:{type:"object"}},save({attributes:e}){const{borderRadius:t,linkTarget:n,rel:o,text:r,title:a,url:l}=e,c=tt()("wp-block-button__link",{"no-border-radius":0===t}),i={borderRadius:t?t+"px":void 0};return Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:c,href:l,title:a,style:i,value:r,target:n,rel:o})},migrate:lt},{supports:{align:!0,alignWide:!1},attributes:{...st,linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},borderRadius:{type:"number"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},customGradient:{type:"string"},gradient:{type:"string"}},isEligible:e=>!!e.customTextColor||!!e.customBackgroundColor||!!e.customGradient,migrate:Object(nt.compose)(lt,ct),save({attributes:e}){const{backgroundColor:t,borderRadius:n,customBackgroundColor:o,customTextColor:r,customGradient:a,linkTarget:l,gradient:c,rel:i,text:s,textColor:u,title:m,url:d}=e,b=Object(Ee.getColorClassName)("color",u),p=!a&&Object(Ee.getColorClassName)("background-color",t),g=Object(Ee.__experimentalGetGradientClass)(c),h=tt()("wp-block-button__link",{"has-text-color":u||r,[b]:b,"has-background":t||o||a||c,[p]:p,"no-border-radius":0===n,[g]:g}),v={background:a||void 0,backgroundColor:p||a||c?void 0:o,color:b?void 0:r,borderRadius:n?n+"px":void 0};return Object(ye.createElement)("div",null,Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:h,href:d,title:m,style:v,value:s,target:l,rel:i}))}},{attributes:{...st,align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"}},isEligible:e=>e.className&&e.className.includes("is-style-squared"),migrate(e){let t=e.className;return t&&(t=t.replace(/is-style-squared[\s]?/,"").trim()),lt(ct({...e,className:t||void 0,borderRadius:0}))},save({attributes:e}){const{backgroundColor:t,customBackgroundColor:n,customTextColor:o,linkTarget:r,rel:a,text:l,textColor:c,title:i,url:s}=e,u=Object(Ee.getColorClassName)("color",c),m=Object(Ee.getColorClassName)("background-color",t),d=tt()("wp-block-button__link",{"has-text-color":c||o,[u]:u,"has-background":t||n,[m]:m}),b={backgroundColor:m?void 0:n,color:u?void 0:o};return Object(ye.createElement)("div",null,Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:d,href:s,title:i,style:b,value:l,target:r,rel:a}))}},{attributes:{...st,align:{type:"string",default:"none"},backgroundColor:{type:"string"},textColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"}},migrate:it,save({attributes:e}){const{url:t,text:n,title:o,backgroundColor:r,textColor:a,customBackgroundColor:l,customTextColor:c}=e,i=Object(Ee.getColorClassName)("color",a),s=Object(Ee.getColorClassName)("background-color",r),u=tt()("wp-block-button__link",{"has-text-color":a||c,[i]:i,"has-background":r||l,[s]:s}),m={backgroundColor:s?void 0:l,color:i?void 0:c};return Object(ye.createElement)("div",null,Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:u,href:t,title:o,style:m,value:n}))}},{attributes:{...st,color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}},save({attributes:e}){const{url:t,text:n,title:o,align:r,color:a,textColor:l}=e,c={backgroundColor:a,color:l};return Object(ye.createElement)("div",{className:"align"+r},Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:"wp-block-button__link",href:t,title:o,style:c,value:n}))},migrate:it},{attributes:{...st,color:{type:"string"},textColor:{type:"string"},align:{type:"string",default:"none"}},save({attributes:e}){const{url:t,text:n,title:o,align:r,color:a,textColor:l}=e;return Object(ye.createElement)("div",{className:"align"+r,style:{backgroundColor:a}},Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",href:t,title:o,style:{color:l},value:n}))},migrate:it}],mt=n("wx14"),dt=n("RxS6"),bt=n("Bpkj"),pt=n("Mp0b");function gt({selectedWidth:e,setAttributes:t}){return Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Width settings")},Object(ye.createElement)(ke.ButtonGroup,{"aria-label":Object(we.__)("Button width")},[25,50,75,100].map(n=>Object(ye.createElement)(ke.Button,{key:n,isSmall:!0,variant:n===e?"primary":void 0,onClick:()=>{var o;t({width:e===(o=n)?void 0:o})}},n,"%"))))}var ht=function(e){var t;const{attributes:n,setAttributes:o,className:r,isSelected:a,onReplace:l,mergeBlocks:c}=e,{linkTarget:i,placeholder:s,rel:u,style:m,text:d,url:b,width:p}=n,g=Object(ye.useCallback)(e=>{o({rel:e})},[o]),h=Object(Ee.__experimentalUseBorderProps)(n),v=Object(Ee.__experimentalUseColorProps)(n),O=Object(Ee.__experimentalGetSpacingClassesAndStyles)(n),j=Object(ye.useRef)(),y=Object(ye.useRef)(),f=Object(Ee.useBlockProps)({ref:j,onKeyDown:function(e){if(dt.isKeyboardEvent.primary(e,"k"))C(e);else if(dt.isKeyboardEvent.primaryShift(e,"k")){var t;x(),null===(t=y.current)||void 0===t||t.focus()}}}),[_,k]=Object(ye.useState)(!1),w=!!b,E="_blank"===i;function C(e){e.preventDefault(),k(!0)}function x(){o({url:void 0,linkTarget:void 0,rel:void 0}),k(!1)}return Object(ye.useEffect)(()=>{a||k(!1)},[a]),Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)("div",Object(mt.a)({},f,{className:tt()(f.className,{["has-custom-width wp-block-button__width-"+p]:p,"has-custom-font-size":f.style.fontSize})}),Object(ye.createElement)(Ee.RichText,{ref:y,"aria-label":Object(we.__)("Button text"),placeholder:s||Object(we.__)("Add text…"),value:d,onChange:e=>{o({text:e.replace(/<\/?a[^>]*>/g,"")})},withoutInteractiveFormatting:!0,className:tt()(r,"wp-block-button__link",v.className,h.className,{"no-border-radius":0===(null==m||null===(t=m.border)||void 0===t?void 0:t.radius)}),style:{...h.style,...v.style,...O.style},onSplit:e=>Object(je.createBlock)("core/button",{...n,text:e}),onReplace:l,onMerge:c,identifier:"text"})),Object(ye.createElement)(Ee.BlockControls,{group:"block"},!w&&Object(ye.createElement)(ke.ToolbarButton,{name:"link",icon:bt.a,title:Object(we.__)("Link"),shortcut:dt.displayShortcut.primary("k"),onClick:C}),w&&Object(ye.createElement)(ke.ToolbarButton,{name:"link",icon:pt.a,title:Object(we.__)("Unlink"),shortcut:dt.displayShortcut.primaryShift("k"),onClick:x,isActive:!0})),a&&(_||w)&&Object(ye.createElement)(ke.Popover,{position:"bottom center",onClose:()=>{var e;k(!1),null===(e=y.current)||void 0===e||e.focus()},anchorRef:null==j?void 0:j.current,focusOnMount:!!_&&"firstElement"},Object(ye.createElement)(Ee.__experimentalLinkControl,{className:"wp-block-navigation-link__inline-link-input",value:{url:b,opensInNewTab:E},onChange:({url:e="",opensInNewTab:t})=>{o({url:e}),E!==t&&function(e){const t=e?"_blank":void 0;let n=u;t&&!u?n="noreferrer noopener":t||"noreferrer noopener"!==u||(n=void 0),o({linkTarget:t,rel:n})}(t)},onRemove:()=>{var e;x(),null===(e=y.current)||void 0===e||e.focus()},forceIsEditingLink:_})),Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(gt,{selectedWidth:p,setAttributes:o})),Object(ye.createElement)(Ee.InspectorControls,{__experimentalGroup:"advanced"},Object(ye.createElement)(ke.TextControl,{label:Object(we.__)("Link rel"),value:u||"",onChange:g})))};const vt={apiVersion:2,name:"core/button",title:"Button",category:"design",parent:["core/buttons"],description:"Prompt visitors to take action with a button-style link.",keywords:["link"],textdomain:"default",attributes:{url:{type:"string",source:"attribute",selector:"a",attribute:"href"},title:{type:"string",source:"attribute",selector:"a",attribute:"title"},text:{type:"string",source:"html",selector:"a"},linkTarget:{type:"string",source:"attribute",selector:"a",attribute:"target"},rel:{type:"string",source:"attribute",selector:"a",attribute:"rel"},placeholder:{type:"string"},backgroundColor:{type:"string"},textColor:{type:"string"},gradient:{type:"string"},width:{type:"number"}},supports:{anchor:!0,align:!0,alignWide:!1,color:{__experimentalSkipSerialization:!0,gradients:!0},typography:{fontSize:!0,__experimentalFontFamily:!0,__experimentalDefaultControls:{fontSize:!0}},reusable:!1,spacing:{__experimentalSkipSerialization:!0,padding:["horizontal","vertical"],__experimentalDefaultControls:{padding:!0}},__experimentalBorder:{radius:!0,__experimentalSkipSerialization:!0},__experimentalSelector:".wp-block-button__link"},styles:[{name:"fill",label:"Fill",isDefault:!0},{name:"outline",label:"Outline"}],editorStyle:"wp-block-button-editor",style:"wp-block-button"},{name:Ot}=vt,jt={icon:Xe.a,example:{attributes:{className:"is-style-fill",text:Object(we.__)("Call to Action")}},edit:ht,save:function({attributes:e,className:t}){var n,o;const{fontSize:r,linkTarget:a,rel:l,style:c,text:i,title:s,url:u,width:m}=e;if(!i)return null;const d=Object(Ee.__experimentalGetBorderClassesAndStyles)(e),b=Object(Ee.__experimentalGetColorClassesAndStyles)(e),p=Object(Ee.__experimentalGetSpacingClassesAndStyles)(e),g=tt()("wp-block-button__link",b.className,d.className,{"no-border-radius":0===(null==c||null===(n=c.border)||void 0===n?void 0:n.radius)}),h={...d.style,...b.style,...p.style},v=tt()(t,{["has-custom-width wp-block-button__width-"+m]:m,"has-custom-font-size":r||(null==c||null===(o=c.typography)||void 0===o?void 0:o.fontSize)});return Object(ye.createElement)("div",Ee.useBlockProps.save({className:v}),Object(ye.createElement)(Ee.RichText.Content,{tagName:"a",className:g,href:u,title:s,style:h,value:i,target:a,rel:l}))},deprecated:ut,merge:(e,{text:t=""})=>({...e,text:(e.text||"")+t})};var yt=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M17 3H7c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 6c0 .3-.2.5-.5.5H7c-.3 0-.5-.2-.5-.5V5c0-.3.2-.5.5-.5h10c.3 0 .5.2.5.5v4zm-8-1.2h5V6.2h-5v1.6zM17 13H7c-1.1 0-2 .9-2 2v4c0 1.1.9 2 2 2h10c1.1 0 2-.9 2-2v-4c0-1.1-.9-2-2-2zm.5 6c0 .3-.2.5-.5.5H7c-.3 0-.5-.2-.5-.5v-4c0-.3.2-.5.5-.5h10c.3 0 .5.2.5.5v4zm-8-1.2h5v-1.5h-5v1.5z"}));const ft=e=>{if(e.layout)return e;const{contentJustification:t,orientation:n}=e,o={...e};return(t||n)&&Object.assign(o,{layout:{type:"flex",justifyContent:t||"left",orientation:n||"horizontal"}}),o};var _t=[{attributes:{contentJustification:{type:"string"},orientation:{type:"string",default:"horizontal"}},supports:{anchor:!0,align:["wide","full"],__experimentalExposeControlsToChildren:!0,spacing:{blockGap:!0,margin:["top","bottom"],__experimentalDefaultControls:{blockGap:!0}}},isEligible:({layout:e})=>!e,migrate:ft,save:({attributes:{contentJustification:e,orientation:t}})=>Object(ye.createElement)("div",Ee.useBlockProps.save({className:tt()({["is-content-justification-"+e]:e,"is-vertical":"vertical"===t})}),Object(ye.createElement)(Ee.InnerBlocks.Content,null))},{supports:{align:["center","left","right"],anchor:!0},save:()=>Object(ye.createElement)("div",null,Object(ye.createElement)(Ee.InnerBlocks.Content,null)),isEligible:({align:e})=>e&&["center","left","right"].includes(e),migrate:e=>ft({...e,align:void 0,contentJustification:e.align})}],kt=n("qRz9");const{name:wt}={apiVersion:2,name:"core/buttons",title:"Buttons",category:"design",description:"Prompt visitors to take action with a group of button-style links.",keywords:["link"],textdomain:"default",supports:{anchor:!0,align:["wide","full"],__experimentalExposeControlsToChildren:!0,spacing:{blockGap:!0,margin:["top","bottom"],__experimentalDefaultControls:{blockGap:!0}},__experimentalLayout:{allowSwitching:!1,allowInheriting:!1,default:{type:"flex"}}},editorStyle:"wp-block-buttons-editor",style:"wp-block-buttons"};var Et={from:[{type:"block",isMultiBlock:!0,blocks:["core/button"],transform:e=>Object(je.createBlock)(wt,{},e.map(e=>Object(je.createBlock)("core/button",e)))},{type:"block",isMultiBlock:!0,blocks:["core/paragraph"],transform:e=>Object(je.createBlock)(wt,{},e.map(e=>{const t=Object(kt.__unstableCreateElement)(document,e.content),n=t.innerText||"",o=t.querySelector("a"),r=null==o?void 0:o.getAttribute("href");return Object(je.createBlock)("core/button",{text:n,url:r})})),isMatch:e=>e.every(e=>{const t=Object(kt.__unstableCreateElement)(document,e.content),n=t.innerText||"",o=t.querySelectorAll("a");return n.length<=30&&o.length<=1})}]};const Ct=[Ot];var xt=function({attributes:{layout:e={}}}){const t=Object(Ee.useBlockProps)(),n=Object(Ie.useSelect)(e=>{var t;const n=e(Ee.store).getSettings().__experimentalPreferredStyleVariations;return null==n||null===(t=n.value)||void 0===t?void 0:t[Ot]},[]),o=Object(Ee.useInnerBlocksProps)(t,{allowedBlocks:Ct,template:[[Ot,{className:n&&"is-style-"+n}]],__experimentalLayout:e,templateInsertUpdatesSelection:!0});return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,{group:"block",__experimentalShareWithChildBlocks:!0}),Object(ye.createElement)("div",o))};const St={apiVersion:2,name:"core/buttons",title:"Buttons",category:"design",description:"Prompt visitors to take action with a group of button-style links.",keywords:["link"],textdomain:"default",supports:{anchor:!0,align:["wide","full"],__experimentalExposeControlsToChildren:!0,spacing:{blockGap:!0,margin:["top","bottom"],__experimentalDefaultControls:{blockGap:!0}},__experimentalLayout:{allowSwitching:!1,allowInheriting:!1,default:{type:"flex"}}},editorStyle:"wp-block-buttons-editor",style:"wp-block-buttons"},{name:Bt}=St,Tt={icon:yt,example:{innerBlocks:[{name:"core/button",attributes:{text:Object(we.__)("Find out more")}},{name:"core/button",attributes:{text:Object(we.__)("Contact us")}}]},deprecated:_t,transforms:Et,edit:xt,save:function(){const e=Ee.useInnerBlocksProps.save(Ee.useBlockProps.save());return Object(ye.createElement)("div",e)}};var Nt=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V7h15v12zM9 10H7v2h2v-2zm0 4H7v2h2v-2zm4-4h-2v2h2v-2zm4 0h-2v2h2v-2zm-4 4h-2v2h2v-2zm4 0h-2v2h2v-2z"})),Pt=n("wy2R"),zt=n.n(Pt),It=n("jZUy");const Mt=He()(e=>{if(!e)return{};const t=zt()(e);return{year:t.year(),month:t.month()+1}});const Rt={apiVersion:2,name:"core/calendar",title:"Calendar",category:"widgets",description:"A calendar of your site’s posts.",keywords:["posts","archive"],textdomain:"default",attributes:{month:{type:"integer"},year:{type:"integer"}},supports:{align:!0},style:"wp-block-calendar"},{name:Lt}=Rt,Vt={icon:Nt,example:{},edit:function({attributes:e}){const t=Object(Ee.useBlockProps)(),{date:n,hasPosts:o,hasPostsResolved:r}=Object(Ie.useSelect)(e=>{const{getEntityRecords:t,hasFinishedResolution:n}=e(It.store),o={status:"publish",per_page:1},r=t("postType","post",o),a=n("getEntityRecords",["postType","post",o]);let l;const c=e("core/editor");if(c){"post"===c.getEditedPostAttribute("type")&&(l=c.getEditedPostAttribute("date"))}return{date:l,hasPostsResolved:a,hasPosts:a&&1===(null==r?void 0:r.length)}},[]);return o?Object(ye.createElement)("div",t,Object(ye.createElement)(ke.Disabled,null,Object(ye.createElement)(xe.a,{block:"core/calendar",attributes:{...e,...Mt(n)}}))):Object(ye.createElement)("div",t,Object(ye.createElement)(ke.Placeholder,{icon:Nt,label:Object(we.__)("Calendar")},r?Object(we.__)("No published posts found."):Object(ye.createElement)(ke.Spinner,null)))}};var At=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M6 5.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5H6a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM4 6a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2H6a2 2 0 01-2-2V6zm11-.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5h-3a.5.5 0 01-.5-.5V6a.5.5 0 01.5-.5zM13 6a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2h-3a2 2 0 01-2-2V6zm5 8.5h-3a.5.5 0 00-.5.5v3a.5.5 0 00.5.5h3a.5.5 0 00.5-.5v-3a.5.5 0 00-.5-.5zM15 13a2 2 0 00-2 2v3a2 2 0 002 2h3a2 2 0 002-2v-3a2 2 0 00-2-2h-3zm-9 1.5h3a.5.5 0 01.5.5v3a.5.5 0 01-.5.5H6a.5.5 0 01-.5-.5v-3a.5.5 0 01.5-.5zM4 15a2 2 0 012-2h3a2 2 0 012 2v3a2 2 0 01-2 2H6a2 2 0 01-2-2v-3z",fillRule:"evenodd",clipRule:"evenodd"}));var Ht=Object(ye.createElement)(fe.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},Object(ye.createElement)(fe.Path,{d:"M10.44 3.02l1.82-1.82 6.36 6.35-1.83 1.82c-1.05-.68-2.48-.57-3.41.36l-.75.75c-.92.93-1.04 2.35-.35 3.41l-1.83 1.82-2.41-2.41-2.8 2.79c-.42.42-3.38 2.71-3.8 2.29s1.86-3.39 2.28-3.81l2.79-2.79L4.1 9.36l1.83-1.82c1.05.69 2.48.57 3.4-.36l.75-.75c.93-.92 1.05-2.35.36-3.41z"}));const Ft={apiVersion:2,name:"core/categories",title:"Categories",category:"widgets",description:"Display a list of all categories.",textdomain:"default",attributes:{displayAsDropdown:{type:"boolean",default:!1},showHierarchy:{type:"boolean",default:!1},showPostCounts:{type:"boolean",default:!1},showOnlyTopLevel:{type:"boolean",default:!1}},supports:{align:!0,html:!1},editorStyle:"wp-block-categories-editor",style:"wp-block-categories"},{name:Dt}=Ft,Gt={icon:At,example:{},edit:function e({attributes:{displayAsDropdown:t,showHierarchy:n,showPostCounts:o,showOnlyTopLevel:r},setAttributes:a}){const l=Object(nt.useInstanceId)(e,"blocks-category-select"),{categories:c,isRequesting:i}=Object(Ie.useSelect)(e=>{const{getEntityRecords:t,isResolving:n}=e(It.store),o={per_page:-1,hide_empty:!0,context:"view"};return r&&(o.parent=0),{categories:t("taxonomy","category",o),isRequesting:n("getEntityRecords",["taxonomy","category",o])}},[r]),s=e=>null!=c&&c.length?null===e?c:c.filter(({parent:t})=>t===e):[],u=e=>"wp-block-categories__list wp-block-categories__list-level-"+e,m=e=>t=>a({[e]:t}),d=e=>e?Object(Re.unescape)(e).trim():Object(we.__)("(Untitled)"),b=(e,t)=>{const r=s(e.id),{id:a,link:l,count:c,name:i}=e;return Object(ye.createElement)("li",{key:a},Object(ye.createElement)("a",{href:l,target:"_blank",rel:"noreferrer noopener"},d(i)),o&&Object(ye.createElement)("span",{className:"wp-block-categories__post-count"},` (${c})`),n&&!!r.length&&Object(ye.createElement)("ul",{className:u(t+1)},r.map(e=>b(e,t+1))))},p=(e,t)=>{const{id:r,count:a,name:l}=e,c=s(r);return[Object(ye.createElement)("option",{key:r},Object(Re.times)(3*t,()=>" "),d(l),o&&` (${a})`),n&&!!c.length&&c.map(e=>p(e,t+1))]};return Object(ye.createElement)("div",Object(Ee.useBlockProps)(),Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Categories settings")},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Display as dropdown"),checked:t,onChange:m("displayAsDropdown")}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show post counts"),checked:o,onChange:m("showPostCounts")}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show only top level categories"),checked:r,onChange:m("showOnlyTopLevel")}),!r&&Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show hierarchy"),checked:n,onChange:m("showHierarchy")}))),i&&Object(ye.createElement)(ke.Placeholder,{icon:Ht,label:Object(we.__)("Categories")},Object(ye.createElement)(ke.Spinner,null)),!i&&0===(null==c?void 0:c.length)&&Object(ye.createElement)("p",null,Object(we.__)("Your site does not have any posts, so there is nothing to display here at the moment.")),!i&&(null==c?void 0:c.length)>0&&(t?(()=>{const e=s(n?0:null);return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(ke.VisuallyHidden,{as:"label",htmlFor:l},Object(we.__)("Categories")),Object(ye.createElement)("select",{id:l,className:"wp-block-categories__dropdown"},e.map(e=>p(e,0))))})():(()=>{const e=s(n?0:null);return Object(ye.createElement)("ul",{className:u(0)},e.map(e=>b(e,0)))})()))}};var qt=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M20 6H4c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm.5 11c0 .3-.2.5-.5.5H4c-.3 0-.5-.2-.5-.5V8c0-.3.2-.5.5-.5h16c.3 0 .5.2.5.5v9zM10 10H8v2h2v-2zm-5 2h2v-2H5v2zm8-2h-2v2h2v-2zm-5 6h8v-2H8v2zm6-4h2v-2h-2v2zm3 0h2v-2h-2v2zm0 4h2v-2h-2v2zM5 16h2v-2H5v2z"}));var Ut=({clientId:e})=>{const{replaceBlocks:t}=Object(Ie.useDispatch)(Ee.store),n=Object(Ie.useSelect)(t=>t(Ee.store).getBlock(e),[e]);return Object(ye.createElement)(ke.ToolbarButton,{onClick:()=>t(n.clientId,Object(je.rawHandler)({HTML:Object(je.serialize)(n)}))},Object(we.__)("Convert to blocks"))};const{wp:Wt}=window;const $t={apiVersion:2,name:"core/freeform",title:"Classic",category:"text",description:"Use the classic WordPress editor.",textdomain:"default",attributes:{content:{type:"string",source:"html"}},supports:{className:!1,customClassName:!1,reusable:!1},editorStyle:"wp-block-freeform-editor"},{name:Zt}=$t,Kt={icon:qt,edit:function({clientId:e,attributes:{content:t},setAttributes:n,onReplace:o}){const{getMultiSelectedBlockClientIds:r}=Object(Ie.useSelect)(Ee.store),a=Object(ye.useRef)(!1);return Object(ye.useEffect)(()=>{if(!a.current)return;const n=window.tinymce.get("editor-"+e);(null==n?void 0:n.getContent())!==t&&n.setContent(t||"")},[t]),Object(ye.useEffect)(()=>{const{baseURL:l,suffix:c}=window.wpEditorL10n.tinymce;function i(e){let a;t&&e.on("loadContent",()=>e.setContent(t)),e.on("blur",()=>{var t;a=e.selection.getBookmark(2,!0);const o=document.querySelector(".interface-interface-skeleton__content"),l=o.scrollTop;return null!==(t=r())&&void 0!==t&&t.length||n({content:e.getContent()}),e.once("focus",()=>{a&&(e.selection.moveToBookmark(a),o.scrollTop!==l&&(o.scrollTop=l))}),!1}),e.on("mousedown touchstart",()=>{a=null});const l=Object(Re.debounce)(()=>{const t=e.getContent();t!==e._lastChange&&(e._lastChange=t,n({content:t}))},250);e.on("Paste Change input Undo Redo",l),e.on("remove",l.cancel),e.on("keydown",t=>{dt.isKeyboardEvent.primary(t,"z")&&t.stopPropagation(),t.keyCode!==dt.BACKSPACE&&t.keyCode!==dt.DELETE||!function(e){const t=e.getBody();return!(t.childNodes.length>1)&&(0===t.childNodes.length||!(t.childNodes[0].childNodes.length>1)&&/^\n?$/.test(t.innerText||t.textContent))}(e)||(o([]),t.preventDefault(),t.stopImmediatePropagation());const{altKey:n}=t;n&&t.keyCode===dt.F10&&t.stopPropagation()}),e.on("init",()=>{const t=e.getBody();t.ownerDocument.activeElement===t&&(t.blur(),e.focus())})}function s(){const{settings:t}=window.wpEditorL10n.tinymce;Wt.oldEditor.initialize("editor-"+e,{tinymce:{...t,inline:!0,content_css:!1,fixed_toolbar_container:"#toolbar-"+e,setup:i}})}function u(){"complete"===document.readyState&&s()}return a.current=!0,window.tinymce.EditorManager.overrideDefaults({base_url:l,suffix:c}),"complete"===document.readyState?s():document.addEventListener("readystatechange",u),()=>{document.removeEventListener("readystatechange",u),Wt.oldEditor.remove("editor-"+e)}},[]),Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,null,Object(ye.createElement)(ke.ToolbarGroup,null,Object(ye.createElement)(Ut,{clientId:e}))),Object(ye.createElement)("div",Object(Ee.useBlockProps)(),Object(ye.createElement)("div",{key:"toolbar",id:"toolbar-"+e,className:"block-library-classic__toolbar",onClick:function(){const t=window.tinymce.get("editor-"+e);t&&t.focus()},"data-placeholder":Object(we.__)("Classic"),onKeyDown:function(e){e.stopPropagation(),e.nativeEvent.stopImmediatePropagation()}}),Object(ye.createElement)("div",{key:"editor",id:"editor-"+e,className:"wp-block-freeform block-library-rich-text__tinymce"})))},save:function({attributes:e}){const{content:t}=e;return Object(ye.createElement)(ye.RawHTML,null,t)}};var Jt=n("1Yn1");function Qt(e){return e.replace(/\[/g,"[")}function Yt(e){return e.replace(/^(\s*https?:)\/\/([^\s<>"]+\s*)$/m,"$1//$2")}var Xt={from:[{type:"enter",regExp:/^```$/,transform:()=>Object(je.createBlock)("core/code")},{type:"block",blocks:["core/html"],transform:({content:e})=>Object(je.createBlock)("core/code",{content:e})},{type:"raw",isMatch:e=>"PRE"===e.nodeName&&1===e.children.length&&"CODE"===e.firstChild.nodeName,schema:{pre:{children:{code:{children:{"#text":{}}}}}}}]};const en={apiVersion:2,name:"core/code",title:"Code",category:"text",description:"Display code snippets that respect your spacing and tabs.",textdomain:"default",attributes:{content:{type:"string",source:"html",selector:"code"}},supports:{anchor:!0,__experimentalSelector:".wp-block-code > code",typography:{fontSize:!0,lineHeight:!0,__experimentalFontStyle:!0,__experimentalFontWeight:!0,__experimentalLetterSpacing:!0,__experimentalTextTransform:!0,__experimentalDefaultControls:{fontSize:!0}},spacing:{margin:["top","bottom"],padding:!0},__experimentalBorder:{radius:!0,color:!0,width:!0,style:!0},color:{text:!0,background:!0,gradients:!0}},style:"wp-block-code"},{name:tn}=en,nn={icon:Jt.a,example:{attributes:{content:Object(we.__)('// A "block" is the abstract term used\n// to describe units of markup that\n// when composed together, form the\n// content or layout of a page.\nregisterBlockType( name, settings );')}},transforms:Xt,edit:function({attributes:e,setAttributes:t,onRemove:n}){const o=Object(Ee.useBlockProps)();return Object(ye.createElement)("pre",o,Object(ye.createElement)(Ee.RichText,{tagName:"code",value:e.content,onChange:e=>t({content:e}),onRemove:n,placeholder:Object(we.__)("Write code…"),"aria-label":Object(we.__)("Code"),preserveWhiteSpace:!0,__unstablePastePlainText:!0}))},save:function({attributes:e}){return Object(ye.createElement)("pre",Ee.useBlockProps.save(),Object(ye.createElement)(Ee.RichText.Content,{tagName:"code",value:(t=e.content,Object(Re.flow)(Qt,Yt)(t||""))}));var t}};var on=Object(ye.createElement)(fe.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(ye.createElement)(fe.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zM6 17.5c-.3 0-.5-.2-.5-.5V8c0-.3.2-.5.5-.5h3v10H6zm13.5-.5c0 .3-.2.5-.5.5h-3v-10h3c.3 0 .5.2.5.5v9z"}));var rn=[{attributes:{verticalAlignment:{type:"string"},width:{type:"number",min:0,max:100}},isEligible:({width:e})=>isFinite(e),migrate:e=>({...e,width:e.width+"%"}),save({attributes:e}){const{verticalAlignment:t,width:n}=e,o=tt()({["is-vertically-aligned-"+t]:t}),r={flexBasis:n+"%"};return Object(ye.createElement)("div",{className:o,style:r},Object(ye.createElement)(Ee.InnerBlocks.Content,null))}}];var an=function({attributes:{verticalAlignment:e,width:t,templateLock:n=!1,allowedBlocks:o},setAttributes:r,clientId:a}){const l=tt()("block-core-columns",{["is-vertically-aligned-"+e]:e}),c=Object(ke.__experimentalUseCustomUnits)({availableUnits:Object(Ee.useSetting)("spacing.units")||["%","px","em","rem","vw"]}),{columnsIds:i,hasChildBlocks:s,rootClientId:u}=Object(Ie.useSelect)(e=>{const{getBlockOrder:t,getBlockRootClientId:n}=e(Ee.store),o=n(a);return{hasChildBlocks:t(a).length>0,rootClientId:o,columnsIds:t(o)}},[a]),{updateBlockAttributes:m}=Object(Ie.useDispatch)(Ee.store),d=Number.isFinite(t)?t+"%":t,b=Object(Ee.useBlockProps)({className:l,style:d?{flexBasis:d}:void 0}),p=i.length,g=i.indexOf(a)+1,h=Object(we.sprintf)(Object(we.__)("%1$s (%2$d of %3$d)"),b["aria-label"],g,p),v=Object(Ee.useInnerBlocksProps)({...b,"aria-label":h},{templateLock:n,allowedBlocks:o,renderAppender:s?void 0:Ee.InnerBlocks.ButtonBlockAppender});return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,null,Object(ye.createElement)(Ee.BlockVerticalAlignmentToolbar,{onChange:e=>{r({verticalAlignment:e}),m(u,{verticalAlignment:null})},value:e})),Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Column settings")},Object(ye.createElement)(ke.__experimentalUnitControl,{label:Object(we.__)("Width"),labelPosition:"edge",__unstableInputWidth:"80px",value:t||"",onChange:e=>{e=0>parseFloat(e)?"0":e,r({width:e})},units:c}))),Object(ye.createElement)("div",v))};const ln={apiVersion:2,name:"core/column",title:"Column",category:"text",parent:["core/columns"],description:"A single column within a columns block.",textdomain:"default",attributes:{verticalAlignment:{type:"string"},width:{type:"string"},allowedBlocks:{type:"array"},templateLock:{type:"string",enum:["all","insert",!1]}},supports:{anchor:!0,reusable:!1,html:!1,color:{gradients:!0,link:!0},spacing:{padding:!0,__experimentalDefaultControls:{padding:!0}}}},{name:cn}=ln,sn={icon:on,edit:an,save:function({attributes:e}){const{verticalAlignment:t,width:n}=e,o=tt()({["is-vertically-aligned-"+t]:t});let r;if(n&&/\d/.test(n)){let e=Number.isFinite(n)?n+"%":n;if(!Number.isFinite(n)&&null!=n&&n.endsWith("%")){const t=1e12;e=Math.round(Number.parseFloat(n)*t)/t+"%"}r={flexBasis:e}}const a=Ee.useBlockProps.save({className:o,style:r}),l=Ee.useInnerBlocksProps.save(a);return Object(ye.createElement)("div",l)},deprecated:rn};var un=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M19 6H6c-1.1 0-2 .9-2 2v9c0 1.1.9 2 2 2h13c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2zm-4.1 1.5v10H10v-10h4.9zM5.5 17V8c0-.3.2-.5.5-.5h2.5v10H6c-.3 0-.5-.2-.5-.5zm14 0c0 .3-.2.5-.5.5h-2.6v-10H19c.3 0 .5.2.5.5v9z"}));function mn(e){let t,{doc:n}=mn;n||(n=document.implementation.createHTMLDocument(""),mn.doc=n),n.body.innerHTML=e;for(const e of n.body.firstChild.classList)if(t=e.match(/^layout-column-(\d+)$/))return Number(t[1])-1}var dn=[{attributes:{verticalAlignment:{type:"string"},backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},customTextColor:{type:"string"},textColor:{type:"string"}},migrate:e=>{if(!e.customTextColor&&!e.customBackgroundColor)return e;const t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),{...Object(Re.omit)(e,["customTextColor","customBackgroundColor"]),style:t,isStackedOnMobile:!0}},save({attributes:e}){const{verticalAlignment:t,backgroundColor:n,customBackgroundColor:o,textColor:r,customTextColor:a}=e,l=Object(Ee.getColorClassName)("background-color",n),c=Object(Ee.getColorClassName)("color",r),i=tt()({"has-background":n||o,"has-text-color":r||a,[l]:l,[c]:c,["are-vertically-aligned-"+t]:t}),s={backgroundColor:l?void 0:o,color:c?void 0:a};return Object(ye.createElement)("div",{className:i||void 0,style:s},Object(ye.createElement)(Ee.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},isEligible:(e,t)=>!!t.some(e=>/layout-column-\d+/.test(e.originalContent))&&t.some(e=>void 0!==mn(e.originalContent)),migrate(e,t){const n=t.reduce((e,t)=>{const{originalContent:n}=t;let o=mn(n);return void 0===o&&(o=0),e[o]||(e[o]=[]),e[o].push(t),e},[]).map(e=>Object(je.createBlock)("core/column",{},e));return[{...Object(Re.omit)(e,["columns"]),isStackedOnMobile:!0},n]},save({attributes:e}){const{columns:t}=e;return Object(ye.createElement)("div",{className:`has-${t}-columns`},Object(ye.createElement)(Ee.InnerBlocks.Content,null))}},{attributes:{columns:{type:"number",default:2}},migrate:(e,t)=>[e={...Object(Re.omit)(e,["columns"]),isStackedOnMobile:!0},t],save({attributes:e}){const{verticalAlignment:t,columns:n}=e,o=tt()(`has-${n}-columns`,{["are-vertically-aligned-"+t]:t});return Object(ye.createElement)("div",{className:o},Object(ye.createElement)(Ee.InnerBlocks.Content,null))}}];const bn=e=>{const t=parseFloat(e);return Number.isFinite(t)?parseFloat(t.toFixed(2)):void 0};function pn(e,t){const{width:n=100/t}=e.attributes;return bn(n)}function gn(e,t,n=e.length){const o=function(e,t=e.length){return Object(Re.sumBy)(e,e=>pn(e,t))}(e,n);return Object(Re.mapValues)(function(e,t=e.length){return e.reduce((e,n)=>{const o=pn(n,t);return Object.assign(e,{[n.clientId]:o})},{})}(e,n),e=>bn(t*e/o))}function hn(e,t){return e.map(e=>Object(Re.merge)({},e,{attributes:{width:t[e.clientId]+"%"}}))}const vn=["core/column"];const On=Object(Ie.withDispatch)((e,t,n)=>({updateAlignment(o){const{clientId:r,setAttributes:a}=t,{updateBlockAttributes:l}=e(Ee.store),{getBlockOrder:c}=n.select(Ee.store);a({verticalAlignment:o});c(r).forEach(e=>{l(e,{verticalAlignment:o})})},updateColumns(o,r){const{clientId:a}=t,{replaceInnerBlocks:l}=e(Ee.store),{getBlocks:c}=n.select(Ee.store);let i=c(a);const s=i.every(e=>{var t;const n=e.attributes.width;return Number.isFinite(null!=n&&null!==(t=n.endsWith)&&void 0!==t&&t.call(n,"%")?parseFloat(n):n)});const u=r>o;if(u&&s){const e=bn(100/r);i=[...hn(i,gn(i,100-e)),...Object(Re.times)(r-o,()=>Object(je.createBlock)("core/column",{width:e+"%"}))]}else if(u)i=[...i,...Object(Re.times)(r-o,()=>Object(je.createBlock)("core/column"))];else if(i=Object(Re.dropRight)(i,o-r),s){i=hn(i,gn(i,100))}l(a,i)}}))((function({attributes:e,setAttributes:t,updateAlignment:n,updateColumns:o,clientId:r}){const{isStackedOnMobile:a,verticalAlignment:l}=e,{count:c}=Object(Ie.useSelect)(e=>({count:e(Ee.store).getBlockCount(r)}),[r]),i=tt()({["are-vertically-aligned-"+l]:l,"is-not-stacked-on-mobile":!a}),s=Object(Ee.useBlockProps)({className:i}),u=Object(Ee.useInnerBlocksProps)(s,{allowedBlocks:vn,orientation:"horizontal",renderAppender:!1});return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,null,Object(ye.createElement)(Ee.BlockVerticalAlignmentToolbar,{onChange:n,value:l})),Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,null,Object(ye.createElement)(ke.RangeControl,{label:Object(we.__)("Columns"),value:c,onChange:e=>o(c,e),min:1,max:Math.max(6,c)}),c>6&&Object(ye.createElement)(ke.Notice,{status:"warning",isDismissible:!1},Object(we.__)("This column count exceeds the recommended amount and may cause visual breakage.")),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Stack on mobile"),checked:a,onChange:()=>t({isStackedOnMobile:!a})}))),Object(ye.createElement)("div",u))}));function jn({clientId:e,name:t,setAttributes:n}){const{blockType:o,defaultVariation:r,variations:a}=Object(Ie.useSelect)(e=>{const{getBlockVariations:n,getBlockType:o,getDefaultBlockVariation:r}=e(je.store);return{blockType:o(t),defaultVariation:r(t,"block"),variations:n(t,"block")}},[t]),{replaceInnerBlocks:l}=Object(Ie.useDispatch)(Ee.store),c=Object(Ee.useBlockProps)();return Object(ye.createElement)("div",c,Object(ye.createElement)(Ee.__experimentalBlockVariationPicker,{icon:Object(Re.get)(o,["icon","src"]),label:Object(Re.get)(o,["title"]),variations:a,onSelect:(t=r)=>{t.attributes&&n(t.attributes),t.innerBlocks&&l(e,Object(je.createBlocksFromInnerBlocksTemplate)(t.innerBlocks),!0)},allowSkip:!0}))}var yn=e=>{const{clientId:t}=e,n=Object(Ie.useSelect)(e=>e(Ee.store).getBlocks(t).length>0,[t])?On:jn;return Object(ye.createElement)(n,e)};var fn=[{name:"one-column-full",title:Object(we.__)("100"),description:Object(we.__)("One column"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"m39.0625 14h-30.0625v20.0938h30.0625zm-30.0625-2c-1.10457 0-2 .8954-2 2v20.0938c0 1.1045.89543 2 2 2h30.0625c1.1046 0 2-.8955 2-2v-20.0938c0-1.1046-.8954-2-2-2z"})),innerBlocks:[["core/column"]],scope:["block"]},{name:"two-columns-equal",title:Object(we.__)("50 / 50"),description:Object(we.__)("Two columns; equal split"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H25V34H39ZM23 34H9V14H23V34Z"})),isDefault:!0,innerBlocks:[["core/column"],["core/column"]],scope:["block"]},{name:"two-columns-one-third-two-thirds",title:Object(we.__)("30 / 70"),description:Object(we.__)("Two columns; one-third, two-thirds split"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H20V34H39ZM18 34H9V14H18V34Z"})),innerBlocks:[["core/column",{width:"33.33%"}],["core/column",{width:"66.66%"}]],scope:["block"]},{name:"two-columns-two-thirds-one-third",title:Object(we.__)("70 / 30"),description:Object(we.__)("Two columns; two-thirds, one-third split"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",clipRule:"evenodd",d:"M39 12C40.1046 12 41 12.8954 41 14V34C41 35.1046 40.1046 36 39 36H9C7.89543 36 7 35.1046 7 34V14C7 12.8954 7.89543 12 9 12H39ZM39 34V14H30V34H39ZM28 34H9V14H28V34Z"})),innerBlocks:[["core/column",{width:"66.66%"}],["core/column",{width:"33.33%"}]],scope:["block"]},{name:"three-columns-equal",title:Object(we.__)("33 / 33 / 33"),description:Object(we.__)("Three columns; equal split"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM28.5 34h-9V14h9v20zm2 0V14H39v20h-8.5zm-13 0H9V14h8.5v20z"})),innerBlocks:[["core/column"],["core/column"],["core/column"]],scope:["block"]},{name:"three-columns-wider-center",title:Object(we.__)("25 / 50 / 25"),description:Object(we.__)("Three columns; wide center column"),icon:Object(ye.createElement)(ke.SVG,{width:"48",height:"48",viewBox:"0 0 48 48",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{fillRule:"evenodd",d:"M41 14a2 2 0 0 0-2-2H9a2 2 0 0 0-2 2v20a2 2 0 0 0 2 2h30a2 2 0 0 0 2-2V14zM31 34H17V14h14v20zm2 0V14h6v20h-6zm-18 0H9V14h6v20z"})),innerBlocks:[["core/column",{width:"25%"}],["core/column",{width:"50%"}],["core/column",{width:"25%"}]],scope:["block"]}];var _n={from:[{type:"block",isMultiBlock:!0,blocks:["*"],__experimentalConvert:e=>{const t=+(100/e.length).toFixed(2),n=e.map(({name:e,attributes:n,innerBlocks:o})=>["core/column",{width:t+"%"},[[e,{...n},o]]]);return Object(je.createBlock)("core/columns",{},Object(je.createBlocksFromInnerBlocksTemplate)(n))},isMatch:({length:e})=>e&&e<=6},{type:"block",blocks:["core/media-text"],priority:1,transform:(e,t)=>{const{align:n,backgroundColor:o,textColor:r,style:a,mediaAlt:l,mediaId:c,mediaPosition:i,mediaSizeSlug:s,mediaType:u,mediaUrl:m,mediaWidth:d,verticalAlignment:b}=e;let p;if("image"!==u&&u)p=["core/video",{id:c,src:m}];else{p=["core/image",{...{id:c,alt:l,url:m,sizeSlug:s},...{href:e.href,linkClass:e.linkClass,linkDestination:e.linkDestination,linkTarget:e.linkTarget,rel:e.rel}}]}const g=[["core/column",{width:d+"%"},[p]],["core/column",{width:100-d+"%"},t]];return"right"===i&&g.reverse(),Object(je.createBlock)("core/columns",{align:n,backgroundColor:o,textColor:r,style:a,verticalAlignment:b},Object(je.createBlocksFromInnerBlocksTemplate)(g))}}]};const kn={apiVersion:2,name:"core/columns",title:"Columns",category:"design",description:"Display content in multiple columns, with blocks added to each column.",textdomain:"default",attributes:{verticalAlignment:{type:"string"},isStackedOnMobile:{type:"boolean",default:!0}},supports:{anchor:!0,align:["wide","full"],html:!1,color:{gradients:!0,link:!0},spacing:{blockGap:!0,margin:["top","bottom"],padding:!0,__experimentalDefaultControls:{blockGap:!0}}},editorStyle:"wp-block-columns-editor",style:"wp-block-columns"},{name:wn}=kn,En={icon:un,variations:fn,example:{viewportWidth:600,innerBlocks:[{name:"core/column",innerBlocks:[{name:"core/paragraph",attributes:{content:Object(we.__)("Lorem ipsum dolor sit amet, consectetur adipiscing elit. Praesent et eros eu felis.")}},{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Windbuchencom.jpg"}},{name:"core/paragraph",attributes:{content:Object(we.__)("Suspendisse commodo neque lacus, a dictum orci interdum et.")}}]},{name:"core/column",innerBlocks:[{name:"core/paragraph",attributes:{content:Object(we.__)("Etiam et egestas lorem. Vivamus sagittis sit amet dolor quis lobortis. Integer sed fermentum arcu, id vulputate lacus. Etiam fermentum sem eu quam hendrerit.")}},{name:"core/paragraph",attributes:{content:Object(we.__)("Nam risus massa, ullamcorper consectetur eros fermentum, porta aliquet ligula. Sed vel mauris nec enim.")}}]}]},deprecated:dn,edit:yn,save:function({attributes:e}){const{isStackedOnMobile:t,verticalAlignment:n}=e,o=tt()({["are-vertically-aligned-"+n]:n,"is-not-stacked-on-mobile":!t}),r=Ee.useBlockProps.save({className:o}),a=Ee.useInnerBlocksProps.save(r);return Object(ye.createElement)("div",a)},transforms:_n};var Cn=Object(ye.createElement)(fe.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(ye.createElement)(fe.Path,{d:"M18.7 3H5.3C4 3 3 4 3 5.3v13.4C3 20 4 21 5.3 21h13.4c1.3 0 2.3-1 2.3-2.3V5.3C21 4 20 3 18.7 3zm.8 15.7c0 .4-.4.8-.8.8H5.3c-.4 0-.8-.4-.8-.8V5.3c0-.4.4-.8.8-.8h6.2v8.9l2.5-3.1 2.5 3.1V4.5h2.2c.4 0 .8.4.8.8v13.4z"}));const xn={"top left":"is-position-top-left","top center":"is-position-top-center","top right":"is-position-top-right","center left":"is-position-center-left","center center":"is-position-center-center",center:"is-position-center-center","center right":"is-position-center-right","bottom left":"is-position-bottom-left","bottom center":"is-position-bottom-center","bottom right":"is-position-bottom-right"};function Sn(e){return e?{backgroundImage:`url(${e})`}:{}}const Bn=["image","video"];function Tn(e){return 50===e||void 0===!e?null:"has-background-dim-"+10*Math.round(e/10)}function Nn(e){return!e||"center center"===e||"center"===e}function Pn(e){return Nn(e)?"":xn[e]}function zn(e){return 0!==e&&50!==e&&e?"has-background-dim-"+10*Math.round(e/10):null}function In(e){return{...e,dimRatio:e.url?e.dimRatio:100}}const Mn={url:{type:"string"},id:{type:"number"},hasParallax:{type:"boolean",default:!1},dimRatio:{type:"number",default:50},overlayColor:{type:"string"},customOverlayColor:{type:"string"},backgroundType:{type:"string",default:"image"},focalPoint:{type:"object"}};var Rn=[{attributes:{...Mn,isRepeated:{type:"boolean",default:!1},minHeight:{type:"number"},minHeightUnit:{type:"string"},gradient:{type:"string"},customGradient:{type:"string"},contentPosition:{type:"string"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""}},supports:{anchor:!0,align:!0,html:!1,spacing:{padding:!0,__experimentalDefaultControls:{padding:!0}},color:{__experimentalDuotone:"> .wp-block-cover__image-background, > .wp-block-cover__video-background",text:!1,background:!1}},save({attributes:e}){const{backgroundType:t,gradient:n,contentPosition:o,customGradient:r,customOverlayColor:a,dimRatio:l,focalPoint:c,hasParallax:i,isRepeated:s,overlayColor:u,url:m,alt:d,id:b,minHeight:p,minHeightUnit:g}=e,h=Object(Ee.getColorClassName)("background-color",u),v=Object(Ee.__experimentalGetGradientClass)(n),O=g?`${p}${g}`:p,j="image"===t,y="video"===t,f=!(i||s),_={...j&&!f?Sn(m):{},backgroundColor:h?void 0:a,background:r&&!m?r:void 0,minHeight:O||void 0},k=c&&f?`${Math.round(100*c.x)}% ${Math.round(100*c.y)}%`:void 0,w=tt()(zn(l),h,{"has-background-dim":0!==l,"has-parallax":i,"is-repeated":s,"has-background-gradient":n||r,[v]:!m&&v,"has-custom-content-position":!Nn(o)},Pn(o));return Object(ye.createElement)("div",Ee.useBlockProps.save({className:w,style:_}),m&&(n||r)&&0!==l&&Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()("wp-block-cover__gradient-background",v),style:r?{background:r}:void 0}),j&&f&&m&&Object(ye.createElement)("img",{className:tt()("wp-block-cover__image-background",b?"wp-image-"+b:null),alt:d,src:m,style:{objectPosition:k},"data-object-fit":"cover","data-object-position":k}),y&&m&&Object(ye.createElement)("video",{className:tt()("wp-block-cover__video-background","intrinsic-ignore"),autoPlay:!0,muted:!0,loop:!0,playsInline:!0,src:m,style:{objectPosition:k},"data-object-fit":"cover","data-object-position":k}),Object(ye.createElement)("div",{className:"wp-block-cover__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))},migrate:In},{attributes:{...Mn,isRepeated:{type:"boolean",default:!1},minHeight:{type:"number"},minHeightUnit:{type:"string"},gradient:{type:"string"},customGradient:{type:"string"},contentPosition:{type:"string"}},supports:{align:!0},save({attributes:e}){const{backgroundType:t,gradient:n,contentPosition:o,customGradient:r,customOverlayColor:a,dimRatio:l,focalPoint:c,hasParallax:i,isRepeated:s,overlayColor:u,url:m,minHeight:d,minHeightUnit:b}=e,p=Object(Ee.getColorClassName)("background-color",u),g=Object(Ee.__experimentalGetGradientClass)(n),h=b?`${d}${b}`:d,v="image"===t,O="video"===t,j=v?Sn(m):{},y={};let f;p||(j.backgroundColor=a),r&&!m&&(j.background=r),j.minHeight=h||void 0,c&&(f=`${Math.round(100*c.x)}% ${Math.round(100*c.y)}%`,v&&!i&&(j.backgroundPosition=f),O&&(y.objectPosition=f));const _=tt()(zn(l),p,{"has-background-dim":0!==l,"has-parallax":i,"is-repeated":s,"has-background-gradient":n||r,[g]:!m&&g,"has-custom-content-position":!Nn(o)},Pn(o));return Object(ye.createElement)("div",Ee.useBlockProps.save({className:_,style:j}),m&&(n||r)&&0!==l&&Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()("wp-block-cover__gradient-background",g),style:r?{background:r}:void 0}),O&&m&&Object(ye.createElement)("video",{className:"wp-block-cover__video-background",autoPlay:!0,muted:!0,loop:!0,playsInline:!0,src:m,style:y}),Object(ye.createElement)("div",{className:"wp-block-cover__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))},migrate:In},{attributes:{...Mn,minHeight:{type:"number"},gradient:{type:"string"},customGradient:{type:"string"}},supports:{align:!0},save({attributes:e}){const{backgroundType:t,gradient:n,customGradient:o,customOverlayColor:r,dimRatio:a,focalPoint:l,hasParallax:c,overlayColor:i,url:s,minHeight:u}=e,m=Object(Ee.getColorClassName)("background-color",i),d=Object(Ee.__experimentalGetGradientClass)(n),b="image"===t?Sn(s):{};m||(b.backgroundColor=r),l&&!c&&(b.backgroundPosition=`${Math.round(100*l.x)}% ${Math.round(100*l.y)}%`),o&&!s&&(b.background=o),b.minHeight=u||void 0;const p=tt()(zn(a),m,{"has-background-dim":0!==a,"has-parallax":c,"has-background-gradient":o,[d]:!s&&d});return Object(ye.createElement)("div",{className:p,style:b},s&&(n||o)&&0!==a&&Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()("wp-block-cover__gradient-background",d),style:o?{background:o}:void 0}),"video"===t&&s&&Object(ye.createElement)("video",{className:"wp-block-cover__video-background",autoPlay:!0,muted:!0,loop:!0,src:s}),Object(ye.createElement)("div",{className:"wp-block-cover__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))},migrate:In},{attributes:{...Mn,minHeight:{type:"number"},gradient:{type:"string"},customGradient:{type:"string"}},supports:{align:!0},save({attributes:e}){const{backgroundType:t,gradient:n,customGradient:o,customOverlayColor:r,dimRatio:a,focalPoint:l,hasParallax:c,overlayColor:i,url:s,minHeight:u}=e,m=Object(Ee.getColorClassName)("background-color",i),d=Object(Ee.__experimentalGetGradientClass)(n),b="image"===t?Sn(s):{};m||(b.backgroundColor=r),l&&!c&&(b.backgroundPosition=`${100*l.x}% ${100*l.y}%`),o&&!s&&(b.background=o),b.minHeight=u||void 0;const p=tt()(zn(a),m,{"has-background-dim":0!==a,"has-parallax":c,"has-background-gradient":o,[d]:!s&&d});return Object(ye.createElement)("div",{className:p,style:b},s&&(n||o)&&0!==a&&Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()("wp-block-cover__gradient-background",d),style:o?{background:o}:void 0}),"video"===t&&s&&Object(ye.createElement)("video",{className:"wp-block-cover__video-background",autoPlay:!0,muted:!0,loop:!0,src:s}),Object(ye.createElement)("div",{className:"wp-block-cover__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))},migrate:In},{attributes:{...Mn,title:{type:"string",source:"html",selector:"p"},contentAlign:{type:"string",default:"center"}},supports:{align:!0},save({attributes:e}){const{backgroundType:t,contentAlign:n,customOverlayColor:o,dimRatio:r,focalPoint:a,hasParallax:l,overlayColor:c,title:i,url:s}=e,u=Object(Ee.getColorClassName)("background-color",c),m="image"===t?Sn(s):{};u||(m.backgroundColor=o),a&&!l&&(m.backgroundPosition=`${100*a.x}% ${100*a.y}%`);const d=tt()(zn(r),u,{"has-background-dim":0!==r,"has-parallax":l,[`has-${n}-content`]:"center"!==n});return Object(ye.createElement)("div",{className:d,style:m},"video"===t&&s&&Object(ye.createElement)("video",{className:"wp-block-cover__video-background",autoPlay:!0,muted:!0,loop:!0,src:s}),!Ee.RichText.isEmpty(i)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"p",className:"wp-block-cover-text",value:i}))},migrate(e){const t={...e,dimRatio:e.url?e.dimRatio:100};return[Object(Re.omit)(t,["title","contentAlign"]),[Object(je.createBlock)("core/paragraph",{content:e.title,align:e.contentAlign,fontSize:"large",placeholder:Object(we.__)("Write title…")})]]}},{attributes:{...Mn,title:{type:"string",source:"html",selector:"p"},contentAlign:{type:"string",default:"center"},align:{type:"string"}},supports:{className:!1},save({attributes:e}){const{url:t,title:n,hasParallax:o,dimRatio:r,align:a,contentAlign:l,overlayColor:c,customOverlayColor:i}=e,s=Object(Ee.getColorClassName)("background-color",c),u=Sn(t);s||(u.backgroundColor=i);const m=tt()("wp-block-cover-image",zn(r),s,{"has-background-dim":0!==r,"has-parallax":o,[`has-${l}-content`]:"center"!==l},a?"align"+a:null);return Object(ye.createElement)("div",{className:m,style:u},!Ee.RichText.isEmpty(n)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"p",className:"wp-block-cover-image-text",value:n}))},migrate(e){const t={...e,dimRatio:e.url?e.dimRatio:100};return[Object(Re.omit)(t,["title","contentAlign","align"]),[Object(je.createBlock)("core/paragraph",{content:e.title,align:e.contentAlign,fontSize:"large",placeholder:Object(we.__)("Write title…")})]]}},{attributes:{...Mn,title:{type:"string",source:"html",selector:"h2"},align:{type:"string"},contentAlign:{type:"string",default:"center"}},supports:{className:!1},save({attributes:e}){const{url:t,title:n,hasParallax:o,dimRatio:r,align:a}=e,l=Sn(t),c=tt()("wp-block-cover-image",zn(r),{"has-background-dim":0!==r,"has-parallax":o},a?"align"+a:null);return Object(ye.createElement)("section",{className:c,style:l},Object(ye.createElement)(Ee.RichText.Content,{tagName:"h2",value:n}))},migrate(e){const t={...e,dimRatio:e.url?e.dimRatio:100};return[Object(Re.omit)(t,["title","contentAlign","align"]),[Object(je.createBlock)("core/paragraph",{content:e.title,align:e.contentAlign,fontSize:"large",placeholder:Object(we.__)("Write title…")})]]}}],Ln=n("FEKF"),Vn=n.n(Ln),An=n("fHnH"),Hn=n("abaT");Object(An.b)([Hn.a]);const{__Visualizer:Fn}=ke.__experimentalBoxControl;function Dn(){return Dn.fastAverageColor||(Dn.fastAverageColor=new Vn.a),Dn.fastAverageColor}function Gn({onChange:e,onUnitChange:t,unit:n="px",value:o=""}){const[r,a]=Object(ye.useState)(null),l="block-cover-height-input-"+Object(nt.useInstanceId)(Ee.__experimentalUnitControl),c="px"===n,i=Object(ke.__experimentalUseCustomUnits)({availableUnits:Object(Ee.useSetting)("spacing.units")||["px","em","rem","vw","vh"],defaultValues:{px:"430",em:"20",rem:"20",vw:"20",vh:"50"}}),s=null!==r?r:o,u=c?50:0;return Object(ye.createElement)(ke.BaseControl,{label:Object(we.__)("Minimum height of cover"),id:l},Object(ye.createElement)(Ee.__experimentalUnitControl,{id:l,isResetValueOnUnitChange:!0,min:u,onBlur:()=>{null!==r&&a(null)},onChange:n=>{const o=""!==n?parseFloat(n):void 0;isNaN(o)&&void 0!==o?a(n):(a(null),e(o),void 0===o&&t())},onUnitChange:t,style:{maxWidth:80},unit:n,units:i,value:s}))}const qn={top:!1,right:!1,bottom:!0,left:!1,topRight:!1,bottomRight:!1,bottomLeft:!1,topLeft:!1};function Un({className:e,onResizeStart:t,onResize:n,onResizeStop:o,...r}){const[a,l]=Object(ye.useState)(!1);return Object(ye.createElement)(ke.ResizableBox,Object(mt.a)({className:tt()(e,{"is-resizing":a}),enable:qn,onResizeStart:(e,o,r)=>{t(r.clientHeight),n(r.clientHeight)},onResize:(e,t,o)=>{n(o.clientHeight),a||l(!0)},onResizeStop:(e,t,n)=>{o(n.clientHeight),l(!1)}},r))}function Wn({x:e,y:t}){return`${Math.round(100*e)}% ${Math.round(100*t)}%`}function $n({disableMediaButtons:e=!1,children:t,noticeUI:n,noticeOperations:o,onSelectMedia:r,style:a}){const{removeAllNotices:l,createErrorNotice:c}=o;return Object(ye.createElement)(Ee.MediaPlaceholder,{icon:Object(ye.createElement)(Ee.BlockIcon,{icon:Cn}),labels:{title:Object(we.__)("Cover"),instructions:Object(we.__)("Drag and drop onto this block, upload, or select existing media from your library.")},onSelect:r,accept:"image/*,video/*",allowedTypes:Bn,notices:n,disableMediaButtons:e,onError:e=>{l(),c(e)},style:a},t)}var Zn=Object(nt.compose)([Object(Ie.withDispatch)(e=>{const{toggleSelection:t}=e(Ee.store);return{toggleSelection:t}}),Object(Ee.withColors)({overlayColor:"background-color"}),ke.withNotices,nt.withInstanceId])((function({attributes:e,clientId:t,isSelected:n,noticeUI:o,noticeOperations:r,overlayColor:a,setAttributes:l,setOverlayColor:c,toggleSelection:i}){var s,u,m;const{contentPosition:d,id:b,backgroundType:p,dimRatio:g,focalPoint:h,hasParallax:v,isDark:O,isRepeated:j,minHeight:y,minHeightUnit:f,style:_,url:k,alt:w,allowedBlocks:E,templateLock:C}=e,{gradientClass:x,gradientValue:S,setGradient:B}=Object(Ee.__experimentalUseGradient)(),T=function(e,t){return n=>{if(!n||!n.url)return void e({url:void 0,id:void 0});let o;if(Object(ze.isBlobURL)(n.url)&&(n.type=Object(ze.getBlobTypeByURL)(n.url)),n.media_type)o="image"===n.media_type?"image":"video";else{if("image"!==n.type&&"video"!==n.type)return;o=n.type}e({dimRatio:100===t?50:t,url:n.url,id:n.id,alt:null==n?void 0:n.alt,backgroundType:o,..."video"===o?{focalPoint:void 0,hasParallax:void 0}:{}})}}(l,g),N=((e,t)=>!e&&Object(ze.isBlobURL)(t))(b,k),[P,z]=Object(ye.useState)(y),[I,M]=Object(ye.useState)(f),R="vh"===f&&100===y,L=Object(ye.useRef)(),V=function(e,t=50,n,o){const[r,a]=Object(ye.useState)(!1);return Object(ye.useEffect)(()=>{e&&t<=50&&o.current&&Dn().getColorAsync(o.current,e=>{a(e.isDark)})},[e,e&&t<=50&&o.current,a]),Object(ye.useEffect)(()=>{if(t>50||!e){if(!n)return void a(!0);a(Object(An.a)(n).isDark())}},[n,t>50||!e,a]),Object(ye.useEffect)(()=>{e||n||a(!1)},[!e&&!n,a]),r}(k,g,a.color,L);Object(ye.useEffect)(()=>{l({isDark:V})},[V]);const A="image"===p,H="video"===p,[F,D]=Object(ye.useState)(null),G=f?`${y}${f}`:y,q=!(v||j),U={...A&&!q?Sn(k):void 0,minHeight:F||G||void 0},W={backgroundColor:a.color},$={objectPosition:h&&q?Wn(h):void 0},Z=!!(k||a.color||S),K=H||A&&(!v||j),J=e=>{const[t,n]=L.current?[L.current.style,"objectPosition"]:[X.current.style,"backgroundPosition"];t[n]=Wn(e)},Q=Object(Ie.useSelect)(e=>e(Ee.store).getBlock(t).innerBlocks.length>0,[t]),Y=Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,{group:"block"},Object(ye.createElement)(Ee.__experimentalBlockAlignmentMatrixControl,{label:Object(we.__)("Change content position"),value:d,onChange:e=>l({contentPosition:e}),isDisabled:!Q}),Object(ye.createElement)(Ee.__experimentalBlockFullHeightAligmentControl,{isActive:R,onToggle:()=>R?l("vh"===I&&100===P?{minHeight:void 0,minHeightUnit:void 0}:{minHeight:P,minHeightUnit:I}):(z(y),M(f),l({minHeight:100,minHeightUnit:"vh"})),isDisabled:!Q})),Object(ye.createElement)(Ee.BlockControls,{group:"other"},Object(ye.createElement)(Ee.MediaReplaceFlow,{mediaId:b,mediaURL:k,allowedTypes:Bn,accept:"image/*,video/*",onSelect:T,name:k?Object(we.__)("Replace"):Object(we.__)("Add Media")})),Object(ye.createElement)(Ee.InspectorControls,null,!!k&&Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Media settings")},A&&Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Fixed background"),checked:v,onChange:()=>{l({hasParallax:!v,...v?{}:{focalPoint:void 0}})}}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Repeated background"),checked:j,onChange:()=>{l({isRepeated:!j})}})),K&&Object(ye.createElement)(ke.FocalPointPicker,{label:Object(we.__)("Focal point picker"),url:k,value:h,onDragStart:J,onDrag:J,onChange:e=>l({focalPoint:e})}),k&&A&&q&&Object(ye.createElement)(ke.TextareaControl,{label:Object(we.__)("Alt text (alternative text)"),value:w,onChange:e=>l({alt:e}),help:Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(ke.ExternalLink,{href:"https://www.w3.org/WAI/tutorials/images/decision-tree"},Object(we.__)("Describe the purpose of the image")),Object(we.__)("Leave empty if the image is purely decorative."))}),Object(ye.createElement)(ke.PanelRow,null,Object(ye.createElement)(ke.Button,{variant:"secondary",isSmall:!0,className:"block-library-cover__reset-button",onClick:()=>l({url:void 0,id:void 0,backgroundType:void 0,focalPoint:void 0,hasParallax:void 0,isRepeated:void 0})},Object(we.__)("Clear Media")))),Object(ye.createElement)(Ee.__experimentalPanelColorGradientSettings,{__experimentalHasMultipleOrigins:!0,title:Object(we.__)("Overlay"),initialOpen:!0,settings:[{colorValue:a.color,gradientValue:S,onColorChange:c,onGradientChange:B,label:Object(we.__)("Color")}]},Object(ye.createElement)(ke.RangeControl,{label:Object(we.__)("Opacity"),value:g,onChange:e=>l({dimRatio:e}),min:0,max:100,step:10,required:!0}))),Object(ye.createElement)(Ee.InspectorControls,{__experimentalGroup:"dimensions"},Object(ye.createElement)(ke.__experimentalToolsPanelItem,{hasValue:()=>!!y,label:Object(we.__)("Minimum height"),onDeselect:()=>l({minHeight:void 0,minHeightUnit:void 0}),resetAllFilter:()=>({minHeight:void 0,minHeightUnit:void 0}),isShownByDefault:!0,panelId:t},Object(ye.createElement)(Gn,{value:F||y,unit:f,onChange:e=>l({minHeight:e}),onUnitChange:e=>l({minHeightUnit:e})})))),X=Object(ye.useRef)(),ee=Object(Ee.useBlockProps)({ref:X}),te=function(e){return[["core/paragraph",{align:"center",placeholder:Object(we.__)("Write title…"),...e}]]}({fontSize:!(null===(s=Object(Ee.useSetting)("typography.fontSizes"))||void 0===s||!s.length)?"large":void 0}),ne=Object(Ee.useInnerBlocksProps)({className:"wp-block-cover__inner-container"},{template:te,templateInsertUpdatesSelection:!0,allowedBlocks:E,templateLock:C});if(!Q&&!Z)return Object(ye.createElement)(ye.Fragment,null,Y,Object(ye.createElement)("div",Object(mt.a)({},ee,{className:tt()("is-placeholder",ee.className)}),Object(ye.createElement)($n,{noticeUI:o,onSelectMedia:T,noticeOperations:r,style:{minHeight:F||G||void 0}},Object(ye.createElement)("div",{className:"wp-block-cover__placeholder-background-options"},Object(ye.createElement)(Ee.ColorPalette,{disableCustomColors:!0,value:a.color,onChange:c,clearable:!1}))),Object(ye.createElement)(Un,{className:"block-library-cover__resize-container",onResizeStart:()=>{l({minHeightUnit:"px"}),i(!1)},onResize:D,onResizeStop:e=>{i(!0),l({minHeight:e}),D(null)},showHandle:n})));const oe=tt()({"is-dark-theme":O,"is-light":!O,"is-transient":N,"has-parallax":v,"is-repeated":j,"has-custom-content-position":!Nn(d)},Pn(d));return Object(ye.createElement)(ye.Fragment,null,Y,Object(ye.createElement)("div",Object(mt.a)({},ee,{className:tt()(oe,ee.className),style:{...U,...ee.style},"data-url":k}),Object(ye.createElement)(Fn,{values:null==_||null===(u=_.spacing)||void 0===u?void 0:u.padding,showValues:null==_||null===(m=_.visualizers)||void 0===m?void 0:m.padding}),Object(ye.createElement)(Un,{className:"block-library-cover__resize-container",onResizeStart:()=>{l({minHeightUnit:"px"}),i(!1)},onResize:D,onResizeStop:e=>{i(!0),l({minHeight:e}),D(null)},showHandle:n}),Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()(Tn(g),{[a.class]:a.class},"wp-block-cover__gradient-background",x,{"has-background-dim":void 0!==g,"has-background-gradient":S,[x]:!k&&x}),style:{backgroundImage:S,...W}}),k&&A&&q&&Object(ye.createElement)("img",{ref:L,className:"wp-block-cover__image-background",alt:w,src:k,style:$}),k&&H&&Object(ye.createElement)("video",{ref:L,className:"wp-block-cover__video-background",autoPlay:!0,muted:!0,loop:!0,src:k,style:$}),N&&Object(ye.createElement)(ke.Spinner,null),Object(ye.createElement)($n,{disableMediaButtons:!0,noticeUI:o,onSelectMedia:T,noticeOperations:r}),Object(ye.createElement)("div",ne)))}));var Kn={from:[{type:"block",blocks:["core/image"],transform:({caption:e,url:t,alt:n,align:o,id:r,anchor:a,style:l})=>{var c;return Object(je.createBlock)("core/cover",{url:t,alt:n,align:o,id:r,anchor:a,style:{color:{duotone:null==l||null===(c=l.color)||void 0===c?void 0:c.duotone}}},[Object(je.createBlock)("core/paragraph",{content:e,fontSize:"large"})])}},{type:"block",blocks:["core/video"],transform:({caption:e,src:t,align:n,id:o,anchor:r})=>Object(je.createBlock)("core/cover",{url:t,align:n,id:o,backgroundType:"video",anchor:r},[Object(je.createBlock)("core/paragraph",{content:e,fontSize:"large"})])},{type:"block",blocks:["core/group"],isMatch:({backgroundColor:e,gradient:t,style:n})=>{var o,r;return e||(null==n||null===(o=n.color)||void 0===o?void 0:o.background)||(null==n||null===(r=n.color)||void 0===r?void 0:r.gradient)||t},transform:({align:e,anchor:t,backgroundColor:n,gradient:o,style:r},a)=>{var l,c;return Object(je.createBlock)("core/cover",{align:e,anchor:t,overlayColor:n,customOverlayColor:null==r||null===(l=r.color)||void 0===l?void 0:l.background,gradient:o,customGradient:null==r||null===(c=r.color)||void 0===c?void 0:c.gradient},a)}}],to:[{type:"block",blocks:["core/image"],isMatch:({backgroundType:e,url:t,overlayColor:n,customOverlayColor:o,gradient:r,customGradient:a})=>t?"image"===e:!(n||o||r||a),transform:({title:e,url:t,alt:n,align:o,id:r,anchor:a,style:l})=>{var c;return Object(je.createBlock)("core/image",{caption:e,url:t,alt:n,align:o,id:r,anchor:a,style:{color:{duotone:null==l||null===(c=l.color)||void 0===c?void 0:c.duotone}}})}},{type:"block",blocks:["core/video"],isMatch:({backgroundType:e,url:t,overlayColor:n,customOverlayColor:o,gradient:r,customGradient:a})=>t?"video"===e:!(n||o||r||a),transform:({title:e,url:t,align:n,id:o,anchor:r})=>Object(je.createBlock)("core/video",{caption:e,src:t,id:o,align:n,anchor:r})}]};const Jn={apiVersion:2,name:"core/cover",title:"Cover",category:"media",description:"Add an image or video with a text overlay — great for headers.",textdomain:"default",attributes:{url:{type:"string"},id:{type:"number"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""},hasParallax:{type:"boolean",default:!1},isRepeated:{type:"boolean",default:!1},dimRatio:{type:"number",default:100},overlayColor:{type:"string"},customOverlayColor:{type:"string"},backgroundType:{type:"string",default:"image"},focalPoint:{type:"object"},minHeight:{type:"number"},minHeightUnit:{type:"string"},gradient:{type:"string"},customGradient:{type:"string"},contentPosition:{type:"string"},isDark:{type:"boolean",default:!0},allowedBlocks:{type:"array"},templateLock:{type:"string",enum:["all","insert",!1]}},supports:{anchor:!0,align:!0,html:!1,spacing:{padding:!0,__experimentalDefaultControls:{padding:!0}},color:{__experimentalDuotone:"> .wp-block-cover__image-background, > .wp-block-cover__video-background",text:!1,background:!1}},editorStyle:"wp-block-cover-editor",style:"wp-block-cover"},{name:Qn}=Jn,Yn={icon:Cn,example:{attributes:{customOverlayColor:"#065174",dimRatio:40,url:"https://s.w.org/images/core/5.3/Windbuchencom.jpg"},innerBlocks:[{name:"core/paragraph",attributes:{customFontSize:48,content:Object(we.__)("Snow Patrol"),align:"center"}}]},transforms:Kn,save:function({attributes:e}){const{backgroundType:t,gradient:n,contentPosition:o,customGradient:r,customOverlayColor:a,dimRatio:l,focalPoint:c,hasParallax:i,isDark:s,isRepeated:u,overlayColor:m,url:d,alt:b,id:p,minHeight:g,minHeightUnit:h}=e,v=Object(Ee.getColorClassName)("background-color",m),O=Object(Ee.__experimentalGetGradientClass)(n),j=h?`${g}${h}`:g,y="image"===t,f="video"===t,_=!(i||u),k={...y&&!_?Sn(d):{},minHeight:j||void 0},w={backgroundColor:v?void 0:a,background:r||void 0},E=c&&_?`${Math.round(100*c.x)}% ${Math.round(100*c.y)}%`:void 0,C=tt()({"is-light":!s,"has-parallax":i,"is-repeated":u,"has-custom-content-position":!Nn(o)},Pn(o));return Object(ye.createElement)("div",Ee.useBlockProps.save({className:C,style:k}),Object(ye.createElement)("span",{"aria-hidden":"true",className:tt()(v,Tn(l),"wp-block-cover__gradient-background",O,{"has-background-dim":void 0!==l,"has-background-gradient":n||r,[O]:!d&&O}),style:w}),y&&_&&d&&Object(ye.createElement)("img",{className:tt()("wp-block-cover__image-background",p?"wp-image-"+p:null),alt:b,src:d,style:{objectPosition:E},"data-object-fit":"cover","data-object-position":E}),f&&d&&Object(ye.createElement)("video",{className:tt()("wp-block-cover__video-background","intrinsic-ignore"),autoPlay:!0,muted:!0,loop:!0,playsInline:!0,src:d,style:{objectPosition:E},"data-object-fit":"cover","data-object-position":E}),Object(ye.createElement)("div",Ee.useInnerBlocksProps.save({className:"wp-block-cover__inner-container"})))},edit:Zn,deprecated:Rn};var Xn=n("B9Az");function eo(e){return e?Object(we.__)("This embed will preserve its aspect ratio when the browser is resized."):Object(we.__)("This embed may not preserve its aspect ratio when the browser is resized.")}var to=({blockSupportsResponsive:e,showEditButton:t,themeSupportsResponsive:n,allowResponsive:o,toggleResponsive:r,switchBackToURLInput:a})=>Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.BlockControls,null,Object(ye.createElement)(ke.ToolbarGroup,null,t&&Object(ye.createElement)(ke.ToolbarButton,{className:"components-toolbar__control",label:Object(we.__)("Edit URL"),icon:Xn.a,onClick:a}))),n&&e&&Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Media settings"),className:"blocks-responsive"},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Resize for smaller devices"),checked:o,help:eo,onChange:r}))));const no=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V9.8l4.7-5.3H19c.3 0 .5.2.5.5v14zm-6-9.5L16 12l-2.5 2.8 1.1 1L18 12l-3.5-3.5-1 1zm-3 0l-1-1L6 12l3.5 3.8 1.1-1L8 12l2.5-2.5z"})),oo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V9.8l4.7-5.3H19c.3 0 .5.2.5.5v14zM13.2 7.7c-.4.4-.7 1.1-.7 1.9v3.7c-.4-.3-.8-.4-1.3-.4-1.2 0-2.2 1-2.2 2.2 0 1.2 1 2.2 2.2 2.2.5 0 1-.2 1.4-.5.9-.6 1.4-1.6 1.4-2.6V9.6c0-.4.1-.6.2-.8.3-.3 1-.3 1.6-.3h.2V7h-.2c-.7 0-1.8 0-2.6.7z"})),ro=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM9.2 4.5H19c.3 0 .5.2.5.5v8.4l-3-2.9c-.3-.3-.8-.3-1 0L11.9 14 9 12c-.3-.2-.6-.2-.8 0l-3.6 2.6V9.8l4.6-5.3zm9.8 15H5c-.3 0-.5-.2-.5-.5v-2.4l4.1-3 3 1.9c.3.2.7.2.9-.1L16 12l3.5 3.4V19c0 .3-.2.5-.5.5z"})),ao=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(ke.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zm.5 16c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V9.8l4.7-5.3H19c.3 0 .5.2.5.5v14zM10 15l5-3-5-3v6z"})),lo={foreground:"#1da1f2",src:Object(ye.createElement)(ke.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(ye.createElement)(ke.G,null,Object(ye.createElement)(ke.Path,{d:"M22.23 5.924c-.736.326-1.527.547-2.357.646.847-.508 1.498-1.312 1.804-2.27-.793.47-1.67.812-2.606.996C18.325 4.498 17.258 4 16.078 4c-2.266 0-4.103 1.837-4.103 4.103 0 .322.036.635.106.935-3.41-.17-6.433-1.804-8.457-4.287-.353.607-.556 1.312-.556 2.064 0 1.424.724 2.68 1.825 3.415-.673-.022-1.305-.207-1.86-.514v.052c0 1.988 1.415 3.647 3.293 4.023-.344.095-.707.145-1.08.145-.265 0-.522-.026-.773-.074.522 1.63 2.038 2.817 3.833 2.85-1.404 1.1-3.174 1.757-5.096 1.757-.332 0-.66-.02-.98-.057 1.816 1.164 3.973 1.843 6.29 1.843 7.547 0 11.675-6.252 11.675-11.675 0-.178-.004-.355-.012-.53.802-.578 1.497-1.3 2.047-2.124z"})))},co={foreground:"#ff0000",src:Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M21.8 8s-.195-1.377-.795-1.984c-.76-.797-1.613-.8-2.004-.847-2.798-.203-6.996-.203-6.996-.203h-.01s-4.197 0-6.996.202c-.39.046-1.242.05-2.003.846C2.395 6.623 2.2 8 2.2 8S2 9.62 2 11.24v1.517c0 1.618.2 3.237.2 3.237s.195 1.378.795 1.985c.76.797 1.76.77 2.205.855 1.6.153 6.8.2 6.8.2s4.203-.005 7-.208c.392-.047 1.244-.05 2.005-.847.6-.607.795-1.985.795-1.985s.2-1.618.2-3.237v-1.517C22 9.62 21.8 8 21.8 8zM9.935 14.595v-5.62l5.403 2.82-5.403 2.8z"}))},io={foreground:"#3b5998",src:Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M20 3H4c-.6 0-1 .4-1 1v16c0 .5.4 1 1 1h8.6v-7h-2.3v-2.7h2.3v-2c0-2.3 1.4-3.6 3.5-3.6 1 0 1.8.1 2.1.1v2.4h-1.4c-1.1 0-1.3.5-1.3 1.3v1.7h2.7l-.4 2.8h-2.3v7H20c.5 0 1-.4 1-1V4c0-.6-.4-1-1-1z"}))},so=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.G,null,Object(ye.createElement)(ke.Path,{d:"M12 4.622c2.403 0 2.688.01 3.637.052.877.04 1.354.187 1.67.31.42.163.72.358 1.036.673.315.315.51.615.673 1.035.123.317.27.794.31 1.67.043.95.052 1.235.052 3.638s-.01 2.688-.052 3.637c-.04.877-.187 1.354-.31 1.67-.163.42-.358.72-.673 1.036-.315.315-.615.51-1.035.673-.317.123-.794.27-1.67.31-.95.043-1.234.052-3.638.052s-2.688-.01-3.637-.052c-.877-.04-1.354-.187-1.67-.31-.42-.163-.72-.358-1.036-.673-.315-.315-.51-.615-.673-1.035-.123-.317-.27-.794-.31-1.67-.043-.95-.052-1.235-.052-3.638s.01-2.688.052-3.637c.04-.877.187-1.354.31-1.67.163-.42.358-.72.673-1.036.315-.315.615-.51 1.035-.673.317-.123.794-.27 1.67-.31.95-.043 1.235-.052 3.638-.052M12 3c-2.444 0-2.75.01-3.71.054s-1.613.196-2.185.418c-.592.23-1.094.538-1.594 1.04-.5.5-.807 1-1.037 1.593-.223.572-.375 1.226-.42 2.184C3.01 9.25 3 9.555 3 12s.01 2.75.054 3.71.196 1.613.418 2.186c.23.592.538 1.094 1.038 1.594s1.002.808 1.594 1.038c.572.222 1.227.375 2.185.418.96.044 1.266.054 3.71.054s2.75-.01 3.71-.054 1.613-.196 2.186-.418c.592-.23 1.094-.538 1.594-1.038s.808-1.002 1.038-1.594c.222-.572.375-1.227.418-2.185.044-.96.054-1.266.054-3.71s-.01-2.75-.054-3.71-.196-1.613-.418-2.186c-.23-.592-.538-1.094-1.038-1.594s-1.002-.808-1.594-1.038c-.572-.222-1.227-.375-2.185-.418C14.75 3.01 14.445 3 12 3zm0 4.378c-2.552 0-4.622 2.07-4.622 4.622s2.07 4.622 4.622 4.622 4.622-2.07 4.622-4.622S14.552 7.378 12 7.378zM12 15c-1.657 0-3-1.343-3-3s1.343-3 3-3 3 1.343 3 3-1.343 3-3 3zm4.804-8.884c-.596 0-1.08.484-1.08 1.08s.484 1.08 1.08 1.08c.596 0 1.08-.484 1.08-1.08s-.483-1.08-1.08-1.08z"}))),uo={foreground:"#0073AA",src:Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.G,null,Object(ye.createElement)(ke.Path,{d:"M12.158 12.786l-2.698 7.84c.806.236 1.657.365 2.54.365 1.047 0 2.05-.18 2.986-.51-.024-.037-.046-.078-.065-.123l-2.762-7.57zM3.008 12c0 3.56 2.07 6.634 5.068 8.092L3.788 8.342c-.5 1.117-.78 2.354-.78 3.658zm15.06-.454c0-1.112-.398-1.88-.74-2.48-.456-.74-.883-1.368-.883-2.11 0-.825.627-1.595 1.51-1.595.04 0 .078.006.116.008-1.598-1.464-3.73-2.36-6.07-2.36-3.14 0-5.904 1.613-7.512 4.053.21.008.41.012.58.012.94 0 2.395-.114 2.395-.114.484-.028.54.684.057.74 0 0-.487.058-1.03.086l3.275 9.74 1.968-5.902-1.4-3.838c-.485-.028-.944-.085-.944-.085-.486-.03-.43-.77.056-.742 0 0 1.484.114 2.368.114.94 0 2.397-.114 2.397-.114.486-.028.543.684.058.74 0 0-.488.058-1.03.086l3.25 9.665.897-2.997c.456-1.17.684-2.137.684-2.907zm1.82-3.86c.04.286.06.593.06.924 0 .912-.17 1.938-.683 3.22l-2.746 7.94c2.672-1.558 4.47-4.454 4.47-7.77 0-1.564-.4-3.033-1.1-4.314zM12 22C6.486 22 2 17.514 2 12S6.486 2 12 2s10 4.486 10 10-4.486 10-10 10z"})))},mo={foreground:"#1db954",src:Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M12 2C6.477 2 2 6.477 2 12s4.477 10 10 10 10-4.477 10-10S17.523 2 12 2m4.586 14.424c-.18.295-.563.387-.857.207-2.35-1.434-5.305-1.76-8.786-.963-.335.077-.67-.133-.746-.47-.077-.334.132-.67.47-.745 3.808-.87 7.076-.496 9.712 1.115.293.18.386.563.206.857M17.81 13.7c-.226.367-.706.482-1.072.257-2.687-1.652-6.785-2.13-9.965-1.166-.413.127-.848-.106-.973-.517-.125-.413.108-.848.52-.973 3.632-1.102 8.147-.568 11.234 1.328.366.226.48.707.256 1.072m.105-2.835C14.692 8.95 9.375 8.775 6.297 9.71c-.493.15-1.016-.13-1.166-.624-.148-.495.13-1.017.625-1.167 3.532-1.073 9.404-.866 13.115 1.337.445.264.59.838.327 1.282-.264.443-.838.59-1.282.325"}))},bo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"m6.5 7c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5zm11 0c-2.75 0-5 2.25-5 5s2.25 5 5 5 5-2.25 5-5-2.25-5-5-5z"})),po={foreground:"#1ab7ea",src:Object(ye.createElement)(ke.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},Object(ye.createElement)(ke.G,null,Object(ye.createElement)(ke.Path,{d:"M22.396 7.164c-.093 2.026-1.507 4.8-4.245 8.32C15.323 19.16 12.93 21 10.97 21c-1.214 0-2.24-1.12-3.08-3.36-.56-2.052-1.118-4.105-1.68-6.158-.622-2.24-1.29-3.36-2.004-3.36-.156 0-.7.328-1.634.98l-.978-1.26c1.027-.903 2.04-1.806 3.037-2.71C6 3.95 7.03 3.328 7.716 3.265c1.62-.156 2.616.95 2.99 3.32.404 2.558.685 4.148.84 4.77.468 2.12.982 3.18 1.543 3.18.435 0 1.09-.687 1.963-2.064.872-1.376 1.34-2.422 1.402-3.142.125-1.187-.343-1.782-1.4-1.782-.5 0-1.013.115-1.542.34 1.023-3.35 2.977-4.976 5.862-4.883 2.14.063 3.148 1.45 3.024 4.16z"})))},go=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M22 11.816c0-1.256-1.02-2.277-2.277-2.277-.593 0-1.122.24-1.526.613-1.48-.965-3.455-1.594-5.647-1.69l1.17-3.702 3.18.75c.01 1.027.847 1.86 1.877 1.86 1.035 0 1.877-.84 1.877-1.877 0-1.035-.842-1.877-1.877-1.877-.77 0-1.43.466-1.72 1.13L13.55 3.92c-.204-.047-.4.067-.46.26l-1.35 4.27c-2.317.037-4.412.67-5.97 1.67-.402-.355-.917-.58-1.493-.58C3.02 9.54 2 10.56 2 11.815c0 .814.433 1.523 1.078 1.925-.037.222-.06.445-.06.673 0 3.292 4.01 5.97 8.94 5.97s8.94-2.678 8.94-5.97c0-.214-.02-.424-.052-.632.687-.39 1.154-1.12 1.154-1.964zm-3.224-7.422c.606 0 1.1.493 1.1 1.1s-.493 1.1-1.1 1.1-1.1-.494-1.1-1.1.493-1.1 1.1-1.1zm-16 7.422c0-.827.673-1.5 1.5-1.5.313 0 .598.103.838.27-.85.675-1.477 1.478-1.812 2.36-.32-.274-.525-.676-.525-1.13zm9.183 7.79c-4.502 0-8.165-2.33-8.165-5.193S7.457 9.22 11.96 9.22s8.163 2.33 8.163 5.193-3.663 5.193-8.164 5.193zM20.635 13c-.326-.89-.948-1.7-1.797-2.383.247-.186.55-.3.882-.3.827 0 1.5.672 1.5 1.5 0 .482-.23.91-.586 1.184zm-11.64 1.704c-.76 0-1.397-.616-1.397-1.376 0-.76.636-1.397 1.396-1.397.76 0 1.376.638 1.376 1.398 0 .76-.616 1.376-1.376 1.376zm7.405-1.376c0 .76-.615 1.376-1.375 1.376s-1.4-.616-1.4-1.376c0-.76.64-1.397 1.4-1.397.76 0 1.376.638 1.376 1.398zm-1.17 3.38c.15.152.15.398 0 .55-.675.674-1.728 1.002-3.22 1.002l-.01-.002-.012.002c-1.492 0-2.544-.328-3.218-1.002-.152-.152-.152-.398 0-.55.152-.152.4-.15.55 0 .52.52 1.394.775 2.67.775l.01.002.01-.002c1.276 0 2.15-.253 2.67-.775.15-.152.398-.152.55 0z"})),ho={foreground:"#35465c",src:Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M19 3H5a2 2 0 00-2 2v14c0 1.1.9 2 2 2h14a2 2 0 002-2V5a2 2 0 00-2-2zm-5.69 14.66c-2.72 0-3.1-1.9-3.1-3.16v-3.56H8.49V8.99c1.7-.62 2.54-1.99 2.64-2.87 0-.06.06-.41.06-.58h1.9v3.1h2.17v2.3h-2.18v3.1c0 .47.13 1.3 1.2 1.26h1.1v2.36c-1.01.02-2.07 0-2.07 0z"}))},vo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"M18.42 14.58c-.51-.66-1.05-1.23-1.05-2.5V7.87c0-1.8.15-3.45-1.2-4.68-1.05-1.02-2.79-1.35-4.14-1.35-2.6 0-5.52.96-6.12 4.14-.06.36.18.54.4.57l2.66.3c.24-.03.42-.27.48-.5.24-1.12 1.17-1.63 2.2-1.63.56 0 1.22.21 1.55.7.4.56.33 1.31.33 1.97v.36c-1.59.18-3.66.27-5.16.93a4.63 4.63 0 0 0-2.93 4.44c0 2.82 1.8 4.23 4.1 4.23 1.95 0 3.03-.45 4.53-1.98.51.72.66 1.08 1.59 1.83.18.09.45.09.63-.1v.04l2.1-1.8c.24-.21.2-.48.03-.75zm-5.4-1.2c-.45.75-1.14 1.23-1.92 1.23-1.05 0-1.65-.81-1.65-1.98 0-2.31 2.1-2.73 4.08-2.73v.6c0 1.05.03 1.92-.5 2.88z"}),Object(ye.createElement)(ke.Path,{d:"M21.69 19.2a17.62 17.62 0 0 1-21.6-1.57c-.23-.2 0-.5.28-.33a23.88 23.88 0 0 0 20.93 1.3c.45-.19.84.3.39.6z"}),Object(ye.createElement)(ke.Path,{d:"M22.8 17.96c-.36-.45-2.22-.2-3.1-.12-.23.03-.3-.18-.05-.36 1.5-1.05 3.96-.75 4.26-.39.3.36-.1 2.82-1.5 4.02-.21.18-.42.1-.3-.15.3-.8 1.02-2.58.69-3z"})),Oo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"m.0206909 21 19.8160091-13.07806 3.5831 6.20826z",fill:"#4bc7ee"}),Object(ye.createElement)(ke.Path,{d:"m23.7254 19.0205-10.1074-17.18468c-.6421-1.114428-1.7087-1.114428-2.3249 0l-11.2931 19.16418h22.5655c1.279 0 1.8019-.8905 1.1599-1.9795z",fill:"#d4cdcb"}),Object(ye.createElement)(ke.Path,{d:"m.0206909 21 15.2439091-16.38571 4.3029 7.32271z",fill:"#c3d82e"}),Object(ye.createElement)(ke.Path,{d:"m13.618 1.83582c-.6421-1.114428-1.7087-1.114428-2.3249 0l-11.2931 19.16418 15.2646-16.38573z",fill:"#e4ecb0"}),Object(ye.createElement)(ke.Path,{d:"m.0206909 21 19.5468091-9.063 1.6621 2.8344z",fill:"#209dbd"}),Object(ye.createElement)(ke.Path,{d:"m.0206909 21 17.9209091-11.82623 1.6259 2.76323z",fill:"#7cb3c9"})),jo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 24 24"},Object(ye.createElement)(ke.Path,{d:"m12.1479 18.5957c-2.4949 0-4.28131-1.7558-4.28131-4.0658 0-2.2176 1.78641-4.0965 4.09651-4.0965 2.2793 0 4.0349 1.7864 4.0349 4.1581 0 2.2794-1.7556 4.0042-3.8501 4.0042zm8.3521-18.5957-4.5329 1v7c-1.1088-1.41691-2.8028-1.8787-4.8049-1.8787-2.09443 0-3.97329.76993-5.5133 2.27917-1.72483 1.66323-2.6489 3.78863-2.6489 6.16033 0 2.5873.98562 4.8049 2.89526 6.499 1.44763 1.2936 3.17251 1.9402 5.17454 1.9402 1.9713 0 3.4498-.5236 4.8973-1.9402v1.9402h4.5329c0-7.6359 0-15.3641 0-23z",fill:"#333436"})),yo=Object(ye.createElement)(ke.SVG,{width:"24",height:"24",viewBox:"0 0 24 24",version:"1.1"},Object(ye.createElement)(ke.Path,{d:"M12.289,2C6.617,2,3.606,5.648,3.606,9.622c0,1.846,1.025,4.146,2.666,4.878c0.25,0.111,0.381,0.063,0.439-0.169 c0.044-0.175,0.267-1.029,0.365-1.428c0.032-0.128,0.017-0.237-0.091-0.362C6.445,11.911,6.01,10.75,6.01,9.668 c0-2.777,2.194-5.464,5.933-5.464c3.23,0,5.49,2.108,5.49,5.122c0,3.407-1.794,5.768-4.13,5.768c-1.291,0-2.257-1.021-1.948-2.277 c0.372-1.495,1.089-3.112,1.089-4.191c0-0.967-0.542-1.775-1.663-1.775c-1.319,0-2.379,1.309-2.379,3.059 c0,1.115,0.394,1.869,0.394,1.869s-1.302,5.279-1.54,6.261c-0.405,1.666,0.053,4.368,0.094,4.604 c0.021,0.126,0.167,0.169,0.25,0.063c0.129-0.165,1.699-2.419,2.142-4.051c0.158-0.59,0.817-2.995,0.817-2.995 c0.43,0.784,1.681,1.446,3.013,1.446c3.963,0,6.822-3.494,6.822-7.833C20.394,5.112,16.849,2,12.289,2"})),fo=Object(ye.createElement)(ke.SVG,{viewBox:"0 0 44 44"},Object(ye.createElement)(ke.Path,{d:"M32.59521,22.001l4.31885-4.84473-6.34131-1.38379.646-6.459-5.94336,2.61035L22,6.31934l-3.27344,5.60351L12.78418,9.3125l.645,6.458L7.08643,17.15234,11.40479,21.999,7.08594,26.84375l6.34131,1.38379-.64551,6.458,5.94287-2.60938L22,37.68066l3.27344-5.60351,5.94287,2.61035-.64551-6.458,6.34277-1.38183Zm.44385,2.75244L30.772,23.97827l-1.59558-2.07391,1.97888.735Zm-8.82147,6.1579L22.75,33.424V30.88977l1.52228-2.22168ZM18.56226,13.48816,19.819,15.09534l-2.49219-.88642L15.94037,12.337Zm6.87719.00116,2.62043-1.15027-1.38654,1.86981L24.183,15.0946Zm3.59357,2.6029-1.22546,1.7381.07525-2.73486,1.44507-1.94867ZM22,29.33008l-2.16406-3.15686L22,23.23688l2.16406,2.93634Zm-4.25458-9.582-.10528-3.836,3.60986,1.284v3.73242Zm5.00458-2.552,3.60986-1.284-.10528,3.836L22.75,20.92853Zm-7.78174-1.10559-.29352-2.94263,1.44245,1.94739.07519,2.73321Zm2.30982,5.08319,3.50817,1.18164-2.16247,2.9342-3.678-1.08447Zm2.4486,7.49285L21.25,30.88977v2.53485L19.78052,30.91Zm3.48707-6.31121,3.50817-1.18164,2.33228,3.03137-3.678,1.08447Zm10.87219-4.28113-2.714,3.04529L28.16418,19.928l1.92176-2.72565ZM24.06036,12.81769l-2.06012,2.6322-2.059-2.63318L22,9.292ZM9.91455,18.07227l4.00079-.87195,1.921,2.72735-3.20794,1.19019Zm2.93024,4.565,1.9801-.73462L13.228,23.97827l-2.26838.77429Zm-1.55591,3.58819L13.701,25.4021l2.64935.78058-2.14447.67853Zm3.64868,1.977L18.19,27.17334l.08313,3.46332L14.52979,32.2793Zm10.7876,2.43549.08447-3.464,3.25165,1.03052.407,4.07684Zm4.06824-3.77478-2.14545-.68,2.65063-.781,2.41266.825Z"}));var _o=()=>Object(ye.createElement)("div",{className:"wp-block-embed is-loading"},Object(ye.createElement)(ke.Spinner,null),Object(ye.createElement)("p",null,Object(we.__)("Embedding…")));var ko=({icon:e,label:t,value:n,onSubmit:o,onChange:r,cannotEmbed:a,fallback:l,tryAgain:c})=>Object(ye.createElement)(ke.Placeholder,{icon:Object(ye.createElement)(Ee.BlockIcon,{icon:e,showColors:!0}),label:t,className:"wp-block-embed",instructions:Object(we.__)("Paste a link to the content you want to display on your site.")},Object(ye.createElement)("form",{onSubmit:o},Object(ye.createElement)("input",{type:"url",value:n||"",className:"components-placeholder__input","aria-label":t,placeholder:Object(we.__)("Enter URL to embed here…"),onChange:r}),Object(ye.createElement)(ke.Button,{variant:"primary",type:"submit"},Object(we._x)("Embed","button label"))),Object(ye.createElement)("div",{className:"components-placeholder__learn-more"},Object(ye.createElement)(ke.ExternalLink,{href:Object(we.__)("https://wordpress.org/support/article/embeds/")},Object(we.__)("Learn more about embeds"))),a&&Object(ye.createElement)("div",{className:"components-placeholder__error"},Object(ye.createElement)("div",{className:"components-placeholder__instructions"},Object(we.__)("Sorry, this content could not be embedded.")),Object(ye.createElement)(ke.Button,{variant:"secondary",onClick:c},Object(we._x)("Try again","button label"))," ",Object(ye.createElement)(ke.Button,{variant:"secondary",onClick:l},Object(we._x)("Convert to link","button label"))));const wo={class:"className",frameborder:"frameBorder",marginheight:"marginHeight",marginwidth:"marginWidth"};function Eo({html:e}){const t=Object(ye.useRef)(),n=Object(ye.useMemo)(()=>{const t=(new window.DOMParser).parseFromString(e,"text/html").querySelector("iframe"),n={};return t?(Array.from(t.attributes).forEach(({name:e,value:t})=>{"style"!==e&&(n[wo[e]||e]=t)}),n):n},[e]);return Object(ye.useEffect)(()=>{const{ownerDocument:e}=t.current,{defaultView:o}=e;function r({data:{secret:e,message:o,value:r}={}}){"height"===o&&e===n["data-secret"]&&(t.current.height=r)}return o.addEventListener("message",r),()=>{o.removeEventListener("message",r)}},[]),Object(ye.createElement)("div",{className:"wp-block-embed__wrapper"},Object(ye.createElement)("iframe",Object(mt.a)({ref:Object(nt.useMergeRefs)([t,Object(nt.useFocusableIframe)()]),title:n.title},n)))}class Co extends ye.Component{constructor(){super(...arguments),this.hideOverlay=this.hideOverlay.bind(this),this.state={interactive:!1}}static getDerivedStateFromProps(e,t){return!e.isSelected&&t.interactive?{interactive:!1}:null}hideOverlay(){this.setState({interactive:!0})}render(){const{preview:e,previewable:t,url:n,type:o,caption:r,onCaptionChange:a,isSelected:l,className:c,icon:i,label:s,insertBlocksAfter:u}=this.props,{scripts:m}=e,{interactive:d}=this.state,b="photo"===o?(e=>{const t=e.thumbnail_url||e.url,n=Object(ye.createElement)("p",null,Object(ye.createElement)("img",{src:t,alt:e.title,width:"100%"}));return Object(ye.renderToString)(n)})(e):e.html,p=new URL(n).host.split("."),g=p.splice(p.length-2,p.length-1).join("."),h=Object(we.sprintf)(Object(we.__)("Embedded content from %s"),g),v=Ve()(o,c,"wp-block-embed__wrapper"),O="wp-embed"===o?Object(ye.createElement)(Eo,{html:b}):Object(ye.createElement)("div",{className:"wp-block-embed__wrapper"},Object(ye.createElement)(ke.SandBox,{html:b,scripts:m,title:h,type:v,onFocus:this.hideOverlay}),!d&&Object(ye.createElement)("div",{className:"block-library-embed__interactive-overlay",onMouseUp:this.hideOverlay}));return Object(ye.createElement)("figure",{className:Ve()(c,"wp-block-embed",{"is-type-video":"video"===o})},t?O:Object(ye.createElement)(ke.Placeholder,{icon:Object(ye.createElement)(Ee.BlockIcon,{icon:i,showColors:!0}),label:s},Object(ye.createElement)("p",{className:"components-placeholder__error"},Object(ye.createElement)("a",{href:n},n)),Object(ye.createElement)("p",{className:"components-placeholder__error"},Object(we.sprintf)(Object(we.__)("Embedded content from %s can't be previewed in the editor."),g))),(!Ee.RichText.isEmpty(r)||l)&&Object(ye.createElement)(Ee.RichText,{tagName:"figcaption",placeholder:Object(we.__)("Add caption"),value:r,onChange:a,inlineToolbar:!0,__unstableOnSplitAtEnd:()=>u(Object(je.createBlock)("core/paragraph"))}))}}var xo=Co;var So=e=>{const{attributes:{providerNameSlug:t,previewable:n,responsive:o,url:r},attributes:a,isSelected:l,onReplace:c,setAttributes:i,insertBlocksAfter:s,onFocus:u}=e,m={title:Object(we._x)("Embed","block title"),icon:no},{icon:d,title:b}=(p=t,(null===(g=Object(je.getBlockVariations)(Fe))||void 0===g?void 0:g.find(({name:e})=>e===p))||m);var p,g;const[h,v]=Object(ye.useState)(r),[O,j]=Object(ye.useState)(!1),{invalidateResolution:y}=Object(Ie.useDispatch)(It.store),{preview:f,fetching:_,themeSupportsResponsive:k,cannotEmbed:w}=Object(Ie.useSelect)(e=>{var t;const{getEmbedPreview:n,isPreviewEmbedFallback:o,isRequestingEmbedPreview:a,getThemeSupports:l}=e(It.store);if(!r)return{fetching:!1,cannotEmbed:!1};const c=n(r),i=o(r),s=!1===(null==c?void 0:c.html)&&void 0===(null==c?void 0:c.type),u=404===(null==c||null===(t=c.data)||void 0===t?void 0:t.status),m=!!c&&!s&&!u;return{preview:m?c:void 0,fetching:a(r),themeSupportsResponsive:l()["responsive-embeds"],cannotEmbed:!m||i}},[r]),E=()=>{const{allowResponsive:e,className:t}=a;return{...a,...We(f,b,t,o,e)}};Object(ye.useEffect)(()=>{if(null==f||!f.html||!w||_)return;const e=r.replace(/\/$/,"");v(e),j(!1),i({url:e})},[null==f?void 0:f.html,r]),Object(ye.useEffect)(()=>{if(f&&!O&&(i(E()),c)){const t=Ge(e,E());t&&c(t)}},[f,O]);const C=Object(Ee.useBlockProps)();if(_)return Object(ye.createElement)(fe.View,C,Object(ye.createElement)(_o,null));const x=Object(we.sprintf)(Object(we.__)("%s URL"),b);if(!f||w||O)return Object(ye.createElement)(fe.View,C,Object(ye.createElement)(ko,{icon:d,label:x,onFocus:u,onSubmit:e=>{e&&e.preventDefault(),j(!1),i({url:h})},value:h,cannotEmbed:w,onChange:e=>v(e.target.value),fallback:()=>function(e,t){const n=Object(ye.createElement)("a",{href:e},e);t(Object(je.createBlock)("core/paragraph",{content:Object(ye.renderToString)(n)}))}(h,c),tryAgain:()=>{y("getEmbedPreview",[h])}}));const{caption:S,type:B,allowResponsive:T,className:N}=E(),P=tt()(N,e.className);return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(to,{showEditButton:f&&!w,themeSupportsResponsive:k,blockSupportsResponsive:o,allowResponsive:T,toggleResponsive:()=>{const{allowResponsive:e,className:t}=a,{html:n}=f,r=!e;i({allowResponsive:r,className:Ue(n,t,o&&r)})},switchBackToURLInput:()=>j(!0)}),Object(ye.createElement)(fe.View,C,Object(ye.createElement)(xo,{preview:f,previewable:n,className:P,url:h,type:B,caption:S,onCaptionChange:e=>i({caption:e}),isSelected:l,icon:d,label:x,insertBlocksAfter:s})))};const{name:Bo}={apiVersion:2,name:"core/embed",title:"Embed",category:"embed",description:"Add a block that displays content pulled from other sites, like Twitter or YouTube.",textdomain:"default",attributes:{url:{type:"string"},caption:{type:"string",source:"html",selector:"figcaption"},type:{type:"string"},providerNameSlug:{type:"string"},allowResponsive:{type:"boolean",default:!0},responsive:{type:"boolean",default:!1},previewable:{type:"boolean",default:!0}},supports:{align:!0},editorStyle:"wp-block-embed-editor",style:"wp-block-embed"};var To={from:[{type:"raw",isMatch:e=>{var t,n;return"P"===e.nodeName&&/^\s*(https?:\/\/\S+)\s*$/i.test(e.textContent)&&1===(null===(t=e.textContent)||void 0===t||null===(n=t.match(/https/gi))||void 0===n?void 0:n.length)},transform:e=>Object(je.createBlock)(Bo,{url:e.textContent.trim()})}],to:[{type:"block",blocks:["core/paragraph"],isMatch:({url:e})=>!!e,transform:({url:e,caption:t})=>{let n=`${e}`;return null!=t&&t.trim()&&(n+="
"+t),Object(je.createBlock)("core/paragraph",{content:n})}}]};const No=[{name:"twitter",title:"Twitter",icon:lo,keywords:["tweet",Object(we.__)("social")],description:Object(we.__)("Embed a tweet."),patterns:[/^https?:\/\/(www\.)?twitter\.com\/.+/i],attributes:{providerNameSlug:"twitter",responsive:!0}},{name:"youtube",title:"YouTube",icon:co,keywords:[Object(we.__)("music"),Object(we.__)("video")],description:Object(we.__)("Embed a YouTube video."),patterns:[/^https?:\/\/((m|www)\.)?youtube\.com\/.+/i,/^https?:\/\/youtu\.be\/.+/i],attributes:{providerNameSlug:"youtube",responsive:!0}},{name:"facebook",title:"Facebook",icon:io,keywords:[Object(we.__)("social")],description:Object(we.__)("Embed a Facebook post."),scope:["block"],patterns:[],attributes:{providerNameSlug:"facebook",previewable:!1,responsive:!0}},{name:"instagram",title:"Instagram",icon:so,keywords:[Object(we.__)("image"),Object(we.__)("social")],description:Object(we.__)("Embed an Instagram post."),scope:["block"],patterns:[],attributes:{providerNameSlug:"instagram",responsive:!0}},{name:"wordpress",title:"WordPress",icon:uo,keywords:[Object(we.__)("post"),Object(we.__)("blog")],description:Object(we.__)("Embed a WordPress post."),attributes:{providerNameSlug:"wordpress"}},{name:"soundcloud",title:"SoundCloud",icon:oo,keywords:[Object(we.__)("music"),Object(we.__)("audio")],description:Object(we.__)("Embed SoundCloud content."),patterns:[/^https?:\/\/(www\.)?soundcloud\.com\/.+/i],attributes:{providerNameSlug:"soundcloud",responsive:!0}},{name:"spotify",title:"Spotify",icon:mo,keywords:[Object(we.__)("music"),Object(we.__)("audio")],description:Object(we.__)("Embed Spotify content."),patterns:[/^https?:\/\/(open|play)\.spotify\.com\/.+/i],attributes:{providerNameSlug:"spotify",responsive:!0}},{name:"flickr",title:"Flickr",icon:bo,keywords:[Object(we.__)("image")],description:Object(we.__)("Embed Flickr content."),patterns:[/^https?:\/\/(www\.)?flickr\.com\/.+/i,/^https?:\/\/flic\.kr\/.+/i],attributes:{providerNameSlug:"flickr",responsive:!0}},{name:"vimeo",title:"Vimeo",icon:po,keywords:[Object(we.__)("video")],description:Object(we.__)("Embed a Vimeo video."),patterns:[/^https?:\/\/(www\.)?vimeo\.com\/.+/i],attributes:{providerNameSlug:"vimeo",responsive:!0}},{name:"animoto",title:"Animoto",icon:Oo,description:Object(we.__)("Embed an Animoto video."),patterns:[/^https?:\/\/(www\.)?(animoto|video214)\.com\/.+/i],attributes:{providerNameSlug:"animoto",responsive:!0}},{name:"cloudup",title:"Cloudup",icon:no,description:Object(we.__)("Embed Cloudup content."),patterns:[/^https?:\/\/cloudup\.com\/.+/i],attributes:{providerNameSlug:"cloudup",responsive:!0}},{name:"collegehumor",title:"CollegeHumor",icon:ao,description:Object(we.__)("Embed CollegeHumor content."),scope:["block"],patterns:[],attributes:{providerNameSlug:"collegehumor",responsive:!0}},{name:"crowdsignal",title:"Crowdsignal",icon:no,keywords:["polldaddy",Object(we.__)("survey")],description:Object(we.__)("Embed Crowdsignal (formerly Polldaddy) content."),patterns:[/^https?:\/\/((.+\.)?polldaddy\.com|poll\.fm|.+\.survey\.fm)\/.+/i],attributes:{providerNameSlug:"crowdsignal",responsive:!0}},{name:"dailymotion",title:"Dailymotion",icon:jo,keywords:[Object(we.__)("video")],description:Object(we.__)("Embed a Dailymotion video."),patterns:[/^https?:\/\/(www\.)?dailymotion\.com\/.+/i],attributes:{providerNameSlug:"dailymotion",responsive:!0}},{name:"imgur",title:"Imgur",icon:ro,description:Object(we.__)("Embed Imgur content."),patterns:[/^https?:\/\/(.+\.)?imgur\.com\/.+/i],attributes:{providerNameSlug:"imgur",responsive:!0}},{name:"issuu",title:"Issuu",icon:no,description:Object(we.__)("Embed Issuu content."),patterns:[/^https?:\/\/(www\.)?issuu\.com\/.+/i],attributes:{providerNameSlug:"issuu",responsive:!0}},{name:"kickstarter",title:"Kickstarter",icon:no,description:Object(we.__)("Embed Kickstarter content."),patterns:[/^https?:\/\/(www\.)?kickstarter\.com\/.+/i,/^https?:\/\/kck\.st\/.+/i],attributes:{providerNameSlug:"kickstarter",responsive:!0}},{name:"mixcloud",title:"Mixcloud",icon:oo,keywords:[Object(we.__)("music"),Object(we.__)("audio")],description:Object(we.__)("Embed Mixcloud content."),patterns:[/^https?:\/\/(www\.)?mixcloud\.com\/.+/i],attributes:{providerNameSlug:"mixcloud",responsive:!0}},{name:"reddit",title:"Reddit",icon:go,description:Object(we.__)("Embed a Reddit thread."),patterns:[/^https?:\/\/(www\.)?reddit\.com\/.+/i],attributes:{providerNameSlug:"reddit",responsive:!0}},{name:"reverbnation",title:"ReverbNation",icon:oo,description:Object(we.__)("Embed ReverbNation content."),patterns:[/^https?:\/\/(www\.)?reverbnation\.com\/.+/i],attributes:{providerNameSlug:"reverbnation",responsive:!0}},{name:"screencast",title:"Screencast",icon:ao,description:Object(we.__)("Embed Screencast content."),patterns:[/^https?:\/\/(www\.)?screencast\.com\/.+/i],attributes:{providerNameSlug:"screencast",responsive:!0}},{name:"scribd",title:"Scribd",icon:no,description:Object(we.__)("Embed Scribd content."),patterns:[/^https?:\/\/(www\.)?scribd\.com\/.+/i],attributes:{providerNameSlug:"scribd",responsive:!0}},{name:"slideshare",title:"Slideshare",icon:no,description:Object(we.__)("Embed Slideshare content."),patterns:[/^https?:\/\/(.+?\.)?slideshare\.net\/.+/i],attributes:{providerNameSlug:"slideshare",responsive:!0}},{name:"smugmug",title:"SmugMug",icon:ro,description:Object(we.__)("Embed SmugMug content."),patterns:[/^https?:\/\/(.+\.)?smugmug\.com\/.*/i],attributes:{providerNameSlug:"smugmug",previewable:!1,responsive:!0}},{name:"speaker-deck",title:"Speaker Deck",icon:no,description:Object(we.__)("Embed Speaker Deck content."),patterns:[/^https?:\/\/(www\.)?speakerdeck\.com\/.+/i],attributes:{providerNameSlug:"speaker-deck",responsive:!0}},{name:"tiktok",title:"TikTok",icon:ao,keywords:[Object(we.__)("video")],description:Object(we.__)("Embed a TikTok video."),patterns:[/^https?:\/\/(www\.)?tiktok\.com\/.+/i],attributes:{providerNameSlug:"tiktok",responsive:!0}},{name:"ted",title:"TED",icon:ao,description:Object(we.__)("Embed a TED video."),patterns:[/^https?:\/\/(www\.|embed\.)?ted\.com\/.+/i],attributes:{providerNameSlug:"ted",responsive:!0}},{name:"tumblr",title:"Tumblr",icon:ho,keywords:[Object(we.__)("social")],description:Object(we.__)("Embed a Tumblr post."),patterns:[/^https?:\/\/(www\.)?tumblr\.com\/.+/i],attributes:{providerNameSlug:"tumblr",responsive:!0}},{name:"videopress",title:"VideoPress",icon:ao,keywords:[Object(we.__)("video")],description:Object(we.__)("Embed a VideoPress video."),patterns:[/^https?:\/\/videopress\.com\/.+/i],attributes:{providerNameSlug:"videopress",responsive:!0}},{name:"wordpress-tv",title:"WordPress.tv",icon:ao,description:Object(we.__)("Embed a WordPress.tv video."),patterns:[/^https?:\/\/wordpress\.tv\/.+/i],attributes:{providerNameSlug:"wordpress-tv",responsive:!0}},{name:"amazon-kindle",title:"Amazon Kindle",icon:vo,keywords:[Object(we.__)("ebook")],description:Object(we.__)("Embed Amazon Kindle content."),patterns:[/^https?:\/\/([a-z0-9-]+\.)?(amazon|amzn)(\.[a-z]{2,4})+\/.+/i,/^https?:\/\/(www\.)?(a\.co|z\.cn)\/.+/i],attributes:{providerNameSlug:"amazon-kindle"}},{name:"pinterest",title:"Pinterest",icon:yo,keywords:[Object(we.__)("social"),Object(we.__)("bookmark")],description:Object(we.__)("Embed Pinterest pins, boards, and profiles."),patterns:[/^https?:\/\/([a-z]{2}|www)\.pinterest\.com(\.(au|mx))?\/.*/i],attributes:{providerNameSlug:"pinterest"}},{name:"wolfram-cloud",title:"Wolfram Cloud",icon:fo,description:Object(we.__)("Embed Wolfram Cloud notebook content."),patterns:[/^https?:\/\/(www\.)?wolframcloud\.com\/obj\/.+/i],attributes:{providerNameSlug:"wolfram-cloud",responsive:!0}}];No.forEach(e=>{e.isActive||(e.isActive=(e,t)=>e.providerNameSlug===t.providerNameSlug)});var Po=No;const{attributes:zo}={apiVersion:2,name:"core/embed",title:"Embed",category:"embed",description:"Add a block that displays content pulled from other sites, like Twitter or YouTube.",textdomain:"default",attributes:{url:{type:"string"},caption:{type:"string",source:"html",selector:"figcaption"},type:{type:"string"},providerNameSlug:{type:"string"},allowResponsive:{type:"boolean",default:!0},responsive:{type:"boolean",default:!1},previewable:{type:"boolean",default:!0}},supports:{align:!0},editorStyle:"wp-block-embed-editor",style:"wp-block-embed"};var Io=[{attributes:zo,save({attributes:{url:e,caption:t,type:n,providerNameSlug:o}}){if(!e)return null;const r=tt()("wp-block-embed",{["is-type-"+n]:n,["is-provider-"+o]:o});return Object(ye.createElement)("figure",{className:r},`\n${e}\n`,!Ee.RichText.isEmpty(t)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:t}))}}];const Mo={apiVersion:2,name:"core/embed",title:"Embed",category:"embed",description:"Add a block that displays content pulled from other sites, like Twitter or YouTube.",textdomain:"default",attributes:{url:{type:"string"},caption:{type:"string",source:"html",selector:"figcaption"},type:{type:"string"},providerNameSlug:{type:"string"},allowResponsive:{type:"boolean",default:!0},responsive:{type:"boolean",default:!1},previewable:{type:"boolean",default:!0}},supports:{align:!0},editorStyle:"wp-block-embed-editor",style:"wp-block-embed"},{name:Ro}=Mo,Lo={icon:no,edit:So,save:function({attributes:e}){const{url:t,caption:n,type:o,providerNameSlug:r}=e;if(!t)return null;const a=Ve()("wp-block-embed",{["is-type-"+o]:o,["is-provider-"+r]:r,["wp-block-embed-"+r]:r});return Object(ye.createElement)("figure",Ee.useBlockProps.save({className:a}),Object(ye.createElement)("div",{className:"wp-block-embed__wrapper"},`\n${t}\n`),!Ee.RichText.isEmpty(n)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:n}))},transforms:To,variations:Po,deprecated:Io};var Vo=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M19 6.2h-5.9l-.6-1.1c-.3-.7-1-1.1-1.8-1.1H5c-1.1 0-2 .9-2 2v11.8c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V8.2c0-1.1-.9-2-2-2zm.5 11.6c0 .3-.2.5-.5.5H5c-.3 0-.5-.2-.5-.5V6c0-.3.2-.5.5-.5h5.8c.2 0 .4.1.4.3l1 2H19c.3 0 .5.2.5.5v9.5z"}));var Ao=[{attributes:{id:{type:"number"},href:{type:"string"},fileName:{type:"string",source:"html",selector:"a:not([download])"},textLinkHref:{type:"string",source:"attribute",selector:"a:not([download])",attribute:"href"},textLinkTarget:{type:"string",source:"attribute",selector:"a:not([download])",attribute:"target"},showDownloadButton:{type:"boolean",default:!0},downloadButtonText:{type:"string",source:"html",selector:"a[download]"},displayPreview:{type:"boolean"},previewHeight:{type:"number",default:600}},supports:{anchor:!0,align:!0},save({attributes:e}){const{href:t,fileName:n,textLinkHref:o,textLinkTarget:r,showDownloadButton:a,downloadButtonText:l,displayPreview:c,previewHeight:i}=e,s=Ee.RichText.isEmpty(n)?Object(we.__)("PDF embed"):Object(we.sprintf)(Object(we.__)("Embed of %s."),n);return t&&Object(ye.createElement)("div",Ee.useBlockProps.save(),c&&Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)("object",{className:"wp-block-file__embed",data:t,type:"application/pdf",style:{width:"100%",height:i+"px"},"aria-label":s})),!Ee.RichText.isEmpty(n)&&Object(ye.createElement)("a",{href:o,target:r,rel:r?"noreferrer noopener":void 0},Object(ye.createElement)(Ee.RichText.Content,{value:n})),a&&Object(ye.createElement)("a",{href:t,className:"wp-block-file__button",download:!0},Object(ye.createElement)(Ee.RichText.Content,{value:l})))}}],Ho=n("onLe");function Fo({hrefs:e,openInNewWindow:t,showDownloadButton:n,changeLinkDestinationOption:o,changeOpenInNewWindow:r,changeShowDownloadButton:a,displayPreview:l,changeDisplayPreview:c,previewHeight:i,changePreviewHeight:s}){const{href:u,textLinkHref:m,attachmentPage:d}=e;let b=[{value:u,label:Object(we.__)("URL")}];return d&&(b=[{value:u,label:Object(we.__)("Media file")},{value:d,label:Object(we.__)("Attachment page")}]),Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.InspectorControls,null,u.endsWith(".pdf")&&Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("PDF settings")},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show inline embed"),help:l?Object(we.__)("Note: Most phone and tablet browsers won't display embedded PDFs."):null,checked:!!l,onChange:c}),l&&Object(ye.createElement)(ke.RangeControl,{label:Object(we.__)("Height in pixels"),min:qo,max:Math.max(Uo,i),value:i,onChange:s})),Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Text link settings")},Object(ye.createElement)(ke.SelectControl,{label:Object(we.__)("Link to"),value:m,options:b,onChange:o}),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Open in new tab"),checked:t,onChange:r})),Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Download button settings")},Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Show download button"),checked:n,onChange:a}))))}const Do=()=>!(window.navigator.userAgent.indexOf("Mobi")>-1)&&(!(window.navigator.userAgent.indexOf("Android")>-1)&&(!(window.navigator.userAgent.indexOf("Macintosh")>-1&&window.navigator.maxTouchPoints&&window.navigator.maxTouchPoints>2)&&!((window.ActiveXObject||"ActiveXObject"in window)&&!Go("AcroPDF.PDF")&&!Go("PDF.PdfCtrl")))),Go=e=>{let t;try{t=new window.ActiveXObject(e)}catch(e){t=void 0}return t},qo=200,Uo=2e3;function Wo({text:e,disabled:t}){const{createNotice:n}=Object(Ie.useDispatch)(Ho.store),o=Object(nt.useCopyToClipboard)(e,()=>{n("info",Object(we.__)("Copied URL to clipboard."),{isDismissible:!0,type:"snackbar"})});return Object(ye.createElement)(ke.ToolbarButton,{className:"components-clipboard-toolbar-button",ref:o,disabled:t},Object(we.__)("Copy URL"))}var $o=Object(ke.withNotices)((function({attributes:e,isSelected:t,setAttributes:n,noticeUI:o,noticeOperations:r,clientId:a}){const{id:l,fileName:c,href:i,textLinkHref:s,textLinkTarget:u,showDownloadButton:m,downloadButtonText:d,displayPreview:b,previewHeight:p}=e,[g,h]=Object(ye.useState)(!1),{media:v,mediaUpload:O}=Object(Ie.useSelect)(e=>({media:void 0===l?void 0:e(It.store).getMedia(l),mediaUpload:e(Ee.store).getSettings().mediaUpload}),[l]),{toggleSelection:j}=Object(Ie.useDispatch)(Ee.store);function y(e){if(e&&e.url){h(!1);const t=e.url.endsWith(".pdf");n({href:e.url,fileName:e.title,textLinkHref:e.url,id:e.id,displayPreview:!!t||void 0,previewHeight:t?600:void 0})}}function f(e){h(!0),r.removeAllNotices(),r.createErrorNotice(e)}function _(e){n({downloadButtonText:e.replace(/<\/?a[^>]*>/g,"")})}Object(ye.useEffect)(()=>{if(Object(ze.isBlobURL)(i)){const e=Object(ze.getBlobByURL)(i);O({filesList:[e],onFileChange:([e])=>y(e),onError:e=>{h(!0),r.createErrorNotice(e)}}),Object(ze.revokeBlobURL)(i)}void 0===d&&_(Object(we._x)("Download","button label"))},[]),Object(ye.useEffect)(()=>{n({fileId:"wp-block-file--media-"+a})},[a]);const k=v&&v.link,w=Object(Ee.useBlockProps)({className:tt()(Object(ze.isBlobURL)(i)&&Object(ke.__unstableGetAnimateClassName)({type:"loading"}),{"is-transient":Object(ze.isBlobURL)(i)})}),E=Do()&&b;return!i||g?Object(ye.createElement)("div",w,Object(ye.createElement)(Ee.MediaPlaceholder,{icon:Object(ye.createElement)(Ee.BlockIcon,{icon:Vo}),labels:{title:Object(we.__)("File"),instructions:Object(we.__)("Upload a file or pick one from your media library.")},onSelect:y,notices:o,onError:f,accept:"*"})):Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Fo,{hrefs:{href:i,textLinkHref:s,attachmentPage:k},openInNewWindow:!!u,showDownloadButton:m,changeLinkDestinationOption:function(e){n({textLinkHref:e})},changeOpenInNewWindow:function(e){n({textLinkTarget:!!e&&"_blank"})},changeShowDownloadButton:function(e){n({showDownloadButton:e})},displayPreview:b,changeDisplayPreview:function(e){n({displayPreview:e})},previewHeight:p,changePreviewHeight:function(e){const t=Math.max(parseInt(e,10),qo);n({previewHeight:t})}}),Object(ye.createElement)(Ee.BlockControls,{group:"other"},Object(ye.createElement)(Ee.MediaReplaceFlow,{mediaId:l,mediaURL:i,accept:"*",onSelect:y,onError:f}),Object(ye.createElement)(Wo,{text:i,disabled:Object(ze.isBlobURL)(i)})),Object(ye.createElement)("div",w,E&&Object(ye.createElement)(ke.ResizableBox,{size:{height:p},minHeight:qo,maxHeight:Uo,minWidth:"100%",grid:[10,10],enable:{top:!1,right:!1,bottom:!0,left:!1,topRight:!1,bottomRight:!1,bottomLeft:!1,topLeft:!1},onResizeStart:()=>j(!1),onResizeStop:function(e,t,o,r){j(!0);const a=parseInt(p+r.height,10);n({previewHeight:a})},showHandle:t},Object(ye.createElement)("object",{className:"wp-block-file__preview",data:i,type:"application/pdf","aria-label":Object(we.__)("Embed of the selected PDF file.")}),!t&&Object(ye.createElement)("div",{className:"wp-block-file__preview-overlay"})),Object(ye.createElement)("div",{className:"wp-block-file__content-wrapper"},Object(ye.createElement)(Ee.RichText,{tagName:"a",value:c,placeholder:Object(we.__)("Write file name…"),withoutInteractiveFormatting:!0,onChange:e=>n({fileName:e}),href:s}),m&&Object(ye.createElement)("div",{className:"wp-block-file__button-richtext-wrapper"},Object(ye.createElement)(Ee.RichText,{tagName:"div","aria-label":Object(we.__)("Download button text"),className:"wp-block-file__button",value:d,withoutInteractiveFormatting:!0,placeholder:Object(we.__)("Add text…"),onChange:e=>_(e)})))))}));var Zo=n("Mmq9");var Ko={from:[{type:"files",isMatch:e=>e.length>0,priority:15,transform:e=>{const t=[];return e.forEach(e=>{const n=Object(ze.createBlobURL)(e);t.push(Object(je.createBlock)("core/file",{href:n,fileName:e.name,textLinkHref:n}))}),t}},{type:"block",blocks:["core/audio"],transform:e=>Object(je.createBlock)("core/file",{href:e.src,fileName:e.caption,textLinkHref:e.src,id:e.id,anchor:e.anchor})},{type:"block",blocks:["core/video"],transform:e=>Object(je.createBlock)("core/file",{href:e.src,fileName:e.caption,textLinkHref:e.src,id:e.id,anchor:e.anchor})},{type:"block",blocks:["core/image"],transform:e=>Object(je.createBlock)("core/file",{href:e.url,fileName:e.caption||Object(Zo.getFilename)(e.url),textLinkHref:e.url,id:e.id,anchor:e.anchor})}],to:[{type:"block",blocks:["core/audio"],isMatch:({id:e})=>{if(!e)return!1;const{getMedia:t}=Object(Ie.select)(It.store),n=t(e);return!!n&&Object(Re.includes)(n.mime_type,"audio")},transform:e=>Object(je.createBlock)("core/audio",{src:e.href,caption:e.fileName,id:e.id,anchor:e.anchor})},{type:"block",blocks:["core/video"],isMatch:({id:e})=>{if(!e)return!1;const{getMedia:t}=Object(Ie.select)(It.store),n=t(e);return!!n&&Object(Re.includes)(n.mime_type,"video")},transform:e=>Object(je.createBlock)("core/video",{src:e.href,caption:e.fileName,id:e.id,anchor:e.anchor})},{type:"block",blocks:["core/image"],isMatch:({id:e})=>{if(!e)return!1;const{getMedia:t}=Object(Ie.select)(It.store),n=t(e);return!!n&&Object(Re.includes)(n.mime_type,"image")},transform:e=>Object(je.createBlock)("core/image",{url:e.href,caption:e.fileName,id:e.id,anchor:e.anchor})}]};const Jo={apiVersion:2,name:"core/file",title:"File",category:"media",description:"Add a link to a downloadable file.",keywords:["document","pdf","download"],textdomain:"default",attributes:{id:{type:"number"},href:{type:"string"},fileId:{type:"string",source:"attribute",selector:"a:not([download])",attribute:"id"},fileName:{type:"string",source:"html",selector:"a:not([download])"},textLinkHref:{type:"string",source:"attribute",selector:"a:not([download])",attribute:"href"},textLinkTarget:{type:"string",source:"attribute",selector:"a:not([download])",attribute:"target"},showDownloadButton:{type:"boolean",default:!0},downloadButtonText:{type:"string",source:"html",selector:"a[download]"},displayPreview:{type:"boolean"},previewHeight:{type:"number",default:600}},supports:{anchor:!0,align:!0},viewScript:"file:./view.min.js",editorStyle:"wp-block-file-editor",style:"wp-block-file"},{name:Qo}=Jo,Yo={icon:Vo,example:{attributes:{href:"https://upload.wikimedia.org/wikipedia/commons/d/dd/Armstrong_Small_Step.ogg",fileName:Object(we._x)("Armstrong_Small_Step","Name of the file")}},transforms:Ko,deprecated:Ao,edit:$o,save:function({attributes:e}){const{href:t,fileId:n,fileName:o,textLinkHref:r,textLinkTarget:a,showDownloadButton:l,downloadButtonText:c,displayPreview:i,previewHeight:s}=e,u=Ee.RichText.isEmpty(o)?Object(we.__)("PDF embed"):Object(we.sprintf)(Object(we.__)("Embed of %s."),o);return t&&Object(ye.createElement)("div",Ee.useBlockProps.save(),i&&Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)("object",{className:"wp-block-file__embed",data:t,type:"application/pdf",style:{width:"100%",height:s+"px"},"aria-label":u})),!Ee.RichText.isEmpty(o)&&Object(ye.createElement)("a",{id:n,href:r,target:a,rel:a?"noreferrer noopener":void 0},Object(ye.createElement)(Ee.RichText.Content,{value:o})),l&&Object(ye.createElement)("a",{href:t,className:"wp-block-file__button",download:!0,"aria-describedby":n},Object(ye.createElement)(Ee.RichText.Content,{value:c})))}};var Xo=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M20.2 8v11c0 .7-.6 1.2-1.2 1.2H6v1.5h13c1.5 0 2.7-1.2 2.7-2.8V8h-1.5zM18 16.4V4.6c0-.9-.7-1.6-1.6-1.6H4.6C3.7 3 3 3.7 3 4.6v11.8c0 .9.7 1.6 1.6 1.6h11.8c.9 0 1.6-.7 1.6-1.6zM4.5 4.6c0-.1.1-.1.1-.1h11.8c.1 0 .1.1.1.1V12l-2.3-1.7c-.3-.2-.6-.2-.9 0l-2.9 2.1L8 11.3c-.2-.1-.5-.1-.7 0l-2.9 1.5V4.6zm0 11.8v-1.8l3.2-1.7 2.4 1.2c.2.1.5.1.8-.1l2.8-2 2.8 2v2.5c0 .1-.1.1-.1.1H4.6c0-.1-.1-.2-.1-.2z"}));function er(e){return Math.min(3,e.images.length)}var tr=[{attributes:{images:{type:"array",default:[],source:"query",selector:".blocks-gallery-item",query:{url:{type:"string",source:"attribute",selector:"img",attribute:"src"},fullUrl:{type:"string",source:"attribute",selector:"img",attribute:"data-full-url"},link:{type:"string",source:"attribute",selector:"img",attribute:"data-link"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""},id:{type:"string",source:"attribute",selector:"img",attribute:"data-id"},caption:{type:"string",source:"html",selector:".blocks-gallery-item__caption"}}},ids:{type:"array",items:{type:"number"},default:[]},columns:{type:"number",minimum:1,maximum:8},caption:{type:"string",source:"html",selector:".blocks-gallery-caption"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string",default:"none"},sizeSlug:{type:"string",default:"large"}},supports:{align:!0},isEligible:({linkTo:e})=>!e||"attachment"===e||"media"===e,migrate(e){let t=e.linkTo;return e.linkTo?"attachment"===e.linkTo?t="post":"media"===e.linkTo&&(t="file"):t="none",{...e,linkTo:t}},save({attributes:e}){const{images:t,columns:n=er(e),imageCrop:o,caption:r,linkTo:a}=e;return Object(ye.createElement)("figure",{className:`columns-${n} ${o?"is-cropped":""}`},Object(ye.createElement)("ul",{className:"blocks-gallery-grid"},t.map(e=>{let t;switch(a){case"media":t=e.fullUrl||e.url;break;case"attachment":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-"+e.id:null});return Object(ye.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(ye.createElement)("figure",null,t?Object(ye.createElement)("a",{href:t},n):n,!Ee.RichText.isEmpty(e.caption)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-item__caption",value:e.caption})))})),!Ee.RichText.isEmpty(r)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:r}))}},{attributes:{images:{type:"array",default:[],source:"query",selector:".blocks-gallery-item",query:{url:{source:"attribute",selector:"img",attribute:"src"},fullUrl:{source:"attribute",selector:"img",attribute:"data-full-url"},link:{source:"attribute",selector:"img",attribute:"data-link"},alt:{source:"attribute",selector:"img",attribute:"alt",default:""},id:{source:"attribute",selector:"img",attribute:"data-id"},caption:{type:"string",source:"html",selector:".blocks-gallery-item__caption"}}},ids:{type:"array",default:[]},columns:{type:"number"},caption:{type:"string",source:"html",selector:".blocks-gallery-caption"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string",default:"none"}},supports:{align:!0},isEligible:({ids:e})=>e&&e.some(e=>"string"==typeof e),migrate:e=>({...e,ids:Object(Re.map)(e.ids,e=>{const t=parseInt(e,10);return Number.isInteger(t)?t:null})}),save({attributes:e}){const{images:t,columns:n=er(e),imageCrop:o,caption:r,linkTo:a}=e;return Object(ye.createElement)("figure",{className:`columns-${n} ${o?"is-cropped":""}`},Object(ye.createElement)("ul",{className:"blocks-gallery-grid"},t.map(e=>{let t;switch(a){case"media":t=e.fullUrl||e.url;break;case"attachment":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-"+e.id:null});return Object(ye.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(ye.createElement)("figure",null,t?Object(ye.createElement)("a",{href:t},n):n,!Ee.RichText.isEmpty(e.caption)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-item__caption",value:e.caption})))})),!Ee.RichText.isEmpty(r)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:r}))}},{attributes:{images:{type:"array",default:[],source:"query",selector:"ul.wp-block-gallery .blocks-gallery-item",query:{url:{source:"attribute",selector:"img",attribute:"src"},fullUrl:{source:"attribute",selector:"img",attribute:"data-full-url"},alt:{source:"attribute",selector:"img",attribute:"alt",default:""},id:{source:"attribute",selector:"img",attribute:"data-id"},link:{source:"attribute",selector:"img",attribute:"data-link"},caption:{type:"array",source:"children",selector:"figcaption"}}},ids:{type:"array",default:[]},columns:{type:"number"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string",default:"none"}},supports:{align:!0},save({attributes:e}){const{images:t,columns:n=er(e),imageCrop:o,linkTo:r}=e;return Object(ye.createElement)("ul",{className:`columns-${n} ${o?"is-cropped":""}`},t.map(e=>{let t;switch(r){case"media":t=e.fullUrl||e.url;break;case"attachment":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-"+e.id:null});return Object(ye.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(ye.createElement)("figure",null,t?Object(ye.createElement)("a",{href:t},n):n,e.caption&&e.caption.length>0&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:e.caption})))}))}},{attributes:{images:{type:"array",default:[],source:"query",selector:"ul.wp-block-gallery .blocks-gallery-item",query:{url:{source:"attribute",selector:"img",attribute:"src"},alt:{source:"attribute",selector:"img",attribute:"alt",default:""},id:{source:"attribute",selector:"img",attribute:"data-id"},link:{source:"attribute",selector:"img",attribute:"data-link"},caption:{type:"array",source:"children",selector:"figcaption"}}},columns:{type:"number"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string",default:"none"}},isEligible:({images:e,ids:t})=>e&&e.length>0&&(!t&&e||t&&e&&t.length!==e.length||Object(Re.some)(e,(e,n)=>!e&&null!==t[n]||parseInt(e,10)!==t[n])),migrate:e=>({...e,ids:Object(Re.map)(e.images,({id:e})=>e?parseInt(e,10):null)}),supports:{align:!0},save({attributes:e}){const{images:t,columns:n=er(e),imageCrop:o,linkTo:r}=e;return Object(ye.createElement)("ul",{className:`columns-${n} ${o?"is-cropped":""}`},t.map(e=>{let t;switch(r){case"media":t=e.url;break;case"attachment":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id,"data-link":e.link,className:e.id?"wp-image-"+e.id:null});return Object(ye.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(ye.createElement)("figure",null,t?Object(ye.createElement)("a",{href:t},n):n,e.caption&&e.caption.length>0&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",value:e.caption})))}))}},{attributes:{images:{type:"array",default:[],source:"query",selector:"div.wp-block-gallery figure.blocks-gallery-image img",query:{url:{source:"attribute",attribute:"src"},alt:{source:"attribute",attribute:"alt",default:""},id:{source:"attribute",attribute:"data-id"}}},columns:{type:"number"},imageCrop:{type:"boolean",default:!0},linkTo:{type:"string",default:"none"},align:{type:"string",default:"none"}},supports:{align:!0},save({attributes:e}){const{images:t,columns:n=er(e),align:o,imageCrop:r,linkTo:a}=e,l=tt()("columns-"+n,{alignnone:"none"===o,"is-cropped":r});return Object(ye.createElement)("div",{className:l},t.map(e=>{let t;switch(a){case"media":t=e.url;break;case"attachment":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id});return Object(ye.createElement)("figure",{key:e.id||e.url,className:"blocks-gallery-image"},t?Object(ye.createElement)("a",{href:t},n):n)}))}}],nr=n("KEfo");const or=Object(ye.createElement)(Ee.BlockIcon,{icon:Xo});const rr=(e,t="large")=>{const n=Object(Re.pick)(e,["alt","id","link","caption"]);n.url=Object(Re.get)(e,["sizes",t,"url"])||Object(Re.get)(e,["media_details","sizes",t,"source_url"])||e.url;const o=Object(Re.get)(e,["sizes","full","url"])||Object(Re.get)(e,["media_details","sizes","full","source_url"]);return o&&(n.fullUrl=o),n},ar=["noreferrer","noopener"],lr=["image"];function cr(e,t){switch(t){case"media":return{href:(null==e?void 0:e.source_url)||(null==e?void 0:e.url),linkDestination:"media"};case"attachment":return{href:null==e?void 0:e.link,linkDestination:"attachment"};case"none":return{href:void 0,linkDestination:"none"}}return{}}function ir(e,{rel:t}){const n=e?"_blank":void 0;let o;return o=n||t?function(e){let t=e;return void 0===e||Object(Re.isEmpty)(t)||Object(Re.isEmpty)(t)||(Object(Re.each)(ar,e=>{const n=new RegExp("\\b"+e+"\\b","gi");t=t.replace(n,"")}),t!==e&&(t=t.trim()),Object(Re.isEmpty)(t)&&(t=void 0)),t}(t):void 0,{linkTarget:n,rel:o}}const sr=["core/image"];function ur({isHidden:e,captionFocused:t,onFocusCaption:n,className:o,value:r,placeholder:a,tagName:l,captionRef:c,...i}){return e?Object(ye.createElement)(ke.VisuallyHidden,Object(mt.a)({as:Ee.RichText},i)):Object(ye.createElement)(Ee.RichText,Object(mt.a)({ref:c,value:r,placeholder:a,className:o,tagName:l,isSelected:t,onClick:n},i))}var mr=e=>{const{attributes:t,isSelected:n,setAttributes:o,mediaPlaceholder:r,insertBlocksAfter:a,blockProps:l}=e,{align:c,columns:i,caption:s,imageCrop:u}=t,{children:m,...d}=Object(Ee.useInnerBlocksProps)(l,{allowedBlocks:sr,orientation:"horizontal",renderAppender:!1,__experimentalLayout:{type:"default",alignments:[]}}),[b,p]=Object(ye.useState)(!1);return Object(ye.useEffect)(()=>{n||p(!1)},[n]),Object(ye.createElement)("figure",Object(mt.a)({},d,{className:tt()(l.className,"blocks-gallery-grid",{["align"+c]:c,["columns-"+i]:void 0!==i,"columns-default":void 0===i,"is-cropped":u})}),m,Object(ye.createElement)(fe.View,{className:"blocks-gallery-media-placeholder-wrapper",onClick:function(){b&&p(!1)}},r),Object(ye.createElement)(ur,{isHidden:!n&&Ee.RichText.isEmpty(s),captionFocused:b,onFocusCaption:function(){b||p(!0)},tagName:"figcaption",className:"blocks-gallery-caption","aria-label":Object(we.__)("Gallery caption text"),placeholder:Object(we.__)("Write gallery caption…"),value:s,onChange:e=>o({caption:e}),inlineToolbar:!0,__unstableOnSplitAtEnd:()=>a(Object(je.createBlock)("core/paragraph"))}))};function dr(e,t,n){return Object(ye.useMemo)(()=>function(){if(!e||0===e.length)return;const{imageSizes:o}=n();let r={};t&&(r=e.reduce((e,t)=>{if(!t.id)return e;const n=o.reduce((e,n)=>{const o=Object(Re.get)(t,["sizes",n.slug,"url"]),r=Object(Re.get)(t,["media_details","sizes",n.slug,"source_url"]);return{...e,[n.slug]:o||r}},{});return{...e,[parseInt(t.id,10)]:n}},{}));return o.filter(({slug:e})=>Object(Re.some)(r,t=>t[e])).map(({name:e,slug:t})=>({value:t,label:e}))}(),[e,t])}function br(e,t){const[n,o]=Object(ye.useState)([]);return Object(ye.useMemo)(()=>function(){let r=!1;const a=n.filter(t=>e.find(e=>t.clientId===e.clientId));a.length{e.fromSavedContent&&!a.find(t=>t.id===e.id)&&(r=!0,a.push(e))});const l=e.filter(e=>!a.find(t=>e.clientId&&t.clientId===e.clientId)&&(null==t?void 0:t.find(t=>t.id===e.id))&&!e.fromSavedConent);(r||(null==l?void 0:l.length)>0)&&o([...a,...l]);return l.length>0?l:null}(),[e,t])}var pr=n("U60i");const gr=[{value:"attachment",label:Object(we.__)("Attachment Page")},{value:"media",label:Object(we.__)("Media File")},{value:"none",label:Object(we._x)("None","Media item link option")}],hr=["image"],vr=ye.Platform.isNative?Object(we.__)("ADD MEDIA"):Object(we.__)("Drag images, upload new ones or select files from your library."),Or=ye.Platform.isNative?{type:"stepper"}:{};var jr=Object(nt.compose)([ke.withNotices,Object(nr.withViewportMatch)({isNarrow:"< small"})])((function(e){const{setAttributes:t,attributes:n,className:o,clientId:r,noticeOperations:a,isSelected:l,noticeUI:c,insertBlocksAfter:i}=e,{columns:s,imageCrop:u,linkTarget:m,linkTo:d,shortCodeTransforms:b,sizeSlug:p}=n;!function(){const{createWarningNotice:e}=Object(Ie.useDispatch)(Ho.store),{toggleFeature:t}=Object(Ie.useDispatch)(pr.i);Object(Ie.useSelect)(e=>{const{isFeatureActive:t}=e(pr.i);return t("core/edit-post","mobileGalleryWarning")},[])&&(e(Object(we.__)("Editing this Gallery in the WordPress mobile app requires version 18.2 or higher."),{type:"snackbar",explicitDismiss:!0}),t("core/edit-post","mobileGalleryWarning"))}();const{__unstableMarkNextChangeAsNotPersistent:g,replaceInnerBlocks:h,updateBlockAttributes:v}=Object(Ie.useDispatch)(Ee.store),{createSuccessNotice:O}=Object(Ie.useDispatch)(Ho.store),{getBlock:j,getSettings:y,preferredStyle:f}=Object(Ie.useSelect)(e=>{var t;const n=e(Ee.store).getSettings().__experimentalPreferredStyleVariations;return{getBlock:e(Ee.store).getBlock,getSettings:e(Ee.store).getSettings,preferredStyle:null==n||null===(t=n.value)||void 0===t?void 0:t["core/image"]}},[]),_=Object(Ie.useSelect)(e=>{var t;return null===(t=e(Ee.store).getBlock(r))||void 0===t?void 0:t.innerBlocks},[r]),k=Object(ye.useMemo)(()=>null==_?void 0:_.map(e=>({clientId:e.clientId,id:e.attributes.id,url:e.attributes.url,attributes:e.attributes,fromSavedContent:Boolean(e.originalContent)})),[_]),w=function(e){const[t,n]=Object(ye.useState)([]),o=Object(Ie.useSelect)(n=>{if(null==e||!e.length)return t;const o=e.map(e=>e.attributes.id).filter(e=>void 0!==e);return 0===o.length?t:n(It.store).getMediaItems({include:o.join(","),per_page:-1})},[e]);return(null==o?void 0:o.length)!==(null==t?void 0:t.length)||null!=o&&o.some(e=>!t.find(t=>t.id===e.id))?(n(o),o):t}(_),E=br(k,w);Object(ye.useEffect)(()=>{null==E||E.forEach(e=>{v(e.clientId,{...S(!1,e.attributes),id:e.id,align:void 0})})},[E]);const C=function(e){const t=Object(Ie.useSelect)(t=>{if(!e||0===e.length)return;const n=t(It.store).getMedia;return e.map(e=>{const t=n(e.id);if(t)return{id:t.id,type:"image",url:t.source_url,mime:t.mime_type,alt:t.alt_text,link:t.link}})},[e]);if(t)return Object(Re.every)(t,e=>e&&e.url)?t:void 0}(b);Object(ye.useEffect)(()=>{b&&C&&(T(C),t({shortCodeTransforms:void 0}))},[b,C]);const x=dr(w,l,y);function S(e,t){if(e)return e.attributes;let o;return o=t.className&&""!==t.className?t.className:f?"is-style-"+f:void 0,{...rr(t,p),...cr(t,d),...ir(m,n),className:o,sizeSlug:p}}function B(e){var t;return hr.some(t=>{var n;return 0===(null===(n=e.type)||void 0===n?void 0:n.indexOf(t))})||0===(null===(t=e.url)||void 0===t?void 0:t.indexOf("blob:"))}function T(e){const t="[object FileList]"===Object.prototype.toString.call(e),n=t?Array.from(e).map(e=>e.url?e:rr({url:Object(ze.createBlobURL)(e)})):e;n.every(B)||(a.removeAllNotices(),a.createErrorNotice(Object(we.__)("If uploading to a gallery all files need to be image formats"),{id:"gallery-upload-invalid-file"}));const o=n.filter(e=>e.url||B(e)).map(e=>e.url?e:rr({url:Object(ze.createBlobURL)(e)})),l=o.reduce((e,t,n)=>(e[t.id]=n,e),{}),c=t?_:_.filter(e=>o.find(t=>t.id===e.attributes.id)),i=o.filter(e=>!c.find(t=>e.id===t.attributes.id)).map(e=>Object(je.createBlock)("core/image",{id:e.id,url:e.url,caption:e.caption,alt:e.alt}));h(r,Object(Re.concat)(c,i).sort((e,t)=>l[e.attributes.id]-l[t.attributes.id]))}Object(ye.useEffect)(()=>{var e,n,o,r,a,l;d||(g(),t({linkTo:(null===(e=window)||void 0===e||null===(n=e.wp)||void 0===n||null===(o=n.media)||void 0===o||null===(r=o.view)||void 0===r||null===(a=r.settings)||void 0===a||null===(l=a.defaultProps)||void 0===l?void 0:l.link)||"none"}))},[d]);const N=!!k.length,P=N&&k.some(e=>!!e.id),z=k.some(e=>{var t;return!e.id&&0===(null===(t=e.url)||void 0===t?void 0:t.indexOf("blob:"))}),I=Object(ye.createElement)(Ee.MediaPlaceholder,{addToGallery:P,handleUpload:!1,isAppender:N,disableMediaButtons:N&&!l||z,icon:!N&&or,labels:{title:!N&&Object(we.__)("Gallery"),instructions:!N&&vr},onSelect:T,accept:"image/*",allowedTypes:hr,multiple:!0,value:P?k:{},onError:function(e){a.removeAllNotices(),a.createErrorNotice(e)},notices:N?void 0:c}),M=Object(Ee.useBlockProps)({className:tt()(o,"has-nested-images")});if(!N)return Object(ye.createElement)(fe.View,M,I);const R=d&&"none"!==d;return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Gallery settings")},k.length>1&&Object(ye.createElement)(ke.RangeControl,Object(mt.a)({label:Object(we.__)("Columns"),value:s||(L=k.length,L?Math.min(3,L):3),onChange:function(e){t({columns:e})},min:1,max:Math.min(8,k.length)},Or,{required:!0})),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Crop images"),checked:!!u,onChange:function(){t({imageCrop:!u})},help:function(e){return e?Object(we.__)("Thumbnails are cropped to align."):Object(we.__)("Thumbnails are not cropped.")}}),Object(ye.createElement)(ke.SelectControl,{label:Object(we.__)("Link to"),value:d,onChange:function(e){t({linkTo:e});const n={},o=[];j(r).innerBlocks.forEach(t=>{o.push(t.clientId);const r=t.attributes.id?Object(Re.find)(w,{id:t.attributes.id}):null;n[t.clientId]=cr(r,e)}),v(o,n,!0);const a=[...gr].find(t=>t.value===e);O(Object(we.sprintf)(Object(we.__)("All gallery image links updated to: %s"),a.label),{id:"gallery-attributes-linkTo",type:"snackbar"})},options:gr,hideCancelButton:!0}),R&&Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Open in new tab"),checked:"_blank"===m,onChange:function(e){const n=e?"_blank":void 0;t({linkTarget:n});const o={},a=[];j(r).innerBlocks.forEach(e=>{a.push(e.clientId),o[e.clientId]=ir(n,e.attributes)}),v(a,o,!0);const l=e?Object(we.__)("All gallery images updated to open in new tab"):Object(we.__)("All gallery images updated to not open in new tab");O(l,{id:"gallery-attributes-openInNewTab",type:"snackbar"})}}),(null==x?void 0:x.length)>0&&Object(ye.createElement)(ke.SelectControl,{label:Object(we.__)("Image size"),value:p,options:x,onChange:function(e){t({sizeSlug:e});const n={},o=[];j(r).innerBlocks.forEach(t=>{o.push(t.clientId);const r=t.attributes.id?Object(Re.find)(w,{id:t.attributes.id}):null;n[t.clientId]=function(e,t){const n=Object(Re.get)(e,["media_details","sizes",t,"source_url"]);return n?{url:n,width:void 0,height:void 0,sizeSlug:t}:{}}(r,e)}),v(o,n,!0);const a=x.find(t=>t.value===e);O(Object(we.sprintf)(Object(we.__)("All gallery image sizes updated to: %s"),a.label),{id:"gallery-attributes-sizeSlug",type:"snackbar"})},hideCancelButton:!0}),ye.Platform.isWeb&&!x&&Object(ye.createElement)(ke.BaseControl,{className:"gallery-image-sizes"},Object(ye.createElement)(ke.BaseControl.VisualLabel,null,Object(we.__)("Image size")),Object(ye.createElement)(fe.View,{className:"gallery-image-sizes__loading"},Object(ye.createElement)(ke.Spinner,null),Object(we.__)("Loading options…"))))),c,Object(ye.createElement)(mr,Object(mt.a)({},e,{images:k,mediaPlaceholder:I,blockProps:M,insertBlocksAfter:i})));var L}));const yr=(e,t="large")=>{const n=Object(Re.pick)(e,["alt","id","link","caption"]);n.url=Object(Re.get)(e,["sizes",t,"url"])||Object(Re.get)(e,["media_details","sizes",t,"source_url"])||e.url;const o=Object(Re.get)(e,["sizes","full","url"])||Object(Re.get)(e,["media_details","sizes","full","source_url"]);return o&&(n.fullUrl=o),n};var fr=Object(ye.createElement)(fe.SVG,{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg"},Object(ye.createElement)(fe.Path,{d:"M19 3H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V5c0-1.1-.9-2-2-2zM5 4.5h14c.3 0 .5.2.5.5v8.4l-3-2.9c-.3-.3-.8-.3-1 0L11.9 14 9 12c-.3-.2-.6-.2-.8 0l-3.6 2.6V5c-.1-.3.1-.5.4-.5zm14 15H5c-.3 0-.5-.2-.5-.5v-2.4l4.1-3 3 1.9c.3.2.7.2.9-.1L16 12l3.5 3.4V19c0 .3-.2.5-.5.5z"})),_r=n("2gm7"),kr=n("1iEr"),wr=n("bWcr");class Er extends ye.Component{constructor(){super(...arguments),this.onSelectImage=this.onSelectImage.bind(this),this.onRemoveImage=this.onRemoveImage.bind(this),this.bindContainer=this.bindContainer.bind(this),this.onEdit=this.onEdit.bind(this),this.onSelectImageFromLibrary=this.onSelectImageFromLibrary.bind(this),this.onSelectCustomURL=this.onSelectCustomURL.bind(this),this.state={isEditing:!1}}bindContainer(e){this.container=e}onSelectImage(){this.props.isSelected||this.props.onSelect()}onRemoveImage(e){this.container===this.container.ownerDocument.activeElement&&this.props.isSelected&&-1!==[dt.BACKSPACE,dt.DELETE].indexOf(e.keyCode)&&(e.preventDefault(),this.props.onRemove())}onEdit(){this.setState({isEditing:!0})}componentDidUpdate(){const{image:e,url:t,__unstableMarkNextChangeAsNotPersistent:n}=this.props;e&&!t&&(n(),this.props.setAttributes({url:e.source_url,alt:e.alt_text}))}deselectOnBlur(){this.props.onDeselect()}onSelectImageFromLibrary(e){const{setAttributes:t,id:n,url:o,alt:r,caption:a,sizeSlug:l}=this.props;if(!e||!e.url)return;let c=yr(e,l);((e,t)=>!e&&Object(ze.isBlobURL)(t))(n,o)&&r&&(c=Object(Re.omit)(c,["alt"])),a&&!Object(Re.get)(c,["caption"])&&(c=Object(Re.omit)(c,["caption"])),t(c),this.setState({isEditing:!1})}onSelectCustomURL(e){const{setAttributes:t,url:n}=this.props;e!==n&&(t({url:e,id:void 0}),this.setState({isEditing:!1}))}render(){const{url:e,alt:t,id:n,linkTo:o,link:r,isFirstItem:a,isLastItem:l,isSelected:c,caption:i,onRemove:s,onMoveForward:u,onMoveBackward:m,setAttributes:d,"aria-label":b}=this.props,{isEditing:p}=this.state;let g;switch(o){case"file":g=e;break;case"post":g=r}const h=Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)("img",{src:e,alt:t,"data-id":n,onKeyDown:this.onRemoveImage,tabIndex:"0","aria-label":b,ref:this.bindContainer}),Object(ze.isBlobURL)(e)&&Object(ye.createElement)(ke.Spinner,null)),v=tt()({"is-selected":c,"is-transient":Object(ze.isBlobURL)(e)});return Object(ye.createElement)("figure",{className:v,onClick:this.onSelectImage,onFocus:this.onSelectImage},!p&&(g?Object(ye.createElement)("a",{href:g},h):h),p&&Object(ye.createElement)(Ee.MediaPlaceholder,{labels:{title:Object(we.__)("Edit gallery image")},icon:fr,onSelect:this.onSelectImageFromLibrary,onSelectURL:this.onSelectCustomURL,accept:"image/*",allowedTypes:["image"],value:{id:n,src:e}}),Object(ye.createElement)(ke.ButtonGroup,{className:"block-library-gallery-item__inline-menu is-left"},Object(ye.createElement)(ke.Button,{icon:_r.a,onClick:a?void 0:m,label:Object(we.__)("Move image backward"),"aria-disabled":a,disabled:!c}),Object(ye.createElement)(ke.Button,{icon:kr.a,onClick:l?void 0:u,label:Object(we.__)("Move image forward"),"aria-disabled":l,disabled:!c})),Object(ye.createElement)(ke.ButtonGroup,{className:"block-library-gallery-item__inline-menu is-right"},Object(ye.createElement)(ke.Button,{icon:Xn.a,onClick:this.onEdit,label:Object(we.__)("Replace image"),disabled:!c}),Object(ye.createElement)(ke.Button,{icon:wr.a,onClick:s,label:Object(we.__)("Remove image"),disabled:!c})),!p&&(c||i)&&Object(ye.createElement)(Ee.RichText,{tagName:"figcaption","aria-label":Object(we.__)("Image caption text"),placeholder:c?Object(we.__)("Add caption"):null,value:i,onChange:e=>d({caption:e}),inlineToolbar:!0}))}}var Cr=Object(nt.compose)([Object(Ie.withSelect)((e,t)=>{const{getMedia:n}=e(It.store),{id:o}=t;return{image:o?n(parseInt(o,10)):null}}),Object(Ie.withDispatch)(e=>{const{__unstableMarkNextChangeAsNotPersistent:t}=e(Ee.store);return{__unstableMarkNextChangeAsNotPersistent:t}})])(Er);function xr({isHidden:e,...t}){return e?Object(ye.createElement)(ke.VisuallyHidden,Object(mt.a)({as:Ee.RichText},t)):Object(ye.createElement)(Ee.RichText,t)}var Sr=e=>{const{attributes:t,isSelected:n,setAttributes:o,selectedImage:r,mediaPlaceholder:a,onMoveBackward:l,onMoveForward:c,onRemoveImage:i,onSelectImage:s,onDeselectImage:u,onSetImageAttributes:m,insertBlocksAfter:d,blockProps:b}=e,{align:p,columns:g=er(t),caption:h,imageCrop:v,images:O}=t;return Object(ye.createElement)("figure",Object(mt.a)({},b,{className:tt()(b.className,{["align"+p]:p,["columns-"+g]:g,"is-cropped":v})}),Object(ye.createElement)("ul",{className:"blocks-gallery-grid"},O.map((e,o)=>{const a=Object(we.sprintf)(Object(we.__)("image %1$d of %2$d in gallery"),o+1,O.length);return Object(ye.createElement)("li",{className:"blocks-gallery-item",key:e.id?`${e.id}-${o}`:e.url},Object(ye.createElement)(Cr,{url:e.url,alt:e.alt,id:e.id,isFirstItem:0===o,isLastItem:o+1===O.length,isSelected:n&&r===o,onMoveBackward:l(o),onMoveForward:c(o),onRemove:i(o),onSelect:s(o),onDeselect:u(o),setAttributes:e=>m(o,e),caption:e.caption,"aria-label":a,sizeSlug:t.sizeSlug}))})),a,Object(ye.createElement)(xr,{isHidden:!n&&Ee.RichText.isEmpty(h),tagName:"figcaption",className:"blocks-gallery-caption","aria-label":Object(we.__)("Gallery caption text"),placeholder:Object(we.__)("Write gallery caption…"),value:h,onChange:e=>o({caption:e}),inlineToolbar:!0,__unstableOnSplitAtEnd:()=>d(Object(je.createBlock)("core/paragraph"))}))};const Br=({clientId:e,getBlock:t,replaceBlocks:n})=>()=>{let o;const{attributes:{sizeSlug:r,linkTo:a,images:l,caption:c}}=t(e);switch(a){case"post":o="post";break;case"file":o="file";break;default:o="none"}const i=l.map(e=>Object(je.createBlock)("core/image",{id:parseInt(e.id,10),url:e.url,alt:e.alt,caption:e.caption,linkDestination:o}));n(e,Object(je.createBlock)("core/gallery",{sizeSlug:r,linkTo:o,caption:c},i))};function Tr({onClose:e,clientId:t}){const{getBlock:n}=Object(Ie.useSelect)(Ee.store),{replaceBlocks:o}=Object(Ie.useDispatch)(Ee.store);return Object(ye.createElement)(ke.Modal,{closeLabel:Object(we.__)("Close"),onRequestClose:e,title:Object(we.__)("Update gallery"),className:"wp-block-update-gallery-modal",aria:{describedby:"wp-block-update-gallery-modal__description"}},Object(ye.createElement)("p",{id:"wp-block-update-gallery-modal__description"},Object(we.__)("Updating to the new format adds the ability to use custom links or styles on individual images in the gallery, and makes it easier to add or move them around.")),Object(ye.createElement)("div",{className:"wp-block-update-gallery-modal-buttons"},Object(ye.createElement)(ke.Button,{isTertiary:!0,onClick:e},Object(we.__)("Cancel")),Object(ye.createElement)(ke.Button,{isPrimary:!0,onClick:Br({replaceBlocks:o,getBlock:n,clientId:t,createBlock:je.createBlock})},Object(we.__)("Update"))))}const Nr=[{value:"post",label:Object(we.__)("Attachment Page")},{value:"file",label:Object(we.__)("Media File")},{value:"none",label:Object(we.__)("None")}],Pr=["image"],zr=ye.Platform.select({web:Object(we.__)("Drag images, upload new ones or select files from your library."),native:Object(we.__)("ADD MEDIA")}),Ir=ye.Platform.select({web:{},native:{type:"stepper"}});var Mr=Object(nt.compose)([ke.withNotices,Object(nr.withViewportMatch)({isNarrow:"< small"})])((function(e){const{attributes:t,clientId:n,isSelected:o,noticeUI:r,noticeOperations:a,onFocus:l}=e,{columns:c=er(t),imageCrop:i,images:s,linkTo:u,sizeSlug:m}=t,[d,b]=Object(ye.useState)(),[p,g]=Object(ye.useState)(),{__unstableMarkNextChangeAsNotPersistent:h}=Object(Ie.useDispatch)(Ee.store),{imageSizes:v,mediaUpload:O,getMedia:j,wasBlockJustInserted:y,__unstableGalleryWithImageBlocks:f}=Object(Ie.useSelect)(e=>{const t=e(Ee.store).getSettings();return{__unstableGalleryWithImageBlocks:t.__unstableGalleryWithImageBlocks,imageSizes:t.imageSizes,mediaUpload:t.mediaUpload,getMedia:e(It.store).getMedia,wasBlockJustInserted:e(Ee.store).wasBlockJustInserted(n,"inserter_menu")}}),_=Object(ye.useMemo)(()=>o?Object(Re.reduce)(t.ids,(e,t)=>{if(!t)return e;const n=j(t),o=Object(Re.reduce)(v,(e,t)=>{const o=Object(Re.get)(n,["sizes",t.slug,"url"]),r=Object(Re.get)(n,["media_details","sizes",t.slug,"source_url"]);return{...e,[t.slug]:o||r}},{});return{...e,[parseInt(t,10)]:o}},{}):{},[o,t.ids,v]);function k(t){if(t.ids)throw new Error('The "ids" attribute should not be changed directly. It is managed automatically when "images" attribute changes');t.images&&(t={...t,ids:Object(Re.map)(t.images,({id:e})=>parseInt(e,10))}),e.setAttributes(t)}function w(e,t){const n=[...s];n.splice(t,1,s[e]),n.splice(e,1,s[t]),b(t),k({images:n})}function E(e){const t=Object(Re.toString)(e.id),n=Object(Re.find)(s,{id:t}),o=n?n.caption:e.caption;if(!p)return o;const r=Object(Re.find)(p,{id:t});return r&&r.caption!==e.caption?e.caption:o}function C(e){g(e.map(e=>({id:Object(Re.toString)(e.id),caption:e.caption}))),k({images:e.map(e=>({...yr(e,m),caption:E(e),id:Object(Re.toString)(e.id)})),columns:t.columns?Math.min(e.length,t.columns):t.columns})}Object(ye.useEffect)(()=>{if("web"===ye.Platform.OS&&s&&s.length>0&&Object(Re.every)(s,({url:e})=>Object(ze.isBlobURL)(e))){const e=Object(Re.map)(s,({url:e})=>Object(ze.getBlobByURL)(e));Object(Re.forEach)(s,({url:e})=>Object(ze.revokeBlobURL)(e)),O({filesList:e,onFileChange:C,allowedTypes:["image"]})}},[]),Object(ye.useEffect)(()=>{o||b()},[o]),Object(ye.useEffect)(()=>{var e,t,n,o,r,a;u||(h(),k({linkTo:(null===(e=window)||void 0===e||null===(t=e.wp)||void 0===t||null===(n=t.media)||void 0===n||null===(o=n.view)||void 0===o||null===(r=o.settings)||void 0===r||null===(a=r.defaultProps)||void 0===a?void 0:a.link)||"none"}))},[u]);const x=!!s.length,S=x&&s.some(e=>!!e.id),B=Object(ye.createElement)(Ee.MediaPlaceholder,{addToGallery:S,isAppender:x,disableMediaButtons:x&&!o,icon:!x&&or,labels:{title:!x&&Object(we.__)("Gallery"),instructions:!x&&zr},onSelect:C,accept:"image/*",allowedTypes:Pr,multiple:!0,value:S?s:{},onError:function(e){a.removeAllNotices(),a.createErrorNotice(e)},notices:x?void 0:r,onFocus:l,autoOpenMediaUpload:!x&&o&&y}),[T,N]=Object(ye.useState)(!1),P=Object(Ee.useBlockProps)();if(!x)return Object(ye.createElement)(fe.View,P,B);const z=Object(Re.map)(Object(Re.filter)(v,({slug:e})=>Object(Re.some)(_,t=>t[e])),({name:e,slug:t})=>({value:t,label:e})),I=x&&!Object(Re.isEmpty)(z);return Object(ye.createElement)(ye.Fragment,null,Object(ye.createElement)(Ee.InspectorControls,null,Object(ye.createElement)(ke.PanelBody,{title:Object(we.__)("Gallery settings")},s.length>1&&Object(ye.createElement)(ke.RangeControl,Object(mt.a)({label:Object(we.__)("Columns"),value:c,onChange:function(e){k({columns:e})},min:1,max:Math.min(8,s.length)},Ir,{required:!0})),Object(ye.createElement)(ke.ToggleControl,{label:Object(we.__)("Crop images"),checked:!!i,onChange:function(){k({imageCrop:!i})},help:function(e){return e?Object(we.__)("Thumbnails are cropped to align."):Object(we.__)("Thumbnails are not cropped.")}}),Object(ye.createElement)(ke.SelectControl,{label:Object(we.__)("Link to"),value:u,onChange:function(e){k({linkTo:e})},options:Nr,hideCancelButton:!0}),I&&Object(ye.createElement)(ke.SelectControl,{label:Object(we.__)("Image size"),value:m,options:z,onChange:function(e){k({images:Object(Re.map)(s,t=>{if(!t.id)return t;const n=Object(Re.get)(_,[parseInt(t.id,10),e]);return{...t,...n&&{url:n}}}),sizeSlug:e})},hideCancelButton:!0}))),ye.Platform.isWeb&&f&&Object(ye.createElement)(Ee.BlockControls,{group:"other"},Object(ye.createElement)(ke.ToolbarButton,{onClick:()=>N(!0),title:Object(we.__)("Update"),label:Object(we.__)("Update to the new gallery format")},Object(we.__)("Update"))),ye.Platform.isWeb&&T&&Object(ye.createElement)(Tr,{onClose:()=>N(!1),clientId:n}),r,Object(ye.createElement)(Sr,Object(mt.a)({},e,{selectedImage:d,mediaPlaceholder:B,onMoveBackward:function(e){return()=>{0!==e&&w(e,e-1)}},onMoveForward:function(e){return()=>{e!==s.length-1&&w(e,e+1)}},onRemoveImage:function(e){return()=>{const n=Object(Re.filter)(s,(t,n)=>e!==n);b(),k({images:n,columns:t.columns?Math.min(n.length,t.columns):t.columns})}},onSelectImage:function(e){return()=>{b(e)}},onDeselectImage:function(){return()=>{b()}},onSetImageAttributes:function(e,t){s[e]&&k({images:[...s.slice(0,e),{...s[e],...t},...s.slice(e+1)]})},blockProps:P,onFocusGalleryCaption:function(){b()}})))}));var Rr=n("g56x");const Lr=e=>e?e.split(",").map(e=>parseInt(e,10)):[];Object(Rr.addFilter)("blocks.switchToBlockType.transformedBlock","core/gallery/update-third-party-transform-to",(function(e){var t;if(Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks&&"core/gallery"===e.name&&(null===(t=e.attributes)||void 0===t?void 0:t.images.length)>0){const t=e.attributes.images.map(({url:t,id:n,alt:o})=>Object(je.createBlock)("core/image",{url:t,id:n?parseInt(n,10):null,alt:o,sizeSlug:e.attributes.sizeSlug,linkDestination:e.attributes.linkDestination}));delete e.attributes.ids,delete e.attributes.images,e.innerBlocks=t}return e})),Object(Rr.addFilter)("blocks.switchToBlockType.transformedBlock","core/gallery/update-third-party-transform-from",(function(e,t){const n=(Array.isArray(t)?t:[t]).find(t=>{var n;return"core/gallery"===t.name&&t.innerBlocks.length>0&&!(null!==(n=t.attributes.images)&&void 0!==n&&n.length)>0&&!e.name.includes("core/")});if(n){const e=n.innerBlocks.map(({attributes:{url:e,id:t,alt:n}})=>({url:e,id:t?parseInt(t,10):null,alt:n})),t=e.map(({id:e})=>e);n.attributes.images=e,n.attributes.ids=t}return e}));var Vr={from:[{type:"block",isMultiBlock:!0,blocks:["core/image"],transform:e=>{let{align:t,sizeSlug:n}=e[0];t=Object(Re.every)(e,["align",t])?t:void 0,n=Object(Re.every)(e,["sizeSlug",n])?n:void 0;const o=Object(Re.filter)(e,({url:e})=>e);if(Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks){const e=o.map(e=>Object(je.createBlock)("core/image",e));return Object(je.createBlock)("core/gallery",{align:t,sizeSlug:n},e)}return Object(je.createBlock)("core/gallery",{images:o.map(({id:e,url:t,alt:n,caption:o})=>({id:Object(Re.toString)(e),url:t,alt:n,caption:o})),ids:o.map(({id:e})=>parseInt(e,10)),align:t,sizeSlug:n})}},{type:"shortcode",tag:"gallery",attributes:{images:{type:"array",shortcode:({named:{ids:e}})=>{if(!Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks)return Lr(e).map(e=>({id:Object(Re.toString)(e)}))}},ids:{type:"array",shortcode:({named:{ids:e}})=>{if(!Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks)return Lr(e)}},shortCodeTransforms:{type:"array",shortcode:({named:{ids:e}})=>{if(Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks)return Lr(e).map(e=>({id:parseInt(e)}))}},columns:{type:"number",shortcode:({named:{columns:e="3"}})=>parseInt(e,10)},linkTo:{type:"string",shortcode:({named:{link:e}})=>{if(!Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks)switch(e){case"post":return"post";case"file":return"file";default:return"post"}switch(e){case"post":return"attachment";case"file":return"media";default:return"none"}}}},isMatch:({named:e})=>void 0!==e.ids},{type:"files",priority:1,isMatch:e=>1!==e.length&&Object(Re.every)(e,e=>0===e.type.indexOf("image/")),transform(e){if(Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks){const t=e.map(e=>Object(je.createBlock)("core/image",{url:Object(ze.createBlobURL)(e)}));return Object(je.createBlock)("core/gallery",{},t)}return Object(je.createBlock)("core/gallery",{images:e.map(e=>rr({url:Object(ze.createBlobURL)(e)}))})}}],to:[{type:"block",blocks:["core/image"],transform:({align:e,images:t,ids:n,sizeSlug:o},r)=>Object(Ie.select)(Ee.store).getSettings().__unstableGalleryWithImageBlocks?r.length>0?r.map(({attributes:{id:t,url:n,alt:o,caption:r,imageSizeSlug:a}})=>Object(je.createBlock)("core/image",{id:t,url:n,alt:o,caption:r,sizeSlug:a,align:e})):Object(je.createBlock)("core/image",{align:e}):t.length>0?t.map(({url:t,alt:r,caption:a},l)=>Object(je.createBlock)("core/image",{id:n[l],url:t,alt:r,caption:a,align:e,sizeSlug:o})):Object(je.createBlock)("core/image",{align:e})}]};const Ar={apiVersion:2,name:"core/gallery",title:"Gallery",category:"media",description:"Display multiple images in a rich gallery.",keywords:["images","photos"],textdomain:"default",attributes:{images:{type:"array",default:[],source:"query",selector:".blocks-gallery-item",query:{url:{type:"string",source:"attribute",selector:"img",attribute:"src"},fullUrl:{type:"string",source:"attribute",selector:"img",attribute:"data-full-url"},link:{type:"string",source:"attribute",selector:"img",attribute:"data-link"},alt:{type:"string",source:"attribute",selector:"img",attribute:"alt",default:""},id:{type:"string",source:"attribute",selector:"img",attribute:"data-id"},caption:{type:"string",source:"html",selector:".blocks-gallery-item__caption"}}},ids:{type:"array",items:{type:"number"},default:[]},shortCodeTransforms:{type:"array",default:[],items:{type:"object"}},columns:{type:"number",minimum:1,maximum:8},caption:{type:"string",source:"html",selector:".blocks-gallery-caption"},imageCrop:{type:"boolean",default:!0},fixedHeight:{type:"boolean",default:!0},linkTarget:{type:"string"},linkTo:{type:"string"},sizeSlug:{type:"string",default:"large"},allowResize:{type:"boolean",default:!1}},providesContext:{allowResize:"allowResize",imageCrop:"imageCrop",fixedHeight:"fixedHeight"},supports:{anchor:!0,align:!0},editorStyle:"wp-block-gallery-editor",style:"wp-block-gallery"},{name:Hr}=Ar,Fr={icon:Xo,example:{attributes:{columns:2},innerBlocks:[{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Glacial_lakes%2C_Bhutan.jpg"}},{name:"core/image",attributes:{url:"https://s.w.org/images/core/5.3/Sediment_off_the_Yucatan_Peninsula.jpg"}}]},transforms:Vr,edit:function(e){var t,n;const{attributes:o,clientId:r}=e,a=Object(Ie.useSelect)(e=>{var t;return null===(t=e(Ee.store).getBlock(r))||void 0===t?void 0:t.innerBlocks},[r]),l=Object(Ie.useSelect)(e=>e(Ee.store).getSettings().__unstableGalleryWithImageBlocks,[]),c=!(null==a||!a.length);return 0<(null==o||null===(t=o.ids)||void 0===t?void 0:t.length)||0<(null==o||null===(n=o.images)||void 0===n?void 0:n.length)||!c&&!l?Object(ye.createElement)(Mr,e):Object(ye.createElement)(jr,e)},save:function({attributes:e}){var t,n;if((null==e||null===(t=e.ids)||void 0===t?void 0:t.length)>0||(null==e||null===(n=e.images)||void 0===n?void 0:n.length)>0)return function({attributes:e}){const{images:t,columns:n=er(e),imageCrop:o,caption:r,linkTo:a}=e,l=`columns-${n} ${o?"is-cropped":""}`;return Object(ye.createElement)("figure",Ee.useBlockProps.save({className:l}),Object(ye.createElement)("ul",{className:"blocks-gallery-grid"},t.map(e=>{let t;switch(a){case"file":t=e.fullUrl||e.url;break;case"post":t=e.link}const n=Object(ye.createElement)("img",{src:e.url,alt:e.alt,"data-id":e.id,"data-full-url":e.fullUrl,"data-link":e.link,className:e.id?"wp-image-"+e.id:null});return Object(ye.createElement)("li",{key:e.id||e.url,className:"blocks-gallery-item"},Object(ye.createElement)("figure",null,t?Object(ye.createElement)("a",{href:t},n):n,!Ee.RichText.isEmpty(e.caption)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-item__caption",value:e.caption})))})),!Ee.RichText.isEmpty(r)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:r}))}({attributes:e});const{caption:o,columns:r,imageCrop:a}=e,l=tt()("has-nested-images",{["columns-"+r]:void 0!==r,"columns-default":void 0===r,"is-cropped":a}),c=Ee.useBlockProps.save({className:l}),i=Ee.useInnerBlocksProps.save(c);return Object(ye.createElement)("figure",i,i.children,!Ee.RichText.isEmpty(o)&&Object(ye.createElement)(Ee.RichText.Content,{tagName:"figcaption",className:"blocks-gallery-caption",value:o}))},deprecated:tr};var Dr=n("u6za");const Gr=e=>{if(e.tagName||(e={...e,tagName:"div"}),!e.customTextColor&&!e.customBackgroundColor)return e;const t={color:{}};return e.customTextColor&&(t.color.text=e.customTextColor),e.customBackgroundColor&&(t.color.background=e.customBackgroundColor),{...Object(Re.omit)(e,["customTextColor","customBackgroundColor"]),style:t}};var qr=[{attributes:{tagName:{type:"string",default:"div"},templateLock:{type:"string"}},supports:{align:["wide","full"],anchor:!0,color:{gradients:!0,link:!0},spacing:{padding:!0},__experimentalBorder:{radius:!0}},save({attributes:e}){const{tagName:t}=e;return Object(ye.createElement)(t,Ee.useBlockProps.save(),Object(ye.createElement)("div",{className:"wp-block-group__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))}},{attributes:{backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},textColor:{type:"string"},customTextColor:{type:"string"}},supports:{align:["wide","full"],anchor:!0,html:!1},migrate:Gr,save({attributes:e}){const{backgroundColor:t,customBackgroundColor:n,textColor:o,customTextColor:r}=e,a=Object(Ee.getColorClassName)("background-color",t),l=Object(Ee.getColorClassName)("color",o),c=tt()(a,l,{"has-text-color":o||r,"has-background":t||n}),i={backgroundColor:a?void 0:n,color:l?void 0:r};return Object(ye.createElement)("div",{className:c,style:i},Object(ye.createElement)("div",{className:"wp-block-group__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))}},{attributes:{backgroundColor:{type:"string"},customBackgroundColor:{type:"string"},textColor:{type:"string"},customTextColor:{type:"string"}},migrate:Gr,supports:{align:["wide","full"],anchor:!0,html:!1},save({attributes:e}){const{backgroundColor:t,customBackgroundColor:n,textColor:o,customTextColor:r}=e,a=Object(Ee.getColorClassName)("background-color",t),l=Object(Ee.getColorClassName)("color",o),c=tt()(a,{"has-text-color":o||r,"has-background":t||n}),i={backgroundColor:a?void 0:n,color:l?void 0:r};return Object(ye.createElement)("div",{className:c,style:i},Object(ye.createElement)("div",{className:"wp-block-group__inner-container"},Object(ye.createElement)(Ee.InnerBlocks.Content,null)))}},{attributes:{backgroundColor:{type:"string"},customBackgroundColor:{type:"string"}},supports:{align:["wide","full"],anchor:!0,html:!1},migrate:Gr,save({attributes:e}){const{backgroundColor:t,customBackgroundColor:n}=e,o=Object(Ee.getColorClassName)("background-color",t),r=tt()(o,{"has-background":t||n}),a={backgroundColor:o?void 0:n};return Object(ye.createElement)("div",{className:r,style:a},Object(ye.createElement)(Ee.InnerBlocks.Content,null))}}];const Ur={header:Object(we.__)("The
element should represent introductory content, typically a group of introductory or navigational aids."),main:Object(we.__)("The
element should be used for the primary content of your document only. "),section:Object(we.__)("The
element should represent a standalone portion of the document that can't be better represented by another element."),article:Object(we.__)("The
element should represent a self contained, syndicatable portion of the document."),aside:Object(we.__)("The