!function(){var t={6942:function(t,e){var r;!function(){"use strict";var n={}.hasOwnProperty;function a(){for(var t="",e=0;e2&&void 0!==arguments[2]&&arguments[2],n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null;return e=(0,p.applyFilters)("rank_math_sanitize_data",e,t,r),null!==n&&(n=(0,p.applyFilters)("rank_math_sanitize_meta_value",n,t,r)),n=null===n?e:n,(0,p.doAction)("rank_math_data_changed",t,e,r),{type:"RANK_MATH_APP_DATA",key:t,value:e,metaKey:r,metaValue:n}}function C(t,e){return(0,p.doAction)("rank_math_update_app_ui",t,e),{type:"RANK_MATH_APP_UI",key:t,value:e}}function B(t){return j.setVariable("focuskw",t.split(",")[0]),rankMathEditor.refresh("keyword"),R("keywords",t,"rank_math_focus_keyword")}function x(t){return R("pillarContent",t,"rank_math_pillar_content",!0===t?"on":"off")}function U(t){return R("showScoreFrontend",t,"rank_math_dont_show_seo_score",!0===t?"off":"on")}function F(t){return R("score",t,"rank_math_seo_score")}function N(t){return R("canonicalUrl",t,"rank_math_canonical_url")}function $(t){return R("advancedRobots",t,"rank_math_advanced_robots")}function L(t){return R("robots",t,"rank_math_robots",Object.keys(t))}function K(t){return R("breadcrumbTitle",t,"rank_math_breadcrumb_title")}function z(t){return R("lockModifiedDate",t,"rank_math_lock_modified_date")}function G(){return R("dirtyMetadata",{})}function H(t){return{type:"RESET_STORE",value:t}}function V(t){return R("facebookTitle",t,"rank_math_facebook_title")}function W(t){return R("facebookDescription",t,"rank_math_facebook_description")}function q(t){return R("facebookImage",t,"rank_math_facebook_image")}function Q(t){return R("facebookImageID",t,"rank_math_facebook_image_id")}function Y(t){return R("facebookHasOverlay",t,"rank_math_facebook_enable_image_overlay",!0===t?"on":"off")}function J(t){return R("facebookImageOverlay",t,"rank_math_facebook_image_overlay")}function X(t){return rankMath.objectID=t,R("postID",t)}function Z(t){return R("permalink",t,"permalink")}function tt(t){return R("title",t,"rank_math_title")}function et(t){return R("description",t,"rank_math_description")}function rt(t){return R("featuredImage",t)}function nt(t,e){return R("primaryTerm",parseInt(t),"rank_math_primary_"+e)}function at(t,e){return R(t,e)}function it(t){return C("redirectionItem",t)}function ot(){return C("redirectionItem",{})}function ut(t){return C("hasRedirect",t)}const ct=lodash,st=function(t){return t.replace(/<\/?[a-z][^>]*?>/gi,"")};r.dn(st);const lt=function(t){return t.replace(/]*>([\S\s]*?)<\/style>/gim,"")};r.dn(lt);const pt=function(t){return t.replace(/ | /gi," ").replace(/\s{2,}/g," ").replace(/\s\./g,".").replace(/^\s+|\s+$/g,"")};r.dn(pt);const ft=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t.replace(/]*>([\S\s]*?)<\/script>/gim,e)};r.dn(ft);const mt=function(t){return t.replace(/[‘’‛`]/g,"'").replace(/[“”〝〞〟‟„]/g,'"')};r.dn(mt);const dt=function(t){return t.replace(//g,"")};r.dn(dt);const ht=function(t){return t.replace(/&\S+?;/g,"")};function gt(t){return(0,ct.isUndefined)(t)||!t?"":(0,ct.flow)([lt,ft,st,dt,ht,pt,mt])(t)}r.dn(ht);const yt=wp.autop;var bt="[^<>&/\\[\\]\0- =]+?",vt=new RegExp("\\["+bt+"( [^\\]]+?)?\\]","g"),wt=new RegExp("\\[/"+bt+"\\]","g");const kt=function(t){return t.replace(vt,"").replace(wt,"")};r.dn(kt);const St=function(t,e){var r=function(t,e){for(var r,n=/]+)?>(.*?)<\/p>/gi,a=[];null!==(r=n.exec(t));)a.push(r);return(0,ct.map)(a,function(t){return e?gt(t[1]):t[1]})}(t=(0,ct.flow)([kt,dt,yt.autop])(t),e=e||!1);return 0]*>([\S\s]*?)<\/script>/gim,"").replace(/<\/?\w(?:[^"'>]|"[^"]*"|'[^']*')*>/gim,""),_t.innerHTML=t,t=_t.textContent,_t.textContent=""),t}r.dn(Et);var Dt=function(t,e){return t=(t=gt(t)).replace(/\r?\n|\r/g," "),e?(0,ct.truncate)(t,{length:e,separator:" "}):t},Pt=function(t){if((0,ct.isEmpty)(t))return"";t=ft(t),t=lt(t),t=(0,ct.unescape)(t).replace(/\[caption[^\]]*\](.*)\[\/caption\]/g,"");var e=(0,ct.filter)(St(t,!0),function(t){return""!==t.trim()});if(!e.length)return"";var r=rankMathEditor.getPrimaryKeyword();if(""!==r){var n=(0,ct.filter)(e,function(t){return(0,ct.includes)(t.toLowerCase(),r.toLowerCase())});if(00&&void 0!==arguments[0]?arguments[0]:Ce(rankMath),e=arguments.length>1?arguments[1]:void 0,r=je({},t.dirtyMetadata);return!1!==e.metaKey&&(r[e.metaKey]=e.metaValue),"RESET_STORE"===e.type?je({},Ce(e.value)):"RANK_MATH_APP_DATA"===e.type?"dirtyMetadata"===e.key?je(je({},t),{},{dirtyMetadata:e.value}):je(je({},t),{},Re(Re({},e.key,e.value),"dirtyMetadata",r)):t}function xe(t){return xe="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},xe(t)}function Ue(t,e){var r=Object.keys(t);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(t);e&&(n=n.filter(function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable})),r.push.apply(r,n)}return r}function Fe(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:$e,e=arguments.length>1?arguments[1]:void 0;return"RANK_MATH_APP_UI"===e.type?Fe(Fe({},t),{},Ne({},e.key,e.value)):t}function Ke(t){return t.appData}function ze(t){return t.appData.dirtyMetadata}function Ge(t){return t.appData.score}function He(t){return t.appData.keywords}function Ve(t){return t.appData.pillarContent}function We(t){return t.appData.robots}function qe(t){return t.appData.advancedRobots}function Qe(t){return t.appData.canonicalUrl}function Ye(t){return t.appData.breadcrumbTitle}function Je(t){return"todo"}function Xe(t){return t.appData.showScoreFrontend}function Ze(t){return t.appData.lockModifiedDate}function tr(t){return t.appUi.isLoaded}function er(t){return t.appUi.selectedKeyword}function rr(t){return t.appUi.socialTab}function nr(t){return t.appUi.refreshResults}function ar(t){return t.appUi.isPro}function ir(t){return t.appUi.isDiviPageSettingsBarActive}function or(t){return t.appUi.isDiviRankMathModalActive}function ur(t){return t.appUi.highlightedParagraphs}function cr(t){return t.appData.facebookTitle}function sr(t){return t.appData.facebookDescription}function lr(t){return t.appData.facebookAuthor}function pr(t){return t.appData.facebookImageID}function fr(t){return t.appData.facebookImage}function mr(t){return t.appData.facebookHasOverlay}function dr(t){return""!==t.appData.facebookImageOverlay?t.appData.facebookImageOverlay:"play"}function hr(t){return t.appData.postID}function gr(t){return t.appData.title}function yr(t){return t.appData.permalink}function br(t){return t.appData.description}function vr(t){return t.appData.featuredImage}function wr(t){var e=t.appData.featuredImage;return'').concat(e.alt_text,'')}function kr(t){return t.appData.primaryTerm}function Sr(t){return String(t.appData.redirectionID)}function _r(t){return t.appData.redirectionType}function Tr(t){return t.appData.redirectionUrl}function Dr(t){return t.appUi.redirectionItem}function Pr(t){return t.appUi.hasRedirect}const Ir=wp.url;function Er(t){return Tt(t.appUi.serpTitle)}function Or(t){return(0,Ir.safeDecodeURIComponent)(t.appUi.serpSlug)}function Ar(t){return t.appUi.serpDescription}function Mr(t){return t.appUi.isSnippetEditorOpen}function jr(t){return t.appUi.snippetPreviewType}function Rr(t){return t.appUi.isSchemaEditorOpen}function Cr(t){return t.appUi.isSchemaTemplatesOpen}function Br(t){return t.appUi.schemaUpdated}function xr(t){return t.appData.schemas}function Ur(t){return t.appUi.editSchemas}function Fr(t){return{id:t.appUi.editingSchemaId,data:t.appUi.editSchemas[t.appUi.editingSchemaId]}}function Nr(t){return t.appData.schemas[t.appUi.editingSchemaId]}function $r(t){return t.appUi.editorTab}function Lr(t){return t.appUi.templateTab}function Kr(t){return t.appData.twitterUseFacebook}function zr(t){return t.appData.twitterCardType}function Gr(t){return t.appData.twitterTitle}function Hr(t){return t.appData.twitterDescription}function Vr(t){return t.appData.twitterAuthor}function Wr(t){return t.appData.twitterImageID}function qr(t){return t.appData.twitterImage}function Qr(t){return t.appData.twitterHasOverlay}function Yr(t){return""!==t.appData.twitterImageOverlay?t.appData.twitterImageOverlay:"play"}function Jr(t){return t.appData.twitterAppDescription}function Xr(t){return t.appData.twitterAppIphoneID}function Zr(t){return t.appData.twitterAppIphoneName}function tn(t){return t.appData.twitterAppIphoneUrl}function en(t){return t.appData.twitterAppIpadID}function rn(t){return t.appData.twitterAppIpadName}function nn(t){return t.appData.twitterAppIpadUrl}function an(t){return t.appData.twitterAppGoogleplayID}function on(t){return t.appData.twitterAppGoogleplayName}function un(t){return t.appData.twitterAppGoogleplayUrl}function cn(t){return t.appData.twitterAppCountry}function sn(t){return t.appData.twitterPlayerUrl}function ln(t){return t.appData.twitterPlayerSize}function pn(t){return t.appData.twitterPlayerStream}function fn(t){return t.appData.twitterPlayerStreamCtype}var mn=(0,c.registerStore)("rank-math",{reducer:(0,c.combineReducers)(e),selectors:n,actions:t});function dn(){return mn}var hn={};(0,ct.isUndefined)(rankMath.assessor)||(0,ct.forEach)(rankMath.assessor.diacritics,function(t,e){return hn[e]=new RegExp(t,"g")});const gn=function(t){if((0,ct.isUndefined)(t))return t;for(var e in hn)t=t.replace(hn[e],e);return t};r.dn(gn);var yn={"&":"&",""":'"',"'":"'"},bn=/&(?:amp|quot|#(0+)?39);/g,vn=RegExp(bn.source);const wn=function(t){return t&&vn.test(t)?t.replace(bn,function(t){return yn[t]||"'"}):t||""};function kn(t){return kn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},kn(t)}function Sn(t,e){for(var r=0;r'+(0,fe.__)("300 words","seo-by-rank-math")+"")}}},{key:"contentLengthBoundary",value:function(){return{recommended:{boundary:299,score:8},belowRecommended:{boundary:200,score:5},low:{boundary:50,score:2}}}}])&&On(t.prototype,e),r&&On(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,r}();function jn(t){return jn="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},jn(t)}function Rn(t,e){for(var r=0;r3?(a=d===n)&&(c=i[(u=i[4])?5:(u=3,3)],i[4]=i[5]=t):i[0]<=m&&((a=r<2&&mn||n>d)&&(i[4]=r,i[5]=n,f.n=d,u=0))}if(a||r>1)return o;throw p=!0,n}return function(a,l,d){if(s>1)throw TypeError("Generator is already running");for(p&&1===l&&m(l,d),u=l,c=d;(e=u<2?t:c)||!p;){i||(u?u<3?(u>1&&(f.n=-1),m(u,c)):f.n=c:f.v=c);try{if(s=2,i){if(u||(a="next"),e=i[a]){if(!(e=e.call(i,c)))throw TypeError("iterator result is not an object");if(!e.done)return e;c=e.value,u<2&&(u=0)}else 1===u&&(e=i.return)&&e.call(i),u<2&&(c=TypeError("The iterator does not provide a '"+a+"' method"),u=1);i=t}else if((e=(p=f.n<0)?c:r.call(n,f))!==o)break}catch(e){i=t,u=1,c=e}finally{s=1}}return{value:e,done:p}}}(r,a,i),!0),s}var o={};function u(){}function c(){}function s(){}e=Object.getPrototypeOf;var l=[][n]?e(e([][n]())):($n(e={},n,function(){return this}),e),p=s.prototype=u.prototype=Object.create(l);function f(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,s):(t.__proto__=s,$n(t,a,"GeneratorFunction")),t.prototype=Object.create(p),t}return c.prototype=s,$n(p,"constructor",s),$n(s,"constructor",c),c.displayName="GeneratorFunction",$n(s,a,"GeneratorFunction"),$n(p),$n(p,a,"Generator"),$n(p,n,function(){return this}),$n(p,"toString",function(){return"[object Generator]"}),(Nn=function(){return{w:i,m:f}})()}function $n(t,e,r,n){var a=Object.defineProperty;try{a({},"",{})}catch(t){a=0}$n=function(t,e,r,n){function i(e,r){$n(t,e,function(t){return this._invoke(e,r,t)})}e?a?a(t,e,{value:r,enumerable:!n,configurable:!n,writable:!n}):t[e]=r:(i("next",0),i("throw",1),i("return",2))},$n(t,e,r,n)}function Ln(t,e,r,n,a,i,o){try{var u=t[i](o),c=u.value}catch(t){return void r(t)}u.done?e(c):Promise.resolve(c).then(n,a)}function Kn(t){return function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(t){Ln(i,n,a,o,u,"next",t)}function u(t){Ln(i,n,a,o,u,"throw",t)}o(void 0)})}}function zn(t,e){for(var r=0;r");var t=this._etAppFrameElem.contentWindow.document,e=i()((0,ct.isNull)(t.querySelector("#theme-builder-area--post_content"))?t.querySelector("body"):t.querySelector("#theme-builder-area--post_content"));return e.length<1?i()("
"):e}},{key:"getExcerpt",value:function(){return this.etSettingsData.excerpt}},{key:"setExcerpt",value:function(t){this.etSettingsData.excerpt=t}},{key:"getPermalink",value:function(){return rankMath.is_front_page?rankMath.homeUrl+"/":this.getSlug()?rankMath.permalinkFormat.replace(/%(postname|pagename)%/,this.getSlug()).trimRight("/"):""}},{key:"getSlug",value:function(){return(0,Ir.safeDecodeURIComponent)((0,c.select)("rank-math").getPermalink())}},{key:"getFeaturedImage",value:function(){if(this._featuredImage)return this._featuredImage;this.setFeaturedImage()}},{key:"setFeaturedImage",value:(o=Kn(Nn().m(function t(e){return Nn().w(function(t){for(;;)switch(t.n){case 0:if(void 0!==e){t.n=2;break}return t.n=1,this.fetchFeaturedImageId();case 1:e=t.v;case 2:if(!this.isValidMediaId(e)||!e){t.n=4;break}return t.n=3,this.fetchWpMedia(e);case 3:this._featuredImage=t.v,t.n=5;break;case 4:this._featuredImage=!1;case 5:return t.a(2)}},t,this)})),function(t){return o.apply(this,arguments)})},{key:"fetchFeaturedImageId",value:(a=Kn(Nn().m(function t(){var e,r=this;return Nn().w(function(t){for(;;)switch(t.n){case 0:if(!this._featuredImageInProcess){t.n=1;break}return t.a(2,this._featuredImage);case 1:return this._featuredImageInProcess=!0,e=null,t.n=2,u()({path:"/rankmath/v1/getFeaturedImageId",method:"POST",data:{postId:(0,ct.get)(ETBuilderBackendDynamic,"postId",0)}}).then(function(t){e=!!t.success&&t.featImgId,r._featuredImageInProcess=!1});case 2:return t.a(2,e)}},t,this)})),function(){return a.apply(this,arguments)})},{key:"fetchWpMedia",value:(n=Kn(Nn().m(function t(e){var r;return Nn().w(function(t){for(;;)switch(t.n){case 0:return r={},t.n=1,u()({path:"/wp/v2/media/".concat(e),method:"GET"}).then(function(t){return r=t});case 1:return t.a(2,r)}},t)})),function(t){return n.apply(this,arguments)})},{key:"isValidMediaId",value:function(t){return"number"==typeof t&&0t.length)&&(e=t.length);for(var r=0,n=Array(e);r=t.length?{done:!0}:{done:!1,value:t[n++]}},e:function(t){throw t},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,u=!1;return{s:function(){r=r.call(t)},n:function(){var t=r.next();return o=t.done,t},e:function(t){u=!0,i=t},f:function(){try{o||null==r.return||r.return()}finally{if(u)throw i}}}}function aa(t,e){(null==e||e>t.length)&&(e=t.length);for(var r=0,n=Array(e);r
'),ra(document.getElementById("rank-math-lock-modified-date-wrapper"),wp.element.createElement(ea,{publishButton:this.publishButton})))},addEventListeners:function(){this.$document.on("click",this.onDocumentClick.bind(this)),this.rmSettingsBarMediaQuery.addListener(this.onRmSettingsBarMediaQueryChange.bind(this)),this.etSettingsBarObserver.observe(this.$etPageSettingsBar[0],{attributeFilter:["class"]})},onDocumentClick:function(t){this.hideModalOnOutsideClick(t.target)},onRmSettingsBarMediaQueryChange:function(){this.detachRmSettingsBar(),this.attachRmSettingsBar(this.getEtSettingsBarPosition())},onEtSettingsBarClassAttrChange:function(){var t=this.isEtSettingsBarActive(),e=this.getEtSettingsBarPosition();this.removePositionalClassNames(this.$body,"rank-math-et-settings-bar-is"),this.$body.addClass("rank-math-et-settings-bar-is-".concat(e)),(0,c.dispatch)("rank-math").toggleIsDiviPageSettingsBarActive(t),this.toggleBodyClasses(),this.detachRmSettingsBar(),this.isEtSettingsBarDragged()?(this.rmPrevModalActiveState=(0,c.select)("rank-math").isDiviRankMathModalActive(),this.rmPrevModalActiveState&&(this.rmModalHiddingTimer=setTimeout(function(){(0,c.dispatch)("rank-math").toggleIsDiviRankMathModalActive(!1)},200))):(clearTimeout(this.rmModalHiddingTimer),this.attachRmSettingsBar(e),(0,c.dispatch)("rank-math").toggleIsDiviRankMathModalActive(this.rmPrevModalActiveState||(0,c.select)("rank-math").isDiviRankMathModalActive()),this.rmPrevModalActiveState=!1)},attachRmSettingsBar:function(t){this.isRmSettingsBarAttached()||(this.toggleRmSettingsBarClassNames(t),this.isEtSettingsBarActive()?this.rmSettingsBarMediaQuery.matches?this.$etPageSettingsBarColumn.filter(".et-fb-page-settings-bar__column--main").append(this.$rmSettingsBarRoot):this.$etPageSettingsBarColumn.filter(".et-fb-page-settings-bar__column--left").prepend(this.$rmSettingsBarRoot):this.$etPageSettingsBarToggleButton.after(this.$rmSettingsBarRoot))},detachRmSettingsBar:function(){this.isRmSettingsBarAttached()&&(this.$rmSettingsBarRoot=this.$etPageSettingsBar.find(this.rmSettingsBarRootSelector).detach())},toggleRmSettingsBarClassNames:function(t){this.removePositionalClassNames(this.$rmSettingsBarRoot),this.$rmSettingsBarRoot.addClass("rank-math-rm-settings-bar-root-".concat(t)),this.$rmSettingsBarRoot.toggleClass(["rank-math-rm-settings-bar-root-is-mobile","rank-math-rm-settings-bar-root-is-mobile-".concat(t)].join(" "),!this.rmSettingsBarMediaQuery.matches),this.$rmSettingsBarRoot.toggleClass(["rank-math-rm-settings-bar-root-is-desktop","rank-math-rm-settings-bar-root-is-desktop-".concat(t)].join(" "),this.rmSettingsBarMediaQuery.matches)},isRmSettingsBarAttached:function(){return i().contains(document.documentElement,this.$rmSettingsBarRoot[0])},isEtSettingsBarActive:function(){return this.$etPageSettingsBar.hasClass("et-fb-page-settings-bar--active")},isEtSettingsBarDragged:function(){return this.$etPageSettingsBar.hasClass("et-fb-page-settings-bar--dragged")&&!this.isEtSettingsBarActive()},removePositionalClassNames:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",r=["".concat(e,"-left"),"".concat(e,"-right"),"".concat(e,"-top"),"".concat(e,"-top-left"),"".concat(e,"-top-right"),"".concat(e,"-bottom"),"".concat(e,"-bottom-left"),"".concat(e,"-bottom-right")].join("|"),n=new RegExp("(".concat(r,")$"),"gim");t.removeClass(function(t,e){var r,a=[],i=na(e.split(" "));try{for(i.s();!(r=i.n()).done;){var o=r.value;n.test(o)&&a.push(o)}}catch(t){i.e(t)}finally{i.f()}return a})},getEtSettingsBarPosition:function(){var t=this.$etPageSettingsBar;return t.hasClass("et-fb-page-settings-bar--horizontal")&&!t.hasClass("et-fb-page-settings-bar--top")?"bottom":t.hasClass("et-fb-page-settings-bar--top")&&!t.hasClass("et-fb-page-settings-bar--corner")?"top":t.hasClass("et-fb-page-settings-bar--bottom-corner")?t.hasClass("et-fb-page-settings-bar--left-corner")?"bottom-left":"bottom-right":t.hasClass("et-fb-page-settings-bar--top-corner")?t.hasClass("et-fb-page-settings-bar--left-corner")?"top-left":"top-right":t.hasClass("et-fb-page-settings-bar--vertical--right")?"right":t.hasClass("et-fb-page-settings-bar--vertical--left")?"left":""},hideModalOnOutsideClick:function(t){if((0,c.select)("rank-math").isDiviRankMathModalActive()){var e=".rank-math-rm-modal";i()(t).parents(e)||t.closest(".components-modal__screen-overlay.rank-math-modal-overlay")||t.closest(".rank-math-rm-modal-toggle-button")||t.contains(document.querySelector(e))||(0,c.dispatch)("rank-math").toggleIsDiviRankMathModalActive(!1)}}};const oa=(0,c.withSelect)(function(t){return{primaryTermId:t("rank-math").getPrimaryTermID()}})(function(t){var e=t.taxonomySlug,r=t.primaryTermId,n=t.options;if(n.length<2||!e)return null;return wp.element.createElement(f.SelectControl,{className:"rank-math-primary-term-select",label:(0,fe.__)("Select Primary Term","seo-by-rank-math"),value:r,options:n,onChange:function(t){(0,c.dispatch)("rank-math").updatePrimaryTermID(parseInt(t),e)},__next40pxDefaultSize:!0,__nextHasNoMarginBottom:!0})});function ua(t){return ua="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ua(t)}function ca(){var t,e,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",a=r.toStringTag||"@@toStringTag";function i(r,n,a,i){var c=n&&n.prototype instanceof u?n:u,s=Object.create(c.prototype);return sa(s,"_invoke",function(r,n,a){var i,u,c,s=0,l=a||[],p=!1,f={p:0,n:0,v:t,a:m,f:m.bind(t,4),d:function(e,r){return i=e,u=0,c=t,f.n=r,o}};function m(r,n){for(u=r,c=n,e=0;!p&&s&&!a&&e3?(a=d===n)&&(c=i[(u=i[4])?5:(u=3,3)],i[4]=i[5]=t):i[0]<=m&&((a=r<2&&mn||n>d)&&(i[4]=r,i[5]=n,f.n=d,u=0))}if(a||r>1)return o;throw p=!0,n}return function(a,l,d){if(s>1)throw TypeError("Generator is already running");for(p&&1===l&&m(l,d),u=l,c=d;(e=u<2?t:c)||!p;){i||(u?u<3?(u>1&&(f.n=-1),m(u,c)):f.n=c:f.v=c);try{if(s=2,i){if(u||(a="next"),e=i[a]){if(!(e=e.call(i,c)))throw TypeError("iterator result is not an object");if(!e.done)return e;c=e.value,u<2&&(u=0)}else 1===u&&(e=i.return)&&e.call(i),u<2&&(c=TypeError("The iterator does not provide a '"+a+"' method"),u=1);i=t}else if((e=(p=f.n<0)?c:r.call(n,f))!==o)break}catch(e){i=t,u=1,c=e}finally{s=1}}return{value:e,done:p}}}(r,a,i),!0),s}var o={};function u(){}function c(){}function s(){}e=Object.getPrototypeOf;var l=[][n]?e(e([][n]())):(sa(e={},n,function(){return this}),e),p=s.prototype=u.prototype=Object.create(l);function f(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,s):(t.__proto__=s,sa(t,a,"GeneratorFunction")),t.prototype=Object.create(p),t}return c.prototype=s,sa(p,"constructor",s),sa(s,"constructor",c),c.displayName="GeneratorFunction",sa(s,a,"GeneratorFunction"),sa(p),sa(p,a,"Generator"),sa(p,n,function(){return this}),sa(p,"toString",function(){return"[object Generator]"}),(ca=function(){return{w:i,m:f}})()}function sa(t,e,r,n){var a=Object.defineProperty;try{a({},"",{})}catch(t){a=0}sa=function(t,e,r,n){function i(e,r){sa(t,e,function(t){return this._invoke(e,r,t)})}e?a?a(t,e,{value:r,enumerable:!n,configurable:!n,writable:!n}):t[e]=r:(i("next",0),i("throw",1),i("return",2))},sa(t,e,r,n)}function la(t,e,r,n,a,i,o){try{var u=t[i](o),c=u.value}catch(t){return void r(t)}u.done?e(c):Promise.resolve(c).then(n,a)}function pa(t){return function(){var e=this,r=arguments;return new Promise(function(n,a){var i=t.apply(e,r);function o(t){la(i,n,a,o,u,"next",t)}function u(t){la(i,n,a,o,u,"throw",t)}o(void 0)})}}function fa(t,e){for(var r=0;rthis.maxAttempts)){t.n=3;break}return t.a(2);case 3:this.cacheDom()?(this.renderContainer(),this.renderComponent(),this.bindEvents()):this.initRecursionTimer=setTimeout(this.init.bind(this),this.attemptInterval);case 4:return t.a(2)}},t,this)})),function(){return a.apply(this,arguments)})},{key:"cacheTaxonomyData",value:(n=pa(ca().m(function t(){var e,r,n=this;return ca().w(function(t){for(;;)switch(t.n){case 0:return e=(0,ct.get)(rankMath,"assessor.primaryTaxonomy.name")||"",r=(0,ct.get)(ETBuilderBackendDynamic,"getTaxonomies",{}),this.primaryTaxonomyTerms=r[e]||[],t.n=1,u()({path:"/wp/v2/taxonomies"}).then(function(t){n.primaryTaxonomy=Object.keys(r).includes(e)&&t[e]?t[e]:{}});case 1:this.hasPostPrimaryTaxonomySupport=!i().isEmptyObject(this.primaryTaxonomy),this.primaryTaxonomyValue=(0,ct.get)(ETBuilderBackendDynamic,"pageSettingsValues.et_pb_post_settings_".concat(this.primaryTaxonomy.rest_base),"");case 2:return t.a(2)}},t,this)})),function(){return n.apply(this,arguments)})},{key:"cacheDom",value:function(){return this.$diviSettingsModal=i()(document).find(".et-fb-modal__page-settings"),!!this.$diviSettingsModal.length&&(this.$diviTermSettingInputs=this.$diviSettingsModal.find(".et-fb-option--".concat(this.primaryTaxonomy.rest_base)),this.$diviTermSettingArea=this.$diviTermSettingInputs.parents(".et-fb-form__group"),this.$diviTermSettingArea.length||(this.$diviTermSettingArea=this.workaroundForFalseDiviTaxonomySelector()),this.$PrimaryTermSelectContainer=i()('
'),!0)}},{key:"workaroundForFalseDiviTaxonomySelector",value:function(){var t=this.primaryTaxonomy.name.toLowerCase();return this.$diviSettingsModal.find(".et-fb-form__label-text").filter(function(e,r){return i()(r).text().toLowerCase()===t}).parents(".et-fb-form__group")}},{key:"renderContainer",value:function(){this.$diviTermSettingArea.after(this.$PrimaryTermSelectContainer)}},{key:"renderComponent",value:function(t){var e={taxonomySlug:this.primaryTaxonomy.slug,options:this.formatActiveTerms(t)};ra(this.$PrimaryTermSelectContainer[0],(0,l.createElement)(oa,e))}},{key:"bindEvents",value:function(){var t=this;(0,p.addFilter)("et.builder.store.setting.update","rank-math",function(e,r){return"et_pb_post_settings_".concat(t.primaryTaxonomy.rest_base)===r&&t.renderComponent(e),e})}},{key:"formatActiveTerms",value:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.primaryTaxonomyValue;return this.primaryTaxonomyTerms.length&&e.trim()?e.split(",").map(function(e){var r=(0,ct.find)(t.primaryTaxonomyTerms,["term_id",parseInt(e)])||{};return{label:r.name,value:r.term_id}}):[]}}],e&&fa(t.prototype,e),r&&fa(t,r),Object.defineProperty(t,"prototype",{writable:!1}),t;var t,e,r,n,a}();ma(ha,"initRecursionTimer",void 0),ma(ha,"attemptsRun",0),ma(ha,"maxAttempts",10),ma(ha,"attemptInterval",1e3);var ga=["className","children"];function ya(){return ya=Object.assign?Object.assign.bind():function(t){for(var e=1;e