[ Index ]

PHP Cross Reference of WordPress Trunk (Updated Daily)

Search

title

Body

[close]

/wp-includes/js/dist/ -> interactivity.js (source)

   1  /******/ // The require scope
   2  /******/ var __webpack_require__ = {};
   3  /******/ 
   4  /************************************************************************/
   5  /******/ /* webpack/runtime/define property getters */
   6  /******/ (() => {
   7  /******/     // define getter functions for harmony exports
   8  /******/     __webpack_require__.d = (exports, definition) => {
   9  /******/         for(var key in definition) {
  10  /******/             if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
  11  /******/                 Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
  12  /******/             }
  13  /******/         }
  14  /******/     };
  15  /******/ })();
  16  /******/ 
  17  /******/ /* webpack/runtime/hasOwnProperty shorthand */
  18  /******/ (() => {
  19  /******/     __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
  20  /******/ })();
  21  /******/ 
  22  /************************************************************************/
  23  var __webpack_exports__ = {};
  24  
  25  // EXPORTS
  26  __webpack_require__.d(__webpack_exports__, {
  27    zj: () => (/* reexport */ getConfig),
  28    SD: () => (/* reexport */ getContext),
  29    V6: () => (/* reexport */ getElement),
  30    jb: () => (/* binding */ privateApis),
  31    M_: () => (/* reexport */ store),
  32    hb: () => (/* reexport */ useCallback),
  33    vJ: () => (/* reexport */ useEffect),
  34    ip: () => (/* reexport */ useInit),
  35    Nf: () => (/* reexport */ useLayoutEffect),
  36    Kr: () => (/* reexport */ useMemo),
  37    li: () => (/* reexport */ hooks_module_F),
  38    J0: () => (/* reexport */ hooks_module_p),
  39    FH: () => (/* reexport */ useWatch),
  40    v4: () => (/* reexport */ withScope)
  41  });
  42  
  43  ;// CONCATENATED MODULE: ./node_modules/preact/dist/preact.module.js
  44  var n,l,preact_module_u,preact_module_t,i,preact_module_o,r,preact_module_f,preact_module_e,preact_module_c={},s=[],a=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,h=Array.isArray;function v(n,l){for(var u in l)n[u]=l[u];return n}function p(n){var l=n.parentNode;l&&l.removeChild(n)}function y(l,u,t){var i,o,r,f={};for(r in u)"key"==r?i=u[r]:"ref"==r?o=u[r]:f[r]=u[r];if(arguments.length>2&&(f.children=arguments.length>3?n.call(arguments,2):t),"function"==typeof l&&null!=l.defaultProps)for(r in l.defaultProps)void 0===f[r]&&(f[r]=l.defaultProps[r]);return d(l,f,i,o,null)}function d(n,t,i,o,r){var f={type:n,props:t,key:i,ref:o,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,constructor:void 0,__v:null==r?++preact_module_u:r,__i:-1,__u:0};return null==r&&null!=l.vnode&&l.vnode(f),f}function _(){return{current:null}}function g(n){return n.children}function b(n,l){this.props=n,this.context=l}function m(n,l){if(null==l)return n.__?m(n.__,n.__i+1):null;for(var u;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e)return u.__e;return"function"==typeof n.type?m(n):null}function w(n,u,t){var i,o=n.__v,r=o.__e,f=n.__P;if(f)return(i=v({},o)).__v=o.__v+1,l.vnode&&l.vnode(i),M(f,i,o,n.__n,void 0!==f.ownerSVGElement,32&o.__u?[r]:null,u,null==r?m(o):r,!!(32&o.__u),t),i.__v=o.__v,i.__.__k[i.__i]=i,i.__d=void 0,i.__e!=r&&k(i),i}function k(n){var l,u;if(null!=(n=n.__)&&null!=n.__c){for(n.__e=n.__c.base=null,l=0;l<n.__k.length;l++)if(null!=(u=n.__k[l])&&null!=u.__e){n.__e=n.__c.base=u.__e;break}return k(n)}}function x(n){(!n.__d&&(n.__d=!0)&&i.push(n)&&!C.__r++||preact_module_o!==l.debounceRendering)&&((preact_module_o=l.debounceRendering)||r)(C)}function C(){var n,u,t,o=[],r=[];for(i.sort(preact_module_f);n=i.shift();)n.__d&&(t=i.length,u=w(n,o,r)||u,0===t||i.length>t?(j(o,u,r),r.length=o.length=0,u=void 0,i.sort(preact_module_f)):u&&l.__c&&l.__c(u,s));u&&j(o,u,r),C.__r=0}function P(n,l,u,t,i,o,r,f,e,a,h){var v,p,y,d,_,g=t&&t.__k||s,b=l.length;for(u.__d=e,S(u,l,g),e=u.__d,v=0;v<b;v++)null!=(y=u.__k[v])&&"boolean"!=typeof y&&"function"!=typeof y&&(p=-1===y.__i?preact_module_c:g[y.__i]||preact_module_c,y.__i=v,M(n,y,p,i,o,r,f,e,a,h),d=y.__e,y.ref&&p.ref!=y.ref&&(p.ref&&N(p.ref,null,y),h.push(y.ref,y.__c||d,y)),null==_&&null!=d&&(_=d),65536&y.__u||p.__k===y.__k?e=$(y,e,n):"function"==typeof y.type&&void 0!==y.__d?e=y.__d:d&&(e=d.nextSibling),y.__d=void 0,y.__u&=-196609);u.__d=e,u.__e=_}function S(n,l,u){var t,i,o,r,f,e=l.length,c=u.length,s=c,a=0;for(n.__k=[],t=0;t<e;t++)r=t+a,null!=(i=n.__k[t]=null==(i=l[t])||"boolean"==typeof i||"function"==typeof i?null:"string"==typeof i||"number"==typeof i||"bigint"==typeof i||i.constructor==String?d(null,i,null,null,null):h(i)?d(g,{children:i},null,null,null):void 0===i.constructor&&i.__b>0?d(i.type,i.props,i.key,i.ref?i.ref:null,i.__v):i)?(i.__=n,i.__b=n.__b+1,f=I(i,u,r,s),i.__i=f,o=null,-1!==f&&(s--,(o=u[f])&&(o.__u|=131072)),null==o||null===o.__v?(-1==f&&a--,"function"!=typeof i.type&&(i.__u|=65536)):f!==r&&(f===r+1?a++:f>r?s>e-r?a+=f-r:a--:f<r?f==r-1&&(a=f-r):a=0,f!==t+a&&(i.__u|=65536))):(o=u[r])&&null==o.key&&o.__e&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=m(o)),O(o,o,!1),u[r]=null,s--);if(s)for(t=0;t<c;t++)null!=(o=u[t])&&0==(131072&o.__u)&&(o.__e==n.__d&&(n.__d=m(o)),O(o,o))}function $(n,l,u){var t,i;if("function"==typeof n.type){for(t=n.__k,i=0;t&&i<t.length;i++)t[i]&&(t[i].__=n,l=$(t[i],l,u));return l}n.__e!=l&&(u.insertBefore(n.__e,l||null),l=n.__e);do{l=l&&l.nextSibling}while(null!=l&&8===l.nodeType);return l}function H(n,l){return l=l||[],null==n||"boolean"==typeof n||(h(n)?n.some(function(n){H(n,l)}):l.push(n)),l}function I(n,l,u,t){var i=n.key,o=n.type,r=u-1,f=u+1,e=l[u];if(null===e||e&&i==e.key&&o===e.type&&0==(131072&e.__u))return u;if(t>(null!=e&&0==(131072&e.__u)?1:0))for(;r>=0||f<l.length;){if(r>=0){if((e=l[r])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return r;r--}if(f<l.length){if((e=l[f])&&0==(131072&e.__u)&&i==e.key&&o===e.type)return f;f++}}return-1}function T(n,l,u){"-"===l[0]?n.setProperty(l,null==u?"":u):n[l]=null==u?"":"number"!=typeof u||a.test(l)?u:u+"px"}function A(n,l,u,t,i){var o;n:if("style"===l)if("string"==typeof u)n.style.cssText=u;else{if("string"==typeof t&&(n.style.cssText=t=""),t)for(l in t)u&&l in u||T(n.style,l,"");if(u)for(l in u)t&&u[l]===t[l]||T(n.style,l,u[l])}else if("o"===l[0]&&"n"===l[1])o=l!==(l=l.replace(/(PointerCapture)$|Capture$/i,"$1")),l=l.toLowerCase()in n?l.toLowerCase().slice(2):l.slice(2),n.l||(n.l={}),n.l[l+o]=u,u?t?u.u=t.u:(u.u=Date.now(),n.addEventListener(l,o?L:D,o)):n.removeEventListener(l,o?L:D,o);else{if(i)l=l.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if("width"!==l&&"height"!==l&&"href"!==l&&"list"!==l&&"form"!==l&&"tabIndex"!==l&&"download"!==l&&"rowSpan"!==l&&"colSpan"!==l&&"role"!==l&&l in n)try{n[l]=null==u?"":u;break n}catch(n){}"function"==typeof u||(null==u||!1===u&&"-"!==l[4]?n.removeAttribute(l):n.setAttribute(l,u))}}function D(n){if(this.l){var u=this.l[n.type+!1];if(n.t){if(n.t<=u.u)return}else n.t=Date.now();return u(l.event?l.event(n):n)}}function L(n){if(this.l)return this.l[n.type+!0](l.event?l.event(n):n)}function M(n,u,t,i,o,r,f,e,c,s){var a,p,y,d,_,m,w,k,x,C,S,$,H,I,T,A=u.type;if(void 0!==u.constructor)return null;128&t.__u&&(c=!!(32&t.__u),r=[e=u.__e=t.__e]),(a=l.__b)&&a(u);n:if("function"==typeof A)try{if(k=u.props,x=(a=A.contextType)&&i[a.__c],C=a?x?x.props.value:a.__:i,t.__c?w=(p=u.__c=t.__c).__=p.__E:("prototype"in A&&A.prototype.render?u.__c=p=new A(k,C):(u.__c=p=new b(k,C),p.constructor=A,p.render=q),x&&x.sub(p),p.props=k,p.state||(p.state={}),p.context=C,p.__n=i,y=p.__d=!0,p.__h=[],p._sb=[]),null==p.__s&&(p.__s=p.state),null!=A.getDerivedStateFromProps&&(p.__s==p.state&&(p.__s=v({},p.__s)),v(p.__s,A.getDerivedStateFromProps(k,p.__s))),d=p.props,_=p.state,p.__v=u,y)null==A.getDerivedStateFromProps&&null!=p.componentWillMount&&p.componentWillMount(),null!=p.componentDidMount&&p.__h.push(p.componentDidMount);else{if(null==A.getDerivedStateFromProps&&k!==d&&null!=p.componentWillReceiveProps&&p.componentWillReceiveProps(k,C),!p.__e&&(null!=p.shouldComponentUpdate&&!1===p.shouldComponentUpdate(k,p.__s,C)||u.__v===t.__v)){for(u.__v!==t.__v&&(p.props=k,p.state=p.__s,p.__d=!1),u.__e=t.__e,u.__k=t.__k,u.__k.forEach(function(n){n&&(n.__=u)}),S=0;S<p._sb.length;S++)p.__h.push(p._sb[S]);p._sb=[],p.__h.length&&f.push(p);break n}null!=p.componentWillUpdate&&p.componentWillUpdate(k,p.__s,C),null!=p.componentDidUpdate&&p.__h.push(function(){p.componentDidUpdate(d,_,m)})}if(p.context=C,p.props=k,p.__P=n,p.__e=!1,$=l.__r,H=0,"prototype"in A&&A.prototype.render){for(p.state=p.__s,p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),I=0;I<p._sb.length;I++)p.__h.push(p._sb[I]);p._sb=[]}else do{p.__d=!1,$&&$(u),a=p.render(p.props,p.state,p.context),p.state=p.__s}while(p.__d&&++H<25);p.state=p.__s,null!=p.getChildContext&&(i=v(v({},i),p.getChildContext())),y||null==p.getSnapshotBeforeUpdate||(m=p.getSnapshotBeforeUpdate(d,_)),P(n,h(T=null!=a&&a.type===g&&null==a.key?a.props.children:a)?T:[T],u,t,i,o,r,f,e,c,s),p.base=u.__e,u.__u&=-161,p.__h.length&&f.push(p),w&&(p.__E=p.__=null)}catch(n){u.__v=null,c||null!=r?(u.__e=e,u.__u|=c?160:32,r[r.indexOf(e)]=null):(u.__e=t.__e,u.__k=t.__k),l.__e(n,u,t)}else null==r&&u.__v===t.__v?(u.__k=t.__k,u.__e=t.__e):u.__e=z(t.__e,u,t,i,o,r,f,c,s);(a=l.diffed)&&a(u)}function j(n,u,t){for(var i=0;i<t.length;i++)N(t[i],t[++i],t[++i]);l.__c&&l.__c(u,n),n.some(function(u){try{n=u.__h,u.__h=[],n.some(function(n){n.call(u)})}catch(n){l.__e(n,u.__v)}})}function z(l,u,t,i,o,r,f,e,s){var a,v,y,d,_,g,b,w=t.props,k=u.props,x=u.type;if("svg"===x&&(o=!0),null!=r)for(a=0;a<r.length;a++)if((_=r[a])&&"setAttribute"in _==!!x&&(x?_.localName===x:3===_.nodeType)){l=_,r[a]=null;break}if(null==l){if(null===x)return document.createTextNode(k);l=o?document.createElementNS("http://www.w3.org/2000/svg",x):document.createElement(x,k.is&&k),r=null,e=!1}if(null===x)w===k||e&&l.data===k||(l.data=k);else{if(r=r&&n.call(l.childNodes),w=t.props||preact_module_c,!e&&null!=r)for(w={},a=0;a<l.attributes.length;a++)w[(_=l.attributes[a]).name]=_.value;for(a in w)_=w[a],"children"==a||("dangerouslySetInnerHTML"==a?y=_:"key"===a||a in k||A(l,a,null,_,o));for(a in k)_=k[a],"children"==a?d=_:"dangerouslySetInnerHTML"==a?v=_:"value"==a?g=_:"checked"==a?b=_:"key"===a||e&&"function"!=typeof _||w[a]===_||A(l,a,_,w[a],o);if(v)e||y&&(v.__html===y.__html||v.__html===l.innerHTML)||(l.innerHTML=v.__html),u.__k=[];else if(y&&(l.innerHTML=""),P(l,h(d)?d:[d],u,t,i,o&&"foreignObject"!==x,r,f,r?r[0]:t.__k&&m(t,0),e,s),null!=r)for(a=r.length;a--;)null!=r[a]&&p(r[a]);e||(a="value",void 0!==g&&(g!==l[a]||"progress"===x&&!g||"option"===x&&g!==w[a])&&A(l,a,g,w[a],!1),a="checked",void 0!==b&&b!==l[a]&&A(l,a,b,w[a],!1))}return l}function N(n,u,t){try{"function"==typeof n?n(u):n.current=u}catch(n){l.__e(n,t)}}function O(n,u,t){var i,o;if(l.unmount&&l.unmount(n),(i=n.ref)&&(i.current&&i.current!==n.__e||N(i,null,u)),null!=(i=n.__c)){if(i.componentWillUnmount)try{i.componentWillUnmount()}catch(n){l.__e(n,u)}i.base=i.__P=null,n.__c=void 0}if(i=n.__k)for(o=0;o<i.length;o++)i[o]&&O(i[o],u,t||"function"!=typeof n.type);t||null==n.__e||p(n.__e),n.__=n.__e=n.__d=void 0}function q(n,l,u){return this.constructor(n,u)}function B(u,t,i){var o,r,f,e;l.__&&l.__(u,t),r=(o="function"==typeof i)?null:i&&i.__k||t.__k,f=[],e=[],M(t,u=(!o&&i||t).__k=y(g,null,[u]),r||preact_module_c,preact_module_c,void 0!==t.ownerSVGElement,!o&&i?[i]:r?null:t.firstChild?n.call(t.childNodes):null,f,!o&&i?i:r?r.__e:t.firstChild,o,e),u.__d=void 0,j(f,u,e)}function E(n,l){B(n,l,E)}function F(l,u,t){var i,o,r,f,e=v({},l.props);for(r in l.type&&l.type.defaultProps&&(f=l.type.defaultProps),u)"key"==r?i=u[r]:"ref"==r?o=u[r]:e[r]=void 0===u[r]&&void 0!==f?f[r]:u[r];return arguments.length>2&&(e.children=arguments.length>3?n.call(arguments,2):t),d(l.type,e,i||l.key,o||l.ref,null)}function G(n,l){var u={__c:l="__cC"+preact_module_e++,__:n,Consumer:function(n,l){return n.children(l)},Provider:function(n){var u,t;return this.getChildContext||(u=[],(t={})[l]=this,this.getChildContext=function(){return t},this.shouldComponentUpdate=function(n){this.props.value!==n.value&&u.some(function(n){n.__e=!0,x(n)})},this.sub=function(n){u.push(n);var l=n.componentWillUnmount;n.componentWillUnmount=function(){u.splice(u.indexOf(n),1),l&&l.call(n)}}),n.children}};return u.Provider.__=u.Consumer.contextType=u}n=s.slice,l={__e:function(n,l,u,t){for(var i,o,r;l=l.__;)if((i=l.__c)&&!i.__)try{if((o=i.constructor)&&null!=o.getDerivedStateFromError&&(i.setState(o.getDerivedStateFromError(n)),r=i.__d),null!=i.componentDidCatch&&(i.componentDidCatch(n,t||{}),r=i.__d),r)return i.__E=i}catch(l){n=l}throw n}},preact_module_u=0,preact_module_t=function(n){return null!=n&&null==n.constructor},b.prototype.setState=function(n,l){var u;u=null!=this.__s&&this.__s!==this.state?this.__s:this.__s=v({},this.state),"function"==typeof n&&(n=n(v({},u),this.props)),n&&v(u,n),null!=n&&this.__v&&(l&&this._sb.push(l),x(this))},b.prototype.forceUpdate=function(n){this.__v&&(this.__e=!0,n&&this.__h.push(n),x(this))},b.prototype.render=g,i=[],r="function"==typeof Promise?Promise.prototype.then.bind(Promise.resolve()):setTimeout,preact_module_f=function(n,l){return n.__v.__b-l.__v.__b},C.__r=0,preact_module_e=0;
  45  
  46  ;// CONCATENATED MODULE: ./node_modules/preact/hooks/dist/hooks.module.js
  47  var hooks_module_t,hooks_module_r,hooks_module_u,hooks_module_i,hooks_module_o=0,hooks_module_f=[],hooks_module_c=[],hooks_module_e=l,hooks_module_a=hooks_module_e.__b,hooks_module_v=hooks_module_e.__r,hooks_module_l=hooks_module_e.diffed,hooks_module_m=hooks_module_e.__c,hooks_module_s=hooks_module_e.unmount,hooks_module_d=hooks_module_e.__;function hooks_module_h(n,t){hooks_module_e.__h&&hooks_module_e.__h(hooks_module_r,n,hooks_module_o||t),hooks_module_o=0;var u=hooks_module_r.__H||(hooks_module_r.__H={__:[],__h:[]});return n>=u.__.length&&u.__.push({__V:hooks_module_c}),u.__[n]}function hooks_module_p(n){return hooks_module_o=1,hooks_module_y(hooks_module_D,n)}function hooks_module_y(n,u,i){var o=hooks_module_h(hooks_module_t++,2);if(o.t=n,!o.__c&&(o.__=[i?i(u):hooks_module_D(void 0,u),function(n){var t=o.__N?o.__N[0]:o.__[0],r=o.t(t,n);t!==r&&(o.__N=[r,o.__[1]],o.__c.setState({}))}],o.__c=hooks_module_r,!hooks_module_r.u)){var f=function(n,t,r){if(!o.__c.__H)return!0;var u=o.__c.__H.__.filter(function(n){return!!n.__c});if(u.every(function(n){return!n.__N}))return!c||c.call(this,n,t,r);var i=!1;return u.forEach(function(n){if(n.__N){var t=n.__[0];n.__=n.__N,n.__N=void 0,t!==n.__[0]&&(i=!0)}}),!(!i&&o.__c.props===n)&&(!c||c.call(this,n,t,r))};hooks_module_r.u=!0;var c=hooks_module_r.shouldComponentUpdate,e=hooks_module_r.componentWillUpdate;hooks_module_r.componentWillUpdate=function(n,t,r){if(this.__e){var u=c;c=void 0,f(n,t,r),c=u}e&&e.call(this,n,t,r)},hooks_module_r.shouldComponentUpdate=f}return o.__N||o.__}function hooks_module_(n,u){var i=hooks_module_h(hooks_module_t++,3);!hooks_module_e.__s&&hooks_module_C(i.__H,u)&&(i.__=n,i.i=u,hooks_module_r.__H.__h.push(i))}function hooks_module_A(n,u){var i=hooks_module_h(hooks_module_t++,4);!hooks_module_e.__s&&hooks_module_C(i.__H,u)&&(i.__=n,i.i=u,hooks_module_r.__h.push(i))}function hooks_module_F(n){return hooks_module_o=5,hooks_module_q(function(){return{current:n}},[])}function hooks_module_T(n,t,r){hooks_module_o=6,hooks_module_A(function(){return"function"==typeof n?(n(t()),function(){return n(null)}):n?(n.current=t(),function(){return n.current=null}):void 0},null==r?r:r.concat(n))}function hooks_module_q(n,r){var u=hooks_module_h(hooks_module_t++,7);return hooks_module_C(u.__H,r)?(u.__V=n(),u.i=r,u.__h=n,u.__V):u.__}function hooks_module_x(n,t){return hooks_module_o=8,hooks_module_q(function(){return n},t)}function hooks_module_P(n){var u=hooks_module_r.context[n.__c],i=hooks_module_h(hooks_module_t++,9);return i.c=n,u?(null==i.__&&(i.__=!0,u.sub(hooks_module_r)),u.props.value):n.__}function V(n,t){hooks_module_e.useDebugValue&&hooks_module_e.useDebugValue(t?t(n):n)}function hooks_module_b(n){var u=hooks_module_h(hooks_module_t++,10),i=hooks_module_p();return u.__=n,hooks_module_r.componentDidCatch||(hooks_module_r.componentDidCatch=function(n,t){u.__&&u.__(n,t),i[1](n)}),[i[0],function(){i[1](void 0)}]}function hooks_module_g(){var n=hooks_module_h(hooks_module_t++,11);if(!n.__){for(var u=hooks_module_r.__v;null!==u&&!u.__m&&null!==u.__;)u=u.__;var i=u.__m||(u.__m=[0,0]);n.__="P"+i[0]+"-"+i[1]++}return n.__}function hooks_module_j(){for(var n;n=hooks_module_f.shift();)if(n.__P&&n.__H)try{n.__H.__h.forEach(hooks_module_z),n.__H.__h.forEach(hooks_module_B),n.__H.__h=[]}catch(t){n.__H.__h=[],hooks_module_e.__e(t,n.__v)}}hooks_module_e.__b=function(n){hooks_module_r=null,hooks_module_a&&hooks_module_a(n)},hooks_module_e.__=function(n,t){n&&t.__k&&t.__k.__m&&(n.__m=t.__k.__m),hooks_module_d&&hooks_module_d(n,t)},hooks_module_e.__r=function(n){hooks_module_v&&hooks_module_v(n),hooks_module_t=0;var i=(hooks_module_r=n.__c).__H;i&&(hooks_module_u===hooks_module_r?(i.__h=[],hooks_module_r.__h=[],i.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=hooks_module_c,n.__N=n.i=void 0})):(i.__h.forEach(hooks_module_z),i.__h.forEach(hooks_module_B),i.__h=[],hooks_module_t=0)),hooks_module_u=hooks_module_r},hooks_module_e.diffed=function(n){hooks_module_l&&hooks_module_l(n);var t=n.__c;t&&t.__H&&(t.__H.__h.length&&(1!==hooks_module_f.push(t)&&hooks_module_i===hooks_module_e.requestAnimationFrame||((hooks_module_i=hooks_module_e.requestAnimationFrame)||hooks_module_w)(hooks_module_j)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==hooks_module_c&&(n.__=n.__V),n.i=void 0,n.__V=hooks_module_c})),hooks_module_u=hooks_module_r=null},hooks_module_e.__c=function(n,t){t.some(function(n){try{n.__h.forEach(hooks_module_z),n.__h=n.__h.filter(function(n){return!n.__||hooks_module_B(n)})}catch(r){t.some(function(n){n.__h&&(n.__h=[])}),t=[],hooks_module_e.__e(r,n.__v)}}),hooks_module_m&&hooks_module_m(n,t)},hooks_module_e.unmount=function(n){hooks_module_s&&hooks_module_s(n);var t,r=n.__c;r&&r.__H&&(r.__H.__.forEach(function(n){try{hooks_module_z(n)}catch(n){t=n}}),r.__H=void 0,t&&hooks_module_e.__e(t,r.__v))};var hooks_module_k="function"==typeof requestAnimationFrame;function hooks_module_w(n){var t,r=function(){clearTimeout(u),hooks_module_k&&cancelAnimationFrame(t),setTimeout(n)},u=setTimeout(r,100);hooks_module_k&&(t=requestAnimationFrame(r))}function hooks_module_z(n){var t=hooks_module_r,u=n.__c;"function"==typeof u&&(n.__c=void 0,u()),hooks_module_r=t}function hooks_module_B(n){var t=hooks_module_r;n.__c=n.__(),hooks_module_r=t}function hooks_module_C(n,t){return!n||n.length!==t.length||t.some(function(t,r){return t!==n[r]})}function hooks_module_D(n,t){return"function"==typeof t?t(n):t}
  48  
  49  ;// CONCATENATED MODULE: ./node_modules/@preact/signals-core/dist/signals-core.module.js
  50  function signals_core_module_i(){throw new Error("Cycle detected")}var signals_core_module_t=Symbol.for("preact-signals");function signals_core_module_r(){if(!(signals_core_module_v>1)){var i,t=!1;while(void 0!==signals_core_module_f){var r=signals_core_module_f;signals_core_module_f=void 0;signals_core_module_e++;while(void 0!==r){var n=r.o;r.o=void 0;r.f&=-3;if(!(8&r.f)&&signals_core_module_l(r))try{r.c()}catch(r){if(!t){i=r;t=!0}}r=n}}signals_core_module_e=0;signals_core_module_v--;if(t)throw i}else signals_core_module_v--}function signals_core_module_n(i){if(signals_core_module_v>0)return i();signals_core_module_v++;try{return i()}finally{signals_core_module_r()}}var signals_core_module_o=void 0,signals_core_module_h=0;function signals_core_module_s(i){if(signals_core_module_h>0)return i();var t=signals_core_module_o;signals_core_module_o=void 0;signals_core_module_h++;try{return i()}finally{signals_core_module_h--;signals_core_module_o=t}}var signals_core_module_f=void 0,signals_core_module_v=0,signals_core_module_e=0,signals_core_module_u=0;function signals_core_module_c(i){if(void 0!==signals_core_module_o){var t=i.n;if(void 0===t||t.t!==signals_core_module_o){t={i:0,S:i,p:signals_core_module_o.s,n:void 0,t:signals_core_module_o,e:void 0,x:void 0,r:t};if(void 0!==signals_core_module_o.s)signals_core_module_o.s.n=t;signals_core_module_o.s=t;i.n=t;if(32&signals_core_module_o.f)i.S(t);return t}else if(-1===t.i){t.i=0;if(void 0!==t.n){t.n.p=t.p;if(void 0!==t.p)t.p.n=t.n;t.p=signals_core_module_o.s;t.n=void 0;signals_core_module_o.s.n=t;signals_core_module_o.s=t}return t}}}function signals_core_module_d(i){this.v=i;this.i=0;this.n=void 0;this.t=void 0}signals_core_module_d.prototype.brand=signals_core_module_t;signals_core_module_d.prototype.h=function(){return!0};signals_core_module_d.prototype.S=function(i){if(this.t!==i&&void 0===i.e){i.x=this.t;if(void 0!==this.t)this.t.e=i;this.t=i}};signals_core_module_d.prototype.U=function(i){if(void 0!==this.t){var t=i.e,r=i.x;if(void 0!==t){t.x=r;i.e=void 0}if(void 0!==r){r.e=t;i.x=void 0}if(i===this.t)this.t=r}};signals_core_module_d.prototype.subscribe=function(i){var t=this;return signals_core_module_O(function(){var r=t.value,n=32&this.f;this.f&=-33;try{i(r)}finally{this.f|=n}})};signals_core_module_d.prototype.valueOf=function(){return this.value};signals_core_module_d.prototype.toString=function(){return this.value+""};signals_core_module_d.prototype.toJSON=function(){return this.value};signals_core_module_d.prototype.peek=function(){return this.v};Object.defineProperty(signals_core_module_d.prototype,"value",{get:function(){var i=signals_core_module_c(this);if(void 0!==i)i.i=this.i;return this.v},set:function(t){if(signals_core_module_o instanceof signals_core_module_)!function(){throw new Error("Computed cannot have side-effects")}();if(t!==this.v){if(signals_core_module_e>100)signals_core_module_i();this.v=t;this.i++;signals_core_module_u++;signals_core_module_v++;try{for(var n=this.t;void 0!==n;n=n.x)n.t.N()}finally{signals_core_module_r()}}}});function signals_core_module_a(i){return new signals_core_module_d(i)}function signals_core_module_l(i){for(var t=i.s;void 0!==t;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return!0;return!1}function signals_core_module_y(i){for(var t=i.s;void 0!==t;t=t.n){var r=t.S.n;if(void 0!==r)t.r=r;t.S.n=t;t.i=-1;if(void 0===t.n){i.s=t;break}}}function signals_core_module_w(i){var t=i.s,r=void 0;while(void 0!==t){var n=t.p;if(-1===t.i){t.S.U(t);if(void 0!==n)n.n=t.n;if(void 0!==t.n)t.n.p=n}else r=t;t.S.n=t.r;if(void 0!==t.r)t.r=void 0;t=n}i.s=r}function signals_core_module_(i){signals_core_module_d.call(this,void 0);this.x=i;this.s=void 0;this.g=signals_core_module_u-1;this.f=4}(signals_core_module_.prototype=new signals_core_module_d).h=function(){this.f&=-3;if(1&this.f)return!1;if(32==(36&this.f))return!0;this.f&=-5;if(this.g===signals_core_module_u)return!0;this.g=signals_core_module_u;this.f|=1;if(this.i>0&&!signals_core_module_l(this)){this.f&=-2;return!0}var i=signals_core_module_o;try{signals_core_module_y(this);signals_core_module_o=this;var t=this.x();if(16&this.f||this.v!==t||0===this.i){this.v=t;this.f&=-17;this.i++}}catch(i){this.v=i;this.f|=16;this.i++}signals_core_module_o=i;signals_core_module_w(this);this.f&=-2;return!0};signals_core_module_.prototype.S=function(i){if(void 0===this.t){this.f|=36;for(var t=this.s;void 0!==t;t=t.n)t.S.S(t)}signals_core_module_d.prototype.S.call(this,i)};signals_core_module_.prototype.U=function(i){if(void 0!==this.t){signals_core_module_d.prototype.U.call(this,i);if(void 0===this.t){this.f&=-33;for(var t=this.s;void 0!==t;t=t.n)t.S.U(t)}}};signals_core_module_.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var i=this.t;void 0!==i;i=i.x)i.t.N()}};signals_core_module_.prototype.peek=function(){if(!this.h())signals_core_module_i();if(16&this.f)throw this.v;return this.v};Object.defineProperty(signals_core_module_.prototype,"value",{get:function(){if(1&this.f)signals_core_module_i();var t=signals_core_module_c(this);this.h();if(void 0!==t)t.i=this.i;if(16&this.f)throw this.v;return this.v}});function signals_core_module_p(i){return new signals_core_module_(i)}function signals_core_module_g(i){var t=i.u;i.u=void 0;if("function"==typeof t){signals_core_module_v++;var n=signals_core_module_o;signals_core_module_o=void 0;try{t()}catch(t){i.f&=-2;i.f|=8;signals_core_module_b(i);throw t}finally{signals_core_module_o=n;signals_core_module_r()}}}function signals_core_module_b(i){for(var t=i.s;void 0!==t;t=t.n)t.S.U(t);i.x=void 0;i.s=void 0;signals_core_module_g(i)}function signals_core_module_x(i){if(signals_core_module_o!==this)throw new Error("Out-of-order effect");signals_core_module_w(this);signals_core_module_o=i;this.f&=-2;if(8&this.f)signals_core_module_b(this);signals_core_module_r()}function signals_core_module_E(i){this.x=i;this.u=void 0;this.s=void 0;this.o=void 0;this.f=32}signals_core_module_E.prototype.c=function(){var i=this.S();try{if(8&this.f)return;if(void 0===this.x)return;var t=this.x();if("function"==typeof t)this.u=t}finally{i()}};signals_core_module_E.prototype.S=function(){if(1&this.f)signals_core_module_i();this.f|=1;this.f&=-9;signals_core_module_g(this);signals_core_module_y(this);signals_core_module_v++;var t=signals_core_module_o;signals_core_module_o=this;return signals_core_module_x.bind(this,t)};signals_core_module_E.prototype.N=function(){if(!(2&this.f)){this.f|=2;this.o=signals_core_module_f;signals_core_module_f=this}};signals_core_module_E.prototype.d=function(){this.f|=8;if(!(1&this.f))signals_core_module_b(this)};function signals_core_module_O(i){var t=new signals_core_module_E(i);try{t.c()}catch(i){t.d();throw i}return t.d.bind(t)}
  51  ;// CONCATENATED MODULE: ./node_modules/@preact/signals/dist/signals.module.js
  52  var signals_module_v,signals_module_s;function signals_module_l(n,i){l[n]=i.bind(null,l[n]||function(){})}function signals_module_d(n){if(signals_module_s)signals_module_s();signals_module_s=n&&n.S()}function signals_module_p(n){var r=this,f=n.data,o=useSignal(f);o.value=f;var e=hooks_module_q(function(){var n=r.__v;while(n=n.__)if(n.__c){n.__c.__$f|=4;break}r.__$u.c=function(){var n;if(!preact_module_t(e.peek())&&3===(null==(n=r.base)?void 0:n.nodeType))r.base.data=e.peek();else{r.__$f|=1;r.setState({})}};return signals_core_module_p(function(){var n=o.value.value;return 0===n?0:!0===n?"":n||""})},[]);return e.value}signals_module_p.displayName="_st";Object.defineProperties(signals_core_module_d.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:signals_module_p},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}});signals_module_l("__b",function(n,r){if("string"==typeof r.type){var i,t=r.props;for(var f in t)if("children"!==f){var o=t[f];if(o instanceof signals_core_module_d){if(!i)r.__np=i={};i[f]=o;t[f]=o.peek()}}}n(r)});signals_module_l("__r",function(n,r){signals_module_d();var i,t=r.__c;if(t){t.__$f&=-2;if(void 0===(i=t.__$u))t.__$u=i=function(n){var r;signals_core_module_O(function(){r=this});r.c=function(){t.__$f|=1;t.setState({})};return r}()}signals_module_v=t;signals_module_d(i);n(r)});signals_module_l("__e",function(n,r,i,t){signals_module_d();signals_module_v=void 0;n(r,i,t)});signals_module_l("diffed",function(n,r){signals_module_d();signals_module_v=void 0;var i;if("string"==typeof r.type&&(i=r.__e)){var t=r.__np,f=r.props;if(t){var o=i.U;if(o)for(var e in o){var u=o[e];if(void 0!==u&&!(e in t)){u.d();o[e]=void 0}}else i.U=o={};for(var a in t){var c=o[a],s=t[a];if(void 0===c){c=signals_module_(i,a,s,f);o[a]=c}else c.o(s,f)}}}n(r)});function signals_module_(n,r,i,t){var f=r in n&&void 0===n.ownerSVGElement,o=signals_core_module_a(i);return{o:function(n,r){o.value=n;t=r},d:signals_core_module_O(function(){var i=o.value.value;if(t[r]!==i){t[r]=i;if(f)n[r]=i;else if(i)n.setAttribute(r,i);else n.removeAttribute(r)}})}}signals_module_l("unmount",function(n,r){if("string"==typeof r.type){var i=r.__e;if(i){var t=i.U;if(t){i.U=void 0;for(var f in t){var o=t[f];if(o)o.d()}}}}else{var e=r.__c;if(e){var u=e.__$u;if(u){e.__$u=void 0;u.d()}}}n(r)});signals_module_l("__h",function(n,r,i,t){if(t<3||9===t)r.__$f|=2;n(r,i,t)});b.prototype.shouldComponentUpdate=function(n,r){var i=this.__$u;if(!(i&&void 0!==i.s||4&this.__$f))return!0;if(3&this.__$f)return!0;for(var t in r)return!0;for(var f in n)if("__source"!==f&&n[f]!==this.props[f])return!0;for(var o in this.props)if(!(o in n))return!0;return!1};function useSignal(n){return hooks_module_q(function(){return signals_core_module_a(n)},[])}function useComputed(n){var r=f(n);r.current=n;signals_module_v.__$f|=4;return t(function(){return u(function(){return r.current()})},[])}function useSignalEffect(n){var r=f(n);r.current=n;o(function(){return c(function(){return r.current()})},[])}
  53  ;// CONCATENATED MODULE: ./node_modules/deepsignal/dist/deepsignal.module.js
  54  var deepsignal_module_a=new WeakMap,deepsignal_module_o=new WeakMap,deepsignal_module_s=new WeakMap,deepsignal_module_u=new WeakSet,deepsignal_module_c=new WeakMap,deepsignal_module_f=/^\$/,deepsignal_module_i=Object.getOwnPropertyDescriptor,deepsignal_module_l=!1,deepsignal_module_g=function(e){if(!deepsignal_module_k(e))throw new Error("This object can't be observed.");return deepsignal_module_o.has(e)||deepsignal_module_o.set(e,deepsignal_module_v(e,deepsignal_module_d)),deepsignal_module_o.get(e)},deepsignal_module_p=function(e,t){deepsignal_module_l=!0;var r=e[t];try{deepsignal_module_l=!1}catch(e){}return r};function deepsignal_module_h(e){return deepsignal_module_u.add(e),e}var deepsignal_module_v=function(e,t){var r=new Proxy(e,t);return deepsignal_module_u.add(r),r},deepsignal_module_y=function(){throw new Error("Don't mutate the signals directly.")},deepsignal_module_w=function(e){return function(t,u,c){var g;if(deepsignal_module_l)return Reflect.get(t,u,c);var p=e||"$"===u[0];if(!e&&p&&Array.isArray(t)){if("$"===u)return deepsignal_module_s.has(t)||deepsignal_module_s.set(t,deepsignal_module_v(t,deepsignal_module_m)),deepsignal_module_s.get(t);p="$length"===u}deepsignal_module_a.has(c)||deepsignal_module_a.set(c,new Map);var h=deepsignal_module_a.get(c),y=p?u.replace(deepsignal_module_f,""):u;if(h.has(y)||"function"!=typeof(null==(g=deepsignal_module_i(t,y))?void 0:g.get)){var w=Reflect.get(t,y,c);if(p&&"function"==typeof w)return;if("symbol"==typeof y&&deepsignal_module_b.has(y))return w;h.has(y)||(deepsignal_module_k(w)&&(deepsignal_module_o.has(w)||deepsignal_module_o.set(w,deepsignal_module_v(w,deepsignal_module_d)),w=deepsignal_module_o.get(w)),h.set(y,signals_core_module_a(w)))}else h.set(y,signals_core_module_p(function(){return Reflect.get(t,y,c)}));return p?h.get(y):h.get(y).value}},deepsignal_module_d={get:deepsignal_module_w(!1),set:function(e,n,s,u){var l;if("function"==typeof(null==(l=deepsignal_module_i(e,n))?void 0:l.set))return Reflect.set(e,n,s,u);deepsignal_module_a.has(u)||deepsignal_module_a.set(u,new Map);var g=deepsignal_module_a.get(u);if("$"===n[0]){s instanceof signals_core_module_d||deepsignal_module_y();var p=n.replace(deepsignal_module_f,"");return g.set(p,s),Reflect.set(e,p,s.peek(),u)}var h=s;deepsignal_module_k(s)&&(deepsignal_module_o.has(s)||deepsignal_module_o.set(s,deepsignal_module_v(s,deepsignal_module_d)),h=deepsignal_module_o.get(s));var w=!(n in e),m=Reflect.set(e,n,s,u);return g.has(n)?g.get(n).value=h:g.set(n,signals_core_module_a(h)),w&&deepsignal_module_c.has(e)&&deepsignal_module_c.get(e).value++,Array.isArray(e)&&g.has("length")&&(g.get("length").value=e.length),m},deleteProperty:function(e,t){"$"===t[0]&&deepsignal_module_y();var r=deepsignal_module_a.get(deepsignal_module_o.get(e)),n=Reflect.deleteProperty(e,t);return r&&r.has(t)&&(r.get(t).value=void 0),deepsignal_module_c.has(e)&&deepsignal_module_c.get(e).value++,n},ownKeys:function(e){return deepsignal_module_c.has(e)||deepsignal_module_c.set(e,signals_core_module_a(0)),deepsignal_module_c._=deepsignal_module_c.get(e).value,Reflect.ownKeys(e)}},deepsignal_module_m={get:deepsignal_module_w(!0),set:deepsignal_module_y,deleteProperty:deepsignal_module_y},deepsignal_module_b=new Set(Object.getOwnPropertyNames(Symbol).map(function(e){return Symbol[e]}).filter(function(e){return"symbol"==typeof e})),R=new Set([Object,Array]),deepsignal_module_k=function(e){return"object"==typeof e&&null!==e&&R.has(e.constructor)&&!deepsignal_module_u.has(e)},deepsignal_module_M=function(t){return e(function(){return deepsignal_module_g(t)},[])};
  55  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/store.js
  56  /**
  57   * External dependencies
  58   */
  59  
  60  
  61  
  62  /**
  63   * Internal dependencies
  64   */
  65  
  66  const isObject = item => item && typeof item === 'object' && item.constructor === Object;
  67  const deepMerge = (target, source) => {
  68    if (isObject(target) && isObject(source)) {
  69      for (const key in source) {
  70        const getter = Object.getOwnPropertyDescriptor(source, key)?.get;
  71        if (typeof getter === 'function') {
  72          Object.defineProperty(target, key, {
  73            get: getter
  74          });
  75        } else if (isObject(source[key])) {
  76          if (!target[key]) target[key] = {};
  77          deepMerge(target[key], source[key]);
  78        } else {
  79          try {
  80            target[key] = source[key];
  81          } catch (e) {
  82            // Assignemnts fail for properties that are only getters.
  83            // When that's the case, the assignment is simply ignored.
  84          }
  85        }
  86      }
  87    }
  88  };
  89  const stores = new Map();
  90  const rawStores = new Map();
  91  const storeLocks = new Map();
  92  const storeConfigs = new Map();
  93  const objToProxy = new WeakMap();
  94  const proxyToNs = new WeakMap();
  95  const scopeToGetters = new WeakMap();
  96  const proxify = (obj, ns) => {
  97    if (!objToProxy.has(obj)) {
  98      const proxy = new Proxy(obj, handlers);
  99      objToProxy.set(obj, proxy);
 100      proxyToNs.set(proxy, ns);
 101    }
 102    return objToProxy.get(obj);
 103  };
 104  const handlers = {
 105    get: (target, key, receiver) => {
 106      const ns = proxyToNs.get(receiver);
 107  
 108      // Check if the property is a getter and we are inside an scope. If that is
 109      // the case, we clone the getter to avoid overwriting the scoped
 110      // dependencies of the computed each time that getter runs.
 111      const getter = Object.getOwnPropertyDescriptor(target, key)?.get;
 112      if (getter) {
 113        const scope = getScope();
 114        if (scope) {
 115          const getters = scopeToGetters.get(scope) || scopeToGetters.set(scope, new Map()).get(scope);
 116          if (!getters.has(getter)) {
 117            getters.set(getter, signals_core_module_p(() => {
 118              setNamespace(ns);
 119              setScope(scope);
 120              try {
 121                return getter.call(target);
 122              } finally {
 123                resetScope();
 124                resetNamespace();
 125              }
 126            }));
 127          }
 128          return getters.get(getter).value;
 129        }
 130      }
 131      const result = Reflect.get(target, key);
 132  
 133      // Check if the proxy is the store root and no key with that name exist. In
 134      // that case, return an empty object for the requested key.
 135      if (typeof result === 'undefined' && receiver === stores.get(ns)) {
 136        const obj = {};
 137        Reflect.set(target, key, obj);
 138        return proxify(obj, ns);
 139      }
 140  
 141      // Check if the property is a generator. If it is, we turn it into an
 142      // asynchronous function where we restore the default namespace and scope
 143      // each time it awaits/yields.
 144      if (result?.constructor?.name === 'GeneratorFunction') {
 145        return async (...args) => {
 146          const scope = getScope();
 147          const gen = result(...args);
 148          let value;
 149          let it;
 150          while (true) {
 151            setNamespace(ns);
 152            setScope(scope);
 153            try {
 154              it = gen.next(value);
 155            } finally {
 156              resetScope();
 157              resetNamespace();
 158            }
 159            try {
 160              value = await it.value;
 161            } catch (e) {
 162              setNamespace(ns);
 163              setScope(scope);
 164              gen.throw(e);
 165            } finally {
 166              resetScope();
 167              resetNamespace();
 168            }
 169            if (it.done) break;
 170          }
 171          return value;
 172        };
 173      }
 174  
 175      // Check if the property is a synchronous function. If it is, set the
 176      // default namespace. Synchronous functions always run in the proper scope,
 177      // which is set by the Directives component.
 178      if (typeof result === 'function') {
 179        return (...args) => {
 180          setNamespace(ns);
 181          try {
 182            return result(...args);
 183          } finally {
 184            resetNamespace();
 185          }
 186        };
 187      }
 188  
 189      // Check if the property is an object. If it is, proxyify it.
 190      if (isObject(result)) return proxify(result, ns);
 191      return result;
 192    },
 193    // Prevents passing the current proxy as the receiver to the deepSignal.
 194    set(target, key, value) {
 195      return Reflect.set(target, key, value);
 196    }
 197  };
 198  
 199  /**
 200   * Get the defined config for the store with the passed namespace.
 201   *
 202   * @param namespace Store's namespace from which to retrieve the config.
 203   * @return Defined config for the given namespace.
 204   */
 205  const getConfig = namespace => storeConfigs.get(namespace || getNamespace()) || {};
 206  const universalUnlock = 'I acknowledge that using a private store means my plugin will inevitably break on the next store release.';
 207  
 208  /**
 209   * Extends the Interactivity API global store adding the passed properties to
 210   * the given namespace. It also returns stable references to the namespace
 211   * content.
 212   *
 213   * These props typically consist of `state`, which is the reactive part of the
 214   * store ― which means that any directive referencing a state property will be
 215   * re-rendered anytime it changes ― and function properties like `actions` and
 216   * `callbacks`, mostly used for event handlers. These props can then be
 217   * referenced by any directive to make the HTML interactive.
 218   *
 219   * @example
 220   * ```js
 221   *  const { state } = store( 'counter', {
 222   *    state: {
 223   *      value: 0,
 224   *      get double() { return state.value * 2; },
 225   *    },
 226   *    actions: {
 227   *      increment() {
 228   *        state.value += 1;
 229   *      },
 230   *    },
 231   *  } );
 232   * ```
 233   *
 234   * The code from the example above allows blocks to subscribe and interact with
 235   * the store by using directives in the HTML, e.g.:
 236   *
 237   * ```html
 238   * <div data-wp-interactive='{ "namespace": "counter" }'>
 239   *   <button
 240   *     data-wp-text="state.double"
 241   *     data-wp-on--click="actions.increment"
 242   *   >
 243   *     0
 244   *   </button>
 245   * </div>
 246   * ```
 247   * @param namespace The store namespace to interact with.
 248   * @param storePart Properties to add to the store namespace.
 249   * @param options   Options for the given namespace.
 250   *
 251   * @return A reference to the namespace content.
 252   */
 253  
 254  function store(namespace, {
 255    state = {},
 256    ...block
 257  } = {}, {
 258    lock = false
 259  } = {}) {
 260    if (!stores.has(namespace)) {
 261      // Lock the store if the passed lock is different from the universal
 262      // unlock. Once the lock is set (either false, true, or a given string),
 263      // it cannot change.
 264      if (lock !== universalUnlock) {
 265        storeLocks.set(namespace, lock);
 266      }
 267      const rawStore = {
 268        state: deepsignal_module_g(isObject(state) ? state : {}),
 269        ...block
 270      };
 271      const proxiedStore = new Proxy(rawStore, handlers);
 272      rawStores.set(namespace, rawStore);
 273      stores.set(namespace, proxiedStore);
 274      proxyToNs.set(proxiedStore, namespace);
 275    } else {
 276      // Lock the store if it wasn't locked yet and the passed lock is
 277      // different from the universal unlock. If no lock is given, the store
 278      // will be public and won't accept any lock from now on.
 279      if (lock !== universalUnlock && !storeLocks.has(namespace)) {
 280        storeLocks.set(namespace, lock);
 281      } else {
 282        const storeLock = storeLocks.get(namespace);
 283        const isLockValid = lock === universalUnlock || lock !== true && lock === storeLock;
 284        if (!isLockValid) {
 285          if (!storeLock) {
 286            throw Error('Cannot lock a public store');
 287          } else {
 288            throw Error('Cannot unlock a private store with an invalid lock code');
 289          }
 290        }
 291      }
 292      const target = rawStores.get(namespace);
 293      deepMerge(target, block);
 294      deepMerge(target.state, state);
 295    }
 296    return stores.get(namespace);
 297  }
 298  const parseInitialData = (dom = document) => {
 299    const storeTag = dom.querySelector(`script[type="application/json"]#wp-interactivity-data`);
 300    if (storeTag?.textContent) {
 301      try {
 302        return JSON.parse(storeTag.textContent);
 303      } catch (e) {
 304        // Do nothing.
 305      }
 306    }
 307    return {};
 308  };
 309  const populateInitialData = data => {
 310    if (isObject(data?.state)) {
 311      Object.entries(data.state).forEach(([namespace, state]) => {
 312        store(namespace, {
 313          state
 314        }, {
 315          lock: universalUnlock
 316        });
 317      });
 318    }
 319    if (isObject(data?.config)) {
 320      Object.entries(data.config).forEach(([namespace, config]) => {
 321        storeConfigs.set(namespace, config);
 322      });
 323    }
 324  };
 325  
 326  // Parse and populate the initial state and config.
 327  const data = parseInitialData();
 328  populateInitialData(data);
 329  
 330  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/hooks.js
 331  /* @jsx createElement */
 332  
 333  /**
 334   * External dependencies
 335   */
 336  
 337  
 338  /**
 339   * Internal dependencies
 340   */
 341  
 342  // Main context.
 343  const context = G({});
 344  
 345  // Wrap the element props to prevent modifications.
 346  const immutableMap = new WeakMap();
 347  const immutableError = () => {
 348    throw new Error('Please use `data-wp-bind` to modify the attributes of an element.');
 349  };
 350  const immutableHandlers = {
 351    get(target, key, receiver) {
 352      const value = Reflect.get(target, key, receiver);
 353      return !!value && typeof value === 'object' ? deepImmutable(value) : value;
 354    },
 355    set: immutableError,
 356    deleteProperty: immutableError
 357  };
 358  const deepImmutable = target => {
 359    if (!immutableMap.has(target)) immutableMap.set(target, new Proxy(target, immutableHandlers));
 360    return immutableMap.get(target);
 361  };
 362  
 363  // Store stacks for the current scope and the default namespaces and export APIs
 364  // to interact with them.
 365  const scopeStack = [];
 366  const namespaceStack = [];
 367  
 368  /**
 369   * Retrieves the context inherited by the element evaluating a function from the
 370   * store. The returned value depends on the element and the namespace where the
 371   * function calling `getContext()` exists.
 372   *
 373   * @param namespace Store namespace. By default, the namespace where the calling
 374   *                  function exists is used.
 375   * @return The context content.
 376   */
 377  const getContext = namespace => getScope()?.context[namespace || getNamespace()];
 378  
 379  /**
 380   * Retrieves a representation of the element where a function from the store
 381   * is being evalutated. Such representation is read-only, and contains a
 382   * reference to the DOM element, its props and a local reactive state.
 383   *
 384   * @return Element representation.
 385   */
 386  const getElement = () => {
 387    if (!getScope()) {
 388      throw Error('Cannot call `getElement()` outside getters and actions used by directives.');
 389    }
 390    const {
 391      ref,
 392      attributes
 393    } = getScope();
 394    return Object.freeze({
 395      ref: ref.current,
 396      attributes: deepImmutable(attributes)
 397    });
 398  };
 399  const getScope = () => scopeStack.slice(-1)[0];
 400  const setScope = scope => {
 401    scopeStack.push(scope);
 402  };
 403  const resetScope = () => {
 404    scopeStack.pop();
 405  };
 406  const getNamespace = () => namespaceStack.slice(-1)[0];
 407  const setNamespace = namespace => {
 408    namespaceStack.push(namespace);
 409  };
 410  const resetNamespace = () => {
 411    namespaceStack.pop();
 412  };
 413  
 414  // WordPress Directives.
 415  const directiveCallbacks = {};
 416  const directivePriorities = {};
 417  
 418  /**
 419   * Register a new directive type in the Interactivity API runtime.
 420   *
 421   * @example
 422   * ```js
 423   * directive(
 424   *   'alert', // Name without the `data-wp-` prefix.
 425   *   ( { directives: { alert }, element, evaluate } ) => {
 426   *     const defaultEntry = alert.find( entry => entry.suffix === 'default' );
 427   *     element.props.onclick = () => { alert( evaluate( defaultEntry ) ); }
 428   *   }
 429   * )
 430   * ```
 431   *
 432   * The previous code registers a custom directive type for displaying an alert
 433   * message whenever an element using it is clicked. The message text is obtained
 434   * from the store under the inherited namespace, using `evaluate`.
 435   *
 436   * When the HTML is processed by the Interactivity API, any element containing
 437   * the `data-wp-alert` directive will have the `onclick` event handler, e.g.,
 438   *
 439   * ```html
 440   * <div data-wp-interactive='{ "namespace": "messages" }'>
 441   *   <button data-wp-alert="state.alert">Click me!</button>
 442   * </div>
 443   * ```
 444   * Note that, in the previous example, the directive callback gets the path
 445   * value (`state.alert`) from the directive entry with suffix `default`. A
 446   * custom suffix can also be specified by appending `--` to the directive
 447   * attribute, followed by the suffix, like in the following HTML snippet:
 448   *
 449   * ```html
 450   * <div data-wp-interactive='{ "namespace": "myblock" }'>
 451   *   <button
 452   *     data-wp-color--text="state.text"
 453   *     data-wp-color--background="state.background"
 454   *   >Click me!</button>
 455   * </div>
 456   * ```
 457   *
 458   * This could be an hypothetical implementation of the custom directive used in
 459   * the snippet above.
 460   *
 461   * @example
 462   * ```js
 463   * directive(
 464   *   'color', // Name without prefix and suffix.
 465   *   ( { directives: { color }, ref, evaluate } ) =>
 466   *     colors.forEach( ( color ) => {
 467   *       if ( color.suffix = 'text' ) {
 468   *         ref.style.setProperty(
 469   *           'color',
 470   *           evaluate( color.text )
 471   *         );
 472   *       }
 473   *       if ( color.suffix = 'background' ) {
 474   *         ref.style.setProperty(
 475   *           'background-color',
 476   *           evaluate( color.background )
 477   *         );
 478   *       }
 479   *     } );
 480   *   }
 481   * )
 482   * ```
 483   *
 484   * @param name             Directive name, without the `data-wp-` prefix.
 485   * @param callback         Function that runs the directive logic.
 486   * @param options          Options object.
 487   * @param options.priority Option to control the directive execution order. The
 488   *                         lesser, the highest priority. Default is `10`.
 489   */
 490  const directive = (name, callback, {
 491    priority = 10
 492  } = {}) => {
 493    directiveCallbacks[name] = callback;
 494    directivePriorities[name] = priority;
 495  };
 496  
 497  // Resolve the path to some property of the store object.
 498  const resolve = (path, namespace) => {
 499    let resolvedStore = stores.get(namespace);
 500    if (typeof resolvedStore === 'undefined') {
 501      resolvedStore = store(namespace, undefined, {
 502        lock: universalUnlock
 503      });
 504    }
 505    let current = {
 506      ...resolvedStore,
 507      context: getScope().context[namespace]
 508    };
 509    path.split('.').forEach(p => current = current[p]);
 510    return current;
 511  };
 512  
 513  // Generate the evaluate function.
 514  const getEvaluate = ({
 515    scope
 516  }) => (entry, ...args) => {
 517    let {
 518      value: path,
 519      namespace
 520    } = entry;
 521    if (typeof path !== 'string') {
 522      throw new Error('The `value` prop should be a string path');
 523    }
 524    // If path starts with !, remove it and save a flag.
 525    const hasNegationOperator = path[0] === '!' && !!(path = path.slice(1));
 526    setScope(scope);
 527    const value = resolve(path, namespace);
 528    const result = typeof value === 'function' ? value(...args) : value;
 529    resetScope();
 530    return hasNegationOperator ? !result : result;
 531  };
 532  
 533  // Separate directives by priority. The resulting array contains objects
 534  // of directives grouped by same priority, and sorted in ascending order.
 535  const getPriorityLevels = directives => {
 536    const byPriority = Object.keys(directives).reduce((obj, name) => {
 537      if (directiveCallbacks[name]) {
 538        const priority = directivePriorities[name];
 539        (obj[priority] = obj[priority] || []).push(name);
 540      }
 541      return obj;
 542    }, {});
 543    return Object.entries(byPriority).sort(([p1], [p2]) => parseInt(p1) - parseInt(p2)).map(([, arr]) => arr);
 544  };
 545  
 546  // Component that wraps each priority level of directives of an element.
 547  const Directives = ({
 548    directives,
 549    priorityLevels: [currentPriorityLevel, ...nextPriorityLevels],
 550    element,
 551    originalProps,
 552    previousScope
 553  }) => {
 554    // Initialize the scope of this element. These scopes are different per each
 555    // level because each level has a different context, but they share the same
 556    // element ref, state and props.
 557    const scope = hooks_module_F({}).current;
 558    scope.evaluate = hooks_module_x(getEvaluate({
 559      scope
 560    }), []);
 561    scope.context = hooks_module_P(context);
 562    /* eslint-disable react-hooks/rules-of-hooks */
 563    scope.ref = previousScope?.ref || hooks_module_F(null);
 564    /* eslint-enable react-hooks/rules-of-hooks */
 565  
 566    // Create a fresh copy of the vnode element and add the props to the scope,
 567    // named as attributes (HTML Attributes).
 568    element = F(element, {
 569      ref: scope.ref
 570    });
 571    scope.attributes = element.props;
 572  
 573    // Recursively render the wrapper for the next priority level.
 574    const children = nextPriorityLevels.length > 0 ? y(Directives, {
 575      directives: directives,
 576      priorityLevels: nextPriorityLevels,
 577      element: element,
 578      originalProps: originalProps,
 579      previousScope: scope
 580    }) : element;
 581    const props = {
 582      ...originalProps,
 583      children
 584    };
 585    const directiveArgs = {
 586      directives,
 587      props,
 588      element,
 589      context,
 590      evaluate: scope.evaluate
 591    };
 592    setScope(scope);
 593    for (const directiveName of currentPriorityLevel) {
 594      const wrapper = directiveCallbacks[directiveName]?.(directiveArgs);
 595      if (wrapper !== undefined) props.children = wrapper;
 596    }
 597    resetScope();
 598    return props.children;
 599  };
 600  
 601  // Preact Options Hook called each time a vnode is created.
 602  const old = l.vnode;
 603  l.vnode = vnode => {
 604    if (vnode.props.__directives) {
 605      const props = vnode.props;
 606      const directives = props.__directives;
 607      if (directives.key) vnode.key = directives.key.find(({
 608        suffix
 609      }) => suffix === 'default').value;
 610      delete props.__directives;
 611      const priorityLevels = getPriorityLevels(directives);
 612      if (priorityLevels.length > 0) {
 613        vnode.props = {
 614          directives,
 615          priorityLevels,
 616          originalProps: props,
 617          type: vnode.type,
 618          element: y(vnode.type, props),
 619          top: true
 620        };
 621        vnode.type = Directives;
 622      }
 623    }
 624    if (old) old(vnode);
 625  };
 626  
 627  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/utils.js
 628  /**
 629   * External dependencies
 630   */
 631  
 632  
 633  
 634  /**
 635   * Internal dependencies
 636   */
 637  
 638  const afterNextFrame = callback => {
 639    return new Promise(resolve => {
 640      const done = () => {
 641        clearTimeout(timeout);
 642        window.cancelAnimationFrame(raf);
 643        setTimeout(() => {
 644          callback();
 645          resolve();
 646        });
 647      };
 648      const timeout = setTimeout(done, 100);
 649      const raf = window.requestAnimationFrame(done);
 650    });
 651  };
 652  
 653  // Using the mangled properties:
 654  // this.c: this._callback
 655  // this.x: this._compute
 656  // https://github.com/preactjs/signals/blob/main/mangle.json
 657  function createFlusher(compute, notify) {
 658    let flush;
 659    const dispose = signals_core_module_O(function () {
 660      flush = this.c.bind(this);
 661      this.x = compute;
 662      this.c = notify;
 663      return compute();
 664    });
 665    return {
 666      flush,
 667      dispose
 668    };
 669  }
 670  
 671  // Version of `useSignalEffect` with a `useEffect`-like execution. This hook
 672  // implementation comes from this PR, but we added short-cirtuiting to avoid
 673  // infinite loops: https://github.com/preactjs/signals/pull/290
 674  function utils_useSignalEffect(callback) {
 675    hooks_module_(() => {
 676      let eff = null;
 677      let isExecuting = false;
 678      const notify = async () => {
 679        if (eff && !isExecuting) {
 680          isExecuting = true;
 681          await afterNextFrame(eff.flush);
 682          isExecuting = false;
 683        }
 684      };
 685      eff = createFlusher(callback, notify);
 686      return eff.dispose;
 687    }, []);
 688  }
 689  
 690  /**
 691   * Returns the passed function wrapped with the current scope so it is
 692   * accessible whenever the function runs. This is primarily to make the scope
 693   * available inside hook callbacks.
 694   *
 695   * @param {Function} func The passed function.
 696   * @return {Function} The wrapped function.
 697   */
 698  const withScope = func => {
 699    const scope = getScope();
 700    const ns = getNamespace();
 701    if (func?.constructor?.name === 'GeneratorFunction') {
 702      return async (...args) => {
 703        const gen = func(...args);
 704        let value;
 705        let it;
 706        while (true) {
 707          setNamespace(ns);
 708          setScope(scope);
 709          try {
 710            it = gen.next(value);
 711          } finally {
 712            resetNamespace();
 713            resetScope();
 714          }
 715          try {
 716            value = await it.value;
 717          } catch (e) {
 718            gen.throw(e);
 719          }
 720          if (it.done) break;
 721        }
 722        return value;
 723      };
 724    }
 725    return (...args) => {
 726      setNamespace(ns);
 727      setScope(scope);
 728      try {
 729        return func(...args);
 730      } finally {
 731        resetNamespace();
 732        resetScope();
 733      }
 734    };
 735  };
 736  
 737  /**
 738   * Accepts a function that contains imperative code which runs whenever any of
 739   * the accessed _reactive_ properties (e.g., values from the global state or the
 740   * context) is modified.
 741   *
 742   * This hook makes the element's scope available so functions like
 743   * `getElement()` and `getContext()` can be used inside the passed callback.
 744   *
 745   * @param {Function} callback The hook callback.
 746   */
 747  function useWatch(callback) {
 748    utils_useSignalEffect(withScope(callback));
 749  }
 750  
 751  /**
 752   * Accepts a function that contains imperative code which runs only after the
 753   * element's first render, mainly useful for intialization logic.
 754   *
 755   * This hook makes the element's scope available so functions like
 756   * `getElement()` and `getContext()` can be used inside the passed callback.
 757   *
 758   * @param {Function} callback The hook callback.
 759   */
 760  function useInit(callback) {
 761    hooks_module_(withScope(callback), []);
 762  }
 763  
 764  /**
 765   * Accepts a function that contains imperative, possibly effectful code. The
 766   * effects run after browser paint, without blocking it.
 767   *
 768   * This hook is equivalent to Preact's `useEffect` and makes the element's scope
 769   * available so functions like `getElement()` and `getContext()` can be used
 770   * inside the passed callback.
 771   *
 772   * @param {Function} callback Imperative function that can return a cleanup
 773   *                            function.
 774   * @param {any[]}    inputs   If present, effect will only activate if the
 775   *                            values in the list change (using `===`).
 776   */
 777  function useEffect(callback, inputs) {
 778    hooks_module_(withScope(callback), inputs);
 779  }
 780  
 781  /**
 782   * Accepts a function that contains imperative, possibly effectful code. Use
 783   * this to read layout from the DOM and synchronously re-render.
 784   *
 785   * This hook is equivalent to Preact's `useLayoutEffect` and makes the element's
 786   * scope available so functions like `getElement()` and `getContext()` can be
 787   * used inside the passed callback.
 788   *
 789   * @param {Function} callback Imperative function that can return a cleanup
 790   *                            function.
 791   * @param {any[]}    inputs   If present, effect will only activate if the
 792   *                            values in the list change (using `===`).
 793   */
 794  function useLayoutEffect(callback, inputs) {
 795    hooks_module_A(withScope(callback), inputs);
 796  }
 797  
 798  /**
 799   * Returns a memoized version of the callback that only changes if one of the
 800   * inputs has changed (using `===`).
 801   *
 802   * This hook is equivalent to Preact's `useCallback` and makes the element's
 803   * scope available so functions like `getElement()` and `getContext()` can be
 804   * used inside the passed callback.
 805   *
 806   * @param {Function} callback Imperative function that can return a cleanup
 807   *                            function.
 808   * @param {any[]}    inputs   If present, effect will only activate if the
 809   *                            values in the list change (using `===`).
 810   */
 811  function useCallback(callback, inputs) {
 812    hooks_module_x(withScope(callback), inputs);
 813  }
 814  
 815  /**
 816   * Pass a factory function and an array of inputs. `useMemo` will only recompute
 817   * the memoized value when one of the inputs has changed.
 818   *
 819   * This hook is equivalent to Preact's `useMemo` and makes the element's scope
 820   * available so functions like `getElement()` and `getContext()` can be used
 821   * inside the passed factory function.
 822   *
 823   * @param {Function} factory Imperative function that can return a cleanup
 824   *                           function.
 825   * @param {any[]}    inputs  If present, effect will only activate if the
 826   *                           values in the list change (using `===`).
 827   */
 828  function useMemo(factory, inputs) {
 829    hooks_module_q(withScope(factory), inputs);
 830  }
 831  
 832  // For wrapperless hydration.
 833  // See https://gist.github.com/developit/f4c67a2ede71dc2fab7f357f39cff28c
 834  const createRootFragment = (parent, replaceNode) => {
 835    replaceNode = [].concat(replaceNode);
 836    const s = replaceNode[replaceNode.length - 1].nextSibling;
 837    function insert(c, r) {
 838      parent.insertBefore(c, r || s);
 839    }
 840    return parent.__k = {
 841      nodeType: 1,
 842      parentNode: parent,
 843      firstChild: replaceNode[0],
 844      childNodes: replaceNode,
 845      insertBefore: insert,
 846      appendChild: insert,
 847      removeChild(c) {
 848        parent.removeChild(c);
 849      }
 850    };
 851  };
 852  
 853  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/utils/kebab-to-camelcase.js
 854  /**
 855   * Transforms a kebab-case string to camelCase.
 856   *
 857   * @param {string} str The kebab-case string to transform to camelCase.
 858   * @return {string} The transformed camelCase string.
 859   */
 860  function kebabToCamelCase(str) {
 861    return str.replace(/^-+|-+$/g, '').toLowerCase().replace(/-([a-z])/g, function (match, group1) {
 862      return group1.toUpperCase();
 863    });
 864  }
 865  
 866  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/directives.js
 867  /* @jsx createElement */
 868  
 869  /**
 870   * External dependencies
 871   */
 872  
 873  
 874  
 875  
 876  /**
 877   * Internal dependencies
 878   */
 879  
 880  
 881  
 882  
 883  // Assigned objects should be ignore during proxification.
 884  const contextAssignedObjects = new WeakMap();
 885  
 886  // Store the context proxy and fallback for each object in the context.
 887  const contextObjectToProxy = new WeakMap();
 888  const contextProxyToObject = new WeakMap();
 889  const contextObjectToFallback = new WeakMap();
 890  const isPlainObject = item => item && typeof item === 'object' && item.constructor === Object;
 891  const descriptor = Reflect.getOwnPropertyDescriptor;
 892  
 893  /**
 894   * Wrap a context object with a proxy to reproduce the context stack. The proxy
 895   * uses the passed `inherited` context as a fallback to look up for properties
 896   * that don't exist in the given context. Also, updated properties are modified
 897   * where they are defined, or added to the main context when they don't exist.
 898   *
 899   * By default, all plain objects inside the context are wrapped, unless it is
 900   * listed in the `ignore` option.
 901   *
 902   * @param {Object} current   Current context.
 903   * @param {Object} inherited Inherited context, used as fallback.
 904   *
 905   * @return {Object} The wrapped context object.
 906   */
 907  const proxifyContext = (current, inherited = {}) => {
 908    // Update the fallback object reference when it changes.
 909    contextObjectToFallback.set(current, inherited);
 910    if (!contextObjectToProxy.has(current)) {
 911      const proxy = new Proxy(current, {
 912        get: (target, k) => {
 913          const fallback = contextObjectToFallback.get(current);
 914          // Always subscribe to prop changes in the current context.
 915          const currentProp = target[k];
 916  
 917          // Return the inherited prop when missing in target.
 918          if (!(k in target) && k in fallback) {
 919            return fallback[k];
 920          }
 921  
 922          // Proxify plain objects that were not directly assigned.
 923          if (k in target && !contextAssignedObjects.get(target)?.has(k) && isPlainObject(deepsignal_module_p(target, k))) {
 924            return proxifyContext(currentProp, fallback[k]);
 925          }
 926  
 927          // Return the stored proxy for `currentProp` when it exists.
 928          if (contextObjectToProxy.has(currentProp)) {
 929            return contextObjectToProxy.get(currentProp);
 930          }
 931  
 932          /*
 933           * For other cases, return the value from target, also
 934           * subscribing to changes in the parent context when the current
 935           * prop is not defined.
 936           */
 937          return k in target ? currentProp : fallback[k];
 938        },
 939        set: (target, k, value) => {
 940          const fallback = contextObjectToFallback.get(current);
 941          const obj = k in target || !(k in fallback) ? target : fallback;
 942  
 943          /*
 944           * Assigned object values should not be proxified so they point
 945           * to the original object and don't inherit unexpected
 946           * properties.
 947           */
 948          if (value && typeof value === 'object') {
 949            if (!contextAssignedObjects.has(obj)) {
 950              contextAssignedObjects.set(obj, new Set());
 951            }
 952            contextAssignedObjects.get(obj).add(k);
 953          }
 954  
 955          /*
 956           * When the value is a proxy, it's because it comes from the
 957           * context, so the inner value is assigned instead.
 958           */
 959          if (contextProxyToObject.has(value)) {
 960            const innerValue = contextProxyToObject.get(value);
 961            obj[k] = innerValue;
 962          } else {
 963            obj[k] = value;
 964          }
 965          return true;
 966        },
 967        ownKeys: target => [...new Set([...Object.keys(contextObjectToFallback.get(current)), ...Object.keys(target)])],
 968        getOwnPropertyDescriptor: (target, k) => descriptor(target, k) || descriptor(contextObjectToFallback.get(current), k)
 969      });
 970      contextObjectToProxy.set(current, proxy);
 971      contextProxyToObject.set(proxy, current);
 972    }
 973    return contextObjectToProxy.get(current);
 974  };
 975  
 976  /**
 977   * Recursively update values within a deepSignal object.
 978   *
 979   * @param {Object} target A deepSignal instance.
 980   * @param {Object} source Object with properties to update in `target`
 981   */
 982  const updateSignals = (target, source) => {
 983    for (const k in source) {
 984      if (isPlainObject(deepsignal_module_p(target, k)) && isPlainObject(deepsignal_module_p(source, k))) {
 985        updateSignals(target[`$$k}`].peek(), source[k]);
 986      } else {
 987        target[k] = source[k];
 988      }
 989    }
 990  };
 991  
 992  /**
 993   * Recursively clone the passed object.
 994   *
 995   * @param {Object} source Source object.
 996   * @return {Object} Cloned object.
 997   */
 998  const deepClone = source => {
 999    if (isPlainObject(source)) {
1000      return Object.fromEntries(Object.entries(source).map(([key, value]) => [key, deepClone(value)]));
1001    }
1002    if (Array.isArray(source)) {
1003      return source.map(i => deepClone(i));
1004    }
1005    return source;
1006  };
1007  const newRule = /(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g;
1008  const ruleClean = /\/\*[^]*?\*\/|  +/g;
1009  const ruleNewline = /\n+/g;
1010  const empty = ' ';
1011  
1012  /**
1013   * Convert a css style string into a object.
1014   *
1015   * Made by Cristian Bote (@cristianbote) for Goober.
1016   * https://unpkg.com/browse/goober@2.1.13/src/core/astish.js
1017   *
1018   * @param {string} val CSS string.
1019   * @return {Object} CSS object.
1020   */
1021  const cssStringToObject = val => {
1022    const tree = [{}];
1023    let block, left;
1024    while (block = newRule.exec(val.replace(ruleClean, ''))) {
1025      if (block[4]) {
1026        tree.shift();
1027      } else if (block[3]) {
1028        left = block[3].replace(ruleNewline, empty).trim();
1029        tree.unshift(tree[0][left] = tree[0][left] || {});
1030      } else {
1031        tree[0][block[1]] = block[2].replace(ruleNewline, empty).trim();
1032      }
1033    }
1034    return tree[0];
1035  };
1036  
1037  /**
1038   * Creates a directive that adds an event listener to the global window or
1039   * document object.
1040   *
1041   * @param {string} type 'window' or 'document'
1042   * @return {void}
1043   */
1044  const getGlobalEventDirective = type => ({
1045    directives,
1046    evaluate
1047  }) => {
1048    directives[`on-$type}`].filter(({
1049      suffix
1050    }) => suffix !== 'default').forEach(entry => {
1051      useInit(() => {
1052        const cb = event => evaluate(entry, event);
1053        const globalVar = type === 'window' ? window : document;
1054        globalVar.addEventListener(entry.suffix, cb);
1055        return () => globalVar.removeEventListener(entry.suffix, cb);
1056      }, []);
1057    });
1058  };
1059  /* harmony default export */ const directives = (() => {
1060    // data-wp-context
1061    directive('context', ({
1062      directives: {
1063        context
1064      },
1065      props: {
1066        children
1067      },
1068      context: inheritedContext
1069    }) => {
1070      const {
1071        Provider
1072      } = inheritedContext;
1073      const inheritedValue = hooks_module_P(inheritedContext);
1074      const currentValue = hooks_module_F(deepsignal_module_g({}));
1075      const defaultEntry = context.find(({
1076        suffix
1077      }) => suffix === 'default');
1078  
1079      // No change should be made if `defaultEntry` does not exist.
1080      const contextStack = hooks_module_q(() => {
1081        if (defaultEntry) {
1082          const {
1083            namespace,
1084            value
1085          } = defaultEntry;
1086          updateSignals(currentValue.current, {
1087            [namespace]: deepClone(value)
1088          });
1089        }
1090        return proxifyContext(currentValue.current, inheritedValue);
1091      }, [defaultEntry, inheritedValue]);
1092      return y(Provider, {
1093        value: contextStack
1094      }, children);
1095    }, {
1096      priority: 5
1097    });
1098  
1099    // data-wp-watch--[name]
1100    directive('watch', ({
1101      directives: {
1102        watch
1103      },
1104      evaluate
1105    }) => {
1106      watch.forEach(entry => {
1107        useWatch(() => evaluate(entry));
1108      });
1109    });
1110  
1111    // data-wp-init--[name]
1112    directive('init', ({
1113      directives: {
1114        init
1115      },
1116      evaluate
1117    }) => {
1118      init.forEach(entry => {
1119        // TODO: Replace with useEffect to prevent unneeded scopes.
1120        useInit(() => evaluate(entry));
1121      });
1122    });
1123  
1124    // data-wp-on--[event]
1125    directive('on', ({
1126      directives: {
1127        on
1128      },
1129      element,
1130      evaluate
1131    }) => {
1132      on.filter(({
1133        suffix
1134      }) => suffix !== 'default').forEach(entry => {
1135        element.props[`on$entry.suffix}`] = event => {
1136          evaluate(entry, event);
1137        };
1138      });
1139    });
1140  
1141    // data-wp-on-window--[event]
1142    directive('on-window', getGlobalEventDirective('window'));
1143    // data-wp-on-document--[event]
1144    directive('on-document', getGlobalEventDirective('document'));
1145  
1146    // data-wp-class--[classname]
1147    directive('class', ({
1148      directives: {
1149        class: classNames
1150      },
1151      element,
1152      evaluate
1153    }) => {
1154      classNames.filter(({
1155        suffix
1156      }) => suffix !== 'default').forEach(entry => {
1157        const className = entry.suffix;
1158        const result = evaluate(entry);
1159        const currentClass = element.props.class || '';
1160        const classFinder = new RegExp(`(^|\\s)$className}(\\s|$)`, 'g');
1161        if (!result) element.props.class = currentClass.replace(classFinder, ' ').trim();else if (!classFinder.test(currentClass)) element.props.class = currentClass ? `$currentClass} $className}` : className;
1162        useInit(() => {
1163          /*
1164           * This seems necessary because Preact doesn't change the class
1165           * names on the hydration, so we have to do it manually. It doesn't
1166           * need deps because it only needs to do it the first time.
1167           */
1168          if (!result) {
1169            element.ref.current.classList.remove(className);
1170          } else {
1171            element.ref.current.classList.add(className);
1172          }
1173        });
1174      });
1175    });
1176  
1177    // data-wp-style--[style-prop]
1178    directive('style', ({
1179      directives: {
1180        style
1181      },
1182      element,
1183      evaluate
1184    }) => {
1185      style.filter(({
1186        suffix
1187      }) => suffix !== 'default').forEach(entry => {
1188        const styleProp = entry.suffix;
1189        const result = evaluate(entry);
1190        element.props.style = element.props.style || {};
1191        if (typeof element.props.style === 'string') element.props.style = cssStringToObject(element.props.style);
1192        if (!result) delete element.props.style[styleProp];else element.props.style[styleProp] = result;
1193        useInit(() => {
1194          /*
1195           * This seems necessary because Preact doesn't change the styles on
1196           * the hydration, so we have to do it manually. It doesn't need deps
1197           * because it only needs to do it the first time.
1198           */
1199          if (!result) {
1200            element.ref.current.style.removeProperty(styleProp);
1201          } else {
1202            element.ref.current.style[styleProp] = result;
1203          }
1204        });
1205      });
1206    });
1207  
1208    // data-wp-bind--[attribute]
1209    directive('bind', ({
1210      directives: {
1211        bind
1212      },
1213      element,
1214      evaluate
1215    }) => {
1216      bind.filter(({
1217        suffix
1218      }) => suffix !== 'default').forEach(entry => {
1219        const attribute = entry.suffix;
1220        const result = evaluate(entry);
1221        element.props[attribute] = result;
1222  
1223        /*
1224         * This is necessary because Preact doesn't change the attributes on the
1225         * hydration, so we have to do it manually. It only needs to do it the
1226         * first time. After that, Preact will handle the changes.
1227         */
1228        useInit(() => {
1229          const el = element.ref.current;
1230  
1231          /*
1232           * We set the value directly to the corresponding HTMLElement instance
1233           * property excluding the following special cases. We follow Preact's
1234           * logic: https://github.com/preactjs/preact/blob/ea49f7a0f9d1ff2c98c0bdd66aa0cbc583055246/src/diff/props.js#L110-L129
1235           */
1236          if (attribute === 'style') {
1237            if (typeof result === 'string') el.style.cssText = result;
1238            return;
1239          } else if (attribute !== 'width' && attribute !== 'height' && attribute !== 'href' && attribute !== 'list' && attribute !== 'form' &&
1240          /*
1241           * The value for `tabindex` follows the parsing rules for an
1242           * integer. If that fails, or if the attribute isn't present, then
1243           * the browsers should "follow platform conventions to determine if
1244           * the element should be considered as a focusable area",
1245           * practically meaning that most elements get a default of `-1` (not
1246           * focusable), but several also get a default of `0` (focusable in
1247           * order after all elements with a positive `tabindex` value).
1248           *
1249           * @see https://html.spec.whatwg.org/#tabindex-value
1250           */
1251          attribute !== 'tabIndex' && attribute !== 'download' && attribute !== 'rowSpan' && attribute !== 'colSpan' && attribute !== 'role' && attribute in el) {
1252            try {
1253              el[attribute] = result === null || result === undefined ? '' : result;
1254              return;
1255            } catch (err) {}
1256          }
1257          /*
1258           * aria- and data- attributes have no boolean representation.
1259           * A `false` value is different from the attribute not being
1260           * present, so we can't remove it.
1261           * We follow Preact's logic: https://github.com/preactjs/preact/blob/ea49f7a0f9d1ff2c98c0bdd66aa0cbc583055246/src/diff/props.js#L131C24-L136
1262           */
1263          if (result !== null && result !== undefined && (result !== false || attribute[4] === '-')) {
1264            el.setAttribute(attribute, result);
1265          } else {
1266            el.removeAttribute(attribute);
1267          }
1268        });
1269      });
1270    });
1271  
1272    // data-wp-ignore
1273    directive('ignore', ({
1274      element: {
1275        type: Type,
1276        props: {
1277          innerHTML,
1278          ...rest
1279        }
1280      }
1281    }) => {
1282      // Preserve the initial inner HTML.
1283      const cached = hooks_module_q(() => innerHTML, []);
1284      return y(Type, {
1285        dangerouslySetInnerHTML: {
1286          __html: cached
1287        },
1288        ...rest
1289      });
1290    });
1291  
1292    // data-wp-text
1293    directive('text', ({
1294      directives: {
1295        text
1296      },
1297      element,
1298      evaluate
1299    }) => {
1300      const entry = text.find(({
1301        suffix
1302      }) => suffix === 'default');
1303      try {
1304        const result = evaluate(entry);
1305        element.props.children = typeof result === 'object' ? null : result.toString();
1306      } catch (e) {
1307        element.props.children = null;
1308      }
1309    });
1310  
1311    // data-wp-run
1312    directive('run', ({
1313      directives: {
1314        run
1315      },
1316      evaluate
1317    }) => {
1318      run.forEach(entry => evaluate(entry));
1319    });
1320  
1321    // data-wp-each--[item]
1322    directive('each', ({
1323      directives: {
1324        each,
1325        'each-key': eachKey
1326      },
1327      context: inheritedContext,
1328      element,
1329      evaluate
1330    }) => {
1331      if (element.type !== 'template') return;
1332      const {
1333        Provider
1334      } = inheritedContext;
1335      const inheritedValue = hooks_module_P(inheritedContext);
1336      const [entry] = each;
1337      const {
1338        namespace,
1339        suffix
1340      } = entry;
1341      const list = evaluate(entry);
1342      return list.map(item => {
1343        const itemProp = suffix === 'default' ? 'item' : kebabToCamelCase(suffix);
1344        const itemContext = deepsignal_module_g({
1345          [namespace]: {}
1346        });
1347        const mergedContext = proxifyContext(itemContext, inheritedValue);
1348  
1349        // Set the item after proxifying the context.
1350        mergedContext[namespace][itemProp] = item;
1351        const scope = {
1352          ...getScope(),
1353          context: mergedContext
1354        };
1355        const key = eachKey ? getEvaluate({
1356          scope
1357        })(eachKey[0]) : item;
1358        return y(Provider, {
1359          value: mergedContext,
1360          key: key
1361        }, element.props.content);
1362      });
1363    }, {
1364      priority: 20
1365    });
1366    directive('each-child', () => null);
1367  });
1368  
1369  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/constants.js
1370  const directivePrefix = 'wp';
1371  
1372  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/vdom.js
1373  /**
1374   * External dependencies
1375   */
1376  
1377  /**
1378   * Internal dependencies
1379   */
1380  
1381  const ignoreAttr = `data-$directivePrefix}-ignore`;
1382  const islandAttr = `data-$directivePrefix}-interactive`;
1383  const fullPrefix = `data-$directivePrefix}-`;
1384  const namespaces = [];
1385  const currentNamespace = () => {
1386    var _namespaces;
1387    return (_namespaces = namespaces[namespaces.length - 1]) !== null && _namespaces !== void 0 ? _namespaces : null;
1388  };
1389  
1390  // Regular expression for directive parsing.
1391  const directiveParser = new RegExp(`^data-$directivePrefix}-` +
1392  // ${p} must be a prefix string, like 'wp'.
1393  // Match alphanumeric characters including hyphen-separated
1394  // segments. It excludes underscore intentionally to prevent confusion.
1395  // E.g., "custom-directive".
1396  '([a-z0-9]+(?:-[a-z0-9]+)*)' +
1397  // (Optional) Match '--' followed by any alphanumeric charachters. It
1398  // excludes underscore intentionally to prevent confusion, but it can
1399  // contain multiple hyphens. E.g., "--custom-prefix--with-more-info".
1400  '(?:--([a-z0-9_-]+))?$', 'i' // Case insensitive.
1401  );
1402  
1403  // Regular expression for reference parsing. It can contain a namespace before
1404  // the reference, separated by `::`, like `some-namespace::state.somePath`.
1405  // Namespaces can contain any alphanumeric characters, hyphens, underscores or
1406  // forward slashes. References don't have any restrictions.
1407  const nsPathRegExp = /^([\w-_\/]+)::(.+)$/;
1408  const hydratedIslands = new WeakSet();
1409  
1410  /**
1411   * Recursive function that transforms a DOM tree into vDOM.
1412   *
1413   * @param {Node} root The root element or node to start traversing on.
1414   * @return {import('preact').VNode[]} The resulting vDOM tree.
1415   */
1416  function toVdom(root) {
1417    const treeWalker = document.createTreeWalker(root, 205 // ELEMENT + TEXT + COMMENT + CDATA_SECTION + PROCESSING_INSTRUCTION
1418    );
1419    function walk(node) {
1420      const {
1421        attributes,
1422        nodeType,
1423        localName
1424      } = node;
1425      if (nodeType === 3) return [node.data];
1426      if (nodeType === 4) {
1427        const next = treeWalker.nextSibling();
1428        node.replaceWith(new window.Text(node.nodeValue));
1429        return [node.nodeValue, next];
1430      }
1431      if (nodeType === 8 || nodeType === 7) {
1432        const next = treeWalker.nextSibling();
1433        node.remove();
1434        return [null, next];
1435      }
1436      const props = {};
1437      const children = [];
1438      const directives = [];
1439      let ignore = false;
1440      let island = false;
1441      for (let i = 0; i < attributes.length; i++) {
1442        const n = attributes[i].name;
1443        if (n[fullPrefix.length] && n.slice(0, fullPrefix.length) === fullPrefix) {
1444          if (n === ignoreAttr) {
1445            ignore = true;
1446          } else {
1447            var _nsPathRegExp$exec$sl;
1448            let [ns, value] = (_nsPathRegExp$exec$sl = nsPathRegExp.exec(attributes[i].value)?.slice(1)) !== null && _nsPathRegExp$exec$sl !== void 0 ? _nsPathRegExp$exec$sl : [null, attributes[i].value];
1449            try {
1450              value = JSON.parse(value);
1451            } catch (e) {}
1452            if (n === islandAttr) {
1453              var _value$namespace;
1454              island = true;
1455              namespaces.push(typeof value === 'string' ? value : (_value$namespace = value?.namespace) !== null && _value$namespace !== void 0 ? _value$namespace : null);
1456            } else {
1457              directives.push([n, ns, value]);
1458            }
1459          }
1460        } else if (n === 'ref') {
1461          continue;
1462        }
1463        props[n] = attributes[i].value;
1464      }
1465      if (ignore && !island) return [y(localName, {
1466        ...props,
1467        innerHTML: node.innerHTML,
1468        __directives: {
1469          ignore: true
1470        }
1471      })];
1472      if (island) hydratedIslands.add(node);
1473      if (directives.length) {
1474        props.__directives = directives.reduce((obj, [name, ns, value]) => {
1475          const [, prefix, suffix = 'default'] = directiveParser.exec(name);
1476          if (!obj[prefix]) obj[prefix] = [];
1477          obj[prefix].push({
1478            namespace: ns !== null && ns !== void 0 ? ns : currentNamespace(),
1479            value,
1480            suffix
1481          });
1482          return obj;
1483        }, {});
1484      }
1485      if (localName === 'template') {
1486        props.content = [...node.content.childNodes].map(childNode => toVdom(childNode));
1487      } else {
1488        let child = treeWalker.firstChild();
1489        if (child) {
1490          while (child) {
1491            const [vnode, nextChild] = walk(child);
1492            if (vnode) children.push(vnode);
1493            child = nextChild || treeWalker.nextSibling();
1494          }
1495          treeWalker.parentNode();
1496        }
1497      }
1498  
1499      // Restore previous namespace.
1500      if (island) namespaces.pop();
1501      return [y(localName, props, children)];
1502    }
1503    return walk(treeWalker.currentNode);
1504  }
1505  
1506  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/init.js
1507  /**
1508   * External dependencies
1509   */
1510  
1511  /**
1512   * Internal dependencies
1513   */
1514  
1515  
1516  
1517  
1518  // Keep the same root fragment for each interactive region node.
1519  const regionRootFragments = new WeakMap();
1520  const getRegionRootFragment = region => {
1521    if (!regionRootFragments.has(region)) {
1522      regionRootFragments.set(region, createRootFragment(region.parentElement, region));
1523    }
1524    return regionRootFragments.get(region);
1525  };
1526  function yieldToMain() {
1527    return new Promise(resolve => {
1528      // TODO: Use scheduler.yield() when available.
1529      setTimeout(resolve, 0);
1530    });
1531  }
1532  
1533  // Initial vDOM regions associated with its DOM element.
1534  const initialVdom = new WeakMap();
1535  
1536  // Initialize the router with the initial DOM.
1537  const init = async () => {
1538    const nodes = document.querySelectorAll(`[data-$directivePrefix}-interactive]`);
1539    for (const node of nodes) {
1540      if (!hydratedIslands.has(node)) {
1541        await yieldToMain();
1542        const fragment = getRegionRootFragment(node);
1543        const vdom = toVdom(node);
1544        initialVdom.set(node, vdom);
1545        await yieldToMain();
1546        E(vdom, fragment);
1547      }
1548    }
1549  };
1550  
1551  ;// CONCATENATED MODULE: ./node_modules/@wordpress/interactivity/build-module/index.js
1552  /**
1553   * External dependencies
1554   */
1555  
1556  
1557  
1558  
1559  /**
1560   * Internal dependencies
1561   */
1562  
1563  
1564  
1565  
1566  
1567  
1568  
1569  
1570  
1571  
1572  const requiredConsent = 'I acknowledge that using private APIs means my theme or plugin will inevitably break in the next version of WordPress.';
1573  const privateApis = lock => {
1574    if (lock === requiredConsent) {
1575      return {
1576        directivePrefix: directivePrefix,
1577        getRegionRootFragment: getRegionRootFragment,
1578        initialVdom: initialVdom,
1579        toVdom: toVdom,
1580        directive: directive,
1581        getNamespace: getNamespace,
1582        h: y,
1583        cloneElement: F,
1584        render: B,
1585        deepSignal: deepsignal_module_g,
1586        parseInitialData: parseInitialData,
1587        populateInitialData: populateInitialData,
1588        batch: signals_core_module_n
1589      };
1590    }
1591    throw new Error('Forbidden access.');
1592  };
1593  document.addEventListener('DOMContentLoaded', async () => {
1594    directives();
1595    await init();
1596  });
1597  
1598  var __webpack_exports__getConfig = __webpack_exports__.zj;
1599  var __webpack_exports__getContext = __webpack_exports__.SD;
1600  var __webpack_exports__getElement = __webpack_exports__.V6;
1601  var __webpack_exports__privateApis = __webpack_exports__.jb;
1602  var __webpack_exports__store = __webpack_exports__.M_;
1603  var __webpack_exports__useCallback = __webpack_exports__.hb;
1604  var __webpack_exports__useEffect = __webpack_exports__.vJ;
1605  var __webpack_exports__useInit = __webpack_exports__.ip;
1606  var __webpack_exports__useLayoutEffect = __webpack_exports__.Nf;
1607  var __webpack_exports__useMemo = __webpack_exports__.Kr;
1608  var __webpack_exports__useRef = __webpack_exports__.li;
1609  var __webpack_exports__useState = __webpack_exports__.J0;
1610  var __webpack_exports__useWatch = __webpack_exports__.FH;
1611  var __webpack_exports__withScope = __webpack_exports__.v4;
1612  export { __webpack_exports__getConfig as getConfig, __webpack_exports__getContext as getContext, __webpack_exports__getElement as getElement, __webpack_exports__privateApis as privateApis, __webpack_exports__store as store, __webpack_exports__useCallback as useCallback, __webpack_exports__useEffect as useEffect, __webpack_exports__useInit as useInit, __webpack_exports__useLayoutEffect as useLayoutEffect, __webpack_exports__useMemo as useMemo, __webpack_exports__useRef as useRef, __webpack_exports__useState as useState, __webpack_exports__useWatch as useWatch, __webpack_exports__withScope as withScope };


Generated : Sat Apr 27 08:20:02 2024 Cross-referenced by PHPXref