2 lines
53 KiB
JavaScript
2 lines
53 KiB
JavaScript
/*! For license information please see subscription-product-onboarding-modal.js.LICENSE.txt */
|
||
(()=>{var e={2485:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function o(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var i=typeof n;if("string"===i||"number"===i)e.push(n);else if(Array.isArray(n)){if(n.length){var s=o.apply(null,n);s&&e.push(s)}}else if("object"===i)if(n.toString===Object.prototype.toString)for(var a in n)r.call(n,a)&&n[a]&&e.push(a);else e.push(n.toString())}}return e.join(" ")}e.exports?(o.default=o,e.exports=o):void 0===(n=function(){return o}.apply(t,[]))||(e.exports=n)}()},8616:e=>{e.exports=function(e,t){var n,r,o=0;function i(){var i,s,a=n,c=arguments.length;e:for(;a;){if(a.args.length===arguments.length){for(s=0;s<c;s++)if(a.args[s]!==arguments[s]){a=a.next;continue e}return a!==n&&(a===r&&(r=a.prev),a.prev.next=a.next,a.next&&(a.next.prev=a.prev),a.next=n,a.prev=null,n.prev=a,n=a),a.val}a=a.next}for(i=new Array(c),s=0;s<c;s++)i[s]=arguments[s];return a={args:i,val:e.apply(null,i)},n?(n.prev=a,a.next=n):r=a,o===t.maxSize?(r=r.prev).next=null:o++,n=a,a.val}return t=t||{},i.clear=function(){n=null,r=null,o=0},i}},5228:e=>{"use strict";var t=Object.getOwnPropertySymbols,n=Object.prototype.hasOwnProperty,r=Object.prototype.propertyIsEnumerable;e.exports=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,o){for(var i,s,a=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(e),c=1;c<arguments.length;c++){for(var l in i=Object(arguments[c]))n.call(i,l)&&(a[l]=i[l]);if(t){s=t(i);for(var u=0;u<s.length;u++)r.call(i,s[u])&&(a[s[u]]=i[s[u]])}}return a}},5606:e=>{var t,n,r=e.exports={};function o(){throw new Error("setTimeout has not been defined")}function i(){throw new Error("clearTimeout has not been defined")}function s(e){if(t===setTimeout)return setTimeout(e,0);if((t===o||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(n){try{return t.call(null,e,0)}catch(n){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:o}catch(e){t=o}try{n="function"==typeof clearTimeout?clearTimeout:i}catch(e){n=i}}();var a,c=[],l=!1,u=-1;function d(){l&&a&&(l=!1,a.length?c=a.concat(c):u=-1,c.length&&p())}function p(){if(!l){var e=s(d);l=!0;for(var t=c.length;t;){for(a=c,c=[];++u<t;)a&&a[u].run();u=-1,t=c.length}a=null,l=!1,function(e){if(n===clearTimeout)return clearTimeout(e);if((n===i||!n)&&clearTimeout)return n=clearTimeout,clearTimeout(e);try{return n(e)}catch(t){try{return n.call(null,e)}catch(t){return n.call(this,e)}}}(e)}}function f(e,t){this.fun=e,this.array=t}function m(){}r.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)t[n-1]=arguments[n];c.push(new f(e,t)),1!==c.length||l||s(p)},f.prototype.run=function(){this.fun.apply(null,this.array)},r.title="browser",r.browser=!0,r.env={},r.argv=[],r.version="",r.versions={},r.on=m,r.addListener=m,r.once=m,r.off=m,r.removeListener=m,r.removeAllListeners=m,r.emit=m,r.prependListener=m,r.prependOnceListener=m,r.listeners=function(e){return[]},r.binding=function(e){throw new Error("process.binding is not supported")},r.cwd=function(){return"/"},r.chdir=function(e){throw new Error("process.chdir is not supported")},r.umask=function(){return 0}},1020:(e,t,n)=>{"use strict";n(5228);var r=n(1609),o=60103;if("function"==typeof Symbol&&Symbol.for){var i=Symbol.for;o=i("react.element"),i("react.fragment")}var s=r.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a=Object.prototype.hasOwnProperty,c={key:!0,ref:!0,__self:!0,__source:!0};function l(e,t,n){var r,i={},l=null,u=null;for(r in void 0!==n&&(l=""+n),void 0!==t.key&&(l=""+t.key),void 0!==t.ref&&(u=t.ref),t)a.call(t,r)&&!c.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps)void 0===i[r]&&(i[r]=t[r]);return{$$typeof:o,type:e,key:l,ref:u,props:i,_owner:s.current}}t.jsx=l,t.jsxs=l},4848:(e,t,n)=>{"use strict";e.exports=n(1020)},1609:e=>{"use strict";e.exports=window.React}},t={};function n(r){var o=t[r];if(void 0!==o)return o.exports;var i=t[r]={exports:{}};return e[r](i,i.exports,n),i.exports}n.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return n.d(t,{a:t}),t},n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{var e;n.g.importScripts&&(e=n.g.location+"");var t=n.g.document;if(!e&&t&&(t.currentScript&&(e=t.currentScript.src),!e)){var r=t.getElementsByTagName("script");if(r.length)for(var o=r.length-1;o>-1&&(!e||!/^http(s?):/.test(e));)e=r[o--].src}if(!e)throw new Error("Automatic publicPath is not supported in this browser");e=e.replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),n.p=e})(),n.p=window.wcpayAssets.url,(()=>{"use strict";var e=n(1609);function t(){return t=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},t.apply(null,arguments)}const r=window.wp.element;var o=n(2485),i=n.n(o);const s=window.lodash,a=window.wp.deprecated;var c=n.n(a);const l=window.wp.compose,u=window.wp.dom,d=window.wp.primitives,p=(0,r.createElement)(d.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(d.Path,{d:"M13 11.8l6.1-6.3-1-1-6.1 6.2-6.1-6.2-1 1 6.1 6.3-6.5 6.7 1 1 6.5-6.6 6.5 6.6 1-1z"})),f=window.wp.i18n;function m(e,t,n){const{defaultView:r}=t,{frameElement:o}=r;if(!o||t===n.ownerDocument)return e;const i=o.getBoundingClientRect();return new r.DOMRect(e.left+i.left,e.top+i.top,e.width,e.height)}let h=0;function g(e){const t=document.scrollingElement||document.body;e&&(h=t.scrollTop);const n=e?"add":"remove";t.classList[n]("lockscroll"),document.documentElement.classList[n]("lockscroll"),e||(t.scrollTop=h)}let v=0;function y(){return(0,r.useEffect)((()=>(0===v&&g(!0),++v,()=>{1===v&&g(!1),--v})),[]),null}window.wp.warning;var w=n(5606);const b=(0,r.createContext)({slots:{},fills:{},registerSlot:()=>{void 0!==w&&w.env},updateSlot:()=>{},unregisterSlot:()=>{},registerFill:()=>{},unregisterFill:()=>{}});function x(e){const t=(0,r.useContext)(b),n=t.slots[e]||{},o=t.fills[e],i=(0,r.useMemo)((()=>o||[]),[o]);return{...n,updateSlot:(0,r.useCallback)((n=>{t.updateSlot(e,n)}),[e,t.updateSlot]),unregisterSlot:(0,r.useCallback)((n=>{t.unregisterSlot(e,n)}),[e,t.unregisterSlot]),fills:i,registerFill:(0,r.useCallback)((n=>{t.registerFill(e,n)}),[e,t.registerFill]),unregisterFill:(0,r.useCallback)((n=>{t.unregisterFill(e,n)}),[e,t.unregisterFill])}}const _=(0,r.createContext)({registerSlot:()=>{},unregisterSlot:()=>{},registerFill:()=>{},unregisterFill:()=>{},getSlot:()=>{},getFills:()=>{},subscribe:()=>{}});function E(e){let{name:t,children:n,registerFill:o,unregisterFill:i}=e;const a=(e=>{const{getSlot:t,subscribe:n}=(0,r.useContext)(_),[o,i]=(0,r.useState)(t(e));return(0,r.useEffect)((()=>(i(t(e)),n((()=>{i(t(e))})))),[e]),o})(t),c=(0,r.useRef)({name:t,children:n});return(0,r.useLayoutEffect)((()=>(o(t,c.current),()=>i(t,c.current))),[]),(0,r.useLayoutEffect)((()=>{c.current.children=n,a&&a.forceUpdate()}),[n]),(0,r.useLayoutEffect)((()=>{t!==c.current.name&&(i(c.current.name,c.current),c.current.name=t,o(t,c.current))}),[t]),a&&a.node?((0,s.isFunction)(n)&&(n=n(a.props.fillProps)),(0,r.createPortal)(n,a.node)):null}const k=e=>(0,r.createElement)(_.Consumer,null,(n=>{let{registerFill:o,unregisterFill:i}=n;return(0,r.createElement)(E,t({},e,{registerFill:o,unregisterFill:i}))}));class C extends r.Component{constructor(){super(...arguments),this.isUnmounted=!1,this.bindNode=this.bindNode.bind(this)}componentDidMount(){const{registerSlot:e}=this.props;e(this.props.name,this)}componentWillUnmount(){const{unregisterSlot:e}=this.props;this.isUnmounted=!0,e(this.props.name,this)}componentDidUpdate(e){const{name:t,unregisterSlot:n,registerSlot:r}=this.props;e.name!==t&&(n(e.name),r(t,this))}bindNode(e){this.node=e}forceUpdate(){this.isUnmounted||super.forceUpdate()}render(){const{children:e,name:t,fillProps:n={},getFills:o}=this.props,i=(0,s.map)(o(t,this),(e=>{const t=(0,s.isFunction)(e.children)?e.children(n):e.children;return r.Children.map(t,((e,t)=>{if(!e||(0,s.isString)(e))return e;const n=e.key||t;return(0,r.cloneElement)(e,{key:n})}))})).filter((0,s.negate)(r.isEmptyElement));return(0,r.createElement)(r.Fragment,null,(0,s.isFunction)(e)?e(i):i)}}const S=e=>(0,r.createElement)(_.Consumer,null,(n=>{let{registerSlot:o,unregisterSlot:i,getFills:s}=n;return(0,r.createElement)(C,t({},e,{registerSlot:o,unregisterSlot:i,getFills:s}))}));var A=function(){function e(e){var t=this;this._insertTag=function(e){var n;n=0===t.tags.length?t.insertionPoint?t.insertionPoint.nextSibling:t.prepend?t.container.firstChild:t.before:t.tags[t.tags.length-1].nextSibling,t.container.insertBefore(e,n),t.tags.push(e)},this.isSpeedy=void 0===e.speedy||e.speedy,this.tags=[],this.ctr=0,this.nonce=e.nonce,this.key=e.key,this.container=e.container,this.prepend=e.prepend,this.insertionPoint=e.insertionPoint,this.before=null}var t=e.prototype;return t.hydrate=function(e){e.forEach(this._insertTag)},t.insert=function(e){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag(function(e){var t=document.createElement("style");return t.setAttribute("data-emotion",e.key),void 0!==e.nonce&&t.setAttribute("nonce",e.nonce),t.appendChild(document.createTextNode("")),t.setAttribute("data-s",""),t}(this));var t=this.tags[this.tags.length-1];if(this.isSpeedy){var n=function(e){if(e.sheet)return e.sheet;for(var t=0;t<document.styleSheets.length;t++)if(document.styleSheets[t].ownerNode===e)return document.styleSheets[t]}(t);try{n.insertRule(e,n.cssRules.length)}catch(e){}}else t.appendChild(document.createTextNode(e));this.ctr++},t.flush=function(){this.tags.forEach((function(e){return e.parentNode&&e.parentNode.removeChild(e)})),this.tags=[],this.ctr=0},e}(),R=Math.abs,O=String.fromCharCode,P=Object.assign;function T(e){return e.trim()}function L(e,t,n){return e.replace(t,n)}function N(e,t){return e.indexOf(t)}function F(e,t){return 0|e.charCodeAt(t)}function j(e,t,n){return e.slice(t,n)}function M(e){return e.length}function D(e){return e.length}function $(e,t){return t.push(e),e}var W=1,I=1,H=0,z=0,B=0,V="";function U(e,t,n,r,o,i,s){return{value:e,root:t,parent:n,type:r,props:o,children:i,line:W,column:I,length:s,return:""}}function q(e,t){return P(U("",null,null,"",null,null,0),e,{length:-e.length},t)}function G(){return B=z>0?F(V,--z):0,I--,10===B&&(I=1,W--),B}function X(){return B=z<H?F(V,z++):0,I++,10===B&&(I=1,W++),B}function K(){return F(V,z)}function Y(){return z}function Z(e,t){return j(V,e,t)}function J(e){switch(e){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function Q(e){return W=I=1,H=M(V=e),z=0,[]}function ee(e){return V="",e}function te(e){return T(Z(z-1,oe(91===e?e+2:40===e?e+1:e)))}function ne(e){for(;(B=K())&&B<33;)X();return J(e)>2||J(B)>3?"":" "}function re(e,t){for(;--t&&X()&&!(B<48||B>102||B>57&&B<65||B>70&&B<97););return Z(e,Y()+(t<6&&32==K()&&32==X()))}function oe(e){for(;X();)switch(B){case e:return z;case 34:case 39:34!==e&&39!==e&&oe(B);break;case 40:41===e&&oe(e);break;case 92:X()}return z}function ie(e,t){for(;X()&&e+B!==57&&(e+B!==84||47!==K()););return"/*"+Z(t,z-1)+"*"+O(47===e?e:X())}function se(e){for(;!J(K());)X();return Z(e,z)}var ae="-ms-",ce="-moz-",le="-webkit-",ue="comm",de="rule",pe="decl",fe="@keyframes";function me(e,t){for(var n="",r=D(e),o=0;o<r;o++)n+=t(e[o],o,e,t)||"";return n}function he(e,t,n,r){switch(e.type){case"@layer":if(e.children.length)break;case"@import":case pe:return e.return=e.return||e.value;case ue:return"";case fe:return e.return=e.value+"{"+me(e.children,r)+"}";case de:e.value=e.props.join(",")}return M(n=me(e.children,r))?e.return=e.value+"{"+n+"}":""}function ge(e){return ee(ve("",null,null,null,[""],e=Q(e),0,[0],e))}function ve(e,t,n,r,o,i,s,a,c){for(var l=0,u=0,d=s,p=0,f=0,m=0,h=1,g=1,v=1,y=0,w="",b=o,x=i,_=r,E=w;g;)switch(m=y,y=X()){case 40:if(108!=m&&58==F(E,d-1)){-1!=N(E+=L(te(y),"&","&\f"),"&\f")&&(v=-1);break}case 34:case 39:case 91:E+=te(y);break;case 9:case 10:case 13:case 32:E+=ne(m);break;case 92:E+=re(Y()-1,7);continue;case 47:switch(K()){case 42:case 47:$(we(ie(X(),Y()),t,n),c);break;default:E+="/"}break;case 123*h:a[l++]=M(E)*v;case 125*h:case 59:case 0:switch(y){case 0:case 125:g=0;case 59+u:-1==v&&(E=L(E,/\f/g,"")),f>0&&M(E)-d&&$(f>32?be(E+";",r,n,d-1):be(L(E," ","")+";",r,n,d-2),c);break;case 59:E+=";";default:if($(_=ye(E,t,n,l,u,o,a,w,b=[],x=[],d),i),123===y)if(0===u)ve(E,t,_,_,b,i,d,a,x);else switch(99===p&&110===F(E,3)?100:p){case 100:case 108:case 109:case 115:ve(e,_,_,r&&$(ye(e,_,_,0,0,o,a,w,o,b=[],d),x),o,x,d,a,r?b:x);break;default:ve(E,_,_,_,[""],x,0,a,x)}}l=u=f=0,h=v=1,w=E="",d=s;break;case 58:d=1+M(E),f=m;default:if(h<1)if(123==y)--h;else if(125==y&&0==h++&&125==G())continue;switch(E+=O(y),y*h){case 38:v=u>0?1:(E+="\f",-1);break;case 44:a[l++]=(M(E)-1)*v,v=1;break;case 64:45===K()&&(E+=te(X())),p=K(),u=d=M(w=E+=se(Y())),y++;break;case 45:45===m&&2==M(E)&&(h=0)}}return i}function ye(e,t,n,r,o,i,s,a,c,l,u){for(var d=o-1,p=0===o?i:[""],f=D(p),m=0,h=0,g=0;m<r;++m)for(var v=0,y=j(e,d+1,d=R(h=s[m])),w=e;v<f;++v)(w=T(h>0?p[v]+" "+y:L(y,/&\f/g,p[v])))&&(c[g++]=w);return U(e,t,n,0===o?de:a,c,l,u)}function we(e,t,n){return U(e,t,n,ue,O(B),j(e,2,-2),0)}function be(e,t,n,r){return U(e,t,n,pe,j(e,0,r),j(e,r+1,-1),r)}var xe=function(e,t,n){for(var r=0,o=0;r=o,o=K(),38===r&&12===o&&(t[n]=1),!J(o);)X();return Z(e,z)},_e=new WeakMap,Ee=function(e){if("rule"===e.type&&e.parent&&!(e.length<1)){for(var t=e.value,n=e.parent,r=e.column===n.column&&e.line===n.line;"rule"!==n.type;)if(!(n=n.parent))return;if((1!==e.props.length||58===t.charCodeAt(0)||_e.get(n))&&!r){_e.set(e,!0);for(var o=[],i=function(e,t){return ee(function(e,t){var n=-1,r=44;do{switch(J(r)){case 0:38===r&&12===K()&&(t[n]=1),e[n]+=xe(z-1,t,n);break;case 2:e[n]+=te(r);break;case 4:if(44===r){e[++n]=58===K()?"&\f":"",t[n]=e[n].length;break}default:e[n]+=O(r)}}while(r=X());return e}(Q(e),t))}(t,o),s=n.props,a=0,c=0;a<i.length;a++)for(var l=0;l<s.length;l++,c++)e.props[c]=o[a]?i[a].replace(/&\f/g,s[l]):s[l]+" "+i[a]}}},ke=function(e){if("decl"===e.type){var t=e.value;108===t.charCodeAt(0)&&98===t.charCodeAt(2)&&(e.return="",e.value="")}};function Ce(e,t){switch(function(e,t){return 45^F(e,0)?(((t<<2^F(e,0))<<2^F(e,1))<<2^F(e,2))<<2^F(e,3):0}(e,t)){case 5103:return le+"print-"+e+e;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return le+e+e;case 5349:case 4246:case 4810:case 6968:case 2756:return le+e+ce+e+ae+e+e;case 6828:case 4268:return le+e+ae+e+e;case 6165:return le+e+ae+"flex-"+e+e;case 5187:return le+e+L(e,/(\w+).+(:[^]+)/,le+"box-$1$2"+ae+"flex-$1$2")+e;case 5443:return le+e+ae+"flex-item-"+L(e,/flex-|-self/,"")+e;case 4675:return le+e+ae+"flex-line-pack"+L(e,/align-content|flex-|-self/,"")+e;case 5548:return le+e+ae+L(e,"shrink","negative")+e;case 5292:return le+e+ae+L(e,"basis","preferred-size")+e;case 6060:return le+"box-"+L(e,"-grow","")+le+e+ae+L(e,"grow","positive")+e;case 4554:return le+L(e,/([^-])(transform)/g,"$1"+le+"$2")+e;case 6187:return L(L(L(e,/(zoom-|grab)/,le+"$1"),/(image-set)/,le+"$1"),e,"")+e;case 5495:case 3959:return L(e,/(image-set\([^]*)/,le+"$1$`$1");case 4968:return L(L(e,/(.+:)(flex-)?(.*)/,le+"box-pack:$3"+ae+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+le+e+e;case 4095:case 3583:case 4068:case 2532:return L(e,/(.+)-inline(.+)/,le+"$1$2")+e;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(M(e)-1-t>6)switch(F(e,t+1)){case 109:if(45!==F(e,t+4))break;case 102:return L(e,/(.+:)(.+)-([^]+)/,"$1"+le+"$2-$3$1"+ce+(108==F(e,t+3)?"$3":"$2-$3"))+e;case 115:return~N(e,"stretch")?Ce(L(e,"stretch","fill-available"),t)+e:e}break;case 4949:if(115!==F(e,t+1))break;case 6444:switch(F(e,M(e)-3-(~N(e,"!important")&&10))){case 107:return L(e,":",":"+le)+e;case 101:return L(e,/(.+:)([^;!]+)(;|!.+)?/,"$1"+le+(45===F(e,14)?"inline-":"")+"box$3$1"+le+"$2$3$1"+ae+"$2box$3")+e}break;case 5936:switch(F(e,t+11)){case 114:return le+e+ae+L(e,/[svh]\w+-[tblr]{2}/,"tb")+e;case 108:return le+e+ae+L(e,/[svh]\w+-[tblr]{2}/,"tb-rl")+e;case 45:return le+e+ae+L(e,/[svh]\w+-[tblr]{2}/,"lr")+e}return le+e+ae+e+e}return e}var Se=[function(e,t,n,r){if(e.length>-1&&!e.return)switch(e.type){case pe:e.return=Ce(e.value,e.length);break;case fe:return me([q(e,{value:L(e.value,"@","@"+le)})],r);case de:if(e.length)return function(e,t){return e.map(t).join("")}(e.props,(function(t){switch(function(e){return(e=/(::plac\w+|:read-\w+)/.exec(e))?e[0]:e}(t)){case":read-only":case":read-write":return me([q(e,{props:[L(t,/:(read-\w+)/,":-moz-$1")]})],r);case"::placeholder":return me([q(e,{props:[L(t,/:(plac\w+)/,":"+le+"input-$1")]}),q(e,{props:[L(t,/:(plac\w+)/,":-moz-$1")]}),q(e,{props:[L(t,/:(plac\w+)/,ae+"input-$1")]})],r)}return""}))}}],Ae=function(e){var t=e.key;if("css"===t){var n=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(n,(function(e){-1!==e.getAttribute("data-emotion").indexOf(" ")&&(document.head.appendChild(e),e.setAttribute("data-s",""))}))}var r,o,i=e.stylisPlugins||Se,s={},a=[];r=e.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+t+' "]'),(function(e){for(var t=e.getAttribute("data-emotion").split(" "),n=1;n<t.length;n++)s[t[n]]=!0;a.push(e)}));var c,l,u,d,p=[he,(d=function(e){c.insert(e)},function(e){e.root||(e=e.return)&&d(e)})],f=(l=[Ee,ke].concat(i,p),u=D(l),function(e,t,n,r){for(var o="",i=0;i<u;i++)o+=l[i](e,t,n,r)||"";return o});o=function(e,t,n,r){c=n,me(ge(e?e+"{"+t.styles+"}":t.styles),f),r&&(m.inserted[t.name]=!0)};var m={key:t,sheet:new A({key:t,container:r,nonce:e.nonce,speedy:e.speedy,prepend:e.prepend,insertionPoint:e.insertionPoint}),nonce:e.nonce,inserted:s,registered:{},insert:o};return m.sheet.hydrate(a),m},Re={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function Oe(e){var t=Object.create(null);return function(n){return void 0===t[n]&&(t[n]=e(n)),t[n]}}var Pe=/[A-Z]|^ms/g,Te=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Le=function(e){return 45===e.charCodeAt(1)},Ne=function(e){return null!=e&&"boolean"!=typeof e},Fe=Oe((function(e){return Le(e)?e:e.replace(Pe,"-$&").toLowerCase()})),je=function(e,t){switch(e){case"animation":case"animationName":if("string"==typeof t)return t.replace(Te,(function(e,t,n){return De={name:t,styles:n,next:De},t}))}return 1===Re[e]||Le(e)||"number"!=typeof t||0===t?t:t+"px"};function Me(e,t,n){if(null==n)return"";if(void 0!==n.__emotion_styles)return n;switch(typeof n){case"boolean":return"";case"object":if(1===n.anim)return De={name:n.name,styles:n.styles,next:De},n.name;if(void 0!==n.styles){var r=n.next;if(void 0!==r)for(;void 0!==r;)De={name:r.name,styles:r.styles,next:De},r=r.next;return n.styles+";"}return function(e,t,n){var r="";if(Array.isArray(n))for(var o=0;o<n.length;o++)r+=Me(e,t,n[o])+";";else for(var i in n){var s=n[i];if("object"!=typeof s)null!=t&&void 0!==t[s]?r+=i+"{"+t[s]+"}":Ne(s)&&(r+=Fe(i)+":"+je(i,s)+";");else if(!Array.isArray(s)||"string"!=typeof s[0]||null!=t&&void 0!==t[s[0]]){var a=Me(e,t,s);switch(i){case"animation":case"animationName":r+=Fe(i)+":"+a+";";break;default:r+=i+"{"+a+"}"}}else for(var c=0;c<s.length;c++)Ne(s[c])&&(r+=Fe(i)+":"+je(i,s[c])+";")}return r}(e,t,n);case"function":if(void 0!==e){var o=De,i=n(e);return De=o,Me(e,t,i)}}if(null==t)return n;var s=t[n];return void 0!==s?s:n}var De,$e,We=/label:\s*([^\s;\n{]+)\s*(;|$)/g,Ie=function(e,t,n){if(1===e.length&&"object"==typeof e[0]&&null!==e[0]&&void 0!==e[0].styles)return e[0];var r=!0,o="";De=void 0;var i=e[0];null==i||void 0===i.raw?(r=!1,o+=Me(n,t,i)):o+=i[0];for(var s=1;s<e.length;s++)o+=Me(n,t,e[s]),r&&(o+=i[s]);We.lastIndex=0;for(var a,c="";null!==(a=We.exec(o));)c+="-"+a[1];var l=function(e){for(var t,n=0,r=0,o=e.length;o>=4;++r,o-=4)t=1540483477*(65535&(t=255&e.charCodeAt(r)|(255&e.charCodeAt(++r))<<8|(255&e.charCodeAt(++r))<<16|(255&e.charCodeAt(++r))<<24))+(59797*(t>>>16)<<16),n=1540483477*(65535&(t^=t>>>24))+(59797*(t>>>16)<<16)^1540483477*(65535&n)+(59797*(n>>>16)<<16);switch(o){case 3:n^=(255&e.charCodeAt(r+2))<<16;case 2:n^=(255&e.charCodeAt(r+1))<<8;case 1:n=1540483477*(65535&(n^=255&e.charCodeAt(r)))+(59797*(n>>>16)<<16)}return(((n=1540483477*(65535&(n^=n>>>13))+(59797*(n>>>16)<<16))^n>>>15)>>>0).toString(36)}(o)+c;return{name:l,styles:o,next:De}},He=!!e.useInsertionEffect&&e.useInsertionEffect,ze=He||function(e){return e()},Be=(He||e.useLayoutEffect,e.createContext("undefined"!=typeof HTMLElement?Ae({key:"css"}):null)),Ve=Be.Provider,Ue=e.createContext({}),qe=n(8616),Ge=n.n(qe),Xe=new Uint8Array(16);function Ke(){if(!$e&&!($e="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto)))throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");return $e(Xe)}const Ye=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i;for(var Ze=[],Je=0;Je<256;++Je)Ze.push((Je+256).toString(16).substr(1));const Qe=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=(Ze[e[t+0]]+Ze[e[t+1]]+Ze[e[t+2]]+Ze[e[t+3]]+"-"+Ze[e[t+4]]+Ze[e[t+5]]+"-"+Ze[e[t+6]]+Ze[e[t+7]]+"-"+Ze[e[t+8]]+Ze[e[t+9]]+"-"+Ze[e[t+10]]+Ze[e[t+11]]+Ze[e[t+12]]+Ze[e[t+13]]+Ze[e[t+14]]+Ze[e[t+15]]).toLowerCase();if(!function(e){return"string"==typeof e&&Ye.test(e)}(n))throw TypeError("Stringified UUID is invalid");return n},et=function(e,t,n){var r=(e=e||{}).random||(e.rng||Ke)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,t){n=n||0;for(var o=0;o<16;++o)t[n+o]=r[o];return t}return Qe(r)},tt=new Set,nt=Ge()((e=>{let t=et().replace(/[0-9]/g,"");for(;tt.has(t);)t=et().replace(/[0-9]/g,"");return tt.add(t),Ae({container:e,key:t})}));function rt(e){let{children:t,document:n}=e;if(!n)return null;const o=nt(n.head);return(0,r.createElement)(Ve,{value:o},t)}function ot(){const[,e]=(0,r.useState)({}),t=(0,r.useRef)(!0);return(0,r.useEffect)((()=>()=>{t.current=!1}),[]),()=>{t.current&&e({})}}function it(e){let{name:t,children:n}=e;const o=x(t),i=(0,r.useRef)({rerender:ot()});if((0,r.useEffect)((()=>(o.registerFill(i),()=>{o.unregisterFill(i)})),[o.registerFill,o.unregisterFill]),!o.ref||!o.ref.current)return null;"function"==typeof n&&(n=n(o.fillProps));const s=(0,r.createElement)(rt,{document:o.ref.current.ownerDocument},n);return(0,r.createPortal)(s,o.ref.current)}const st=(0,r.forwardRef)((function(e,n){let{name:o,fillProps:i={},as:s="div",...a}=e;const c=(0,r.useContext)(b),u=(0,r.useRef)();return(0,r.useLayoutEffect)((()=>(c.registerSlot(o,u,i),()=>{c.unregisterSlot(o,u)})),[c.registerSlot,c.unregisterSlot,o]),(0,r.useLayoutEffect)((()=>{c.updateSlot(o,i)})),(0,r.createElement)(s,t({ref:(0,l.useMergeRefs)([n,u])},a))}));function at(e){return(0,r.createElement)(r.Fragment,null,(0,r.createElement)(k,e),(0,r.createElement)(it,e))}const ct=(0,r.forwardRef)(((e,n)=>{let{bubblesVirtually:o,...i}=e;return o?(0,r.createElement)(st,t({},i,{ref:n})):(0,r.createElement)(S,i)}));function lt(e){return"appear"===e?"top":"left"}const ut="Popover",dt=(0,r.createContext)();function pt(e,t){const{paddingTop:n,paddingBottom:r,paddingLeft:o,paddingRight:i}=function(e){return e.ownerDocument.defaultView.getComputedStyle(e)}(t),s=n?parseInt(n,10):0,a=r?parseInt(r,10):0,c=o?parseInt(o,10):0,l=i?parseInt(i,10):0;return{x:e.left+c,y:e.top+s,width:e.width-c-l,height:e.height-s-a,left:e.left+c,right:e.right-l,top:e.top+s,bottom:e.bottom-a}}function ft(e,t,n){n?e.getAttribute(t)!==n&&e.setAttribute(t,n):e.hasAttribute(t)&&e.removeAttribute(t)}function mt(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";e.style[t]!==n&&(e.style[t]=n)}function ht(e,t,n){n?e.classList.contains(t)||e.classList.add(t):e.classList.contains(t)&&e.classList.remove(t)}const gt=(0,r.forwardRef)(((e,n)=>{let{headerTitle:o,onClose:s,children:a,className:c,noArrow:d=!0,isAlternate:h,position:g="bottom right",range:v,focusOnMount:w="firstElement",anchorRef:b,shouldAnchorIncludePadding:_,anchorRect:E,getAnchorRect:k,expandOnMobile:C,animate:S=!0,onFocusOutside:A,__unstableStickyBoundaryElement:R,__unstableSlotName:O=ut,__unstableObserveElement:P,__unstableBoundaryParent:T,__unstableForcePosition:L,__unstableForceXAlignment:N,__unstableEditorCanvasWrapper:F,...j}=e;const M=(0,r.useRef)(null),D=(0,r.useRef)(null),$=(0,r.useRef)(),W=(0,l.useViewportMatch)("medium","<"),[I,H]=(0,r.useState)(),z=(0,r.useContext)(dt)||O,B=x(z),V=C&&W,[U,q]=(0,l.useResizeObserver)();d=V||d,(0,r.useLayoutEffect)((()=>{if(V)return ht($.current,"is-without-arrow",d),ht($.current,"is-alternate",h),ft($.current,"data-x-axis"),ft($.current,"data-y-axis"),mt($.current,"top"),mt($.current,"left"),mt(D.current,"maxHeight"),void mt(D.current,"maxWidth");const e=()=>{if(!$.current||!D.current)return;let e=function(e,t,n){let r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4?arguments[4]:void 0,i=arguments.length>5?arguments[5]:void 0;if(t)return t;if(n){if(!e.current)return;const t=n(e.current);return m(t,t.ownerDocument||e.current.ownerDocument,i)}if(!1!==r){if(!(r&&window.Range&&window.Element&&window.DOMRect))return;if("function"==typeof(null==r?void 0:r.cloneRange))return m((0,u.getRectangleFromRange)(r),r.endContainer.ownerDocument,i);if("function"==typeof(null==r?void 0:r.getBoundingClientRect)){const e=m(r.getBoundingClientRect(),r.ownerDocument,i);return o?e:pt(e,r)}const{top:e,bottom:t}=r,n=e.getBoundingClientRect(),s=t.getBoundingClientRect(),a=m(new window.DOMRect(n.left,n.top,n.width,s.bottom-n.top),e.ownerDocument,i);return o?a:pt(a,r)}if(!e.current)return;const{parentNode:s}=e.current,a=m(s.getBoundingClientRect(),s.ownerDocument,i);return o?a:pt(a,s)}(M,E,k,b,_,$.current);if(!e)return;const{offsetParent:t,ownerDocument:n}=$.current;let r,o=0;if(t&&t!==n.body){const n=t.getBoundingClientRect();o=n.top,e=new window.DOMRect(e.left-n.left,e.top-n.top,e.width,e.height)}T&&(r=$.current.parentElement);const i=q.height?q:D.current.getBoundingClientRect(),{popoverTop:s,popoverLeft:a,xAxis:c,yAxis:l,contentHeight:p,contentWidth:v}=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"top",r=arguments.length>3?arguments[3]:void 0,o=arguments.length>5?arguments[5]:void 0,i=arguments.length>6?arguments[6]:void 0,s=arguments.length>7?arguments[7]:void 0,a=arguments.length>8?arguments[8]:void 0,c=arguments.length>9?arguments[9]:void 0;const[l,u="center",d]=n.split(" "),p=function(e,t,n,r,o,i,s,a,c){const{height:l}=t;if(o){const t=o.getBoundingClientRect(),r=t.top+l-s,i=t.bottom-l-s;if(e.top<=r)return!c||l+10<c.scrollTop+e.top?{yAxis:n,popoverTop:Math.min(e.bottom,r)}:{yAxis:"bottom",popoverTop:Math.min(e.bottom,i)}}let u=e.top+e.height/2;"bottom"===r?u=e.bottom:"top"===r&&(u=e.top);const d={popoverTop:u,contentHeight:(u-l/2>0?l/2:u)+(u+l/2>window.innerHeight?window.innerHeight-u:l/2)},p={popoverTop:e.top,contentHeight:e.top-10-l>0?l:e.top-10},f={popoverTop:e.bottom,contentHeight:e.bottom+10+l>window.innerHeight?window.innerHeight-10-e.bottom:l};let m,h=n,g=null;if(!o&&!a)if("middle"===n&&d.contentHeight===l)h="middle";else if("top"===n&&p.contentHeight===l)h="top";else if("bottom"===n&&f.contentHeight===l)h="bottom";else{h=p.contentHeight>f.contentHeight?"top":"bottom";const e="top"===h?p.contentHeight:f.contentHeight;g=e!==l?e:null}return m="middle"===h?d.popoverTop:"top"===h?p.popoverTop:f.popoverTop,{yAxis:h,popoverTop:m,contentHeight:g}}(e,t,l,d,r,0,o,s,c),m=function(e,t,n,r,o,i,s,a,c){const{width:l}=t;"left"===n&&(0,f.isRTL)()?n="right":"right"===n&&(0,f.isRTL)()&&(n="left"),"left"===r&&(0,f.isRTL)()?r="right":"right"===r&&(0,f.isRTL)()&&(r="left");const u=Math.round(e.left+e.width/2),d={popoverLeft:u,contentWidth:(u-l/2>0?l/2:u)+(u+l/2>window.innerWidth?window.innerWidth-u:l/2)};let p=e.left;"right"===r?p=e.right:"middle"===i||c||(p=u);let m=e.right;"left"===r?m=e.left:"middle"===i||c||(m=u);const h={popoverLeft:p,contentWidth:p-l>0?l:p},g={popoverLeft:m,contentWidth:m+l>window.innerWidth?window.innerWidth-m:l};let v,y=n,w=null;if(!o&&!a)if("center"===n&&d.contentWidth===l)y="center";else if("left"===n&&h.contentWidth===l)y="left";else if("right"===n&&g.contentWidth===l)y="right";else{y=h.contentWidth>g.contentWidth?"left":"right";const e="left"===y?h.contentWidth:g.contentWidth;l>window.innerWidth&&(w=window.innerWidth),e!==l&&(y="center",d.popoverLeft=window.innerWidth/2)}return v="center"===y?d.popoverLeft:"left"===y?h.popoverLeft:g.popoverLeft,s&&(v=Math.min(v,s.offsetLeft+s.offsetWidth-l),(0,f.isRTL)()||(v=Math.max(v,0))),{xAxis:y,popoverLeft:v,contentWidth:w}}(e,t,u,d,r,p.yAxis,i,s,a);return{...m,...p}}(e,i,g,R,$.current,o,r,L,N,F);"number"==typeof s&&"number"==typeof a&&(mt($.current,"top",s+"px"),mt($.current,"left",a+"px")),ht($.current,"is-without-arrow",d||"center"===c&&"middle"===l),ht($.current,"is-alternate",h),ft($.current,"data-x-axis",c),ft($.current,"data-y-axis",l),mt(D.current,"maxHeight","number"==typeof p?p+"px":""),mt(D.current,"maxWidth","number"==typeof v?v+"px":""),H(({left:"right",right:"left"}[c]||"center")+" "+({top:"bottom",bottom:"top"}[l]||"middle"))};e();const{ownerDocument:t}=$.current,{defaultView:n}=t,r=n.setInterval(e,500);let o;const i=()=>{n.cancelAnimationFrame(o),o=n.requestAnimationFrame(e)};n.addEventListener("click",i),n.addEventListener("resize",e),n.addEventListener("scroll",e,!0);const s=function(e){if(e)return e.endContainer?e.endContainer.ownerDocument:e.top?e.top.ownerDocument:e.ownerDocument}(b);let a;return s&&s!==t&&(s.defaultView.addEventListener("resize",e),s.defaultView.addEventListener("scroll",e,!0)),P&&(a=new n.MutationObserver(e),a.observe(P,{attributes:!0})),()=>{var c,l;n.clearInterval(r),n.removeEventListener("resize",e),n.removeEventListener("scroll",e,!0),n.removeEventListener("click",i),n.cancelAnimationFrame(o),s&&s!==t&&(null===(c=s.defaultView)||void 0===c||c.removeEventListener("resize",e),null===(l=s.defaultView)||void 0===l||l.removeEventListener("scroll",e,!0)),a&&a.disconnect()}}),[V,E,k,b,_,g,q,R,P,T]);const G=(e,t)=>{"focus-outside"===e&&A?A(t):s&&s()},[X,K]=(0,l.__experimentalUseDialog)({focusOnMount:w,__unstableOnClose:G,onClose:G}),Y=(0,l.useMergeRefs)([$,X,n]),Z=Boolean(S&&I)&&function(e){if("loading"===e.type)return i()("components-animate__loading");const{type:t,origin:n=lt(t)}=e;if("appear"===t){const[e,t="center"]=n.split(" ");return i()("components-animate__appear",{["is-from-"+t]:"center"!==t,["is-from-"+e]:"middle"!==e})}return"slide-in"===t?i()("components-animate__slide-in","is-from-"+n):void 0}({type:"appear",origin:I});let J=(0,r.createElement)("div",t({className:i()("components-popover",c,Z,{"is-expanded":V,"is-without-arrow":d,"is-alternate":h})},j,{ref:Y},K,{tabIndex:"-1"}),V&&(0,r.createElement)(y,null),V&&(0,r.createElement)("div",{className:"components-popover__header"},(0,r.createElement)("span",{className:"components-popover__header-title"},o),(0,r.createElement)(en,{className:"components-popover__close",icon:p,onClick:s})),(0,r.createElement)("div",{ref:D,className:"components-popover__content"},(0,r.createElement)("div",{style:{position:"relative"}},U,a)));return B.ref&&(J=(0,r.createElement)(at,{name:z},J)),b||E?J:(0,r.createElement)("span",{ref:M},J)}));gt.Slot=(0,r.forwardRef)((function(e,t){let{name:n=ut}=e;return(0,r.createElement)(ct,{bubblesVirtually:!0,name:n,className:"popover-slot",ref:t})})),gt.__unstableSlotNameProvider=dt.Provider;const vt=gt,yt=function(e){let t,n,{shortcut:o,className:i}=e;return o?((0,s.isString)(o)&&(t=o),(0,s.isObject)(o)&&(t=o.display,n=o.ariaLabel),(0,r.createElement)("span",{className:i,"aria-label":n},t)):null},wt=700,bt=(0,r.createElement)("div",{className:"event-catcher"}),xt=e=>{let{eventHandlers:t,child:n,childrenWithPopover:o}=e;return(0,r.cloneElement)((0,r.createElement)("span",{className:"disabled-element-wrapper"},(0,r.cloneElement)(bt,t),(0,r.cloneElement)(n,{children:o})),t)},_t=e=>{let{child:t,eventHandlers:n,childrenWithPopover:o}=e;return(0,r.cloneElement)(t,{...n,children:o})},Et=(e,t,n)=>{if(1!==r.Children.count(e))return;const o=r.Children.only(e);o.props.disabled||"function"==typeof o.props[t]&&o.props[t](n)},kt=function(e){const{children:t,position:n,text:o,shortcut:i,delay:a=wt}=e,[c,u]=(0,r.useState)(!1),[d,p]=(0,r.useState)(!1),f=(0,l.useDebounce)(p,a),m=e=>{Et(t,"onMouseDown",e),document.addEventListener("mouseup",v),u(!0)},h=e=>{Et(t,"onMouseUp",e),document.removeEventListener("mouseup",v),u(!1)},g=e=>"mouseUp"===e?h:"mouseDown"===e?m:void 0,v=g("mouseUp"),y=(e,n)=>r=>{if(Et(t,e,r),r.currentTarget.disabled)return;if("focus"===r.type&&c)return;f.cancel();const o=(0,s.includes)(["focus","mouseenter"],r.type);o!==d&&(n?f(o):p(o))},w=()=>{f.cancel(),document.removeEventListener("mouseup",v)};if((0,r.useEffect)((()=>w),[]),1!==r.Children.count(t))return t;const b={onMouseEnter:y("onMouseEnter",!0),onMouseLeave:y("onMouseLeave"),onClick:y("onClick"),onFocus:y("onFocus"),onBlur:y("onBlur"),onMouseDown:g("mouseDown")},x=r.Children.only(t),{children:_,disabled:E}=x.props,k=E?xt:_t,C=(e=>{let{grandchildren:t,isOver:n,position:o,text:i,shortcut:s}=e;return(0,r.concatChildren)(t,n&&(0,r.createElement)(vt,{focusOnMount:!1,position:o,className:"components-tooltip","aria-hidden":"true",animate:!1,noArrow:!0},i,(0,r.createElement)(yt,{className:"components-tooltip__shortcut",shortcut:s})))})({grandchildren:_,isOver:d,position:n,text:o,shortcut:i});return k({child:x,eventHandlers:b,childrenWithPopover:C})},Ct=function(e){let{icon:n,className:o,...i}=e;const s=["dashicon","dashicons","dashicons-"+n,o].filter(Boolean).join(" ");return(0,r.createElement)("span",t({className:s},i))},St=function(e){let{icon:n=null,size:o=24,...i}=e;if("string"==typeof n)return(0,r.createElement)(Ct,t({icon:n},i));if((0,r.isValidElement)(n)&&Ct===n.type)return(0,r.cloneElement)(n,{...i});if("function"==typeof n)return n.prototype instanceof r.Component?(0,r.createElement)(n,{size:o,...i}):n({size:o,...i});if(n&&("svg"===n.type||n.type===d.SVG)){const e={width:o,height:o,...n.props,...i};return(0,r.createElement)(d.SVG,e)}return(0,r.isValidElement)(n)?(0,r.cloneElement)(n,{size:o,...i}):n};var At=n(5606);const Rt=(0,r.createContext)({}),Ot=()=>(0,r.useContext)(Rt);function Pt(e){let{value:t}=e;const n=Ot(),o=(0,r.useRef)(t);return function(e,n){const i=(0,r.useRef)(!1);(0,r.useEffect)((()=>{i.current?(0,s.isEqual)(o.current,t)&&o.current!==t&&void 0!==At&&At.env:i.current=!0}),n)}(0,[t]),(0,r.useMemo)((()=>(0,s.merge)((0,s.cloneDeep)(n),t)),[n,t])}(0,r.memo)((e=>{let{children:t,value:n}=e;const o=Pt({value:n});return(0,r.createElement)(Rt.Provider,{value:o},t)}));const Tt="data-wp-component",Lt="data-wp-c16t",Nt="__contextSystemKey__",Ft=Ge()((function(e){return`components-${(0,s.kebabCase)(e)}`}));function jt(e,t,n){var r="";return n.split(" ").forEach((function(n){void 0!==e[n]?t.push(e[n]+";"):r+=n+" "})),r}function Mt(e,t){if(void 0===e.inserted[t.name])return e.insert("",t,e.sheet,!0)}function Dt(e,t,n){var r=[],o=jt(e,r,n);return r.length<2?n:o+t(r)}var $t=function e(t){for(var n="",r=0;r<t.length;r++){var o=t[r];if(null!=o){var i=void 0;switch(typeof o){case"boolean":break;case"object":if(Array.isArray(o))i=e(o);else for(var s in i="",o)o[s]&&s&&(i&&(i+=" "),i+=s);break;default:i=o}i&&(n&&(n+=" "),n+=i)}}return n},Wt=function(){var e=Ae({key:"css"});e.sheet.speedy=function(e){this.isSpeedy=e},e.compat=!0;var t=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=Ie(n,e.registered,void 0);return function(e,t){!function(e,t){var n=e.key+"-"+t.name;void 0===e.registered[n]&&(e.registered[n]=t.styles)}(e,t);var n=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var r=t;do{e.insert(t===r?"."+n:"",r,e.sheet,!0),r=r.next}while(void 0!==r)}}(e,o),e.key+"-"+o.name};return{css:t,cx:function(){for(var n=arguments.length,r=new Array(n),o=0;o<n;o++)r[o]=arguments[o];return Dt(e.registered,t,$t(r))},injectGlobal:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=Ie(n,e.registered);Mt(e,o)},keyframes:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];var o=Ie(n,e.registered),i="animation-"+o.name;return Mt(e,{name:o.name,styles:"@keyframes "+i+"{"+o.styles+"}"}),i},hydrate:function(t){t.forEach((function(t){e.inserted[t]=!0}))},flush:function(){e.registered={},e.inserted={},e.sheet.flush()},sheet:e.sheet,cache:e,getRegisteredStyles:jt.bind(null,e.registered),merge:Dt.bind(null,e.registered,t)}}(),It=(Wt.flush,Wt.hydrate,Wt.cx);Wt.merge,Wt.getRegisteredStyles,Wt.injectGlobal,Wt.keyframes,Wt.css,Wt.sheet,Wt.cache;n(5606);var Ht=n(5606);const zt={border:0,clip:"rect(1px, 1px, 1px, 1px)",WebkitClipPath:"inset( 50% )",clipPath:"inset( 50% )",height:"1px",margin:"-1px",overflow:"hidden",padding:0,position:"absolute",width:"1px",wordWrap:"normal"};var Bt=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,Vt=function(e,t,n){var r=e.key+"-"+t.name;!1===n&&void 0===e.registered[r]&&(e.registered[r]=t.styles)},Ut=Oe((function(e){return Bt.test(e)||111===e.charCodeAt(0)&&110===e.charCodeAt(1)&&e.charCodeAt(2)<91})),qt=function(e){return"theme"!==e},Gt=function(e){return"string"==typeof e&&e.charCodeAt(0)>96?Ut:qt},Xt=function(e,t,n){var r;if(t){var o=t.shouldForwardProp;r=e.__emotion_forwardProp&&o?function(t){return e.__emotion_forwardProp(t)&&o(t)}:o}return"function"!=typeof r&&n&&(r=e.__emotion_forwardProp),r},Kt=function(e){var t=e.cache,n=e.serialized,r=e.isStringTag;return Vt(t,n,r),ze((function(){return function(e,t,n){Vt(e,t,n);var r=e.key+"-"+t.name;if(void 0===e.inserted[t.name]){var o=t;do{e.insert(t===o?"."+r:"",o,e.sheet,!0),o=o.next}while(void 0!==o)}}(t,n,r)})),null};const Yt=function n(r,o){var i,s,a=r.__emotion_real===r,c=a&&r.__emotion_base||r;void 0!==o&&(i=o.label,s=o.target);var l=Xt(r,o,a),u=l||Gt(c),d=!u("as");return function(){var p=arguments,f=a&&void 0!==r.__emotion_styles?r.__emotion_styles.slice(0):[];if(void 0!==i&&f.push("label:"+i+";"),null==p[0]||void 0===p[0].raw)f.push.apply(f,p);else{f.push(p[0][0]);for(var m=p.length,h=1;h<m;h++)f.push(p[h],p[0][h])}var g,v=(g=function(t,n,r){var o,i,a,p,m=d&&t.as||c,h="",g=[],v=t;if(null==t.theme){for(var y in v={},t)v[y]=t[y];v.theme=e.useContext(Ue)}"string"==typeof t.className?(o=n.registered,i=g,a=t.className,p="",a.split(" ").forEach((function(e){void 0!==o[e]?i.push(o[e]+";"):p+=e+" "})),h=p):null!=t.className&&(h=t.className+" ");var w=Ie(f.concat(g),n.registered,v);h+=n.key+"-"+w.name,void 0!==s&&(h+=" "+s);var b=d&&void 0===l?Gt(m):u,x={};for(var _ in t)d&&"as"===_||b(_)&&(x[_]=t[_]);return x.className=h,x.ref=r,e.createElement(e.Fragment,null,e.createElement(Kt,{cache:n,serialized:w,isStringTag:"string"==typeof m}),e.createElement(m,x))},(0,e.forwardRef)((function(t,n){var r=(0,e.useContext)(Be);return g(t,r,n)})));return v.displayName=void 0!==i?i:"Styled("+("string"==typeof c?c:c.displayName||c.name||"Component")+")",v.defaultProps=r.defaultProps,v.__emotion_real=v,v.__emotion_base=c,v.__emotion_styles=f,v.__emotion_forwardProp=l,Object.defineProperty(v,"toString",{value:function(){return"."+s}}),v.withComponent=function(e,r){return n(e,t({},o,r,{shouldForwardProp:Xt(v,r,!0)})).apply(void 0,f)},v}}("div",{target:"em57xhy0"})("");Yt.selector=".components-view",Yt.displayName="View";const Zt=Yt,Jt=function(e,t){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};const{memo:o=!1}=n;let i=(0,r.forwardRef)(e);o&&(i=(0,r.memo)(i)),void 0===t&&void 0!==Ht&&Ht.env;let a=i[Nt]||[t];return Array.isArray(t)&&(a=[...a,...t]),"string"==typeof t&&(a=[...a,t]),i.displayName=t,i[Nt]=(0,s.uniq)(a),i.selector=`.${Ft(t)}`,i}((function(n,o){const{style:i,...s}=function(t,n){const o=Ot(),i=(null==o?void 0:o[n])||{},s={[Lt]:!0,...(a=n,{[Tt]:a})};var a;const{_overrides:c,...l}=i,u=Object.entries(l).length?Object.assign({},l,t):t,d=(()=>{const t=(0,e.useContext)(Be),n=(0,r.useCallback)((function(){if(null===t)throw new Error("The `useCx` hook should be only used within a valid Emotion Cache Context");for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return It(...n.map((e=>{return null!=(n=e)&&["name","styles"].every((e=>void 0!==n[e]))?(function(e,t){var n=e.key+"-"+t.name;if(void 0===e.registered[n]&&(e.registered[n]=t.styles),void 0===e.inserted[t.name]){var r=t;do{e.insert(t===r?"."+n:"",r,e.sheet,!0),r=r.next}while(void 0!==r)}}(t,e),`${t.key}-${e.name}`):e;var n})))}),[t]);return n})()(Ft(n),t.className),p="function"==typeof u.renderChildren?u.renderChildren(u):u.children;for(const e in u)s[e]=u[e];for(const e in c)s[e]=c[e];return s.children=p,s.className=d,s}(n,"VisuallyHidden");return(0,r.createElement)(Zt,t({ref:o},s,{style:{...zt,...i||{}}}))}),"VisuallyHidden"),Qt=["onMouseDown","onClick"],en=(0,r.forwardRef)((function e(n,o){const{href:a,target:u,isSmall:d,isPressed:p,isBusy:f,isDestructive:m,className:h,disabled:g,icon:v,iconPosition:y="left",iconSize:w,showTooltip:b,tooltipPosition:x,shortcut:_,label:E,children:k,text:C,variant:S,__experimentalIsFocusable:A,describedBy:R,...O}=function(e){let{isDefault:t,isPrimary:n,isSecondary:r,isTertiary:o,isLink:i,variant:s,...a}=e,l=s;var u,d,p,f,m;return n&&(null!==(u=l)&&void 0!==u||(l="primary")),o&&(null!==(d=l)&&void 0!==d||(l="tertiary")),r&&(null!==(p=l)&&void 0!==p||(l="secondary")),t&&(c()("Button isDefault prop",{since:"5.4",alternative:'variant="secondary"',version:"6.2"}),null!==(f=l)&&void 0!==f||(l="secondary")),i&&(null!==(m=l)&&void 0!==m||(l="link")),{...a,variant:l}}(n),P=(0,l.useInstanceId)(e,"components-button__description"),T=i()("components-button",h,{"is-secondary":"secondary"===S,"is-primary":"primary"===S,"is-small":d,"is-tertiary":"tertiary"===S,"is-pressed":p,"is-busy":f,"is-link":"link"===S,"is-destructive":m,"has-text":!!v&&!!k,"has-icon":!!v}),L=g&&!A,N=void 0===a||L?"button":"a",F="a"===N?{href:a,target:u}:{type:"button",disabled:L,"aria-pressed":p};if(g&&A){F["aria-disabled"]=!0;for(const e of Qt)O[e]=e=>{e.stopPropagation(),e.preventDefault()}}const j=!L&&(b&&E||_||!!E&&(!k||(0,s.isArray)(k)&&!k.length)&&!1!==b),M=R?P:null,D=O["aria-describedby"]||M,$=(0,r.createElement)(N,t({},F,O,{className:T,"aria-label":O["aria-label"]||E,"aria-describedby":D,ref:o}),v&&"left"===y&&(0,r.createElement)(St,{icon:v,size:w}),C&&(0,r.createElement)(r.Fragment,null,C),v&&"right"===y&&(0,r.createElement)(St,{icon:v,size:w}),k);return j?(0,r.createElement)(r.Fragment,null,(0,r.createElement)(kt,{text:R||E,shortcut:_,position:x},$),R&&(0,r.createElement)(Jt,null,(0,r.createElement)("span",{id:M},R))):(0,r.createElement)(r.Fragment,null,$,R&&(0,r.createElement)(Jt,null,(0,r.createElement)("span",{id:M},R)))})),tn=window.wp.keycodes,nn=(0,r.createElement)(d.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,r.createElement)(d.Path,{d:"M12 13.06l3.712 3.713 1.061-1.06L13.061 12l3.712-3.712-1.06-1.06L12 10.938 8.288 7.227l-1.061 1.06L10.939 12l-3.712 3.712 1.06 1.061L12 13.061z"})),rn=new Set(["alert","status","log","marquee","timer"]);let on=[],sn=!1;let an=0;const cn=(0,r.forwardRef)((function e(n,o){const{bodyOpenClassName:a="modal-open",role:c="dialog",title:u=null,focusOnMount:d=!0,shouldCloseOnEsc:p=!0,shouldCloseOnClickOutside:m=!0,isDismissible:h=!0,aria:g={labelledby:null,describedby:null},onRequestClose:v,icon:y,closeButtonLabel:w,children:b,style:x,overlayClassName:_,className:E,contentLabel:k,onKeyDown:C,isFullScreen:S=!1,__experimentalHideHeader:A=!1}=n,R=(0,r.useRef)(),O=(0,l.useInstanceId)(e),P=u?`components-modal-header-${O}`:g.labelledby,T=(0,l.useFocusOnMount)(d),L=(0,l.useConstrainedTabbing)(),N=(0,l.useFocusReturn)(),F=(0,l.__experimentalUseFocusOutside)(v);return(0,r.useEffect)((()=>(an++,1===an&&(function(e){if(sn)return;const t=document.body.children;(0,s.forEach)(t,(t=>{t!==e&&function(e){const t=e.getAttribute("role");return!("SCRIPT"===e.tagName||e.hasAttribute("aria-hidden")||e.hasAttribute("aria-live")||rn.has(t))}(t)&&(t.setAttribute("aria-hidden","true"),on.push(t))})),sn=!0}(R.current),document.body.classList.add(a)),()=>{an--,0===an&&(document.body.classList.remove(a),sn&&((0,s.forEach)(on,(e=>{e.removeAttribute("aria-hidden")})),on=[],sn=!1))})),[]),(0,r.createPortal)((0,r.createElement)("div",{ref:(0,l.useMergeRefs)([R,o]),className:i()("components-modal__screen-overlay",_),onKeyDown:function(e){p&&e.keyCode===tn.ESCAPE&&!e.defaultPrevented&&(e.preventDefault(),v&&v(e))}},(0,r.createElement)(rt,{document},(0,r.createElement)("div",t({className:i()("components-modal__frame",E,{"is-full-screen":S}),style:x,ref:(0,l.useMergeRefs)([L,N,T]),role:c,"aria-label":k,"aria-labelledby":k?null:P,"aria-describedby":g.describedby,tabIndex:"-1"},m?F:{},{onKeyDown:C}),(0,r.createElement)("div",{className:i()("components-modal__content",{"hide-header":A}),role:"document"},!A&&(0,r.createElement)("div",{className:"components-modal__header"},(0,r.createElement)("div",{className:"components-modal__header-heading-container"},y&&(0,r.createElement)("span",{className:"components-modal__icon-container","aria-hidden":!0},y),u&&(0,r.createElement)("h1",{id:P,className:"components-modal__header-heading"},u)),h&&(0,r.createElement)(en,{onClick:v,icon:nn,label:w||(0,f.__)("Close dialog")})),b)))),document.body)})),ln=window.wp.plugins,un=window.wp.url,dn=window.wp.domReady;var pn=n.n(dn);const fn=(e,t={})=>{var n;if(window.wcpaySettings){Object.assign(t,{is_test_mode:wcpaySettings.testMode,jetpack_connected:wcpaySettings.isJetpackConnected,wcpay_version:wcpaySettings.version,woo_country_code:wcpaySettings.connect.country,hosting_provider:null===(n=wcpaySettings.trackingInfo)||void 0===n?void 0:n.hosting_provider});for(const e in t)void 0===t[e]&&delete t[e]}pn()((()=>{var n,r;(null!==(r=null===(n=null===wc||void 0===wc?void 0:wc.tracks)||void 0===n?void 0:n.recordEvent)&&void 0!==r?r:wcTracks.recordEvent)(e,t)}))};var mn=n(4848);const{connectUrl:hn,pluginScope:gn}=window.wcpaySubscriptionProductOnboardingModal,vn=()=>{const[e,t]=(0,r.useState)(!1);return(0,mn.jsx)(en,{disabled:e,href:hn,isBusy:e,isPrimary:!0,onClick:()=>{fn("wcpay_subscriptions_account_not_connected_product_modal_finish_setup"),t(!0)},children:(0,f.__)("Finish setup","woocommerce-payments")})},yn=({onRequestClose:e=()=>{}})=>((0,r.useEffect)((()=>{fn("wcpay_subscriptions_account_not_connected_product_modal_view")}),[]),(0,mn.jsxs)(cn,{className:"wcpay-subscription-product-modal",onRequestClose:()=>{fn("wcpay_subscriptions_account_not_connected_product_modal_dismiss"),e()},shouldCloseOnClickOutside:!1,children:[(0,mn.jsx)("p",{className:"wcpay-subscription-product-modal__title",children:(0,f.__)("One more step to accept recurring payments","woocommerce-payments")}),(0,mn.jsx)("p",{children:(0,f.sprintf)((0,f.__)("Verify your business details with %s to accept recurring payments for this subscription product.","woocommerce-payments"),"WooPayments")}),(0,mn.jsx)("p",{className:"wcpay-subscription-product-modal__tos",children:(0,r.createInterpolateElement)((0,f.__)('By clicking "Finish setup", you agree to the <a>Terms of Service</a>',"woocommerce-payments"),{a:(0,mn.jsx)("a",{href:"https://wordpress.com/tos/",target:"_blank",rel:"noreferrer"})})}),(0,mn.jsxs)("div",{className:"wcpay-subscription-product-modal__footer",children:[(0,mn.jsxs)("div",{className:"wcpay-subscription-product-modal__saved-indicator",children:[(0,mn.jsx)(St,{icon:"saved"}),(0,mn.jsx)("p",{children:(0,f.__)("We’ve saved your product as a draft.","woocommerce-payments")})]}),(0,mn.jsx)(vn,{})]})]}));(0,ln.registerPlugin)("wcpay-subscription-product-onboarding-modal",{icon:null,render:()=>{const[e,t]=(0,r.useState)(!0);return(0,r.useEffect)((()=>{window?.history&&window.history.replaceState(null,null,(0,un.removeQueryArgs)(window.location.href,"wcpay-subscription-saved-as-draft"))}),[]),e?(0,mn.jsx)(yn,{onRequestClose:()=>{t(!1)}}):null},scope:gn})})()})(); |