!function(){var e={649:function(e){e.exports=function(e,t){var o,n,r=0;function l(){var l,a,i=o,c=arguments.length;e:for(;i;){if(i.args.length===arguments.length){for(a=0;a>>32-t},rotr:function(e,t){return e<<32-t|e>>>t},endian:function(e){if(e.constructor==Number)return 16711935&o.rotl(e,8)|4278255360&o.rotl(e,24);for(var t=0;t0;e--)t.push(Math.floor(256*Math.random()));return t},bytesToWords:function(e){for(var t=[],o=0,n=0;o>>5]|=e[o]<<24-n%32;return t},wordsToBytes:function(e){for(var t=[],o=0;o<32*e.length;o+=8)t.push(e[o>>>5]>>>24-o%32&255);return t},bytesToHex:function(e){for(var t=[],o=0;o>>4).toString(16)),t.push((15&e[o]).toString(16));return t.join("")},hexToBytes:function(e){for(var t=[],o=0;o>>6*(3-l)&63)):o.push("=");return o.join("")},base64ToBytes:function(e){e=e.replace(/[^A-Z0-9+\/]/gi,"");for(var o=[],n=0,r=0;n>>6-2*r);return o}},e.exports=o},960:function(e,t){"use strict";var o;Object.defineProperty(t,"__esModule",{value:!0}),t.Doctype=t.CDATA=t.Tag=t.Style=t.Script=t.Comment=t.Directive=t.Text=t.Root=t.isTag=t.ElementType=void 0,function(e){e.Root="root",e.Text="text",e.Directive="directive",e.Comment="comment",e.Script="script",e.Style="style",e.Tag="tag",e.CDATA="cdata",e.Doctype="doctype"}(o=t.ElementType||(t.ElementType={})),t.isTag=function(e){return e.type===o.Tag||e.type===o.Script||e.type===o.Style},t.Root=o.Root,t.Text=o.Text,t.Directive=o.Directive,t.Comment=o.Comment,t.Script=o.Script,t.Style=o.Style,t.Tag=o.Tag,t.CDATA=o.CDATA,t.Doctype=o.Doctype},915:function(e,t,o){"use strict";var n=this&&this.__createBinding||(Object.create?function(e,t,o,n){void 0===n&&(n=o);var r=Object.getOwnPropertyDescriptor(t,o);r&&!("get"in r?!t.__esModule:r.writable||r.configurable)||(r={enumerable:!0,get:function(){return t[o]}}),Object.defineProperty(e,n,r)}:function(e,t,o,n){void 0===n&&(n=o),e[n]=t[o]}),r=this&&this.__exportStar||function(e,t){for(var o in e)"default"===o||Object.prototype.hasOwnProperty.call(t,o)||n(t,e,o)};Object.defineProperty(t,"__esModule",{value:!0}),t.DomHandler=void 0;var l=o(960),a=o(790);r(o(790),t);var i={withStartIndices:!1,withEndIndices:!1,xmlMode:!1},c=function(){function e(e,t,o){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null,"function"==typeof t&&(o=t,t=i),"object"==typeof e&&(t=e,e=void 0),this.callback=null!=e?e:null,this.options=null!=t?t:i,this.elementCB=null!=o?o:null}return e.prototype.onparserinit=function(e){this.parser=e},e.prototype.onreset=function(){this.dom=[],this.root=new a.Document(this.dom),this.done=!1,this.tagStack=[this.root],this.lastNode=null,this.parser=null},e.prototype.onend=function(){this.done||(this.done=!0,this.parser=null,this.handleCallback(null))},e.prototype.onerror=function(e){this.handleCallback(e)},e.prototype.onclosetag=function(){this.lastNode=null;var e=this.tagStack.pop();this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),this.elementCB&&this.elementCB(e)},e.prototype.onopentag=function(e,t){var o=this.options.xmlMode?l.ElementType.Tag:void 0,n=new a.Element(e,t,void 0,o);this.addNode(n),this.tagStack.push(n)},e.prototype.ontext=function(e){var t=this.lastNode;if(t&&t.type===l.ElementType.Text)t.data+=e,this.options.withEndIndices&&(t.endIndex=this.parser.endIndex);else{var o=new a.Text(e);this.addNode(o),this.lastNode=o}},e.prototype.oncomment=function(e){if(this.lastNode&&this.lastNode.type===l.ElementType.Comment)this.lastNode.data+=e;else{var t=new a.Comment(e);this.addNode(t),this.lastNode=t}},e.prototype.oncommentend=function(){this.lastNode=null},e.prototype.oncdatastart=function(){var e=new a.Text(""),t=new a.CDATA([e]);this.addNode(t),e.parent=t,this.lastNode=e},e.prototype.oncdataend=function(){this.lastNode=null},e.prototype.onprocessinginstruction=function(e,t){var o=new a.ProcessingInstruction(e,t);this.addNode(o)},e.prototype.handleCallback=function(e){if("function"==typeof this.callback)this.callback(e,this.dom);else if(e)throw e},e.prototype.addNode=function(e){var t=this.tagStack[this.tagStack.length-1],o=t.children[t.children.length-1];this.options.withStartIndices&&(e.startIndex=this.parser.startIndex),this.options.withEndIndices&&(e.endIndex=this.parser.endIndex),t.children.push(e),o&&(e.prev=o,o.next=e),e.parent=t,this.lastNode=null},e}();t.DomHandler=c,t.default=c},790:function(e,t,o){"use strict";var n,r=this&&this.__extends||(n=function(e,t){return n=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var o in t)Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o])},n(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function o(){this.constructor=e}n(e,t),e.prototype=null===t?Object.create(t):(o.prototype=t.prototype,new o)}),l=this&&this.__assign||function(){return l=Object.assign||function(e){for(var t,o=1,n=arguments.length;o0?this.children[this.children.length-1]:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"childNodes",{get:function(){return this.children},set:function(e){this.children=e},enumerable:!1,configurable:!0}),t}(i);t.NodeWithChildren=d;var m=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=a.ElementType.CDATA,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 4},enumerable:!1,configurable:!0}),t}(d);t.CDATA=m;var f=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.type=a.ElementType.Root,t}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 9},enumerable:!1,configurable:!0}),t}(d);t.Document=f;var b=function(e){function t(t,o,n,r){void 0===n&&(n=[]),void 0===r&&(r="script"===t?a.ElementType.Script:"style"===t?a.ElementType.Style:a.ElementType.Tag);var l=e.call(this,n)||this;return l.name=t,l.attribs=o,l.type=r,l}return r(t,e),Object.defineProperty(t.prototype,"nodeType",{get:function(){return 1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tagName",{get:function(){return this.name},set:function(e){this.name=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"attributes",{get:function(){var e=this;return Object.keys(this.attribs).map((function(t){var o,n;return{name:t,value:e.attribs[t],namespace:null===(o=e["x-attribsNamespace"])||void 0===o?void 0:o[t],prefix:null===(n=e["x-attribsPrefix"])||void 0===n?void 0:n[t]}}))},enumerable:!1,configurable:!0}),t}(d);function y(e){return(0,a.isTag)(e)}function h(e){return e.type===a.ElementType.CDATA}function v(e){return e.type===a.ElementType.Text}function g(e){return e.type===a.ElementType.Comment}function _(e){return e.type===a.ElementType.Directive}function k(e){return e.type===a.ElementType.Root}function w(e,t){var o;if(void 0===t&&(t=!1),v(e))o=new s(e.data);else if(g(e))o=new u(e.data);else if(y(e)){var n=t?O(e.children):[],r=new b(e.name,l({},e.attribs),n);n.forEach((function(e){return e.parent=r})),null!=e.namespace&&(r.namespace=e.namespace),e["x-attribsNamespace"]&&(r["x-attribsNamespace"]=l({},e["x-attribsNamespace"])),e["x-attribsPrefix"]&&(r["x-attribsPrefix"]=l({},e["x-attribsPrefix"])),o=r}else if(h(e)){n=t?O(e.children):[];var a=new m(n);n.forEach((function(e){return e.parent=a})),o=a}else if(k(e)){n=t?O(e.children):[];var i=new f(n);n.forEach((function(e){return e.parent=i})),e["x-mode"]&&(i["x-mode"]=e["x-mode"]),o=i}else{if(!_(e))throw new Error("Not implemented yet: ".concat(e.type));var c=new p(e.name,e.data);null!=e["x-name"]&&(c["x-name"]=e["x-name"],c["x-publicId"]=e["x-publicId"],c["x-systemId"]=e["x-systemId"]),o=c}return o.startIndex=e.startIndex,o.endIndex=e.endIndex,null!=e.sourceCodeLocation&&(o.sourceCodeLocation=e.sourceCodeLocation),o}function O(e){for(var t=e.map((function(e){return w(e,!0)})),o=1;o/i,i=//i,c=function(e,t){throw new Error("This browser does not support `document.implementation.createHTMLDocument`")},s=function(e,t){throw new Error("This browser does not support `DOMParser.prototype.parseFromString`")},u="object"==typeof window&&window.DOMParser;if("function"==typeof u){var p=new u;c=s=function(e,t){return t&&(e="<".concat(t,">").concat(e,"")),p.parseFromString(e,"text/html")}}if("object"==typeof document&&document.implementation){var d=document.implementation.createHTMLDocument();c=function(e,t){if(t){var o=d.documentElement.querySelector(t);return o&&(o.innerHTML=e),d}return d.documentElement.innerHTML=e,d}}var m,f="object"==typeof document&&document.createElement("template");f&&f.content&&(m=function(e){return f.innerHTML=e,f.content.childNodes})},152:function(e,t,o){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];var t=e.match(a),o=t?t[1]:void 0;return(0,l.formatDOM)((0,r.default)(e),null,o)};var r=n(o(276)),l=o(507),a=/<(![a-zA-Z\s]+)>/},507:function(e,t,o){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.formatAttributes=l,t.formatDOM=function e(t,o,r){void 0===o&&(o=null);for(var i,c=[],s=0,u=t.length;s1&&(h=p(h,{key:h.key||b})),n.push(s(h,y,b));continue}}if("text"!==y.type){var v=y,g={};c(v)?((0,a.setStyleProp)(v.attribs.style,v.attribs),g=v.attribs):v.attribs&&(g=(0,l.default)(v.attribs,v.name));var _=void 0;switch(y.type){case"script":case"style":y.children[0]&&(g.dangerouslySetInnerHTML={__html:y.children[0].data});break;case"tag":"textarea"===y.name&&y.children[0]?g.defaultValue=y.children[0].data:y.children&&y.children.length&&(_=e(y.children,o));break;default:continue}f>1&&(g.key=b),n.push(s(d(y.name,g,_),y,b))}else{var k=!y.data.trim().length;if(k&&y.parent&&!(0,a.canTextBeChildOfNode)(y.parent))continue;if(o.trim&&k)continue;n.push(s(y.data,y,b))}}return 1===n.length?n[0]:n};var r=o(313),l=n(o(484)),a=o(606),i={cloneElement:r.cloneElement,createElement:r.createElement,isValidElement:r.isValidElement};function c(e){return a.PRESERVE_CUSTOM_ATTRIBUTES&&"tag"===e.type&&(0,a.isCustomComponent)(e.name,e.attribs)}},426:function(e,t,o){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.htmlToDOM=t.domToReact=t.attributesToProps=t.Text=t.ProcessingInstruction=t.Element=t.Comment=void 0,t.default=function(e,t){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];return(0,a.default)((0,r.default)(e,(null==t?void 0:t.htmlparser2)||c),t)};var r=n(o(152));t.htmlToDOM=r.default;var l=n(o(484));t.attributesToProps=l.default;var a=n(o(670));t.domToReact=a.default;var i=o(915);Object.defineProperty(t,"Comment",{enumerable:!0,get:function(){return i.Comment}}),Object.defineProperty(t,"Element",{enumerable:!0,get:function(){return i.Element}}),Object.defineProperty(t,"ProcessingInstruction",{enumerable:!0,get:function(){return i.ProcessingInstruction}}),Object.defineProperty(t,"Text",{enumerable:!0,get:function(){return i.Text}});var c={lowerCaseAttributeNames:!1}},606:function(e,t,o){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.returnFirstArg=t.canTextBeChildOfNode=t.ELEMENTS_WITH_NO_TEXT_CHILDREN=t.PRESERVE_CUSTOM_ATTRIBUTES=void 0,t.isCustomComponent=function(e,t){if(!e.includes("-"))return Boolean(t&&"string"==typeof t.is);if(a.has(e))return!1;return!0},t.setStyleProp=function(e,t){if("string"!=typeof e)return;if(!e.trim())return void(t.style={});try{t.style=(0,l.default)(e,i)}catch(e){t.style={}}};var r=o(313),l=n(o(476)),a=new Set(["annotation-xml","color-profile","font-face","font-face-src","font-face-uri","font-face-format","font-face-name","missing-glyph"]);var i={reactCompat:!0};t.PRESERVE_CUSTOM_ATTRIBUTES=Number(r.version.split(".")[0])>=16,t.ELEMENTS_WITH_NO_TEXT_CHILDREN=new Set(["tr","tbody","thead","tfoot","colgroup","table","head","html","frameset"]);t.canTextBeChildOfNode=function(e){return!t.ELEMENTS_WITH_NO_TEXT_CHILDREN.has(e.name)};t.returnFirstArg=function(e){return e}},139:function(e){var t=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,o=/\n/g,n=/^\s*/,r=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,l=/^:\s*/,a=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,i=/^[;\s]*/,c=/^\s+|\s+$/g,s="";function u(e){return e?e.replace(c,s):s}e.exports=function(e,c){if("string"!=typeof e)throw new TypeError("First argument must be a string");if(!e)return[];c=c||{};var p=1,d=1;function m(e){var t=e.match(o);t&&(p+=t.length);var n=e.lastIndexOf("\n");d=~n?e.length-n:d+e.length}function f(){var e={line:p,column:d};return function(t){return t.position=new b(e),g(),t}}function b(e){this.start=e,this.end={line:p,column:d},this.source=c.source}b.prototype.content=e;var y=[];function h(t){var o=new Error(c.source+":"+p+":"+d+": "+t);if(o.reason=t,o.filename=c.source,o.line=p,o.column=d,o.source=e,!c.silent)throw o;y.push(o)}function v(t){var o=t.exec(e);if(o){var n=o[0];return m(n),e=e.slice(n.length),o}}function g(){v(n)}function _(e){var t;for(e=e||[];t=k();)!1!==t&&e.push(t);return e}function k(){var t=f();if("/"==e.charAt(0)&&"*"==e.charAt(1)){for(var o=2;s!=e.charAt(o)&&("*"!=e.charAt(o)||"/"!=e.charAt(o+1));)++o;if(o+=2,s===e.charAt(o-1))return h("End of comment missing");var n=e.slice(2,o-2);return d+=2,m(n),e=e.slice(o),d+=2,t({type:"comment",comment:n})}}function w(){var e=f(),o=v(r);if(o){if(k(),!v(l))return h("property missing ':'");var n=v(a),c=e({type:"declaration",property:u(o[0].replace(t,s)),value:n?u(n[0].replace(t,s)):s});return v(i),c}}return g(),function(){var e,t=[];for(_(t);e=w();)!1!==e&&(t.push(e),_(t));return t}()}},738:function(e){function t(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)} /*! * Determine if an object is a Buffer * * @author Feross Aboukhadijeh * @license MIT */ e.exports=function(e){return null!=e&&(t(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&t(e.slice(0,0))}(e)||!!e._isBuffer)}},568:function(e,t,o){var n,r,l,a,i;n=o(12),r=o(487).utf8,l=o(738),a=o(487).bin,(i=function(e,t){e.constructor==String?e=t&&"binary"===t.encoding?a.stringToBytes(e):r.stringToBytes(e):l(e)?e=Array.prototype.slice.call(e,0):Array.isArray(e)||e.constructor===Uint8Array||(e=e.toString());for(var o=n.bytesToWords(e),c=8*e.length,s=1732584193,u=-271733879,p=-1732584194,d=271733878,m=0;m>>24)|4278255360&(o[m]<<24|o[m]>>>8);o[c>>>5]|=128<>>9<<4)]=c;var f=i._ff,b=i._gg,y=i._hh,h=i._ii;for(m=0;m>>0,u=u+g>>>0,p=p+_>>>0,d=d+k>>>0}return n.endian([s,u,p,d])})._ff=function(e,t,o,n,r,l,a){var i=e+(t&o|~t&n)+(r>>>0)+a;return(i<>>32-l)+t},i._gg=function(e,t,o,n,r,l,a){var i=e+(t&n|o&~n)+(r>>>0)+a;return(i<>>32-l)+t},i._hh=function(e,t,o,n,r,l,a){var i=e+(t^o^n)+(r>>>0)+a;return(i<>>32-l)+t},i._ii=function(e,t,o,n,r,l,a){var i=e+(o^(t|~n))+(r>>>0)+a;return(i<>>32-l)+t},i._blocksize=16,i._digestsize=16,e.exports=function(e,t){if(null==e)throw new Error("Illegal argument "+e);var o=n.wordsToBytes(i(e,t));return t&&t.asBytes?o:t&&t.asString?a.bytesToString(o):n.bytesToHex(o)}},496:function(e){for(var t=self.crypto||self.msCrypto,o="-_",n=36;n--;)o+=n.toString(36);for(n=36;n---10;)o+=n.toString(36).toUpperCase();e.exports=function(e){var r="",l=t.getRandomValues(new Uint8Array(e||21));for(n=e||21;n--;)r+=o[63&l[n]];return r}},726:function(e,t,o){"use strict";function n(e,t,o,n,r,l,a){this.acceptsBooleans=2===t||3===t||4===t,this.attributeName=n,this.attributeNamespace=r,this.mustUseProperty=o,this.propertyName=e,this.type=t,this.sanitizeURL=l,this.removeEmptyString=a}const r={};["children","dangerouslySetInnerHTML","defaultValue","defaultChecked","innerHTML","suppressContentEditableWarning","suppressHydrationWarning","style"].forEach((e=>{r[e]=new n(e,0,!1,e,null,!1,!1)})),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach((([e,t])=>{r[e]=new n(e,1,!1,t,null,!1,!1)})),["contentEditable","draggable","spellCheck","value"].forEach((e=>{r[e]=new n(e,2,!1,e.toLowerCase(),null,!1,!1)})),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach((e=>{r[e]=new n(e,2,!1,e,null,!1,!1)})),["allowFullScreen","async","autoFocus","autoPlay","controls","default","defer","disabled","disablePictureInPicture","disableRemotePlayback","formNoValidate","hidden","loop","noModule","noValidate","open","playsInline","readOnly","required","reversed","scoped","seamless","itemScope"].forEach((e=>{r[e]=new n(e,3,!1,e.toLowerCase(),null,!1,!1)})),["checked","multiple","muted","selected"].forEach((e=>{r[e]=new n(e,3,!0,e,null,!1,!1)})),["capture","download"].forEach((e=>{r[e]=new n(e,4,!1,e,null,!1,!1)})),["cols","rows","size","span"].forEach((e=>{r[e]=new n(e,6,!1,e,null,!1,!1)})),["rowSpan","start"].forEach((e=>{r[e]=new n(e,5,!1,e.toLowerCase(),null,!1,!1)}));const l=/[\-\:]([a-z])/g,a=e=>e[1].toUpperCase();["accent-height","alignment-baseline","arabic-form","baseline-shift","cap-height","clip-path","clip-rule","color-interpolation","color-interpolation-filters","color-profile","color-rendering","dominant-baseline","enable-background","fill-opacity","fill-rule","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","glyph-name","glyph-orientation-horizontal","glyph-orientation-vertical","horiz-adv-x","horiz-origin-x","image-rendering","letter-spacing","lighting-color","marker-end","marker-mid","marker-start","overline-position","overline-thickness","paint-order","panose-1","pointer-events","rendering-intent","shape-rendering","stop-color","stop-opacity","strikethrough-position","strikethrough-thickness","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-anchor","text-decoration","text-rendering","underline-position","underline-thickness","unicode-bidi","unicode-range","units-per-em","v-alphabetic","v-hanging","v-ideographic","v-mathematical","vector-effect","vert-adv-y","vert-origin-x","vert-origin-y","word-spacing","writing-mode","xmlns:xlink","x-height"].forEach((e=>{const t=e.replace(l,a);r[t]=new n(t,1,!1,e,null,!1,!1)})),["xlink:actuate","xlink:arcrole","xlink:role","xlink:show","xlink:title","xlink:type"].forEach((e=>{const t=e.replace(l,a);r[t]=new n(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)})),["xml:base","xml:lang","xml:space"].forEach((e=>{const t=e.replace(l,a);r[t]=new n(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)})),["tabIndex","crossOrigin"].forEach((e=>{r[e]=new n(e,1,!1,e.toLowerCase(),null,!1,!1)}));r.xlinkHref=new n("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach((e=>{r[e]=new n(e,1,!1,e.toLowerCase(),null,!0,!0)}));const{CAMELCASE:i,SAME:c,possibleStandardNames:s}=o(229),u=RegExp.prototype.test.bind(new RegExp("^(data|aria)-[:A-Z_a-z\\u00C0-\\u00D6\\u00D8-\\u00F6\\u00F8-\\u02FF\\u0370-\\u037D\\u037F-\\u1FFF\\u200C-\\u200D\\u2070-\\u218F\\u2C00-\\u2FEF\\u3001-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFFD\\-.0-9\\u00B7\\u0300-\\u036F\\u203F-\\u2040]*$")),p=Object.keys(s).reduce(((e,t)=>{const o=s[t];return o===c?e[t]=t:o===i?e[t.toLowerCase()]=t:e[t]=o,e}),{});t.BOOLEAN=3,t.BOOLEANISH_STRING=2,t.NUMERIC=5,t.OVERLOADED_BOOLEAN=4,t.POSITIVE_NUMERIC=6,t.RESERVED=0,t.STRING=1,t.getPropertyInfo=function(e){return r.hasOwnProperty(e)?r[e]:null},t.isCustomAttribute=u,t.possibleStandardNames=p},229:function(e,t){t.SAME=0;t.CAMELCASE=1,t.possibleStandardNames={accept:0,acceptCharset:1,"accept-charset":"acceptCharset",accessKey:1,action:0,allowFullScreen:1,alt:0,as:0,async:0,autoCapitalize:1,autoComplete:1,autoCorrect:1,autoFocus:1,autoPlay:1,autoSave:1,capture:0,cellPadding:1,cellSpacing:1,challenge:0,charSet:1,checked:0,children:0,cite:0,class:"className",classID:1,className:1,cols:0,colSpan:1,content:0,contentEditable:1,contextMenu:1,controls:0,controlsList:1,coords:0,crossOrigin:1,dangerouslySetInnerHTML:1,data:0,dateTime:1,default:0,defaultChecked:1,defaultValue:1,defer:0,dir:0,disabled:0,disablePictureInPicture:1,disableRemotePlayback:1,download:0,draggable:0,encType:1,enterKeyHint:1,for:"htmlFor",form:0,formMethod:1,formAction:1,formEncType:1,formNoValidate:1,formTarget:1,frameBorder:1,headers:0,height:0,hidden:0,high:0,href:0,hrefLang:1,htmlFor:1,httpEquiv:1,"http-equiv":"httpEquiv",icon:0,id:0,innerHTML:1,inputMode:1,integrity:0,is:0,itemID:1,itemProp:1,itemRef:1,itemScope:1,itemType:1,keyParams:1,keyType:1,kind:0,label:0,lang:0,list:0,loop:0,low:0,manifest:0,marginWidth:1,marginHeight:1,max:0,maxLength:1,media:0,mediaGroup:1,method:0,min:0,minLength:1,multiple:0,muted:0,name:0,noModule:1,nonce:0,noValidate:1,open:0,optimum:0,pattern:0,placeholder:0,playsInline:1,poster:0,preload:0,profile:0,radioGroup:1,readOnly:1,referrerPolicy:1,rel:0,required:0,reversed:0,role:0,rows:0,rowSpan:1,sandbox:0,scope:0,scoped:0,scrolling:0,seamless:0,selected:0,shape:0,size:0,sizes:0,span:0,spellCheck:1,src:0,srcDoc:1,srcLang:1,srcSet:1,start:0,step:0,style:0,summary:0,tabIndex:1,target:0,title:0,type:0,useMap:1,value:0,width:0,wmode:0,wrap:0,about:0,accentHeight:1,"accent-height":"accentHeight",accumulate:0,additive:0,alignmentBaseline:1,"alignment-baseline":"alignmentBaseline",allowReorder:1,alphabetic:0,amplitude:0,arabicForm:1,"arabic-form":"arabicForm",ascent:0,attributeName:1,attributeType:1,autoReverse:1,azimuth:0,baseFrequency:1,baselineShift:1,"baseline-shift":"baselineShift",baseProfile:1,bbox:0,begin:0,bias:0,by:0,calcMode:1,capHeight:1,"cap-height":"capHeight",clip:0,clipPath:1,"clip-path":"clipPath",clipPathUnits:1,clipRule:1,"clip-rule":"clipRule",color:0,colorInterpolation:1,"color-interpolation":"colorInterpolation",colorInterpolationFilters:1,"color-interpolation-filters":"colorInterpolationFilters",colorProfile:1,"color-profile":"colorProfile",colorRendering:1,"color-rendering":"colorRendering",contentScriptType:1,contentStyleType:1,cursor:0,cx:0,cy:0,d:0,datatype:0,decelerate:0,descent:0,diffuseConstant:1,direction:0,display:0,divisor:0,dominantBaseline:1,"dominant-baseline":"dominantBaseline",dur:0,dx:0,dy:0,edgeMode:1,elevation:0,enableBackground:1,"enable-background":"enableBackground",end:0,exponent:0,externalResourcesRequired:1,fill:0,fillOpacity:1,"fill-opacity":"fillOpacity",fillRule:1,"fill-rule":"fillRule",filter:0,filterRes:1,filterUnits:1,floodOpacity:1,"flood-opacity":"floodOpacity",floodColor:1,"flood-color":"floodColor",focusable:0,fontFamily:1,"font-family":"fontFamily",fontSize:1,"font-size":"fontSize",fontSizeAdjust:1,"font-size-adjust":"fontSizeAdjust",fontStretch:1,"font-stretch":"fontStretch",fontStyle:1,"font-style":"fontStyle",fontVariant:1,"font-variant":"fontVariant",fontWeight:1,"font-weight":"fontWeight",format:0,from:0,fx:0,fy:0,g1:0,g2:0,glyphName:1,"glyph-name":"glyphName",glyphOrientationHorizontal:1,"glyph-orientation-horizontal":"glyphOrientationHorizontal",glyphOrientationVertical:1,"glyph-orientation-vertical":"glyphOrientationVertical",glyphRef:1,gradientTransform:1,gradientUnits:1,hanging:0,horizAdvX:1,"horiz-adv-x":"horizAdvX",horizOriginX:1,"horiz-origin-x":"horizOriginX",ideographic:0,imageRendering:1,"image-rendering":"imageRendering",in2:0,in:0,inlist:0,intercept:0,k1:0,k2:0,k3:0,k4:0,k:0,kernelMatrix:1,kernelUnitLength:1,kerning:0,keyPoints:1,keySplines:1,keyTimes:1,lengthAdjust:1,letterSpacing:1,"letter-spacing":"letterSpacing",lightingColor:1,"lighting-color":"lightingColor",limitingConeAngle:1,local:0,markerEnd:1,"marker-end":"markerEnd",markerHeight:1,markerMid:1,"marker-mid":"markerMid",markerStart:1,"marker-start":"markerStart",markerUnits:1,markerWidth:1,mask:0,maskContentUnits:1,maskUnits:1,mathematical:0,mode:0,numOctaves:1,offset:0,opacity:0,operator:0,order:0,orient:0,orientation:0,origin:0,overflow:0,overlinePosition:1,"overline-position":"overlinePosition",overlineThickness:1,"overline-thickness":"overlineThickness",paintOrder:1,"paint-order":"paintOrder",panose1:0,"panose-1":"panose1",pathLength:1,patternContentUnits:1,patternTransform:1,patternUnits:1,pointerEvents:1,"pointer-events":"pointerEvents",points:0,pointsAtX:1,pointsAtY:1,pointsAtZ:1,prefix:0,preserveAlpha:1,preserveAspectRatio:1,primitiveUnits:1,property:0,r:0,radius:0,refX:1,refY:1,renderingIntent:1,"rendering-intent":"renderingIntent",repeatCount:1,repeatDur:1,requiredExtensions:1,requiredFeatures:1,resource:0,restart:0,result:0,results:0,rotate:0,rx:0,ry:0,scale:0,security:0,seed:0,shapeRendering:1,"shape-rendering":"shapeRendering",slope:0,spacing:0,specularConstant:1,specularExponent:1,speed:0,spreadMethod:1,startOffset:1,stdDeviation:1,stemh:0,stemv:0,stitchTiles:1,stopColor:1,"stop-color":"stopColor",stopOpacity:1,"stop-opacity":"stopOpacity",strikethroughPosition:1,"strikethrough-position":"strikethroughPosition",strikethroughThickness:1,"strikethrough-thickness":"strikethroughThickness",string:0,stroke:0,strokeDasharray:1,"stroke-dasharray":"strokeDasharray",strokeDashoffset:1,"stroke-dashoffset":"strokeDashoffset",strokeLinecap:1,"stroke-linecap":"strokeLinecap",strokeLinejoin:1,"stroke-linejoin":"strokeLinejoin",strokeMiterlimit:1,"stroke-miterlimit":"strokeMiterlimit",strokeWidth:1,"stroke-width":"strokeWidth",strokeOpacity:1,"stroke-opacity":"strokeOpacity",suppressContentEditableWarning:1,suppressHydrationWarning:1,surfaceScale:1,systemLanguage:1,tableValues:1,targetX:1,targetY:1,textAnchor:1,"text-anchor":"textAnchor",textDecoration:1,"text-decoration":"textDecoration",textLength:1,textRendering:1,"text-rendering":"textRendering",to:0,transform:0,typeof:0,u1:0,u2:0,underlinePosition:1,"underline-position":"underlinePosition",underlineThickness:1,"underline-thickness":"underlineThickness",unicode:0,unicodeBidi:1,"unicode-bidi":"unicodeBidi",unicodeRange:1,"unicode-range":"unicodeRange",unitsPerEm:1,"units-per-em":"unitsPerEm",unselectable:0,vAlphabetic:1,"v-alphabetic":"vAlphabetic",values:0,vectorEffect:1,"vector-effect":"vectorEffect",version:0,vertAdvY:1,"vert-adv-y":"vertAdvY",vertOriginX:1,"vert-origin-x":"vertOriginX",vertOriginY:1,"vert-origin-y":"vertOriginY",vHanging:1,"v-hanging":"vHanging",vIdeographic:1,"v-ideographic":"vIdeographic",viewBox:1,viewTarget:1,visibility:0,vMathematical:1,"v-mathematical":"vMathematical",vocab:0,widths:0,wordSpacing:1,"word-spacing":"wordSpacing",writingMode:1,"writing-mode":"writingMode",x1:0,x2:0,x:0,xChannelSelector:1,xHeight:1,"x-height":"xHeight",xlinkActuate:1,"xlink:actuate":"xlinkActuate",xlinkArcrole:1,"xlink:arcrole":"xlinkArcrole",xlinkHref:1,"xlink:href":"xlinkHref",xlinkRole:1,"xlink:role":"xlinkRole",xlinkShow:1,"xlink:show":"xlinkShow",xlinkTitle:1,"xlink:title":"xlinkTitle",xlinkType:1,"xlink:type":"xlinkType",xmlBase:1,"xml:base":"xmlBase",xmlLang:1,"xml:lang":"xmlLang",xmlns:0,"xml:space":"xmlSpace",xmlnsXlink:1,"xmlns:xlink":"xmlnsXlink",xmlSpace:1,y1:0,y2:0,y:0,yChannelSelector:1,z:0,zoomAndPan:1}},826:function(e){var t={À:"A",Á:"A",Â:"A",Ã:"A",Ä:"A",Å:"A",Ấ:"A",Ắ:"A",Ẳ:"A",Ẵ:"A",Ặ:"A",Æ:"AE",Ầ:"A",Ằ:"A",Ȃ:"A",Ả:"A",Ạ:"A",Ẩ:"A",Ẫ:"A",Ậ:"A",Ç:"C",Ḉ:"C",È:"E",É:"E",Ê:"E",Ë:"E",Ế:"E",Ḗ:"E",Ề:"E",Ḕ:"E",Ḝ:"E",Ȇ:"E",Ẻ:"E",Ẽ:"E",Ẹ:"E",Ể:"E",Ễ:"E",Ệ:"E",Ì:"I",Í:"I",Î:"I",Ï:"I",Ḯ:"I",Ȋ:"I",Ỉ:"I",Ị:"I",Ð:"D",Ñ:"N",Ò:"O",Ó:"O",Ô:"O",Õ:"O",Ö:"O",Ø:"O",Ố:"O",Ṍ:"O",Ṓ:"O",Ȏ:"O",Ỏ:"O",Ọ:"O",Ổ:"O",Ỗ:"O",Ộ:"O",Ờ:"O",Ở:"O",Ỡ:"O",Ớ:"O",Ợ:"O",Ù:"U",Ú:"U",Û:"U",Ü:"U",Ủ:"U",Ụ:"U",Ử:"U",Ữ:"U",Ự:"U",Ý:"Y",à:"a",á:"a",â:"a",ã:"a",ä:"a",å:"a",ấ:"a",ắ:"a",ẳ:"a",ẵ:"a",ặ:"a",æ:"ae",ầ:"a",ằ:"a",ȃ:"a",ả:"a",ạ:"a",ẩ:"a",ẫ:"a",ậ:"a",ç:"c",ḉ:"c",è:"e",é:"e",ê:"e",ë:"e",ế:"e",ḗ:"e",ề:"e",ḕ:"e",ḝ:"e",ȇ:"e",ẻ:"e",ẽ:"e",ẹ:"e",ể:"e",ễ:"e",ệ:"e",ì:"i",í:"i",î:"i",ï:"i",ḯ:"i",ȋ:"i",ỉ:"i",ị:"i",ð:"d",ñ:"n",ò:"o",ó:"o",ô:"o",õ:"o",ö:"o",ø:"o",ố:"o",ṍ:"o",ṓ:"o",ȏ:"o",ỏ:"o",ọ:"o",ổ:"o",ỗ:"o",ộ:"o",ờ:"o",ở:"o",ỡ:"o",ớ:"o",ợ:"o",ù:"u",ú:"u",û:"u",ü:"u",ủ:"u",ụ:"u",ử:"u",ữ:"u",ự:"u",ý:"y",ÿ:"y",Ā:"A",ā:"a",Ă:"A",ă:"a",Ą:"A",ą:"a",Ć:"C",ć:"c",Ĉ:"C",ĉ:"c",Ċ:"C",ċ:"c",Č:"C",č:"c",C̆:"C",c̆:"c",Ď:"D",ď:"d",Đ:"D",đ:"d",Ē:"E",ē:"e",Ĕ:"E",ĕ:"e",Ė:"E",ė:"e",Ę:"E",ę:"e",Ě:"E",ě:"e",Ĝ:"G",Ǵ:"G",ĝ:"g",ǵ:"g",Ğ:"G",ğ:"g",Ġ:"G",ġ:"g",Ģ:"G",ģ:"g",Ĥ:"H",ĥ:"h",Ħ:"H",ħ:"h",Ḫ:"H",ḫ:"h",Ĩ:"I",ĩ:"i",Ī:"I",ī:"i",Ĭ:"I",ĭ:"i",Į:"I",į:"i",İ:"I",ı:"i",IJ:"IJ",ij:"ij",Ĵ:"J",ĵ:"j",Ķ:"K",ķ:"k",Ḱ:"K",ḱ:"k",K̆:"K",k̆:"k",Ĺ:"L",ĺ:"l",Ļ:"L",ļ:"l",Ľ:"L",ľ:"l",Ŀ:"L",ŀ:"l",Ł:"l",ł:"l",Ḿ:"M",ḿ:"m",M̆:"M",m̆:"m",Ń:"N",ń:"n",Ņ:"N",ņ:"n",Ň:"N",ň:"n",ʼn:"n",N̆:"N",n̆:"n",Ō:"O",ō:"o",Ŏ:"O",ŏ:"o",Ő:"O",ő:"o",Œ:"OE",œ:"oe",P̆:"P",p̆:"p",Ŕ:"R",ŕ:"r",Ŗ:"R",ŗ:"r",Ř:"R",ř:"r",R̆:"R",r̆:"r",Ȓ:"R",ȓ:"r",Ś:"S",ś:"s",Ŝ:"S",ŝ:"s",Ş:"S",Ș:"S",ș:"s",ş:"s",Š:"S",š:"s",Ţ:"T",ţ:"t",ț:"t",Ț:"T",Ť:"T",ť:"t",Ŧ:"T",ŧ:"t",T̆:"T",t̆:"t",Ũ:"U",ũ:"u",Ū:"U",ū:"u",Ŭ:"U",ŭ:"u",Ů:"U",ů:"u",Ű:"U",ű:"u",Ų:"U",ų:"u",Ȗ:"U",ȗ:"u",V̆:"V",v̆:"v",Ŵ:"W",ŵ:"w",Ẃ:"W",ẃ:"w",X̆:"X",x̆:"x",Ŷ:"Y",ŷ:"y",Ÿ:"Y",Y̆:"Y",y̆:"y",Ź:"Z",ź:"z",Ż:"Z",ż:"z",Ž:"Z",ž:"z",ſ:"s",ƒ:"f",Ơ:"O",ơ:"o",Ư:"U",ư:"u",Ǎ:"A",ǎ:"a",Ǐ:"I",ǐ:"i",Ǒ:"O",ǒ:"o",Ǔ:"U",ǔ:"u",Ǖ:"U",ǖ:"u",Ǘ:"U",ǘ:"u",Ǚ:"U",ǚ:"u",Ǜ:"U",ǜ:"u",Ứ:"U",ứ:"u",Ṹ:"U",ṹ:"u",Ǻ:"A",ǻ:"a",Ǽ:"AE",ǽ:"ae",Ǿ:"O",ǿ:"o",Þ:"TH",þ:"th",Ṕ:"P",ṕ:"p",Ṥ:"S",ṥ:"s",X́:"X",x́:"x",Ѓ:"Г",ѓ:"г",Ќ:"К",ќ:"к",A̋:"A",a̋:"a",E̋:"E",e̋:"e",I̋:"I",i̋:"i",Ǹ:"N",ǹ:"n",Ồ:"O",ồ:"o",Ṑ:"O",ṑ:"o",Ừ:"U",ừ:"u",Ẁ:"W",ẁ:"w",Ỳ:"Y",ỳ:"y",Ȁ:"A",ȁ:"a",Ȅ:"E",ȅ:"e",Ȉ:"I",ȉ:"i",Ȍ:"O",ȍ:"o",Ȑ:"R",ȑ:"r",Ȕ:"U",ȕ:"u",B̌:"B",b̌:"b",Č̣:"C",č̣:"c",Ê̌:"E",ê̌:"e",F̌:"F",f̌:"f",Ǧ:"G",ǧ:"g",Ȟ:"H",ȟ:"h",J̌:"J",ǰ:"j",Ǩ:"K",ǩ:"k",M̌:"M",m̌:"m",P̌:"P",p̌:"p",Q̌:"Q",q̌:"q",Ř̩:"R",ř̩:"r",Ṧ:"S",ṧ:"s",V̌:"V",v̌:"v",W̌:"W",w̌:"w",X̌:"X",x̌:"x",Y̌:"Y",y̌:"y",A̧:"A",a̧:"a",B̧:"B",b̧:"b",Ḑ:"D",ḑ:"d",Ȩ:"E",ȩ:"e",Ɛ̧:"E",ɛ̧:"e",Ḩ:"H",ḩ:"h",I̧:"I",i̧:"i",Ɨ̧:"I",ɨ̧:"i",M̧:"M",m̧:"m",O̧:"O",o̧:"o",Q̧:"Q",q̧:"q",U̧:"U",u̧:"u",X̧:"X",x̧:"x",Z̧:"Z",z̧:"z",й:"и",Й:"И",ё:"е",Ё:"Е"},o=Object.keys(t).join("|"),n=new RegExp(o,"g"),r=new RegExp(o,"");function l(e){return t[e]}var a=function(e){return e.replace(n,l)};e.exports=a,e.exports.has=function(e){return!!e.match(r)},e.exports.remove=a},975:function(e,t,o){var n;!function(){"use strict";var r={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function l(e){return function(e,t){var o,n,a,i,c,s,u,p,d,m=1,f=e.length,b="";for(n=0;n=0),i.type){case"b":o=parseInt(o,10).toString(2);break;case"c":o=String.fromCharCode(parseInt(o,10));break;case"d":case"i":o=parseInt(o,10);break;case"j":o=JSON.stringify(o,null,i.width?parseInt(i.width):0);break;case"e":o=i.precision?parseFloat(o).toExponential(i.precision):parseFloat(o).toExponential();break;case"f":o=i.precision?parseFloat(o).toFixed(i.precision):parseFloat(o);break;case"g":o=i.precision?String(Number(o.toPrecision(i.precision))):parseFloat(o);break;case"o":o=(parseInt(o,10)>>>0).toString(8);break;case"s":o=String(o),o=i.precision?o.substring(0,i.precision):o;break;case"t":o=String(!!o),o=i.precision?o.substring(0,i.precision):o;break;case"T":o=Object.prototype.toString.call(o).slice(8,-1).toLowerCase(),o=i.precision?o.substring(0,i.precision):o;break;case"u":o=parseInt(o,10)>>>0;break;case"v":o=o.valueOf(),o=i.precision?o.substring(0,i.precision):o;break;case"x":o=(parseInt(o,10)>>>0).toString(16);break;case"X":o=(parseInt(o,10)>>>0).toString(16).toUpperCase()}r.json.test(i.type)?b+=o:(!r.number.test(i.type)||p&&!i.sign?d="":(d=p?"+":"-",o=o.toString().replace(r.sign,"")),s=i.pad_char?"0"===i.pad_char?"0":i.pad_char.charAt(1):" ",u=i.width-(d+o).length,c=i.width&&u>0?s.repeat(u):"",b+=i.align?d+o+c:"0"===s?d+c+o:c+d+o)}return b}(function(e){if(i[e])return i[e];var t,o=e,n=[],l=0;for(;o;){if(null!==(t=r.text.exec(o)))n.push(t[0]);else if(null!==(t=r.modulo.exec(o)))n.push("%");else{if(null===(t=r.placeholder.exec(o)))throw new SyntaxError("[sprintf] unexpected placeholder");if(t[2]){l|=1;var a=[],c=t[2],s=[];if(null===(s=r.key.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(a.push(s[1]);""!==(c=c.substring(s[0].length));)if(null!==(s=r.key_access.exec(c)))a.push(s[1]);else{if(null===(s=r.index_access.exec(c)))throw new SyntaxError("[sprintf] failed to parse named argument key");a.push(s[1])}t[2]=a}else l|=2;if(3===l)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");n.push({placeholder:t[0],param_no:t[1],keys:t[2],sign:t[3],pad_char:t[4],align:t[5],width:t[6],precision:t[7],type:t[8]})}o=o.substring(t[0].length)}return i[e]=n}(e),arguments)}function a(e,t){return l.apply(null,[e].concat(t||[]))}var i=Object.create(null);l,a,"undefined"!=typeof window&&(window.sprintf=l,window.vsprintf=a,void 0===(n=function(){return{sprintf:l,vsprintf:a}}.call(t,o,t,e))||(e.exports=n))}()},476:function(e,t,o){"use strict";var n=(this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}})(o(174)),r=o(678);function l(e,t){var o={};return e&&"string"==typeof e?((0,n.default)(e,(function(e,n){e&&n&&(o[(0,r.camelCase)(e,t)]=n)})),o):o}l.default=l,e.exports=l},678:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.camelCase=void 0;var o=/^--[a-zA-Z0-9_-]+$/,n=/-([a-z])/g,r=/^[^-]+$/,l=/^-(webkit|moz|ms|o|khtml)-/,a=/^-(ms)-/,i=function(e,t){return t.toUpperCase()},c=function(e,t){return"".concat(t,"-")};t.camelCase=function(e,t){return void 0===t&&(t={}),function(e){return!e||r.test(e)||o.test(e)}(e)?e:(e=e.toLowerCase(),(e=t.reactCompat?e.replace(a,c):e.replace(l,c)).replace(n,i))}},174:function(e,t,o){"use strict";var n=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0}),t.default=function(e,t){var o=null;if(!e||"string"!=typeof e)return o;var n=(0,r.default)(e),l="function"==typeof t;return n.forEach((function(e){if("declaration"===e.type){var n=e.property,r=e.value;l?t(n,r,e):r&&((o=o||{})[n]=r)}})),o};var r=n(o(139))},313:function(e){"use strict";e.exports=window.React},61:function(e,t,o){var n=o(698).default;function r(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */e.exports=r=function(){return o},e.exports.__esModule=!0,e.exports.default=e.exports;var t,o={},l=Object.prototype,a=l.hasOwnProperty,i=Object.defineProperty||function(e,t,o){e[t]=o.value},c="function"==typeof Symbol?Symbol:{},s=c.iterator||"@@iterator",u=c.asyncIterator||"@@asyncIterator",p=c.toStringTag||"@@toStringTag";function d(e,t,o){return Object.defineProperty(e,t,{value:o,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{d({},"")}catch(t){d=function(e,t,o){return e[t]=o}}function m(e,t,o,n){var r=t&&t.prototype instanceof _?t:_,l=Object.create(r.prototype),a=new A(n||[]);return i(l,"_invoke",{value:j(e,o,a)}),l}function f(e,t,o){try{return{type:"normal",arg:e.call(t,o)}}catch(e){return{type:"throw",arg:e}}}o.wrap=m;var b="suspendedStart",y="suspendedYield",h="executing",v="completed",g={};function _(){}function k(){}function w(){}var O={};d(O,s,(function(){return this}));var x=Object.getPrototypeOf,C=x&&x(x(B([])));C&&C!==l&&a.call(C,s)&&(O=C);var E=w.prototype=_.prototype=Object.create(O);function P(e){["next","throw","return"].forEach((function(t){d(e,t,(function(e){return this._invoke(t,e)}))}))}function S(e,t){function o(r,l,i,c){var s=f(e[r],e,l);if("throw"!==s.type){var u=s.arg,p=u.value;return p&&"object"==n(p)&&a.call(p,"__await")?t.resolve(p.__await).then((function(e){o("next",e,i,c)}),(function(e){o("throw",e,i,c)})):t.resolve(p).then((function(e){u.value=e,i(u)}),(function(e){return o("throw",e,i,c)}))}c(s.arg)}var r;i(this,"_invoke",{value:function(e,n){function l(){return new t((function(t,r){o(e,n,t,r)}))}return r=r?r.then(l,l):l()}})}function j(e,o,n){var r=b;return function(l,a){if(r===h)throw Error("Generator is already running");if(r===v){if("throw"===l)throw a;return{value:t,done:!0}}for(n.method=l,n.arg=a;;){var i=n.delegate;if(i){var c=I(i,n);if(c){if(c===g)continue;return c}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(r===b)throw r=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);r=h;var s=f(e,o,n);if("normal"===s.type){if(r=n.done?v:y,s.arg===g)continue;return{value:s.arg,done:n.done}}"throw"===s.type&&(r=v,n.method="throw",n.arg=s.arg)}}}function I(e,o){var n=o.method,r=e.iterator[n];if(r===t)return o.delegate=null,"throw"===n&&e.iterator.return&&(o.method="return",o.arg=t,I(e,o),"throw"===o.method)||"return"!==n&&(o.method="throw",o.arg=new TypeError("The iterator does not provide a '"+n+"' method")),g;var l=f(r,e.iterator,o.arg);if("throw"===l.type)return o.method="throw",o.arg=l.arg,o.delegate=null,g;var a=l.arg;return a?a.done?(o[e.resultName]=a.value,o.next=e.nextLoc,"return"!==o.method&&(o.method="next",o.arg=t),o.delegate=null,g):a:(o.method="throw",o.arg=new TypeError("iterator result is not an object"),o.delegate=null,g)}function T(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function D(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function A(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(T,this),this.reset(!0)}function B(e){if(e||""===e){var o=e[s];if(o)return o.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var r=-1,l=function o(){for(;++r=0;--r){var l=this.tryEntries[r],i=l.completion;if("root"===l.tryLoc)return n("end");if(l.tryLoc<=this.prev){var c=a.call(l,"catchLoc"),s=a.call(l,"finallyLoc");if(c&&s){if(this.prev=0;--o){var n=this.tryEntries[o];if(n.tryLoc<=this.prev&&a.call(n,"finallyLoc")&&this.prev=0;--t){var o=this.tryEntries[t];if(o.finallyLoc===e)return this.complete(o.completion,o.afterLoc),D(o),g}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var o=this.tryEntries[t];if(o.tryLoc===e){var n=o.completion;if("throw"===n.type){var r=n.arg;D(o)}return r}}throw Error("illegal catch attempt")},delegateYield:function(e,o,n){return this.delegate={iterator:B(e),resultName:o,nextLoc:n},"next"===this.method&&(this.arg=t),g}},o}e.exports=r,e.exports.__esModule=!0,e.exports.default=e.exports},698:function(e){function t(o){return e.exports=t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e.exports.__esModule=!0,e.exports.default=e.exports,t(o)}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports},687:function(e,t,o){var n=o(61)();e.exports=n;try{regeneratorRuntime=n}catch(e){"object"==typeof globalThis?globalThis.regeneratorRuntime=n:Function("r","regeneratorRuntime = r")(n)}}},o={};function n(t){var r=o[t];if(void 0!==r)return r.exports;var l=o[t]={exports:{}};return e[t].call(l.exports,l,l.exports,n),l.exports}n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,{a:t}),t},n.d=function(e,t){for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},function(){"use strict";function e(t){return e="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},e(t)}function o(t){var o=function(t,o){if("object"!=e(t)||!t)return t;var n=t[Symbol.toPrimitive];if(void 0!==n){var r=n.call(t,o||"default");if("object"!=e(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return("string"===o?String:Number)(t)}(t,"string");return"symbol"==e(o)?o:o+""}function r(e,t,n){return(t=o(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var l=window.wp.element,a=window.wp.i18n,i=window.wp.blocks,c=window.wp.blockEditor,s=window.wp.data,u=window.blc_blocks_data,p=u.breadcrumb_home_item,d=u.breadcrumb_home_text,m=u.breadcrumb_separator,f=u.breadcrumb_page_title,b=function(){var e=(0,l.useMemo)((function(){return"text"===p?d:(0,l.createElement)("svg",{class:"ct-home-icon",width:"15",viewBox:"0 0 24 20"},(0,l.createElement)("path",{d:"M12,0L0.4,10.5h3.2V20h6.3v-6.3h4.2V20h6.3v-9.5h3.2L12,0z"}))}),[]),t=(0,l.useMemo)((function(){return"type-2"===m?(0,l.createElement)("svg",{class:"separator",width:"8",height:"8",viewBox:"0 0 8 8"},(0,l.createElement)("polygon",{points:"2.5,0 6.9,4 2.5,8 "})):"type-3"===m?(0,l.createElement)("span",{className:"separator"},"/"):(0,l.createElement)("svg",{class:"separator",width:"8",height:"8",viewBox:"0 0 8 8"},(0,l.createElement)("path",{d:"M2,6.9L4.8,4L2,1.1L2.6,0l4,4l-4,4L2,6.9z"}))}),[]),o=(0,s.withSelect)((function(e){var t;return{title:(null===(t=e("core/editor"))||void 0===t?void 0:t.getEditedPostAttribute("title"))||""}}))((function(e){return(0,l.createElement)("span",null,(null==e?void 0:e.title)||(0,a.__)("Page","blocksy-companion"))}));return(0,l.createElement)(React.Fragment,null,(0,l.createElement)("span",null,(0,l.createElement)("span",null,e),t),(0,l.createElement)("span",null,(0,l.createElement)("span",null,(0,a.__)("Subpage","blocksy-companion")),f&&t),f&&(0,l.createElement)(o,null))};function y(){return y=Object.assign?Object.assign.bind():function(e){for(var t=1;te.length)&&(t=e.length);for(var o=0,n=Array(t);o2&&void 0!==arguments[2]?arguments[2]:{};return L.fetch(e,t,o)},q=function(e){var t=e.attributes,o=e.previewedPostId,n=C((0,l.useState)(null),2),r=n[0],a=n[1];return(0,l.useEffect)((function(){var e=new URLSearchParams(window.location.search);U("".concat(wp.ajax.settings.url,"?action=blocksy_get_posts_block_data").concat(e.get("lang")?"&lang="+e.get("lang"):""),{attributes:t,previewedPostId:o},{fetcherName:"posts-block-data-".concat(t.uniqueId),headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST"}).then((function(e){return e.json()})).then((function(e){var t=e.success,o=e.data;t&&a(o)})).catch((function(e){}))}),[t,o]),{blockData:r}},G=window.blocksyOptions,W=function(e){var t=e.isSlideshow,o=e.attributes,n=e.context,r=e.toWatch,a=C((0,l.useState)(null),2),i=a[0],c=a[1],s=(0,l.useRef)(),u=C((0,l.useState)(null),2),p=u[0],d=u[1],m={},f=[];return(0,l.useEffect)((function(){i&&i.scheduleSliderRecalculation()}),[o,n]),(0,l.useEffect)((function(){i&&!t&&i.destroy(),i&&t&&setTimeout((function(){i.refreshActivation()}),50)}),[t,i,r]),(0,l.useEffect)((function(){return function(){i&&i.destroy()}}),[]),t&&(m.ref=s,m.onMouseOver=function(){i||(0,G.mountFlexy)().then((function(e){var t=e.mount;e.Flexy;c(t((function(){return s.current}),{flexyOptions:{dragAndDropOptions:{mountDragAndDropEventListener:!1},arrowsOptions:{mountListeners:!1},onRender:function(e,t){d(t)}}}))}))}),p&&(Object.keys(p.flexyAttributeElAttr).map((function(e){m[e]=p.flexyAttributeElAttr[e]})),f=p.elementsDescriptor),{flexyInstance:i,flexyContainerAttr:m,elementsDescriptor:f,elementDescriptorForIndex:function(e){return f&&f.length>0&&f[e]?f[e]:f&&f.length>0&&!f[e]?f[0]:null},arrowsDescritor:{left:{onClick:function(e){e.preventDefault(),i&&i.sliderArrows.navigate("left")}},right:{onClick:function(e){e.preventDefault(),i&&i.sliderArrows.navigate("right")}}}}},Z=n(496),$=n.n(Z);function K(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}var X=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],o="",n=$()(),a={cacheId:n,initialStyleTagsDescriptor:[{readStyles:function(){return""},persistStyles:function(e){o=e}}]};G.syncHelpers.getStyleTagsWithAst(a);e.map((function(e){var t=G.syncHelpers.getUpdateAstsForStyleDescriptor(function(e){for(var t=1;t1}({attributes:t,clientId:o,blockType:r})||n({uniqueId:re(o)})}),[o]);var a=t.uniqueId||re(o);return{uniqueId:a,props:{"data-id":a}}},ae=function(e){var t=e.clientId,o=e.setAttributes,n=e.setIsPatternSelectionModalOpen,r=(0,s.useDispatch)(c.store).replaceInnerBlocks;return(0,l.createElement)("div",{className:"components-placeholder is-large"},(0,l.createElement)("div",{className:"components-placeholder__label"},(0,l.createElement)("svg",{viewBox:"0 0 24 24",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24","aria-hidden":"true",focusable:"false"},(0,l.createElement)("path",{d:"M5.5 18v-1c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v1c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5zm.5 2c-1.1 0-2-.9-2-2v-1c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v1c0 1.1-.9 2-2 2H6zm-.5-9V6c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v5c0 .3-.2.5-.5.5H6c-.3 0-.5-.2-.5-.5zm.5 2c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v5c0 1.1-.9 2-2 2H6zm8.5 0v5c0 .3.2.5.5.5h3c.3 0 .5-.2.5-.5v-5c0-.3-.2-.5-.5-.5h-3c-.3 0-.5.2-.5.5zM13 18c0 1.1.9 2 2 2h3c1.1 0 2-.9 2-2v-5c0-1.1-.9-2-2-2h-3c-1.1 0-2 .9-2 2v5zm1.5-11V6c0-.3.2-.5.5-.5h3c.3 0 .5.2.5.5v1c0 .3-.2.5-.5.5h-3c-.3 0-.5-.2-.5-.5zm.5 2c-1.1 0-2-.9-2-2V6c0-1.1.9-2 2-2h3c1.1 0 2 .9 2 2v1c0 1.1-.9 2-2 2h-3z",fillRule:"evenodd"})),(0,a.__)("Advanced Posts","blocksy-companion")),(0,l.createElement)("fieldset",{className:"components-placeholder__fieldset"},(0,l.createElement)("legend",{className:"components-placeholder__instructions"},(0,a.__)("Inherit the Customizer layout, start with a pattern or create a custom layout","blocksy-companion")),(0,l.createElement)("button",{className:"components-button is-primary",onClick:function(e){e.preventDefault(),o({design:"default"})}},(0,a.__)("Inherit From Customizer","blocksy-companion")),(0,l.createElement)("button",{className:"components-button is-primary",onClick:function(e){e.preventDefault(),n(!0)}},(0,a.__)("Choose Pattern","blocksy-companion")),(0,l.createElement)("button",{className:"components-button is-primary",onClick:function(e){e.preventDefault(),r(t,(0,i.createBlocksFromInnerBlocksTemplate)([["blocksy/post-template",{},[["blocksy/dynamic-data",{tagName:"h2",field:"wp:title",has_field_link:"yes"}],["blocksy/dynamic-data",{field:"wp:date"}],["blocksy/dynamic-data",{field:"wp:excerpt"}]]]]),!1)}},(0,a.__)("Create Custom Layout","blocksy-companion"))))},ie=n(313),ce=window.wp.primitives;var se=(0,ie.createElement)(ce.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ie.createElement)(ce.Path,{d:"M11 12.5V17.5H12.5V12.5H17.5V11H12.5V6H11V11H6V12.5H11Z"}));var ue=(0,ie.createElement)(ce.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ie.createElement)(ce.Path,{d:"M13 19h-2v-2h2v2zm0-6h-2v-2h2v2zm0-6h-2V5h2v2z"}));var pe=(0,ie.createElement)(ce.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,ie.createElement)(ce.Path,{d:"M16.7 7.1l-6.3 8.5-3.3-2.5-.9 1.2 4.5 3.4L17.9 8z"})),de=window.wp.a11y,me=function(e){var t=e.items,o=e.selectedItems,n=e.onItemClick,r=e.label,i=e.resetAll,c=o.length>0;return(0,l.createElement)(h.__experimentalHStack,null,(0,l.createElement)(h.__experimentalHeading,{style:{margin:0},level:2},r),(0,l.createElement)(h.DropdownMenu,{icon:0===o.length?se:ue,label:(0,a.__)("Parameters options","blocksy-companion"),toggleProps:{isSmall:!0,describedBy:0===o.length?(0,a.__)("All options are currently hidden","blocksy-companion"):void 0}},(function(){return(0,l.createElement)(React.Fragment,null,t.map((function(e,t){return(0,l.createElement)(h.MenuGroup,{key:t,label:e.label},e.items.map((function(e,t){var r=o.includes(e.label);return(0,l.createElement)(h.MenuItem,{key:t,icon:r?pe:null,isSelected:r,onClick:function(){return n(e.label)}},e.label)})))})),(0,l.createElement)(h.MenuGroup,null,(0,l.createElement)(h.MenuItem,{"aria-disabled":!c,variant:"tertiary",onClick:function(){c&&(i(),(0,de.speak)((0,a.__)("All options reset","blocksy-companion"),"assertive"))}},(0,a.__)("Reset all","blocksy-companion"))))})))},fe=function(e){var t=e.className,o=e.attributes,n=e.setAttributes,r=e.resetAll,a=e.items,i=e.label,c=a.reduce((function(e,t){return[].concat(P(e),P(t.items.filter((function(e){return e.hasValue()})).map((function(e){return e.label}))))}),[]),s=C((0,l.useState)([]),2),u=s[0],p=s[1],d=P(new Set([].concat(P(u),P(c))));return(0,l.createElement)("div",{className:Y()("ct-tools-panel",t)},(0,l.createElement)(me,{label:i,resetAll:function(){p([]),r()},items:a,selectedItems:d,attributes:o,setAttributes:n,onItemClick:function(e){if(d.includes(e)){var t=a.reduce((function(e,t){return[].concat(P(e),P(t.items))}),[]).find((function(t){return t.label===e}));p(u.filter((function(t){return t!==e}))),t.reset()}else p([].concat(P(u),[e]))}}),(0,l.createElement)("div",{className:"ct-tools-panel-items"},a.reduce((function(e,t){return[].concat(P(e),P(t.items))}),[]).filter((function(e){return d.includes(e.label)})).map((function(e){return e.render()}))))},be=window.wp.coreData;function ye(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function he(e){for(var t=1;t0;){var l,a=r.shift();"blocksy/query"===a.name&&(a.attributes.uniqueId="",n.push(a.clientId)),null===(l=a.innerBlocks)||void 0===l||l.forEach((function(e){r.push(e)}))}return{newBlocks:o,queryClientIds:n}};var _e=function(e){return(0,s.useSelect)((function(t){return((0,t(be.store).getTaxonomies)({type:e,per_page:-1,context:"view"})||[]).filter((function(e){var t=e.slug;return!ve.includes(t)}))}),[e])},ke=window.wp.compose;function we(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(!e)return;if("string"==typeof e)return Oe(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return Array.from(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return Oe(e,t)}(e))){var t=0,o=function(){};return{s:o,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,r,l=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return l=e.done,e},e:function(e){a=!0,r=e},f:function(){try{l||null==n.return||n.return()}finally{if(a)throw r}}}}function Oe(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,n=new Array(t);o0?{label:(0,a.__)("Taxonomies","blocksy-companion"),items:l}:null}},Ne=function(e){var t=e.context,o=e.attributes,n=(e.attributes.post_type,e.setAttributes),i=function(e){var t=e.attributes,o=e.attributes.post_type,n=e.previewedPostMatchesType,r=e.setAttributes,l=_e(o),i=[];return l&&l.length>0&&(i=[].concat(P(l.map((function(e){return Ae({taxonomy:e,attributes:t,setAttributes:r,previewedPostMatchesType:n})}))),P(l.map((function(e){return Be({taxonomy:e,attributes:t,setAttributes:r})}))))),{taxonomiesGroup:i.length>0?{label:(0,a.__)("Taxonomies","blocksy-companion"),items:i}:null}}({attributes:o,setAttributes:n,previewedPostMatchesType:o.post_type===t.postType}),s=i.taxonomiesGroup;return(0,l.createElement)(c.InspectorControls,null,(0,l.createElement)(fe,{className:"ct-query-parameters-component",attributes:o,setAttributes:n,resetAll:function(){n({offset:0,sticky_posts:"include",orderby:"post_date",order:"desc",include_term_ids:{},exclude_term_ids:{}})},items:[{label:(0,a.__)("General","blocksy-companion"),items:[{label:(0,a.__)("Offset","blocksy-companion"),hasValue:function(){return 0!==o.offset},reset:function(){n({offset:0})},render:function(){return(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){n(r({},e,t))},options:{offset:{type:"ct-number",label:(0,a.__)("Offset","blocksy-companion"),value:"",min:0,max:500}},value:o,hasRevertButton:!1})}},{label:(0,a.__)("Order by","blocksy-companion"),hasValue:function(){return"post_date"!==o.orderby},reset:function(){n({orderby:"post_date"})},render:function(){return(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){n(r({},e,t))},options:{orderby:{type:"ct-select",label:(0,a.__)("Order by","blocksy-companion"),value:"",choices:[{key:"title",value:(0,a.__)("Title","blocksy-companion")},{key:"post_date",value:(0,a.__)("Publish Date","blocksy-companion")},{key:"modified",value:(0,a.__)("Modified Date","blocksy-companion")},{key:"comment_count",value:(0,a.__)("Most commented","blocksy-companion")},{key:"author",value:(0,a.__)("Author","blocksy-companion")},{key:"rand",value:(0,a.__)("Random","blocksy-companion")},{key:"menu_order",value:(0,a.__)("Menu Order","blocksy-companion")}]}},value:o,hasRevertButton:!1})}},{label:(0,a.__)("Order","blocksy-companion"),hasValue:function(){return"desc"!==o.order},reset:function(){n({order:"desc"})},render:function(){return(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){n(r({},e,t))},options:{order:{type:"ct-select",label:(0,a.__)("Order","blocksy-companion"),value:"",choices:[{key:"DESC",value:(0,a.__)("Descending","blocksy-companion")},{key:"ASC",value:(0,a.__)("Ascending","blocksy-companion")}]}},value:o,hasRevertButton:!1})}},{label:(0,a.__)("Sticky Posts","blocksy-companion"),hasValue:function(){return"include"!==o.sticky_posts},reset:function(){n({sticky_posts:"include"})},render:function(){return(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){n(r({},e,t))},options:{sticky_posts:{type:"ct-select",label:(0,a.__)("Sticky Posts","blocksy-companion"),value:"include",choices:[{key:"include",value:(0,a.__)("Include","blocksy-companion")},{key:"exclude",value:(0,a.__)("Exclude","blocksy-companion")},{key:"only",value:(0,a.__)("Only","blocksy-companion")}]}},value:o,hasRevertButton:!1})}}]}].concat(P(s?[s]:[])),label:(0,a.__)("Parameters","blocksy-companion")}))};function ze(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function Me(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:"";return e=(e=Le()(e)).trim().toLowerCase()}function qe(e,t){var o=Ue(t),n=Ue(e.title),r=0;if(o===n)r+=30;else if(n.startsWith(o))r+=20;else{o.split(" ").every((function(e){return n.includes(e)}))&&(r+=10)}return r}function Ge(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";if(!t)return e;var o=e.map((function(e){return[e,qe(e,t)]})).filter((function(e){return C(e,2)[1]>0}));return o.sort((function(e,t){var o=C(e,2)[1];return C(t,2)[1]-o})),o.map((function(e){return C(e,1)[0]}))}var We=function(e){var t=e.clientId,o=(e.attributes,e.setIsPatternSelectionModalOpen),n=e.postType,r=C((0,l.useState)(""),2),u=r[0],p=r[1],d=(0,s.useDispatch)(c.store),m=d.replaceBlock,f=d.selectBlock,b=C((0,l.useState)([]),2),y=b[0],v=b[1];(0,l.useEffect)((function(){new Promise((function(e){Fe?e(Fe):fetch("".concat(wp.ajax.settings.url,"?action=blocksy_get_posts_block_patterns"),{headers:{Accept:"application/json","Content-Type":"application/json"},method:"POST",body:JSON.stringify({}),signal:Re.signal}).then((function(e){return e.json()})).then((function(t){var o=t.success,n=t.data;o&&(Fe=n.patterns.map((function(e){return Me(Me({},e),{},{blocks:(0,i.parse)(e.content,{__unstableSkipMigrationLogs:!0})})})),e(Fe))}))})).then((function(e){v(e)}))}),[]);var g=(0,l.useMemo)((function(){return{previewPostType:n}}),[n]),_=(0,l.useMemo)((function(){return Ge(y,u)}),[y,u]),k=(0,ke.useAsyncList)(_);return(0,l.createElement)(h.Modal,{overlayClassName:"block-library-query-pattern__selection-modal",title:(0,a.__)("Choose a pattern","blocksy-companion"),onRequestClose:function(){return o(!1)},isFullScreen:!0},(0,l.createElement)("div",{className:"block-library-query-pattern__selection-content"},(0,l.createElement)("div",{className:"block-library-query-pattern__selection-search"},(0,l.createElement)(h.SearchControl,{__nextHasNoMarginBottom:!0,onChange:p,value:u,label:(0,a.__)("Search for patterns","blocksy-companion"),placeholder:(0,a.__)("Search","blocksy-companion")})),(0,l.createElement)(c.BlockContextProvider,{value:g},(0,l.createElement)(c.__experimentalBlockPatternsList,{blockPatterns:_,shownPatterns:k,onClickPattern:function(e,o){var n=ge(o),r=n.newBlocks,l=n.queryClientIds;m(t,r),l[0]&&f(l[0])}}))))};function Ze(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function $e(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{}).hasPages,t=void 0!==e&&e,o=(0,s.useSelect)((function(e){var o,n=e(be.store).getPostTypes,r=["attachment","product"].concat(P(t?[]:["page"]));return null===(o=n({per_page:-1}))||void 0===o?void 0:o.filter((function(e){var t=e.viewable,o=e.slug;return t&&!r.includes(o)&&!o.includes("ct_")&&!o.includes("blc-")}))}),[t]);return{postTypesTaxonomiesMap:(0,l.useMemo)((function(){if(null!=o&&o.length)return o.reduce((function(e,t){return e[t.slug]=t.taxonomies,e}),{})}),[o]),postTypesSelectOptions:(0,l.useMemo)((function(){return(o||[]).reduce((function(e,t){return he(he({},e),{},r({},t.slug,t.labels.singular_name))}),{})}),[o])}}({hasPages:d}),b=f.postTypesSelectOptions,v=le({attributes:n,setAttributes:i,clientId:t,blockType:"blocksy/query"}),g=v.uniqueId,_=v.props,k=u.postId,w=(u.postType,(0,l.useRef)()),O=C((0,l.useState)(null),2),x=(O[0],O[1],(0,c.__experimentalUseBorderProps)(n)),E=(0,c.useBlockProps)({ref:w,className:o,style:$e({},x.style)}),S=C((0,l.useState)(!1),2),j=S[0],I=S[1];return(0,l.createElement)(React.Fragment,null,j&&(0,l.createElement)(We,{clientId:t,attributes:n,setIsPatternSelectionModalOpen:I,postType:n.post_type}),m?(0,l.createElement)("div",y({},E,_),(0,l.createElement)(ae,{setIsPatternSelectionModalOpen:I,attributes:n,setAttributes:i,clientId:t})):(0,l.createElement)("div",y({},E,_),"default"===n.design&&(0,l.createElement)(ne,{uniqueId:g,attributes:n,postId:k}),d&&(0,l.createElement)("div",p)),(0,l.createElement)(c.BlockControls,null,(0,l.createElement)(h.ToolbarGroup,null,(0,l.createElement)(h.ToolbarButton,{className:"components-toolbar__control",icon:"layout",label:(0,a.__)("Reset layout","blocksy-companion"),disabled:m,onClick:function(){d?(0,s.dispatch)("core/block-editor").replaceInnerBlocks(t,[],!1):(0,s.dispatch)("core/block-editor").updateBlockAttributes(t,{design:""})}}))),!m&&(0,l.createElement)(React.Fragment,null,(0,l.createElement)(c.InspectorControls,null,(0,l.createElement)(h.PanelBody,null,(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){i($e(r({},e,t),"post_type"===e?{include_term_ids:{},exclude_term_ids:{},include_post_ids:{ids:[],current_post:!1},exclude_post_ids:{ids:[],current_post:!1}}:{}))},options:{post_type:{type:"ct-select",label:(0,a.__)("Post Type","blocksy-companion"),value:"",defaultToFirstItem:!1,choices:b,purpose:"default"},limit:{type:"ct-number",label:(0,a.__)("Limit","blocksy-companion"),value:"",min:1,max:100},has_slideshow:{type:"ct-switch",label:(0,a.__)("Slideshow","blocksy-companion"),value:""},has_slideshow_condition:{type:"ct-condition",condition:{has_slideshow:"yes"},options:{has_slideshow_arrows:{type:"ct-switch",label:(0,a.__)("Arrows","blocksy-companion"),value:""},has_slideshow_autoplay:{type:"ct-switch",label:(0,a.__)("Autoplay","blocksy-companion"),value:""},has_slideshow_autoplay_condition:{type:"ct-condition",condition:{has_slideshow_autoplay:"yes"},options:{has_slideshow_autoplay_speed:{type:"ct-number",label:(0,a.__)("Autoplay Speed","blocksy-companion"),value:"",min:1,max:100}}}}},has_pagination_condition:{type:"ct-condition",condition:{has_slideshow:"no"},options:{has_pagination:{type:"ct-switch",label:(0,a.__)("Pagination","blocksy-companion"),value:""}}}},value:n,hasRevertButton:!1}))),(0,l.createElement)(Ne,{attributes:n,setAttributes:i,context:u})),(0,l.createElement)(c.InspectorControls,{group:"advanced"},(0,l.createElement)(h.TextControl,{__nextHasNoMarginBottom:!0,autoComplete:"off",label:(0,a.__)("Block ID","blocksy-companion"),value:g,onChange:function(e){},onFocus:function(e){e.target.select()},help:(0,a.__)("Please look at the documentation for more information on why this is useful.","blocksy-companion")})))},Xe=function(e){var t=c.useBlockProps.save(),o=c.useInnerBlocksProps.save(t);return(0,l.createElement)("div",o)},Je=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"blocksy/query","category":"blocksy-blocks","attributes":{"uniqueId":{"type":"string","default":""},"type":{"type":"string","default":"post"},"post_type":{"type":"string","default":"post"},"limit":{"type":"number","default":5},"include_term_ids":{"type":"object","default":{}},"exclude_term_ids":{"type":"object","default":{}},"include_post_ids":{"type":"object","default":{"ids":[],"current_post":false}},"exclude_post_ids":{"type":"object","default":{"ids":[],"current_post":false}},"order":{"type":"string","default":"desc"},"orderby":{"type":"string","default":"post_date"},"orderby_custom":{"type":"string","default":""},"offset":{"type":"number","default":0},"design":{"type":"string","default":""},"has_pagination":{"type":"string","default":"no"},"textColor":{"type":"string"},"customTextColor":{"type":"string"},"linkColor":{"type":"string"},"customLinkColor":{"type":"string"},"linkHoverColor":{"type":"string"},"customLinkHoverColor":{"type":"string"},"sticky_posts":{"type":"string","default":"include"},"has_slideshow":{"type":"string","default":"no"},"has_slideshow_arrows":{"type":"string","default":"yes"},"has_slideshow_autoplay":{"type":"string","default":"no"},"has_slideshow_autoplay_speed":{"type":"number","default":3}},"supports":{"align":["wide","full"],"html":false,"spacing":{"margin":true,"padding":true,"__experimentalDefaultControls":{"margin":false,"padding":false}},"__experimentalBorder":{"color":true,"radius":true,"width":true,"__experimentalDefaultControls":{"color":true,"radius":true,"width":true},"__experimentalSelector":"img, .block-editor-media-placeholder, .wp-block-post-featured-image__overlay","__experimentalSkipSerialization":true},"color":{"gradients":true,"link":false,"__experimentalDefaultControls":{"text":false,"background":true,"link":false}}},"usesContext":["postId","postType"],"providesContext":{"uniqueId":"uniqueId","post_type":"post_type","limit":"limit","order":"order","orderby":"orderby","sticky_posts":"sticky_posts","orderby_custom":"orderby_custom","offset":"offset","has_slideshow":"has_slideshow","has_slideshow_arrows":"has_slideshow_arrows","has_slideshow_autoplay":"has_slideshow_autoplay","has_slideshow_autoplay_speed":"has_slideshow_autoplay_speed","has_pagination":"has_pagination","include_term_ids":"include_term_ids","exclude_term_ids":"exclude_term_ids"}}');function Ye(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function Qe(e){for(var t=1;t *)"),variable:"margin-block-end",unit:"",responsive:!0},value:y});if(b){var _={desktop:"",tablet:"",mobile:""};Object.keys(_).forEach((function(e){_[e]=["[data-id='".concat(i,"']"),'[data-flexy="no"]',".flexy-item:nth-child(n + ".concat(parseFloat(v[e])+1,")")].join(" ")})),h.push({variables:{selector:_,variable:"height",responsive:!0},value:"1px"})}return h}({attributes:o,context:p})),T=(0,c.useBlockProps)({className:Y()(d,{"ct-query-template-grid":P&&!j,"ct-query-template-default":!P&&!j,"is-layout-flow":!P&&!j,"ct-query-template":j,"is-layout-slider":j}),"data-id":v}),D=q({attributes:p,previewedPostId:m}).blockData,A=W({isSlideshow:j,context:p,attributes:o,toWatch:D?D.all_posts:{}}),B=(0,s.useSelect)((function(e){return{blocks:(0,e(c.store).getBlocks)(t)}}),[t]).blocks;if(!D)return(0,l.createElement)("p",T,(0,l.createElement)(h.Spinner,null));var H=D.all_posts.map((function(e){return{postId:e.ID,postType:e.post_type}})),N=[{icon:yt,title:(0,a.__)("List view"),onClick:function(){u({layout:{type:"default"},tabletColumns:2,mobileColumns:1})},isActive:!P},{icon:ht,title:(0,a.__)("Grid view"),onClick:function(){u({layout:{type:"grid",columnCount:3},tabletColumns:2,mobileColumns:1})},isActive:P}],z=function(e){var t=e.isSlideshow,o=e.elementDescriptorForIndex;return(0,l.createElement)(React.Fragment,null,0===H.length&&(0,l.createElement)("p",null,(0,a.__)("No results found.","blocksy-companion")),H.length>0&&H.map((function(e,n){var r,a;return(0,l.createElement)(c.BlockContextProvider,{key:e.postId,value:e},e.postId===(_||(null===(r=H[0])||void 0===r?void 0:r.postId))?(0,l.createElement)(wt,{isSlideshow:t,elementDescriptor:o?o(n):null}):null,(0,l.createElement)(Ot,{blocks:B,blockContextId:e.postId,setActiveBlockContextId:k,isSlideshow:t,elementDescriptor:o?o(n):null,isHidden:e.postId===(_||(null===(a=H[0])||void 0===a?void 0:a.postId))}))})))};return(0,l.createElement)(React.Fragment,null,(0,l.createElement)(c.BlockControls,null,(0,l.createElement)(h.ToolbarGroup,{controls:N}),P?(0,l.createElement)(c.BlockVerticalAlignmentToolbar,{onChange:function(e){u({verticalAlignment:e})},value:i}):null),(0,l.createElement)(c.InspectorControls,null,P&&S?(0,l.createElement)(h.PanelBody,{title:"Layout",initialOpen:!0},(0,l.createElement)(vt,{label:(0,a.__)("Desktop Columns","blocksy-companion"),onChange:function(e){return u({layout:_t(_t({},r),{},{columnCount:e})})},value:E}),(0,l.createElement)(vt,{label:(0,a.__)("Tablet Columns","blocksy-companion"),onChange:function(e){return u({tabletColumns:e})},value:null==o?void 0:o.tabletColumns}),(0,l.createElement)(vt,{label:(0,a.__)("Mobile Columns","blocksy-companion"),onChange:function(e){return u({mobileColumns:e})},value:null==o?void 0:o.mobileColumns})):null),(0,l.createElement)("div",T,j?(0,l.createElement)("div",y({class:"flexy-container","data-flexy":"no"},A.flexyContainerAttr),(0,l.createElement)("div",{class:"flexy"},(0,l.createElement)("div",{class:"flexy-view","data-flexy-view":"boxed"},(0,l.createElement)("div",{class:"flexy-items"},z({isSlideshow:j,elementDescriptorForIndex:A.elementDescriptorForIndex}))),(0,l.createElement)(xt,{has_slideshow_arrows:"yes"===b,sliderDescriptor:A}))):z({isSlideshow:j})),D&&"yes"===p.has_pagination&&!j&&(0,l.createElement)(l.RawHTML,null,D.pagination_output),I||null)},Et=function(){return(0,l.createElement)(c.InnerBlocks.Content,null)},Pt=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"blocksy/post-template","parent":["blocksy/query"],"title":"Post Template","category":"theme","description":"Contains the block elements used to render a post, like the title, date, featured image, content or excerpt, and more.","textdomain":"default","supports":{"reusable":false,"html":false,"layout":false,"spacing":{"blockGap":{"__experimentalDefault":"1.25em"},"__experimentalDefaultControls":{"blockGap":true}}},"attributes":{"tabletColumns":{"type":"number","default":2},"mobileColumns":{"type":"number","default":1},"verticalAlignment":{"type":"string"},"layout":{"type":"object"}},"usesContext":["uniqueId","post_type","limit","order","orderby","orderby_custom","offset","postId","postType","has_slideshow","has_slideshow_arrows","has_slideshow_autoplay","has_slideshow_autoplay_speed","has_pagination","include_term_ids","exclude_term_ids","sticky_posts"]}');function St(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function jt(e){for(var t=1;t *)"),variable:"margin-block-end",unit:""},value:b});if(f){var g={desktop:"",tablet:"",mobile:""};Object.keys(g).forEach((function(e){g[e]=["[data-id='".concat(a,"']"),'[data-flexy="no"]',".flexy-item:nth-child(n + ".concat(parseFloat(h[e])+1,")")].join(" ")})),y.push({variables:{selector:g,variable:"height",responsive:!0},value:"1px"})}return y}({attributes:i,context:p})),I=(0,c.useBlockProps)({className:Y()(d,{"ct-query-template-grid":P&&!S,"ct-query-template-default":!P&&!S,"is-layout-flow":!P&&!S,"ct-query-template":S,"is-layout-slider":S}),"data-id":v}),T=et({attributes:p,previewedPostId:m}).blockData,D=W({isSlideshow:S,attributes:i,context:p,toWatch:T?T.all_terms:{}}),A=(0,s.useSelect)((function(e){return{blocks:(0,e(c.store).getBlocks)(t)}}),[t]).blocks;if(!T)return(0,l.createElement)("p",I,(0,l.createElement)(h.Spinner,null));var B=T.all_terms.map((function(e){return{termId:e.term_id,termIcon:null==e?void 0:e.icon,termImage:null==e?void 0:e.image}})),H=[{icon:yt,title:(0,a.__)("List view"),onClick:function(){u({layout:{type:"default"},tabletColumns:2,mobileColumns:1})},isActive:!P},{icon:ht,title:(0,a.__)("Grid view"),onClick:function(){u({layout:{type:"grid",columnCount:3},tabletColumns:2,mobileColumns:1})},isActive:P}],N=function(e){var t=e.isSlideshow,o=e.elementDescriptorForIndex;return(0,l.createElement)(React.Fragment,null,0===B.length&&(0,l.createElement)("p",null,(0,a.__)("No results found.","blocksy-companion")),B.length>0&&B.map((function(e,n){var r,a;return(0,l.createElement)(c.BlockContextProvider,{key:e.termId,value:e},e.termId===(_||(null===(r=B[0])||void 0===r?void 0:r.termId))?(0,l.createElement)(At,{isSlideshow:t,termId:e.termId,elementDescriptor:o?o(n):null}):null,(0,l.createElement)(Bt,{blocks:A,blockContextId:e.termId,setActiveBlockContextId:k,isSlideshow:t,termId:e.termId,elementDescriptor:o?o(n):null,isHidden:e.termId===(_||(null===(a=B[0])||void 0===a?void 0:a.termId))}))})))};return(0,l.createElement)(React.Fragment,null,(0,l.createElement)(c.BlockControls,null,(0,l.createElement)(h.ToolbarGroup,{controls:H}),P?(0,l.createElement)(c.BlockVerticalAlignmentToolbar,{onChange:function(e){u({verticalAlignment:e})},value:r}):null),(0,l.createElement)(c.InspectorControls,null,P?(0,l.createElement)(h.PanelBody,{title:"Layout",initialOpen:!0},(0,l.createElement)(vt,{label:(0,a.__)("Desktop Columns","blocksy-companion"),onChange:function(e){return u({layout:Tt(Tt({},n),{},{columnCount:e})})},value:E}),(0,l.createElement)(vt,{label:(0,a.__)("Tablet Columns","blocksy-companion"),onChange:function(e){return u({tabletColumns:e})},value:null==i?void 0:i.tabletColumns}),(0,l.createElement)(vt,{label:(0,a.__)("Mobile Columns","blocksy-companion"),onChange:function(e){return u({mobileColumns:e})},value:null==i?void 0:i.mobileColumns})):null),(0,l.createElement)("div",I,S?(0,l.createElement)("div",y({class:"flexy-container","data-flexy":"no"},D.flexyContainerAttr),(0,l.createElement)("div",{class:"flexy"},(0,l.createElement)("div",{class:"flexy-view","data-flexy-view":"boxed"},(0,l.createElement)("div",{class:"flexy-items"},N({isSlideshow:S,elementDescriptorForIndex:D.elementDescriptorForIndex}))),(0,l.createElement)(xt,{has_slideshow_arrows:"yes"===b,sliderDescriptor:D}))):N({isSlideshow:S})),j||null)},Nt=function(){return(0,l.createElement)(c.InnerBlocks.Content,null)},zt=JSON.parse('{"$schema":"https://schemas.wp.org/trunk/block.json","apiVersion":3,"name":"blocksy/tax-template","parent":["blocksy/tax-query"],"title":"Tax Template","category":"theme","description":"Contains the block elements used to render a taxonomy, like the title, date, featured image, content or excerpt, and more.","textdomain":"default","supports":{"reusable":false,"html":false,"layout":false,"spacing":{"blockGap":{"__experimentalDefault":"1.25em"},"__experimentalDefaultControls":{"blockGap":true}}},"attributes":{"tabletColumns":{"type":"number","default":2},"mobileColumns":{"type":"number","default":1},"verticalAlignment":{"type":"string"},"layout":{"type":"object"}},"usesContext":["uniqueId","taxonomy","level","limit","hide_empty","order","orderby","offset","include_term_ids","exclude_term_ids","has_slideshow","has_slideshow_arrows","has_slideshow_autoplay","has_slideshow_autoplay_speed"]}');function Mt(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function Ft(e){for(var t=1;t/g,"\n")).trim().replace(/\n\n+/g,"\n\n")}var an=function(e){var t=e.attributes.has_field_link,o=e.postId,n=e.postType,r=C((0,be.useEntityProp)("postType",n,"title",o),3),a=r[0],i=void 0===a?"":a;r[1],r[2];return o?i?"yes"===t?(0,l.createElement)("a",{href:"#",rel:"noopener noreferrer"},ln(i)):ln(i):null:"Title"},cn=function(e){if(!e)return"";var t=(new window.DOMParser).parseFromString(e,"text/html");return t.body.textContent||t.body.innerText||""},sn=function(e){var t=e.attributes.excerpt_length,o=e.postId,n=e.postType,r=e.fallback,a=C((0,be.useEntityProp)("postType",n,"excerpt",o),3),i=a[0],c=(a[1],a[2]),s=(c=void 0===c?{}:c).rendered,u=(c.protected,C((0,be.useEntityProp)("postType",n,"content",o),3)),p=(u[0],u[1],u[2]),d=(p=void 0===p?{}:p).rendered,m=(i||cn(s)||cn(d)).trim(),f=m.split(" ",t).join(" "),b=f!==m?"...":"";return o?f?(0,l.createElement)(l.RawHTML,null,f,b):r:"Excerpt"},un=window.wp.date,pn=function(e){var t=e.postId,o=e.postType,n=e.attributes,r=n.date_type,a=n.default_format,i=n.date_format,c=n.custom_date_format,s=n.has_field_link,u=C((0,be.useEntityProp)("postType",o,"published"===r?"date":"modified",t),1)[0],p="yes"===a?(0,un.getSettings)().formats.date:"custom"!==i?i:c,d=(0,l.createElement)("span",null,(0,un.format)(p,u));return t?(s&&(d=(0,l.createElement)("a",{href:"#"},d)),d):"Date"},dn=window.wp.apiFetch,mn=n.n(dn),fn=window.wp.url,bn={},yn=function(e){var t=e.postId,o=C((0,l.useState)(null),2),n=o[0],r=o[1];return(0,l.useEffect)((function(){bn[t]&&r(bn[t]),bn[t]||mn()({path:(0,fn.addQueryArgs)("/wp/v2/comments",{post:t,_fields:"id"}),method:"HEAD",parse:!1}).then((function(e){var o={total:parseInt(e.headers.get("X-WP-Total"))};r(o),bn[t]=o}))}),[t]),{commentsData:n}},hn=function(e){var t=e.postId,o=(e.postType,e.attributes),n=o.has_field_link,r=o.zero_text,a=o.single_text,i=o.multiple_text,c=yn({postId:t}).commentsData,s=c&&c.total?c.total:0,u=0===s?r:1===s?a:i;return"yes"===n?(0,l.createElement)("a",{href:"#",rel:"noopener noreferrer"},u.replace("%",s)):u.replace("%",s)},vn=function(e,t){switch(t){case"email":return(null==e?void 0:e.email)||"";case"nicename":return(null==e?void 0:e.nickname)||"";case"display_name":return(null==e?void 0:e.name)||"";case"first_name":return(null==e?void 0:e.first_name)||"";case"last_name":return(null==e?void 0:e.last_name)||"";case"description":return(null==e?void 0:e.description)||""}},gn=function(e){var t=e.postId,o=e.postType,n=e.attributes,r=n.has_field_link,a=n.author_field,i=e.fallback,c=(e.fieldsDescriptor,(0,s.useSelect)((function(e){var n,r=e(be.store),l=r.getEditedEntityRecord,a=r.getUser,i=(r.getUsers,null===(n=l("postType",o,t))||void 0===n?void 0:n.author);return{authorId:i,authorDetails:i?a(i):null}}),[o,t])),u=(c.authorId,c.authorDetails);return t?u?"yes"===r?(0,l.createElement)("a",{href:"#",rel:"noopener noreferrer"},vn(u,a)||i):vn(u,a)||i:null:"Author: ".concat(a)},_n=function(e){var t,o=e.postId,n=e.postType,a=e.fallback,i=e.attributes,c=e.attributes,u=c.has_field_link,p=c.taxonomy,d=c.separator,m=(e.fieldsDescriptor,_e(n)),f=(0,s.useSelect)((function(e){return{terms:e("core").getEntityRecords("taxonomy",p||(m&&m.length>0?m[0].slug:""),{per_page:-1,post:o})||[]}})).terms,b=(null===(t=m.find((function(e){return e.slug===p})))||void 0===t?void 0:t.name)||"Category";if(!o)return"".concat(b);if(0===f.length)return a||"".concat(b);var h="span",v={};return"yes"===u&&(h="a",v.href="#",v.rel="noopener noreferrer"),f.map((function(e,t){return(0,l.createElement)(React.Fragment,null,(0,l.createElement)(h,y({},v,{className:Y()(r({},"ct-term-".concat(e.id),"yes"===i.termAccentColor),i.termClass),dangerouslySetInnerHTML:{__html:e.name}})),t!==f.length-1?d.replace(/ /g," "):"")}))},kn={x:.5,y:.5};function wn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:kn,t=e.x,o=e.y;return"".concat(Math.round(100*t),"% ").concat(Math.round(100*o),"%")}var On=function(e){var t=e.attributes,o=e.url,n=t.hasParallax,r=t.focalPoint,a=t.alt,i=o?"url(".concat(o,")"):void 0,c=wn(r);return o?n?(0,l.createElement)("div",{role:a?"img":void 0,"aria-label":a||void 0,className:Y()("wp-block-cover__image-background",{"has-parallax":n}),style:{backgroundImage:i,backgroundPosition:c}}):(0,l.createElement)("img",{alt:a,className:Y()("wp-block-cover__image-background",{"has-parallax":n}),src:o,style:{objectPosition:r?wn(r):void 0}}):(0,l.createElement)("div",{className:Y()("ct-dynamic-data-placeholder",{})},(0,l.createElement)("svg",{fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 60 60",preserveAspectRatio:"none",className:"ct-dynamic-data-placeholder-illustration","aria-hidden":"true",focusable:"false"},(0,l.createElement)("path",{vectorEffect:"non-scaling-stroke",d:"M60 60 0 0"})))};var xn=function(){return xn=Object.assign||function(e){for(var t,o=1,n=arguments.length;o1&&void 0!==arguments[1]?arguments[1]:{},o=t.additionalRules,n=E(t,["additionalRules"]),r=[].concat(P((0,In.getCSSRules)(e,n)),P(o||[]));if(null==n||!n.selector){var l=[];return r.forEach((function(e){l.push("".concat(Hn(e.key),": ").concat(e.value,";"))})),l.join(" ")}var a=r.reduce((function(e,t){var o=t.selector;return o?(e[o]||(e[o]=[]),e[o].push(t),e):e}),{});return Object.keys(a).reduce((function(e,t){return e.push("".concat(t," { ").concat(a[t].map((function(e){return"".concat(Hn(e.key),": ").concat(e.value,";")})).join(" ")," }")),e}),[]).join("\n")}function Bn(e,t){var o=C((0,c.useSettings)("background.backgroundImage","background.backgroundSize","typography.fontFamilies.custom","typography.fontFamilies.default","typography.fontFamilies.theme","typography.defaultFontSizes","typography.fontSizes.custom","typography.fontSizes.default","typography.fontSizes.theme","typography.customFontSize","typography.fontStyle","typography.fontWeight","typography.lineHeight","typography.textAlign","typography.textColumns","typography.textDecoration","typography.writingMode","typography.textTransform","typography.letterSpacing","spacing.padding","spacing.margin","spacing.blockGap","spacing.defaultSpacingSizes","spacing.customSpacingSize","spacing.spacingSizes.custom","spacing.spacingSizes.default","spacing.spacingSizes.theme","spacing.units","dimensions.aspectRatio","dimensions.minHeight","layout","border.color","border.radius","border.style","border.width","color.custom","color.palette.custom","color.customDuotone","color.palette.theme","color.palette.default","color.defaultPalette","color.defaultDuotone","color.duotone.custom","color.duotone.theme","color.duotone.default","color.gradients.custom","color.gradients.theme","color.gradients.default","color.defaultGradients","color.customGradient","color.background","color.link","color.text","color.heading","color.button","shadow"),56),n=o[0],r=o[1],a=o[2],i=o[3],s=o[4],u=o[5],p=o[6],d=o[7],m=o[8],f=o[9],b=o[10],y=o[11],h=o[12],v=o[13],g=o[14],_=o[15],k=o[16],w=o[17],O=o[18],x=o[19],E=o[20],P=o[21],S=o[22],j=o[23],I=o[24],T=o[25],D=o[26],A=o[27],B=o[28],H=o[29],N=o[30],z=o[31],M=o[32],F=o[33],R=o[34],V=o[35],L=o[36],U=o[37],q=o[38],G=o[39],W=o[40],Z=o[41],$=o[42],K=o[43],X=o[44],J=o[45],Y=o[46],Q=o[47],ee=o[48],te=o[49],oe=o[50],ne=o[51],re=o[52],le=o[53],ae=o[54],ie=o[55];return(0,l.useMemo)((function(){return{background:{backgroundImage:n,backgroundSize:r},color:{palette:{custom:L,theme:q,default:G},gradients:{custom:J,theme:Y,default:Q},duotone:{custom:$,theme:K,default:X},defaultGradients:ee,defaultPalette:W,defaultDuotone:Z,custom:V,customGradient:te,customDuotone:U,background:oe,link:ne,heading:le,button:ae,text:re},typography:{fontFamilies:{custom:a,default:i,theme:s},fontSizes:{custom:p,default:d,theme:m},customFontSize:f,defaultFontSizes:u,fontStyle:b,fontWeight:y,lineHeight:h,textAlign:v,textColumns:g,textDecoration:_,textTransform:w,letterSpacing:O,writingMode:k},spacing:{spacingSizes:{custom:I,default:T,theme:D},customSpacingSize:j,defaultSpacingSizes:S,padding:x,margin:E,blockGap:P,units:A},border:{color:z,radius:M,style:F,width:R},dimensions:{aspectRatio:B,minHeight:H},layout:N,parentLayout:t,shadow:ie}}),[n,r,a,i,s,u,p,d,m,f,b,y,h,v,g,_,w,O,k,x,E,P,S,j,I,T,D,A,B,H,N,t,z,M,F,R,V,L,U,q,G,W,Z,$,K,X,J,Y,Q,ee,te,oe,ne,re,le,ae,ie])}function Hn(e){var t,o,n=null!==(t=null==e||null===(o=e.toString)||void 0===o?void 0:o.call(e))&&void 0!==t?t:"";return function(e,t){return void 0===t&&(t={}),jn(e,xn({delimiter:"-"},t))}(n=n.replace(/['\u2019]/,""),{splitRegexp:[/(?!(?:1ST|2ND|3RD|[4-9]TH)(?![a-z]))([a-z0-9])([A-Z])/g,/(?!(?:1st|2nd|3rd|[4-9]th)(?![a-z]))([0-9])([a-z])/g,/([A-Za-z])([0-9])/g,/([A-Z])([A-Z][a-z])/g]})}function Nn(e,t){if(e&&t)return"has-".concat(Hn(t),"-").concat(e)}var zn=function t(o){if(null===o||"object"!==e(o)||Array.isArray(o))return o;var n=Object.entries(o).map((function(e){var o=C(e,2),n=o[0],r=o[1];return[n,t(r)]})).filter((function(e){return void 0!==C(e,2)[1]}));return n.length?Object.fromEntries(n):void 0};function Mn(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t={};return(0,In.getCSSRules)(e).forEach((function(e){t[e.key]=e.value})),t}var Fn={link:"a",overlay:".wp-block-cover__background"};function Rn(e,t){if(!e||!t)return t;var o=e.split(","),n=t.split(","),r=[];return o.forEach((function(e){n.forEach((function(t){r.push("".concat(e.trim()," ").concat(t.trim()))}))})),r.join(", ")}var Vn=function(e){var t=e.fieldType,o=e.attributes,n=e.uniqueClass,a=C((0,c.useSettings)("color.palette.custom","color.palette.theme","color.palette.default"),3),i=a[0],s=a[1],u=a[2],p=((0,l.useMemo)((function(){return[].concat(P(i||[]),P(s||[]),P(u||[]))}),[i,s,u]),o.style),d=function(e,t,o,n){var r=[{elementType:"link",pseudo:[":hover"]}];"image"===o&&r.push({elementType:"overlay",additionalRules:function(e,t){return[{selector:e,key:"opacity",value:parseFloat(t.dimRatio)/100}]}});var a=".".concat(n),i=null==e?void 0:e.elements;return{className:n,styles:(0,l.useMemo)((function(){if(i){var e=[];return r.forEach((function(o){var n=o.elementType,r=o.pseudo,l=(o.elements,o.additionalRules),c=null==i?void 0:i[n];if(c){var s=Rn(a,Fn[n]),u=An(c,{selector:s,additionalRules:l?l(s,t):[]});e.push(u),r&&r.forEach((function(t){c[t]&&e.push(An(c[t],{selector:Rn(a,"".concat(Fn[n]).concat(t))}))}))}})),e.length>0?e.join(""):void 0}}),[a,i,t])}}(p,o,t,n);if("text"===t){var m,f,b,y,h,v,g=o.backgroundColor,_=o.textColor,k=Nn("background-color",g),w=Nn("color",_),O=g||(null==p||null===(m=p.color)||void 0===m?void 0:m.background);g||(null==p||null===(f=p.color)||void 0===f||f.background);return{className:Y()(w,d.className,(v={},r(v,k,!!k),r(v,"has-background",O),r(v,"has-text-color",_||(null==p||null===(b=p.color)||void 0===b?void 0:b.text)),r(v,"has-link-color",null==p||null===(y=p.elements)||void 0===y||null===(h=y.link)||void 0===h?void 0:h.color),v)),style:Mn(p),css:d.styles}}return{className:Y()(d.className,{}),style:"",css:d.styles}};function Ln(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function Un(e){for(var t=1;t .wp-block-cover__inner-container > :where(:not(.alignleft):not(.alignright):not(.alignfull)) {\n\t\t\t\t\t\t\t\t\t\tmax-width: ").concat(B,";\n\t\t\t\t\t\t\t\t\t}"):"","\n\n\t\t\t\t\t\t\t").concat(H?"#".concat(j.id," > .wp-block-cover__inner-container > .alignwide {\n\t\t\t\t\t\t\t\t\t\t\tmax-width: ").concat(H,";\n\t\t\t\t\t\t\t\t\t\t}"):"","\n\t\t\t\t\t\t"),T.css),(0,l.createElement)(On,{attributes:i,url:n}),(0,l.createElement)("span",{"aria-hidden":"true",className:Y()("wp-block-cover__background",r({"wp-block-cover__gradient-background":!!P,"has-background-gradient":!!P},S,!!S)),style:{background:P}}),(0,l.createElement)("div",N));var M=(0,l.createElement)("img",{className:z?"":x.className,style:Un(Un({},z?{}:x.style),D),src:n,loading:"lazy"});return n&&a||(M=(0,l.createElement)("div",{className:Y()("ct-dynamic-data-placeholder",r({},x.className,!z)),style:Un(Un({},z?{}:x.style),D)},(0,l.createElement)("svg",{fill:"none",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 60 60",preserveAspectRatio:"none",className:"ct-dynamic-data-placeholder-illustration","aria-hidden":"true",focusable:"false"},(0,l.createElement)("path",{vectorEffect:"non-scaling-stroke",d:"M60 60 0 0"})))),z&&(M=(0,l.createElement)("span",{"data-hover":b,className:"ct-dynamic-media-inner ".concat(x.className),style:Un({},x.style)},M,null!=o&&o.has_video&&"yes"===h?(0,l.createElement)(qn,null):null)),(0,l.createElement)("figure",j,M,null!=o&&o.has_video&&"yes"===h?(0,l.createElement)(qn,null):null)},Wn=n(649),Zn=n.n(Wn);n(975);Zn()(console.error);var $n,Kn,Xn,Jn;$n={"(":9,"!":8,"*":7,"/":7,"%":7,"+":6,"-":6,"<":5,"<=":5,">":5,">=":5,"==":4,"!=":4,"&&":3,"||":2,"?":1,"?:":1},Kn=["(","?"],Xn={")":["("],":":["?","?:"]},Jn=/<=|>=|==|!=|&&|\|\||\?:|\(|!|\*|\/|%|\+|-|<|>|\?|\)|:/;var Yn={"!":function(e){return!e},"*":function(e,t){return e*t},"/":function(e,t){return e/t},"%":function(e,t){return e%t},"+":function(e,t){return e+t},"-":function(e,t){return e-t},"<":function(e,t){return e":function(e,t){return e>t},">=":function(e,t){return e>=t},"==":function(e,t){return e===t},"!=":function(e,t){return e!==t},"&&":function(e,t){return e&&t},"||":function(e,t){return e||t},"?:":function(e,t,o){if(e)throw t;return o}};function Qn(e){var t=function(e){for(var t,o,n,r,l=[],a=[];t=e.match(Jn);){for(o=t[0],(n=e.substr(0,t.index).trim())&&l.push(n);r=a.pop();){if(Xn[o]){if(Xn[o][0]===r){o=Xn[o][1]||o;break}}else if(Kn.indexOf(r)>=0||$n[r]<$n[o]){a.push(r);break}l.push(r)}Xn[o]||a.push(o),e=e.substr(t.index+o.length)}return(e=e.trim())&&l.push(e),l.concat(a.reverse())}(e);return function(e){return function(e,t){var o,n,r,l,a,i,c=[];for(o=0;o1===e?0:1},nr=/^i18n\.(n?gettext|has_translation)(_|$)/;const rr=((e,t,o)=>{const n=new tr({}),r=new Set,l=()=>{r.forEach((e=>e()))},a=function(e){var t;let o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";n.data[o]={...n.data[o],...e},n.data[o][""]={...or,...null===(t=n.data[o])||void 0===t?void 0:t[""]},delete n.pluralForms[o]},i=(e,t)=>{a(e,t),l()},c=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1?arguments[1]:void 0,o=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,l=arguments.length>4?arguments[4]:void 0;return n.data[e]||a(void 0,e),n.dcnpgettext(e,t,o,r,l)},s=function(){return arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default"},u=(e,t,n)=>{let r=c(n,t,e);return o?(r=o.applyFilters("i18n.gettext_with_context",r,e,t,n),o.applyFilters("i18n.gettext_with_context_"+s(n),r,e,t,n)):r};if(e&&i(e,t),o){const e=e=>{nr.test(e)&&l()};o.addAction("hookAdded","core/i18n",e),o.addAction("hookRemoved","core/i18n",e)}return{getLocaleData:function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default";return n.data[e]},setLocaleData:i,addLocaleData:function(e){var t;let o=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";n.data[o]={...n.data[o],...e,"":{...or,...null===(t=n.data[o])||void 0===t?void 0:t[""],...null==e?void 0:e[""]}},delete n.pluralForms[o],l()},resetLocaleData:(e,t)=>{n.data={},n.pluralForms={},i(e,t)},subscribe:e=>(r.add(e),()=>r.delete(e)),__:(e,t)=>{let n=c(t,void 0,e);return o?(n=o.applyFilters("i18n.gettext",n,e,t),o.applyFilters("i18n.gettext_"+s(t),n,e,t)):n},_x:u,_n:(e,t,n,r)=>{let l=c(r,void 0,e,t,n);return o?(l=o.applyFilters("i18n.ngettext",l,e,t,n,r),o.applyFilters("i18n.ngettext_"+s(r),l,e,t,n,r)):l},_nx:(e,t,n,r,l)=>{let a=c(l,r,e,t,n);return o?(a=o.applyFilters("i18n.ngettext_with_context",a,e,t,n,r,l),o.applyFilters("i18n.ngettext_with_context_"+s(l),a,e,t,n,r,l)):a},isRTL:()=>"rtl"===u("ltr","text direction"),hasTranslation:(e,t,r)=>{var l,a;const i=t?t+""+e:e;let c=!(null===(l=n.data)||void 0===l||null===(a=l[null!=r?r:"default"])||void 0===a||!a[i]);return o&&(c=o.applyFilters("i18n.has_translation",c,e,t,r),c=o.applyFilters("i18n.has_translation_"+s(r),c,e,t,r)),c}}})(void 0,void 0,window.wp.hooks.defaultHooks);rr.getLocaleData.bind(rr),rr.setLocaleData.bind(rr),rr.resetLocaleData.bind(rr),rr.subscribe.bind(rr);const lr=rr.__.bind(rr);rr._x.bind(rr),rr._n.bind(rr),rr._nx.bind(rr),rr.isRTL.bind(rr),rr.hasTranslation.bind(rr);function ar(e){var t=e.postId,o=e.postType,n=(0,s.useSelect)((function(e){var n,r=e(be.store),l=r.getEditedEntityRecord,a=r.getUser,i=null===(n=l("postType",o,t))||void 0===n?void 0:n.author;return{authorDetails:i?a(i):null}}),[o,t]).authorDetails,r=null!=n&&n.avatar_urls?Object.values(n.avatar_urls):null,l=(null!=n&&n.avatar_urls&&Object.keys(n.avatar_urls),(0,s.useSelect)((function(e){return(0,e(c.store).getSettings)().__experimentalDiscussionSettings})).avatarURL);return{src:r?r[r.length-1]:l}}function ir(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function cr(e){for(var t=1;t0&&void 0!==arguments[0]?arguments[0]:{}).termId,t=document.body.classList.contains("post-type-ct_content_block"),o=[];return e&&(o=[{id:"term_title",label:(0,a.__)("Term Title","blocksy-companion")},{id:"term_description",label:(0,a.__)("Term Description","blocksy-companion")},{id:"term_image",label:(0,a.__)("Term Image","blocksy-companion")},{id:"term_count",label:(0,a.__)("Term Count","blocksy-companion")}]),e||(o=[{id:"title",label:(0,a.__)("Title","blocksy-companion")},{id:"excerpt",label:(0,a.__)("Excerpt","blocksy-companion")},{id:"date",label:(0,a.__)("Post Date","blocksy-companion")},{id:"comments",label:(0,a.__)("Comments","blocksy-companion")},{id:"terms",label:(0,a.__)("Terms","blocksy-companion")},{id:"author",label:(0,a.__)("Author","blocksy-companion")},{id:"featured_image",label:(0,a.__)("Featured Image","blocksy-companion")},{id:"author_avatar",label:(0,a.__)("Author Avatar","blocksy-companion")}]),!e&&t&&(o=[].concat(P(o),[{id:"archive_title",label:(0,a.__)("Archive Title","blocksy-companion")},{id:"archive_description",label:(0,a.__)("Archive Description","blocksy-companion")},{id:"archive_image",label:(0,a.__)("Archive Image","blocksy-companion")}])),{provider:"wp",fields:o}},Lr=function(e){var t=e.postId,o=e.postType,n=e.termId,r=(e.taxonomy,_e(o)),i=C((0,l.useState)([]),2),c=i[0],s=i[1];(0,l.useEffect)((function(){t&&!n&&U("".concat(wp.ajax.settings.url,"?action=blocksy_blocks_retrieve_dynamic_data_descriptor"),{post_id:t}).then((function(e){return e.json()})).then((function(e){e.success;var t=e.data;s(t.fields)}))}),[t,n]);var u={fields:[Vr({termId:n})]},p=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(void 0===window.wc||"product"!==e)return null;var o=(t||[]).find((function(e){return"product_brands"===e.slug}));return{provider:"woo",fields:[{id:"price",label:(0,a.__)("Price","blocksy-companion")},{id:"rating",label:(0,a.__)("Rating","blocksy-companion")},{id:"stock_status",label:(0,a.__)("Stock Status","blocksy-companion")},{id:"sku",label:(0,a.__)("SKU","blocksy-companion")}].concat(P(o?[{id:"brands",label:(0,a.__)("Brands","blocksy-companion")}]:[]))}}(o,r);return p&&u.fields.push(p),c.length>0&&(u.fields=[].concat(P(u.fields),P(c))),{fieldsDescriptor:u,options:Rr,fieldsChoices:u.fields.reduce((function(e,t){return[].concat(P(e),P(t.fields.filter((function(e){return"wp"!==t.provider||"terms"!==e.id||r&&r.length>0})).map((function(e){return{group:(o=t.provider,{wp:"WordPress",woo:"WooCommerce",acf:"ACF",metabox:"MetaBox",custom:(0,a.__)("Custom","blocksy-companion"),toolset:"Toolset",jetengine:"Jet Engine",pods:"Pods",acpt:"ACPT"}[o]||(0,a.__)("Unknown","blocksy-companion")),key:"".concat(t.provider,":").concat(e.id),value:e.label};var o}))))}),[])}},Ur=function(e){var t=e.sizeSlug,o=e.onChange,n=e.clientId,r=(0,s.useSelect)((function(e){return e(c.store).getSettings().imageSizes}),[]).map((function(e){var t=e.name;return{value:e.slug,label:t}}));return r.length?(0,l.createElement)(h.__experimentalToolsPanelItem,{hasValue:function(){return!!t},label:(0,a.__)("Resolution","blocksy-companion"),onDeselect:function(){return o(void 0)},resetAllFilter:function(){return{sizeSlug:void 0}},isShownByDefault:!1,key:n},(0,l.createElement)(h.SelectControl,{__nextHasNoMarginBottom:!0,label:(0,a.__)("Resolution","blocksy-companion"),value:t||"full",options:r,onChange:function(e){return o(e)},help:(0,a.__)("Select the size of the source image.","blocksy-companion")})):null},qr=function(e){var t=e.clientId,o=e.attributes,n=o.aspectRatio,i=o.imageFit,s=o.width,u=o.height,p=o.sizeSlug,d=o.viewType,m=o.minimumHeight,f=e.setAttributes,b=(0,h.__experimentalUseCustomUnits)({availableUnits:(0,c.useSetting)("spacing.units")||["px","%","vw","em","rem"]}),y=function(e,t){var o=parseFloat(t);isNaN(o)&&t||f(r({},e,o<0?"0":t))};return(0,l.createElement)(h.__experimentalToolsPanel,{label:"cover"===d?(0,a.__)("Block Settings","blocksy-companion"):(0,a.__)("Image Settings","blocksy-companion"),resetAll:function(){f({aspectRatio:"auto",width:void 0,height:void 0,sizeSlug:void 0,minimumHeight:void 0})}},(0,l.createElement)(h.__experimentalToolsPanelItem,{hasValue:function(){return!!n},label:(0,a.__)("Aspect Ratio","blocksy-companion"),onDeselect:function(){return f({aspectRatio:void 0})},resetAllFilter:function(){return{aspectRatio:"auto"}},isShownByDefault:!0,key:t},(0,l.createElement)(h.SelectControl,{__nextHasNoMarginBottom:!0,label:(0,a.__)("Aspect Ratio","blocksy-companion"),value:n,options:[{label:(0,a.__)("Original","blocksy-companion"),value:"auto"},{label:(0,a.__)("Square","blocksy-companion"),value:"1"},{label:(0,a.__)("16:9","blocksy-companion"),value:"16/9"},{label:(0,a.__)("4:3","blocksy-companion"),value:"4/3"},{label:(0,a.__)("3:2","blocksy-companion"),value:"3/2"},{label:(0,a.__)("9:16","blocksy-companion"),value:"9/16"},{label:(0,a.__)("3:4","blocksy-companion"),value:"3/4"},{label:(0,a.__)("2:3","blocksy-companion"),value:"2/3"}],onChange:function(e){return f({aspectRatio:e,minimumHeight:void 0})}})),"cover"!==d?(0,l.createElement)(React.Fragment,null,(0,l.createElement)(h.__experimentalToolsPanelItem,{style:{"grid-column":"span 1 / auto"},hasValue:function(){return!!s},label:(0,a.__)("Width","blocksy-companion"),onDeselect:function(){return f({width:void 0})},resetAllFilter:function(){return{width:void 0}},isShownByDefault:!0,key:t},(0,l.createElement)(h.__experimentalUnitControl,{label:(0,a.__)("Width","blocksy-companion"),labelPosition:"top",value:s||"",min:0,onChange:function(e){return y("width",e)},units:b})),(0,l.createElement)(h.__experimentalToolsPanelItem,{style:{"grid-column":"span 1 / auto"},hasValue:function(){return!!u},label:(0,a.__)("Height","blocksy-companion"),onDeselect:function(){return f({height:void 0})},resetAllFilter:function(){return{height:void 0}},isShownByDefault:!0,key:t},(0,l.createElement)(h.__experimentalUnitControl,{label:(0,a.__)("Height","blocksy-companion"),labelPosition:"top",value:u||"",min:0,onChange:function(e){return y("height",e)},units:b})),(0,l.createElement)(h.__experimentalToolsPanelItem,{hasValue:function(){return!!i},label:(0,a.__)("Scale","blocksy-companion"),onDeselect:function(){return f({imageFit:void 0})},resetAllFilter:function(){return{imageFit:"cover"}},isShownByDefault:!0,key:t},(0,l.createElement)(h.__experimentalToggleGroupControl,{label:(0,a.__)("Scale","blocksy-companion"),value:i,isBlock:!0,onChange:function(e){return f({imageFit:e})}},(0,l.createElement)(h.__experimentalToggleGroupControlOption,{key:"cover",value:"cover",label:(0,a.__)("Cover","blocksy-companion")}),(0,l.createElement)(h.__experimentalToggleGroupControlOption,{key:"contain",value:"contain",label:(0,a.__)("Contain","blocksy-companion")})))):null,"cover"===d?(0,l.createElement)(h.__experimentalToolsPanelItem,{hasValue:function(){return!!m},label:(0,a.__)("Minimum height"),onDeselect:function(){return f({minimumHeight:void 0})},isShownByDefault:!0},(0,l.createElement)(h.__experimentalUnitControl,{__next40pxDefaultSize:!0,label:(0,a.__)("Minimum height"),labelPosition:"top",value:m||"",onChange:function(e){e=0>parseFloat(e)?"0":e,f({minimumHeight:e,aspectRatio:"auto"})},units:b})):(0,l.createElement)(Ur,{sizeSlug:p,onChange:function(e){return f({sizeSlug:e})},clientId:t}))};function Gr(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}var Wr=function(){return(0,l.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true",focusable:"false"},(0,l.createElement)("path",{d:"M19 5.5H5V4h14v1.5ZM19 20H5v-1.5h14V20ZM5 9h14v6H5V9Z"}))},Zr=function(){return(0,l.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",width:"24",height:"24","aria-hidden":"true",focusable:"false"},(0,l.createElement)("path",{d:"M16 5.5H8V4h8v1.5ZM16 20H8v-1.5h8V20ZM5 9h14v6H5V9Z"}))},$r=function(e){var t=e.clientId,o=e.postType,n=e.postId,a=e.attributes,i=e.setAttributes,u=a.focalPoint,p=a.hasParallax,d=a.isRepeated,m=a.sizeSlug,f=a.allowCustomContentAndWideSize,b=a.contentSize,y=a.wideSize,v=C((0,be.useEntityProp)("postType",o,"featured_media",n),2),g=v[0],_=(v[1],function(e,t){var o,n,r;return(null==e||null===(o=e.media_details)||void 0===o||null===(n=o.sizes)||void 0===n||null===(r=n[t])||void 0===r?void 0:r.source_url)||(null==e?void 0:e.source_url)}((0,s.useSelect)((function(e){var t=e(be.store).getMedia;return{media:g&&t(g,{context:"view"})}}),[g]).media,m)),k=!p,w=(0,h.__experimentalUseCustomUnits)({availableUnits:(0,c.useSetting)("spacing.units")||["px","%","vw","em","rem"]});return"cover"!==a.viewType?null:(0,l.createElement)(React.Fragment,null,(0,l.createElement)(h.__experimentalToolsPanel,{label:lr("Layout"),resetAll:function(){i({hasParallax:!1,focalPoint:void 0,isRepeated:!1})}},(0,l.createElement)(h.__experimentalToolsPanelItem,{label:lr("Layout"),isShownByDefault:!0,hasValue:function(){return!f},onDeselect:function(){return i({allowCustomContentAndWideSize:!0,contentSize:void 0,wideSize:void 0})}},(0,l.createElement)(h.__experimentalVStack,{spacing:4,className:"block-editor-hooks__layout-constrained"},(0,l.createElement)(h.ToggleControl,{label:lr("Inner blocks use content width"),checked:f,onChange:function(){i({allowCustomContentAndWideSize:!f})},help:lr(f?"Nested blocks use content width with options for full and wide widths.":"Nested blocks will fill the width of this container. Toggle to constrain.")}),f&&(0,l.createElement)(React.Fragment,null,(0,l.createElement)(h.__experimentalUnitControl,{__next40pxDefaultSize:!0,label:lr("Content width"),labelPosition:"top",value:b||y||"",onChange:function(e){e=0>parseFloat(e)?"0":e,i({contentSize:e})},units:w,prefix:(0,l.createElement)(h.__experimentalInputControlPrefixWrapper,{variant:"icon"},(0,l.createElement)(Wr,null))}),(0,l.createElement)(h.__experimentalUnitControl,{__next40pxDefaultSize:!0,label:lr("Wide width"),labelPosition:"top",value:y||b||"",onChange:function(e){e=0>parseFloat(e)?"0":e,i({wideSize:e})},units:w,prefix:(0,l.createElement)(h.__experimentalInputControlPrefixWrapper,{variant:"icon"},(0,l.createElement)(Zr,null))}),(0,l.createElement)("p",{className:"block-editor-hooks__layout-constrained-helptext"},lr("Customize the width for all elements that are assigned to the center or wide columns.")))))),(0,l.createElement)(h.__experimentalToolsPanel,{label:lr("Image Settings","blocksy-companion"),resetAll:function(){i({hasParallax:!1,focalPoint:void 0,isRepeated:!1})}},k&&(0,l.createElement)(h.__experimentalToolsPanelItem,{label:lr("Focal point"),isShownByDefault:!0,hasValue:function(){return!!u},onDeselect:function(){return i({focalPoint:void 0})}},(0,l.createElement)(h.FocalPointPicker,{__nextHasNoMarginBottom:!0,label:lr("Focal point"),url:_,value:u,onDragStart:function(e){return i({focalPoint:e})},onDrag:function(e){return i({focalPoint:e})},onChange:function(e){return i({focalPoint:e})}})),(0,l.createElement)(h.__experimentalToolsPanelItem,{label:lr("Fixed background"),isShownByDefault:!0,hasValue:function(){return p},onDeselect:function(){return i({hasParallax:!1,focalPoint:void 0})}},(0,l.createElement)(h.ToggleControl,{__nextHasNoMarginBottom:!0,label:lr("Fixed background"),checked:p,onChange:function(){i(function(e){for(var t=1;t0}const ll=(e,t,o)=>{const n=Array.isArray(t)?t:t.split(".");let r=e;return n.forEach((e=>{r=r?.[e]})),r??o};const al=[{path:["color","palette"],valueKey:"color",cssVarInfix:"color",classes:[{classSuffix:"color",propertyName:"color"},{classSuffix:"background-color",propertyName:"background-color"},{classSuffix:"border-color",propertyName:"border-color"}]},{path:["color","gradients"],valueKey:"gradient",cssVarInfix:"gradient",classes:[{classSuffix:"gradient-background",propertyName:"background"}]},{path:["color","duotone"],valueKey:"colors",cssVarInfix:"duotone",valueFunc:({slug:e})=>`url( '#wp-duotone-${e}' )`,classes:[]},{path:["shadow","presets"],valueKey:"shadow",cssVarInfix:"shadow",classes:[]},{path:["typography","fontSizes"],valueFunc:(e,t)=>nl(e,t),valueKey:"size",cssVarInfix:"font-size",classes:[{classSuffix:"font-size",propertyName:"font-size"}]},{path:["typography","fontFamilies"],valueKey:"fontFamily",cssVarInfix:"font-family",classes:[{classSuffix:"font-family",propertyName:"font-family"}]},{path:["spacing","spacingSizes"],valueKey:"size",cssVarInfix:"spacing",valueFunc:({size:e})=>e,classes:[]}];function il(e,t,o,n,r){const l=[ll(e,["blocks",t,...o]),ll(e,o)];for(const a of l)if(a){const l=["custom","theme","default"];for(const i of l){const l=a[i];if(l){const a=l.find((e=>e[n]===r));if(a){if("slug"===n)return a;return il(e,t,o,"slug",a.slug)[n]===a[n]?a:void 0}}}}}function cl(e,t,o){if(!o||"string"!=typeof o){if("string"!=typeof o?.ref)return o;if(!(o=ll(e,o.ref))||o?.ref)return o}const n="var:",r="var(--wp--";let l;if(o.startsWith(n))l=o.slice(4).split("|");else{if(!o.startsWith(r)||!o.endsWith(")"))return o;l=o.slice(10,-1).split("--")}const[a,...i]=l;return"preset"===a?function(e,t,o,[n,r]){const l=al.find((e=>e.cssVarInfix===n));if(!l)return o;const a=il(e.settings,t,l.path,"slug",r);if(a){const{valueKey:o}=l;return cl(e,t,a[o])}return o}(e,t,o,i):"custom"===a?function(e,t,o,n){const r=ll(e.settings,["blocks",t,"custom",...n])??ll(e.settings,["custom",...n]);return r?cl(e,t,r):o}(e,t,o,i):o}function sl(e){if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(e=function(e,t){if(!e)return;if("string"==typeof e)return ul(e,t);var o=Object.prototype.toString.call(e).slice(8,-1);"Object"===o&&e.constructor&&(o=e.constructor.name);if("Map"===o||"Set"===o)return Array.from(e);if("Arguments"===o||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(o))return ul(e,t)}(e))){var t=0,o=function(){};return{s:o,n:function(){return t>=e.length?{done:!0}:{done:!1,value:e[t++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var n,r,l=!0,a=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return l=e.done,e},e:function(e){a=!0,r=e},f:function(){try{l||null==n.return||n.return()}finally{if(a)throw r}}}}function ul(e,t){(null==t||t>e.length)&&(t=e.length);for(var o=0,n=new Array(t);o0?{taxonomy:{type:"ct-select",label:(0,a.__)("Taxonomy","blocksy-companion"),value:"",design:"inline",purpose:"default",choices:B.map((function(e){var t=e.name;return{key:e.slug,value:t}}))}}:{}),"wp:term_image"===S.field?{imageSource:{type:"ct-radio",label:(0,a.__)("Image Source","blocksy-companion"),value:S.imageSource,design:"inline",purpose:"gutenberg",divider:"bottom",choices:{featured:(0,a.__)("Image","blocksy-companion"),icon:(0,a.__)("Icon/Logo","blocksy-companion")}}}:{}),I),value:dl(dl({},S),C&&C.has_taxonomies_customization?{has_taxonomies_customization:"yes"}:{}),hasRevertButton:!1}),on(x)&&"wp:author_avatar"!==S.field&&"wp:archive_image"!==S.field&&"default"===S.viewType&&(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){j(r({},e,t))},options:dl(dl({lightbox_condition:{type:"ct-condition",condition:{has_field_link:"no"},options:{lightbox:{type:"ct-switch",label:(0,a.__)("Expand on click","blocksy-companion"),value:"no"}}}},"wp:featured_image"===S.field?{videoThumbnail:{type:"ct-switch",label:(0,a.__)("Video thumbnail","blocksy-companion"),value:"no"}}:{}),{},{image_hover_effect:{label:(0,a.__)("Image Hover Effect","blocksy-companion"),type:"ct-select",value:"none",view:"text",design:"inline",divider:"top:full",choices:{none:(0,a.__)("None","blocksy-companion"),"zoom-in":(0,a.__)("Zoom In","blocksy-companion"),"zoom-out":(0,a.__)("Zoom Out","blocksy-companion")}}}),value:S,hasRevertButton:!1})),on(x)&&"wp:author_avatar"!==S.field&&(0,l.createElement)(React.Fragment,null,(0,l.createElement)($r,{attributes:S,setAttributes:j,postId:H,postType:N}),(0,l.createElement)(qr,{clientId:D,attributes:S,setAttributes:j})),"wp:author_avatar"===S.field&&(0,l.createElement)(h.PanelBody,null,(0,l.createElement)(h.RangeControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,label:(0,a.__)("Image size","blocksy-companion"),onChange:function(e){return j({avatar_size:e})},min:5,max:500,initialPosition:null==S?void 0:S.avatar_size,value:null==S?void 0:S.avatar_size})),"woo:brands"===S.field&&(0,l.createElement)(h.PanelBody,null,(0,l.createElement)(h.RangeControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,label:(0,a.__)("Logo Size","blocksy-companion"),onChange:function(e){return j({brands_size:e})},min:5,max:500,initialPosition:null==S?void 0:S.brands_size,value:null==S?void 0:S.brands_size}),(0,l.createElement)(h.RangeControl,{__nextHasNoMarginBottom:!0,__next40pxDefaultSize:!0,label:(0,a.__)("Logo Gap","blocksy-companion"),onChange:function(e){return j({brands_gap:e})},min:5,max:500,initialPosition:null==S?void 0:S.brands_gap,value:null==S?void 0:S.brands_gap})),!on(x)&&"woo:brands"!==S.field&&(0,l.createElement)(h.PanelBody,null,(0,l.createElement)(G.OptionsPanel,{purpose:"gutenberg",onChange:function(e,t){j(r({},e,t))},options:dl({before:{type:"text",label:(0,a.__)("Before","blocksy-companion"),value:""},after:{type:"text",label:(0,a.__)("After","blocksy-companion"),value:""}},"wp"!==x.provider||"wp"===x.provider&&("excerpt"===x.id||"terms"===x.id||"author"===x.id)?{fallback:{type:"text",label:(0,a.__)("Fallback","blocksy-companion"),value:(0,a.__)("Custom field fallback","blocksy-companion")}}:{}),value:S,hasRevertButton:!1}))),(0,l.createElement)(c.InspectorControls,{group:"color",resetAllFilter:function(){var e=on(x)?"image":"text";"text"===e&&(ee(),te(),oe(),setTimeout((function(){var e,t=null==S||null===(e=S.style)||void 0===e?void 0:e.elements,o=(t.link,E(t,["link"])),n=dl(dl({},S.style),{},{elements:o});j({textColor:void 0,style:n})}))),"image"===e&&setTimeout((function(){Y("#000000")}),50)}},(0,l.createElement)(v,{label:(0,a.__)("Colors","blocksy-companion"),panelId:D,settings:ne,skipToolsPanel:!0,containerProps:{"data-field-type":on(x)?"image:".concat(S.viewType):"text"}}),on(x)&&"default"!==S.viewType?(0,l.createElement)(h.__experimentalToolsPanelItem,{hasValue:function(){return void 0!==S.dimRatio&&50!==S.dimRatio},label:(0,a.__)("Overlay opacity"),onDeselect:function(){return j({dimRatio:50})},resetAllFilter:function(){return{dimRatio:50}},isShownByDefault:!0,panelId:D},(0,l.createElement)(h.RangeControl,{__nextHasNoMarginBottom:!0,label:(0,a.__)("Overlay opacity"),value:S.dimRatio,onChange:function(e){return j({dimRatio:e})},min:0,max:100,step:10,required:!0,__next40pxDefaultSize:!0})):null),"wp:terms"===S.field&&(0,l.createElement)(c.InspectorControls,{group:"advanced"},(0,l.createElement)(h.TextControl,{__nextHasNoMarginBottom:!0,autoComplete:"off",label:(0,a.__)("Term additional class","blocksy-companion"),value:S.termClass,onChange:function(e){j({termClass:e})},help:(0,a.__)("Additional class for term items. Useful for styling.","blocksy-companion")})))};function yl(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,n)}return o}function hl(e){for(var t=1;t