267 lines
56 KiB
JavaScript
267 lines
56 KiB
JavaScript
|
!function(e){var t={};function s(o){if(t[o])return t[o].exports;var r=t[o]={i:o,l:!1,exports:{}};return e[o].call(r.exports,r,r.exports,s),r.l=!0,r.exports}s.m=e,s.c=t,s.d=function(e,t,o){s.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:o})},s.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},s.t=function(e,t){if(1&t&&(e=s(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var o=Object.create(null);if(s.r(o),Object.defineProperty(o,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)s.d(o,r,function(t){return e[t]}.bind(null,r));return o},s.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return s.d(t,"a",t),t},s.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},s.p="",s(s.s=288)}({0:function(e,t){e.exports=window.wp.element},1:function(e,t){e.exports=window.wp.i18n},107:function(e,t,s){"use strict";s.d(t,"a",(function(){return i}));var o,r,n=s(3);function a(){return(a=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var s=arguments[t];for(var o in s)Object.prototype.hasOwnProperty.call(s,o)&&(e[o]=s[o])}return e}).apply(this,arguments)}function i(e){return n.createElement("svg",a({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 425 456.27","aria-hidden":"true"},e),o||(o=n.createElement("path",{d:"M73 405.26a66.79 66.79 0 01-6.54-1.7 64.75 64.75 0 01-6.28-2.31c-1-.42-2-.89-3-1.37-1.49-.72-3-1.56-4.77-2.56-1.5-.88-2.71-1.64-3.83-2.39-.9-.61-1.8-1.26-2.68-1.92a70.154 70.154 0 01-5.08-4.19 69.21 69.21 0 01-8.4-9.17c-.92-1.2-1.68-2.25-2.35-3.24a70.747 70.747 0 01-3.44-5.64 68.29 68.29 0 01-8.29-32.55V142.13a68.26 68.26 0 018.29-32.55c1-1.92 2.21-3.82 3.44-5.64s2.55-3.58 4-5.27a69.26 69.26 0 0114.49-13.25C50.37 84.19 52.27 83 54.2 82A67.59 67.59 0 0173 75.09a68.75 68.75 0 0113.75-1.39h169.66L263 55.39H86.75A86.84 86.84 0 000 142.13v196.09A86.84 86.84 0 0086.75 425h11.32v-18.35H86.75A68.75 68.75 0 0173 405.26zM368.55 60.85l-1.41-.53-6.41 17.18 1.41.53a68.06 68.06 0 018.66 4c1.93 1 3.82 2.2 5.65 3.43A69.19 69.19 0 01391 98.67c1.4 1.68 2.72 3.46 3.95 5.27s2.39 3.72 3.44 5.64a68.29 68.29 0 018.29 32.55v264.52H233.55l-.44.76c-3.07 5.37-6.26 10.48-9.49 15.19L222 425h203V142.13a87.2 87.2 0 00-56.45-81.28z"})),r||(r=n.createElement("path",{d:"M119.8 408.28v46c28.49-1.12 50.73-10.6 69.61-29.58 19.45-19.55 36.17-50 52.61-96L363.94 1.9H305l-98.25 272.89-48.86-153h-54l71.7 184.18a75.67 75.67 0 010 55.12c-7.3 18.68-20.25 40.66-55.79 47.19z",stroke:"#000",strokeMiterlimit:10,strokeWidth:3.81})))}},11:function(e,t){e.exports=window.yoast.styledComponents},12:function(e,t){function s(){return e.exports=s=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var s=arguments[t];for(var o in s)Object.prototype.hasOwnProperty.call(s,o)&&(e[o]=s[o])}return e},e.exports.default=e.exports,e.exports.__esModule=!0,s.apply(this,arguments)}e.exports=s,e.exports.default=e.exports,e.exports.__esModule=!0},127:function(e,t,s){"use strict";var o=s(3),r="function"==typeof Symbol&&Symbol.for&&Symbol.for("react.element")||60103,n=s(93),a=s(128),i=s(129),l="function"==typeof Symbol&&Symbol.iterator;function c(e,t){return e&&"object"==typeof e&&null!=e.key?(s=e.key,o={"=":"=0",":":"=2"},"$"+(""+s).replace(/[=:]/g,(function(e){return o[e]}))):t.toString(36);var s,o}var u=/\/+/g;function p(e){return(""+e).replace(u,"$&/")}var d,b,m=h,h=function(e){if(this.instancePool.length){var t=this.instancePool.pop();return this.call(t,e),t}return new this(e)};function g(e,t,s,o){this.result=e,this.keyPrefix=t,this.func=s,this.context=o,this.count=0}function y(e,t,s){var r,a,i=e.result,l=e.keyPrefix,c=e.func,u=e.context,d=c.call(u,t,e.count++);Array.isArray(d)?f(d,i,s,n.thatReturnsArgument):null!=d&&(o.isValidElement(d)&&(r=d,a=l+(!d.key||t&&t.key===d.key?"":p(d.key)+"/")+s,d=o.cloneElement(r,{key:a},void 0!==r.props?r.props.children:void 0)),i.push(d))}function f(e,t,s,o,n){var i="";null!=s&&(i=p(s)+"/");var u=g.getPooled(t,i,o,n);
|
||
|
/* translators: %s expands to a 'Yoast SEO Premium' text linked to the yoast.com website. */
|
||
|
Object(i.__)("Great news: you can, with %s!","wordpress-seo"),"{{link}}Yoast SEO Premium{{/link}}"),s=[Object(i.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(i.__)("%1$sCreate content faster%2$s: Use AI to create titles & meta descriptions","wordpress-seo"),"<strong>","</strong>"),Object(i.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(i.__)("%1$sNo more dead links%2$s: easy redirect manager","wordpress-seo"),"<strong>","</strong>"),`<strong>${Object(i.__)("Superfast internal linking suggestions","wordpress-seo")}</strong>`,Object(i.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(i.__)("%1$sSocial media preview%2$s: Facebook & Twitter","wordpress-seo"),"<strong>","</strong>"),`<strong>${Object(i.__)("24/7 email support","wordpress-seo")}</strong>`,`<strong>${Object(i.__)("No ads!","wordpress-seo")}</strong>`],{locationContext:r}=Object(p.useRootContext)(),a=n()({mixedString:t,components:{link:Object(o.createElement)(b,{href:Object(d.addQueryArgs)(e.link,{context:r})})}}),c=Object(i.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(i.__)("Other benefits of %s for you:","wordpress-seo"),"Yoast SEO Premium");return Object(o.createElement)(l.a,{infoParagraphs:[a,c],benefits:s,upsellButtonText:Object(i.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(i.__)("Get %s","wordpress-seo"),"Yoast SEO Premium"),upsellButton:{href:Object(d.addQueryArgs)(e.buyLink,{context:r}),className:"yoast-button-upsell",rel:null,"data-ctb-id":"f6a84663-465f-4cb5-8ba5-f7a6d72224b2","data-action":"load-nfd-ctb"},upsellButtonLabel:Object(i.__)("1 year free support and updates included!","wordpress-seo")})};m.propTypes={link:u.a.string.isRequired,buyLink:u.a.string.isRequired},t.a=m},14:function(e,t){e.exports=window.yoast.analysis},15:function(e,t){e.exports=window.wp.url},154:function(e,t,s){"use strict";var o=s(0),r=s(8),n=s(2),a=s.n(n),i=s(61),l=s(74);const c=e=>{let{target:t,scoreIndicator:s}=e;return Object(o.createElement)(l.a,{target:t},Object(o.createElement)(r.SvgIcon,Object(i.getIconForScore)(s)))};c.propTypes={target:a.a.string.isRequired,scoreIndicator:a.a.string.isRequired},t.a=c},157:function(e,t,s){"use strict";var o=s(5),r=s(20),n=s(0),a=s(1),i=s(38),l=s(2),c=s.n(l),u=s(164),p=s(4),d=s(14),b=s(61);class m extends n.Component{constructor(e){super(e);const t=this.props.results;this.state={mappedResults:{}},null!==t&&(this.state={mappedResults:Object(b.default)(t,this.props.keywordKey)}),this.handleMarkButtonClick=this.handleMarkButtonClick.bind(this),this.handleEditButtonClick=this.handleEditButtonClick.bind(this),this.handleResultsChange=this.handleResultsChange.bind(this)}componentDidUpdate(e){null!==this.props.results&&this.props.results!==e.results&&this.setState({mappedResults:Object(b.default)(this.props.results,this.props.keywordKey)})}deactivateMarker(){this.props.setActiveMarker(null),this.props.setMarkerPauseStatus(!1),this.removeMarkers()}activateMarker(e,t){this.props.setActiveMarker(e),t()}handleMarkButtonClick(e,t){const s=this.props.keywordKey.length>0?`${this.props.keywordKey}:${e}`:e;s===this.props.activeMarker?this.deactivateMarker():this.activateMarker(s,t)}handleResultsChange(e,t,s){const o=this.props.keywordKey.length>0?`${this.props.keywordKey}:${e}`:e;o===this.props.activeMarker&&(s?Object(p.isUndefined)(t)||this.activateMarker(o,t):this.deactivateMarker())}focusOnKeyphraseField(e){const t=this.props.keywordKey,s=""===t?"focus-keyword-input-"+e:"yoast-keyword-input-"+t+"-"+e,o=document.getElementById(s);o.focus(),o.scrollIntoView({behavior:"auto",block:"center",inline:"center"})}focusOnGooglePreviewField(e,t){let s;s="metaDescriptionKeyword"===e||"metaDescriptionLength"===e?"description":"titleWidth"===e||"keyphraseInSEOTitle"===e?"title":"slug";const o=document.getElementById("yoast-google-preview-"+s+"-"+t);o.focus(),o.scrollIntoView({behavior:"auto",block:"center",inline:"center"})}handleEditButtonClick(e){const t=this.props.location;"functionWordsInKeyphrase"!==e&&"keyphraseLength"!==e?(["metaDescriptionKeyword","metaDescriptionLength","titleWidth","keyphraseInSEOTitle","slugKeyword"].includes(e)&&this.handleGooglePreviewFocus(t,e),Object(i.doAction)("yoast.focus.input",e)):this.focusOnKeyphraseField(t)}handleGooglePreviewFocus(e,t){if("sidebar"===e)document.getElementById("yoast-google-preview-modal-open-button").click(),setTimeout(()=>this.focusOnGooglePreviewField(t,"modal"),500);else{const s=document.getElementById("yoast-snippet-editor-metabox");s&&"false"===s.getAttribute("aria-expanded")?(s.click(),setTimeout(()=>this.focusOnGooglePreviewField(t,e),100)):this.focusOnGooglePreviewField(t,e)}}removeMarkers(){window.YoastSEO.analysis.applyMarks(new d.Paper("",{}),[])}render(){const{mappedResults:e}=this.state,{errorsResults:t,improvementsResults:s,goodResults:o,considerationsResults:r,problemsResults:i}=e,{upsellResults:l,resultCategoryLabels:c}=this.props,p={errors:Object(a.__)("Errors","wordpress-seo"),problems:Object(a.__)("Problems","wordpress-seo"),improvements:Object(a.__)("Improvements","wordpress-seo"),considerations:Object(a.__)("Considerations","wordpress-seo"),goodResults:Object(a.__)("Good results","wordpress-seo")},d=Object.assign(p,c);return Object(n.createElement)(n.Fragment,null,Object(n.createElement)(u.ContentAnalysis,{errorsResults:t,problemsResults:i,upsellResults:l,improvementsResults:s,considerationsResults:r,goodResul
|
||
|
display: flex;
|
||
|
margin-top: 8px;
|
||
|
`;class b extends o.Component{render(){return Object(o.createElement)(d,null,Object(o.createElement)(a.Toggle,{id:this.props.id,labelText:Object(r.__)("Mark as cornerstone content","wordpress-seo"),isEnabled:this.props.isEnabled,onSetToggleState:this.props.onToggle,onToggleDisabled:this.props.onToggleDisabled}))}}b.propTypes={id:c.a.string,isEnabled:c.a.bool,onToggle:c.a.func,onToggleDisabled:c.a.func},b.defaultProps={id:"cornerstone-toggle",isEnabled:!0,onToggle:()=>{},onToggleDisabled:()=>{}};var m=b,h=s(49),g=s(66);const y=Object(i.makeOutboundLink)();function f(e){let{isCornerstone:t,onChange:s,learnMoreUrl:l,location:c}=e;const u="metabox"===c?h.a:g.a;return Object(o.createElement)(u,{id:Object(i.join)(["yoast-cornerstone-collapsible",c]),title:Object(r.__)("Cornerstone content","wordpress-seo")},Object(o.createElement)(a.HelpText,null,Object(r.__)("Cornerstone content should be the most important and extensive articles on your site.","wordpress-seo")+" ",Object(o.createElement)(y,{href:l},Object(r.__)("Learn more about Cornerstone Content.","wordpress-seo"))),Object(o.createElement)(m,{id:Object(i.join)(["yoast-cornerstone",c]),isEnabled:t,onToggle:s}),Object(o.createElement)(n.Slot,{name:"YoastAfterCornerstoneToggle"}))}f.propTypes={isCornerstone:c.a.bool,onChange:c.a.func,learnMoreUrl:c.a.string.isRequired,location:c.a.string},f.defaultProps={isCornerstone:!0,onChange:()=>{},location:""};var O=s(20),w=s(5),j=s(22),k=s(25),v=s.n(k),_=s(76),x=s(40),E=s(107),R=s(99);class C extends o.Component{constructor(e){super(e),this.onModalOpen=this.onModalOpen.bind(this),this.onModalClose=this.onModalClose.bind(this),this.onLinkClick=this.onLinkClick.bind(this),this.listenToMessages=this.listenToMessages.bind(this)}onModalOpen(){this.props.keyphrase.trim()?this.props.onOpen(this.props.location):this.props.onOpenWithNoKeyphrase()}onModalClose(e){Object(R.b)(e)&&this.props.onClose()}onLinkClick(e){if(e.preventDefault(),!this.props.keyphrase.trim())return void this.props.onOpenWithNoKeyphrase();const t=e.target.href,s=["top="+(window.top.outerHeight/2+window.top.screenY-285),"left="+(window.top.outerWidth/2+window.top.screenX-170),"width=340","height=570","resizable=1","scrollbars=1","status=0"];this.popup&&!this.popup.closed||(this.popup=window.open(t,"SEMrush_login",s.join(","))),this.popup&&this.popup.focus(),window.addEventListener("message",this.listenToMessages,!1)}async listenToMessages(e){const{data:t,source:s,origin:o}=e;"https://oauth.semrush.com"===o&&this.popup===s&&("semrush:oauth:success"===t.type&&(this.popup.close(),window.removeEventListener("message",this.listenToMessages,!1),await this.performAuthenticationRequest(t)),"semrush:oauth:denied"===t.type&&(this.popup.close(),window.removeEventListener("message",this.listenToMessages,!1),this.props.onAuthentication(!1)))}async performAuthenticationRequest(e){try{const t=new URL(e.url).searchParams.get("code"),s=await v()({path:"yoast/v1/semrush/authenticate",method:"POST",data:{code:t}});200===s.status?(this.props.onAuthentication(!0),this.onModalOpen(),this.popup.close()):console.error(s.error)}catch(e){console.error(e.message)}}render(){const{keyphrase:e,location:t,whichModalOpen:s,isLoggedIn:i,shouldCloseOnClickOutside:l}=this.props;return Object(o.createElement)(o.Fragment,null,i&&Object(o.createElement)("div",{className:"yoast"},Object(o.createElement)(a.NewButton,{variant:"secondary",id:"yoast-get-related-keyphrases-"+t,onClick:this.onModalOpen},Object(r.__)("Get related keyphrases","wordpress-seo"))),e&&s===t&&Object(o.createElement)(x.a,{title:Object(r.__)("Related keyphrases","wordpress-seo"),onRequestClose:this.onModalClose,icon:Object(o.createElement)(E.a,null),additionalClassName:"yoast-related-keyphrases-modal",shouldCloseOnClickOutside:l},Object(o.createElement)(_.a,{className:"yoast-gutenberg-modal__content yoast-related-keyphrases-modal__content"},Object(o.createElement)(n.Slot,{name:"YoastRelatedKeyphrases"}))),!i&&Object(o.createElement)("div",{className:"yoast"},Object(o.createElement)(a.ButtonStyledLink,{variant:"secondary",id:"yoast-get-related
|
||
|
display: flex;
|
||
|
flex-direction: column;
|
||
|
`,F=p.a.label`
|
||
|
font-size: var(--yoast-font-size-default);
|
||
|
font-weight: var(--yoast-font-weight-bold);
|
||
|
${Object(i.getDirectionalStyle)("margin-right: 4px","margin-left: 4px")};
|
||
|
`,K=p.a.span`
|
||
|
margin-bottom: 0.5em;
|
||
|
`,q=p()(a.InputField)`
|
||
|
flex: 1 !important;
|
||
|
box-sizing: border-box;
|
||
|
max-width: 100%;
|
||
|
margin: 0; // Reset margins inherited from WordPress.
|
||
|
|
||
|
// Hide native X in Edge and IE11.
|
||
|
&::-ms-clear {
|
||
|
display: none;
|
||
|
}
|
||
|
|
||
|
&.has-error {
|
||
|
border-color: ${L} !important;
|
||
|
background-color: ${T} !important;
|
||
|
|
||
|
&:focus {
|
||
|
box-shadow: 0 0 2px ${L} !important;
|
||
|
}
|
||
|
}
|
||
|
`,z=p.a.ul`
|
||
|
color: ${$};
|
||
|
list-style-type: disc;
|
||
|
list-style-position: outside;
|
||
|
margin: 0;
|
||
|
margin-left: 1.2em;
|
||
|
`,U=p.a.li`
|
||
|
color: ${$};
|
||
|
margin: 0 0 0.5em 0;
|
||
|
`,W=Object(a.addFocusStyle)(p.a.button`
|
||
|
border: 1px solid transparent;
|
||
|
box-shadow: none;
|
||
|
background: none;
|
||
|
flex: 0 0 32px;
|
||
|
height: 32px;
|
||
|
max-width: 32px;
|
||
|
padding: 0;
|
||
|
cursor: pointer;
|
||
|
`);W.propTypes={type:c.a.string,focusColor:c.a.string,focusBackgroundColor:c.a.string,focusBorderColor:c.a.string},W.defaultProps={type:"button",focusColor:I.colors.$color_button_text_hover,focusBackgroundColor:"transparent",focusBorderColor:I.colors.$color_blue};const D=p()(a.SvgIcon)`
|
||
|
margin-top: 4px;
|
||
|
`,Y=p.a.div`
|
||
|
display: flex;
|
||
|
flex-direction: row;
|
||
|
align-items: center;
|
||
|
|
||
|
&.has-remove-keyword-button {
|
||
|
${q} {
|
||
|
${Object(i.getDirectionalStyle)("padding-right: 40px","padding-left: 40px")};
|
||
|
}
|
||
|
|
||
|
${W} {
|
||
|
${Object(i.getDirectionalStyle)("margin-left: -32px","margin-right: -32px")};
|
||
|
}
|
||
|
}
|
||
|
`;class G extends o.Component{constructor(e){super(e),this.handleChange=this.handleChange.bind(this)}handleChange(e){this.props.onChange(e.target.value)}renderLabel(){const{id:e,label:t,helpLink:s}=this.props;return Object(o.createElement)(K,null,Object(o.createElement)(F,{htmlFor:e},t),s)}renderErrorMessages(){const e=[...this.props.errorMessages];return!Object(M.isEmpty)(e)&&Object(o.createElement)(z,null,e.map((e,t)=>Object(o.createElement)(U,{key:t},Object(o.createElement)("span",{role:"alert"},e))))}render(){const{id:e,showLabel:t,keyword:s,onRemoveKeyword:r,onBlurKeyword:n,onFocusKeyword:a,hasError:i}=this.props,l=!t,c=r!==M.noop;return Object(o.createElement)(A,null,t&&this.renderLabel(),i&&this.renderErrorMessages(),Object(o.createElement)(Y,{className:c?"has-remove-keyword-button":null},Object(o.createElement)(q,{"aria-label":l?this.props.label:null,type:"text",id:e,className:i?"has-error":null,onChange:this.handleChange,onFocus:a,onBlur:n,value:s,autoComplete:"off"}),c&&Object(o.createElement)(W,{onClick:r,focusBoxShadowColor:"#084A67"},Object(o.createElement)(D,{size:"18px",icon:"times-circle",color:P}))))}}G.propTypes={id:c.a.string.isRequired,showLabel:c.a.bool,keyword:c.a.string,onChange:c.a.func.isRequired,onRemoveKeyword:c.a.func,onBlurKeyword:c.a.func,onFocusKeyword:c.a.func,label:c.a.string.isRequired,helpLink:c.a.node,hasError:c.a.bool,errorMessages:c.a.arrayOf(c.a.string)},G.defaultProps={showLabel:!0,keyword:"",onRemoveKeyword:M.noop,onBlurKeyword:M.noop,onFocusKeyword:M.noop,helpLink:null,hasError:!1,errorMessages:[]};var H=G;const Q=p.a.div`
|
||
|
padding: 16px;
|
||
|
/* Necessary to compensate negative top margin of the collapsible after the keyword input. */
|
||
|
border-bottom: 1px solid transparent;
|
||
|
`;class V extends o.Component{constructor(e){super(e),this.validate=this.validate.bind(this)}static renderHelpLink(){return Object(o.createElement)(B.a,{href:wpseoAdminL10n["shortlinks.focus_keyword_info"],className:"dashicons"},Object(o.createElement)("span",{className:"screen-reader-text"},Object(r.__)("Help on choosing the perfect focus keyphrase","wordpress-seo")))}validate(){const e=[...this.props.errors];return 0===this.props.keyword.trim().length&&this.props.displayNoKeyphraseMessage&&e.push(Object(r.__)("Please enter a focus keyphrase first to get related keyphrases","wordpress-seo")),0===this.props.keyword.trim().length&&this.props.displayNoKeyphrasForTrackingMessage&&e.push(Object(r.__)("Please enter a focus keyphrase first to track keyphrase performance","wordpress-seo")),this.props.keyword.includes(",")&&e.push(Object(r.__)("Are you trying to use multiple keyphrases? You should add them separately below.","wordpress-seo")),this.props.keyword.length>191&&e.push(Object(r.__)("Your keyphrase is too long. It can be a maximum of 191 characters.","wordpress-seo")),e}render(){const e=this.validate();return Object(o.createElement)(j.LocationConsumer,null,t=>Object(o.createElement)("div",{style:"sidebar"===t?{borderBottom:"1px solid #f0f0f0"}:{}},Object(o.createElement)(Q,{location:t},Object(o.createElement)(H,{id:"focus-keyword-input-"+t,onChange:this.props.onFocusKeywordChange,keyword:this.props.keyword,label:Object(r.__)("Focus keyphrase","wordpress-seo"),helpLink:V.renderHelpLink(),onBlurKeyword:this.props.onBlurKeyword,onFocusKeyword:this.props.onFocusKeyword,hasError:e.length>0,errorMessages:e}),this.props.isSEMrushIntegrationActive&&Object(o.createElement)(N,{location:t,keyphrase:this.props.keyword})),Object(o.createElement)(n.Slot,{name:"YoastAfterKeywordInput"+(t.charAt(0).toUpperCase()+t.slice(1))})))}}V.propTypes={keyword:c.a.string,onFocusKeywordChange:c.a.func.isRequired,onFocusKeyword:c.a.func.isRequired,onBlurKeyword:c.a.func.isRequired,isSEMrushIntegrationActive:c.a.bool,displayNoKeyphraseMessage:c.a.bool,displayNoKeyphrasForTrackingMessage:c.a.bool,errors:c.a.arrayOf(c.a.string)},V.defaultProps={keyword:"",isSEMrushIntegrationActive:!1,displayNoKeyphraseMessage:!1,displayNoKeyphrasForTrackingMessage:!1,errors:[]};var J=Object(O.compose)([Object(w.withSelect)(e=>{const{getFocusKeyphrase:t,getSEMrushNoKeyphraseMessage:s,hasWincherNoKeyphrase:o,getFocusKeyphraseErrors:r}=e("yoast-seo/editor");return{keyword:t(),displayNoKeyphraseMessage:s(),displayNoKeyphrasForTrackingMessage:o(),errors:r()}}),Object(w.withDispatch)(e=>{const{setFocusKeyword:t,setMarkerPauseStatus:s}=e("yoast-seo/editor");return{onFocusKeywordChange:t,onFocusKeyword:()=>s(!0),onBlurKeyword:()=>s(!1)}})])(V),X=s(154),Z=s(157),ee=s(44),te=s(61),se=s(74);function oe(e){let{target:t,children:s}=e;return Object(o.createElement)(se.a,{target:t},s)}oe.propTypes={target:c.a.string.isRequired,children:c.a.node.isRequired};var re=s(14),ne=s(15);const ae=p.a.span`
|
||
|
font-size: 1em;
|
||
|
font-weight: bold;
|
||
|
margin: 0 0 8px;
|
||
|
display: block;
|
||
|
`,ie=p.a.div`
|
||
|
padding: 16px;
|
||
|
`,le=p()(B.a)`
|
||
|
margin: -8px 0 -4px 4px;
|
||
|
`;class ce extends o.Component{renderResults(e){return Object(o.createElement)(o.Fragment,null,Object(o.createElement)(ae,null,Object(r.__)("Analysis results","wordpress-seo"),Object(o.createElement)(le,{href:wpseoAdminL10n["shortlinks.readability_analysis_info"],className:"dashicons"},Object(o.createElement)("span",{className:"screen-reader-text"},Object(r.__)("Learn more about the readability analysis","wordpress-seo")))),Object(o.createElement)(Z.a,{results:this.props.results,upsellResults:e,marksButtonClassName:"yoast-tooltip yoast-tooltip-w",marksButtonStatus:this.props.marksButtonStatus}))}getUpsellResults(e,t){let s=wpseoAdminL10n["shortlinks.upsell.metabox.word_complexity"];return"sidebar"===e&&(s=wpseoAdminL10n["shortlinks.upsell.sidebar.word_complexity"]),s=Object(ne.addQueryArgs)(s,{context:t}),function(){const e=re.helpers.getLanguagesWithWordComplexity(),t=window.wpseoScriptData.metabox.contentLocale,s=re.languageProcessing.getLanguage(t);return e.includes(s)}()?[{score:0,rating:"upsell",hasMarks:!1,id:"wordComplexity",text:Object(r.sprintf)(
|
||
|
/* Translators: %1$s is a span tag that adds styling to 'Word complexity', %2$s is a closing span tag.
|
||
|
%3$s is an anchor tag with a link to yoast.com, %4$s is a closing anchor tag.*/
|
||
|
Object(r.__)("%1$sWord complexity%2$s: Is your vocabulary suited for a larger audience? %3$sYoast SEO Premium will tell you!%4$s","wordpress-seo"),"<span style='text-decoration: underline'>","</span>",`<a href="${s}" data-action="load-nfd-ctb" data-ctb-id="f6a84663-465f-4cb5-8ba5-f7a6d72224b2" target="_blank">`,"</a>"),markerId:"wordComplexity"}]:[]}render(){const e=Object(ee.a)(this.props.overallScore);return Object(M.isNil)(this.props.overallScore)&&(e.className="loading"),Object(o.createElement)(j.LocationConsumer,null,t=>Object(o.createElement)(j.RootContext.Consumer,null,s=>{let{locationContext:n}=s,a=[];return this.props.shouldUpsell&&(a=this.getUpsellResults(t,n)),"sidebar"===t?Object(o.createElement)(g.a,{title:Object(r.__)("Readability analysis","wordpress-seo"),titleScreenReaderText:e.screenReaderReadabilityText,prefixIcon:Object(te.getIconForScore)(e.className),prefixIconCollapsed:Object(te.getIconForScore)(e.className),id:"yoast-readability-analysis-collapsible-"+t},this.renderResults(a)):"metabox"===t?Object(o.createElement)(oe,{target:"wpseo-metabox-readability-root"},Object(o.createElement)(ie,null,Object(o.createElement)(X.a,{target:"wpseo-readability-score-icon",scoreIndicator:e.className}),this.renderResults(a))):void 0}))}}ce.propTypes={results:c.a.array.isRequired,marksButtonStatus:c.a.string.isRequired,overallScore:c.a.number,shouldUpsell:c.a.bool},ce.defaultProps={overallScore:null,shouldUpsell:!1};var ue=Object(w.withSelect)(e=>{const{getReadabilityResults:t,getMarkButtonStatus:s}=e("yoast-seo/editor");return{...t(),marksButtonStatus:s()}})(ce),pe=s(17);const de=p.a.p`
|
||
|
color: ${I.colors.$color_upsell_text};
|
||
|
margin: 0;
|
||
|
padding-right: 8px;
|
||
|
`,be=p.a.div`
|
||
|
font-size: 1em;
|
||
|
display: flex;
|
||
|
flex-direction: ${e=>"horizontal"===e.alignment?"row":"column"};
|
||
|
${Object(i.getDirectionalStyle)("border-left","border-right")}: 4px solid ${I.colors.$color_pink_dark};
|
||
|
margin: 16px 0;
|
||
|
padding: 0 0 0 8px;
|
||
|
max-width: 600px;
|
||
|
|
||
|
> ${de} {
|
||
|
margin-bottom: ${e=>"vertical"===e.alignment&&"16px"};
|
||
|
}
|
||
|
`,me=p()(a.SvgIcon)`
|
||
|
margin: ${Object(i.getDirectionalStyle)("0 0 0 4px","0 4px 0 0")};
|
||
|
transform: ${Object(i.getDirectionalStyle)("rotate(0deg)","rotate(180deg)")};
|
||
|
`,he=Object(i.makeOutboundLink)(a.UpsellLinkButton),ge=e=>{const{alignment:t,url:s}=e;return Object(o.createElement)(be,{alignment:t},Object(o.createElement)(de,null,Object(r.sprintf)(
|
||
|
/* translators: %s expands to Yoast SEO Premium */
|
||
|
Object(r.__)("Did you know %s also analyzes the different word forms of your keyphrase, like plurals and past tenses?","wordpress-seo"),"Yoast SEO Premium")),Object(o.createElement)("div",null,Object(o.createElement)(he,{href:s,className:"UpsellLinkButton","data-action":"load-nfd-ctb","data-ctb-id":"f6a84663-465f-4cb5-8ba5-f7a6d72224b2"},Object(r.sprintf)(
|
||
|
/* translators: %s expands to Premium */
|
||
|
Object(r.__)("Go %s!","wordpress-seo"),"Premium"),Object(o.createElement)(me,{icon:"arrow-right",size:"8px",color:I.colors.$color_black}))))};ge.propTypes={alignment:c.a.oneOf(["horizontal","vertical"]),url:c.a.string.isRequired},ge.defaultProps={alignment:"vertical"};var ye=ge,fe=s(28),Oe=s.n(fe),we=s(85);const je=Object(i.makeOutboundLink)(),ke=e=>{const t=Object(r.sprintf)(
|
||
|
/* translators: %1$s expands to a 'Yoast SEO Premium' text linked to the yoast.com website. */
|
||
|
Object(r.__)("Great news: you can, with %1$s!","wordpress-seo"),"{{link}}Yoast SEO Premium{{/link}}"),s=Oe()({mixedString:t,components:{link:Object(o.createElement)(je,{href:e.link})}}),n=[Object(r.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(r.__)("%1$sCreate content faster%2$s: Use AI to create titles & meta descriptions","wordpress-seo"),"<strong>","</strong>"),`<strong>${Object(r.__)("Rank better with synonyms & related keyphrases","wordpress-seo")}</strong>`,Object(r.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(r.__)("%1$sNo more dead links%2$s: easy redirect manager","wordpress-seo"),"<strong>","</strong>"),`<strong>${Object(r.__)("Superfast internal linking suggestions","wordpress-seo")}</strong>`,Object(r.sprintf)(
|
||
|
/* translators: %1$s expands to a 'strong' start tag, %2$s to a 'strong' end tag. */
|
||
|
Object(r.__)("%1$sSocial media preview%2$s: Facebook & Twitter","wordpress-seo"),"<strong>","</strong>"),`<strong>${Object(r.__)("24/7 email support","wordpress-seo")}</strong>`,`<strong>${Object(r.__)("No ads!","wordpress-seo")}</strong>`],a=Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Other benefits of %s for you:","wordpress-seo"),"Yoast SEO Premium");return Object(o.createElement)(we.a,{infoParagraphs:[s,a],benefits:n,upsellButtonText:Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Get %s","wordpress-seo"),"Yoast SEO Premium"),upsellButton:{href:e.buyLink,className:"yoast-button-upsell",rel:null,"data-ctb-id":"f6a84663-465f-4cb5-8ba5-f7a6d72224b2","data-action":"load-nfd-ctb"},upsellButtonLabel:Object(r.__)("1 year free support and updates included!","wordpress-seo")})};ke.propTypes={link:c.a.string.isRequired,buyLink:c.a.string.isRequired};var ve=ke,_e=s(134);const xe=p.a.button`
|
||
|
// Increase specificity to override WP rules.
|
||
|
&& {
|
||
|
display: flex;
|
||
|
align-items: center;
|
||
|
}
|
||
|
|
||
|
.yoast-svg-icon {
|
||
|
margin: 1px 7px 0 0;
|
||
|
fill: currentColor;
|
||
|
}
|
||
|
`,Ee={open:Object(r.__)("Open","wordpress-seo"),heading:"",closeIconButton:Object(r.__)("Close","wordpress-seo"),closeButton:""},Re=e=>{const[t,s]=Object(o.useState)(!1),r=Object.assign({},Ee,e.labels),n=Object(o.useCallback)(()=>s(!1),[]),i=Object(o.useCallback)(()=>s(!0),[]);return Object(o.createElement)(o.Fragment,null,Object(o.createElement)(xe,{type:"button",onClick:i,className:e.classes.openButton+" yoast-modal__button-open"},e.openButtonIcon&&Object(o.createElement)(a.SvgIcon,{icon:e.openButtonIcon,size:"13px"}),r.open),t&&Object(o.createElement)(x.a,{onRequestClose:n,className:e.className,title:r.heading},e.children))};Re.propTypes={openButtonIcon:c.a.string,labels:c.a.shape({open:c.a.string,modalAriaLabel:c.a.string.isRequired,heading:c.a.string,closeIconButton:c.a.string,closeButton:c.a.string}).isRequired,classes:c.a.shape({openButton:c.a.string,closeIconButton:c.a.string,closeButton:c.a.string}),className:c.a.string,children:c.a.any.isRequired},Re.defaultProps={className:x.b,openButtonIcon:"",classes:{}};var Ce=Re;function Se(e){let{location:t}=e;return Object(o.createElement)(n.Slot,{name:"yoast-synonyms-"+t})}Se.propTypes={location:c.a.string.isRequired};const Ne=p.a.span`
|
||
|
font-size: 1em;
|
||
|
font-weight: bold;
|
||
|
margin: 1.5em 0 1em;
|
||
|
display: block;
|
||
|
`;class Be extends o.Component{renderSynonymsUpsell(e,t){const s={classes:{openButton:"wpseo-keyword-synonyms button-link"},labels:{open:"+ "+Object(r.__)("Add synonyms","wordpress-seo"),modalAriaLabel:Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Get %s","wordpress-seo"),"Yoast SEO Premium"),heading:Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Get %s","wordpress-seo"),"Yoast SEO Premium")}};let n=wpseoAdminL10n["shortlinks.upsell.metabox.focus_keyword_synonyms_link"],i=wpseoAdminL10n["shortlinks.upsell.metabox.focus_keyword_synonyms_button"];return"sidebar"===e.toLowerCase()&&(n=wpseoAdminL10n["shortlinks.upsell.sidebar.focus_keyword_synonyms_link"],i=wpseoAdminL10n["shortlinks.upsell.sidebar.focus_keyword_synonyms_button"]),n=Object(ne.addQueryArgs)(n,{context:t}),i=Object(ne.addQueryArgs)(i,{context:t}),Object(o.createElement)(Ce,s,Object(o.createElement)(_.a,null,Object(o.createElement)(_.b,{icon:a.YoastSeoIcon}),Object(o.createElement)("h2",null,Object(r.__)("Would you like to add keyphrase synonyms?","wordpress-seo")),Object(o.createElement)(ve,{link:n,buyLink:i})))}renderMultipleKeywordsUpsell(e){const t={classes:{openButton:"wpseo-multiple-keywords button-link"},labels:{open:"+ "+Object(r.__)("Add related keyphrase","wordpress-seo"),modalAriaLabel:Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Get %s","wordpress-seo"),"Yoast SEO Premium"),heading:Object(r.sprintf)(
|
||
|
/* translators: %s expands to 'Yoast SEO Premium'. */
|
||
|
Object(r.__)("Get %s","wordpress-seo"),"Yoast SEO Premium")}};let s=wpseoAdminL10n["shortlinks.upsell.metabox.focus_keyword_additional_link"],n=wpseoAdminL10n["shortlinks.upsell.metabox.focus_keyword_additional_button"];return"sidebar"===e.toLowerCase()&&(s=wpseoAdminL10n["shortlinks.upsell.sidebar.focus_keyword_additional_link"],n=wpseoAdminL10n["shortlinks.upsell.sidebar.focus_keyword_additional_button"]),Object(o.createElement)(Ce,t,Object(o.createElement)(_.a,null,Object(o.createElement)(_.b,{icon:a.YoastSeoIcon}),Object(o.createElement)("h2",null,Object(r.__)("Would you like to add a related keyphrase?","wordpress-seo")),Object(o.createElement)(_e.a,{link:s,buyLink:n})))}renderWordFormsUpsell(e,t){let s="sidebar"===e?wpseoAdminL10n["shortlinks.upsell.sidebar.morphology_upsell_sidebar"]:wpseoAdminL10n["shortlinks.upsell.sidebar.morphology_upsell_metabox"];return s=Object(ne.addQueryArgs)(s,{context:t}),Object(o.createElement)(ye,{url:s,alignment:"sidebar"===e?"vertical":"horizontal"})}renderTabIcon(e,t){return"metabox"!==e?null:Object(o.createElement)(X.a,{target:"wpseo-seo-score-icon",scoreIndicator:t})}getUpsellResults(e,t){let s=wpseoAdminL10n["shortlinks.upsell.metabox.keyphrase_distribution"];return"sidebar"===e&&(s=wpseoAdminL10n["shortlinks.upsell.sidebar.keyphrase_distribution"]),s=Object(ne.addQueryArgs)(s,{context:t}),[{score:0,rating:"upsell",hasMarks:!1,hasJumps:!1,id:"keyphraseDistribution",text:Object(r.sprintf)(
|
||
|
/* Translators: %1$s is a span tag that adds styling to 'Keyphrase distribution', %2$s is a closing span tag.
|
||
|
%3%s is an anchor tag with a link to yoast.com, %4$s is a closing anchor tag.*/
|
||
|
Object(r.__)("%1$sKeyphrase distribution%2$s: Have you evenly distributed your focus keyphrase throughout the whole text? %3$sYoast SEO Premium will tell you!%4$s","wordpress-seo"),"<span style='text-decoration: underline'>","</span>",`<a href="${s}" data-action="load-nfd-ctb" data-ctb-id="f6a84663-465f-4cb5-8ba5-f7a6d72224b2" target="_blank">`,"</a>"),markerId:"keyphraseDistribution"}]}render(){const e=Object(ee.a)(this.props.overallScore),t=Object(pe.a)().isPremium;return"loading"!==e.className&&""===this.props.keyword&&(e.className="na",e.screenReaderReadabilityText=Object(r.__)("Enter a focus keyphrase to calculate the SEO score","wordpress-seo")),Object(o.createElement)(j.LocationConsumer,null,s=>Object(o.createElement)(j.RootContext.Consumer,null,n=>{let{locationContext:a}=n;const i="metabox"===s?h.a:g.a;let l=[];return this.props.shouldUpsell&&(l=this.getUpsellResults(s,a)),Object(o.createElement)(o.Fragment,null,Object(o.createElement)(i,{title:t?Object(r.__)("Premium SEO analysis","wordpress-seo"):Object(r.__)("SEO analysis","wordpress-seo"),titleScreenReaderText:e.screenReaderReadabilityText,prefixIcon:Object(te.getIconForScore)(e.className),prefixIconCollapsed:Object(te.getIconForScore)(e.className),subTitle:this.props.keyword,id:"yoast-seo-analysis-collapsible-"+s},Object(o.createElement)(Se,{location:s}),this.props.shouldUpsell&&Object(o.createElement)(o.Fragment,null,this.renderSynonymsUpsell(s,a),this.renderMultipleKeywordsUpsell(s)),this.props.shouldUpsellWordFormRecognition&&this.renderWordFormsUpsell(s,a),Object(o.createElement)(Ne,null,Object(r.__)("Analysis results","wordpress-seo")),Object(o.createElement)(Z.a,{results:this.props.results,upsellResults:l,marksButtonClassName:"yoast-tooltip yoast-tooltip-w",editButtonClassName:"yoast-tooltip yoast-tooltip-w",marksButtonStatus:this.props.marksButtonStatus,location:s})),this.renderTabIcon(s,e.className))}))}}Be.propTypes={results:c.a.array,marksButtonStatus:c.a.string,keyword:c.a.string,shouldUpsell:c.a.bool,shouldUpsellWordFormRecognition:c.a.bool,overallScore:c.a.number},Be.defaultProps={results:[],marksButtonStatus:null,keyword:"",shouldUpsell:!1,shouldUpsellWordFormRecognition:!1,overallScore:null};var Me=Object(w.withSelect)((e,t)=>{const{getFocusKeyphrase:s,getMarksButtonStatus:o,getResultsForKeyword:r}=e("yoast-seo/editor"),n=s();return{...r(n),marksButtonStatus:t.hideMarksButtons?"disabled":o(),keyword:n}})(Be);function Ie(){const e=Object(pe.a)();return Object(M.get)(e,"multilingualPluginActive",!1)}const Le=p.a.span`
|
||
|
font-size: 1em;
|
||
|
font-weight: bold;
|
||
|
margin: 0 0 8px;
|
||
|
display: block;
|
||
|
`,Te=p.a.div`
|
||
|
padding: 16px;
|
||
|
`,Pe=p()(B.a)`
|
||
|
margin: -8px 0 -4px 4px;
|
||
|
`,$e=p.a.p`
|
||
|
min-height: 24px;
|
||
|
margin: 12px 0 0 0;
|
||
|
padding: 0;
|
||
|
display: flex;
|
||
|
align-items: flex-start;
|
||
|
`,Ae=p()(a.SvgIcon)`
|
||
|
margin: 3px 11px 0 0; // icon 13 + 11 right margin = 24 for the 8px grid.
|
||
|
`,Fe=e=>{const t=wpseoAdminL10n["shortlinks.inclusive_language_analysis_info"];function s(){return Object(o.createElement)(o.Fragment,null,Object(o.createElement)(Le,null,Object(r.__)("Analysis results","wordpress-seo"),Object(o.createElement)(Pe,{href:t,className:"dashicons"},Object(o.createElement)("span",{className:"screen-reader-text"},Object(r.__)("Learn more about the inclusive language analysis","wordpress-seo")))),Object(o.createElement)(Z.a,{results:e.results,marksButtonClassName:"yoast-tooltip yoast-tooltip-w",marksButtonStatus:e.marksButtonStatus,resultCategoryLabels:{problems:Object(r.__)("Non-inclusive phrases","wordpress-seo"),improvements:Object(r.__)("Potentially non-inclusive phrases","wordpress-seo")}}))}const n=Object(o.createInterpolateElement)(Object(r.sprintf)(
|
||
|
/* Translators: %1$s expands to a link on yoast.com, %2$s expands to the anchor end tag. */
|
||
|
Object(r.__)("%1$sInclusive language%2$s: We haven't detected any potentially non-inclusive phrases. Great work!","wordpress-seo"),"<a>","</a>"),{a:Object(o.createElement)("a",{href:t,target:"_blank",rel:"noreferrer"})});function i(){const e=Object(r.__)("We noticed that you are using a multilingual plugin. Please be aware that this analysis feedback is intended only for texts written in English.","wordpress-seo");return Object(o.createElement)(a.Alert,{type:"info"},e)}function l(){return Object(o.createElement)(o.Fragment,null,Object(o.createElement)(Le,null,Object(r.__)("Analysis results","wordpress-seo"),Object(o.createElement)(Pe,{href:t,className:"dashicons"},Object(o.createElement)("span",{className:"screen-reader-text"},Object(r.__)("Learn more about the inclusive language analysis","wordpress-seo")))),Object(o.createElement)($e,null,Object(o.createElement)(Ae,{icon:"circle",color:"#7ad03a",size:"13px"}),Object(o.createElement)("span",null,n)))}const c=Object(ee.a)(e.overallScore);return Object(M.isNil)(e.overallScore)&&(c.className="loading"),Object(o.createElement)(j.LocationConsumer,null,t=>{return"sidebar"===t?(n=e.results,a=c,Object(o.createElement)(g.a,{title:Object(r.__)("Inclusive language","wordpress-seo"),titleScreenReaderText:a.screenReaderInclusiveLanguageText,prefixIcon:Object(te.getIconForScore)(a.className),prefixIconCollapsed:Object(te.getIconForScore)(a.className),id:"yoast-inclusive-language-analysis-collapsible-sidebar"},Ie()?i():null,n.length>=1?s():l())):"metabox"===t?function(e,t){return Object(o.createElement)(se.a,{target:"wpseo-metabox-inclusive-language-root"},Object(o.createElement)(Te,null,Object(o.createElement)(X.a,{target:"wpseo-inclusive-language-score-icon",scoreIndicator:t.className}),Ie()?i():null,e.length>=1?s():l()))}(e.results,c):void 0;var n,a})};Fe.propTypes={results:c.a.array,marksButtonStatus:c.a.oneOf(["enabled","disabled","hidden"]).isRequired,overallScore:c.a.number},Fe.defaultProps={results:[],overallScore:null};var Ke=Object(w.withSelect)(e=>{const{getInclusiveLanguageResults:t,getMarkButtonStatus:s}=e("yoast-seo/editor");return{...t(),marksButtonStatus:s()}})(Fe);window.yoast=window.yoast||{},window.yoast.externals=window.yoast.externals||{},window.yoast.externals.components={CollapsibleCornerstone:f,KeywordInput:J,ReadabilityAnalysis:ue,SeoAnalysis:Me,InclusiveLanguageAnalysis:Ke}},3:function(e,t){e.exports=window.React},38:function(e,t){e.exports=window.wp.hooks},4:function(e,t){e.exports=window.lodash},40:function(e,t,s){"use strict";s.d(t,"b",(function(){return c}));var o=s(12),r=s.n(o),n=s(0),a=s(2),i=s.n(a),l=s(18);const c="yoast yoast-gutenberg-modal",u=e=>{const{title:t,className:s,showYoastIcon:o,additionalClassName:a,...i}=e,c=o?Object(n.createElement)("span",{className:"yoast-icon"}):null;return Object(n.createElement)(l.Modal,r()({title:t,className:`${s} ${a}`,icon:c},i),e.children)};u.propTypes={title:i.a.string,className:i.a.string,showYoastIcon:i.a.bool,children:i.a.oneOfType([i.a.node,i.a.arrayOf(i.a.node)]),additionalClassName:i.a.string},u.defaultProps={title:"Yoast SEO",className:c,showYoastIcon:!0,children:null,additionalClassName:""},t.a=u},44:function(e,t,s){"use strict";s.d(t,"a",(function(){return a}));var o=s(1),r=s(14),n=s(4);function a(e){return Object(n.isNil)(e)||(e/=10),function(e){switch(e){case"feedback":return{className:"na",screenReaderText:Object(o.__)("Feedback","wordpress-seo"),screenReaderReadabilityText:"",screenReaderInclusiveLanguageText:""};case"bad":return{className:"bad",screenReaderText:Object(o.__)("Needs improvement","wordpress-seo"),screenReaderReadabilityText:Object(o.__)("Needs improvement","wordpress-seo"),screenReaderInclusiveLanguageText:Object(o.__)("Needs improvement","wordpress-seo")};case"ok":return{className:"ok",screenReaderText:Object(o.__)("OK SEO score","wordpress-seo"),screenReaderReadabilityText:Object(o.__)("OK","wordpress-seo"),screenReaderInclusiveLanguageText:Object(o.__)("Potentially non-inclusive","wordpress-seo")};case"good":return{className:"good",screenReaderText:Object(o.__)("Good SEO score","
|
||
|
h2 > button {
|
||
|
padding-left: 24px;
|
||
|
padding-top: 16px;
|
||
|
|
||
|
&:hover {
|
||
|
background-color: #f0f0f0;
|
||
|
}
|
||
|
}
|
||
|
|
||
|
div[class^="collapsible_content"] {
|
||
|
padding: 24px 0;
|
||
|
margin: 0 24px;
|
||
|
border-top: 1px solid rgba(0,0,0,0.2);
|
||
|
}
|
||
|
|
||
|
`;t.a=e=>Object(n.createElement)(l,r()({hasPadding:!0,hasSeparator:!0},e))},5:function(e,t){e.exports=window.wp.data},61:function(e,t,s){"use strict";s.r(t),s.d(t,"getIconForScore",(function(){return i})),s.d(t,"default",(function(){return l}));var o=s(19),r=s(14);function n(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const s=e.getIdentifier(),o={score:e.score,rating:r.interpreters.scoreToRating(e.score),hasMarks:e.hasMarks(),marker:e.getMarker(),id:s,text:e.text,markerId:t.length>0?`${t}:${s}`:s,hasBetaBadge:e.hasBetaBadge(),hasJumps:e.hasJumps(),editFieldName:e.editFieldName};return"ok"===o.rating&&(o.rating="OK"),o}function a(e,t){switch(e.rating){case"error":t.errorsResults.push(e);break;case"feedback":t.considerationsResults.push(e);break;case"bad":t.problemsResults.push(e);break;case"OK":t.improvementsResults.push(e);break;case"good":t.goodResults.push(e)}return t}function i(e){switch(e){case"loading":return{icon:"loading-spinner",color:o.colors.$color_green_medium_light};case"not-set":return{icon:"seo-score-none",color:o.colors.$color_score_icon};case"noindex":return{icon:"seo-score-none",color:o.colors.$color_noindex};case"good":return{icon:"seo-score-good",color:o.colors.$color_green_medium};case"ok":return{icon:"seo-score-ok",color:o.colors.$color_ok};default:return{icon:"seo-score-bad",color:o.colors.$color_red}}}function l(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",s={errorsResults:[],problemsResults:[],improvementsResults:[],goodResults:[],considerationsResults:[]};if(!e)return s;for(let o=0;o<e.length;o++){const r=e[o];r.text&&(s=a(n(r,t),s))}return s}},66:function(e,t,s){"use strict";var o=s(0),r=s(8),n=s(2),a=s.n(n);const i=e=>{const[t,s]=Object(o.useState)(!1),{prefixIcon:n}=e;return Object(o.createElement)("div",{className:"yoast components-panel__body "+(t?"is-opened":"")},Object(o.createElement)("h2",{className:"components-panel__body-title"},Object(o.createElement)("button",{onClick:function(){s(!t)},className:"components-button components-panel__body-toggle"},Object(o.createElement)("span",{className:"yoast-icon-span",style:{fill:""+(n&&n.color||"")}},n&&Object(o.createElement)(r.SvgIcon,{icon:n.icon,color:n.color,size:n.size})),Object(o.createElement)("span",{className:"yoast-title-container"},Object(o.createElement)("div",{className:"yoast-title"},e.title),Object(o.createElement)("div",{className:"yoast-subtitle"},e.subTitle)),e.hasBetaBadgeLabel&&Object(o.createElement)(r.BetaBadge,null),Object(o.createElement)("span",{className:"yoast-chevron","aria-hidden":"true"}))),t&&e.children)};t.a=i,i.propTypes={title:a.a.string.isRequired,children:a.a.oneOfType([a.a.node,a.a.arrayOf(a.a.node)]).isRequired,prefixIcon:a.a.object,subTitle:a.a.string,hasBetaBadgeLabel:a.a.bool},i.defaultProps={prefixIcon:null,subTitle:"",hasBetaBadgeLabel:!1}},67:function(e,t,s){"use strict";var o=s(19),r=s(9),n=s(11),a=s.n(n);const i=Object(r.makeOutboundLink)(a.a.a`
|
||
|
display: inline-block;
|
||
|
position: relative;
|
||
|
outline: none;
|
||
|
text-decoration: none;
|
||
|
border-radius: 100%;
|
||
|
width: 24px;
|
||
|
height: 24px;
|
||
|
margin: -4px 0;
|
||
|
vertical-align: middle;
|
||
|
|
||
|
color: ${o.colors.$color_help_text};
|
||
|
|
||
|
&:hover,
|
||
|
&:focus {
|
||
|
color: ${o.colors.$color_snippet_focus};
|
||
|
}
|
||
|
|
||
|
// Overwrite the default blue active color for links.
|
||
|
&:active {
|
||
|
color: ${o.colors.$color_help_text};
|
||
|
}
|
||
|
|
||
|
&::before {
|
||
|
position: absolute;
|
||
|
top: 0;
|
||
|
left: 0;
|
||
|
padding: 2px;
|
||
|
content: "\f223";
|
||
|
}
|
||
|
`);t.a=i},74:function(e,t,s){"use strict";s.d(t,"a",(function(){return a}));var o=s(0),r=s(2),n=s.n(r);function a(e){let{target:t,children:s}=e,r=t;return"string"==typeof t&&(r=document.getElementById(t)),r?Object(o.createPortal)(s,r):null}a.propTypes={target:n.a.oneOfType([n.a.string,n.a.object]).isRequired,children:n.a.node.isRequired}},76:function(e,t,s){"use strict";s.d(t,"a",(function(){return i})),s.d(t,"b",(function(){return l}));var o=s(11),r=s.n(o),n=s(8),a=s(9);const i=r.a.div`
|
||
|
min-width: 600px;
|
||
|
|
||
|
@media screen and ( max-width: 680px ) {
|
||
|
min-width: 0;
|
||
|
width: 86vw;
|
||
|
}
|
||
|
`,l=r()(n.Icon)`
|
||
|
float: ${Object(a.getDirectionalStyle)("right","left")};
|
||
|
margin: ${Object(a.getDirectionalStyle)("0 0 16px 16px","0 16px 16px 0")};
|
||
|
|
||
|
&& {
|
||
|
width: 150px;
|
||
|
height: 150px;
|
||
|
|
||
|
@media screen and ( max-width: 680px ) {
|
||
|
width: 80px;
|
||
|
height: 80px;
|
||
|
}
|
||
|
}
|
||
|
`},78:function(e,t,s){"use strict";var o=s(0),r=s(8),n=s(2),a=s.n(n);const i=e=>Object(o.createElement)("div",{className:"yoast components-panel__body"},Object(o.createElement)("h2",{className:"components-panel__body-title"},Object(o.createElement)("button",{id:e.id,onClick:e.onClick,className:"components-button components-panel__body-toggle"},e.prefixIcon&&Object(o.createElement)("span",{className:"yoast-icon-span",style:{fill:""+(e.prefixIcon&&e.prefixIcon.color||"")}},Object(o.createElement)(r.SvgIcon,{size:e.prefixIcon.size,icon:e.prefixIcon.icon})),Object(o.createElement)("span",{className:"yoast-title-container"},Object(o.createElement)("div",{className:"yoast-title"},e.title),Object(o.createElement)("div",{className:"yoast-subtitle"},e.subTitle)),e.children,e.suffixIcon&&Object(o.createElement)(r.SvgIcon,{size:e.suffixIcon.size,icon:e.suffixIcon.icon}))));t.a=i,i.propTypes={onClick:a.a.func.isRequired,title:a.a.string.isRequired,id:a.a.string,subTitle:a.a.string,suffixIcon:a.a.object,prefixIcon:a.a.object,children:a.a.node},i.defaultProps={id:"",suffixIcon:null,prefixIcon:null,subTitle:"",children:null}},8:function(e,t){e.exports=window.yoast.componentsNew},85:function(e,t,s){"use strict";var o=s(0),r=s(28),n=s.n(r),a=s(2),i=s.n(a),l=s(11),c=s.n(l),u=s(9);const p=c.a.ul`
|
||
|
list-style: none;
|
||
|
margin: 0 0 24px;
|
||
|
padding: 0;
|
||
|
|
||
|
li {
|
||
|
margin: 10px 0 0 0;
|
||
|
}
|
||
|
|
||
|
span[aria-hidden="true"]:before {
|
||
|
content: "";
|
||
|
display: inline-block;
|
||
|
height: 13px;
|
||
|
width: 13px;
|
||
|
background-size: 13px 13px;
|
||
|
background-image: var( --yoast-svg-icon-check );
|
||
|
background-repeat: no-repeat;
|
||
|
margin-right: 10px;
|
||
|
}
|
||
|
`,d=c.a.small`
|
||
|
display: block;
|
||
|
margin-top: 4px;
|
||
|
`,b=Object(u.makeOutboundLink)();class m extends o.Component{constructor(e){super(e)}createBenefitsList(e){return e.length>0&&Object(o.createElement)(p,{role:"list"},e.map((e,t)=>Object(o.createElement)("li",{key:t},Object(o.createElement)("span",{"aria-hidden":"true"}),n()({mixedString:e.replace("<strong>","{{strong}}").replace("</strong>","{{/strong}}"),components:{strong:Object(o.createElement)("strong",null)}}))))}createInfoParagraphs(e){return e.map((e,t)=>Object(o.createElement)("p",{key:t},e))}render(){return Object(o.createElement)("div",null,this.createInfoParagraphs(this.props.infoParagraphs),this.createBenefitsList(this.props.benefits),Object(o.createElement)(b,this.props.upsellButton,this.props.upsellButtonText,this.props.upsellButtonHasCaret&&Object(o.createElement)("span",{"aria-hidden":"true",className:"yoast-button-upsell__caret"})),Object(o.createElement)(d,{id:this.props.upsellButton["aria-describedby"]},this.props.upsellButtonLabel))}}m.propTypes={benefits:i.a.array,infoParagraphs:i.a.array,upsellButton:i.a.object,upsellButtonText:i.a.string.isRequired,upsellButtonLabel:i.a.string,upsellButtonHasCaret:i.a.bool},m.defaultProps={infoParagraphs:[],benefits:[],upsellButton:{href:"",className:"button button-primary"},upsellButtonLabel:"",upsellButtonHasCaret:!0},t.a=m},9:function(e,t){e.exports=window.yoast.helpers},93:function(e,t,s){"use strict";function o(e){return function(){return e}}var r=function(){};r.thatReturns=o,r.thatReturnsFalse=o(!1),r.thatReturnsTrue=o(!0),r.thatReturnsNull=o(null),r.thatReturnsThis=function(){return this},r.thatReturnsArgument=function(e){return e},e.exports=r},99:function(e,t,s){"use strict";s.d(t,"b",(function(){return p}));var o=s(0),r=s(1),n=s(40),a=s(2),i=s.n(a),l=s(4),c=s(78),u=s(22);const p=e=>{let t=!0;if("blur"===e.type){const{relatedTarget:s}=e;if(s){const e=["media-modal","wp-core-ui"];t=Object(l.intersection)(e,Array.from(s.classList)).length!==e.length}}return t},d=e=>{let{id:t,postTypeName:s,children:a,title:i,isOpen:l,close:d,open:b,shouldCloseOnClickOutside:m,showChangesWarning:h}=e;const g=Object(o.useCallback)(e=>{p(e)&&d()},[d]);return Object(o.createElement)(o.Fragment,null,l&&Object(o.createElement)(u.LocationProvider,{value:"modal"},Object(o.createElement)(n.a,{title:i,onRequestClose:g,additionalClassName:"yoast-collapsible-modal yoast-post-settings-modal",id:"id",shouldCloseOnClickOutside:m},Object(o.createElement)("div",{className:"yoast-content-container"},Object(o.createElement)("div",{className:"yoast-modal-content"},a)),Object(o.createElement)("div",{className:"yoast-notice-container"},Object(o.createElement)("hr",null),Object(o.createElement)("div",{className:"yoast-button-container"},h&&Object(o.createElement)("p",null,
|
||
|
/* Translators: %s translates to the Post Label in singular form */
|
||
|
Object(r.sprintf)(Object(r.__)("Make sure to save your %s for changes to take effect","wordpress-seo"),s)),Object(o.createElement)("button",{className:"yoast-button yoast-button--primary yoast-button--post-settings-modal",type:"button",onClick:g},
|
||
|
/* Translators: %s translates to the Post Label in singular form */
|
||
|
Object(r.sprintf)(Object(r.__)("Return to your %s","wordpress-seo"),s)))))),Object(o.createElement)(c.a,{id:t+"-open-button",title:i,suffixIcon:{size:"20px",icon:"pencil-square"},onClick:b}))};d.propTypes={id:i.a.string.isRequired,postTypeName:i.a.string.isRequired,children:i.a.oneOfType([i.a.node,i.a.arrayOf(i.a.node)]).isRequired,title:i.a.string.isRequired,isOpen:i.a.bool.isRequired,open:i.a.func.isRequired,close:i.a.func.isRequired,shouldCloseOnClickOutside:i.a.bool,showChangesWarning:i.a.bool},d.defaultProps={shouldCloseOnClickOutside:!0,showChangesWarning:!0},t.a=d}});
|