View file File name : first-time-configuration.js Content :(()=>{var e={4184:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function a(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var s=typeof n;if("string"===s||"number"===s)e.push(n);else if(Array.isArray(n)&&n.length){var o=a.apply(null,n);o&&e.push(o)}else if("object"===s)for(var i in n)r.call(n,i)&&n[i]&&e.push(i)}}return e.join(" ")}e.exports?(a.default=a,e.exports=a):void 0===(n=function(){return a}.apply(t,[]))||(e.exports=n)}()},8133:(e,t,n)=>{"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},s=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=c(n(9196)),i=c(n(5890)),l=c(n(4184));function c(e){return e&&e.__esModule?e:{default:e}}function u(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var d={animating:"rah-animating",animatingUp:"rah-animating--up",animatingDown:"rah-animating--down",animatingToHeightZero:"rah-animating--to-height-zero",animatingToHeightAuto:"rah-animating--to-height-auto",animatingToHeightSpecific:"rah-animating--to-height-specific",static:"rah-static",staticHeightZero:"rah-static--height-zero",staticHeightAuto:"rah-static--height-auto",staticHeightSpecific:"rah-static--height-specific"},p=["animateOpacity","animationStateClasses","applyInlineTransitions","children","contentClassName","delay","duration","easing","height","onAnimationEnd","onAnimationStart"];function m(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(!n.length)return e;for(var a={},s=Object.keys(e),o=0;o<s.length;o++){var i=s[o];-1===n.indexOf(i)&&(a[i]=e[i])}return a}function f(e){e.forEach((function(e){return cancelAnimationFrame(e)}))}function y(e){return!isNaN(parseFloat(e))&&isFinite(e)}function h(e){return"string"==typeof e&&e.search("%")===e.length-1&&y(e.substr(0,e.length-1))}function b(e,t){e&&"function"==typeof e&&e(t)}var g=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));n.animationFrameIDs=[];var r="auto",s="visible";y(e.height)?(r=e.height<0||"0"===e.height?0:e.height,s="hidden"):h(e.height)&&(r="0%"===e.height?0:e.height,s="hidden"),n.animationStateClasses=a({},d,e.animationStateClasses);var o=n.getStaticStateClasses(r);return n.state={animationStateClasses:o,height:r,overflow:s,shouldUseTransitions:!1},n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),s(t,[{key:"componentDidMount",value:function(){var e=this.state.height;this.contentElement&&this.contentElement.style&&this.hideContent(e)}},{key:"componentDidUpdate",value:function(e,t){var n,r,a=this,s=this.props,o=s.delay,i=s.duration,c=s.height,d=s.onAnimationEnd,p=s.onAnimationStart;if(this.contentElement&&c!==e.height){var m;this.showContent(t.height),this.contentElement.style.overflow="hidden";var g=this.contentElement.offsetHeight;this.contentElement.style.overflow="";var v=i+o,E=null,w={height:null,overflow:"hidden"},x="auto"===t.height;y(c)?(E=c<0||"0"===c?0:c,w.height=E):h(c)?(E="0%"===c?0:c,w.height=E):(E=g,w.height="auto",w.overflow=null),x&&(w.height=E,E=g);var S=(0,l.default)((u(m={},this.animationStateClasses.animating,!0),u(m,this.animationStateClasses.animatingUp,"auto"===e.height||c<e.height),u(m,this.animationStateClasses.animatingDown,"auto"===c||c>e.height),u(m,this.animationStateClasses.animatingToHeightZero,0===w.height),u(m,this.animationStateClasses.animatingToHeightAuto,"auto"===w.height),u(m,this.animationStateClasses.animatingToHeightSpecific,w.height>0),m)),_=this.getStaticStateClasses(w.height);this.setState({animationStateClasses:S,height:E,overflow:"hidden",shouldUseTransitions:!x}),clearTimeout(this.timeoutID),clearTimeout(this.animationClassesTimeoutID),x?(w.shouldUseTransitions=!0,f(this.animationFrameIDs),this.animationFrameIDs=(n=function(){a.setState(w),b(p,{newHeight:w.height})},(r=[])[0]=requestAnimationFrame((function(){r[1]=requestAnimationFrame((function(){n()}))})),r),this.animationClassesTimeoutID=setTimeout((function(){a.setState({animationStateClasses:_,shouldUseTransitions:!1}),a.hideContent(w.height),b(d,{newHeight:w.height})}),v)):(b(p,{newHeight:E}),this.timeoutID=setTimeout((function(){w.animationStateClasses=_,w.shouldUseTransitions=!1,a.setState(w),"auto"!==c&&a.hideContent(E),b(d,{newHeight:E})}),v))}}},{key:"componentWillUnmount",value:function(){f(this.animationFrameIDs),clearTimeout(this.timeoutID),clearTimeout(this.animationClassesTimeoutID),this.timeoutID=null,this.animationClassesTimeoutID=null,this.animationStateClasses=null}},{key:"showContent",value:function(e){0===e&&(this.contentElement.style.display="")}},{key:"hideContent",value:function(e){0===e&&(this.contentElement.style.display="none")}},{key:"getStaticStateClasses",value:function(e){var t;return(0,l.default)((u(t={},this.animationStateClasses.static,!0),u(t,this.animationStateClasses.staticHeightZero,0===e),u(t,this.animationStateClasses.staticHeightSpecific,e>0),u(t,this.animationStateClasses.staticHeightAuto,"auto"===e),t))}},{key:"render",value:function(){var e,t=this,n=this.props,r=n.animateOpacity,s=n.applyInlineTransitions,i=n.children,c=n.className,d=n.contentClassName,f=n.delay,y=n.duration,h=n.easing,b=n.id,g=n.style,v=this.state,E=v.height,w=v.overflow,x=v.animationStateClasses,S=v.shouldUseTransitions,_=a({},g,{height:E,overflow:w||g.overflow});S&&s&&(_.transition="height "+y+"ms "+h+" "+f+"ms",g.transition&&(_.transition=g.transition+", "+_.transition),_.WebkitTransition=_.transition);var O={};r&&(O.transition="opacity "+y+"ms "+h+" "+f+"ms",O.WebkitTransition=O.transition,0===E&&(O.opacity=0));var R=(0,l.default)((u(e={},x,!0),u(e,c,c),e)),C=void 0!==this.props["aria-hidden"]?this.props["aria-hidden"]:0===E;return o.default.createElement("div",a({},m.apply(void 0,[this.props].concat(p)),{"aria-hidden":C,className:R,id:b,style:_}),o.default.createElement("div",{className:d,style:O,ref:function(e){return t.contentElement=e}},i))}}]),t}(o.default.Component);g.propTypes={"aria-hidden":i.default.bool,animateOpacity:i.default.bool,animationStateClasses:i.default.object,applyInlineTransitions:i.default.bool,children:i.default.any.isRequired,className:i.default.string,contentClassName:i.default.string,delay:i.default.number,duration:i.default.number,easing:i.default.string,height:function(e,t,n){var a=e[t];return"number"==typeof a&&a>=0||h(a)||"auto"===a?null:new TypeError('value "'+a+'" of type "'+(void 0===a?"undefined":r(a))+'" is invalid type for '+t+" in "+n+'. It needs to be a positive number, string "auto" or percentage string (e.g. "15%").')},id:i.default.string,onAnimationEnd:i.default.func,onAnimationStart:i.default.func,style:i.default.object},g.defaultProps={animateOpacity:!1,animationStateClasses:d,applyInlineTransitions:!0,duration:250,delay:0,easing:"ease",style:{}},t.Z=g},4530:(e,t)=>{var n;!function(){"use strict";var r={}.hasOwnProperty;function a(){for(var e=[],t=0;t<arguments.length;t++){var n=arguments[t];if(n){var s=typeof n;if("string"===s||"number"===s)e.push(n);else if(Array.isArray(n)){if(n.length){var o=a.apply(null,n);o&&e.push(o)}}else if("object"===s){if(n.toString!==Object.prototype.toString&&!n.toString.toString().includes("[native code]")){e.push(n.toString());continue}for(var i in n)r.call(n,i)&&n[i]&&e.push(i)}}}return e.join(" ")}e.exports?(a.default=a,e.exports=a):void 0===(n=function(){return a}.apply(t,[]))||(e.exports=n)}()},9196:e=>{"use strict";e.exports=window.React},5890:e=>{"use strict";e.exports=window.yoast.propTypes}},t={};function n(r){var a=t[r];if(void 0!==a)return a.exports;var s=t[r]={exports:{}};return e[r](s,s.exports,n),s.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.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),(()=>{"use strict";var e=n(9196);const t=window.wp.domReady;var r=n.n(t);const a=window.wp.element,s=window.yoast.uiLibrary,o=window.lodash,i=window.wp.i18n,l=window.wp.apiFetch;var c=n.n(l);const u=window.wp.data,d="@yoast/general";var p=n(4530),m=n.n(p);(0,i.__)("E.g. https://www.facebook.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.instagram.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.linkedin.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.myspace.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.pinterest.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.soundcloud.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.tumblr.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.twitter.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.youtube.com/yoast","wordpress-seo"),(0,i.__)("E.g. https://www.wikipedia.com/yoast","wordpress-seo");const f=e=>`error-${e}`,y=(e,{isVisible:t})=>t?{"aria-invalid":!0,"aria-describedby":f(e)}:{};function h({active:e,selected:t}){return m()("yst-relative yst-cursor-default yst-select-none yst-py-2 yst-pl-3 yst-pr-9 yst-my-0",t&&"yst-bg-primary-500 yst-text-white",e&&!t&&"yst-bg-primary-200 yst-text-slate-700",!e&&!t&&"yst-text-slate-700")}function b(e,t){const n=function(e,t){return e.includes(t)?[...e]:[...e,t]}(e.editedSteps,t);return{...e,editedSteps:n}}function g(e,t){let n=(0,o.cloneDeep)(e);switch(t.type){case"SET_COMPANY_OR_PERSON":return n=b(n,2),n.companyOrPerson=t.payload,n.companyOrPersonLabel=n.companyOrPersonOptions.filter((e=>e.value===t.payload)).pop().label,n;case"CHANGE_COMPANY_NAME":return n=b(n,2),n.companyName=t.payload,n;case"SET_COMPANY_LOGO":return n=b(n,2),n.companyLogo=t.payload.url,n.companyLogoId=t.payload.id,n;case"REMOVE_COMPANY_LOGO":return n=b(n,2),n.companyLogo="",n.companyLogoId="",n;case"CHANGE_WEBSITE_NAME":return n=b(n,2),n.websiteName=t.payload,n;case"SET_PERSON_LOGO":return n=b(n,2),n.personLogo=t.payload.url,n.personLogoId=t.payload.id,n;case"REMOVE_PERSON_LOGO":return n=b(n,2),n.personLogo="",n.personLogoId="",n;case"SET_PERSON":return n=b(n,2),n.personId=t.payload.value,n.personName=t.payload.label,n;case"SET_CAN_EDIT_USER":return n=b(n,2),n.canEditUser=!0===t.payload?1:0,n;case"CHANGE_SOCIAL_PROFILE":return n=b(n,3),n.socialProfiles[t.payload.socialMedium]=t.payload.value,n.errorFields=n.errorFields.filter((e=>"facebookUrl"===t.payload.socialMedium?"facebook_site"!==e:"twitterUsername"!==t.payload.socialMedium||"twitter_site"!==e)),n;case"CHANGE_OTHERS_SOCIAL_PROFILE":return n=b(n,3),n.socialProfiles.otherSocialUrls[t.payload.index]=t.payload.value,n.errorFields=n.errorFields.filter((e=>e!==`other_social_urls-${t.payload.index}`)),n;case"ADD_OTHERS_SOCIAL_PROFILE":return n=b(n,3),n.socialProfiles.otherSocialUrls=[...n.socialProfiles.otherSocialUrls,t.payload.value],n;case"REMOVE_OTHERS_SOCIAL_PROFILE":return n=b(n,3),n.socialProfiles.otherSocialUrls.splice(t.payload.index,1),n.errorFields=(r=n.errorFields,a=t.payload.index,r.map((e=>{const t=parseInt(e.replace("other_social_urls-",""),10);return t===a?"remove":t>a?"other_social_urls-"+(t-1):e})).filter((e=>"remove"!==e))),n;case"SET_ERROR_FIELDS":return n.errorFields=t.payload,n;case"SET_STEP_ERROR":return n.stepErrors[t.payload.step]=t.payload.message,n;case"REMOVE_STEP_ERROR":return n.stepErrors=(0,o.pickBy)(n.stepErrors,((e,n)=>n!==t.payload)),n;case"SET_TRACKING":return n=b(n,4),n.tracking=t.payload,n;default:return n}var r,a}var v=n(5890),E=n.n(v);const w=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:2,stroke:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19 7l-.867 12.142A2 2 0 0116.138 21H7.862a2 2 0 01-1.995-1.858L5 7m5 4v6m4-6v6m1-10V4a1 1 0 00-1-1h-4a1 1 0 00-1 1v3M4 7h16"}))})),x=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M10 3a1 1 0 011 1v5h5a1 1 0 110 2h-5v5a1 1 0 11-2 0v-5H4a1 1 0 110-2h5V4a1 1 0 011-1z",clipRule:"evenodd"}))})),S=({items:t,onAddProfile:n,onRemoveProfile:r,onChangeProfile:o,errorFields:l,fieldType:c,addButtonChildren:u})=>{const d=(0,a.useCallback)((e=>{r(parseInt(e.currentTarget.dataset.index,10))}),[r]);return(0,e.createElement)("div",null,t.map(((t,n)=>(0,e.createElement)("div",{key:`url-${n}`},(0,e.createElement)("div",{className:"yst-w-full yst-flex yst-items-start yst-mt-4"},(0,e.createElement)(c,{className:"yst-grow",label:(0,i.__)("Other social profile","wordpress-seo"),id:`social-input-other-url-${n}`,value:t,socialMedium:"other",index:n,onChange:o,placeholder:(0,i.__)("E.g. https://social-platform.com/yoast","wordpress-seo"),feedback:{type:"error",isVisible:l.includes("other_social_urls-"+n),message:[(0,i.__)("Could not save this value. Please check the URL.","wordpress-seo")]}}),(0,e.createElement)("button",{type:"button",className:"yst-mt-[27.5px] yst-ml-2 yst-p-3 yst-text-slate-500 yst-rounded-md hover:yst-text-primary-500 focus:yst-text-primary-500 focus:yst-outline-none focus:yst-ring-2 focus:yst-ring-primary-500 yst-no-underline;",id:`remove-profile-${n}`,"data-index":n,onClick:d},(0,e.createElement)("span",{className:"yst-sr-only"},/* translators: Hidden accessibility text. */ (0,i.__)("Delete item","wordpress-seo")),(0,e.createElement)(w,{className:"yst-w-5 yst-h-5"})))))),(0,e.createElement)(s.Button,{id:"add-profile",variant:"secondary",className:"yst-items-center yst-mt-8",onClick:n,"data-hiive-event-name":"clicked_add_profile"},(0,e.createElement)(x,{className:"yst-w-5 yst-h-5 yst-mr-1 yst-text-slate-400"}),u))};S.propTypes={fieldType:E().elementType.isRequired,items:E().array.isRequired,onAddProfile:E().func.isRequired,onRemoveProfile:E().func.isRequired,onChangeProfile:E().func.isRequired,errorFields:E().array,addButtonChildren:E().node},S.defaultProps={errorFields:[],addButtonChildren:(0,i.__)("Add another profile","wordpress-seo")};const _=S,O=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7 4a1 1 0 11-2 0 1 1 0 012 0zm-1-9a1 1 0 00-1 1v4a1 1 0 102 0V6a1 1 0 00-1-1z",clipRule:"evenodd"}))})),R=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.707-9.293a1 1 0 00-1.414-1.414L9 10.586 7.707 9.293a1 1 0 00-1.414 1.414l2 2a1 1 0 001.414 0l4-4z",clipRule:"evenodd"}))})),C=({texts:t,id:n,as:r,...s})=>{const i=(0,a.useMemo)((()=>(0,o.last)(t)),[t]);return(0,e.createElement)(r,{id:n,...s},t.map(((t,r)=>(0,e.createElement)(a.Fragment,{key:`${n}-text-${r}`},t,i!==t&&(0,e.createElement)("br",null)))))};C.defaultProps={as:"p"},C.propTypes={texts:E().arrayOf(E().string).isRequired,id:E().string.isRequired,as:E().oneOfType([E().string,E().elementType])};const k=C;function T({hasError:t,hasSuccess:n}){return t?(0,e.createElement)("div",{className:"yst-flex yst-items-center yst-absolute yst-inset-y-0 yst-right-0 yst-mr-3"},(0,e.createElement)(O,{className:"yst-pointer-events-none yst-h-5 yst-w-5 yst-text-red-500"})):n?(0,e.createElement)("div",{className:"yst-flex yst-items-center yst-absolute yst-inset-y-0 yst-right-0 yst-mr-3"},(0,e.createElement)(R,{className:"yst-pointer-events-none yst-h-5 yst-w-5 yst-text-emerald-600"})):null}function P({className:t,id:n,label:r,description:s,value:o,onChange:i,placeholder:l,feedback:c,type:u,...d}){const p=u||"text",f=(0,a.useMemo)((()=>c.isVisible&&"error"===c.type),[c.isVisible,c.type]),h=(0,a.useMemo)((()=>c.isVisible&&"success"===c.type),[c.isVisible,c.type]);return(0,e.createElement)("div",{className:t},r&&(0,e.createElement)("label",{className:"yst-block yst-mb-2 yst-font-medium yst-text-slate-700",htmlFor:n},r),(0,e.createElement)("div",{className:"yst-relative"},(0,e.createElement)("input",{id:n,type:p,value:o,className:m()("yst-block yst-w-full yst-h-[45px] yst-input focus:yst-ring-1",{"yst-border-red-300 yst-text-red-900 focus:yst-ring-red-500 focus:yst-border-red-500":f,"yst-border-emerald-600 yst-text-slate-700 focus:yst-ring-emerald-600 focus:yst-border-emerald-600":h,"yst-text-slate-700 yst-border-slate-300 focus:yst-ring-primary-500 focus:yst-border-primary-500":!f&&!h}),onChange:i,placeholder:l,...y(n,c),...d}),(0,e.createElement)(T,{hasError:f,hasSuccess:h})),c.isVisible&&(0,e.createElement)(k,{id:`${f?"error-":"success-"}${n}`,className:m()("yst-mt-2 yst-text-sm",{"yst-text-red-600":f,"yst-text-emerald-600":h}),texts:c.message}),s)}function N({id:t,onChange:n,socialMedium:r,isDisabled:s,...o}){const i=(0,a.useCallback)((e=>{n(e.target.value,"other"===r?o.index:r)}),[r,o.index]);return(0,e.createElement)(P,{onChange:i,disabled:s,id:t,...o})}function I({socialProfiles:t,errorFields:n,dispatch:r}){const s=(0,a.useCallback)(((e,t)=>{r({type:"CHANGE_SOCIAL_PROFILE",payload:{socialMedium:t,value:e}})}),[]),o=(0,a.useCallback)(((e,t)=>{r({type:"CHANGE_OTHERS_SOCIAL_PROFILE",payload:{index:t,value:e}})}),[]),i=(0,a.useCallback)((()=>{r({type:"ADD_OTHERS_SOCIAL_PROFILE",payload:{value:""}})}),[]),l=(0,a.useCallback)((e=>{r({type:"REMOVE_OTHERS_SOCIAL_PROFILE",payload:{index:e}})}),[]);return(0,e.createElement)(M,{socialProfiles:t,onChangeHandler:s,onChangeOthersHandler:o,onAddProfileHandler:i,onRemoveProfileHandler:l,errorFields:n})}function M({socialProfiles:t,onChangeHandler:n,onChangeOthersHandler:r,onAddProfileHandler:a,onRemoveProfileHandler:s,errorFields:o}){return(0,e.createElement)("div",{id:"social-input-section"},(0,e.createElement)(N,{className:"yst-mt-4",label:(0,i.__)("Facebook","wordpress-seo"),id:"social-input-facebook-url",value:t.facebookUrl,socialMedium:"facebookUrl",onChange:n,placeholder:(0,i.__)("E.g. https://facebook.com/yoast","wordpress-seo"),feedback:{message:[(0,i.__)("Could not save this value. Please check the URL.","wordpress-seo")],isVisible:o.includes("facebook_site"),type:"error"}}),(0,e.createElement)(N,{className:"yst-mt-4",label:(0,i.__)("X","wordpress-seo"),id:"social-input-twitter-url",value:t.twitterUsername,socialMedium:"twitterUsername",onChange:n,placeholder:(0,i.__)("E.g. https://x.com/yoast","wordpress-seo"),feedback:{message:[(0,i.__)("Could not save this value. Please check the URL or username.","wordpress-seo")],isVisible:o.includes("twitter_site"),type:"error"}}),(0,e.createElement)(_,{items:t.otherSocialUrls,onAddProfile:a,onRemoveProfile:s,onChangeProfile:r,errorFields:o,fieldType:N}))}T.propTypes={hasError:v.PropTypes.bool,hasSuccess:v.PropTypes.bool},T.defaultProps={hasError:!1,hasSuccess:!1},P.propTypes={className:v.PropTypes.string,id:v.PropTypes.string.isRequired,label:v.PropTypes.string,description:v.PropTypes.node,value:v.PropTypes.string,onChange:v.PropTypes.func.isRequired,placeholder:v.PropTypes.string,feedback:v.PropTypes.shape({type:v.PropTypes.string,message:v.PropTypes.array,isVisible:v.PropTypes.bool}),type:v.PropTypes.string},P.defaultProps={value:"",className:"",label:"",description:null,placeholder:"",feedback:{message:[],isVisible:!1},type:"text"},N.propTypes={id:E().string.isRequired,onChange:E().func.isRequired,socialMedium:E().string,isDisabled:E().bool},N.defaultProps={socialMedium:"",isDisabled:!1},I.propTypes={socialProfiles:E().object.isRequired,dispatch:E().func.isRequired,errorFields:E().array},I.defaultProps={errorFields:[]},M.propTypes={socialProfiles:E().object.isRequired,onChangeHandler:E().func.isRequired,onChangeOthersHandler:E().func.isRequired,onAddProfileHandler:E().func.isRequired,onRemoveProfileHandler:E().func.isRequired,errorFields:E().array.isRequired};const L=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a1 1 0 000 2v3a1 1 0 001 1h1a1 1 0 100-2v-3a1 1 0 00-1-1H9z",clipRule:"evenodd"}))})),F=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M8.257 3.099c.765-1.36 2.722-1.36 3.486 0l5.58 9.92c.75 1.334-.213 2.98-1.742 2.98H4.42c-1.53 0-2.493-1.646-1.743-2.98l5.58-9.92zM11 13a1 1 0 11-2 0 1 1 0 012 0zm-1-8a1 1 0 00-1 1v3a1 1 0 002 0V6a1 1 0 00-1-1z",clipRule:"evenodd"}))})),A=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zM8.707 7.293a1 1 0 00-1.414 1.414L8.586 10l-1.293 1.293a1 1 0 101.414 1.414L10 11.414l1.293 1.293a1 1 0 001.414-1.414L11.414 10l1.293-1.293a1 1 0 00-1.414-1.414L10 8.586 8.707 7.293z",clipRule:"evenodd"}))}));var D=n(8133);function z({type:t,children:n,className:r}){let a,s;switch(t){case"info":a=(0,e.createElement)(L,{"aria-hidden":"true",className:"yst-flex-shrink-0 yst-w-5 yst-h-5 yst-text-blue-500"}),s="yst-bg-blue-100 yst-text-blue-800";break;case"warning":a=(0,e.createElement)(F,{"aria-hidden":"true",className:"yst-flex-shrink-0 yst-w-5 yst-h-5 yst-text-yellow-500"}),s="yst-bg-yellow-100 yst-text-yellow-800";break;case"error":a=(0,e.createElement)(A,{"aria-hidden":"true",className:"yst-flex-shrink-0 yst-w-5 yst-h-5 yst-text-red-500"}),s="yst-bg-red-100 yst-text-red-800";break;case"success":a=(0,e.createElement)(R,{"aria-hidden":"true",className:"yst-flex-shrink-0 yst-w-5 yst-h-5 yst-text-emerald-600"}),s="yst-bg-green-100 yst-text-green-800"}return(0,e.createElement)("div",{className:m()("yst-flex yst-p-4 yst-rounded-md",s,r)},a,(0,e.createElement)("div",{className:"yst-flex-1 yst-ml-3 yst-text-sm"},n))}function q({id:t,isVisible:n,expandDuration:r,type:s,children:o,className:i}){const[l,c]=(0,a.useState)(n?"yst-opacity-100":"yst-opacity-0"),u=(0,a.useCallback)((()=>{c("yst-opacity-100")}),[]);return(0,e.createElement)(D.Z,{id:t,height:n?"auto":0,easing:"linear",duration:r,onAnimationEnd:u},(0,e.createElement)(z,{type:s,className:m()("yst-transition-opacity yst-duration-300 yst-mt-4",l,i)},o))}function j({state:t,dispatch:n,setErrorFields:r}){const s=(0,i.__)("If you select a Person to represent this site, we will use the social profiles from the selected user's profile page.","wordpress-seo"),o=(0,a.createInterpolateElement)((0,i.sprintf)( // translators: %1$s is replaced by the selected person's username. (0,i.__)("You have selected the user %1$s as the person this site represents.","wordpress-seo"),`<b>${t.personName}</b>`),{b:(0,e.createElement)("b",null)}),l=(0,a.createInterpolateElement)((0,i.sprintf)( // translators: %1$s and %2$s is replaced by a link to the selected person's profile page. (0,i.__)("You can %1$supdate or add social profiles to this user profile%2$s.","wordpress-seo"),"<a>","</a>"),{a:(0,e.createElement)("a",{id:"yoast-configuration-person-social-profiles-user-link",href:window.wpseoScriptData.userEditUrl.replace("{user_id}",t.personId),target:"_blank",rel:"noopener noreferrer","data-hiive-event-name":"clicked_update_or_add_profile | social profiles"})}),c=(0,i.__)("You're not allowed to edit the social profiles of this user. Please ask this user or an admin to do this.","wordpress-seo");return["company","emptyChoice"].includes(t.companyOrPerson)?(0,e.createElement)(a.Fragment,null,(0,e.createElement)("p",null,(0,i.__)("Fantastic work! Add your organization's social media accounts below. This allows us to fine-tune the metadata for these platforms.","wordpress-seo")),(0,e.createElement)(I,{socialProfiles:t.socialProfiles,dispatch:n,errorFields:t.errorFields,setErrorFields:r})):0===t.personId?(0,e.createElement)(a.Fragment,null,(0,e.createElement)("p",null,s),(0,e.createElement)(z,{type:"info",className:"yst-mt-5"}, // translators: please note that "Site representation" here refers to the name of a step in the first-time configuration, so this occurrence needs to be translated in the same manner as that step's heading. (0,i.__)("Please select a user in the Site representation step.","wordpress-seo"))):(0,e.createElement)(a.Fragment,null,(0,e.createElement)("p",null,o," ",t.canEditUser?l:c))}z.propTypes={type:E().oneOf(["info","warning","error","success"]),children:E().oneOfType([E().arrayOf(E().node),E().node]).isRequired,className:E().string},z.defaultProps={type:"info",className:""},q.propTypes={id:E().string.isRequired,isVisible:E().bool.isRequired,type:E().oneOf(["info","warning","error","success"]),children:E().oneOfType([E().arrayOf(E().node),E().node]).isRequired,expandDuration:E().number,className:E().string},q.defaultProps={expandDuration:400,type:"info",className:""},j.propTypes={state:E().object.isRequired,dispatch:E().func.isRequired,setErrorFields:E().func.isRequired};const U={slideDuration:500,fadeDuration:200,delayBeforeOpening:900,delayBeforeFadingIn:1400,delayBeforeClosing:200},$={fadeDuration:"yst-duration-200",slideDuration:"yst-duration-500",delayBeforeOpening:"yst-delay-[900ms]",delayUntilStepFaded:"yst-delay-200"},H=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M16.707 5.293a1 1 0 010 1.414l-8 8a1 1 0 01-1.414 0l-4-4a1 1 0 011.414-1.414L8 12.586l7.293-7.293a1 1 0 011.414 0z",clipRule:"evenodd"}))})),{slideDuration:V,delayUntilStepFaded:B}=$,Z=`yst-transition-opacity ${V} yst-absolute yst-inset-0 yst-border-2 yst-flex yst-items-center yst-justify-center yst-rounded-full`;function G(e){return`${Z} ${e?"yst-opacity-100":`${B} yst-opacity-0`}`}function W({isVisible:t}){return(0,e.createElement)("span",{className:`yst-bg-white yst-border-primary-500 ${G(t)}`},(0,e.createElement)("span",{className:"yst-h-2.5 yst-w-2.5 yst-rounded-full yst-bg-primary-500"}))}function Y({isVisible:t}){return(0,e.createElement)("span",{className:`yst-bg-primary-500 yst-border-primary-500 ${G(t)}`},(0,e.createElement)(H,{className:"yst-w-5 yst-h-5 yst-text-white","aria-hidden":"true"}))}function Q({isVisible:t}){return(0,e.createElement)("span",{className:`yst-bg-white yst-border-slate-300 ${G(t)}`},(0,e.createElement)("span",{className:"yst-h-2.5 yst-w-2.5 yst-rounded-full yst-bg-transparent"}))}function K({activationDelay:t,deactivationDelay:n,isFinished:r}){const{activeStepIndex:s,stepIndex:o,lastStepIndex:i}=le(),l=o===i,c=s===o,[u,d]=(0,a.useState)((()=>!!c&&!l));return(0,a.useEffect)((()=>{if(c){const e=setTimeout((()=>{d(!0)}),t);return()=>clearTimeout(e)}const e=setTimeout((()=>{d(!1)}),n);return()=>clearTimeout(e)}),[c,l,t,n]),(0,e.createElement)("span",{className:"yst-relative yst-z-10 yst-w-8 yst-h-8 yst-rounded-full"},(0,e.createElement)(Q,{isVisible:!0}),(0,e.createElement)(Y,{isVisible:r}),(0,e.createElement)(W,{isVisible:u&&!l}))}function J(e,t,n){return t&&!n?"yst-text-primary-500":e?"yst-text-slate-900":"yst-text-slate-600"}function X({name:t,description:n,isFinished:r,children:s}){const{stepIndex:o,activeStepIndex:i,lastStepIndex:l}=le(),c=i===o,u=l===o,[d,p]=(0,a.useState)(J(r,c,u));return(0,a.useEffect)((()=>{if(c){const e=J(r,c,u),t=setTimeout((()=>p(e)),U.delayBeforeOpening);return()=>clearTimeout(t)}const e=J(r,c,u);p(e)}),[i,r,u,J]),(0,e.createElement)("div",{className:"yst-relative yst-flex yst-items-center yst-group","aria-current":c?"step":null},(0,e.createElement)("span",{className:"yst-flex yst-items-center","aria-hidden":c?"true":null},(0,e.createElement)(K,{activationDelay:U.delayBeforeOpening,deactivationDelay:0,isFinished:r})),(0,e.createElement)("span",{className:"yst-ml-4 yst-min-w-0 yst-flex yst-flex-col"},(0,e.createElement)("span",{className:`yst-transition-colors yst-duration-500 yst-text-xs yst-font-[650] yst-tracking-wide yst-uppercase ${d}`},t),n&&(0,e.createElement)("span",{className:"yst-text-sm yst-text-slate-600"},n)),s)}W.propTypes={isVisible:E().bool},W.defaultProps={isVisible:!0},Y.propTypes={isVisible:E().bool},Y.defaultProps={isVisible:!0},Q.propTypes={isVisible:E().bool},Q.defaultProps={isVisible:!0},K.propTypes={isFinished:E().bool.isRequired,activationDelay:E().number,deactivationDelay:E().number},K.defaultProps={activationDelay:0,deactivationDelay:0},X.propTypes={name:E().string.isRequired,isFinished:E().bool.isRequired,description:E().string,children:E().node},X.defaultProps={description:"",children:[]};const{slideDuration:ee,delayBeforeOpening:te,delayBeforeFadingIn:ne,delayBeforeClosing:re}=U,{fadeDuration:ae,delayUntilStepFaded:se,slideDuration:oe}=$,ie=(0,a.createContext)();function le(){const e=(0,a.useContext)(ie);if(!e)throw new Error("Stepper compound components cannot be rendered outside the Stepper component");return e}function ce({beforeGo:t,children:n,destination:r,...o}){const{stepIndex:i,setActiveStepIndex:l,lastStepIndex:c}=le(),u=(0,a.useCallback)((()=>{l("string"==typeof r?"last"===r?c:0:i+r)}),[i,c,l,r]),d=(0,a.useCallback)((async()=>{let e=!0;t&&(e=!1,e=await t()),e&&u()}),[u,t]);return(0,e.createElement)(s.Button,{onClick:d,...o},n)}function ue({children:t,...n}){const{stepIndex:r,setActiveStepIndex:o}=le(),i=(0,a.useCallback)((()=>{o(r)}),[o,r]);return(0,e.createElement)(s.Button,{onClick:i,variant:"secondary",size:"small",...n},t)}function de({children:t}){const{lastStepIndex:n,stepIndex:r,activeStepIndex:s}=le();return(0,e.createElement)(a.Fragment,null,r!==n&&(0,e.createElement)(a.Fragment,null,(0,e.createElement)("div",{className:"yst--ml-px yst-absolute yst-left-4 yst-w-0.5 yst-h-full yst-bg-slate-300 yst--bottom-6","aria-hidden":"true"}),(0,e.createElement)("div",{className:`yst-h-12 yst-transition-transform ${se} yst-ease-linear ${oe} ${r<s?"yst-scale-y-1":"yst-scale-y-0"} yst-origin-top yst--ml-px yst-absolute yst-left-4 yst-w-0.5 yst-bg-primary-500 yst-top-8`,"aria-hidden":"true"})),t)}function pe({id:t,message:n,className:r}){return(0,e.createElement)(q,{id:t,type:"error",isVisible:!!n,className:r},(0,i.sprintf)(/* translators: %1$s expands to the error message returned by the server */ (0,i.__)("An error has occurred: %1$s","wordpress-seo"),n))}function me({children:t}){const{activeStepIndex:n,stepIndex:r}=le(),s=n===r,[o,i]=(0,a.useState)(s?"auto":0),[l,c]=(0,a.useState)(!s);return(0,a.useEffect)((()=>{s?(i("auto"),setTimeout((()=>c(!1)),ne)):(c(!0),i(0))}),[s]),(0,e.createElement)(a.Fragment,null,(0,e.createElement)(D.Z,{id:`content-${r}`,delay:0===o?re:te,height:o,easing:"ease-in-out",duration:ee},(0,e.createElement)("div",{className:`yst-transition-opacity ${ae} yst-relative yst-ml-12 yst-mt-4 yst-pb-1 ${l?"yst-opacity-0 yst-pointer-events-none":"yst-opacity-100"}`},t)))}function fe({children:t,setActiveStepIndex:n,activeStepIndex:r,isStepperFinished:a}){return(0,e.createElement)("ol",null,t.map(((s,o)=>(0,e.createElement)("li",{key:`${s.props.name}-${o}`,className:(o===t.length-1?"":"yst-pb-8")+" yst-mb-0 yst-relative yst-max-w-none"},(0,e.createElement)(ie.Provider,{value:{stepIndex:o,activeStepIndex:r,setActiveStepIndex:n,lastStepIndex:t.length-1,isStepperFinished:a}},s)))))}ce.propTypes={beforeGo:E().func,children:E().node,destination:E().oneOfType([E().number,E().oneOf(["first","last"])])},ce.defaultProps={beforeGo:null,children:(0,e.createElement)(a.Fragment,null,(0,i.__)("Continue","wordpress-seo")),destination:1},ue.propTypes={children:E().node},ue.defaultProps={children:(0,e.createElement)(a.Fragment,null,(0,i.__)("Edit","wordpress-seo"))},de.propTypes={children:E().node.isRequired},pe.propTypes={id:E().string.isRequired,message:E().string.isRequired,className:E().string},pe.defaultProps={className:""},me.propTypes={children:E().node.isRequired},fe.propTypes={setActiveStepIndex:E().func.isRequired,activeStepIndex:E().number.isRequired,isStepperFinished:E().bool,children:E().node.isRequired},fe.defaultProps={isStepperFinished:!1},de.Content=me,de.Error=pe,de.Header=X,de.GoButton=ce,de.EditButton=ue;const ye={optimizeSeoData:"optimizeSeoData",siteRepresentation:"siteRepresentation",socialProfiles:"socialProfiles",personalPreferences:"personalPreferences"},he={[ye.optimizeSeoData]:"data optimization",[ye.siteRepresentation]:"site representation",[ye.socialProfiles]:"social profiles",[ye.personalPreferences]:"personal preferences"};function be({stepId:t,beforeGo:n,children:r,additionalClasses:a,...s}){return(0,e.createElement)(de.GoButton,{id:`button-${t}-continue`,variant:"primary",className:a,destination:1,beforeGo:n,"data-hiive-event-name":`clicked_continue | ${he[t]}`,...s},r)}function ge({stepId:t,beforeGo:n,isVisible:r,children:a,additionalClasses:s,...o}){const i=`yst-transition-opacity ${$.slideDuration} yst-ease-out ${r?"yst-opacity-100":`${$.delayBeforeOpening} yst-opacity-0 yst-pointer-events-none yst-hidden`}`;return(0,e.createElement)(de.GoButton,{id:`button-${t}-edit`,variant:"secondary",size:"small",className:m()(i,s),destination:0,beforeGo:n,"data-hiive-event-name":`clicked_edit | ${he[t]}`,...o},a)}function ve({stepId:t,beforeGo:n,children:r,additionalClasses:a,...s}){return(0,e.createElement)(de.GoButton,{id:`button-${t}-back`,variant:"secondary",className:a,destination:-1,beforeGo:n,"data-hiive-event-name":`clicked_go_back | ${he[t]}`,...s},r)}function Ee({stepId:t,beforeContinue:n,continueLabel:r,beforeBack:a,backLabel:s}){return(0,e.createElement)("div",{className:"yst-mt-12"},(0,e.createElement)(be,{stepId:t,beforeGo:n},r),(0,e.createElement)(ve,{stepId:t,additionalClasses:"yst-ml-3",beforeGo:a},s))}function we({stepId:t,stepperFinishedOnce:n,saveFunction:r,setEditState:s}){const o=(0,a.useCallback)((async()=>{const e=await r();return s(!e),e}),[r]);return n?(0,e.createElement)(de.GoButton,{id:`button-${t}-go`,variant:"primary",className:"yst-mt-12",destination:"last",beforeGo:o,"data-hiive-event-name":`clicked_save_changes | ${he[t]}`},(0,i.__)("Save changes","wordpress-seo")):(0,e.createElement)(Ee,{stepId:t,beforeContinue:r,continueLabel:(0,i.__)("Save and continue","wordpress-seo")})}var xe,Se,_e,Oe,Re,Ce,ke,Te,Pe,Ne,Ie,Me,Le,Fe,Ae,De,ze,qe,je,Ue,$e,He,Ve,Be,Ze,Ge,We,Ye,Qe,Ke,Je,Xe,et,tt,nt,rt,at,st,ot,it,lt,ct,ut,dt,pt,mt,ft,yt,ht,bt,gt;function vt(){return vt=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},vt.apply(this,arguments)}be.propTypes={stepId:E().string.isRequired,additionalClasses:E().string,beforeGo:E().func,children:E().node},be.defaultProps={additionalClasses:"",beforeGo:null,children:null},ge.propTypes={stepId:E().string.isRequired,additionalClasses:E().string,isVisible:E().bool,beforeGo:E().func,children:E().node},ge.defaultProps={additionalClasses:"",isVisible:!0,beforeGo:null,children:null},ve.propTypes={stepId:E().string.isRequired,additionalClasses:E().string,beforeGo:E().func,children:E().node},ve.defaultProps={additionalClasses:"",beforeGo:null,children:null},Ee.propTypes={stepId:E().string.isRequired,beforeContinue:E().func,continueLabel:E().string,beforeBack:E().func,backLabel:E().string},Ee.defaultProps={beforeContinue:null,continueLabel:(0,i.__)("Continue","wordpress-seo"),beforeBack:null,backLabel:(0,i.__)("Go back","wordpress-seo")},we.propTypes={stepId:E().string.isRequired,stepperFinishedOnce:E().bool.isRequired,saveFunction:E().func.isRequired,setEditState:E().func.isRequired};const Et=t=>e.createElement("svg",vt({xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",viewBox:"0 0 262.37 284.15"},t),xe||(xe=e.createElement("path",{fill:"#f0ecf0",d:"M262.37 153A131.19 131.19 0 1 0 54.71 259.56a28.08 28.08 0 0 1 1.91-7.37c2-4.92-12.06-11.1-7.52-26.48 3.49-11.81 30.9-25.16 37.1-41.56 2.4-6.32 12-30.34 29.69-35.66 9-2.7 48.29-13.29 60.25-11.07s37.48 11 31.66 41.46c-10.26 53.79-44.8 59.12-46.28 94.64a27.46 27.46 0 0 0 .65 6.94A131.23 131.23 0 0 0 262.37 153Z"})),Se||(Se=e.createElement("path",{fill:"#006531",d:"M161.52 273.52c1.44-35.53 36-40.85 46.28-94.64 5.82-30.51-19.7-39.25-31.66-41.46s-51.23 8.37-60.25 11.07c-17.72 5.32-27.29 29.34-29.69 35.66-6.2 16.4-33.61 29.75-37.1 41.56-4.54 15.38 9.53 21.56 7.52 26.48a28.08 28.08 0 0 0-1.91 7.37 131.71 131.71 0 0 0 12.68 8.05 184.18 184.18 0 0 1 7.18-34.05c-4.12-2.43-8.32-4-19.15-2.33 16.06-23.66 34.79-45.11 64.9-65.12 2.54 22.59 3.65 40.75 14.49 60-14.93-3.2-25.12 0-32 4.77a103.74 103.74 0 0 0-4.6 49.12 132 132 0 0 0 64 .49 27.23 27.23 0 0 1-.69-6.97Z"})),_e||(_e=e.createElement("path",{fill:"#89bc3b",d:"M102.8 230.9c6.89-4.73 17.08-8 32-4.77-10.84-19.27-12-37.43-14.49-60-30.11 20-48.84 41.46-64.9 65.12 10.83-1.66 15-.1 19.15 2.33a184.18 184.18 0 0 0-7.18 34A130.42 130.42 0 0 0 98.21 280a103.65 103.65 0 0 1 4.59-49.1Z"})),Oe||(Oe=e.createElement("path",{fill:"#093f22",d:"M61.29 184.66c-4.39 13.11-15 33.6-14.52 47.42 11.9-18 34.83-42.28 46.73-60.26 2.69-4.08 1.49-10.8-3.21-13.29-3.83-2-8.45-.15-11.7 1.92-8.3 5.28-14.21 14.98-17.3 24.21Zm72.61 58.65 18.32-60.92s.51 11.07 1.1 9.3 16.4-28.8 16.4-28.8l-28.14 81Z"})),Re||(Re=e.createElement("path",{fill:"#006531",d:"M169.31 113.64c.71 13.17 6.24 22.36 5.36 25.68-33.67 6.42-49.16 29.46-54 28.88-6.67-3.85-5.76-14.39-5.54-17.71 3.55-6.65-.12-17.65 1.77-23.89 1.4-4.6 9.38-12.6 18.1-14.53s33.93-5.54 34.31 1.57Z"})),Ce||(Ce=e.createElement("path",{fill:"#b498c6",d:"M122.32 166.11c6.09-9.75 11.1-30.31 14.62-33.9 3.33-3.39 22.1-12 26.12-13.51 1.56-1.22 2-2.55 2.09-6.65l.23-19.82-45.16 16.39 2.53 37.22c.67 5.09.35 10.08-.43 20.27Z"})),ke||(ke=e.createElement("path",{fill:"#8b6c9c",d:"m166.15 92.89-.64 7.17c-.94 12.77-25.4 31.3-38.1 30.12-4.6-.42-5.78-10.38-7.39-15.06l-2.61-9.52Z"})),Te||(Te=e.createElement("path",{fill:"#b498c6",d:"M157.71 192S128 247.74 126 254s-.23 13.67 4.49 15.24 16.51.6 24.27-7.47c5.9-6.14 28.74-39.14 29.45-39.85.06-13.3-7.49-22.14-26.5-29.92Z"})),Pe||(Pe=e.createElement("ellipse",{cx:106.71,cy:192.91,fill:"#fbb03b",stroke:"#fc3",strokeMiterlimit:10,rx:8.8,ry:5.58,transform:"rotate(-19.17 106.716 192.914)"})),Ne||(Ne=e.createElement("path",{fill:"#f19018",d:"M92.72 206.13c4.25-1.18 9.78-1.68 17-1.26-6.39 3.89-15.24 15.48-15.51 17.65a87.16 87.16 0 0 1 11-1.88c-16 10.81-23.79 31.12-22.85 30.75-1.24.41-3.63-21.77 6.06-31.06a32.05 32.05 0 0 0-7.73 1.1c1.68-4.03 6.97-11.62 12.03-15.3Z"})),Ie||(Ie=e.createElement("path",{fill:"#fbb03b",stroke:"#fc3",strokeMiterlimit:10,d:"M92.72 206.13c4.25-1.18 9.78-1.68 17-1.26-6.39 3.89-15.24 15.48-15.51 17.65a87.16 87.16 0 0 1 11-1.88c-16 10.81-23.79 31.12-22.85 30.75-1.24.41-3.63-21.77 6.06-31.06a32.05 32.05 0 0 0-7.73 1.1c1.68-4.03 6.97-11.62 12.03-15.3Z"})),Me||(Me=e.createElement("path",{fill:"#006531",d:"M183.45 223.15c-3.73-9.11-19.27-19.94-31.68-20.38 7.54-16.39 11.46-29.12 19.31-42.24 0 0-5.74-22.74-1-22.2 8.52 1 19-7.56 33.67-4.23 14.25 3.23 20.27 23.26 17 38-4.47 19.9-40.04 54.49-37.3 51.05Z"})),Le||(Le=e.createElement("path",{fill:"#8b6c9c",d:"M80 254.38C77.79 252.17 71.81 244 65.6 244s-33 6.87-33 6.87l-.45 9.3s16.69 1.77 19.94 2.22 16-3.55 16-3.55Z"})),Fe||(Fe=e.createElement("path",{fill:"#8b6c9c",d:"M72.14 260.36c-12.31-.11-23.45 6.28-26.55 5.39-4.1-1.33-4.21.82-6.64.59s-6.7-3.65-6.7-3.65l.12-12.3 39 7.09Z"})),Ae||(Ae=e.createElement("path",{fill:"#8b6c9c",d:"M50.63 262.9c-4.43-2.21-15.73 4.28-17.74 2.71-4.64-3.65-8.27-6.21-9.3-8.42s2.47-5.91 1.59-16.1c-.44-5.07 4.31-5.32 6.09-1.33.93 2.1 1.33 13.51 1.33 13.51l7.63 2.1Z"})),De||(De=e.createElement("path",{fill:"#b498c6",d:"M100.38 163.12c.89 4-22.61 60.35-31.91 76.3S40.9 257.36 40.9 257.36s-14.48-.79-9.17-22.05 24.47-27.82 31.55-37.42 20.27-29 20.27-33.45c0-3.1 15.95-5.31 16.83-1.32Z"})),ze||(ze=e.createElement("path",{fill:"#8b6c9c",d:"M100.48 163.09a3.78 3.78 0 0 1 0 .95 9.1 9.1 0 0 1-.16.91c-.12.6-.29 1.19-.44 1.78-.33 1.17-.69 2.34-1.06 3.5-.76 2.32-1.56 4.62-2.38 6.92Q94 184 91.28 190.83q-5.4 13.59-11.26 27-2.92 6.71-6 13.34A63.91 63.91 0 0 1 66.55 244 35.8 35.8 0 0 1 55 253.26a38.85 38.85 0 0 1-14.07 4.2v-.2a41.07 41.07 0 0 0 6.94-2.09 39.27 39.27 0 0 0 6.44-3.17A35.56 35.56 0 0 0 65 242.71a26.19 26.19 0 0 0 2-2.9c.66-1 1.22-2.05 1.8-3.1q1.74-3.18 3.36-6.44c2.2-4.33 4.31-8.71 6.37-13.12q6.14-13.23 11.79-26.7 2.85-6.72 5.53-13.51c.88-2.27 1.74-4.55 2.56-6.84.4-1.14.79-2.29 1.15-3.46.17-.58.35-1.16.48-1.75a6.54 6.54 0 0 0 .18-.88 3.19 3.19 0 0 0 .06-.87Z"})),qe||(qe=e.createElement("path",{fill:"#8b6c9c",d:"M98.61 166.22s10.4-10 11.73-14c1.78-5.31-.21-15.41 2.56-22.17 1.13-2.77 5-12.4 5.3-13.28s-3.13-2.36-4.76-1.77a17.06 17.06 0 0 0-6.26 5.61c-1.33 2.22-.68 10.15-4.37 11.34s-18.23 10.61-18.38 17.4.44 11.85 14.18 16.87Z"})),je||(je=e.createElement("path",{fill:"#8b6c9c",d:"m100.38 163.12 8.42-13.74-13.74-19s4.35-12 5.09-16.39 3.84-11.14.56-18.17c-2.12-4.55-4.79-5-5.09-2.1s-1.16 13.72-2.62 17.12-8.08 14.62-8.08 14.62l-12.4 14.62Z"})),Ue||(Ue=e.createElement("path",{fill:"#b498c6",d:"M138.58 5.48c-20.7-.38-38 19.23-39.7 21.63-1.34 1.94-5.06 12-6.58 19.34.42-1.33.87-2.62 1.33-3.85 13.19-6.56 37.64-4.79 70.11 2.89 1.75 6.74 1.36 12.38 1.15 20.18 0 0-15.4 8.58-24.28 9.94-7.5 1.16-11.68-1.37-14.5-3.62-4-3.18-7.61-9.22-13.15-9.67-5.81-.47-7.83 9.3-10.72 9-1.73-.18-7.25.7-9.63 2.76a34.28 34.28 0 0 0-.24 9.16c1.25 5.91 5.63 11.61 8.16 14.52s4.19 11.43 8.45 15.76c9.81 9.93 47-6.94 55.48-17.25 3.75-4.53 8.8-28 8.8-28s10.52-10.21 10.46-16.87c-.21-22.82-17.07-45.4-45.14-45.92Z"})),$e||($e=e.createElement("path",{fill:"#fcee21",d:"M92.41 51.14a78.25 78.25 0 0 1 .88-8.53C83.1 69 92.42 74.26 92.61 74.09a39.64 39.64 0 0 1 2.9-8.67s-3.36-7.58-3.1-14.28Z"})),He||(He=e.createElement("path",{fill:"#fbb03b",d:"M102.24 71.33c2.89.29 4.91-9.48 10.72-9 5.54.45 9.14 6.49 13.15 9.67 2.82 2.25 7 4.78 14.5 3.62 8.88-1.36 24.28-9.94 24.28-9.94.21-7.8.6-13.44-1.15-20.18-32.47-7.69-56.92-9.5-70.11-2.9-.89 2-1.63 13.3-1.63 13.3-.3 5 .89 6.64 3.47 9.52a42 42 0 0 0-2.82 8.67c2.35-2.09 7.86-2.94 9.59-2.76Z"})),Ve||(Ve=e.createElement("path",{fill:"#89bc3b",d:"M156 194.13c7.53-.89 21.71 6.87 26.81 12.62 14.42-12.32 25.39-37.37 27.91-45.19 6.64-20.6-11.52-28.35-11.52-28.35l2.44.66s18.38 5.76 14.84 31.9c-1.24 9.13-14.64 33.72-28.8 46.3.89 1.55 2.22 3.32 2.66 4.87l-6.65 6.43c-2.66-8.42-22.81-20.82-31.9-20.6Z"})),Be||(Be=e.createElement("path",{fill:"#b498c6",d:"M86.65 168.87c-.89-1.32-17.89-25.57-18.34-28.67s4.69-7.7 6.13-7c9.64 4.61 24.21 17.67 26 22.1s-.71 11.59-.71 11.59Zm-8.86-38.1s12.14-11.89 15.09-12 10.11 6 13.11 7.91c3.2 2 3.87 7.13 8.23 10.45.44 2.07-2.22 3.42-5.62 2.39s-7.34-6.81-7.34-6.81l-7.12-3.46-8.38 6.88Z"})),Ze||(Ze=e.createElement("path",{fill:"#b498c6",d:"M74.24 133s11.93-9 13.4-9 12.38 7.59 13.42 9.22 1.88 8.59 3.75 14.86c.65 2.17-3.28 5.17-6.53 1.33s-4.77-10.32-4.77-10.32l-7.33-4.61-5.29 3.85Z"})),Ge||(Ge=e.createElement("path",{fill:"#8b6c9c",d:"M84.58 124.87a4.75 4.75 0 0 1 3-1.15 7.83 7.83 0 0 1 3.22.82 21.82 21.82 0 0 1 2.69 1.76c.86.62 1.71 1.25 2.56 1.89a47.7 47.7 0 0 1 4.94 4.14 4.21 4.21 0 0 1 .55.71 5.87 5.87 0 0 1 .36.81c.18.53.33 1.05.46 1.57.26 1 .48 2.08.7 3.12.44 2.07.87 4.14 1.37 6.19.25 1 .53 2 .82 3a2.42 2.42 0 0 1 .12 1 2.36 2.36 0 0 1-.26.93 3.58 3.58 0 0 1-1.21 1.34 4 4 0 0 1-3.47.47 5.93 5.93 0 0 1-2.73-2.06 12.37 12.37 0 0 1-2.52-5.93 36.66 36.66 0 0 0 3.3 5.3 5 5 0 0 0 2.26 1.74 3 3 0 0 0 2.6-.35 1.93 1.93 0 0 0 1-2.16c-.3-1-.58-2.06-.83-3.09-.51-2.07-.94-4.15-1.38-6.22-.22-1-.44-2.07-.69-3.08-.13-.51-.27-1-.43-1.49a2.76 2.76 0 0 0-.7-1.17 49.75 49.75 0 0 0-4.81-4c-.84-.63-1.69-1.26-2.55-1.88s-1.75-1.16-2.57-1.8a6.81 6.81 0 0 0-2.78-1.11 4.77 4.77 0 0 0-3.02.7Z"})),We||(We=e.createElement("path",{fill:"#b498c6",d:"M72.62 133.87s5-4.31 6.43-4.66c2.52-.63 12.51 5.9 13.36 7.77 1.31 2.91 2.2 7.57 3.87 11.4.9 2.06-2.84 2.15-5.49.53s-3.57-6.71-3.57-6.71c-2.51-1.89-4.82-2.52-6.54-3.69-.3 2.47-2.6 5.07-7 8.07Z"})),Ye||(Ye=e.createElement("path",{fill:"#8b6c9c",d:"M79.05 129.21a5.63 5.63 0 0 1 2.7.27c.88.26 1.73.57 2.58.91a28.34 28.34 0 0 1 4.81 2.54c.77.48 1.53 1 2.27 1.52a12.53 12.53 0 0 1 2.14 1.84 2.76 2.76 0 0 1 .45.71c.09.21.17.44.24.66a12.73 12.73 0 0 1 .38 1.34c.21.9.37 1.8.52 2.68a38.28 38.28 0 0 0 1.15 5.2c.13.41.29.82.46 1.22a2.2 2.2 0 0 1 .2.84 1.33 1.33 0 0 1-.37 1 2.48 2.48 0 0 1-1.56.62 6 6 0 0 1-1.47-.08 8.62 8.62 0 0 1-2.69-.94 5.84 5.84 0 0 1-2.1-2 15.27 15.27 0 0 1-2-5.2l.19.31a9.76 9.76 0 0 0-2.57-1.41 12.13 12.13 0 0 1-3-1.25l.74-.19a14 14 0 0 1-2.58 2.75 8.41 8.41 0 0 0-2.18 2.84 8.13 8.13 0 0 1 1.78-3.21 14.17 14.17 0 0 0 2.08-2.85l.23-.52.5.33a5.89 5.89 0 0 0 1.27.66l1.46.5a10.54 10.54 0 0 1 2.83 1.55l.15.11v.2a14.16 14.16 0 0 0 1.83 4.84 4.89 4.89 0 0 0 1.75 1.69 7.75 7.75 0 0 0 2.38.83 5 5 0 0 0 1.22.06 1.54 1.54 0 0 0 .92-.31c.13-.13.14-.32 0-.72s-.35-.86-.49-1.3a36.1 36.1 0 0 1-1.18-5.34c-.15-.88-.31-1.76-.51-2.61a13 13 0 0 0-.35-1.26 3.72 3.72 0 0 0-.49-1 11.48 11.48 0 0 0-1.94-1.67c-.72-.52-1.46-1-2.22-1.48-1.5-1-3.1-1.75-4.62-2.68-.78-.44-1.57-.86-2.38-1.22a5.79 5.79 0 0 0-2.53-.78Z"})),Qe||(Qe=e.createElement("path",{fill:"#006531",d:"M167.62 84.35c22.06 1.45 35.92 5.68 36.5-3.92S197.69 6.63 141.9.54C89-5.24 83.2 37.33 82.73 45s7.68 8.3 7.68 8.3c.22-4 2.07-7.82 3.22-10.71 15.18-4.88 64.17 1.48 67.52 6.22s.8 13 1.47 16.45 9.68 6.8 9.68 6.8Z"})),Ke||(Ke=e.createElement("path",{fill:"#093f22",d:"M202.05 84.6c2.39-1.92-8.89-16.64-20.3-20.87l-6 7.31-.26 12.81c7.99 2.15 22.68 3.88 26.56.75Z"})),Je||(Je=e.createElement("path",{fill:"#b498c6",d:"M180.18 72.06c3.68 2.46 4 8.69 2.45 12.56s-10.89 10.8-13.28 11.15a26.88 26.88 0 0 1-5.15-.2L171 71.7s5.51-2.1 9.18.36Z"})),Xe||(Xe=e.createElement("path",{fill:"#191a1a",d:"M165.72 67.49s-13.58 37.88-20.45 41.87c1 1 7.06-1.52 9-3.51 3.55-2.44 16.85-34.8 16.85-34.8Z"})),et||(et=e.createElement("path",{fill:"#093f22",d:"M136.35 21.41c-1.17-2.11 21.15-11.14 32.7-11.14 2.66 0 10.64 6.2 11.52 9.74-15.29-.23-43.05 3.5-44.22 1.4Zm4.82 11.1c-.92-3 31.73-6.14 43.24-3.93 6.28 1.2 8.82 13.26 4.14 11.81-12.21-3.78-46.78-5.97-47.38-7.88ZM99.94 23c2.07-.89.29-4.14-1.48-10.93a19.93 19.93 0 0 0-7.35 7.62s6.76 4.16 8.83 3.31Zm-5.66 8.72c.18-1.29-5.85-5.57-6.48-4.62a17.56 17.56 0 0 0-2.94 8.78s9.23-2.88 9.42-4.16Z"})),tt||(tt=e.createElement("path",{fill:"#fcee21",d:"M95.9 65.56c4.07.42 7.79 1.24 12.23-1 0 0-4-8.79-8.72-8s-3.51 9-3.51 9Z"})),nt||(nt=e.createElement("path",{fill:"#f15a24",d:"M108.08 64.63c-5.34-9-13.34-9.9-12.12.92-.49.07-1.34-1.88-1.61-2.93-1.29-5.79 4.65-9.51 9.59-5.14 3.17 2.79 4.45 7.01 4.14 7.15Z"})),rt||(rt=e.createElement("path",{fill:"#f15a24",d:"M106.93 52c1.27.52 2.88 4 1.65 3.5A18.34 18.34 0 0 0 92 57.38c.7-5.91 13-6.22 14.93-5.38Z"})),at||(at=e.createElement("path",{fill:"#8b6c9c",d:"M121.12 71.07c.66 1.59 1.38 3.39-.41 4.53s-4.33-2-5.87-1.57-3.88 2.72-5.55 2.41c-3.52-.66-3.15-3.48-3.15-3.48s-1.61 5.55 4 5.62c3.81 0 4.23-2.58 7.44-2.27s3.46 2.53 4.89 1.61c2.88-1.82.31-6.69-1.35-6.85Z"})),st||(st=e.createElement("path",{fill:"#8b6c9c",d:"M106.73 75.68s-2.65.74-1.19 2.49c-3.18 0-3.08-4.59-1.32-6-.75 2.66 2.51 3.51 2.51 3.51Z"})),ot||(ot=e.createElement("ellipse",{cx:98.36,cy:62.94,fill:"#f15a24",rx:3.53,ry:3.42,transform:"rotate(-5.96 98.33 62.903)"})),it||(it=e.createElement("path",{fill:"#8b6c9c",d:"M138.73 83.69c-8.66 7.53-14.4 12.67-22.62 13-9.3.32-7.2-7.2-7.2-7.2s.85-2.54 5.63-2.77 20.66-2.78 24.19-3.03Z"})),lt||(lt=e.createElement("path",{fill:"#4b3f51",d:"M108.91 89.78c.34-.46 1.86-1.93 2.29-1 1.92 3.93 8.45 1.71 28.05-5.2-15 2.26-17.88.24-20.85.48s-3.62 1.67-4.72 1.45-3.43-1.68-4.73-1.1c-3.03 1.27-2.05 3.67-.04 5.37Z"})),ct||(ct=e.createElement("path",{fill:"#8b6c9c",d:"M132.64 76.68c1.08 1.47 9.51 5.88 9.51 5.88a60.71 60.71 0 0 1-2.89 6.3c.41 0 1.39-5-.85-6.64-1.72-1.22-4.64-2.58-5.77-5.54Z"})),ut||(ut=e.createElement("path",{fill:"#b498c6",d:"M65.82 248.62c-4.13-.44-11-7.38-15.72-6.64s-9.53 5.31-9.53 5.31-12.7-4.87-16.84-4-9.45 2.36-10.63 3.54-.59 5.91 2.22 5.76 6.05-1 9.3-.44 8.73 6.36 12.41 8c14.17 6.2 29.24.44 29.24.44s3.73-11.52-.45-11.97Z"})),dt||(dt=e.createElement("path",{fill:"#8b6c9c",d:"M64.15 248c-2.62.11-5-1.72-6.28-2.59-3.86-2.56-4.62-2.62-19.34 1.45-5.79-2.69-4.72-1.58-7.88-2.74a18.46 18.46 0 0 1 8.14 1.76c-.64 0 13-5.16 16.5-3.92s6.23 5.3 8.86 6.04Z"})),pt||(pt=e.createElement("path",{fill:"#093f22",d:"M90.49 53.46a87 87 0 0 1 3.14-10.86c19.79-3.78 64.81 2.3 67.52 6.22s1.23 13.54 1.18 16.09 8.72 6.72 8.72 6.72l4.57-.74s-8.51-2.28-8.66-6.71 1.56-16.78-3.22-18.69c-29.19-11.62-64.36-8.8-72.53-6.65-6.5 1.7-9.09 6.62-7.44 10.27s6.72 4.35 6.72 4.35Zm70 24.59 7.38 2.95-3.99 9.31-7.34-2.07 3.95-10.19z"})),mt||(mt=e.createElement("path",{fill:"#b498c6",d:"M153.33 236.52c-10.63-4-31.44 3.41-44.53 5.89-29.24 5.53-37.33 5.55-44.09 6-5 .33-3.44 8.5-2.43 12.17 34.11 6.21 41.2 8.42 72 8.92 22.36-5.62 29.72-28.99 19.05-32.98Z"})),ft||(ft=e.createElement("path",{fill:"#8b6c9c",d:"M131.58 242.4c.39-2 .09-3.41.48-5.52l2.21-.22a53.48 53.48 0 0 0-2.69 5.74Z"})),yt||(yt=e.createElement("path",{fill:"#fc3",d:"M148.89 45c2 6.65 5.32 17.43 2.44 27.4-2.29 1-10 3.61-12.33 3.39.66-5.76.44-23.11-3.77-32.64 2.31.14 8.22 1.03 13.66 1.85Z"})),ht||(ht=e.createElement("path",{fill:"#fcee21",d:"M145.22 62.31c-3.94 1.59-12.14 3.79-17.43 1.19 0 0-1.22-9.33 5.51-8.76s11.92 7.57 11.92 7.57Z"})),bt||(bt=e.createElement("path",{fill:"#f15a24",d:"M127.69 63.52c-1.85-4-.92-8.41 4.11-9.48 4.24-.75 11.08 1.85 13.5 8.21-.29.22-7.6-8.06-14-6.15-4.44 1.33-3.13 7.35-3.61 7.42Zm-4.81-17.78c-1.23.51.14 4 1.3 4.36s9.23-2.79 12.1-2.41 8.81 4.79 11.58 7c-.44-1.88-7.92-9.3-10.88-9.92s-12.87.45-14.1.97Z"})),gt||(gt=e.createElement("ellipse",{cx:131.8,cy:60.56,fill:"#f15a24",rx:3.76,ry:3.99,transform:"rotate(-5.96 131.772 60.6)"})));function wt(...e){return e.filter(Boolean).join(" ")}function xt(e,t,...n){if(e in t){let r=t[e];return"function"==typeof r?r(...n):r}let r=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map((e=>`"${e}"`)).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,xt),r}var St,_t,Ot=((_t=Ot||{})[_t.None=0]="None",_t[_t.RenderStrategy=1]="RenderStrategy",_t[_t.Static=2]="Static",_t),Rt=((St=Rt||{})[St.Unmount=0]="Unmount",St[St.Hidden=1]="Hidden",St);function Ct({ourProps:e,theirProps:t,slot:n,defaultTag:r,features:a,visible:s=!0,name:o}){let i=Tt(t,e);if(s)return kt(i,n,r,o);let l=null!=a?a:0;if(2&l){let{static:e=!1,...t}=i;if(e)return kt(t,n,r,o)}if(1&l){let{unmount:e=!0,...t}=i;return xt(e?0:1,{0:()=>null,1:()=>kt({...t,hidden:!0,style:{display:"none"}},n,r,o)})}return kt(i,n,r,o)}function kt(t,n={},r,a){var s;let{as:o=r,children:i,refName:l="ref",...c}=It(t,["unmount","static"]),u=void 0!==t.ref?{[l]:t.ref}:{},d="function"==typeof i?i(n):i;c.className&&"function"==typeof c.className&&(c.className=c.className(n));let p={};if(n){let e=!1,t=[];for(let[r,a]of Object.entries(n))"boolean"==typeof a&&(e=!0),!0===a&&t.push(r);e&&(p["data-headlessui-state"]=t.join(" "))}if(o===e.Fragment&&Object.keys(Nt(c)).length>0){if(!(0,e.isValidElement)(d)||Array.isArray(d)&&d.length>1)throw new Error(['Passing props on "Fragment"!',"",`The current component <${a} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(c).map((e=>` - ${e}`)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map((e=>` - ${e}`)).join("\n")].join("\n"));let t=wt(null==(s=d.props)?void 0:s.className,c.className),n=t?{className:t}:{};return(0,e.cloneElement)(d,Object.assign({},Tt(d.props,Nt(It(c,["ref"]))),p,u,function(...e){return{ref:e.every((e=>null==e))?void 0:t=>{for(let n of e)null!=n&&("function"==typeof n?n(t):n.current=t)}}}(d.ref,u.ref),n))}return(0,e.createElement)(o,Object.assign({},It(c,["ref"]),o!==e.Fragment&&u,o!==e.Fragment&&p),d)}function Tt(...e){if(0===e.length)return{};if(1===e.length)return e[0];let t={},n={};for(let r of e)for(let e in r)e.startsWith("on")&&"function"==typeof r[e]?(null!=n[e]||(n[e]=[]),n[e].push(r[e])):t[e]=r[e];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(n).map((e=>[e,void 0]))));for(let e in n)Object.assign(t,{[e](t,...r){let a=n[e];for(let e of a){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;e(t,...r)}}});return t}function Pt(t){var n;return Object.assign((0,e.forwardRef)(t),{displayName:null!=(n=t.displayName)?n:t.name})}function Nt(e){let t=Object.assign({},e);for(let e in t)void 0===t[e]&&delete t[e];return t}function It(e,t=[]){let n=Object.assign({},e);for(let e of t)e in n&&delete n[e];return n}let Mt=(0,e.createContext)(null);Mt.displayName="OpenClosedContext";var Lt=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Lt||{});function Ft(){return(0,e.useContext)(Mt)}function At({value:t,children:n}){return e.createElement(Mt.Provider,{value:t},n)}var Dt=Object.defineProperty,zt=(e,t,n)=>(((e,t,n)=>{t in e?Dt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n})(e,"symbol"!=typeof t?t+"":t,n),n);let qt=new class{constructor(){zt(this,"current",this.detect()),zt(this,"handoffState","pending"),zt(this,"currentId",0)}set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof window||"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}},jt=(t,n)=>{qt.isServer?(0,e.useEffect)(t,n):(0,e.useLayoutEffect)(t,n)};function Ut(){let t=(0,e.useRef)(!1);return jt((()=>(t.current=!0,()=>{t.current=!1})),[]),t}function $t(t){let n=(0,e.useRef)(t);return jt((()=>{n.current=t}),[t]),n}function Ht(){let[t,n]=(0,e.useState)(qt.isHandoffComplete);return t&&!1===qt.isHandoffComplete&&n(!1),(0,e.useEffect)((()=>{!0!==t&&n(!0)}),[t]),(0,e.useEffect)((()=>qt.handoff()),[]),t}let Vt=function(t){let n=$t(t);return e.useCallback(((...e)=>n.current(...e)),[n])},Bt=Symbol();function Zt(...t){let n=(0,e.useRef)(t);(0,e.useEffect)((()=>{n.current=t}),[t]);let r=Vt((e=>{for(let t of n.current)null!=t&&("function"==typeof t?t(e):t.current=e)}));return t.every((e=>null==e||(null==e?void 0:e[Bt])))?void 0:r}function Gt(){let e=[],t=[],n={enqueue(e){t.push(e)},addEventListener:(e,t,r,a)=>(e.addEventListener(t,r,a),n.add((()=>e.removeEventListener(t,r,a)))),requestAnimationFrame(...e){let t=requestAnimationFrame(...e);return n.add((()=>cancelAnimationFrame(t)))},nextFrame:(...e)=>n.requestAnimationFrame((()=>n.requestAnimationFrame(...e))),setTimeout(...e){let t=setTimeout(...e);return n.add((()=>clearTimeout(t)))},microTask(...e){let t={current:!0};return function(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch((e=>setTimeout((()=>{throw e}))))}((()=>{t.current&&e[0]()})),n.add((()=>{t.current=!1}))},add:t=>(e.push(t),()=>{let n=e.indexOf(t);if(n>=0){let[t]=e.splice(n,1);t()}}),dispose(){for(let t of e.splice(0))t()},async workQueue(){for(let e of t.splice(0))await e()}};return n}function Wt(e,...t){e&&t.length>0&&e.classList.add(...t)}function Yt(e,...t){e&&t.length>0&&e.classList.remove(...t)}function Qt(){let[t]=(0,e.useState)(Gt);return(0,e.useEffect)((()=>()=>t.dispose()),[t]),t}function Kt({container:e,direction:t,classes:n,onStart:r,onStop:a}){let s=Ut(),o=Qt(),i=$t(t);jt((()=>{let t=Gt();o.add(t.dispose);let l=e.current;if(l&&"idle"!==i.current&&s.current)return t.dispose(),r.current(i.current),t.add(function(e,t,n,r){let a=n?"enter":"leave",s=Gt(),o=void 0!==r?function(e){let t={called:!1};return(...n)=>{if(!t.called)return t.called=!0,e(...n)}}(r):()=>{};"enter"===a&&(e.removeAttribute("hidden"),e.style.display="");let i=xt(a,{enter:()=>t.enter,leave:()=>t.leave}),l=xt(a,{enter:()=>t.enterTo,leave:()=>t.leaveTo}),c=xt(a,{enter:()=>t.enterFrom,leave:()=>t.leaveFrom});return Yt(e,...t.enter,...t.enterTo,...t.enterFrom,...t.leave,...t.leaveFrom,...t.leaveTo,...t.entered),Wt(e,...i,...c),s.nextFrame((()=>{Yt(e,...c),Wt(e,...l),function(e,t){let n=Gt();if(!e)return n.dispose;let{transitionDuration:r,transitionDelay:a}=getComputedStyle(e),[s,o]=[r,a].map((e=>{let[t=0]=e.split(",").filter(Boolean).map((e=>e.includes("ms")?parseFloat(e):1e3*parseFloat(e))).sort(((e,t)=>t-e));return t}));if(s+o!==0){let r=n.addEventListener(e,"transitionend",(e=>{e.target===e.currentTarget&&(t(),r())}))}else t();n.add((()=>t())),n.dispose}(e,(()=>(Yt(e,...i),Wt(e,...t.entered),o())))})),s.dispose}(l,n.current,"enter"===i.current,(()=>{t.dispose(),a.current(i.current)}))),t.dispose}),[t])}function Jt(e=""){return e.split(" ").filter((e=>e.trim().length>1))}let Xt=(0,e.createContext)(null);Xt.displayName="TransitionContext";var en=(e=>(e.Visible="visible",e.Hidden="hidden",e))(en||{});let tn=(0,e.createContext)(null);function nn(e){return"children"in e?nn(e.children):e.current.filter((({el:e})=>null!==e.current)).filter((({state:e})=>"visible"===e)).length>0}function rn(t,n){let r=$t(t),a=(0,e.useRef)([]),s=Ut(),o=Qt(),i=Vt(((e,t=Rt.Hidden)=>{let n=a.current.findIndex((({el:t})=>t===e));-1!==n&&(xt(t,{[Rt.Unmount](){a.current.splice(n,1)},[Rt.Hidden](){a.current[n].state="hidden"}}),o.microTask((()=>{var e;!nn(a)&&s.current&&(null==(e=r.current)||e.call(r))})))})),l=Vt((e=>{let t=a.current.find((({el:t})=>t===e));return t?"visible"!==t.state&&(t.state="visible"):a.current.push({el:e,state:"visible"}),()=>i(e,Rt.Unmount)})),c=(0,e.useRef)([]),u=(0,e.useRef)(Promise.resolve()),d=(0,e.useRef)({enter:[],leave:[],idle:[]}),p=Vt(((e,t,r)=>{c.current.splice(0),n&&(n.chains.current[t]=n.chains.current[t].filter((([t])=>t!==e))),null==n||n.chains.current[t].push([e,new Promise((e=>{c.current.push(e)}))]),null==n||n.chains.current[t].push([e,new Promise((e=>{Promise.all(d.current[t].map((([e,t])=>t))).then((()=>e()))}))]),"enter"===t?u.current=u.current.then((()=>null==n?void 0:n.wait.current)).then((()=>r(t))):r(t)})),m=Vt(((e,t,n)=>{Promise.all(d.current[t].splice(0).map((([e,t])=>t))).then((()=>{var e;null==(e=c.current.shift())||e()})).then((()=>n(t)))}));return(0,e.useMemo)((()=>({children:a,register:l,unregister:i,onStart:p,onStop:m,wait:u,chains:d})),[l,i,a,p,m,d,u])}function an(){}tn.displayName="NestingContext";let sn=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function on(e){var t;let n={};for(let r of sn)n[r]=null!=(t=e[r])?t:an;return n}let ln=Ot.RenderStrategy,cn=Pt((function(t,n){let{beforeEnter:r,afterEnter:a,beforeLeave:s,afterLeave:o,enter:i,enterFrom:l,enterTo:c,entered:u,leave:d,leaveFrom:p,leaveTo:m,...f}=t,y=(0,e.useRef)(null),h=Zt(y,n),b=f.unmount?Rt.Unmount:Rt.Hidden,{show:g,appear:v,initial:E}=function(){let t=(0,e.useContext)(Xt);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),[w,x]=(0,e.useState)(g?"visible":"hidden"),S=function(){let t=(0,e.useContext)(tn);if(null===t)throw new Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return t}(),{register:_,unregister:O}=S,R=(0,e.useRef)(null);(0,e.useEffect)((()=>_(y)),[_,y]),(0,e.useEffect)((()=>{if(b===Rt.Hidden&&y.current)return g&&"visible"!==w?void x("visible"):xt(w,{hidden:()=>O(y),visible:()=>_(y)})}),[w,y,_,O,g,b]);let C=$t({enter:Jt(i),enterFrom:Jt(l),enterTo:Jt(c),entered:Jt(u),leave:Jt(d),leaveFrom:Jt(p),leaveTo:Jt(m)}),k=function(t){let n=(0,e.useRef)(on(t));return(0,e.useEffect)((()=>{n.current=on(t)}),[t]),n}({beforeEnter:r,afterEnter:a,beforeLeave:s,afterLeave:o}),T=Ht();(0,e.useEffect)((()=>{if(T&&"visible"===w&&null===y.current)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")}),[y,w,T]);let P=E&&!v,N=!T||P||R.current===g?"idle":g?"enter":"leave",I=Vt((e=>xt(e,{enter:()=>k.current.beforeEnter(),leave:()=>k.current.beforeLeave(),idle:()=>{}}))),M=Vt((e=>xt(e,{enter:()=>k.current.afterEnter(),leave:()=>k.current.afterLeave(),idle:()=>{}}))),L=rn((()=>{x("hidden"),O(y)}),S);Kt({container:y,classes:C,direction:N,onStart:$t((e=>{L.onStart(y,e,I)})),onStop:$t((e=>{L.onStop(y,e,M),"leave"===e&&!nn(L)&&(x("hidden"),O(y))}))}),(0,e.useEffect)((()=>{!P||(b===Rt.Hidden?R.current=null:R.current=g)}),[g,P,w]);let F=f,A={ref:h};return v&&g&&qt.isServer&&(F={...F,className:wt(f.className,...C.current.enter,...C.current.enterFrom)}),e.createElement(tn.Provider,{value:L},e.createElement(At,{value:xt(w,{visible:Lt.Open,hidden:Lt.Closed})},Ct({ourProps:A,theirProps:F,defaultTag:"div",features:ln,visible:"visible"===w,name:"Transition.Child"})))})),un=Pt((function(t,n){let{show:r,appear:a=!1,unmount:s,...o}=t,i=(0,e.useRef)(null),l=Zt(i,n);Ht();let c=Ft();if(void 0===r&&null!==c&&(r=xt(c,{[Lt.Open]:!0,[Lt.Closed]:!1})),![!0,!1].includes(r))throw new Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[u,d]=(0,e.useState)(r?"visible":"hidden"),p=rn((()=>{d("hidden")})),[m,f]=(0,e.useState)(!0),y=(0,e.useRef)([r]);jt((()=>{!1!==m&&y.current[y.current.length-1]!==r&&(y.current.push(r),f(!1))}),[y,r]);let h=(0,e.useMemo)((()=>({show:r,appear:a,initial:m})),[r,a,m]);(0,e.useEffect)((()=>{if(r)d("visible");else if(nn(p)){let e=i.current;if(!e)return;let t=e.getBoundingClientRect();0===t.x&&0===t.y&&0===t.width&&0===t.height&&d("hidden")}else d("hidden")}),[r,p]);let b={unmount:s};return e.createElement(tn.Provider,{value:p},e.createElement(Xt.Provider,{value:h},Ct({ourProps:{...b,as:e.Fragment,children:e.createElement(cn,{ref:l,...b,...o})},theirProps:{},defaultTag:e.Fragment,features:ln,visible:"visible"===u,name:"Transition"})))})),dn=Pt((function(t,n){let r=null!==(0,e.useContext)(Xt),a=null!==Ft();return e.createElement(e.Fragment,null,!r&&a?e.createElement(un,{ref:n,...t}):e.createElement(cn,{ref:n,...t}))})),pn=Object.assign(un,{Child:dn,Root:un});const mn=window.yoast.helpers;class fn extends Error{constructor(e,t,n,r,a){super(e),this.name="RequestError",this.url=t,this.method=n,this.statusCode=r,this.stackTrace=a}}const{stripTagsFromHtmlString:yn}=mn.strings,hn=["a","p"];function bn({title:t,value:n}){return n?(0,e.createElement)("p",null,(0,e.createElement)("strong",null,t),(0,e.createElement)("br",null),n):null}function gn({title:t,value:n}){return n?(0,e.createElement)("details",null,(0,e.createElement)("summary",null,t),(0,e.createElement)("pre",{className:"yst-overflow-x-scroll yst-max-w-[500px] yst-border-px yst-p-4"},n)):null}function vn({message:t,error:n,className:r}){return(0,e.createElement)(z,{type:"error",className:r},(0,e.createElement)("div",{dangerouslySetInnerHTML:{__html:yn(t,hn)}}),(0,e.createElement)("details",null,(0,e.createElement)("summary",null,(0,i.__)("Error details","wordpress-seo")),(0,e.createElement)("div",{className:"yst-mt-2"},(0,e.createElement)(bn,{title:(0,i.__)("Request URL","wordpress-seo"),value:n.url}),(0,e.createElement)(bn,{title:(0,i.__)("Request method","wordpress-seo"),value:n.method}),(0,e.createElement)(bn,{title:(0,i.__)("Status code","wordpress-seo"),value:n.statusCode}),(0,e.createElement)(bn,{title:(0,i.__)("Error message","wordpress-seo"),value:n.message}),(0,e.createElement)(gn,{title:(0,i.__)("Response","wordpress-seo"),value:n.parseString}),(0,e.createElement)(gn,{title:(0,i.__)("Error stack trace","wordpress-seo"),value:n.stackTrace}))))}bn.propTypes={title:E().string.isRequired,value:E().any},bn.defaultProps={value:""},gn.propTypes={title:E().string.isRequired,value:E().string},gn.defaultProps={value:""},vn.propTypes={message:E().string.isRequired,error:E().oneOfType([E().instanceOf(Error),E().instanceOf(fn)]).isRequired,className:E().string},vn.defaultProps={className:""};class En extends Error{constructor(e,t){super(e),this.name="ParseError",this.parseString=t}}const wn="idle",xn="in_progress",Sn="errored",On="completed";class Rn extends a.Component{constructor(e){super(e),this.settings=yoastIndexingData,this.state={state:wn,processed:0,error:null,amount:parseInt(this.settings.amount,10),firstTime:"1"===this.settings.firstTime},this.startIndexing=this.startIndexing.bind(this),this.stopIndexing=this.stopIndexing.bind(this)}async doIndexingRequest(e,t){const n=await fetch(e,{method:"POST",headers:{"X-WP-Nonce":t}}),r=await n.text();let a;try{a=JSON.parse(r)}catch(e){throw new En("Error parsing the response to JSON.",r)}if(!n.ok){const t=a.data?a.data.stackTrace:"";throw new fn(a.message,e,"POST",n.status,t)}return a}async doPreIndexingAction(e){"function"==typeof this.props.preIndexingActions[e]&&await this.props.preIndexingActions[e](this.settings)}async doPostIndexingAction(e,t){"function"==typeof this.props.indexingActions[e]&&await this.props.indexingActions[e](t.objects,this.settings)}async doIndexing(e){let t=this.settings.restApi.root+this.settings.restApi.indexing_endpoints[e];for(;this.isState(xn)&&!1!==t;)try{await this.doPreIndexingAction(e);const n=await this.doIndexingRequest(t,this.settings.restApi.nonce);await this.doPostIndexingAction(e,n),(0,a.flushSync)((()=>{this.setState((e=>({processed:e.processed+n.objects.length,firstTime:!1})))})),t=n.next_url}catch(e){(0,a.flushSync)((()=>{this.setState({state:Sn,error:e,firstTime:!1})}))}}async index(){for(const e of Object.keys(this.settings.restApi.indexing_endpoints))await this.doIndexing(e);this.isState(Sn)||this.isState(wn)||this.completeIndexing()}async startIndexing(){this.setState({processed:0,state:xn},this.index)}completeIndexing(){this.setState({state:On})}stopIndexing(){this.setState((e=>({state:wn,processed:0,amount:e.amount-e.processed})))}componentDidMount(){var e,t;if(!this.settings.disabled&&(this.props.indexingStateCallback(0===this.state.amount?"already_done":this.state.state),"true"===new URLSearchParams(window.location.search).get("start-indexation"))){const n=function(e,t){const n=new URL(e);return n.searchParams.delete("start-indexation"),n.href}(window.location.href);null,e=document.title,t=n,window.history.pushState(null,e,t),this.startIndexing()}}componentDidUpdate(e,t){this.state.state!==t.state&&this.props.indexingStateCallback(this.state.state)}isState(e){return this.state.state===e}renderFirstIndexationNotice(){return(0,e.createElement)(z,{type:"info",className:"yst-mt-6"},(0,i.__)("This feature includes and replaces the Text Link Counter and Internal Linking Analysis","wordpress-seo"))}renderStartButton(){return(0,e.createElement)(s.Button,{variant:"secondary",onClick:this.startIndexing,id:"indexation-data-optimization","data-hiive-event-name":"clicked_start_data_optimization"},(0,i.__)("Start SEO data optimization","wordpress-seo"))}renderStopButton(){return(0,e.createElement)(s.Button,{variant:"secondary",onClick:this.stopIndexing},(0,i.__)("Stop SEO data optimization","wordpress-seo"))}renderDisabledTool(){return(0,e.createElement)(a.Fragment,null,(0,e.createElement)("p",null,(0,e.createElement)(s.Button,{variant:"secondary",disabled:!0,id:"indexation-data-optimization"},(0,i.__)("Start SEO data optimization","wordpress-seo"))),(0,e.createElement)(z,{type:"info",className:"yst-mt-6"},(0,i.__)("SEO data optimization is disabled for non-production environments.","wordpress-seo")))}renderProgressBar(){let t=0;return this.isState(On)&&(t=100),this.isState(xn)&&(t=this.state.processed/parseInt(this.state.amount,10)*100),(0,e.createElement)("div",{className:"yst-w-full yst-bg-slate-200 yst-rounded-full yst-h-2.5 yst-mb-4"},(0,e.createElement)("div",{className:"yst-transition-[width] yst-ease-linear yst-bg-primary-500 yst-h-2.5 yst-rounded-full",style:{width:`${t}%`}}))}renderCaption(){return(0,e.createElement)(D.Z,{id:"optimization-in-progress-text",height:this.isState(xn)?"auto":0,easing:"linear",duration:300},(0,e.createElement)("p",{className:"yst-text-sm yst-italic yst-mb-4 yst-mt-4"},(0,i.__)("SEO data optimization is running… You can safely move on to the next steps of this configuration.","wordpress-seo")))}renderErrorAlert(){return(0,e.createElement)(vn,{message:yoastIndexingData.errorMessage,error:this.state.error,className:"yst-mb-4"})}render(){return this.settings.disabled?this.renderDisabledTool():(0,e.createElement)("div",{className:"yst-relative"},this.props.children,(0,e.createElement)(pn,{unmount:!1,show:this.isState(Sn)||this.isState(xn)||this.isState(wn)&&this.state.amount>0,leave:"yst-transition-opacity yst-duration-1000",leaveFrom:"yst-opacity-100",leaveTo:"yst-opacity-0"},this.renderProgressBar(),this.isState(Sn)&&this.renderErrorAlert(),this.isState(xn)?this.renderStopButton():this.renderStartButton(),this.renderCaption(),this.isState(wn)&&this.state.firstTime&&this.renderFirstIndexationNotice()))}}Rn.propTypes={indexingActions:E().object,preIndexingActions:E().object,indexingStateCallback:E().func,children:E().node},Rn.defaultProps={indexingActions:{},preIndexingActions:{},indexingStateCallback:()=>{},children:null};const Cn=Rn;function kn({indexingStateCallback:t,indexingState:n,isStepperFinished:r}){return(0,e.createElement)(Cn,{preIndexingActions:window.yoast.indexing.preIndexingActions,indexingActions:window.yoast.indexing.indexingActions,indexingStateCallback:t},(0,e.createElement)(pn,{unmount:!1,show:["completed","already_done"].includes(n),enter:"yst-transition-opacity yst-duration-1000",enterFrom:"yst-opacity-0",enterTo:"yst-opacity-100"},(0,e.createElement)(z,{type:"success"},"already_done"!==n||r?(0,i.__)("We've successfully analyzed your site & optimized your SEO data!","wordpress-seo"):(0,i.__)("We've already successfully analyzed your site. You can move on to the next step.","wordpress-seo"))))}function Tn({indexingState:t,setIndexingState:n,showRunIndexationAlert:r,isStepperFinished:s}){return(0,e.createElement)(a.Fragment,null,(0,e.createElement)("div",{className:"yst-flex yst-flex-row yst-justify-between yst-flex-wrap yst-mb-8"},(0,e.createElement)("p",{className:"yst-text-sm yst-whitespace-pre-line yst-w-[463px]"},(0,i.__)("Let's start by running the SEO data optimization. That means we'll scan your site and create a database with optimized SEO data. It won't change any content or settings on your site and you don't need to do anything, just hit start!\n\nNote: If you have a lot of content, this optimization could take a moment. But trust us, it's worth it!","wordpress-seo")),(0,e.createElement)(Et,{className:"yst-h-28 yst-w-24 yst-mr-6"})),(0,e.createElement)("div",{id:"yoast-configuration-indexing-container",className:"indexation-container"},(0,e.createElement)(kn,{indexingStateCallback:n,indexingState:t,isStepperFinished:s})),(0,e.createElement)(q,{id:"indexation-alert",isVisible:"idle"===t&&r,expandDuration:400,type:"info"},(0,i.__)("Be aware that you should run the SEO data optimization for this configuration to take maximum effect.","wordpress-seo")))}function Pn(t,n,r=""){return(0,a.createInterpolateElement)(t,{a:(0,e.createElement)("a",{id:r,href:n,target:"_blank",rel:"noopener noreferrer"})})}var Nn;kn.propTypes={indexingStateCallback:E().func.isRequired,indexingState:E().string.isRequired,isStepperFinished:E().bool},kn.defaultProps={isStepperFinished:!1},Tn.propTypes={indexingState:E().string.isRequired,setIndexingState:E().func.isRequired,showRunIndexationAlert:E().bool,isStepperFinished:E().bool},Tn.defaultProps={showRunIndexationAlert:!1,isStepperFinished:!1};let In=null!=(Nn=e.useId)?Nn:function(){let t=Ht(),[n,r]=e.useState(t?()=>qt.nextId():null);return jt((()=>{null===n&&r(qt.nextId())}),[n]),null!=n?""+n:void 0};function Mn(t,n){let[r,a]=(0,e.useState)(t),s=$t(t);return jt((()=>a(s.current)),[s,a,...n]),r}var Ln=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(Ln||{}),Fn=(e=>(e[e.First=0]="First",e[e.Previous=1]="Previous",e[e.Next=2]="Next",e[e.Last=3]="Last",e[e.Specific=4]="Specific",e[e.Nothing=5]="Nothing",e))(Fn||{});function An(e,t){let n=t.resolveItems();if(n.length<=0)return null;let r=t.resolveActiveIndex(),a=null!=r?r:-1,s=(()=>{switch(e.focus){case 0:return n.findIndex((e=>!t.resolveDisabled(e)));case 1:{let e=n.slice().reverse().findIndex(((e,n,r)=>!(-1!==a&&r.length-n-1>=a||t.resolveDisabled(e))));return-1===e?e:n.length-1-e}case 2:return n.findIndex(((e,n)=>!(n<=a||t.resolveDisabled(e))));case 3:{let e=n.slice().reverse().findIndex((e=>!t.resolveDisabled(e)));return-1===e?e:n.length-1-e}case 4:return n.findIndex((n=>t.resolveId(n)===e.id));case 5:return null;default:!function(e){throw new Error("Unexpected object: "+e)}(e)}})();return-1===s?r:s}function Dn(e){let t=e.parentElement,n=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(n=t),t=t.parentElement;let r=""===(null==t?void 0:t.getAttribute("disabled"));return(!r||!function(e){if(!e)return!1;let t=e.previousElementSibling;for(;null!==t;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}(n))&&r}function zn(e){return qt.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}let qn=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map((e=>`${e}:not([tabindex='-1'])`)).join(",");var jn,Un=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e))(Un||{}),$n=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))($n||{}),Hn=((jn=Hn||{})[jn.Previous=-1]="Previous",jn[jn.Next=1]="Next",jn),Vn=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(Vn||{});function Bn(e,t=0){var n;return e!==(null==(n=zn(e))?void 0:n.body)&&xt(t,{0:()=>e.matches(qn),1(){let t=e;for(;null!==t;){if(t.matches(qn))return!0;t=t.parentElement}return!1}})}function Zn(e,t=(e=>e)){return e.slice().sort(((e,n)=>{let r=t(e),a=t(n);if(null===r||null===a)return 0;let s=r.compareDocumentPosition(a);return s&Node.DOCUMENT_POSITION_FOLLOWING?-1:s&Node.DOCUMENT_POSITION_PRECEDING?1:0}))}function Gn(e){var t;if(e.type)return e.type;let n=null!=(t=e.as)?t:"button";return"string"==typeof n&&"button"===n.toLowerCase()?"button":void 0}function Wn(t,n){let[r,a]=(0,e.useState)((()=>Gn(t)));return jt((()=>{a(Gn(t))}),[t.type,t.as]),jt((()=>{r||!n.current||n.current instanceof HTMLButtonElement&&!n.current.hasAttribute("type")&&a("button")}),[r,n]),r}function Yn(t,n,r){let a=$t(n);(0,e.useEffect)((()=>{function e(e){a.current(e)}return document.addEventListener(t,e,r),()=>document.removeEventListener(t,e,r)}),[t,r])}function Qn(t,n,r=!0){let a=(0,e.useRef)(!1);function s(e,r){if(!a.current||e.defaultPrevented)return;let s=function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(t),o=r(e);if(null!==o&&o.getRootNode().contains(o)){for(let t of s){if(null===t)continue;let n=t instanceof HTMLElement?t:t.current;if(null!=n&&n.contains(o)||e.composed&&e.composedPath().includes(n))return}return!Bn(o,Vn.Loose)&&-1!==o.tabIndex&&e.preventDefault(),n(e,o)}}(0,e.useEffect)((()=>{requestAnimationFrame((()=>{a.current=r}))}),[r]);let o=(0,e.useRef)(null);Yn("mousedown",(e=>{var t,n;a.current&&(o.current=(null==(n=null==(t=e.composedPath)?void 0:t.call(e))?void 0:n[0])||e.target)}),!0),Yn("click",(e=>{!o.current||(s(e,(()=>o.current)),o.current=null)}),!0),Yn("blur",(e=>s(e,(()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null))),!0)}["textarea","input"].join(",");var Kn=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(Kn||{});let Jn=Pt((function(e,t){let{features:n=1,...r}=e;return Ct({ourProps:{ref:t,"aria-hidden":2==(2&n)||void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...4==(4&n)&&2!=(2&n)&&{display:"none"}}},theirProps:r,slot:{},defaultTag:"div",name:"Hidden"})}));function Xn(e={},t=null,n=[]){for(let[r,a]of Object.entries(e))tr(n,er(t,r),a);return n}function er(e,t){return e?e+"["+t+"]":t}function tr(e,t,n){if(Array.isArray(n))for(let[r,a]of n.entries())tr(e,er(t,r.toString()),a);else n instanceof Date?e.push([t,n.toISOString()]):"boolean"==typeof n?e.push([t,n?"1":"0"]):"string"==typeof n?e.push([t,n]):"number"==typeof n?e.push([t,`${n}`]):null==n?e.push([t,""]):Xn(n,t,e)}function nr(t,n,r){let[a,s]=(0,e.useState)(r),o=void 0!==t,i=(0,e.useRef)(o),l=(0,e.useRef)(!1),c=(0,e.useRef)(!1);return!o||i.current||l.current?!o&&i.current&&!c.current&&(c.current=!0,i.current=o,console.error("A component is changing from controlled to uncontrolled. This may be caused by the value changing from a defined value to undefined, which should not happen.")):(l.current=!0,i.current=o,console.error("A component is changing from uncontrolled to controlled. This may be caused by the value changing from undefined to a defined value, which should not happen.")),[o?t:a,Vt((e=>(o||s(e),null==n?void 0:n(e))))]}function rr(e){return[e.screenX,e.screenY]}function ar(){let t=(0,e.useRef)([-1,-1]);return{wasMoved(e){let n=rr(e);return(t.current[0]!==n[0]||t.current[1]!==n[1])&&(t.current=n,!0)},update(e){t.current=rr(e)}}}var sr=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(sr||{}),or=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(or||{}),ir=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(ir||{}),lr=(e=>(e[e.OpenListbox=0]="OpenListbox",e[e.CloseListbox=1]="CloseListbox",e[e.GoToOption=2]="GoToOption",e[e.Search=3]="Search",e[e.ClearSearch=4]="ClearSearch",e[e.RegisterOption=5]="RegisterOption",e[e.UnregisterOption=6]="UnregisterOption",e[e.RegisterLabel=7]="RegisterLabel",e))(lr||{});function cr(e,t=(e=>e)){let n=null!==e.activeOptionIndex?e.options[e.activeOptionIndex]:null,r=Zn(t(e.options.slice()),(e=>e.dataRef.current.domRef.current)),a=n?r.indexOf(n):null;return-1===a&&(a=null),{options:r,activeOptionIndex:a}}let ur={1:e=>e.dataRef.current.disabled||1===e.listboxState?e:{...e,activeOptionIndex:null,listboxState:1},0(e){if(e.dataRef.current.disabled||0===e.listboxState)return e;let t=e.activeOptionIndex,{isSelected:n}=e.dataRef.current,r=e.options.findIndex((e=>n(e.dataRef.current.value)));return-1!==r&&(t=r),{...e,listboxState:0,activeOptionIndex:t}},2(e,t){var n;if(e.dataRef.current.disabled||1===e.listboxState)return e;let r=cr(e),a=An(t,{resolveItems:()=>r.options,resolveActiveIndex:()=>r.activeOptionIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});return{...e,...r,searchQuery:"",activeOptionIndex:a,activationTrigger:null!=(n=t.trigger)?n:1}},3:(e,t)=>{if(e.dataRef.current.disabled||1===e.listboxState)return e;let n=""!==e.searchQuery?0:1,r=e.searchQuery+t.value.toLowerCase(),a=(null!==e.activeOptionIndex?e.options.slice(e.activeOptionIndex+n).concat(e.options.slice(0,e.activeOptionIndex+n)):e.options).find((e=>{var t;return!e.dataRef.current.disabled&&(null==(t=e.dataRef.current.textValue)?void 0:t.startsWith(r))})),s=a?e.options.indexOf(a):-1;return-1===s||s===e.activeOptionIndex?{...e,searchQuery:r}:{...e,searchQuery:r,activeOptionIndex:s,activationTrigger:1}},4:e=>e.dataRef.current.disabled||1===e.listboxState||""===e.searchQuery?e:{...e,searchQuery:""},5:(e,t)=>{let n={id:t.id,dataRef:t.dataRef},r=cr(e,(e=>[...e,n]));return null===e.activeOptionIndex&&e.dataRef.current.isSelected(t.dataRef.current.value)&&(r.activeOptionIndex=r.options.indexOf(n)),{...e,...r}},6:(e,t)=>{let n=cr(e,(e=>{let n=e.findIndex((e=>e.id===t.id));return-1!==n&&e.splice(n,1),e}));return{...e,...n,activationTrigger:1}},7:(e,t)=>({...e,labelId:t.id})},dr=(0,e.createContext)(null);function pr(t){let n=(0,e.useContext)(dr);if(null===n){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,pr),e}return n}dr.displayName="ListboxActionsContext";let mr=(0,e.createContext)(null);function fr(t){let n=(0,e.useContext)(mr);if(null===n){let e=new Error(`<${t} /> is missing a parent <Listbox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,fr),e}return n}function yr(e,t){return xt(t.type,ur,e,t)}mr.displayName="ListboxDataContext";let hr=e.Fragment,br=Pt((function(t,n){let{value:r,defaultValue:a,name:s,onChange:o,by:i=((e,t)=>e===t),disabled:l=!1,horizontal:c=!1,multiple:u=!1,...d}=t;const p=c?"horizontal":"vertical";let m=Zt(n),[f=(u?[]:void 0),y]=nr(r,o,a),[h,b]=(0,e.useReducer)(yr,{dataRef:(0,e.createRef)(),listboxState:1,options:[],searchQuery:"",labelId:null,activeOptionIndex:null,activationTrigger:1}),g=(0,e.useRef)({static:!1,hold:!1}),v=(0,e.useRef)(null),E=(0,e.useRef)(null),w=(0,e.useRef)(null),x=Vt("string"==typeof i?(e,t)=>{let n=i;return(null==e?void 0:e[n])===(null==t?void 0:t[n])}:i),S=(0,e.useCallback)((e=>xt(_.mode,{1:()=>f.some((t=>x(t,e))),0:()=>x(f,e)})),[f]),_=(0,e.useMemo)((()=>({...h,value:f,disabled:l,mode:u?1:0,orientation:p,compare:x,isSelected:S,optionsPropsRef:g,labelRef:v,buttonRef:E,optionsRef:w})),[f,l,u,h]);jt((()=>{h.dataRef.current=_}),[_]),Qn([_.buttonRef,_.optionsRef],((e,t)=>{var n;b({type:1}),Bn(t,Vn.Loose)||(e.preventDefault(),null==(n=_.buttonRef.current)||n.focus())}),0===_.listboxState);let O=(0,e.useMemo)((()=>({open:0===_.listboxState,disabled:l,value:f})),[_,l,f]),R=Vt((e=>{let t=_.options.find((t=>t.id===e));!t||M(t.dataRef.current.value)})),C=Vt((()=>{if(null!==_.activeOptionIndex){let{dataRef:e,id:t}=_.options[_.activeOptionIndex];M(e.current.value),b({type:2,focus:Fn.Specific,id:t})}})),k=Vt((()=>b({type:0}))),T=Vt((()=>b({type:1}))),P=Vt(((e,t,n)=>e===Fn.Specific?b({type:2,focus:Fn.Specific,id:t,trigger:n}):b({type:2,focus:e,trigger:n}))),N=Vt(((e,t)=>(b({type:5,id:e,dataRef:t}),()=>b({type:6,id:e})))),I=Vt((e=>(b({type:7,id:e}),()=>b({type:7,id:null})))),M=Vt((e=>xt(_.mode,{0:()=>null==y?void 0:y(e),1(){let t=_.value.slice(),n=t.findIndex((t=>x(t,e)));return-1===n?t.push(e):t.splice(n,1),null==y?void 0:y(t)}}))),L=Vt((e=>b({type:3,value:e}))),F=Vt((()=>b({type:4}))),A=(0,e.useMemo)((()=>({onChange:M,registerOption:N,registerLabel:I,goToOption:P,closeListbox:T,openListbox:k,selectActiveOption:C,selectOption:R,search:L,clearSearch:F})),[]),D={ref:m},z=(0,e.useRef)(null),q=Qt();return(0,e.useEffect)((()=>{!z.current||void 0!==a&&q.addEventListener(z.current,"reset",(()=>{M(a)}))}),[z,M]),e.createElement(dr.Provider,{value:A},e.createElement(mr.Provider,{value:_},e.createElement(At,{value:xt(_.listboxState,{0:Lt.Open,1:Lt.Closed})},null!=s&&null!=f&&Xn({[s]:f}).map((([t,n],r)=>e.createElement(Jn,{features:Kn.Hidden,ref:0===r?e=>{var t;z.current=null!=(t=null==e?void 0:e.closest("form"))?t:null}:void 0,...Nt({key:t,as:"input",type:"hidden",hidden:!0,readOnly:!0,name:t,value:n})}))),Ct({ourProps:D,theirProps:d,slot:O,defaultTag:hr,name:"Listbox"}))))})),gr=Pt((function(t,n){var r;let a=In(),{id:s=`headlessui-listbox-button-${a}`,...o}=t,i=fr("Listbox.Button"),l=pr("Listbox.Button"),c=Zt(i.buttonRef,n),u=Qt(),d=Vt((e=>{switch(e.key){case Ln.Space:case Ln.Enter:case Ln.ArrowDown:e.preventDefault(),l.openListbox(),u.nextFrame((()=>{i.value||l.goToOption(Fn.First)}));break;case Ln.ArrowUp:e.preventDefault(),l.openListbox(),u.nextFrame((()=>{i.value||l.goToOption(Fn.Last)}))}})),p=Vt((e=>{e.key===Ln.Space&&e.preventDefault()})),m=Vt((e=>{if(Dn(e.currentTarget))return e.preventDefault();0===i.listboxState?(l.closeListbox(),u.nextFrame((()=>{var e;return null==(e=i.buttonRef.current)?void 0:e.focus({preventScroll:!0})}))):(e.preventDefault(),l.openListbox())})),f=Mn((()=>{if(i.labelId)return[i.labelId,s].join(" ")}),[i.labelId,s]),y=(0,e.useMemo)((()=>({open:0===i.listboxState,disabled:i.disabled,value:i.value})),[i]);return Ct({ourProps:{ref:c,id:s,type:Wn(t,i.buttonRef),"aria-haspopup":"listbox","aria-controls":null==(r=i.optionsRef.current)?void 0:r.id,"aria-expanded":i.disabled?void 0:0===i.listboxState,"aria-labelledby":f,disabled:i.disabled,onKeyDown:d,onKeyUp:p,onClick:m},theirProps:o,slot:y,defaultTag:"button",name:"Listbox.Button"})})),vr=Pt((function(t,n){let r=In(),{id:a=`headlessui-listbox-label-${r}`,...s}=t,o=fr("Listbox.Label"),i=pr("Listbox.Label"),l=Zt(o.labelRef,n);jt((()=>i.registerLabel(a)),[a]);let c=Vt((()=>{var e;return null==(e=o.buttonRef.current)?void 0:e.focus({preventScroll:!0})})),u=(0,e.useMemo)((()=>({open:0===o.listboxState,disabled:o.disabled})),[o]);return Ct({ourProps:{ref:l,id:a,onClick:c},theirProps:s,slot:u,defaultTag:"label",name:"Listbox.Label"})})),Er=Ot.RenderStrategy|Ot.Static,wr=Pt((function(t,n){var r;let a=In(),{id:s=`headlessui-listbox-options-${a}`,...o}=t,i=fr("Listbox.Options"),l=pr("Listbox.Options"),c=Zt(i.optionsRef,n),u=Qt(),d=Qt(),p=Ft(),m=null!==p?p===Lt.Open:0===i.listboxState;(0,e.useEffect)((()=>{var e;let t=i.optionsRef.current;!t||0===i.listboxState&&t!==(null==(e=zn(t))?void 0:e.activeElement)&&t.focus({preventScroll:!0})}),[i.listboxState,i.optionsRef]);let f=Vt((e=>{switch(d.dispose(),e.key){case Ln.Space:if(""!==i.searchQuery)return e.preventDefault(),e.stopPropagation(),l.search(e.key);case Ln.Enter:if(e.preventDefault(),e.stopPropagation(),null!==i.activeOptionIndex){let{dataRef:e}=i.options[i.activeOptionIndex];l.onChange(e.current.value)}0===i.mode&&(l.closeListbox(),Gt().nextFrame((()=>{var e;return null==(e=i.buttonRef.current)?void 0:e.focus({preventScroll:!0})})));break;case xt(i.orientation,{vertical:Ln.ArrowDown,horizontal:Ln.ArrowRight}):return e.preventDefault(),e.stopPropagation(),l.goToOption(Fn.Next);case xt(i.orientation,{vertical:Ln.ArrowUp,horizontal:Ln.ArrowLeft}):return e.preventDefault(),e.stopPropagation(),l.goToOption(Fn.Previous);case Ln.Home:case Ln.PageUp:return e.preventDefault(),e.stopPropagation(),l.goToOption(Fn.First);case Ln.End:case Ln.PageDown:return e.preventDefault(),e.stopPropagation(),l.goToOption(Fn.Last);case Ln.Escape:return e.preventDefault(),e.stopPropagation(),l.closeListbox(),u.nextFrame((()=>{var e;return null==(e=i.buttonRef.current)?void 0:e.focus({preventScroll:!0})}));case Ln.Tab:e.preventDefault(),e.stopPropagation();break;default:1===e.key.length&&(l.search(e.key),d.setTimeout((()=>l.clearSearch()),350))}})),y=Mn((()=>{var e,t,n;return null!=(n=null==(e=i.labelRef.current)?void 0:e.id)?n:null==(t=i.buttonRef.current)?void 0:t.id}),[i.labelRef.current,i.buttonRef.current]),h=(0,e.useMemo)((()=>({open:0===i.listboxState})),[i]);return Ct({ourProps:{"aria-activedescendant":null===i.activeOptionIndex||null==(r=i.options[i.activeOptionIndex])?void 0:r.id,"aria-multiselectable":1===i.mode||void 0,"aria-labelledby":y,"aria-orientation":i.orientation,id:s,onKeyDown:f,role:"listbox",tabIndex:0,ref:c},theirProps:o,slot:h,defaultTag:"ul",features:Er,visible:m,name:"Listbox.Options"})})),xr=Pt((function(t,n){let r=In(),{id:a=`headlessui-listbox-option-${r}`,disabled:s=!1,value:o,...i}=t,l=fr("Listbox.Option"),c=pr("Listbox.Option"),u=null!==l.activeOptionIndex&&l.options[l.activeOptionIndex].id===a,d=l.isSelected(o),p=(0,e.useRef)(null),m=$t({disabled:s,value:o,domRef:p,get textValue(){var e,t;return null==(t=null==(e=p.current)?void 0:e.textContent)?void 0:t.toLowerCase()}}),f=Zt(n,p);jt((()=>{if(0!==l.listboxState||!u||0===l.activationTrigger)return;let e=Gt();return e.requestAnimationFrame((()=>{var e,t;null==(t=null==(e=p.current)?void 0:e.scrollIntoView)||t.call(e,{block:"nearest"})})),e.dispose}),[p,u,l.listboxState,l.activationTrigger,l.activeOptionIndex]),jt((()=>c.registerOption(a,m)),[m,a]);let y=Vt((e=>{if(s)return e.preventDefault();c.onChange(o),0===l.mode&&(c.closeListbox(),Gt().nextFrame((()=>{var e;return null==(e=l.buttonRef.current)?void 0:e.focus({preventScroll:!0})})))})),h=Vt((()=>{if(s)return c.goToOption(Fn.Nothing);c.goToOption(Fn.Specific,a)})),b=ar(),g=Vt((e=>b.update(e))),v=Vt((e=>{!b.wasMoved(e)||s||u||c.goToOption(Fn.Specific,a,0)})),E=Vt((e=>{!b.wasMoved(e)||s||!u||c.goToOption(Fn.Nothing)})),w=(0,e.useMemo)((()=>({active:u,selected:d,disabled:s})),[u,d,s]);return Ct({ourProps:{id:a,ref:f,role:"option",tabIndex:!0===s?void 0:-1,"aria-disabled":!0===s||void 0,"aria-selected":d,disabled:void 0,onClick:y,onFocus:h,onPointerEnter:g,onMouseEnter:g,onPointerMove:v,onMouseMove:v,onPointerLeave:E,onMouseLeave:E},theirProps:i,slot:w,defaultTag:"li",name:"Listbox.Option"})})),Sr=Object.assign(br,{Button:gr,Label:vr,Options:wr,Option:xr});const _r=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{fillRule:"evenodd",d:"M10 3a1 1 0 01.707.293l3 3a1 1 0 01-1.414 1.414L10 5.414 7.707 7.707a1 1 0 01-1.414-1.414l3-3A1 1 0 0110 3zm-3.707 9.293a1 1 0 011.414 0L10 14.586l2.293-2.293a1 1 0 011.414 1.414l-3 3a1 1 0 01-1.414 0l-3-3a1 1 0 010-1.414z",clipRule:"evenodd"}))}));function Or({id:t,value:n,choices:r,label:s,onChange:o,error:l,disabled:c}){const u=(0,a.useMemo)((()=>{const e=r.find((e=>n===e.value));return e?e.label:(0,i.__)("Select an option","wordpress-seo")}),[r,n]);return(0,e.createElement)(Sr,{id:t,as:"div",value:n,onChange:o,disabled:c},(({open:o})=>(0,e.createElement)(a.Fragment,null,s&&(0,e.createElement)(Sr.Label,{className:"yst-block yst-max-w-sm yst-mb-1 yst-text-sm yst-font-medium yst-text-slate-700"},s),(0,e.createElement)("div",{className:"yst-max-w-sm"},(0,e.createElement)("div",{className:"yst-relative"},(0,e.createElement)(Sr.Button,{"data-id":`button-${t} `,className:m()("yst-relative yst-h-[45px] yst-w-full yst-leading-6 yst-py-2 yst-pl-3 yst-pr-10 yst-text-left yst-bg-white yst-border yst-border-slate-300 yst-rounded-md yst-shadow-sm yst-cursor-default focus:yst-outline-none focus:yst-ring-1 focus:yst-ring-primary-500 focus:yst-border-primary-500 sm:yst-text-sm",{"yst-border-red-300":l.isVisible,"yst-opacity-50":c},"emptyChoice"===n?"yst-text-slate-400":"yst-text-slate-700"),...y(t,l)},(0,e.createElement)("span",{className:"yst-block yst-truncate"},u),(0,e.createElement)("span",{className:"yst-absolute yst-inset-y-0 yst-right-0 yst-flex yst-items-center yst-pr-2 yst-pointer-events-none"},(0,e.createElement)(_r,{className:"yst-w-5 yst-h-5 yst-text-slate-400","aria-hidden":"true"})),l.isVisible&&(0,e.createElement)("div",{className:"yst-flex yst-items-center yst-absolute yst-inset-y-0 yst-right-0 yst-mr-8"},(0,e.createElement)(O,{className:"yst-pointer-events-none yst-h-5 yst-w-5 yst-text-red-500"}))),(0,e.createElement)(pn,{show:o,as:a.Fragment,leave:"yst-transition yst-ease-in yst-duration-100",leaveFrom:"yst-opacity-100",leaveTo:"yst-opacity-0"},(0,e.createElement)(Sr.Options,{static:!0,className:"yst-absolute yst-z-10 yst-w-full yst-mt-1 yst-overflow-auto yst-bg-white yst-rounded-md yst-shadow-lg yst-max-h-60 yst-ring-1 yst-ring-black yst-ring-opacity-5 focus:yst-outline-none sm:yst-text-sm"},r.map((t=>(0,e.createElement)(Sr.Option,{key:t.id,as:a.Fragment,value:t.value},(({selected:n,active:r})=>(0,e.createElement)("li",{className:h({selected:n,active:r})},(0,e.createElement)("span",{className:m()(n?"yst-font-semibold":"yst-font-normal","yst-block yst-truncate")},t.label),n?(0,e.createElement)("span",{className:m()("yst-text-white yst-absolute yst-inset-y-0 yst-right-0 yst-flex yst-items-center yst-pr-4")},(0,e.createElement)(H,{className:"yst-w-5 yst-h-5","aria-hidden":"true"})):null)))))))),l.isVisible&&(0,e.createElement)(k,{id:f(t),className:"yst-mt-2 yst-text-sm yst-text-red-600",texts:l.message})))))}Or.propTypes={value:v.PropTypes.string.isRequired,choices:v.PropTypes.arrayOf(v.PropTypes.shape({id:v.PropTypes.oneOfType([v.PropTypes.number,v.PropTypes.string]).isRequired,value:v.PropTypes.string.isRequired,label:v.PropTypes.string.isRequired})).isRequired,label:v.PropTypes.string.isRequired,onChange:v.PropTypes.func.isRequired,id:v.PropTypes.string.isRequired,error:v.PropTypes.shape({message:v.PropTypes.string,isVisible:v.PropTypes.bool}),disabled:v.PropTypes.bool},Or.defaultProps={error:{message:"",isVisible:!1},disabled:!1};const Rr=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:2,stroke:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M4 16l4.586-4.586a2 2 0 012.828 0L16 16m-2-2l1.586-1.586a2 2 0 012.828 0L20 14m-6-6h.01M6 20h12a2 2 0 002-2V6a2 2 0 00-2-2H6a2 2 0 00-2 2v12a2 2 0 002 2z"}))})),Cr=({className:t})=>(0,e.createElement)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",className:m()("yst-animate-spin",t)},(0,e.createElement)("circle",{className:"yst-opacity-25",cx:"12",cy:"12",r:"10",stroke:"currentColor",strokeWidth:"4"}),(0,e.createElement)("path",{className:"yst-opacity-75",fill:"currentColor",d:"M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"}));Cr.propTypes={className:E().string},Cr.defaultProps={className:""};const kr=Cr;function Tr({id:t,imageAltText:n,url:r,fallbackUrl:o,label:l,onSelectImageClick:c,onRemoveImageClick:u,className:d,error:p,status:h}){const b=m()("yst-relative yst-w-full yst-h-48 yst-mt-2 yst-flex yst-justify-center yst-items-center yst-rounded-md yst-mb-4 focus:yst-outline-none focus:yst-ring-2 focus:yst-ring-offset-2 focus:yst-ring-primary-500",p.isVisible?"yst-border-red-300":"yst-border-slate-300","yst-border-2 yst-border-dashed"),g=(0,a.useCallback)((()=>"loading"===h?(0,e.createElement)("div",{className:"yst-text-center"},(0,e.createElement)(kr,{size:"10",color:"gray-400",className:"yst-inline-block"}),(0,e.createElement)("p",{className:"yst-mt-3"},(0,i.__)("Uploading image...","wordpress-seo"))):r?(0,e.createElement)("img",{src:r,alt:n,className:"yst-w-full yst-h-full yst-object-contain"}):o?(0,e.createElement)("img",{src:o,alt:n,className:"yst-w-full yst-h-full yst-object-contain"}):(0,e.createElement)(Rr,{id:`${t}-no-image-svg`,className:"yst-w-14 yst-h-14 yst-text-slate-500"})),[h,t,r,n]);return(0,e.createElement)("div",{className:m()("yst-max-w-sm",d),...y(t,p)},(0,e.createElement)("label",{htmlFor:t,className:"yst-block yst-mb-2 yst-font-medium yst-text-slate-700"},l),(0,e.createElement)("button",{id:t,className:b,onClick:c,type:"button","data-hiive-event-name":"clicked_select_image"},g()),(0,e.createElement)("div",null,(0,e.createElement)(s.Button,{id:r?t+"__replace-image":t+"__select-image",variant:"secondary",className:"yst-mr-2",onClick:c,"data-hiive-event-name":r?"clicked_replace_image":"clicked_select_image"},r?(0,i.__)("Replace image","wordpress-seo"):(0,i.__)("Select image","wordpress-seo")),r&&(0,e.createElement)(s.Link,{id:`${t}__remove-image`,as:"button",type:"button",variant:"error",onClick:u,className:"yst-px-3 yst-py-2 yst-rounded-md","data-hiive-event-name":"clicked_remove_image"},(0,i.__)("Remove image","wordpress-seo"))),"error"===h&&(0,e.createElement)("p",{className:"yst-mt-2 yst-text-sm yst-text-red-600"},p),p.isVisible&&(0,e.createElement)(k,{id:f(t),className:"yst-mt-2 yst-text-sm yst-text-red-600",texts:p.message}))}Tr.propTypes={label:E().string,id:E().string.isRequired,url:E().string,fallbackUrl:E().string,imageAltText:E().string,onRemoveImageClick:E().func,onSelectImageClick:E().func,className:E().string,error:E().shape({message:E().string,isVisible:E().bool}),status:E().string},Tr.defaultProps={label:"",url:"",fallbackUrl:"",imageAltText:"",onRemoveImageClick:o.noop,onSelectImageClick:o.noop,className:"",error:{message:"",isVisible:!1},status:"idle"},window.yoast.socialMetadataForms;const Pr=e=>({type:e.subtype,width:e.width,height:e.height,url:e.url,id:e.id,sizes:e.sizes,alt:e.alt||e.title||e.name});function Nr(e){(function(e){const t=window.wp.media();return t.on("select",(()=>{const n=t.state().get("selection").first();e(Pr(n.attributes))})),t})(e).open()}function Ir({dispatch:t,imageUrl:n,fallbackImageUrl:r,organizationName:s,fallbackOrganizationName:o,errorFields:l}){const c=(0,a.useCallback)((()=>{Nr((e=>{t({type:"SET_COMPANY_LOGO",payload:{...e}})}))}),[Nr]),u=(0,a.useCallback)((()=>{t({type:"REMOVE_COMPANY_LOGO"})})),d=(0,a.useCallback)((e=>{t({type:"CHANGE_COMPANY_NAME",payload:e.target.value})}));return(0,e.createElement)(a.Fragment,null,(0,e.createElement)(P,{className:"yst-mt-6",id:"organization-name-input",name:"organization-name",label:(0,i.__)("Organization name","wordpress-seo"),value:""===s?o:s,onChange:d,feedback:{isVisible:l.includes("company_name"),message:[(0,i.__)("We could not save the organization name. Please check the value.","wordpress-seo")],type:"error"}}),(0,e.createElement)(Tr,{className:"yst-mt-6",id:"organization-logo-input",url:n,fallbackUrl:r,onSelectImageClick:c,onRemoveImageClick:u,imageAltText:"",hasPreview:!0,label:(0,i.__)("Organization logo","wordpress-seo")}))}function Mr(t,n){let r=(0,e.useRef)([]),a=Vt(t);(0,e.useEffect)((()=>{let e=[...r.current];for(let[t,s]of n.entries())if(r.current[t]!==s){let t=a(n,e);return r.current=n,t}}),[a,...n])}Ir.propTypes={dispatch:E().func.isRequired,imageUrl:E().string,fallbackImageUrl:E().string,organizationName:E().string,fallbackOrganizationName:E().string,errorFields:E().array},Ir.defaultProps={imageUrl:"",fallbackImageUrl:"",organizationName:"",fallbackOrganizationName:"",errorFields:[]};var Lr=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Lr||{}),Fr=(e=>(e[e.Single=0]="Single",e[e.Multi=1]="Multi",e))(Fr||{}),Ar=(e=>(e[e.Pointer=0]="Pointer",e[e.Other=1]="Other",e))(Ar||{}),Dr=(e=>(e[e.OpenCombobox=0]="OpenCombobox",e[e.CloseCombobox=1]="CloseCombobox",e[e.GoToOption=2]="GoToOption",e[e.RegisterOption=3]="RegisterOption",e[e.UnregisterOption=4]="UnregisterOption",e[e.RegisterLabel=5]="RegisterLabel",e))(Dr||{});function zr(e,t=(e=>e)){let n=null!==e.activeOptionIndex?e.options[e.activeOptionIndex]:null,r=Zn(t(e.options.slice()),(e=>e.dataRef.current.domRef.current)),a=n?r.indexOf(n):null;return-1===a&&(a=null),{options:r,activeOptionIndex:a}}let qr={1:e=>e.dataRef.current.disabled||1===e.comboboxState?e:{...e,activeOptionIndex:null,comboboxState:1},0(e){if(e.dataRef.current.disabled||0===e.comboboxState)return e;let t=e.activeOptionIndex,{isSelected:n}=e.dataRef.current,r=e.options.findIndex((e=>n(e.dataRef.current.value)));return-1!==r&&(t=r),{...e,comboboxState:0,activeOptionIndex:t}},2(e,t){var n;if(e.dataRef.current.disabled||e.dataRef.current.optionsRef.current&&!e.dataRef.current.optionsPropsRef.current.static&&1===e.comboboxState)return e;let r=zr(e);if(null===r.activeOptionIndex){let e=r.options.findIndex((e=>!e.dataRef.current.disabled));-1!==e&&(r.activeOptionIndex=e)}let a=An(t,{resolveItems:()=>r.options,resolveActiveIndex:()=>r.activeOptionIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});return{...e,...r,activeOptionIndex:a,activationTrigger:null!=(n=t.trigger)?n:1}},3:(e,t)=>{let n={id:t.id,dataRef:t.dataRef},r=zr(e,(e=>[...e,n]));null===e.activeOptionIndex&&e.dataRef.current.isSelected(t.dataRef.current.value)&&(r.activeOptionIndex=r.options.indexOf(n));let a={...e,...r,activationTrigger:1};return e.dataRef.current.__demoMode&&void 0===e.dataRef.current.value&&(a.activeOptionIndex=0),a},4:(e,t)=>{let n=zr(e,(e=>{let n=e.findIndex((e=>e.id===t.id));return-1!==n&&e.splice(n,1),e}));return{...e,...n,activationTrigger:1}},5:(e,t)=>({...e,labelId:t.id})},jr=(0,e.createContext)(null);function Ur(t){let n=(0,e.useContext)(jr);if(null===n){let e=new Error(`<${t} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,Ur),e}return n}jr.displayName="ComboboxActionsContext";let $r=(0,e.createContext)(null);function Hr(t){let n=(0,e.useContext)($r);if(null===n){let e=new Error(`<${t} /> is missing a parent <Combobox /> component.`);throw Error.captureStackTrace&&Error.captureStackTrace(e,Hr),e}return n}function Vr(e,t){return xt(t.type,qr,e,t)}$r.displayName="ComboboxDataContext";let Br=e.Fragment,Zr=Pt((function(t,n){let{value:r,defaultValue:a,onChange:s,name:o,by:i=((e,t)=>e===t),disabled:l=!1,__demoMode:c=!1,nullable:u=!1,multiple:d=!1,...p}=t,[m=(d?[]:void 0),f]=nr(r,s,a),[y,h]=(0,e.useReducer)(Vr,{dataRef:(0,e.createRef)(),comboboxState:c?0:1,options:[],activeOptionIndex:null,activationTrigger:1,labelId:null}),b=(0,e.useRef)(!1),g=(0,e.useRef)({static:!1,hold:!1}),v=(0,e.useRef)(null),E=(0,e.useRef)(null),w=(0,e.useRef)(null),x=(0,e.useRef)(null),S=Vt("string"==typeof i?(e,t)=>{let n=i;return(null==e?void 0:e[n])===(null==t?void 0:t[n])}:i),_=(0,e.useCallback)((e=>xt(O.mode,{1:()=>m.some((t=>S(t,e))),0:()=>S(m,e)})),[m]),O=(0,e.useMemo)((()=>({...y,optionsPropsRef:g,labelRef:v,inputRef:E,buttonRef:w,optionsRef:x,value:m,defaultValue:a,disabled:l,mode:d?1:0,get activeOptionIndex(){if(b.current&&null===y.activeOptionIndex&&y.options.length>0){let e=y.options.findIndex((e=>!e.dataRef.current.disabled));if(-1!==e)return e}return y.activeOptionIndex},compare:S,isSelected:_,nullable:u,__demoMode:c})),[m,a,l,d,u,c,y]);jt((()=>{y.dataRef.current=O}),[O]),Qn([O.buttonRef,O.inputRef,O.optionsRef],(()=>F.closeCombobox()),0===O.comboboxState);let R=(0,e.useMemo)((()=>({open:0===O.comboboxState,disabled:l,activeIndex:O.activeOptionIndex,activeOption:null===O.activeOptionIndex?null:O.options[O.activeOptionIndex].dataRef.current.value,value:m})),[O,l,m]),C=Vt((e=>{let t=O.options.find((t=>t.id===e));!t||L(t.dataRef.current.value)})),k=Vt((()=>{if(null!==O.activeOptionIndex){let{dataRef:e,id:t}=O.options[O.activeOptionIndex];L(e.current.value),F.goToOption(Fn.Specific,t)}})),T=Vt((()=>{h({type:0}),b.current=!0})),P=Vt((()=>{h({type:1}),b.current=!1})),N=Vt(((e,t,n)=>(b.current=!1,e===Fn.Specific?h({type:2,focus:Fn.Specific,id:t,trigger:n}):h({type:2,focus:e,trigger:n})))),I=Vt(((e,t)=>(h({type:3,id:e,dataRef:t}),()=>h({type:4,id:e})))),M=Vt((e=>(h({type:5,id:e}),()=>h({type:5,id:null})))),L=Vt((e=>xt(O.mode,{0:()=>null==f?void 0:f(e),1(){let t=O.value.slice(),n=t.findIndex((t=>S(t,e)));return-1===n?t.push(e):t.splice(n,1),null==f?void 0:f(t)}}))),F=(0,e.useMemo)((()=>({onChange:L,registerOption:I,registerLabel:M,goToOption:N,closeCombobox:P,openCombobox:T,selectActiveOption:k,selectOption:C})),[]),A=null===n?{}:{ref:n},D=(0,e.useRef)(null),z=Qt();return(0,e.useEffect)((()=>{!D.current||void 0!==a&&z.addEventListener(D.current,"reset",(()=>{L(a)}))}),[D,L]),e.createElement(jr.Provider,{value:F},e.createElement($r.Provider,{value:O},e.createElement(At,{value:xt(O.comboboxState,{0:Lt.Open,1:Lt.Closed})},null!=o&&null!=m&&Xn({[o]:m}).map((([t,n],r)=>e.createElement(Jn,{features:Kn.Hidden,ref:0===r?e=>{var t;D.current=null!=(t=null==e?void 0:e.closest("form"))?t:null}:void 0,...Nt({key:t,as:"input",type:"hidden",hidden:!0,readOnly:!0,name:t,value:n})}))),Ct({ourProps:A,theirProps:p,slot:R,defaultTag:Br,name:"Combobox"}))))})),Gr=Pt((function(t,n){var r,a,s,o;let i=In(),{id:l=`headlessui-combobox-input-${i}`,onChange:c,displayValue:u,type:d="text",...p}=t,m=Hr("Combobox.Input"),f=Ur("Combobox.Input"),y=Zt(m.inputRef,n),h=(0,e.useRef)(!1),b=Qt();var g;Mr((([e,t],[n,r])=>{h.current||!m.inputRef.current||(0===r&&1===t||e!==n)&&(m.inputRef.current.value=e)}),["function"==typeof u&&void 0!==m.value?null!=(g=u(m.value))?g:"":"string"==typeof m.value?m.value:"",m.comboboxState]),Mr((([e],[t])=>{if(0===e&&1===t){let e=m.inputRef.current;if(!e)return;let t=e.value,{selectionStart:n,selectionEnd:r,selectionDirection:a}=e;e.value="",e.value=t,null!==a?e.setSelectionRange(n,r,a):e.setSelectionRange(n,r)}}),[m.comboboxState]);let v=(0,e.useRef)(!1),E=Vt((()=>{v.current=!0})),w=Vt((()=>{setTimeout((()=>{v.current=!1}))})),x=Vt((e=>{switch(h.current=!0,e.key){case Ln.Backspace:case Ln.Delete:if(0!==m.mode||!m.nullable)return;let t=e.currentTarget;b.requestAnimationFrame((()=>{""===t.value&&(f.onChange(null),m.optionsRef.current&&(m.optionsRef.current.scrollTop=0),f.goToOption(Fn.Nothing))}));break;case Ln.Enter:if(h.current=!1,0!==m.comboboxState||v.current)return;if(e.preventDefault(),e.stopPropagation(),null===m.activeOptionIndex)return void f.closeCombobox();f.selectActiveOption(),0===m.mode&&f.closeCombobox();break;case Ln.ArrowDown:return h.current=!1,e.preventDefault(),e.stopPropagation(),xt(m.comboboxState,{0:()=>{f.goToOption(Fn.Next)},1:()=>{f.openCombobox()}});case Ln.ArrowUp:return h.current=!1,e.preventDefault(),e.stopPropagation(),xt(m.comboboxState,{0:()=>{f.goToOption(Fn.Previous)},1:()=>{f.openCombobox(),b.nextFrame((()=>{m.value||f.goToOption(Fn.Last)}))}});case Ln.Home:if(e.shiftKey)break;return h.current=!1,e.preventDefault(),e.stopPropagation(),f.goToOption(Fn.First);case Ln.PageUp:return h.current=!1,e.preventDefault(),e.stopPropagation(),f.goToOption(Fn.First);case Ln.End:if(e.shiftKey)break;return h.current=!1,e.preventDefault(),e.stopPropagation(),f.goToOption(Fn.Last);case Ln.PageDown:return h.current=!1,e.preventDefault(),e.stopPropagation(),f.goToOption(Fn.Last);case Ln.Escape:return h.current=!1,0!==m.comboboxState?void 0:(e.preventDefault(),m.optionsRef.current&&!m.optionsPropsRef.current.static&&e.stopPropagation(),f.closeCombobox());case Ln.Tab:if(h.current=!1,0!==m.comboboxState)return;0===m.mode&&f.selectActiveOption(),f.closeCombobox()}})),S=Vt((e=>{f.openCombobox(),null==c||c(e)})),_=Vt((()=>{h.current=!1})),O=Mn((()=>{if(m.labelId)return[m.labelId].join(" ")}),[m.labelId]),R=(0,e.useMemo)((()=>({open:0===m.comboboxState,disabled:m.disabled})),[m]);return Ct({ourProps:{ref:y,id:l,role:"combobox",type:d,"aria-controls":null==(r=m.optionsRef.current)?void 0:r.id,"aria-expanded":m.disabled?void 0:0===m.comboboxState,"aria-activedescendant":null===m.activeOptionIndex||null==(a=m.options[m.activeOptionIndex])?void 0:a.id,"aria-multiselectable":1===m.mode||void 0,"aria-labelledby":O,"aria-autocomplete":"list",defaultValue:null!=(o=null!=(s=t.defaultValue)?s:void 0!==m.defaultValue?null==u?void 0:u(m.defaultValue):null)?o:m.defaultValue,disabled:m.disabled,onCompositionStart:E,onCompositionEnd:w,onKeyDown:x,onChange:S,onBlur:_},theirProps:p,slot:R,defaultTag:"input",name:"Combobox.Input"})})),Wr=Pt((function(t,n){var r;let a=Hr("Combobox.Button"),s=Ur("Combobox.Button"),o=Zt(a.buttonRef,n),i=In(),{id:l=`headlessui-combobox-button-${i}`,...c}=t,u=Qt(),d=Vt((e=>{switch(e.key){case Ln.ArrowDown:return e.preventDefault(),e.stopPropagation(),1===a.comboboxState&&s.openCombobox(),u.nextFrame((()=>{var e;return null==(e=a.inputRef.current)?void 0:e.focus({preventScroll:!0})}));case Ln.ArrowUp:return e.preventDefault(),e.stopPropagation(),1===a.comboboxState&&(s.openCombobox(),u.nextFrame((()=>{a.value||s.goToOption(Fn.Last)}))),u.nextFrame((()=>{var e;return null==(e=a.inputRef.current)?void 0:e.focus({preventScroll:!0})}));case Ln.Escape:return 0!==a.comboboxState?void 0:(e.preventDefault(),a.optionsRef.current&&!a.optionsPropsRef.current.static&&e.stopPropagation(),s.closeCombobox(),u.nextFrame((()=>{var e;return null==(e=a.inputRef.current)?void 0:e.focus({preventScroll:!0})})));default:return}})),p=Vt((e=>{if(Dn(e.currentTarget))return e.preventDefault();0===a.comboboxState?s.closeCombobox():(e.preventDefault(),s.openCombobox()),u.nextFrame((()=>{var e;return null==(e=a.inputRef.current)?void 0:e.focus({preventScroll:!0})}))})),m=Mn((()=>{if(a.labelId)return[a.labelId,l].join(" ")}),[a.labelId,l]),f=(0,e.useMemo)((()=>({open:0===a.comboboxState,disabled:a.disabled,value:a.value})),[a]);return Ct({ourProps:{ref:o,id:l,type:Wn(t,a.buttonRef),tabIndex:-1,"aria-haspopup":"listbox","aria-controls":null==(r=a.optionsRef.current)?void 0:r.id,"aria-expanded":a.disabled?void 0:0===a.comboboxState,"aria-labelledby":m,disabled:a.disabled,onClick:p,onKeyDown:d},theirProps:c,slot:f,defaultTag:"button",name:"Combobox.Button"})})),Yr=Pt((function(t,n){let r=In(),{id:a=`headlessui-combobox-label-${r}`,...s}=t,o=Hr("Combobox.Label"),i=Ur("Combobox.Label"),l=Zt(o.labelRef,n);jt((()=>i.registerLabel(a)),[a]);let c=Vt((()=>{var e;return null==(e=o.inputRef.current)?void 0:e.focus({preventScroll:!0})})),u=(0,e.useMemo)((()=>({open:0===o.comboboxState,disabled:o.disabled})),[o]);return Ct({ourProps:{ref:l,id:a,onClick:c},theirProps:s,slot:u,defaultTag:"label",name:"Combobox.Label"})})),Qr=Ot.RenderStrategy|Ot.Static,Kr=Pt((function(t,n){let r=In(),{id:a=`headlessui-combobox-options-${r}`,hold:s=!1,...o}=t,i=Hr("Combobox.Options"),l=Zt(i.optionsRef,n),c=Ft(),u=null!==c?c===Lt.Open:0===i.comboboxState;jt((()=>{var e;i.optionsPropsRef.current.static=null!=(e=t.static)&&e}),[i.optionsPropsRef,t.static]),jt((()=>{i.optionsPropsRef.current.hold=s}),[i.optionsPropsRef,s]),function({container:t,accept:n,walk:r,enabled:a=!0}){let s=(0,e.useRef)(n),o=(0,e.useRef)(r);(0,e.useEffect)((()=>{s.current=n,o.current=r}),[n,r]),jt((()=>{if(!t||!a)return;let e=zn(t);if(!e)return;let n=s.current,r=o.current,i=Object.assign((e=>n(e)),{acceptNode:n}),l=e.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,i,!1);for(;l.nextNode();)r(l.currentNode)}),[t,a,s,o])}({container:i.optionsRef.current,enabled:0===i.comboboxState,accept:e=>"option"===e.getAttribute("role")?NodeFilter.FILTER_REJECT:e.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT,walk(e){e.setAttribute("role","none")}});let d=Mn((()=>{var e,t;return null!=(t=i.labelId)?t:null==(e=i.buttonRef.current)?void 0:e.id}),[i.labelId,i.buttonRef.current]);return Ct({ourProps:{"aria-labelledby":d,role:"listbox",id:a,ref:l},theirProps:o,slot:(0,e.useMemo)((()=>({open:0===i.comboboxState})),[i]),defaultTag:"ul",features:Qr,visible:u,name:"Combobox.Options"})})),Jr=Pt((function(t,n){var r,a;let s=In(),{id:o=`headlessui-combobox-option-${s}`,disabled:i=!1,value:l,...c}=t,u=Hr("Combobox.Option"),d=Ur("Combobox.Option"),p=null!==u.activeOptionIndex&&u.options[u.activeOptionIndex].id===o,m=u.isSelected(l),f=(0,e.useRef)(null),y=$t({disabled:i,value:l,domRef:f,textValue:null==(a=null==(r=f.current)?void 0:r.textContent)?void 0:a.toLowerCase()}),h=Zt(n,f),b=Vt((()=>d.selectOption(o)));jt((()=>d.registerOption(o,y)),[y,o]);let g=(0,e.useRef)(!u.__demoMode);jt((()=>{if(!u.__demoMode)return;let e=Gt();return e.requestAnimationFrame((()=>{g.current=!0})),e.dispose}),[]),jt((()=>{if(0!==u.comboboxState||!p||!g.current||0===u.activationTrigger)return;let e=Gt();return e.requestAnimationFrame((()=>{var e,t;null==(t=null==(e=f.current)?void 0:e.scrollIntoView)||t.call(e,{block:"nearest"})})),e.dispose}),[f,p,u.comboboxState,u.activationTrigger,u.activeOptionIndex]);let v=Vt((e=>{if(i)return e.preventDefault();b(),0===u.mode&&d.closeCombobox()})),E=Vt((()=>{if(i)return d.goToOption(Fn.Nothing);d.goToOption(Fn.Specific,o)})),w=ar(),x=Vt((e=>w.update(e))),S=Vt((e=>{!w.wasMoved(e)||i||p||d.goToOption(Fn.Specific,o,0)})),_=Vt((e=>{!w.wasMoved(e)||i||!p||u.optionsPropsRef.current.hold||d.goToOption(Fn.Nothing)})),O=(0,e.useMemo)((()=>({active:p,selected:m,disabled:i})),[p,m,i]);return Ct({ourProps:{id:o,ref:h,role:"option",tabIndex:!0===i?void 0:-1,"aria-disabled":!0===i||void 0,"aria-selected":m,disabled:void 0,onClick:v,onFocus:E,onPointerEnter:x,onMouseEnter:x,onPointerMove:S,onMouseMove:S,onPointerLeave:_,onMouseLeave:_},theirProps:c,slot:O,defaultTag:"li",name:"Combobox.Option"})})),Xr=Object.assign(Zr,{Input:Gr,Button:Wr,Label:Yr,Options:Kr,Option:Jr});function ea(e){return e&&e.label?e.label:null}function ta({id:t,value:n,label:r,onChange:s,onQueryChange:o,options:l,placeholder:c,isLoading:u}){const[d,p]=(0,a.useState)(l),[f,y]=(0,a.useState)(""),b=(0,a.useCallback)((e=>{y(e.target.value)}),[y]),g=(0,a.useCallback)((()=>{y("")}),[y]);(0,a.useEffect)((()=>{p(l)}),[l]),(0,a.useEffect)((()=>{o?o(f):p(l.filter((e=>e.label.toLowerCase().includes(f.toLowerCase()))))}),[f,o]);const v=(0,a.useCallback)(((e,t)=>({selected:n,active:r})=>h({selected:n||e===t,active:r})),[h]),E=(0,a.useCallback)((e=>t=>{e&&t.stopPropagation()}),[]);return(0,e.createElement)(Xr,{id:t,as:"div",value:n,onChange:s,onBlur:g},(({open:s})=>(0,e.createElement)(a.Fragment,null,r&&(0,e.createElement)(Xr.Label,{className:"yst-block yst-mb-1 yst-max-w-sm yst-text-sm yst-font-medium yst-text-slate-700"},r),(0,e.createElement)("div",{className:"yst-h-[45px] yst-max-w-sm yst-relative"},(0,e.createElement)(Xr.Button,{"data-id":`button-${t}`,role:"button",className:"yst-w-full yst-h-full yst-rounded-md yst-border yst-border-slate-300 yst-flex yst-items-center yst-rounded-r-md yst-pl-3 yst-pr-2 focus-within:yst-border-primary-500 focus-within:yst-outline-none focus-within:yst-ring-1 focus-within:yst-ring-primary-500",as:"div"},(0,e.createElement)(Xr.Input,{"data-id":`input-${t}`,className:"yst-w-full yst-text-slate-700 yst-rounded-md yst-border-0 yst-outline-none yst-bg-white yst-py-2 yst-pl-0 yst-pr-10 yst-shadow-none sm:yst-text-sm",onChange:b,displayValue:ea,placeholder:c,onClick:E(s)}),(0,e.createElement)(_r,{className:"yst-h-5 yst-w-5 yst-text-slate-400 yst-inset-y-0 yst-right-0","aria-hidden":"true"})),d.length>0&&(0,e.createElement)(Xr.Options,{className:"yst-absolute yst-z-10 yst-mt-1 yst-max-h-60 yst-w-full yst-overflow-auto yst-rounded-md yst-bg-white yst-text-base yst-shadow-lg yst-ring-1 yst-ring-black yst-ring-opacity-5 focus:yst-outline-none sm:yst-text-sm"},u&&(0,e.createElement)("div",{className:"yst-flex yst-bg-white yst-sticky yst-z-20 yst-text-sm yst-italic yst-top-0 yst-py-2 yst-pl-3 yst-pr-9 yst-my-0"},(0,e.createElement)(kr,{className:"yst-text-primary-500 yst-h-4 yst-w-4 yst-mr-2 yst-self-center"}),(0,i.__)("Loading...","wordpress-seo")),d.map((t=>(0,e.createElement)(Xr.Option,{key:`yst-option-${t.value}`,value:t,className:v(t.value,n.value)},(({selected:r})=>(0,e.createElement)(a.Fragment,null,(0,e.createElement)("span",{className:m()("yst-block yst-truncate",(r||n.value===t.value)&&"yst-font-semibold")},t.label),(r||n.value===t.value)&&(0,e.createElement)("span",{className:"yst-absolute yst-inset-y-0 yst-right-0 yst-flex yst-items-center yst-pr-4 yst-text-white"},(0,e.createElement)(H,{className:"yst-h-5 yst-w-5","aria-hidden":"true"}))))))))))))}ta.propTypes={onChange:E().func.isRequired,options:E().array.isRequired,id:E().string.isRequired,value:E().shape({value:E().number,label:E().string}),label:E().string,onQueryChange:E().func,placeholder:E().string,isLoading:E().bool},ta.defaultProps={value:null,label:"",onQueryChange:null,placeholder:(0,i.__)("Select an option","wordpress-seo"),isLoading:!1};const na={"X-WP-NONCE":wpApiSettings.nonce},ra=wpApiSettings.root;function aa({initialValue:t,onChangeCallback:n,placeholder:r}){const[s,l]=(0,a.useState)([]),[c,u]=(0,a.useState)({value:t.id,label:t.name}),[d,p]=(0,a.useState)(!1),m=(0,a.useRef)(!0);(0,a.useEffect)((()=>()=>{m.current=!1}),[]);const f=(0,a.useCallback)((e=>{u(e),n(e)})),y=(0,a.useCallback)((0,o.debounce)((async e=>{p(!0);const t=await function(e=""){const t=`${ra}wp/v2/users?per_page=20${e?`&search=${encodeURIComponent(e)}`:""}`;return(0,mn.sendRequest)(t,{method:"GET",headers:na})}(e);m.current&&(p(!1),l(t.map((e=>({value:e.id,label:e.name})))))}),500),[]);return(0,e.createElement)(ta,{id:"yoast-configuration-user-select",value:c,label:(0,i.__)("Name","wordpress-seo"),onChange:f,onQueryChange:y,options:s,placeholder:r,isLoading:d})}function sa({dispatch:t,imageUrl:n,fallbackImageUrl:r,person:s,canEditUser:o}){const l=(0,a.useCallback)((()=>{Nr((e=>{t({type:"SET_PERSON_LOGO",payload:{...e}})}))}),[Nr]),u=(0,a.useCallback)((()=>{t({type:"REMOVE_PERSON_LOGO"})})),d=(0,a.useCallback)((e=>{t({type:"SET_PERSON",payload:e}),c()({path:`yoast/v1/configuration/check_capability?user_id=${e.value}`}).then((e=>{t({type:"SET_CAN_EDIT_USER",payload:e.success})})).catch((e=>{console.error(e.message)}))}),[t]),p=(0,a.useMemo)((()=>(0,a.createInterpolateElement)((0,i.sprintf)( // translators: %1$s is replaced by the selected user's name, and %2$s and %3$s are opening and closing anchor tags. o?(0,i.__)("You have selected the user %1$s as the person this site represents. This user profile information will now be used in search results. %2$sUpdate this profile to make sure the information is correct%3$s.","wordpress-seo"):(0,i.__)("You have selected the user %1$s as the person this site represents. This user profile information will now be used in search results. You're not allowed to update this user profile, so please ask this user or an admin to make sure the information is correct.","wordpress-seo"),`<b>${s.name}</b>`,"<a>","</a>"),{b:(0,e.createElement)("b",null),a:(0,e.createElement)("a",{id:"yoast-configuration-user-selector-user-link",href:window.wpseoScriptData.userEditUrl.replace("{user_id}",s.id),target:"_blank",rel:"noopener noreferrer"})})),[s.id,s.name,o]);return(0,e.createElement)(a.Fragment,null,(0,e.createElement)(aa,{initialValue:s,onChangeCallback:d,name:"person_id",placeholder:(0,i.__)("Select a user","wordpress-seo")}),(0,e.createElement)(q,{id:"user-representation-alert",isVisible:0!==s.id,type:"info",className:"yst-mt-5"},p),(0,e.createElement)(Tr,{className:"yst-mt-6",id:"person-logo-input",url:n,fallbackUrl:r,onSelectImageClick:l,onRemoveImageClick:u,imageAltText:"",hasPreview:!0,label:(0,i.__)("Personal logo or avatar","wordpress-seo")}))}function oa({onOrganizationOrPersonChange:t,dispatch:n,state:r,siteRepresentationEmpty:s}){const[o,l]=(0,a.useState)("emptyChoice"===r.companyOrPerson?"yst-opacity-0":"yst-opacity-100"),c=(0,a.useCallback)((()=>{l("yst-opacity-100")})),u=(0,a.useCallback)((e=>{n({type:"CHANGE_WEBSITE_NAME",payload:e.target.value})})),d=Pn((0,i.sprintf)(/* translators: %1$s expands to opening 'a' HTML tag, %2$s expands to closing 'a' HTML tag. */ (0,i.__)("Completing this step helps Google to understand your site even better. Bonus: You'll improve your chance of getting %1$srich results%2$s!","wordpress-seo"),"<a>","</a>"),"https://yoa.st/config-workout-rich-results","yoast-configuration-rich-text-link");return(0,e.createElement)(a.Fragment,null,window.wpseoFirstTimeConfigurationData.knowledgeGraphMessage&&(0,e.createElement)(z,{type:"info"},window.wpseoFirstTimeConfigurationData.knowledgeGraphMessage),(0,e.createElement)("p",{className:m()("yst-text-sm yst-whitespace-pre-line yst-mb-6",r.shouldForceCompany?"yst-mt-4":"yst-mt-0")},r.shouldForceCompany?d:(0,e.createElement)(a.Fragment,null,(0,i.__)("Tell us! Is your site about an organization or a person? ","wordpress-seo"),d)),(0,e.createElement)(Or,{id:"organization-person-select",htmlFor:"organization-person-select",name:"organization",label:(0,i.__)("Does your site represent an Organization or Person?","wordpress-seo"),value:r.shouldForceCompany?"company":r.companyOrPerson,onChange:t,choices:r.companyOrPersonOptions,disabled:!!r.shouldForceCompany}),!("company"===r.companyOrPerson&&r.companyName&&r.companyLogo||"company"===r.companyOrPerson&&!r.companyLogoFallback||"person"===r.companyOrPerson&&r.personLogo||"person"===r.companyOrPerson&&!r.personLogoFallback)&&(0,e.createElement)(z,{type:"info",className:"yst-mt-6"},(0,i.__)("We took the liberty of using your website name and logo for the organization name and logo. Feel free to change them below.","wordpress-seo")),(0,e.createElement)(P,{className:"yst-my-6",id:"website-name-input",name:"website-name",label:(0,i.__)("Website name","wordpress-seo"),value:r.websiteName||r.fallbackWebsiteName,onChange:u,feedback:{isVisible:r.errorFields.includes("website_name"),message:[(0,i.__)("We could not save the website name. Please check the value.","wordpress-seo")],type:"error"}}),(0,e.createElement)(D.Z,{height:["company","person"].includes(r.companyOrPerson)?"auto":0,duration:400,easing:"linear",onAnimationEnd:c},(0,e.createElement)("div",{className:m()("yst-transition-opacity yst-duration-300 yst-mt-6",o)},"company"===r.companyOrPerson&&(0,e.createElement)(Ir,{dispatch:n,imageUrl:r.companyLogo,fallbackImageUrl:r.companyLogoFallback,organizationName:r.companyName,fallbackOrganizationName:r.fallbackCompanyName,errorFields:r.errorFields}),"person"===r.companyOrPerson&&(0,e.createElement)(sa,{dispatch:n,imageUrl:r.personLogo,fallbackImageUrl:r.personLogoFallback,person:{id:r.personId,name:r.personName},canEditUser:!!r.canEditUser,errorFields:r.errorFields}))),(0,e.createElement)(q,{id:"site-representation-empty-alert",isVisible:s,className:"yst-mt-6"},(0,i.__)("You're almost there! Complete all settings in this step so search engines know what your site is about.","wordpress-seo")))}aa.propTypes={initialValue:E().shape({id:E().number,name:E().string}),onChangeCallback:E().func,placeholder:E().string},aa.defaultProps={initialValue:{id:0,name:""},onChangeCallback:o.noop,placeholder:(0,i.__)("Select a user","wordpress-seo")},sa.propTypes={dispatch:E().func.isRequired,imageUrl:E().string,fallbackImageUrl:E().string,person:E().shape({id:E().number,name:E().string}),canEditUser:E().bool.isRequired},sa.defaultProps={imageUrl:"",fallbackImageUrl:"",person:{id:0,name:""}},oa.propTypes={onOrganizationOrPersonChange:E().func.isRequired,dispatch:E().func.isRequired,state:E().object.isRequired,siteRepresentationEmpty:E().bool.isRequired};const ia=window.wp.url,la=(0,i.__)("Oops! Something went wrong. Check your email address and try again.","wordpress-seo"),ca=(0,i.__)("Please enter a valid email address.","wordpress-seo"),ua=(0,i.__)("Thank you! Check your inbox for the confirmation email.","wordpress-seo");function da({gdprLink:t}){const[n,r]=(0,a.useState)(""),[s,o]=(0,a.useState)("waiting"),[l,c]=(0,a.useState)(""),u=(0,a.useCallback)((async function(){if(!(0,ia.isEmail)(n))return o("error"),void c(ca);o("loading"),(await async function(e){return(await fetch("https://my.yoast.com/api/Mailing-list/subscribe",{method:"POST",mode:"cors",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"},redirect:"follow",referrerPolicy:"no-referrer",body:JSON.stringify({customerDetails:{firstName:"",email:e},list:"Yoast newsletter",source:"free"})})).json()}(n)).error?(o("error"),c(la)):(o("success"),c(ua))}),[n]),d=(0,a.useCallback)((e=>{o("waiting"),r(e.target.value)}),[r]);return(0,e.createElement)(a.Fragment,null,(0,e.createElement)("h4",{className:"yst-text-slate-900 yst-text-base yst-leading-6 yst-font-normal"},(0,i.__)("Get free weekly SEO tips!","wordpress-seo")),(0,e.createElement)("p",{className:"yst-my-2"},(0,i.sprintf)(/* translators: %1$s expands to "Yoast SEO", %2$s expands to "Yoast SEO". */ (0,i.__)("Subscribe to the %1$s newsletter to receive best practices for improving your rankings, save time on SEO tasks, stay up-to-date with the latest SEO news, and get expert guidance on how to make the most of %2$s!","wordpress-seo"),"Yoast SEO","Yoast SEO")),(0,e.createElement)("div",{className:"yst-flex yst-items-start yst-gap-2 yst-mt-4"},(0,e.createElement)(P,{label:(0,i.__)("Email address","wordpress-seo"),id:"newsletter-email",name:"newsletter email",value:n,onChange:d,className:"yst-grow",type:"email",placeholder:(0,i.__)("E.g. example@email.com","wordpress-seo"),feedback:{isVisible:["error","success"].includes(s),type:s,message:[l]}}),(0,e.createElement)("button",{type:"button",id:"newsletter-sign-up-button",className:"yst-button yst-button--primary yst-h-[45px] yst-items-center yst-mt-[27.5px] yst-shrink-0",onClick:u,disabled:"loading"===s,"data-hiive-event-name":"clicked_signup | personal preferences"},(0,i.__)("Yes, give me your free tips!","wordpress-seo"))),(0,e.createElement)("p",{className:"yst-text-slate-600 yst-text-xxs yst-leading-4"},Pn((0,i.sprintf)( // translators: %1$s and %2$s are replaced by opening and closing anchor tags. (0,i.__)("Yoast respects your privacy. Read %1$sour privacy policy%2$s on how we handle your personal information.","wordpress-seo"),"<a>","</a>"),t,"yoast-configuration-gdpr-link")))}da.propTypes={gdprLink:E().string},da.defaultProps={gdprLink:""};const pa={variant:{default:"","inline-block":"yst-radio-group--inline-block"}},ma=({id:t,name:n,value:r,label:a,className:s,...o})=>(0,e.createElement)("div",{className:m()("yst-radio",s)},(0,e.createElement)("input",{type:"radio",id:t,name:n,value:r,className:"yst-radio__input",...o}),a&&(0,e.createElement)(fa,{htmlFor:t,className:"yst-radio__label"},a));ma.propTypes={name:E().string.isRequired,id:E().string.isRequired,value:E().oneOfType([E().string,E().number]).isRequired,label:E().string.isRequired,variant:E().oneOf(Object.keys({default:"","inline-block":"yst-radio--inline-block"})),className:E().string},ma.defaultProps={variant:"default",className:""};const fa=({children:t,as:n,className:r,...a})=>(0,e.createElement)(n,{className:m()("yst-label",r),...a},t);fa.propTypes={children:E().node.isRequired,as:E().elementType,className:E().string},fa.defaultProps={as:"label",className:""};const ya=({children:t,id:n,name:r,value:s,label:o,options:i,onChange:l,variant:c,className:u,...d})=>{const p=(0,a.useCallback)((({target:e})=>e.checked&&l(e.value)),[l]);return(0,e.createElement)("fieldset",{className:m()("yst-radio-group",pa.variant[c],u)},o&&(0,e.createElement)(fa,{as:"legend",className:"yst-radio-group__label"},o),t&&(0,e.createElement)("div",{className:"yst-radio-group__description"},t),(0,e.createElement)("div",{className:"yst-radio-group__options"},i.map(((t,a)=>{const o=`${n}-${a}`;return(0,e.createElement)(ma,{key:o,id:o,name:r,value:t.value,label:t.label,variant:c,checked:s===t.value,onChange:p,...d})}))))};ya.propTypes={children:E().node,id:E().string.isRequired,name:E().string.isRequired,value:E().oneOfType([E().string,E().number]).isRequired,options:E().arrayOf(E().shape({value:E().oneOfType([E().string,E().number]).isRequired,label:E().string.isRequired})).isRequired,onChange:E().func.isRequired,label:E().node,variant:E().oneOf(Object.keys(pa.variant)),className:E().string},ya.defaultProps={children:null,label:null,variant:"default",className:""};const ha=ya,ba=(0,mn.makeOutboundLink)();function ga({state:t,setTracking:n}){return(0,e.createElement)(a.Fragment,null,!t.isPremium&&(0,e.createElement)(a.Fragment,null,(0,e.createElement)(da,{gdprLink:window.wpseoFirstTimeConfigurationData.shortlinks.gdpr}),(0,e.createElement)("br",null)),(0,e.createElement)("h4",{className:"yst-text-slate-900 yst-text-base yst-leading-6 yst-font-normal"},(0,i.__)("Are you open to help us improve our services?","wordpress-seo")),!!t.isMainSite&&!t.isTrackingAllowedMultisite&&(0,e.createElement)(z,{type:"warning",className:"yst-mt-2"},(0,i.__)("This feature has been disabled by the network admin.","wordpress-seo")),!t.isMainSite&&(0,e.createElement)(z,{type:"warning",className:"yst-mt-2"},(0,i.__)("This feature has been disabled since subsites never send tracking data.","wordpress-seo")),(0,e.createElement)("p",{className:m()("yst-text-normal yst-mt-2 yst-mb-4",t.isMainSite&&t.isTrackingAllowedMultisite?"":"yst-opacity-50")},(0,i.sprintf)(/* translators: 1: Yoast SEO. */ (0,i.__)("Can we collect anonymous information about your website to enhance %1$s?","wordpress-seo"),"Yoast SEO")),(0,e.createElement)(ha,{id:"yoast-configuration-tracking-radio-button",name:"yoast-configuration-tracking",value:t.tracking,onChange:n,className:t.isMainSite&&t.isTrackingAllowedMultisite?"":"yst-opacity-50",disabled:!t.isMainSite||!t.isTrackingAllowedMultisite,options:[{value:0,label:(0,i.__)("No, I don't want to share my site data","wordpress-seo")},{value:1,label:(0,i.__)("Yes, you can collect my site data","wordpress-seo")}]}),!!t.isMainSite&&!!t.isTrackingAllowedMultisite&&(0,e.createElement)(a.Fragment,null,(0,e.createElement)(ba,{className:"yst-inline-block yst-mt-4",href:"https://yoa.st/config-workout-tracking"},(0,i.__)("What data will be collected and why?","wordpress-seo")),(0,e.createElement)("p",{className:"yst-my-2"},(0,e.createElement)("i",null,(0,i.__)("Important: We won't sell this data, and we won't collect any personal information about you or your visitors.","wordpress-seo")))))}ga.propTypes={state:E().object.isRequired,setTracking:E().func.isRequired};const va=e.forwardRef((function(t,n){return e.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:2,stroke:"currentColor","aria-hidden":"true",ref:n},t),e.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M17 8l4 4m0 0l-4 4m4-4H3"}))}));var Ea,wa,xa,Sa,_a,Oa,Ra,Ca,ka,Ta,Pa,Na,Ia,Ma,La,Fa,Aa,Da,za,qa,ja,Ua,$a,Ha,Va,Ba,Za,Ga,Wa,Ya,Qa,Ka,Ja,Xa,es,ts,ns,rs,as,ss,os,is,ls,cs,us,ds,ps,ms,fs,ys,hs;function bs(){return bs=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},bs.apply(this,arguments)}const gs=t=>e.createElement("svg",bs({xmlns:"http://www.w3.org/2000/svg","aria-hidden":"true",className:"indexables_2_left_bubble_optm_svg__yst-shrink-0 indexables_2_left_bubble_optm_svg__yst-h-28",viewBox:"0 0 289.98 291.69"},t),Ea||(Ea=e.createElement("path",{fill:"#006531",d:"M178.09 168c6.2.88 11.73 57.74 10.9 64-1 7.61-20.47 21.56-35.83 16.83s-22.28-17.36-17.85-26.51 36.58-55.25 42.78-54.32z"})),wa||(wa=e.createElement("path",{fill:"#f0ecf0",d:"M256.47 217s6 6 13.08 13.82a131.19 131.19 0 1 0-181.07 40.45q3.55 2.25 7.23 4.27c.71-2.79 1.36-5 1.81-6.64 1.48-5.32 6.32-14.53 5.36-19.55s-4.13-7.68-3.54-20.08a114.5 114.5 0 0 1 3.54-25.72 14.88 14.88 0 0 0-7.09-1.77 113.17 113.17 0 0 1 10.95-12c6.87-21.57 17-42 23.64-51.22 6.22-8.64 29.37-10.27 52.71-6.72s47.75 28.12 40.37 63-28.46 44.21-30.79 49.23-5.57 18.8-3.65 23.67c1.29 3.28 6.19 9.05 11.85 17.05a130.91 130.91 0 0 0 48-28.94c-8.87-9.55-19.31-20.38-19.87-21.12 9.73-11.73 15.92-18.83 27.47-17.73z"})),xa||(xa=e.createElement("path",{fill:"#006531",d:"M150.14 131.06c-3.25-1.48-3.86-.12-7.4.48s-18.86-1.18-23.91.81c-9.9 3.91-14 11.82-16 20.27s.54 19.16 1.72 25.95-3.39 53.18-3.09 59.38 20.2 11.57 22.27.35 15.33-65.3 15.33-65.3 14.33-40.46 11.08-41.94z"})),Sa||(Sa=e.createElement("path",{fill:"#b498c6",d:"M49 177.58c26.5 32.94 70.46 51.81 71.35 58.6s-3.84 13.34-8.87 16.29-30.71-3.4-45.77-22.47c-15.55-19.67-28.56-37.13-28.56-37.13s5.68-8.18 11.85-15.29z"})),_a||(_a=e.createElement("path",{fill:"#006531",d:"M132.36 152.53c-4.21 2.95-21 27.42-26.52 32-4.18 3.48-14.36 15.36-15.25 23.63s6.39 19.91 16 25.4c5.24 3 23.88-5.3 25.65-13.27s4.32-70.72.12-67.76z"})),Oa||(Oa=e.createElement("path",{fill:"#006531",d:"M192.67 244.07c2.37-5 23.4-14.36 30.79-49.21s-17-59.44-40.37-63-46.49-1.86-52.71 6.74c-6.63 9.2-16.77 29.65-23.64 51.22 15.28-14.48 30.08-20.49 39.86-32.18-.3 1.55 8.49 23.45 11.81 28.36 4.15 6.13 14.16 17.89 20.38 31-10.34-1.92-21.49-1.6-31.9 2.41-2.66 6.3-2.07 16.93-.88 22.84-2.28 17.87-2.12 33.54.46 48.85 4.06.37 8.17.58 12.32.58a131.19 131.19 0 0 0 42.08-6.9c-5.66-8-10.56-13.77-11.85-17-1.92-4.91 1.29-18.69 3.65-23.71zM112.56 231c-.27-7.26-.22-8.8.78-20.95-2.89-1.6-6.55-4.57-10.46-6.48a114.5 114.5 0 0 0-3.54 25.72c-.59 12.4 2.59 15.06 3.54 20.08S99 263.58 97.52 268.9c-.45 1.6-1.1 3.85-1.81 6.64a127.06 127.06 0 0 0 13.85 6.58c-1.44-18.61-1.04-36.3 3-51.12z"})),Ra||(Ra=e.createElement("path",{fill:"#b498c6",d:"M269.55 230.83C262.43 223 256.47 217 256.47 217c-11.55-1.11-17.74 6-27.47 17.72.56.74 11 11.57 19.88 21.12a132.58 132.58 0 0 0 20.67-25.01z"})),Ca||(Ca=e.createElement("path",{fill:"#89bc3b",d:"M95.79 201.78a14.88 14.88 0 0 1 7.09 1.77c1.1-4.56 2.4-9.17 3.86-13.73a113.74 113.74 0 0 0-10.95 11.96z"})),ka||(ka=e.createElement("path",{fill:"#89bc3b",d:"M112.56 231c-4 14.84-4.44 32.53-3 51.14a130.52 130.52 0 0 0 36.91 9c-2.58-15.31-2.74-31-.46-48.85-1.19-5.91-1.78-16.54.88-22.84 10.41-4 21.56-4.33 31.9-2.41-6.22-13.12-16.23-24.88-20.38-31-3.32-4.91-12.11-26.81-11.81-28.36-9.78 11.69-24.58 17.7-39.86 32.18-1.46 4.56-2.76 9.17-3.86 13.73 3.91 1.91 7.57 4.88 10.46 6.48-1 12.11-1.05 13.65-.78 20.93z"})),Ta||(Ta=e.createElement("path",{fill:"#b498c6",d:"M35.85 151.6s2.66 3.18 4.43 5.55 4.66 16 8.68 20.43-7 12.22-7 12.22c-12-.92-23-13.34-21-28.7 0 0 3.25-4.73 3.84-6.5s-.18-5-.18-5a34.85 34.85 0 0 1-4.29-6.21c-1.21-2.65-.84-6.46.37-9.18s4.56-2.56 4.68-1.89c.31 1.74 2 8.86 1.86 8.6-.87-2.01 2.67 2.19 8.61 10.68z"})),Pa||(Pa=e.createElement("path",{fill:"#b498c6",d:"M32.13 155.37c-12 4.78-18.36 1.3-24.56 4.84s1.22 17.61 1.22 17.61 1.84 6.8 5.39 11.23 24.27 4.41 24.27 4.41l10.15-13.52z"})),Na||(Na=e.createElement("path",{fill:"#b498c6",d:"M28.47 184.32c-.59.89-5.5 6.45-8.45 7.45s-6.34-.66-6.34-.66c-3.64-1.42-4.81-3.6-3.07-6.2 0 0 10.29-.52 7.34.18s7.57-4.31 7.57-4.31c1.96.66 3.09 1.77 2.95 3.54z"})),Ia||(Ia=e.createElement("path",{fill:"#8b6c9c",d:"M25.52 180.78c7.47.85-3.24 16.33-11.84 10.33 5.39 1.3 7.32.21 10.71-3.07 2.5-2.49 3.06-2.79 2.42-5.24a2.59 2.59 0 0 0-1.29-2.02z"})),Ma||(Ma=e.createElement("path",{fill:"#b498c6",d:"M5.48 176.94c-2.11 2.55-1.17 5.19 4.13 8l8.39 1.15 8.57-5.31a8.67 8.67 0 0 0-.89-6.8l-10.34 3.25z"})),La||(La=e.createElement("path",{fill:"#8b6c9c",d:"M9.61 184.91c7.51.44 7.78 1.78 12.14-.95 5-3.14 5.69-4.17 3.88-10 4.06 5.07 1.3 7.9-3.35 10.83-3.09 1.94-6.79 2.92-12.67.12z"})),Fa||(Fa=e.createElement("path",{fill:"#b498c6",d:"M1.34 168.67c-3.06 1.58-.35 9.08 2.77 9l11.18-.41s9.12-2 10.34-3.25c1.81-1.8-.57-7.7-1.48-7.38l-10.93 3z"})),Aa||(Aa=e.createElement("path",{fill:"#8b6c9c",d:"M4.11 177.64c11.75.39 10.61 4.06 19.09-3.93 1.37-1.34-.15-7.07-1.05-7.11 1.23-.32 4.11 5.64 1.75 7.82-5.45 5.13-8.43 7.58-19.79 3.22z"})),Da||(Da=e.createElement("path",{fill:"#b498c6",d:"M4.59 159.81c-2.79.54-3.52 2-3.54 5.43s-.94 2.44 1.29 3.43 13.88.88 13.88.88l7.93-3c.73-2.37.66-4.59-1.18-6.5l-9.4-.89a69.28 69.28 0 0 0-8.98.65z"})),za||(za=e.createElement("path",{fill:"#8b6c9c",d:"M2.34 168.67c1.27.26 12.13.39 13.88.38-.45.09-.73.24 7.76-2.92-.91 1 .41-.43.05-2.9-.51-3.6-2.16-2.54-5.81-3.09-4.5-.9-9.43-1.88 4.8-.54.53.05 3 2.56 1.61 7.14-.11.36.83-.09-8.31 3.31-3.68.02-10.94.14-13.98-1.38z"})),qa||(qa=e.createElement("path",{fill:"#006531",d:"M197.4 137.56c4.72.88 31.31 19.79 39.83 35.92 3.33 6.31 6 21.38 8.9 27.58s13.59 18.31 14.48 19.79c-17.13 2.66-27.18 19.2-27.18 19.2-4-3.26-43.16-44.31-44-46.38-3.25-7.97 3.24-57 7.97-56.11z"})),ja||(ja=e.createElement("path",{fill:"#006531",d:"M195.4 110.09c-1.55 13 2 27.47 2 27.47s-44.31 21.26-50.8 20.08-3-24.33-3-24.33-.88-13.29 1.48-17.13 4.75-9.93 13-11.11 38.1-1.57 37.32 5.02z"})),Ua||(Ua=e.createElement("path",{fill:"#b498c6",d:"M147.3 154.39s11.48-21.63 15-24.29 18.72-8.83 22.56-10 3.84-5.31 5-8.56 1.48-29.79 1.48-29.79l-45.29 2 4.73 39.81c.36 12.52-4.85 19.83-3.48 30.83z"})),$a||($a=e.createElement("path",{fill:"#89bc3b",d:"M195.45 138.74s27.35 19.2 39.05 36.26c2.65 3.85 4.84 20.79 7.2 25.81s10.05 15.07 10.05 15.07l5.31.29 3.55 4.73c-9.41 1.64-18.27 9.31-27.18 19.2l-6.49-5.62c5.46-7.09 11.49-13 18.9-15.94 0 0-7.68-12.11-9.75-16.54s-4.52-21.19-7.2-26.41c-9-17.6-39.06-34.73-39.06-34.73z"})),Ha||(Ha=e.createElement("path",{fill:"#093f22",d:"m192.38 197.7 21.02 21.79-2.66 5.31-15.36 5.61 11.88-10.33-14.88-22.38zm-71.73-50.53 1.55 13.29a79.66 79.66 0 0 1-7.31 11.54c-4.43 5.76-8.76 11.31-8.76 11.31L114 156l-.44 12z"})),Va||(Va=e.createElement("path",{fill:"#8b6c9c",d:"M191.38 81.73s1.91 5.52-1.07 17.09c-2.07 8-25.57 30.6-35 28.17-6-1.54-6-11.85-7.27-16.31L145 83.8z"})),Ba||(Ba=e.createElement("path",{fill:"#b498c6",d:"M172.22 6.3c-20-2.46-38.74 14.76-40.58 16.91-1.16 1.35-4.27 8.05-6.64 14.45 13.42-5 36.89-.82 67.51 9.88 1 6.7.06 12.11-.92 19.63 0 0-8.61 4.69-16 4.69s-16.29-2.46-18.45-5.23-8-9.63-13.77-10-11.37 5.87-13.89 6.59c-1.75.5-8 3-10.15 5.15v-.08a15.41 15.41 0 0 0-1.18 6.5c.8 8.65 6.53 18.51 8.69 21.59s2.72 9.45 6.41 14.07c3.13 3.91 15.33 3.46 20 2.1 7-2 29.38-9.37 32.77-14S198.23 70 198.23 70s12.4-8.23 13-14.69c2.12-22.13-11.91-45.67-39.01-49.01z"})),Za||(Za=e.createElement("path",{fill:"#006531",d:"M192.2 87.46c21.23 1.16 34.39 0 35.92-9.22s1.16-64.85-52.19-76.38c-50.56-10.93-60.49 29.65-61.72 37s7.59 8.91 7.59 8.91c-.61-3.09 1.55-2.73 3.19-10.14 15.18-3.18 61.91 7.92 64.68 12.84s-.54 12.68-.24 16.06 7.69 6.47 7.69 6.47z"})),Ga||(Ga=e.createElement("path",{fill:"#093f22",d:"M225.1 81.93c1.13-4.56-4.46-9.51-15.07-14.76l-5.22 5.23-4.92 15.37c12.11.23 23.63.05 25.21-5.84z"})),Wa||(Wa=e.createElement("path",{fill:"#b498c6",d:"M207 73.61c3.69 3.07 3.93 10.55 1.78 14.54s-14.78 8.49-17.21 7.57-4.92-3.88-4.92-3.88l10.45-18.62a12.33 12.33 0 0 1 4.49.11c.31 0 2.8-1 3.11-.91a6.32 6.32 0 0 1 2.3 1.19z"})),Ya||(Ya=e.createElement("path",{fill:"#191a1a",d:"M192.2 69s-19.69 37.82-22.44 39c.82.16 5.58-1.59 7.38-2.46s20-32.59 20-32.59z"})),Qa||(Qa=e.createElement("path",{fill:"#093f22",d:"m186.03 79.26 5.37 4.21-4.21 7.53-5.93-3.32 4.77-8.42z"})),Ka||(Ka=e.createElement("path",{fill:"#fcee21",d:"M122.11 47.5a54.43 54.43 0 0 1 2.89-9.84c-4.93 9.91-10.22 24.17-5.7 30.66a35.07 35.07 0 0 1 5.58-8.22s-3.7-6.1-2.77-12.6z"})),Ja||(Ja=e.createElement("path",{fill:"#fbb03b",d:"M129.49 65.25c2.72-.78 8.83-7.61 14.37-6.38s11.14 8 13.29 10.76 11.07 5.23 18.45 5.23 16-7.69 16-7.69c1-7.52 1.93-12.93.92-19.63-30.62-10.7-54.09-14.89-67.52-9.88a54.43 54.43 0 0 0-2.89 9.84c-.93 6.45 2.76 12.6 2.76 12.6a35.07 35.07 0 0 0-5.58 8.22v.08c2.2-2.15 6.93-2.21 10.2-3.15z"})),Xa||(Xa=e.createElement("path",{fill:"#4b3f51",d:"M164.1 84.58s-10-6.68-19.87-7.87c-1.84-.22-2.48.64-3.69.59-1.78-.07-2.9-.67-4.28-.74-4.79-.22-5.77 2.37-5.77 2.37a4.35 4.35 0 0 0 1.93 4.43c1.77 1 2.51-1.11 3.32 1.77 17.72-1.66 22.26-.59 28.36-.55z"})),es||(es=e.createElement("path",{fill:"#8b6c9c",d:"M135.67 85c0 2.77-5.87 11.68 5.81 12.3 12.65.7 19.82-9.23 22.52-12.67-9.76-.11-19.34-2.38-28.33.37z"})),ts||(ts=e.createElement("path",{fill:"#f2f2f2",d:"M136.67 81.48c-.95 1.52-.25 7.58 4.61 8.3 7.75 1 16.17-1.77 22-5.22-9.55-1.06-11.88-2.62-16.38-3.49-2.54-.48-9.09-1.42-10.23.41z"})),ns||(ns=e.createElement("path",{fill:"#fcee21",d:"M124.87 60.1a20.07 20.07 0 0 0 12-.61s-2.15-7.92-6.76-7.61-5.24 8.22-5.24 8.22z"})),rs||(rs=e.createElement("path",{fill:"#f15a24",d:"M136.81 59.5c-3.13-10.48-10.72-10.06-11.88.6-1.93-.14-1.38-9.34 4.35-9.94 6.86-.67 8.23 9.15 7.53 9.34zm1.59-18.77c1.26.46.58 3.28-.69 3.38s-7.64-.52-9.45.31-5.08 4.17-6.25 6.08c.21-1.54 3.68-7.57 5-8.85s10.14-1.38 11.39-.92z"})),as||(as=e.createElement("path",{fill:"#8b6c9c",stroke:"#8b6c9c",strokeMiterlimit:10,d:"M150.7 66.25c.48 1.6 1 3.41-.85 4.33s-4-2.41-5.53-2.1-4 2.24-5.61 1.77c-3.34-1-3.69-2.69-3.69-2.69s-1.12 4.2 4.3 4.84c3.68.43 5.35-2.06 8.42-1.45s2.09 2.8 3.57 2.06c2.97-1.47.98-6.44-.61-6.76z"})),ss||(ss=e.createElement("path",{fill:"#8b6c9c",d:"M154.79 69.68c2.27 1.94 3.94 10 11.63 10.35 1.28 2-.13 5.41-1.89 9.58a20.53 20.53 0 0 0 7.07-12.91c-11.05.3-13.26-5.8-16.81-7.02zm-18.22.44s-2.47-.4-2.47.87a.37.37 0 0 1-.16.3.38.38 0 0 1-.34.06c-2.4-.79-1.79-4.72-.07-5.86-1.72 4.02 3.04 4.63 3.04 4.63z"})),os||(os=e.createElement("path",{fill:"#8b6c9c",d:"M132.48 68.63c-2 2.71-2.16 7-2 10.24 0 0-1-1.86-2-1.79s-.71 5.3.79 9a31 31 0 0 1-6-15.73c2.67 1.07 6 .5 9.27-3.38z"})),is||(is=e.createElement("ellipse",{cx:139.18,cy:184.17,fill:"#fbb03b",stroke:"#fc3",strokeMiterlimit:10,rx:8.75,ry:5.25,transform:"rotate(-9.22 139.183 184.166)"})),ls||(ls=e.createElement("path",{fill:"#f19018",d:"m129.81 195.84 18.24-2.09a100.85 100.85 0 0 0-14.23 16.57l8-.9a78.29 78.29 0 0 0-8.82 18.82c-3.2 9.33-2.81 18.19-3 17.84a47.74 47.74 0 0 1-3.75-14.91 56 56 0 0 1 .51-15.19c-3 .83-6 1.67-8.89 2.51a73.05 73.05 0 0 1 11.94-22.65z"})),cs||(cs=e.createElement("path",{fill:"#fbb03b",stroke:"#fc3",strokeMiterlimit:10,d:"m129.81 195.84 18.24-2.09a100.85 100.85 0 0 0-14.23 16.57l8-.9a78.29 78.29 0 0 0-8.82 18.82c-3.2 9.33-2.81 18.19-3 17.84a47.74 47.74 0 0 1-3.75-14.91 56 56 0 0 1 .51-15.19c-3 .83-6 1.67-8.89 2.51a73.05 73.05 0 0 1 11.94-22.65z"})),us||(us=e.createElement("path",{fill:"#f15a24",d:"M136 56.78c1 1.52-.76 3.87-2.65 3.87s-3.66-1.26-3.66-3.1a3.38 3.38 0 0 1 3.43-3.32c1.88 0 1.51.55 2.88 2.55z"})),ds||(ds=e.createElement("path",{fill:"#8b6c9c",d:"M25 161.28c-.08 6.93 1.26 20.08 15.09 24.42 0 0-8.67 1.28-11.66-1.38s-6.92-16.88-3.43-23.04z"})),ps||(ps=e.createElement("path",{fill:"#093f22",d:"m120.68 47.53 4.32-9.87c19.53-1.66 62.46 8.77 64.68 12.84s.07 13.6-.24 16.06 7.68 6.44 7.68 6.44l4.61.31s-8.3-3.07-8-7.38 3.2-16.07-1.23-18.4c-27.06-14.19-61.36-15-69.48-13.76-6.46 1-8.44 6.4-7.22 10.09.85 2.58 4.88 3.67 4.88 3.67zm47.77-26.05c-.92-2.15 18.91-8.27 30.13-7.68 6.17.32 13.26 10.33 5.91 9.45-14.77-1.77-35.11.38-36.04-1.77zM172 32.7c-.59-3 28.35-3 39.26.35 6 1.8 2.55 12.33-1.84 10.45C198 38.61 172.38 34.61 172 32.7zm-38.21-14.1L131 9.07l-6.15 6.15s8.02 4.61 8.94 3.38zm-7.07 8.61C127 26 120.57 21.06 120 22s-2.77 8.3-2.77 8.3 9.18-1.86 9.49-3.09z"})),ms||(ms=e.createElement("path",{fill:"#fc3",d:"M181.6 46.59c-.06 10.33-1.83 19.86-6 28.27A30.57 30.57 0 0 1 163.36 73c3.15-11.43 5.89-22.37 5.61-29.76a90 90 0 0 1 12.63 3.35z"})),fs||(fs=e.createElement("path",{fill:"#fcee21",d:"M172.83 62.87c-5.55.17-12.05 1.5-16.91-1.54 0 0 .7-8.22 7.15-7s9.76 8.54 9.76 8.54z"})),ys||(ys=e.createElement("path",{fill:"#f15a24",d:"M155 42.88c-1.24.38-.16 2.92.92 3.39s8.91 1.14 11.65 1.79 6.2 4.36 8.64 6.81c-.22-1.86-4.87-8.63-7.68-9.53s-12.29-2.83-13.53-2.46zm13.31 16.56a3.78 3.78 0 1 1-3.44-4.09 5 5 0 0 1 .56.09 4.28 4.28 0 0 1 2.88 4z"})),hs||(hs=e.createElement("path",{fill:"#f15a24",d:"M155.82 61.32c-2.89-12.19 15.29-11.67 17.1 1.51-.51.23-2.75-6.29-8.94-8.06-7.49-2.22-7.59 6.6-8.16 6.55z"})));function vs(e){e.preventDefault(),window.location.href="admin.php?page=wpseo_dashboard"}function Es(){const t=(0,o.get)(window,"wpseoScriptData.webinarIntroFirstTimeConfigUrl","https://yoa.st/webinar-intro-first-time-config");return(0,e.createElement)("div",{className:"yst-flex yst-flex-row yst-justify-between yst-items-center yst--mt-4"},(0,e.createElement)("div",{className:"yst-mr-6"},(0,e.createElement)("p",{className:"yst-text-sm yst-mb-4"},(0,i.sprintf)(/* translators: 1: Yoast. */ (0,i.__)("Great work! Thanks to the details you've provided, %1$s has enhanced your site for search engines, giving them a clearer picture of what your site is all about.","wordpress-seo"),"Yoast")),(0,e.createElement)("p",{className:"yst-text-sm yst-mb-6"},(0,i.__)("If your goal is to increase your rankings, you need to work on your SEO regularly. That can be overwhelming, so let's tackle it one step at a time!","wordpress-seo")),(0,e.createElement)(s.Button,{as:"a",variant:"primary",id:"button-webinar-seo-dashboard",href:t,target:"_blank","data-hiive-event-name":"clicked_to_onboarding_page"},(0,i.sprintf)(/* translators: 1: Yoast SEO. */ (0,i.__)("Learn how to increase your rankings with %1$s","wordpress-seo"),"Yoast SEO"),(0,e.createElement)(va,{className:"yst-w-4 yst-h-4 yst-icon-rtl yst-ml-2"})),(0,e.createElement)("p",{className:"yst-mt-4"},(0,e.createElement)(s.Link,{id:"link-webinar-register",href:"#",onClick:vs,"data-hiive-event-name":"clicked_seo_dashboard"},(0,i.__)("Or go to your SEO dashboard","wordpress-seo")))),(0,e.createElement)(gs,{className:"yst-shrink-0 yst-h-28 yst-mb-24"}))}function ws(e,t){const{companyName:n,companyLogo:r,companyOrPersonOptions:a,shouldForceCompany:s,fallbackCompanyName:o,websiteName:i,fallbackWebsiteName:l}=e;let{companyOrPerson:c}=e;return("company"!==c||n||r||t(ye.siteRepresentation))&&!s||(c="company"),{...e,personId:Number(e.personId),personLogoId:Number(e.personLogoId),companyLogoId:Number(e.companyLogoId),tracking:Number(e.tracking),companyOrPerson:c,companyOrPersonOptions:a,errorFields:[],stepErrors:{},editedSteps:[],companyName:n||o,websiteName:i||l}}function xs(){const{removeAlert:t}=(0,u.useDispatch)(d),[n,r]=(0,a.useState)(window.wpseoFirstTimeConfigurationData.finishedSteps),s=(0,a.useCallback)((e=>n.includes(e)),[n]),l=(0,a.useCallback)((e=>{r((t=>(0,o.uniq)([...t,e])))}),[r]);(0,a.useEffect)((()=>{!async function(e){const t=await c()({path:"yoast/v1/configuration/save_configuration_state",method:"POST",data:{finishedSteps:e}});await t.json}(n),window.wpseoFirstTimeConfigurationData.finishedSteps=n}),[n]);const[p,m]=(0,a.useReducer)(g,{...ws(window.wpseoFirstTimeConfigurationData,s)}),[f,y]=(0,a.useState)((()=>"0"===window.yoastIndexingData.amount?"already_done":"idle")),[h,b]=(0,a.useState)(!1),[v,E]=(0,a.useState)(!1),w=(0,a.useCallback)(((e,t)=>{m({type:"SET_STEP_ERROR",payload:{step:e,message:t}})}),[]),x=(0,a.useCallback)((e=>{m({type:"REMOVE_STEP_ERROR",payload:e})}),[]);(0,a.useEffect)((()=>{"completed"===f&&(t("wpseo-reindex"),window.yoastIndexingData.amount="0")}),[f,t]);const S=s(ye.siteRepresentation),_=s(ye.socialProfiles),O=s(ye.personalPreferences),R=(0,a.useCallback)((e=>{m({type:"SET_TRACKING",payload:parseInt(e,10)})})),C=(0,a.useCallback)((e=>{m({type:"SET_ERROR_FIELDS",payload:e})})),k=!("company"!==p.companyOrPerson||p.companyName&&(p.companyLogo||p.companyLogoFallback)&&p.websiteName),T=!("person"!==p.companyOrPerson||p.personId&&(p.personLogo||p.personLogoFallback)&&p.websiteName),P=(0,a.useCallback)((e=>m({type:"SET_COMPANY_OR_PERSON",payload:e})),[m]),N=[S,_,O].every(Boolean),[I,M]=(0,a.useState)(s(ye.siteRepresentation)),L=[I,s(ye.siteRepresentation),s(ye.socialProfiles),s(ye.personalPreferences),N],[F,A]=(0,a.useState)(function(e){if(!Array.isArray(e)||0===e.length)return 0;const t=e.findIndex((e=>!1===e));return-1!==t?t:e.every(Boolean)?e.length-1:0}(L)),[D,z]=(0,a.useState)(N),[q,U]=(0,a.useState)(!1),[$,H]=(0,a.useState)(D&&!q);function V(){return H(!1),U(!0),!0}(0,a.useEffect)((()=>{N&&z(!0)}),[N]),(0,a.useEffect)((()=>{H(D&&!q)}),[D,q]),(0,a.useEffect)((()=>{function e(e){"Enter"===e.key&&"first-time-configuration-tab"===document.querySelector(".nav-tab.nav-tab-active").id&&"INPUT"===e.target.tagName&&e.preventDefault()}return addEventListener("keydown",e),()=>removeEventListener("keydown",e)}),[]),(0,a.useEffect)((()=>{p.editedSteps.includes(F+1)||"in_progress"===f?window.isStepBeingEdited=!0:window.isStepBeingEdited=!1}),[p.editedSteps,f,F]);const B=(0,a.useCallback)((e=>{(p.editedSteps.includes(F+1)||"in_progress"===f)&&(-1===location.href.indexOf("page=wpseo_dashboard#top#first-time-configuration")&&-1===location.href.indexOf("page=wpseo_dashboard#/first-time-configuration")||(e.preventDefault(),e.returnValue=""))}),[p.editedSteps,f,F]);return(0,a.useEffect)((()=>(window.addEventListener("beforeunload",B),()=>{window.removeEventListener("beforeunload",B)})),[B]),(0,e.createElement)(fe,{setActiveStepIndex:A,activeStepIndex:F,isStepperFinished:N},(0,e.createElement)(de,null,(0,e.createElement)(de.Header,{name:(0,i.__)("SEO data optimization","wordpress-seo"),isFinished:I},(0,e.createElement)(ge,{stepId:ye.optimizeSeoData,beforeGo:V,isVisible:$,additionalClasses:"yst-ml-auto"},(0,i.__)("Edit","wordpress-seo"))),(0,e.createElement)(de.Content,null,(0,e.createElement)(Tn,{setIndexingState:y,indexingState:f,showRunIndexationAlert:v,isStepperFinished:N}),(0,e.createElement)(be,{stepId:ye.optimizeSeoData,additionalClasses:"yst-mt-12",beforeGo:function(){return v||"idle"!==f||"1"===window.yoastIndexingData.disabled?(M(!0),U(!1),!0):(E(!0),!1)},destination:D?"last":1},(0,i.__)("Continue","wordpress-seo")))),(0,e.createElement)(de,null,(0,e.createElement)(de.Header,{name:(0,i.__)("Site representation","wordpress-seo"),isFinished:S},(0,e.createElement)(ge,{stepId:ye.siteRepresentation,beforeGo:V,isVisible:$,additionalClasses:"yst-ml-auto"},(0,i.__)("Edit","wordpress-seo"))),(0,e.createElement)(de.Content,null,(0,e.createElement)(oa,{onOrganizationOrPersonChange:P,dispatch:m,state:p,siteRepresentationEmpty:h}),(0,e.createElement)(de.Error,{id:"yoast-site-representation-step-error",message:p.stepErrors[ye.siteRepresentation]||""}),(0,e.createElement)(we,{stepId:ye.siteRepresentation,stepperFinishedOnce:D,saveFunction:function(){return!h&&k||!h&&T?(b(!0),!1):h||"emptyChoice"!==p.companyOrPerson?(b("emptyChoice"===p.companyOrPerson||k||T),async function(e){const t={company_or_person:"emptyChoice"===e.companyOrPerson?"company":e.companyOrPerson,company_name:e.companyName,company_logo:e.companyLogo,company_logo_id:e.companyLogoId?e.companyLogoId:0,website_name:e.websiteName,person_logo:e.personLogo,person_logo_id:e.personLogoId?e.personLogoId:0,company_or_person_user_id:e.personId},n=await c()({path:"yoast/v1/configuration/site_representation",method:"POST",data:t});return await n.json}(p).then((()=>(C([]),x(ye.siteRepresentation),l(ye.siteRepresentation),window.wpseoFirstTimeConfigurationData={...window.wpseoFirstTimeConfigurationData,...p},!0))).catch((e=>e.failures?(C(e.failures),!1):(e.message&&w(ye.siteRepresentation,e.message),!1)))):(b(!0),!1)},setEditState:U}))),(0,e.createElement)(de,null,(0,e.createElement)(de.Header,{name:(0,i.__)("Social profiles","wordpress-seo"),isFinished:_},(0,e.createElement)(ge,{stepId:ye.socialProfiles,beforeGo:V,isVisible:$,additionalClasses:"yst-ml-auto"},(0,i.__)("Edit","wordpress-seo"))),(0,e.createElement)(de.Content,null,(0,e.createElement)(j,{state:p,dispatch:m,setErrorFields:C}),(0,e.createElement)(de.Error,{id:"yoast-social-profiles-step-error",message:p.stepErrors[ye.socialProfiles]||""}),(0,e.createElement)(we,{stepId:ye.socialProfiles,stepperFinishedOnce:D,saveFunction:function(){return"person"===p.companyOrPerson?(l(ye.socialProfiles),!0):async function(e){const t={facebook_site:e.socialProfiles.facebookUrl,twitter_site:e.socialProfiles.twitterUsername,other_social_urls:e.socialProfiles.otherSocialUrls},n=await c()({path:"yoast/v1/configuration/social_profiles",method:"POST",data:t});return await n.json}(p).then((e=>!1===e.success?(C(e.failures),Promise.reject("There were errors saving social profiles")):e)).then((()=>{C([]),x(ye.socialProfiles),l(ye.socialProfiles)})).then((()=>(window.wpseoFirstTimeConfigurationData.socialProfiles=p.socialProfiles,!0))).catch((e=>(e.failures&&C(e.failures),e.message&&w(ye.socialProfiles,e.message),!1)))},setEditState:U}))),(0,e.createElement)(de,null,(0,e.createElement)(de.Header,{name:(0,i.__)("Personal preferences","wordpress-seo"),isFinished:O},(0,e.createElement)(ge,{stepId:ye.personalPreferences,beforeGo:V,isVisible:$,additionalClasses:"yst-ml-auto"},(0,i.__)("Edit","wordpress-seo"))),(0,e.createElement)(de.Content,null,(0,e.createElement)(ga,{state:p,setTracking:R}),(0,e.createElement)(de.Error,{id:"yoast-personal-preferences-step-error",message:p.stepErrors[ye.personalPreferences]||""}),(0,e.createElement)(we,{stepId:ye.personalPreferences,stepperFinishedOnce:D,saveFunction:function(){return async function(e){if(0!==e.tracking&&1!==e.tracking)throw"Value not set!";const t={tracking:e.tracking},n=await c()({path:"yoast/v1/configuration/enable_tracking",method:"POST",data:t});return await n.json}(p).then((()=>l(ye.personalPreferences))).then((()=>(x(ye.personalPreferences),window.wpseoFirstTimeConfigurationData.tracking=p.tracking,!0))).catch((e=>(e.message&&w(ye.personalPreferences,e.message),!1)))},setEditState:U}))),(0,e.createElement)(de,null,(0,e.createElement)(de.Header,{name:(0,i.__)("Finish configuration","wordpress-seo"),isFinished:N}),(0,e.createElement)(de.Content,null,(0,e.createElement)(Es,null))))}function Ss(){return(0,e.createElement)("div",{id:"yoast-configuration",className:"yst-max-w-[715px] yst-mt-6 yst-p-8 yst-rounded-lg yst-bg-white yst-shadow yst-text-slate-600"},(0,e.createElement)("h2",{id:"yoast-configuration-title",className:"yst-text-lg yst-text-primary-500 yst-font-medium"},(0,i.__)("Tell us about your site, so we can get it ranked!","wordpress-seo")),(0,e.createElement)("p",{className:"yst-pt-2 yst-mb-6"},(0,i.__)("Let's get your site in tip-top shape for the search engines. Simply follow these 5 steps to make Google understand what your site is about.","wordpress-seo")),(0,e.createElement)("hr",{id:"configuration-hr-top"}),(0,e.createElement)("div",{className:"yst-mt-8"},(0,e.createElement)(xs,null)))}r()((()=>{const t={isRtl:Boolean((0,o.get)(window,"wpseoScriptData.metabox.isRtl",!1))},n=document.getElementById("wpseo-first-time-configuration");n&&(0,a.render)((0,e.createElement)(s.Root,{context:t},(0,e.createElement)(Ss,null)),n)}))})()})();