A Jetpack connection is required for our free security and traffic features to work.
","jetpack"),{a:o.a.createElement("a",{href:nl("jetpack-cancelled-connection"),target:"_blank",rel:"noopener noreferrer"}),p:o.a.createElement("p",null)});break;case"wrong_state":r=Object(wt.__)("You need to stay logged in to your WordPress blog while you authorize Jetpack.","jetpack");break;case"invalid_client":r=Object(wt.__)("We had an issue connecting Jetpack; deactivate then reactivate the Jetpack plugin, then connect again.","jetpack");break;case"invalid_grant":r=Object(wt.__)('There was an issue connecting your Jetpack. Please click "Connect to WordPress.com" again.',"jetpack");break;case"site_inaccessible":case"site_requires_authorization":r=Object(wt.sprintf)(Object(wt.__)("Your website needs to be publicly accessible to use Jetpack: %s","jetpack"),e);break;case"site_blacklisted":r=Object(Uu.createInterpolateElement)(Object(wt.__)("This site can't be connected to WordPress.com because it violates our Terms of Service.","jetpack"),{a:o.a.createElement("a",{href:nl("wpcom-tos"),rel:"noopener noreferrer",target:"_blank"})});break;case"not_public":r=Object(Uu.createInterpolateElement)(Object(wt.__)("Your Jetpack has a glitch. Connecting this site with WordPress.com is not possible. This usually means your site is not publicly accessible (localhost).","jetpack"),{s:o.a.createElement("strong",null)});break;case"wpcom_408":case"wpcom_5??":case"wpcom_bad_response":case"wpcom_outage":r=Object(wt.__)("WordPress.com is currently having problems and is unable to fuel up your Jetpack. Please try again later.","jetpack");break;case"register_http_request_failed":case"token_http_request_failed":r=Object(wt.sprintf)(Object(wt.__)("Jetpack could not contact WordPress.com: %s. This usually means something is incorrectly configured on your web host.","jetpack"),e);break;case"no_role":case"no_cap":case"no_code":case"no_state":case"invalid_state":case"invalid_request":case"invalid_scope":case"unsupported_response_type":case"invalid_token":case"no_token":case"missing_secrets":case"home_missing":case"siteurl_missing":case"gmt_offset_missing":case"site_name_missing":case"secret_1_missing":case"secret_2_missing":case"site_lang_missing":case"home_malformed":case"siteurl_malformed":case"gmt_offset_malformed":case"timezone_string_malformed":case"site_name_malformed":case"secret_1_malformed":case"secret_2_malformed":case"site_lang_malformed":case"secrets_mismatch":case"verify_secret_1_missing":case"verify_secret_1_malformed":case"verify_secrets_missing":case"verify_secrets_mismatch":r=Object(Uu.createInterpolateElement)(Object(wt.sprintf)(Object(wt.__)("Your Jetpack has a glitch. We’re sorry for the inconvenience. Please try again later, if the issue continues please contact support with this message: %s","jetpack"),e),{s:o.a.createElement("strong",null)});break;default:r=e}return t?o.a.createElement("div",null,r,o.a.createElement("br",null),t):o.a.createElement("div",null,r)})),Ya()(Oc()(n),"getMessageFromKey",(function(e){var t,r="",i="is-info";switch(e){case"modules_activated":r=Object(Uu.createInterpolateElement)(Object(wt.sprintf)(Object(wt.__)("Welcome to Jetpack %s!","jetpack"),n.props.currentVersion),{s:o.a.createElement("strong",null)});break;case"already_authorized":r=Object(wt.__)("Your Jetpack is already connected.","jetpack"),i="is-success";break;case"authorized":r=Object(wt.__)("You're fueled up and ready to go, Jetpack is now active.","jetpack"),i="is-success";break;case"linked":r=Object(wt.__)("You're fueled up and ready to go.","jetpack"),i="is-success";break;case"protect_misconfigured_ip":r=Object(wt.__)("Your server is misconfigured, which means that Jetpack Protect is unable to effectively protect your site.","jetpack"),i="is-info",t=o.a.createElement(Fm,{href:nl("jetpack-support-security-troubleshooting-protect")},Object(wt.__)("Learn More","jetpack"));break;case"reconnection_completed":r=Object(Uu.createInterpolateElement)(Object(wt.__)("Jetpack successfully reconnected! You can check your Jetpack Connection health by visiting the Site Health tool.","jetpack"),{a:o.a.createElement("a",{href:n.props.siteAdminUrl+"site-health.php"})}),i="is-success";break;default:r=e}return[r,i,t]})),Ya()(Oc()(n),"renderContent",(function(){var e,t="is-info",r="",i=n.props.jetpackStateNoticesErrorCode,a=n.props.jetpackStateNoticesMessageCode,s=n.props.jetpackStateNoticesMessageContent;if(i||a||s){if(i&&(r=n.getErrorFromKey(i),"access_denied"!==i&&(t="is-error")),s&&s.release_post_content)return o.a.createElement(Hm,{dismiss:n.dismissJetpackStateNotice,version:n.props.currentVersion,releasePostContent:s.release_post_content,featuredImage:s.release_post_featured_image,title:s.release_post_title});if(a){var c=n.getMessageFromKey(a);r=c[0],t=c[1],e=c[2]}return o.a.createElement(Yu,{status:t,onDismissClick:n.dismissJetpackStateNotice,text:r},e)}})),n}return Pi()(t,e),Cc()(t,[{key:"render",value:function(){return o.a.createElement("div",null,this.state.showNotice?this.renderContent():null)}}]),t}(o.a.Component);Ya()(qm,"displayName","JetpackStateNotices");var Km=ce((function(e){return{currentVersion:Gi(e),jetpackStateNoticesErrorCode:Bs(e),jetpackStateNoticesMessageCode:Vs(e),jetpackStateNoticesErrorDescription:qs(e),jetpackStateNoticesMessageContent:Hs(e),siteAdminUrl:Xi(e)}}))(qm),Jm=function(e){function t(){var e,n;Oi()(this,t);for(var r=arguments.length,i=new Array(r),a=0;aOffline Mode (some features are disabled) because: ","jetpack"),{a:o.a.createElement("a",{href:nl("jetpack-support-development-mode"),target:"_blank",rel:"noopener noreferrer"}),reasons:o.a.createElement("ul",null,t.map((function(e,t){return o.a.createElement("li",{key:t},e)})))});return o.a.createElement(Yu,{showDismiss:!1,status:"is-info",text:n},o.a.createElement(Fm,{href:nl("jetpack-support-development-mode")},Object(wt.__)("Learn More","jetpack")))}return!1}}]),t}(o.a.Component);Ya()(cg,"displayName","OfflineModeNotice"),cg.propTypes={siteConnectionStatus:u.a.oneOfType([u.a.string,u.a.bool]).isRequired,siteOfflineMode:u.a.oneOfType([u.a.bool,u.a.object]).isRequired};var lg=function(e){function t(){return Oi()(this,t),Ti()(this,xi()(t).apply(this,arguments))}return Pi()(t,e),Cc()(t,[{key:"render",value:function(){return!(this.props.isLinked||!this.props.connectUrl||!this.props.siteConnected)&&o.a.createElement("div",{className:"jp-unlinked-notice"},o.a.createElement(zm,{title:Object(wt.__)("Jetpack is powering your site, but to access all of its features you’ll need to connect your account to WordPress.com.","jetpack"),callToAction:Object(wt.__)("Create account","jetpack"),href:"".concat(this.props.connectUrl,"&from=unlinked-user-connect"),icon:"my-sites",className:"is-jetpack-info",from:"unlinked-user-connect",connectUser:!0}))}}]),t}(o.a.Component);Ya()(lg,"displayName","UserUnlinked"),lg.propTypes={connectUrl:u.a.string.isRequired,siteConnected:u.a.bool.isRequired};var ug=function(e){function t(){return Oi()(this,t),Ti()(this,xi()(t).apply(this,arguments))}return Pi()(t,e),Cc()(t,[{key:"render",value:function(){var e=this.props.siteDataErrors.filter((function(e){return e.hasOwnProperty("action")}));return o.a.createElement("div",{"aria-live":"polite"},o.a.createElement(rg,null),this.props.siteConnectionStatus&&this.props.userCanConnectSite&&!this.props.isReconnectingSite&&(this.props.connectionErrors.length>0||e.length>0)&&o.a.createElement(Ym,{errors:this.props.connectionErrors.concat(e)}),o.a.createElement(Km,null),o.a.createElement(sg,{isDevVersion:this.props.isDevVersion,userIsSubscriber:this.props.userIsSubscriber}),o.a.createElement(cg,{siteConnectionStatus:this.props.siteConnectionStatus,siteOfflineMode:this.props.siteOfflineMode}),o.a.createElement(og,{isStaging:this.props.isStaging,isInIdentityCrisis:this.props.isInIdentityCrisis}),o.a.createElement(ag,null),o.a.createElement(Lm,null),!this.props.isReconnectingSite&&!e.length&&!this.props.connectionErrors.length&&o.a.createElement(lg,{connectUrl:this.props.connectUrl,siteConnected:!0===this.props.siteConnectionStatus,isLinked:this.props.isLinked}),!this.props.siteConnectionStatus&&!this.props.userCanConnectSite&&o.a.createElement(Yu,{showDismiss:!1,status:"is-warning",text:Object(wt.__)("This site is not connected to WordPress.com. Please ask the site administrator to connect.","jetpack")}),this.props.licensingError&&o.a.createElement(Yu,{showDismiss:!0,status:"is-error",text:this.props.licensingError,onDismissClick:this.props.clearLicensingError}))}}]),t}(o.a.Component);Ya()(ug,"displayName","JetpackNotices");var pg=ce((function(e){return{connectUrl:ws(e),siteConnectionStatus:_s(e),userCanConnectSite:oa(e),userIsSubscriber:ta(e),isLinked:Ts(e),isDevVersion:Wi(e),siteOfflineMode:ks(e),isStaging:xs(e),isInIdentityCrisis:Ns(e),connectionErrors:xa(e),siteDataErrors:Bo(e),isReconnectingSite:zs(e),licensingError:yc(e)}}),(function(e){return{clearLicensingError:function(){return e((function(e){return e({type:yi,error:""}),Vi.updateLicensingError({error:""})}))}}}))(ug),dg=function(e){function t(){return Oi()(this,t),Ti()(this,xi()(t).apply(this,arguments))}return Pi()(t,e),Cc()(t,[{key:"componentDidMount",value:function(){var e=jQuery(this.refs.adminNotices),t=jQuery(".vp-deactivated");t.length>0&&t.each((function(){var t=jQuery(this).addClass("dops-notice is-success is-dismissable").removeClass("wrap vp-notice notice notice-success");t.wrapInner(''),t.find(".dops-notice__content").before('').css("display","block"),t.find(".dops-notice__content").after(''),t.find("h2").replaceWith((function(){return jQuery("",{html:this.innerHTML})})),t.find("p").replaceWith((function(){return jQuery("",{html:this.innerHTML})})),t.prependTo(e).css("display","flex")}));var n=jQuery(".vp-notice");n.length>0&&n.each((function(){var t=jQuery(this);if(0===t.find(".dops-notice__icon").length){var n=t.hasClass("vp-registered"),r=n?"is-success":"is-error";t.addClass("dops-notice vp-notice-jp "+r),t.wrapInner('');var i=n?'':'';t.find(".dops-notice__content").before(i),t.find(".vp-message").removeClass("vp-message").addClass("dops-notice__text"),t.find("h3").replaceWith((function(){return jQuery("",{html:this.innerHTML})})),t.find("p").replaceWith((function(){return jQuery("",{html:this.innerHTML})})),t.css("display","flex")}t.find('a[href*="admin.php?page=vaultpress"]').remove(),t.prependTo(e).removeClass("wrap vp-notice")}));var r=jQuery(".woocommerce-message");r.length>0&&r.each((function(){var t=jQuery(this).addClass("dops-notice").removeClass("updated wc-connect");t.find(".button-primary").addClass("dops-notice__action").removeClass("button-primary").detach().appendTo(t),t.find("p").not(".submit").wrapAll('');var n=t.find(".dops-notice__text");n.find("p").replaceWith((function(){return jQuery("",{html:this.innerHTML,class:"dops-notice__moved_text"})})),n.find("br").remove(),t.find(".button-secondary").removeClass("button-secondary").detach().appendTo(n),t.find(".submit").remove(),t.find(".woocommerce-message-close").removeClass("woocommerce-message-close notice-dismiss").addClass("dops-notice__action"),t.wrapInner('').prependTo(e).css("display","flex"),t.find(".dops-notice__action").not(":first").removeClass("dops-notice__action").detach().appendTo(t.find(".dops-notice__text")),t.find(".dops-notice__action:first").detach().appendTo(t)}));var i=jQuery(".notice");i.length>0&&i.each((function(){jQuery(this).hide()})),e.length>0&&jQuery(".dops-notice__dismiss").click((function(){jQuery(this).parent().closest("div").hide()}))}},{key:"render",value:function(){return o.a.createElement("div",{id:"jp-admin-notices",ref:"adminNotices","aria-live":"polite"})}}]),t}(o.a.Component),hg=function(e){function t(){return Oi()(this,t),Ti()(this,xi()(t).apply(this,arguments))}return Pi()(t,e),Cc()(t,[{key:"UNSAFE_componentWillReceiveProps",value:function(e){var t=this.props.analytics.tracks.recordEvent;e.searchTerm!==this.props.searchTerm&&e.searchTerm.length>=3&&t("jetpack_wpa_search_term",{term:e.searchTerm})}},{key:"render",value:function(){return null}}]),t}(s.Component);hg.propTypes={analytics:u.a.object,searchTerm:u.a.string};var fg=ce((function(e){return{searchTerm:ro(e)}}))(hg),mg=(n(356),function(e){function t(){var e,n;Oi()(this,t);for(var r=arguments.length,i=new Array(r),a=0;a0&&t.prependTo(e)}},{key:"shouldComponentUpdate",value:function(e){return!["/wpbody-content","/wp-toolbar"].includes(e.location.pathname)&&(e.siteConnectionStatus!==this.props.siteConnectionStatus||e.isLinked!==this.props.isLinked||e.isAuthorizingInPlace!==this.props.isAuthorizingInPlace||e.location.pathname!==this.props.location.pathname||e.searchTerm!==this.props.searchTerm||e.rewindStatus!==this.props.rewindStatus||e.areThereUnsavedSettings!==this.props.areThereUnsavedSettings||e.isReconnectingSite!==this.props.isReconnectingSite)}},{key:"componentDidUpdate",value:function(e){if(e.location.pathname!==this.props.location.pathname&&this.props.isSiteConnected&&Hc.tracks.recordEvent("jetpack_wpa_page_view",{path:this.props.location.pathname,current_version:this.props.currentVersion}),e.siteConnectionStatus!==this.props.siteConnectionStatus){var t=jQuery("#toplevel_page_jetpack").find("ul.wp-submenu li");t.find('a[href$="#/settings"]').hide(),t.find('a[href$="admin.php?page=stats"]').hide()}}},{key:"getAtAGlance",value:function(){return o.a.createElement(Gf,{siteRawUrl:this.props.siteRawUrl,siteAdminUrl:this.props.siteAdminUrl,rewindStatus:this.props.rewindStatus})}},{key:"shouldShowAppsCard",value:function(){return this.props.isSiteConnected&&vg.includes(this.props.location.pathname)}},{key:"shouldShowSupportCard",value:function(){return this.props.isSiteConnected&&vg.includes(this.props.location.pathname)}},{key:"shouldShowRewindStatus",value:function(){return this.props.isSiteConnected&&vg.includes(this.props.location.pathname)}},{key:"shouldShowMasthead",value:function(){return[].concat(bg,vg,_g).includes(this.props.location.pathname)}},{key:"shouldShowFooter",value:function(){return[].concat(vg,_g).includes(this.props.location.pathname)}},{key:"shouldShowAuthIframe",value:function(){return this.props.isAuthorizingInPlace}},{key:"shouldBlurMainContent",value:function(){return this.props.isReconnectingSite}},{key:"shouldShowReconnectModal",value:function(){return"/reconnect"===this.props.location.pathname}},{key:"closeReconnectModal",value:function(){this.props.history.replace("/dashboard")}},{key:"render",value:function(){return o.a.createElement("div",null,this.shouldShowReconnectModal()&&o.a.createElement(gg,{show:!0,onHide:this.closeReconnectModal}),this.shouldShowMasthead()&&o.a.createElement(tl,{location:this.props.location}),o.a.createElement("div",{className:"jp-lower"},this.shouldShowRewindStatus()&&o.a.createElement(Jp,null),o.a.createElement(dg,null),o.a.createElement(pg,null),this.shouldShowAuthIframe()&&o.a.createElement(Ic,this.props.isReconnectingSite&&{scrollToIframe:!1,title:Object(wt.__)("Reconnect to WordPress.com by approving the connection","jetpack")}),o.a.createElement(Ge,{when:this.props.areThereUnsavedSettings,message:this.handleRouterWillLeave}),this.renderMainContent(this.props.location.pathname),this.shouldShowSupportCard()&&o.a.createElement(Mm,{path:this.props.location.pathname}),this.shouldShowAppsCard()&&o.a.createElement(Nm,null)),this.shouldShowFooter()&&o.a.createElement(Am,{siteAdminUrl:this.props.siteAdminUrl}),o.a.createElement(fg,{analytics:Hc}))}}]),t}(o.a.Component),kg=ce((function(e){return{siteConnectionStatus:_s(e),isLinked:Ts(e),isAuthorizingInPlace:Os(e),siteRawUrl:Qi(e),siteAdminUrl:Xi(e),searchTerm:ro(e),apiRoot:ba(e),apiNonce:ga(e),tracksUserData:va(e),areThereUnsavedSettings:fo(e),userCanManageModules:ra(e),userCanConnectSite:oa(e),isSiteConnected:ys(e),isReconnectingSite:zs(e),rewindStatus:Qs(e),currentVersion:Gi(e),showSetupWizard:Ca(e)}}),(function(e){return{setInitialState:function(){return e((function(e){e({type:Nt,initialState:window.Initial_State})}))},clearUnsavedSettingsFlag:function(){return e(Yl())},reconnectSite:function(){return e(Nc())}}}))(lt(yg));function wg(e){switch(e){case"/dashboard":return Object(wt._x)("At A Glance","Navigation item.","jetpack");case"/setup":return Object(wt._x)("Set up","Navigation item.","jetpack");case"/my-plan":return Object(wt._x)("My Plan","Navigation item.","jetpack");case"/plans":case"/plans-prompt":return Object(wt._x)("Plans","Navigation item.","jetpack");case"/settings":return Object(wt._x)("Settings","Navigation item.","jetpack");case"/discussion":return Object(wt._x)("Discussion","Navigation item.","jetpack");case"/security":return Object(wt._x)("Security","Navigation item.","jetpack");case"/performance":return Object(wt._x)("Performance","Navigation item.","jetpack");case"/traffic":return Object(wt._x)("Traffic","Navigation item.","jetpack");case"/writing":return Object(wt._x)("Writing","Navigation item.","jetpack");case"/sharing":return Object(wt._x)("Sharing","Navigation item.","jetpack");default:return Object(wt._x)("At A Glance","Navigation item.","jetpack")}}window.wpNavMenuClassChange=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{setup:-1,dashboard:1,settings:2},t=window.location.hash;jQuery(".current").each((function(e,t){jQuery(t).removeClass("current")}));var n=function(e){return jQuery("#toplevel_page_jetpack").find("li").filter((function(t){return t===e}))[0]};t=t.split("?")[0].replace(/#/,""),bg.includes(t)?n(e.setup).classList.add("current"):vg.includes(t)?n(e.dashboard).classList.add("current"):_g.includes(t)&&n(e.settings).classList.add("current");var r=jQuery("body");r.on("click",'a[href$="#/dashboard"], a[href$="#/settings"], .jp-dash-section-header__settings[href="#/security"], .dops-button[href="#/my-plan"], .dops-button[href="#/plans"], .jp-dash-section-header__external-link[href="#/security"]',(function(){window.scrollTo(0,0)})),r.on("click",".jetpack-js-stop-propagation",(function(e){e.stopPropagation()}))},Ct(),function(){var e=document.getElementById("jp-plugin-container");if(null===e)return;a.a.render(o.a.createElement("div",null,o.a.createElement(h,{store:Ec},o.a.createElement(dt,null,o.a.createElement(ct,null,o.a.createElement(nt,{path:"/dashboard"},o.a.createElement(kg,{routeName:wg("/dashboard")})),o.a.createElement(nt,{path:"/reconnect"},o.a.createElement(kg,{routeName:wg("/reconnect")})),o.a.createElement(nt,{path:"/setup"},o.a.createElement(kg,{routeName:wg("/setup")})),o.a.createElement(nt,{path:"/my-plan"},o.a.createElement(kg,{routeName:wg("/my-plan")})),o.a.createElement(nt,{path:"/plans"},o.a.createElement(kg,{routeName:wg("/plans")})),o.a.createElement(nt,{path:"/plans-prompt"},o.a.createElement(kg,{routeName:wg("/plans-prompt")})),o.a.createElement(nt,{path:"/settings"},o.a.createElement(kg,{routeName:wg("/settings")})),o.a.createElement(nt,{path:"/discussion"},o.a.createElement(kg,{routeName:wg("/discussion")})),o.a.createElement(nt,{path:"/security"},o.a.createElement(kg,{routeName:wg("/security")})),o.a.createElement(nt,{path:"/performance"},o.a.createElement(kg,{routeName:wg("/performance")})),o.a.createElement(nt,{path:"/traffic"},o.a.createElement(kg,{routeName:wg("/traffic")})),o.a.createElement(nt,{path:"/writing"},o.a.createElement(kg,{routeName:wg("/writing")})),o.a.createElement(nt,{path:"/sharing"},o.a.createElement(kg,{routeName:wg("/sharing")})),o.a.createElement(nt,{path:"/wpbody-content",component:kg}),o.a.createElement(nt,{path:"/wp-toolbar",component:kg}),o.a.createElement(nt,{path:"/privacy",component:kg}),o.a.createElement(nt,{path:"/*"},o.a.createElement(kg,{routeName:wg("/*")})))))),e)}()}]));