kollapsminoriteten/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-ad-blocking-r...

42 lines
174 KiB
JavaScript
Raw Normal View History

2025-12-12 13:13:07 +01:00
"use strict";(globalThis.__googlesitekit_webpackJsonp=globalThis.__googlesitekit_webpackJsonp||[]).push([[265,290],{1102:(e,t,i)=>{i.d(t,{w:()=>a});var n=i(35470),s=i(63696),o=i(2422);function r(){}function a(e,t){const i=(0,o.W)({sticky:!0}),a=(0,s.useRef)(),l=(0,s.useCallback)(e,t),c=(0,n.A)(i?l:r);return i&&(a.current=c),a.current}},2362:(e,t,i)=>{i.d(t,{A:()=>g});var n=i(4452),s=i.n(n),o=i(62688),r=i.n(o),a=i(63696),l=i(62540);const c=(0,a.forwardRef)(({label:e,className:t,hasLeftSpacing:i=!1,...n},o)=>(0,l.jsx)("span",{ref:o,...n,className:s()("googlesitekit-badge",t,{"googlesitekit-badge--has-left-spacing":i}),children:e}));c.displayName="Badge",c.propTypes={label:r().string.isRequired,hasLeftSpacing:r().bool};const g=c},2422:(e,t,i)=>{i.d(t,{W:()=>l});var n=i(79257),s=i(35470),o=i(63696),r=i(6732),a=i(7081);function l({sticky:e=!1}={}){const t=(0,o.useContext)(r.A),[i,l]=(0,o.useState)(!1),c=(0,s.A)(e=>e(a.n).getInViewResetCount()),g=(0,s.A)(e=>e(a.n).getValue("forceInView"));return(0,o.useEffect)(()=>{t.value&&!i&&l(!0)},[i,t,l]),(0,o.useEffect)(()=>{g&&l(!0)},[g]),(0,n.A)(()=>{l(!1)},[c]),!(!e||!i)||!!t.value}},2522:(e,t,i)=>{i.d(t,{D:()=>o});var n=i(32091),s=i.n(n);function o(e,{dateRangeLength:t}){s()(Array.isArray(e),"report must be an array to partition."),s()(Number.isInteger(t)&&t>0,"dateRangeLength must be a positive integer.");const i=-1*t;return{currentRange:e.slice(i),compareRange:e.slice(2*i,i)}}},3288:(e,t,i)=>{i.d(t,{Q:()=>n});const n="emailReportingUserSettingsSelectionPanelOpened"},3714:(e,t,i)=>{i.d(t,{Kk:()=>o,SZ:()=>n,Yw:()=>r,oJ:()=>a,tT:()=>s});const n="body",s=[n,"display","headline","label","title"],o="small",r="medium",a=[o,r,"large"]},3782:(e,t,i)=>{i.d(t,{A:()=>CTAButton});var n=i(62688),s=i.n(n),o=i(49383),r=i(83366),a=i(62540);function CTAButton({label:e,ariaLabel:t,disabled:i,inProgress:n,onClick:s,href:l,external:c=!1,hideExternalIndicator:g=!1}){if(!e||!s&&!l)return null;let d;return c&&!g&&(d=(0,a.jsx)(r.A,{width:14,height:14})),(0,a.jsx)(o.SpinnerButton,{className:"googlesitekit-banner__cta","aria-label":t,disabled:i||n,isSaving:n,onClick:s,href:l,target:c?"_blank":void 0,trailingIcon:d,children:e})}CTAButton.propTypes={label:s().string,ariaLabel:s().string,disabled:s().bool,inProgress:s().bool,onClick:s().func,href:s().string,dismissOnClick:s().bool,dismissOptions:s().shape({expiresInSeconds:s().number,skipHidingFromQueue:s().bool})}},4445:(e,t,i)=>{i.d(t,{A:()=>d});var n=i(62688),s=i.n(n),o=i(63696),r=i(81276),a=i(49383),l=i(8420),c=i(62540);let g=null;function RefocusableModalDialog({dialogActive:e=!1,refocusQuerySelector:t=null,...i}){const n=(0,o.useCallback)(()=>{setTimeout(()=>{const e=t?document.querySelector(t):g;e&&document.body.contains(e)&&e.focus(),t||(g=null)})},[t]),s=(0,r.A)(e);return(0,o.useEffect)(()=>(!0===s&&!1===e&&n(),()=>{n()}),[s,e,n]),(0,c.jsx)(l.A,{dialogActive:e,...i})}!function(){function e(e){const t=e.target.closest("button, a, input");t&&!t.classList.contains("mdc-dialog__cancel-button")&&(g=t)}void 0!==i.g&&i.g.document&&!i.g._googlesitekitModalFocusTrackerInitialized&&(i.g.document.addEventListener("mousedown",e),i.g.document.addEventListener("keydown",t=>{"Enter"!==t.key&&" "!==t.key||e(t)}),i.g._googlesitekitModalFocusTrackerInitialized=!0)}(),RefocusableModalDialog.propTypes={dialogActive:s().bool,refocusQuerySelector:s().string,...a.Dialog.propTypes};const d=RefocusableModalDialog},4884:(e,t,i)=>{i.d(t,{A:()=>d});var n=i(62688),s=i.n(n),o=i(4452),r=i.n(o),a=i(49383),l=i(20898),c=i(15167),g=i(62540);function CTA({title:e,headerText:t,headerContent:i,description:n,ctaLink:s,ctaLabel:o,ctaLinkExternal:d,ctaType:u,error:p,onClick:h,"aria-label":m,children:f}){return(0,g.jsxs)("div",{className:r()("googlesitekit-cta",{"googlesitekit-cta--error":p}),children:[(t||i)&&(0,g.jsxs)("div",{className:"googlesitekit-cta__header",children:[t&&(0,g.jsx)(c.A,{as:"h2",size:"small",type:"label",className:"googlesitekit-cta__header_text",children:t}),i]}),(0,g.jsxs)("div",{className:"googlesitekit-cta__body",children:[e&&(0,g.jsx)(c.A,{as:"h3",size:"small",type:
(0,c.__)("<strong>Note:</strong> %s","google-site-kit"),k),{strong:(0,u.jsx)("strong",{})})})]}),(0,u.jsxs)(g.DialogFooter,{children:[(0,u.jsx)(g.Button,{className:"mdc-dialog__cancel-button",onClick:i,disabled:y,tertiary:!0,children:(0,c.__)("Cancel","google-site-kit")}),b?(0,u.jsx)(g.Button,{href:b,onClick:h,target:"_blank",danger:_,children:f}):(0,u.jsx)(g.SpinnerButton,{onClick:h,danger:_,disabled:y,isSaving:y,children:f||(0,c.__)("Disconnect","google-site-kit")})]})]})}ModalDialog.displayName="Dialog",ModalDialog.propTypes={className:s().string,dialogActive:s().bool,handleDialog:s().func,handleConfirm:s().func.isRequired,onOpen:s().func,onClose:s().func,title:s().string,confirmButton:s().string,danger:s().bool,small:s().bool,medium:s().bool,buttonLink:s().string};const p=ModalDialog},10804:(e,t,i)=>{i.d(t,{A:()=>AdBlockerWarning});var n,s=i(62688),o=i.n(s),r=i(50539),a=i(93896),l=i(37226),c=i(82871),g=i(13606),d=i(20898),u=i(63696);function p(){return p=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},p.apply(null,arguments)}const h=e=>u.createElement("svg",p({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 13 14"},e),n||(n=u.createElement("path",{stroke:"currentColor",strokeWidth:1.5,d:"M4.5 1.5H3a2 2 0 0 0-2 2v7a2 2 0 0 0 2 2h7a2 2 0 0 0 2-2V9M7 1.5h5v5M5 8.5 11.5 2"})));var m=i(80035),f=i(62540);function AdBlockerWarningMessage({getHelpLink:e="",warningMessage:t=null}){return t?(0,f.jsx)(m.A,{className:"googlesitekit-notice--small",type:m.A.TYPES.WARNING,description:(0,g.A)((0,c.sprintf)(/* translators: 1: The warning message. 2: "Get help" text. */ /* translators: 1: The warning message. 2: "Get help" text. */
(0,c.__)("%1$s. <Link><Strong>%2$s</Strong></Link>","google-site-kit"),t,(0,c.__)("Get help","google-site-kit")),{Link:(0,f.jsx)(d.A,{href:e,trailingIcon:(0,f.jsx)(h,{width:15,height:15}),external:!0,hideExternalIndicator:!0}),Strong:(0,f.jsx)("strong",{})}),hideIcon:!0}):null}function AdBlockerWarning({moduleSlug:e,className:t}){const i=(0,r.useSelect)(t=>t(l.i).getModuleStoreName(e)),n=(0,r.useSelect)(e=>e(i)?.getAdBlockerWarningMessage()),s=(0,r.useSelect)(t=>t(a.O4).getDocumentationLinkURL(`${e}-ad-blocker-detected`));return(0,f.jsx)(AdBlockerWarningMessage,{className:t,getHelpLink:s,warningMessage:n})}AdBlockerWarningMessage.propTypes={getHelpLink:o().string,warningMessage:o().string},AdBlockerWarning.propTypes={className:o().string,moduleSlug:o().string.isRequired}},11106:(e,t,i)=>{i.d(t,{A:()=>o});var n=i(63696),s=i(65214);const o=(0,n.createContext)(s.t)},12108:(e,t,i)=>{i.d(t,{YJ:()=>o,Eq:()=>r});var n=i(32947),s=i(17243);function o(e,t){const n=document.querySelector(e);if(!n)return 0;const s=n.getBoundingClientRect().top,o=r(t);return s+i.g.scrollY-o}function r(e){let t=function(e){let t=0;const o=document.querySelector(".googlesitekit-header");t=o&&"sticky"===i.g.getComputedStyle(o).position?function(e){const t=document.querySelector(".googlesitekit-header");if(t){if(e===n.mp)return t.offsetHeight;const i=t.getBoundingClientRect().bottom;return i<0?0:i}return 0}(e):function(e){const t=document.querySelector("#wpadminbar");if(t&&e!==n.mp)return t.offsetHeight;return 0}(e);return t=function(e){return(0,s.isFinite)(e)?e:0}(t),t<0?0:t}(e);const o=document.querySelectorAll(".googlesitekit-navigation, .googlesitekit-entity-header");return t+=Array.from(o).reduce((e,t)=>e+t.offsetHeight,0),t}},12701:(e,t,i)=>{i.d(t,{A:()=>Root});var n=i(62688),s=i.n(n),o=i(44010),r=i(77105),a=i(63696),l=i(50539),c=i.n(l),g=i(82871),d=i(54312),u=i(61991),p=i(90007),h=i(12850),m=i(62540);class ErrorHandler extends a.Component{constructor(e){super(e),this.state={error:null,info:null,copied:!1}}componentDidCatch(e,t){i.g.console.error("Caught an error:",e,t),this.setState({error:e,info:t}),(0,h.sx)("react_error",`handle_${this.context||"unknown"}_error`,`${e?.message}\n${t?.componentStack}`.slice(0,500))}render(){const{children:e}=this.props,{error:t,info:i}=this.state;return t?(0,m.jsx)(p.A,{notificationID:"googlesitekit-error",className:"googlesitekit-error-handler",type:"error",title:(0,g.__)("Site Kit encountered an error","google-site-kit"),description:(0,m.jsxs)(a.Fragment,{children:[(0,m.jsx)(d.A,{message:t.message,componentStack:i.componentStack}),(0,m.jsxs)("pre",{className:"googlesitekit-overflow-auto",children:[t.message,i.componentStack]})]})}):e}}ErrorHandler.contextType=u.Ay,ErrorHandler.propTypes={children:s().node.isRequired};const f=ErrorHandler;var k=i(11106);const{Consumer:_,Provider:y}=k.A,v=y;var x=i(65214),b=i(4445),S=i(78340),A=i(45472),j=i(58116),N=i(64067),I=i(14007);const w=function AuthenticatedPermissionsModal(){const e=(0,l.useRegistry)(),t=(0,l.useSelect)(e=>e(j.oR).getPermissionScopeError()),n=(0,l.useSelect)(e=>e(j.oR).getUnsatisfiedScopes()),s=(0,l.useSelect)(e=>e(j.oR).getConnectURL({additionalScopes:t?.data?.scopes,redirectURL:t?.data?.redirectURL||i.g.location.href,errorRedirectURL:t?.data?.errorRedirectURL})),{clearPermissionScopeError:o}=(0,l.useDispatch)(j.oR),{navigateTo:r}=(0,l.useDispatch)(A.M),{setValues:c}=(0,l.useDispatch)(S.s),d=(0,a.useCallback)(()=>{o()},[o]),u=(0,a.useCallback)(async()=>{c(j.$8,{permissionsError:t}),await(0,N.mR)(e),r(s)},[e,s,r,t,c]);return(0,a.useEffect)(()=>{!async function(){t?.data?.skipModal&&t?.data?.scopes?.length&&await u()}()},[u,t]),t?t?.data?.scopes?.length?t?.data?.skipModal||n&&t?.data?.scopes.every(e=>n.includes(e))?null:(0,m.jsx)(I.A,{children:(0,m.jsx)(b.A,{title:(0,g.__)("Additional Permissions Required","google-site-kit"),subtitle:t.message,confirmButton:(0,g.__)("Proceed","google-site-kit"),handleConfirm:u,handleCancel:d,onClose:d,dialogActive:!0,medium:!0})}):(i.g.console.warn("permissionsError lacks scopes array to use for redirect, so not showing t
(0,g.__)("Google Account for %1$s (Email: %2$s)","google-site-kit"),s,i)),s&&!i&&(Z=(0,g.sprintf)(/* translators: Account info text. 1: User's (full) name. */ /* translators: Account info text. 1: User's (full) name. */
(0,g.__)("Google Account for %1$s","google-site-kit"),s)),!s&&i&&(Z=(0,g.sprintf)(/* translators: Account info text. 1: User's email address. */ /* translators: Account info text. 1: User's email address. */
(0,g.__)("Google Account (Email: %1$s)","google-site-kit"),i)),(0,S.jsxs)(d.Fragment,{children:[(0,S.jsxs)("div",{ref:A,className:"googlesitekit-user-selector googlesitekit-dropdown-menu googlesitekit-dropdown-menu__icon-menu mdc-menu-surface--anchor",children:[(0,S.jsx)(k.Button,{disabled:r,ref:N,className:"googlesitekit-header__dropdown mdc-button--dropdown googlesitekit-border-radius-round--tablet googlesitekit-border-radius-round--phone googlesitekit-border-radius-round googlesitekit-button-icon",onClick:T,icon:!!n&&(0,S.jsx)("i",{className:"mdc-button__icon mdc-button__account","aria-hidden":"true",children:(0,S.jsx)("img",{className:"mdc-button__icon--image",src:n,alt:(0,g.__)("User Avatar","google-site-kit")})}),"aria-haspopup":"menu","aria-expanded":c,"aria-controls":"user-menu","aria-label":r?void 0:(0,g.__)("Account","google-site-kit"),tooltipEnterDelayInMS:500,customizedTooltip:r?null:(0,S.jsxs)("span",{"aria-label":Z,children:[(0,S.jsx)("strong",{children:(0,g.__)("Google Account","google-site-kit")}),(0,S.jsx)("br",{}),(0,S.jsx)("br",{}),s,s&&(0,S.jsx)("br",{}),i]}),text:!0,tooltip:!0}),(0,S.jsxs)(k.Menu,{className:"googlesitekit-user-menu",menuOpen:c,onSelected:O,id:"user-menu",children:[(0,S.jsx)("li",{children:(0,S.jsx)(Details,{})}),e&&(0,S.jsx)("li",{id:"manage-email-reports",className:"mdc-list-item",role:"menuitem",children:(0,S.jsx)(Item,{icon:(0,S.jsx)(z,{width:"24"}),label:(0,g.__)("Manage email reports","google-site-kit")})}),!!t&&(0,S.jsx)("li",{id:"manage-sites",className:"mdc-list-item",role:"menuitem",children:(0,S.jsx)(Item,{icon:(0,S.jsx)(C,{width:"24"}),label:(0,g.__)("Manage Sites","google-site-kit")})}),(0,S.jsx)("li",{id:"disconnect",className:"mdc-list-item",role:"menuitem",children:(0,S.jsx)(Item,{icon:(0,S.jsx)(j,{width:"24"}),label:(0,g.__)("Disconnect","google-site-kit")})})]})]}),(0,S.jsx)(x.A,{children:(0,S.jsx)(_.A,{dialogActive:a,handleConfirm:L,handleCancel:E,onClose:E,title:(0,g.__)("Disconnect","google-site-kit"),subtitle:(0,g.__)("Disconnecting Site Kit by Google will remove your access to all services. After disconnecting, you will need to re-authorize to restore service.","google-site-kit"),confirmButton:(0,g.__)("Disconnect","google-site-kit"),danger:!0,small:!0})})]})}var Z=i(55527),$=i(35323),Q=i(29898),X=i(15844),J=i(39525),q=i(30521),K=i(24558),ee=i(73874),te=i(12108),ie=i(32947);var ne=i(44949),se=i(86134);const oe={[ee.Oo]:{[K.SH]:ne.CONTEXT_MAIN_DASHBOARD_KEY_METRICS,[K.OT]:ne.CONTEXT_MAIN_DASHBOARD_TRAFFIC,[K.en]:ne.CONTEXT_MAIN_DASHBOARD_CONTENT,[K.Ej]:ne.CONTEXT_MAIN_DASHBOARD_SPEED,[K.Gw]:ne.CONTEXT_MAIN_DASHBOARD_MONETIZATION},[ee.oE]:{[K.OT]:ne.CONTEXT_ENTITY_DASHBOARD_TRAFFIC,[K.en]:ne.CONTEXT_ENTITY_DASHBOARD_CONTENT,[K.Ej]:ne.CONTEXT_ENTITY_DASHBOARD_SPEED,[K.Gw]:ne.CONTEXT_ENTITY_DASHBOARD_MONETIZATION}};var re;function ae(){return ae=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},ae.apply(null,arguments)}const le=e=>d.createElement("svg",ae({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 18 18"},e),re||(re=d.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M18 16V2c0-1.1-1-2-2.222-2H2.222C1 0 0 .9 0 2v14c0 1.1 1 2 2.222 2h13.556C17 18 18 17.1 18 16M9 7h5V5H9zm7-5H2v14h14zM4 4h4v4H4zm10 7H9v2h5zM4 10h4v4H4z",clipRule:"evenodd"})));var ce,ge,de,ue;function pe(){return pe=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},pe.apply(null,arguments)}const he=e=>d.createElement("svg",pe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 13 12"},e),ce||(ce=d.createElement("rect",{width:5,height:5,x:.5,fill:"currentColor",rx:1})),ge||(ge=d.createElement("rect",{width:5,height:5,x:7.5,fill:"currentColor",rx:1})),de||(de=d.createElement("rect",{width:5,height:5,x:.5,y:7,fill:"currentColor",rx:1})),ue||(ue=d.createElement("rect",{width:5,height:5,x:7.5,y:7,fill:"currentColor",rx:1})));var m
(0,g.__)("Shared by <strong>%s</strong>","google-site-kit"),n.login),{strong:(0,S.jsx)("strong",{title:n.login})})})]})}Service.propTypes={module:r().string.isRequired};var Be=i(15167);function SharedServices(){const e=(0,u.useSelect)(e=>e(b.oR).getViewableModules());return void 0===e?null:(0,S.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,S.jsx)(Be.A,{as:"h4",size:"large",type:"title",children:(0,g.__)("Shared services","google-site-kit")}),(0,S.jsx)("ul",{children:e.map(e=>(0,S.jsx)(Service,{module:e},e))})]})}var Pe=i(82167);function Tracking(){const e=(0,F.A)();return(0,S.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,S.jsx)(Me.A,{children:(0,Le.A)((0,g.__)("Thanks for using Site Kit!<br />Help us make it even better","google-site-kit"),{br:(0,S.jsx)("br",{})})}),(0,S.jsx)(Pe.A,{trackEventCategory:`${e}_headerbar_viewonly`,alignCheckboxLeft:!0})]})}var He=i(74595);function ManageEmailReports(){const{setValue:e}=(0,He.wA)(P.n);return(0,S.jsxs)(d.Fragment,{children:[(0,S.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,S.jsx)("li",{className:"googlesitekit-view-only-menu__list-item googlesitekit-view-only-menu__email-reporting",children:(0,S.jsx)("ul",{className:"googlesitekit-view-only-menu",children:(0,S.jsx)("li",{className:"googlesitekit-view-only-menu__email-reporting-item",children:(0,S.jsx)(k.Button,{onClick:()=>e(G.Q,!0),icon:(0,S.jsx)("span",{className:"googlesitekit-view-only-menu__email-reporting-item--icon",children:(0,S.jsx)(z,{width:"24"})}),tertiary:!0,children:(0,S.jsx)("span",{className:"googlesitekit-view-only-menu__email-reporting-item--name",children:(0,g.__)("Manage email reports","google-site-kit")})})})})})]})}function ViewOnlyMenu(){const e=(0,W.i)("proactiveUserEngagement"),[t,i]=(0,d.useState)(!1),n=(0,d.useRef)(),s=(0,F.A)();(0,h.A)(n,()=>i(!1)),(0,Y.l)([f._f,f.wn],n,()=>i(!1));const o=(0,d.useCallback)(()=>{t||(0,y.sx)(`${s}_headerbar`,"open_viewonly"),i(!t)},[t,s]),r=(0,u.useSelect)(e=>e(b.oR).hasCapability(b.ej));return(0,S.jsxs)("div",{ref:n,className:l()("googlesitekit-view-only-menu","googlesitekit-dropdown-menu","googlesitekit-dropdown-menu__icon-menu","mdc-menu-surface--anchor",{"googlesitekit-view-only-menu--user-can-authenticate":r}),children:[(0,S.jsx)(k.Button,{className:"googlesitekit-header__dropdown mdc-button--dropdown googlesitekit-border-radius-round--phone googlesitekit-button-icon",onClick:o,icon:(0,S.jsx)("span",{className:"mdc-button__icon","aria-hidden":"true",children:(0,S.jsx)(Oe,{className:"mdc-button__icon--image"})}),"aria-haspopup":"menu","aria-expanded":t,"aria-controls":"view-only-menu","aria-label":(0,g.__)("View only","google-site-kit"),tooltipEnterDelayInMS:500,text:!0,tooltip:!0,children:(0,g.__)("View only","google-site-kit")}),(0,S.jsxs)(k.Menu,{menuOpen:t,onSelected:o,id:"view-only-menu",nonInteractive:!0,children:[(0,S.jsx)(Description,{}),(0,S.jsx)(SharedServices,{}),e&&(0,S.jsx)(ManageEmailReports,{}),(0,S.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,S.jsx)(Tracking,{})]})]})}var Ue=i(71423),Ge=i(53137),Ye=i(77513);function CoreSiteBannerNotification({id:e,...t}){const{dismissNotification:i,acceptNotification:n}=(0,u.useDispatch)(B.O4),s=(0,d.useCallback)(()=>{n(e)},[e,n]),o=(0,d.useCallback)(()=>{i(e)},[e,i]);return(0,S.jsx)(Ye.A,{onCTAClick:s,onDismissClick:o,...t,id:e})}CoreSiteBannerNotification.propTypes={content:r().string,ctaLabel:r().string,ctaTarget:r().string,ctaURL:r().string,dismissLabel:r().string,dismissible:r().bool,gaTrackingEventArgs:r().object,id:r().string.isRequired,learnMoreLabel:r().string,learnMoreURL:r().string,title:r().string.isRequired},CoreSiteBannerNotification.defaultProps={content:"",ctaLabel:"",ctaTarget:"",ctaURL:"",dismissLabel:(0,g.__)("OK, Got it!","google-site-kit"),dismissible:!0,learnMoreLabel:"",learnMoreURL:""};const Fe=CoreSiteBannerNotification;const Ve=function CoreSiteBannerNotifications(){const e=(0,F.A)(),[t,i]=(0,d.useState)(!1),[n,s]=(0,d.useState)(!1),o=(0,d.useRef)(Date.now()),r=(0,u.useSelect)(e=>e(B.O4).isUsin
(0,y._n)("Last %s day","Last %s days",e,"google-site-kit"),e)}return{"last-7-days":{slug:"last-7-days",label:e(7),days:7},"last-14-days":{slug:"last-14-days",label:e(14),days:14},"last-28-days":{slug:"last-28-days",label:e(28),days:28},"last-90-days":{slug:"last-90-days",label:e(90),days:90}}}function w(e=""){if(!(0,n.isString)(e))return!1;if(3!==e.split("-").length)return!1;const t=new Date(e);return(0,n.isDate)(t)&&!isNaN(t)}function E(e){_()((0,n.isDate)(e)&&!isNaN(e),v);const t=`${e.getMonth()+1}`,i=`${e.getDate()}`;return[e.getFullYear(),t.length<2?`0${t}`:t,i.length<2?`0${i}`:i].join("-")}function M(e){_()(w(e),x);const[t,i,n]=e.split("-");return new Date(t,i-1,n)}function T(e,t){return E(D(e,t*j))}function C(e){const t=e.split("-");return 3===t.length&&"last"===t[0]&&!Number.isNaN(t[1])&&!Number.isNaN(parseFloat(t[1]))&&"days"===t[2]}function D(e,t){_()(w(e)||(0,n.isDate)(e)&&!isNaN(e),x);const i=w(e)?Date.parse(e):e.getTime();return new Date(i-1e3*t)}var R=i(69743),O=i(94552),L=i(62540);function z(e,t={}){if(Number.isNaN(Number(e)))return"";const{invertColor:i=!1}=t;return(0,R.Ay)((0,L.jsx)(O.A,{direction:e>0?"up":"down",invertColor:i}))}function B(e,t){return e>0&&t>0?e/t-1:e>0?1:t>0?-1:0}var P=i(8143);function H(e){const t=parseFloat(e)||0;return!!Number.isInteger(t)&&t>0}function U(e){if("number"==typeof e)return!0;const t=(e||"").toString();return!!t&&!isNaN(t)}function G(e){return Array.isArray(e)?[...e].sort():e}var Y=i(2522);function F(e,t){function i(e){return"0"===e||0===e}if(i(e)&&i(t))return 0;if(i(e)||Number.isNaN(e))return null;const n=(t-e)/e;return Number.isNaN(n)||!Number.isFinite(n)?null:n}function V(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}}function W(e){if(!e)return"";const t=e.replace(/&#(\d+);/g,(e,t)=>String.fromCharCode(t)).replace(/(\\)/g,"");return(0,n.unescape)(t)}},14007:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(47209),s=i(62688),o=i.n(s),r=i(63696),a=i(78325);function Portal({children:e,slug:t}){const[i]=(0,r.useState)(document.createElement("div"));return(0,n.A)(()=>{t&&i.classList.add(`googlesitekit-portal-${t}`);const e=document.querySelector(".googlesitekit-plugin")||document.body;return e.appendChild(i),()=>e.removeChild(i)}),(0,a.createPortal)(e,i)}Portal.propTypes={slug:o().string,children:o().node},Portal.defaultProps={slug:"",children:null};const l=Portal},15167:(e,t,i)=>{i.d(t,{A:()=>Typography});var n=i(62688),s=i.n(n),o=i(4452),r=i.n(o),a=i(3714),l=i(62540);function Typography({className:e,type:t,size:i,as:n="span",children:s,...o}){return(0,l.jsx)(n,{className:r()("googlesitekit-typography",e,{[`googlesitekit-typography--${t}`]:t&&a.tT.includes(t),[`googlesitekit-typography--${i}`]:i&&a.oJ.includes(i)}),...o,children:s})}Typography.propTypes={className:s().string,type:s().oneOf(a.tT),size:s().oneOf(a.oJ),as:s().oneOfType([s().string,s().elementType])}},15210:(e,t,i)=>{i.d(t,{O:()=>s});var n=i(31234);const s=i.n(n)()(i.g)},15577:(e,t,i)=>{i.d(t,{SO:()=>c});var n=i(55620),s=i(99123);const o={},r=void 0===i.g?null:i.g;function a(){return[i.g.innerWidth,i.g.innerHeight]}function l(e=o){const{fps:t,leading:i,initialWidth:l=0,initialHeight:c=0}=e,[g,d]=(0,n._)("undefined"==typeof document?[l,c]:a,t,i);function u(){return d(a)}return(0,s.A)(r,"resize",u),(0,s.A)(r,"orientationchange",u),g}function c(e){return l(e)[0]}},16834:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(62688),s=i.n(n),o=i(4452),r=i.n(o),a=i(62540);function VisuallyHidden({className:e,children:t,...i}){return t?(0,a.jsx)("span",{...i,className:r()("screen-reader-text",e),children:t}):null}VisuallyHidden.propTypes={className:s().string,children:s().node},VisuallyHidden.defaultProps={className:""};const l=VisuallyHidden},18418:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var n,s=i(63696);function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},o.apply(null,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>s.createElement("svg",o({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 2 12"},e
(0,l.__)("Step %1$s of %2$s (upcoming).","google-site-kit"),e,s);case y.ACTIVE:return(0,l.sprintf)(/* translators: 1: The number of the current step. 2: The total number of steps. */ /* translators: 1: The number of the current step. 2: The total number of steps. */
(0,l.__)("Step %1$s of %2$s (active).","google-site-kit"),e,s);case y.COMPLETED:return(0,l.sprintf)(/* translators: 1: The number of the current step. 2: The total number of steps. */ /* translators: 1: The number of the current step. 2: The total number of steps. */
(0,l.__)("Step %1$s of %2$s (completed).","google-site-kit"),e,s);default:return""}}return(0,v.jsx)("ol",{className:k()("googlesitekit-stepper",i),children:n.Children.map(e,(e,i)=>{const r=function(e=-1){return e<t?y.COMPLETED:e===t?y.ACTIVE:y.UPCOMING}(i),a=i+1;return(0,v.jsxs)("li",{className:k()("googlesitekit-stepper__step",`googlesitekit-stepper__step--${r}`,e.props.className),children:[(0,v.jsxs)("div",{className:"googlesitekit-stepper__step-progress",children:[(0,v.jsx)("span",{className:"googlesitekit-stepper__step-number",title:o(a,r),children:r===y.COMPLETED?(0,v.jsx)(_.A,{}):a}),a<s&&(0,v.jsx)("div",{className:"googlesitekit-stepper__step-progress-line"})]}),(0,n.cloneElement)(e,{stepStatus:r})]})})})}Stepper.propTypes={children:m().node.isRequired,activeStep:m().number,className:m().string};var x=i(15167);function Step({children:e,title:t,stepStatus:i}){return(0,v.jsxs)("div",{className:"googlesitekit-stepper__step-info",children:[(0,v.jsx)(x.A,{as:"h2",className:"googlesitekit-stepper__step-title",size:"medium",type:"title",children:t}),(0,v.jsx)("div",{className:"googlesitekit-stepper__step-content-container",children:i===y.ACTIVE&&(0,v.jsx)("div",{className:"googlesitekit-stepper__step-content",children:e})})]})}Step.propTypes={children:m().node.isRequired,title:m().string.isRequired,stepStatus:m().oneOf(Object.values(y))};var b,S,A,j,N,I,w,E,M,T,C,D,R,O,L,z,B,P,H,U,G=i(99620),Y=i(45472),F=i(93896),V=i(7081),W=i(77766),Z=i(12850),$=i(74179);function Q(){return Q=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},Q.apply(null,arguments)}const X=e=>n.createElement("svg",Q({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 390 273"},e),b||(b=n.createElement("path",{fill:"#F3F5F7",d:"M22.56 28.885a85 85 0 0 1 8.606-7.899C60.044-2.097 83.903-2.06 116.934 2.153 139.265 5 158.642 18.5 182.13 17.185 205.617 15.871 238.088 7.743 264 9.5c29.5 2 37 5.5 63.227 19.385 24.273 12.85 46.312 35.426 57.388 65.284 18.985 51.177-14.865 143.285-60.259 147.628-32.893 3.148-60.039-33.973-93.239-25.376-20.452 5.297-32.583 27.515-48.362 42.177-18.409 17.107-48.199 16.032-69.755 6.902-20.542-8.699-35.63-25.926-42.338-51.32-5.107-19.338-4.595-38.709-16.86-53.857C36.497 138.947 9.432 134 1.281 94.168c-5.16-25.213 5.942-49.13 21.279-65.283"})),S||(S=n.createElement("g",{filter:"url(#ad-blocking-recovery-setup_svg__a)"},n.createElement("rect",{width:257.906,height:176.087,x:50.837,y:42.913,fill:"#fff",rx:14.086}),n.createElement("rect",{width:259.302,height:177.484,x:50.139,y:42.214,stroke:"#CBD0D3",strokeWidth:1.396,rx:14.785}))),A||(A=n.createElement("rect",{width:78,height:126.285,x:65,y:78.486,fill:"#EE92DA",rx:5.282})),j||(j=n.createElement("circle",{cx:104.5,cy:139.528,r:11,stroke:"#fff",strokeWidth:3})),N||(N=n.createElement("path",{stroke:"#fff",strokeWidth:3,d:"m112 132.028-15.5 15.5"})),I||(I=n.createElement("path",{fill:"#EBEEF0",d:"M50.837 56.999c0-7.78 6.307-14.086 14.087-14.086h229.733c7.78 0 14.086 6.306 14.086 14.086v7.258H50.837z"})),w||(w=n.createElement("rect",{width:7.115,height:7.115,x:61.509,y:50.027,fill:"#CBD0D3",rx:3.557})),E||(E=n.createElement("rect",{width:7.115,height:7.115,x:72.181,y:50.027,fill:"#CBD0D3",rx:3.557})),M||(M=n.createElement("rect",{width:125.396,height:42.688,x:164,y:78.486,fill:"#EBEEF0",rx:5.585})),T||(T=n.createElement("rect",{width:92.49,height:14.229,x:164,y:129,fill:"#EBEEF0",rx:7.115})),C||(C=n.createElement("rect",{width:108.498,height:5.585,x:164,y:151,fill:"#EBEEF0",rx:2.793})),D||(D=n.createElement("rect",{width:92.49,height:5.585,x:164,y:165,fill:"#EBEEF0",rx:2.793})),R||(R=n.createElement("rect",{width:125.396,height:5.585,x:164,y:179,fill:"#EBEEF0",rx:2.793})),O||(O=n.createElement("g",{filter:"url(#ad-blocking-recovery-setup_svg__b)"},n.createElement("path",{fill:"#fff",d:"M199 163c0-6.075 4.925-11 11-11h126c6.075 0 11 4.925 11 11v83.038c0 6.076-4.925 11-11 11H210c-6.075 0-11-4.924-11-11z"}),n.createElement("path",{stroke:"#CBD0D3",d:"M199.5 163c0-5
(0,l.__)("Site Kit detected AdSense code for a different account %1$s on your site. In order to configure AdSense for your current account %2$s, we recommend you use Site Kit to place the code instead.","google-site-kit"),(0,ie.c)(t),(0,ie.c)(i)),a=`${g} ${d}`):a=d,(0,v.jsx)(ne.TZ,{checkedMessage:a,uncheckedMessage:g,saveOnChange:!0})}var se=i(79257),oe=i(93431),re=i(81779),ae=i(61991);function SetupAccountSiteUI({heading:e,description:t,primaryButton:i,secondaryButton:s}){const o=(0,c.useSelect)(e=>e($.wl).isDoingSubmitChanges()||e(Y.M).isNavigating());return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(x.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-setup-module__title",children:e}),(0,v.jsx)(ne.kg,{}),(0,v.jsx)(p.A,{children:t}),(0,v.jsx)(SetupUseSnippetSwitch,{}),(0,v.jsxs)("div",{className:"googlesitekit-setup-module__action",children:[(0,v.jsx)(g.SpinnerButton,{onClick:i.onClick,href:i.href,disabled:o,isSaving:o,children:i.label}),s&&(0,v.jsx)("div",{className:"googlesitekit-setup-module__sub-action",children:(0,v.jsx)(g.Button,{onClick:s.onClick,tertiary:!0,children:s.label})})]})]})}function NeedsAttention(){const e=(0,n.useContext)(ae.Ay),t=(0,c.useSelect)(e=>e($.wl).getServiceAccountManageSitesURL()),s=(0,n.useCallback)(n=>{n.preventDefault(),(0,Z.sx)(`${e}_adsense`,"review_site_state","needs_attention"),i.g.open(t,"_blank")},[t,e]),o=(0,l.__)("Your site isnt ready to show ads yet","google-site-kit"),r=(0,l.__)("You need to fix some things with this site before we can connect Site Kit to your AdSense account","google-site-kit"),a={label:(0,l.__)("Review site in AdSense","google-site-kit"),href:t,onClick:s};return(0,v.jsx)(SetupAccountSiteUI,{heading:o,description:r,primaryButton:a})}function GettingReady(){const e=(0,n.useContext)(ae.Ay),t=(0,c.useSelect)(e=>e($.wl).getServiceAccountManageSitesURL()),s=(0,n.useCallback)(n=>{n.preventDefault(),(0,Z.sx)(`${e}_adsense`,"review_site_state","getting_ready"),i.g.open(t,"_blank")},[t,e]),o=(0,l.__)("Your site is getting ready","google-site-kit"),r=(0,l.__)("This usually takes a few days, but in some cases can take a few weeks. Youll get an email from AdSense as soon as they have run some checks on your site.","google-site-kit"),a={label:(0,l.__)("Review site in AdSense","google-site-kit"),href:t,onClick:s};return(0,v.jsx)(SetupAccountSiteUI,{heading:o,description:r,primaryButton:a})}function RequiresReview(){const e=(0,n.useContext)(ae.Ay),t=(0,c.useSelect)(e=>e($.wl).getServiceAccountManageSitesURL()),s=(0,n.useCallback)(n=>{n.preventDefault(),(0,Z.sx)(`${e}_adsense`,"review_site_state","requires_review"),i.g.open(t,"_blank")},[t,e]),o=(0,l.__)("Your site requires review","google-site-kit"),r=(0,l.__)("To start serving ads, your site needs to be approved first. Go to AdSense to request the review.","google-site-kit"),a={label:(0,l.__)("Request review in AdSense","google-site-kit"),href:t,onClick:s};return(0,v.jsx)(SetupAccountSiteUI,{heading:o,description:r,primaryButton:a})}function Ready({site:e,finishSetup:t}){const[s,o]=(0,n.useState)(!1),r=(0,n.useContext)(ae.Ay),a=(0,c.useSelect)(e=>e($.wl).getExistingTag()),g=(0,c.useSelect)(e=>e($.wl).getServiceAccountSiteAdsPreviewURL()),d=(0,c.useSelect)(e=>e($.wl).isDoingSubmitChanges()),{completeSiteSetup:u,completeAccountSetup:p}=(0,c.useDispatch)($.wl),{setValue:h}=(0,c.useDispatch)(V.n),m=(0,n.useCallback)(e=>{e.preventDefault(),(0,Z.sx)(`${r}_adsense`,"enable_auto_ads"),i.g.open(g,"_blank")},[g,r]),f=(0,n.useCallback)(e=>{e.preventDefault(),(0,Z.sx)(`${r}_adsense`,"disable_auto_ads"),o(!0)},[r]),k=(0,n.useCallback)(async()=>{if(d)return;h($.O0,!0);const e=await u(),i=await p();h($.O0,!1),e&&i&&"function"==typeof t&&t()},[d,h,u,p,t]),_={};return e.autoAdsEnabled||s?(_.heading=a?(0,l.__)("Your AdSense account is ready to connect to Site Kit","google-site-kit"):(0,l.__)("Your site is ready to use AdSense","google-site-kit"),_.description=a?(0,l.__)("Connect your AdSense account to see stats on your overall earnings, page CTR, and top earning pages","google-site-kit"):(0,l.__)("Site Kit has placed AdSe
(0,l.__)("Invalid site state %s","google-site-kit"),s),skipRetryMessage:!0})}}SetupAccountSiteUI.propTypes={heading:m().string.isRequired,description:m().string.isRequired,primaryButton:m().shape({label:m().string,href:m().string,onClick:m().func}).isRequired,secondaryButton:m().shape({label:m().string,onClick:m().func})},SetupAccountSite.propTypes={site:m().shape({autoAdsEnabled:m().bool,state:m().string}).isRequired,finishSetup:m().func};var le=i(44174);function SetupAccountNoClient(){const e=(0,W.A)(),t=(0,n.useCallback)(()=>{(0,Z.sx)(`${e}_adsense`,"apply_afc")},[e]);return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(x.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-setup-module__title",children:(0,l.__)("Looks like you need to upgrade your AdSense account","google-site-kit")}),(0,v.jsx)(ne.kg,{}),(0,v.jsx)(p.A,{children:(0,ee.A)((0,l.__)("To start using AdSense on your website, you need to upgrade your account to add “AdSense for content”. <a>Learn more</a>","google-site-kit"),{a:(0,v.jsx)(le.A,{path:"/adsense/answer/6023158","aria-label":(0,l.__)("Learn more about updating your AdSense account","google-site-kit"),external:!0})})}),(0,v.jsx)("div",{className:"googlesitekit-setup-module__action",children:(0,v.jsx)(g.Button,{href:"https://www.google.com/adsense",target:"_blank","aria-label":(0,l.__)("Learn more about updating your AdSense account","google-site-kit"),onClick:t,children:(0,l.__)("Apply now","google-site-kit")})})]})}function SetupAccountCreateSite(){const e=(0,W.A)(),t=(0,c.useSelect)(e=>e($.wl).getServiceAccountManageSiteURL()),s=(0,n.useCallback)(n=>{n.preventDefault(),(0,Z.sx)(`${e}_adsense`,"create_site"),i.g.open(t,"_blank")},[t,e]);return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(x.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-setup-module__title",children:(0,l.__)("Add this site to your AdSense account","google-site-kit")}),(0,v.jsx)(ne.kg,{}),(0,v.jsx)(p.A,{children:(0,l.__)("Weve detected that you havent added this site to your AdSense account yet","google-site-kit")}),(0,v.jsx)("div",{className:"googlesitekit-setup-module__action",children:(0,v.jsx)(g.Button,{onClick:s,href:t,children:(0,l.__)("Add site to AdSense","google-site-kit")})})]})}function SetupAccountPendingTasks(){const e=(0,W.A)(),t=(0,n.useCallback)(()=>{(0,Z.sx)(`${e}_adsense`,"review_tasks")},[e]),i=(0,c.useSelect)(e=>e($.wl).getServiceAccountURL());return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(x.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-setup-module__title",children:(0,l.__)("Your account isnt ready to show ads yet","google-site-kit")}),(0,v.jsx)(ne.kg,{}),(0,v.jsx)(p.A,{children:(0,l.__)("You need to fix some things before we can connect Site Kit to your AdSense account","google-site-kit")}),(0,v.jsx)(SetupUseSnippetSwitch,{}),(0,v.jsx)("div",{className:"googlesitekit-setup-module__action",children:(0,v.jsx)(g.Button,{onClick:t,href:i,children:(0,l.__)("Review AdSense account","google-site-kit")})})]})}function SetupAccount({account:e,finishSetup:t}){const{_id:i,state:s}=e,o=(0,c.useSelect)(e=>e($.wl).getClientID()),r=(0,c.useSelect)(e=>e($.wl).getCurrentSite(i)),a=(0,c.useSelect)(e=>e($.wl).getAFCClient(i)),{setClientID:l,setAccountStatus:d,setSiteStatus:u}=(0,c.useDispatch)($.wl);return(0,n.useEffect)(()=>{a?._id&&o!==a._id?l(a._id):null===a&&o&&l("")},[a,o,l]),(0,n.useEffect)(()=>{null===r&&u(re.SG)},[u,r]),(0,n.useEffect)(()=>{void 0!==r&&(o?s===$._L?d(re.gV):a?.state===$.LE?d(re.bF):a?.state===$.IY?d(re.Yb):d(re.pJ):d(re.ze))},[s,a,o,d,r]),void 0===r?(0,v.jsx)(g.ProgressBar,{}):o?null===r?(0,v.jsx)(SetupAccountCreateSite,{}):s===$._L||a?.state===$.LE||a?.state===$.IY?(0,v.jsx)(SetupAccountPendingTasks,{}):(0,v.jsx)(SetupAccountSite,{site:r,finishSetup:t}):(0,v.jsx)(SetupAccountNoClient,{})}SetupAccount.propTypes={account:m().shape({_id:m().string,state:m().string}),finishSetup:m().func};var ce=i(58116);function SetupCreateAccount(){const e=`${(0,W.A)()}_adsense`,t=(0,c.useSelect)(e=>e(ce.oR).getEmail()),s=(0,c.useSelect)(e=>e($.wl).getExistingTag()),o=(0,c.
(0,l.__)("Site Kit detected AdSense code %1$s on your page. We recommend you remove that code or add %2$s as a user to the AdSense account %3$s.","google-site-kit"),s,t,(0,ie.c)(s)),!s&&(0,ee.A)((0,l.sprintf)(/* translators: %s: user email address */ /* translators: %s: user email address */
(0,l.__)("Already use AdSense? Add %s as a user to an existing AdSense account. <a>Learn more</a>","google-site-kit"),t),{a:(0,v.jsx)(le.A,{path:"/adsense/answer/2659101","aria-label":(0,l.__)("Learn more about adding a user to an existing AdSense account","google-site-kit"),external:!0})})]})]})}function SetupSelectAccount(){return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(x.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-setup-module__title",children:(0,l.__)("Select your AdSense account","google-site-kit")}),(0,v.jsx)(ne.kg,{}),(0,v.jsx)(p.A,{children:(0,l.__)("Looks like you have multiple AdSense accounts associated with your Google account. Select the account to use with Site Kit below.","google-site-kit")}),(0,v.jsx)("div",{className:"googlesitekit-setup-module__inputs",children:(0,v.jsx)(ne.QB,{})})]})}var ge=i(10804),de=i(42125);function SetupMain_SetupMain({finishSetup:e}){const t=`${(0,W.A)()}_adsense`,{resetAccounts:i,resetClients:s,resetSites:o,setAccountID:r,setAccountStatus:a,submitChanges:d}=(0,c.useDispatch)($.wl),[u,p]=(0,n.useState)(!1),[h,m]=(0,n.useState)(!1),f=(0,c.useSelect)(e=>!!e(V.n).getValue($.O0)),k=(0,c.useSelect)(e=>e(ce.oR).isAdBlockerActive()),_=(0,c.useSelect)(e=>e($.wl).getAccounts()),y=(0,c.useSelect)(e=>e($.wl).getAccountID()),b=(0,c.useSelect)(e=>e($.wl).hasSettingChanged("accountID")),S=(0,c.useSelect)(e=>e($.wl).hasSettingChanged("clientID")),A=(0,c.useSelect)(e=>e($.wl).canSubmitChanges()),j=(0,c.useSelect)(e=>e($.wl).getClientID()),N=(0,c.useSelect)(e=>e($.wl).getAccountStatus()),I=(0,c.useSelect)(e=>e($.wl).hasSettingChanged("accountStatus")),w=(0,c.useSelect)(e=>e($.wl).getSiteStatus()),E=(0,c.useSelect)(e=>e($.wl).hasSettingChanged("siteStatus")),M=(0,c.useSelect)(e=>e($.wl).hasErrors()),T=(0,c.useSelect)(e=>e($.wl).hasFinishedResolution("getAccounts")),C=(0,c.useSelect)(e=>e(ce.oR).getEmail()),D=(0,c.useSelect)(e=>e(F.O4).getReferenceSiteURL()),R=(0,c.useSelect)(e=>e($.wl).getExistingTag()),O=_?.find(({_id:e})=>e===y);(0,se.A)(()=>{(b&&void 0!==y||S&&void 0!==j||I&&void 0!==N||E&&void 0!==w)&&p(!0)},[y,b,j,S,N,I,w,E]),(0,n.useEffect)(()=>{if(!Array.isArray(_))return;let e;1!==_.length||y&&_[0]._id===y?0===_.length&&y&&(e=""):e=_[0]._id,void 0!==e&&(r(e),p(!0))},[_,y,r]),(0,n.useEffect)(()=>{0===_?.length?a(re.uP):_?.length>1&&!y&&a(re.Sw)},[a,y,_]),(0,n.useEffect)(()=>{u&&!h&&A&&!f&&(p(!1),(async()=>{m(!0),await d(),m(!1)})())},[u,h,A,d,f]);const L=(0,n.useCallback)(()=>{void 0!==N&&re.pJ!==N&&(i(),s(),o())},[N,i,s,o]);let z;return(0,de.$)(L,15e3),(0,n.useEffect)(()=>{void 0!==N&&(0,Z.sx)(t,"receive_account_state",N)},[t,N]),(0,n.useEffect)(()=>{void 0!==w&&(0,Z.sx)(t,"receive_site_state",w)},[t,w]),z=T&&void 0!==y&&void 0!==C&&void 0!==D&&void 0!==R?M?(0,v.jsx)(ne.kg,{hasButton:!0}):_?.length?y?(0,v.jsx)(SetupAccount,{account:O,finishSetup:e}):(0,v.jsx)(SetupSelectAccount,{}):(0,v.jsx)(SetupCreateAccount,{}):(0,v.jsx)(g.ProgressBar,{}),(0,v.jsxs)("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense",children:[(0,v.jsxs)("div",{className:"googlesitekit-setup-module__step",children:[(0,v.jsx)("div",{className:"googlesitekit-setup-module__logo",children:(0,v.jsx)(oe.A,{width:"40",height:"40"})}),(0,v.jsx)(x.A,{as:"h3",className:"googlesitekit-setup-module__title",size:"small",type:"headline",children:(0,l._x)("AdSense","Service name","google-site-kit")})]}),(0,v.jsxs)("div",{className:"googlesitekit-setup-module__step",children:[(0,v.jsx)(ge.A,{moduleSlug:"adsense"}),!k&&z]})]})}SetupMain_SetupMain.propTypes={finishSetup:m().func}},47121:(e,t,i)=>{i.d(t,{$C:()=>I,RF:()=>N,WI:()=>A,_5:()=>x,jU:()=>v,o3:()=>y,x0:()=>S});var n=i(32091),s=i.n(n),o=i(50532),r=i.n(o),a=i(17243),l=i(78913);const c="GET_REGISTRY",g="AWAIT";function d(...e){const t=e.reduce((e,t)=>({...e,...t}),{}),i=b(e.reduce((e,t)=>[...e,...Object.keys(t)],[]));return s()(0===i.length,`collect() cannot accept collections with duplicate keys. Your call to collect() contains the following duplicated functions: ${i.join(", ")}. Check your data stores for duplicates.`),t}const u=d
(0,n.__)("Your Google account does not have sufficient permissions to access %s data, so you wont be able to see stats from it on the Site Kit dashboard.","google-site-kit"),r)),a&&a.login&&(c=(0,n.sprintf)(/* translators: %s: owner name */ /* translators: %s: owner name */
(0,n.__)('This service was originally connected by the administrator "%s" — you can contact them for more information.',"google-site-kit"),a.login)),c||(c=(0,n.__)("This service was originally connected by an administrator — you can contact them for more information.","google-site-kit")),`${l} ${c}`}},67150:(e,t,i)=>{i.d(t,{G:()=>c,HY:()=>d,SG:()=>g,db:()=>s,e4:()=>p,vl:()=>u});i(17243);var n=i(82871);const s="missing_required_scopes",o="insufficientPermissions",r="forbidden",a="internal_server_error",l="invalid_json";function c(e){return e?.code===s}function g(e){return[o,r].includes(e?.data?.reason)}function d(e){return!!e?.data?.reconnectURL}function u(e,t){return!(!t?.storeName||g(e)||c(e)||d(e))}function p(e){return e?.code===a?(0,n.__)("There was a critical error on this website while fetching data","google-site-kit"):e?.code===l?(0,n.__)("The server provided an invalid response","google-site-kit"):e?.message}},68869:(e,t,i)=>{i.d(t,{Ay:()=>r});var n=i(6732);const{Consumer:s,Provider:o}=n.A,r=o},71032:(e,t,i)=>{i.d(t,{A:()=>c});var n=i(62688),s=i.n(n),o=i(63696),r=i(82871),a=i(77967),l=i(62540);class MediaErrorHandler extends o.Component{constructor(e){super(e),this.state={error:null}}componentDidCatch(e,t){i.g.console.error("Caught an error:",e,t),this.setState({error:e})}render(){const{children:e,errorMessage:t}=this.props,{error:i}=this.state;return i?(0,l.jsx)(a.A,{message:t}):e}}MediaErrorHandler.defaultProps={errorMessage:(0,r.__)("Failed to load media","google-site-kit")},MediaErrorHandler.propTypes={children:s().node.isRequired,errorMessage:s().string.isRequired};const c=MediaErrorHandler},71423:(e,t,i)=>{i.d(t,{$:()=>o,D:()=>s});var n=i(24558);const s="core/notifications",o=[n.uR,n.jU,n.f7,n.Ax,n.Is]},72455:(e,t,i)=>{i.d(t,{CV:()=>I,Cu:()=>b,K9:()=>n,Kr:()=>m,Lf:()=>p,Oh:()=>r,PW:()=>N,Rx:()=>C,S9:()=>f,TQ:()=>d,Vt:()=>M,Wl:()=>v,ZC:()=>s,ZY:()=>a,_p:()=>T,ag:()=>h,aj:()=>u,bz:()=>w,dq:()=>E,f2:()=>c,fB:()=>j,fV:()=>A,iB:()=>g,kc:()=>l,mo:()=>_,nc:()=>S,rm:()=>x,to:()=>o,wo:()=>k,yn:()=>y});const n="modules/analytics-4",s="account_create",o="property_create",r="webdatastream_create",a="analyticsSetup",l=10,c=1,g="https://www.googleapis.com/auth/tagmanager.readonly",d="enhanced-measurement-form",u="enhanced-measurement-enabled",p="enhanced-measurement-should-dismiss-activation-banner",h="analyticsAccountCreate",m="analyticsCustomDimensionsCreate",f="https://www.googleapis.com/auth/analytics.edit",k="dashboardAllTrafficWidgetDimensionName",_="dashboardAllTrafficWidgetDimensionColor",y="dashboardAllTrafficWidgetDimensionValue",v="dashboardAllTrafficWidgetActiveRowIndex",x="dashboardAllTrafficWidgetLoaded",b={googlesitekit_post_date:{parameterName:"googlesitekit_post_date",displayName:"WordPress Post Date",description:"Created by Site Kit: Date when a post was published",scope:"EVENT"},googlesitekit_post_author:{parameterName:"googlesitekit_post_author",displayName:"WordPress Post Author",description:"Created by Site Kit: WordPress name of the post author",scope:"EVENT"},googlesitekit_post_categories:{parameterName:"googlesitekit_post_categories",displayName:"WordPress Post Categories",description:"Created by Site Kit: Names of categories assigned to a post",scope:"EVENT"},googlesitekit_post_type:{parameterName:"googlesitekit_post_type",displayName:"WordPress Post Type",description:"Created by Site Kit: Content type of a post",scope:"EVENT"}},S={ADD_TO_CART:"add_to_cart",PURCHASE:"purchase",SUBMIT_LEAD_FORM:"submit_lead_form",GENERATE_LEAD:"generate_lead",CONTACT:"contact"},A=[S.CONTACT,S.GENERATE_LEAD,S.SUBMIT_LEAD_FORM],j={"new-visitors":{description:"People who visited the site for the first time",displayName:"New visitors",membershipDurationDays:-1,filterClauses:[{clauseType:"INCLUDE",simpleFilter:{scope:"AUDIENCE_FILTER_SCOPE_ACROSS_ALL_SESSIONS",filterExpression:{andGroup:{filterExpressions:[{orGroup:{filterExpressions:[{dimensionOrMetricFilter:{fieldName:"newVsReturning",stringFilter:{matchType:"EXACT",value:"new"}}}]}},{orGroup:{filterExpressions:[{notExpression:{dimensionOrMetricFilter:{fieldName
(0,r.__)("%s (Please try again.)","google-site-kit"),v)),p||(v=(0,r.sprintf)(/* translators: $%s: Error message */ /* translators: $%s: Error message */
(0,r.__)("Error: %s","google-site-kit"),v));const x=t?.data?.reconnectURL;x&&(0,a.m)(x)&&(v=(0,r.sprintf)(/* translators: 1: Original error message 2: Reconnect URL */ /* translators: 1: Original error message 2: Reconnect URL */
(0,r.__)('%1$s To fix this, <a href="%2$s">redo the plugin setup</a>.',"google-site-kit"),v,x));return(0,u.jsx)(g.A,{className:e,type:g.A.TYPES.ERROR,description:(0,u.jsx)("span",{dangerouslySetInnerHTML:(0,d.p9)(v,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})}),ctaButton:y?{label:(0,r.__)("Retry","google-site-kit"),onClick:_}:void 0,hideIcon:m})}ErrorNotice.propTypes={className:s().string,error:s().shape({message:s().string}),hasButton:s().bool,storeName:s().string,message:s().string,noPrefix:s().bool,skipRetryMessage:s().bool,hideIcon:s().bool}},78340:(e,t,i)=>{i.d(t,{s:()=>n});const n="core/forms"},79829:(e,t,i)=>{i.d(t,{Eo:()=>d,JK:()=>m,K5:()=>h,jq:()=>p,mK:()=>g});var n=i(17243),s=i(50532),o=i.n(s),r=i(82871);function a(e,t={}){const{formatUnit:i,formatDecimal:n}=function(e,t={}){const{hours:i,minutes:n,seconds:s}=l(e);return{hours:i,minutes:n,seconds:s,formatUnit(){const{unitDisplay:o="short",...a}=t,l={unitDisplay:o,...a,style:"unit"};return 0===e?p(s,{...l,unit:"second"}):(0,r.sprintf)(/* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */ /* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */
(0,r._x)("%3$s %2$s %1$s","duration of time: hh mm ss","google-site-kit"),s?p(s,{...l,unit:"second"}):"",n?p(n,{...l,unit:"minute"}):"",i?p(i,{...l,unit:"hour"}):"").trim()},formatDecimal(){const t=(0,r.sprintf)(
// translators: %s: number of seconds with "s" as the abbreviated unit.
// translators: %s: number of seconds with "s" as the abbreviated unit.
(0,r.__)("%ds","google-site-kit"),s);if(0===e)return t;const o=(0,r.sprintf)(
// translators: %s: number of minutes with "m" as the abbreviated unit.
// translators: %s: number of minutes with "m" as the abbreviated unit.
(0,r.__)("%dm","google-site-kit"),n),a=(0,r.sprintf)(
// translators: %s: number of hours with "h" as the abbreviated unit.
// translators: %s: number of hours with "h" as the abbreviated unit.
(0,r.__)("%dh","google-site-kit"),i);return(0,r.sprintf)(/* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */ /* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */
(0,r._x)("%3$s %2$s %1$s","duration of time: hh mm ss","google-site-kit"),s?t:"",n?o:"",i?a:"").trim()}}}(e,t);try{return i()}catch{return n()}}function l(e){e=parseInt(e,10),Number.isNaN(e)&&(e=0);return{hours:Math.floor(e/60/60),minutes:Math.floor(e/60%60),seconds:Math.floor(e%60)}}function c(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e}function g(e){let t={};return"%"===e?t={style:"percent",maximumFractionDigits:2}:"s"===e?t={style:"duration",unitDisplay:"narrow"}:e&&"string"==typeof e?t={style:"currency",currency:e}:(0,n.isPlainObject)(e)&&(t={...e}),t}function d(e,t={}){e=(0,n.isFinite)(e)?e:Number(e),(0,n.isFinite)(e)||(console.warn("Invalid number",e,typeof e),e=0);const i=g(t),{style:s="metric"}=i;return"metric"===s?function(e){const t={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?(0,r.sprintf)(
// translators: %s: an abbreviated number in millions.
// translators: %s: an abbreviated number in millions.
(0,r.__)("%sM","google-site-kit"),p(c(e),e%10==0?{}:t)):1e4<=e?(0,r.sprintf)(
// translators: %s: an abbreviated number in thousands.
// translators: %s: an abbreviated number in thousands.
(0,r.__)("%sK","google-site-kit"),p(c(e))):1e3<=e?(0,r.sprintf)(
// translators: %s: an abbreviated number in thousands.
// translators: %s: an abbreviated number in thousands.
(0,r.__)("%sK","google-site-kit"),p(c(e),e%10==0?{}:t)):p(e,{signDisplay:"never",maximumFractionDigits:1})}(e):"duration"===s?a(e,i):"durationISO"===s?function(e){let{hours:t,minutes:i,seconds:n}=l(e);return n=("0"+n).slice(-2),i=("0"+i).slice(-2),t=("0"+t).slice(-2),"00"===t?`${i}:${n}`:`${t}:${i}:${n}`}(e):p(e,i)}const u=o()(console.warn);function p(e,t={}){const{locale:i=m(),...n}=t;try{return new Intl.NumberFormat(i,n).format(e)}catch(t){u(`Site Kit numberFormat error: Intl.NumberFormat( ${JSON.stringify(i)}, ${JSON.stringify(n)} ).format( ${typeof e} )`,t.message)}const s={currencyDisplay:"narrow",currencySign:"accounting",style:"unit"},o=["signDisplay","compactDisplay"],r={};for(const[e,t]of Object.entries(n))s[e]&&t===s[e]||o.includes(e)||(r[e]=t);try{return new Intl.NumberFormat(i,r).format(e)}catch{return new Intl.NumberFormat(i).format(e)}}function h(e,t={}){const{locale:i=m(),style:n="long",type:s="conjunction"}=t;if(Intl.ListFormat){return new Intl.ListFormat(i,{style:n,type:s}).format(e)}
/* translators: used between list items, there is a space after the comma. */const o=(0,r.__)(", ","google-site-kit");return e.join(o)}function m(e=i.g){const t=(0,n.get)(e,["_googlesitekitLegacyData","locale"]);if(t){const e=t.match(/^(\w{2})?(_)?(\w{2})/);if(e&&e[0])return e[0].replace(/_/g,"-")}return e.navigator.language}},80035:(e,t,i)=>{i.d(t,{A:()=>y});var n,s=i(62688),o=i.n(s),r=i(4452),a=i.n(r),l=i(63696),c=i(19793);function g(){return g=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},g.apply(null,arguments)}const warning_notice=e=>l.createElement("svg",g({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},e),n||(n=l.createElement("path",{fill:"currentColor",d:"M12 1c6.075 0 11 4.925 11 11s-4.925 11-11 11S1 18.075 1 12 5.925 1 12 1m0 14a1.5 1.5 0 1 0 0 3 1.5 1.5 0 0 0 0-3m-1-2h2V6h-2z"})));var d=i(42343),u=i(49655),p=i(62540);const h={[u.Q.NEW]:d.A,[u.Q.SUCCESS]:c.A,[u.Q.INFO]:warning_notice,[u.Q.WARNING]:warning_notice,[u.Q.ERROR]:warning_notice};function Icon({type:e}){const t=h[e]||warning_notice;return(0,p.jsx)(t,{width:24,height:24})}function Title({className:e,children:t}){return(0,p.jsx)("p",{className:a()("googlesitekit-notice__title",e),children:t})}function Description({className:e,children:t}){return(0,p.jsx)("p",{className:a()("googlesitekit-notice__description",e),children:t})}Icon.propTypes={type:o().oneOf(Object.values(u.Q))},Title.propTypes={className:o().string,children:o().node},Description.propTypes={className:o().string,children:o().node};var m=i(49383),f=i(83366);function CTAButton({label:e,disabled:t,inProgress:i,onClick:n,href:s,external:o=!1,hideExternalIndicator:r=!1}){let a;return o&&!r&&(a=(0,p.jsx)(f.A,{width:14,height:14})),(0,p.jsx)(m.SpinnerButton,{className:"googlesitekit-notice__cta",disabled:t,isSaving:i,onClick:n,href:s,target:o?"_blank":void 0,trailingIcon:a,children:e})}CTAButton.propTypes={label:o().string.isRequired,disabled:o().bool,inProgress:o().bool,onClick:o().func,href:o().string,external:o().bool,hideExternalIndicator:o().bool};var k=i(82871);function DismissButton({label:e=(0,k.__)("Got it","google-site-kit"),onClick:t,disabled:i}){return(0,p.jsx)(m.Button,{onClick:t,disabled:i,tertiary:!0,children:e})}DismissButton.propTypes={label:o().string,onClick:o().func.isRequired,disabled:o().bool};const _=(0,l.forwardRef)(({className:e,title:t,description:i,dismissButton:n,ctaButton:s,type:o=u.Q.INFO,children:r,hideIcon:l},c)=>(0,p.jsxs)("div",{ref:c,className:a()("googlesitekit-notice",`googlesitekit-notice--${o}`,e),children:[!l&&(0,p.jsx)("div",{className:"googlesitekit-notice__icon",children:(0,p.jsx)(Icon,{type:o})}),(0,p.jsxs)("div",{className:"googlesitekit-notice__content",children:[t&&(0,p.jsx)(Title,{children:t}),i&&(0,p.jsx)(Description,{children:i})]}),(n?.label||n?.onClick||s?.label&&(s?.onClick||s?.href)||r)&&(0,p.jsxs)("div",{className:"googlesitekit-notice__action",children:[r,(n?.label||n?.onClick)&&(0,p.jsx)(DismissButton,{label:n.label,onClick:n.onClick,disabled:n.disabled}),s?.label&&(s?.onClick||s?.href)&&(0,p.jsx)(CTAButton,{label:s.label,onClick:s.onClick,inProgress:s.inProgress,disabled:s.disabled,href:s.href,external:s.external,hideExternalIndicator:s.hideExternalIndicator})]})]}));_.TYPES=u.Q,_.propTypes={className:o().string,title:o().oneOfType([o().string,o().object]),description:o().node,type:o().oneOf(Object.values(u.Q)),dismissButton:o().shape(DismissButton.propTypes),ctaButton:o().shape({...CTAButton.propTypes,label:o().string}),children:o().node,hideIcon:o().bool};const y=_},81779:(e,t,i)=>{i.d(t,{DZ:()=>b,RL:()=>x,SG:()=>v,Sw:()=>u,TF:()=>_,Uv:()=>h,X_:()=>o,Yb:()=>g,ZT:()=>r,bF:()=>c,dL:()=>f,f8:()=>n,gV:()=>a,iP:()=>s,k:()=>m,oC:()=>k,pJ:()=>l,uP:()=>d,um:()=>y,ze:()=>p});const n="disapproved",s="graylisted",o="pending",r="approved",a="needs-attention",l="ready",c="client-requires-review",g="client-getting-ready",d="none",u="multiple",p="no-client",h="added",m="needs-attention",f="requires-review",k="
(0,l.__)("Source: %s","google-site-kit"),`<a>${e}</a>`),{a:(0,d.jsx)(c.A,{href:t,external:n},"link")})})}SourceLink.propTypes={name:s().string,href:s().string,className:s().string,external:s().bool},SourceLink.defaultProps={name:"",href:"",className:"",external:!1};const u=SourceLink},93431:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var n,s=i(63696);function o(){return o=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},o.apply(null,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>s.createElement("svg",o({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 173 152"},e),n||(n=s.createElement("g",{fill:"none",fillRule:"evenodd"},s.createElement("path",{fill:"#FBBC04",d:"M107.91 41.72c7.73-13.22 3.14-30.12-10.24-37.75S67.18.87 59.45 14.09c-.35.59-.66 1.2-.96 1.81l-26.1 44.66q-.435.66-.84 1.35c-.27.46-.52.93-.76 1.4L3.67 110.1l48.45 27.16 26.98-46.4q.435-.66.84-1.35c.27-.46.52-.93.76-1.39l26.11-44.67c.38-.57.76-1.14 1.1-1.73"}),s.createElement("path",{fill:"#34A853",d:"M52.34 137.11c-7.68 13.43-25 18.38-38.31 10.62s-18.02-24.57-10.34-38 24.86-18.39 38.16-10.64 18.18 24.59 10.49 38.02"}),s.createElement("path",{fill:"#4285F4",d:"M158.79 51.86c-13.23-7.62-30.15-3.1-37.79 10.1l-27.66 47.8c-7.64 13.2-3.11 30.08 10.13 37.7 13.23 7.62 30.15 3.1 37.79-10.1l27.66-47.8c7.63-13.2 3.1-30.08-10.13-37.7"}))))},93896:(e,t,i)=>{i.d(t,{O4:()=>n,OQ:()=>o,qc:()=>s});const n="core/site",s="primary",o="secondary"},94552:(e,t,i)=>{i.d(t,{A:()=>l});var n=i(62688),s=i.n(n),o=i(4452),r=i.n(o),a=i(62540);function ChangeArrow({direction:e,invertColor:t,width:i,height:n}){return(0,a.jsx)("svg",{className:r()("googlesitekit-change-arrow",`googlesitekit-change-arrow--${e}`,{"googlesitekit-change-arrow--inverted-color":t}),width:i,height:n,viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsx)("path",{d:"M5.625 10L5.625 2.375L9.125 5.875L10 5L5 -1.76555e-07L-2.7055e-07 5L0.875 5.875L4.375 2.375L4.375 10L5.625 10Z",fill:"currentColor"})})}ChangeArrow.propTypes={direction:s().string,invertColor:s().bool,width:s().number,height:s().number},ChangeArrow.defaultProps={direction:"up",invertColor:!1,width:9,height:9};const l=ChangeArrow},95267:(e,t,i)=>{i.d(t,{A:()=>PageHeader});var n=i(4452),s=i.n(n),o=i(62688),r=i.n(o),a=i(55527),l=i(24560),c=i(18418),g=i(84385),d=i(15167),u=i(62540);function PageHeader(e){const{title:t,icon:i,className:n,status:o,statusText:r,fullWidth:p,children:h}=e,m=p?{size:12}:{smSize:4,mdSize:4,lgSize:6},f=""!==o||Boolean(h);return(0,u.jsx)("header",{className:"googlesitekit-page-header",children:(0,u.jsxs)(a.fI,{children:[t&&(0,u.jsxs)(a.fh,{...m,children:[i,(0,u.jsx)(d.A,{as:"h1",className:s()("googlesitekit-page-header__title",n),size:"medium",type:"title",children:t})]}),f&&(0,u.jsx)(a.fh,{smSize:4,mdSize:4,lgSize:6,alignBottom:!0,mdAlignRight:!0,children:(0,u.jsxs)("div",{className:"googlesitekit-page-header__details",children:[o&&(0,u.jsxs)("span",{className:s()("googlesitekit-page-header__status",`googlesitekit-page-header__status--${o}`),children:[r,(0,u.jsx)(g.A,{children:"connected"===o?(0,u.jsx)(l.A,{width:10,height:8}):(0,u.jsx)(c.A,{width:2,height:12})})]}),h]})})]})})}PageHeader.propTypes={title:r().string,icon:r().node,className:r().string,status:r().string,statusText:r().string,fullWidth:r().bool},PageHeader.defaultProps={title:"",icon:null,className:"googlesitekit-heading-3",status:"",statusText:"",fullWidth:!1}},97398:(e,t,i)=>{i.d(t,{Y:()=>n});const n="search-console"},99235:(e,t,i)=>{i.d(t,{l:()=>s});var n=i(78174);function s(e,t,i){(0,n.A)(i=>e.includes(i.keyCode)&&t.current.contains(i.target),i)}},99455:(e,t,i)=>{i.d(t,{A:()=>d});var n,s=i(82871),o=i(88933),r=i(63696);function a(){return a=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var n in i)({}).hasOwnProperty.call(i,n)&&(e[n]=i[n])}return e},a.apply(null,arguments)}const l=e=>r.createElement("svg",a({xmlns:"http://www.w3.org/2000/svg",fill:"none",v