kollapsminoriteten/wp-content/plugins/google-site-kit/dist/assets/js/googlesitekit-settings-3a2e...

61 lines
422 KiB
JavaScript
Raw Normal View History

2025-12-12 13:13:07 +01:00
"use strict";(globalThis.__googlesitekit_webpackJsonp=globalThis.__googlesitekit_webpackJsonp||[]).push([[290,937],{133:(e,t,i)=>{i.d(t,{B:()=>s});i(72455);function s(e){return 400===e?.code&&e?.message?.includes("is not a valid dimension")}},674:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s,n,o=i(63696);function r(){return r=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},r.apply(null,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>o.createElement("svg",r({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 22 22"},e),s||(s=o.createElement("path",{fillRule:"evenodd",d:"m12.149 7.96-5.166 5.166a.34.34 0 0 0-.094.176l-.35 1.755a.344.344 0 0 0 .404.404l1.755-.35a.34.34 0 0 0 .175-.095l5.166-5.165zm2.301-1.814a1.03 1.03 0 0 0-1.458 0L6.497 12.64a1.03 1.03 0 0 0-.282.527l-.35 1.755a1.03 1.03 0 0 0 1.213 1.213l1.754-.35c.2-.04.383-.139.527-.283l6.495-6.494a1.03 1.03 0 0 0 0-1.459z",clipRule:"evenodd"})),n||(n=o.createElement("path",{d:"m12.149 7.96.117-.116a.165.165 0 0 0-.234 0zm-5.166 5.166-.116-.116zm-.094.176.162.033zm-.35 1.755.161.032zm.404.404.032.162zm1.755-.35.032.161zm.175-.095.117.117zm5.166-5.165.116.116a.165.165 0 0 0 0-.233zm-1.047-3.705.116.116zm1.458 0-.116.116zM6.497 12.64l.117.117zm-.282.527-.162-.032zm-.35 1.755.161.032zm1.213 1.213-.033-.162zm1.754-.35.033.161zm.527-.283.117.117zm6.495-6.494-.117-.117zm0-1.459.117-.116zm-3.822.295L6.867 13.01l.233.233 5.166-5.165zM6.867 13.01a.5.5 0 0 0-.14.26l.324.065a.2.2 0 0 1 .05-.092zm-.14.26-.35 1.754.323.065.351-1.755zm-.35 1.754a.51.51 0 0 0 .598.599l-.064-.324a.18.18 0 0 1-.21-.21zm.598.599 1.755-.35-.065-.325-1.754.351zm1.755-.35a.5.5 0 0 0 .26-.14l-.233-.233a.2.2 0 0 1-.092.048zm.26-.14 5.165-5.166-.233-.233L8.757 14.9zm3.042-7.055 1.89 1.89.233-.234-1.89-1.89zm1.076-1.816a.866.866 0 0 1 1.226 0l.233-.233a1.196 1.196 0 0 0-1.692 0zm-6.494 6.495 6.494-6.495-.233-.233-6.494 6.495zm-.237.443a.87.87 0 0 1 .237-.443l-.233-.233c-.167.167-.281.38-.328.61zm-.35 1.754.35-1.754-.324-.065-.35 1.755zm1.018 1.02a.866.866 0 0 1-1.019-1.02l-.323-.065a1.196 1.196 0 0 0 1.407 1.408zm1.755-.351-1.755.35.065.324 1.755-.35zm.443-.237a.87.87 0 0 1-.443.237l.065.323c.231-.046.444-.16.611-.327zm6.494-6.495-6.494 6.495.233.233 6.495-6.494zm0-1.225a.866.866 0 0 1 0 1.225l.234.234a1.196 1.196 0 0 0 0-1.692zm-1.403-1.404 1.403 1.404.234-.233-1.404-1.404z"})))},718:(e,t,i)=>{i.d(t,{gy:()=>SelectionPanelFooter,W4:()=>SelectionPanelHeader,y3:()=>SelectionPanelItem,DW:()=>SelectionPanelItems,Ay:()=>N});var s=i(4452),n=i.n(s),o=i(62688),r=i.n(o),a=i(4544),l=i.n(a),c=i(21795),g=i(78174),d=i(63696),u=i(19266),p=i(14007),m=i(62540);function SideSheet({className:e,children:t,isOpen:i,isLoading:s,onOpen:o=()=>{},closeSheet:r=()=>{},focusTrapOptions:a={}}){const h=(0,d.useRef)();return(0,d.useEffect)(()=>{i?(o(),document.body.classList.add("googlesitekit-side-sheet-scroll-lock")):document.body.classList.remove("googlesitekit-side-sheet-scroll-lock")},[i,o]),(0,c.A)(h,r),(0,g.A)(e=>i&&u._f===e.keyCode,r),(0,m.jsxs)(p.A,{children:[(0,m.jsx)(l(),{active:!!i&&!s,focusTrapOptions:{fallbackFocus:"body",...a},children:(0,m.jsx)("section",{ref:h,className:n()("googlesitekit-side-sheet",e,{"googlesitekit-side-sheet--open":i}),role:"dialog","aria-modal":"true","aria-hidden":!i,tabIndex:"0",children:t})}),i&&(0,m.jsx)("span",{className:"googlesitekit-side-sheet-overlay"})]})}function SelectionPanel({children:e,isOpen:t,isLoading:i,onOpen:s,closePanel:o,className:r}){const a=r?.split(/\s+/).map(e=>`.${e}`).join(""),l=a?`${a} .googlesitekit-selection-panel-item .googlesitekit-selection-box input`:".googlesitekit-selection-panel-item .googlesitekit-selection-box input";return(0,m.jsx)(SideSheet,{className:n()("googlesitekit-selection-panel",r),isOpen:t,isLoading:i,onOpen:s,closeSheet:o,focusTrapOptions:{initialFocus:l},children:e})}SideSheet.propTypes={className:r().string,children:r().node,isOpen:r().bool,isLoading:r().bool,onOpen:r().func,closeSheet:r().func,focus
(0,y.__)("%1$d selected <MaxCount>(up to %2$d)</MaxCount>","google-site-kit"),C,n),{MaxCount:(0,m.jsx)("span",{className:"googlesitekit-selection-panel-footer__item-count--max-count"})})});return(0,m.jsx)("footer",{className:"googlesitekit-selection-panel-footer",children:(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-footer__content",children:[T,(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-footer__actions",children:[(0,m.jsx)(k.Button,{onClick:S,disabled:o,tertiary:!0,children:(0,y.__)("Cancel","google-site-kit")}),(0,m.jsx)(k.SpinnerButton,{onClick:N,isSaving:o,disabled:C<s||C>n||o||!l&&p,children:g||v})]})]})})}SelectionPanelFooter.propTypes={savedItemSlugs:r().array,selectedItemSlugs:r().array,saveSettings:r().func,minSelectedItemCount:r().number,maxSelectedItemCount:r().number,isBusy:r().bool,onSaveSuccess:r().func,onCancel:r().func,isOpen:r().bool,closePanel:r().func};const N=SelectionPanel},1102:(e,t,i)=>{i.d(t,{w:()=>a});var s=i(35470),n=i(63696),o=i(2422);function r(){}function a(e,t){const i=(0,o.W)({sticky:!0}),a=(0,n.useRef)(),l=(0,n.useCallback)(e,t),c=(0,s.A)(i?l:r);return i&&(a.current=c),a.current}},2362:(e,t,i)=>{i.d(t,{A:()=>g});var s=i(4452),n=i.n(s),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,...s},o)=>(0,l.jsx)("span",{ref:o,...s,className:n()("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},2390:(e,t,i)=>{i.d(t,{A:()=>SpinnerButton,k:()=>g});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(25874),l=i(9341),c=i(62540);const g={BEFORE:"before",AFTER:"after"};function SpinnerButton(e){const{className:t,onClick:i=()=>{},isSaving:s=!1,spinnerPosition:n=g.AFTER,...o}=e;return(0,c.jsx)(a.A,{className:r()(t,"googlesitekit-button-icon--spinner",{"googlesitekit-button-icon--spinner__running":s,"googlesitekit-button-icon--spinner__before":n===g.BEFORE,"googlesitekit-button-icon--spinner__after":n===g.AFTER}),icon:s&&n===g.BEFORE?(0,c.jsx)(l.A,{size:14}):void 0,trailingIcon:s&&n===g.AFTER?(0,c.jsx)(l.A,{size:14}):void 0,onClick:i,...o})}SpinnerButton.propTypes={className:n().string,onClick:n().func,isSaving:n().bool,spinnerPosition:n().oneOf(Object.values(g))}},2422:(e,t,i)=>{i.d(t,{W:()=>l});var s=i(79257),n=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,n.A)(e=>e(a.n).getInViewResetCount()),g=(0,n.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,s.A)(()=>{l(!1)},[c]),!(!e||!i)||!!t.value}},2478:(e,t,i)=>{i.d(t,{A:()=>ChangeBadge});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(12850),l=i(62540);function ChangeBadge(e){const{previousValue:t,currentValue:i,isAbsolute:s}=e,n=s?i-t:(0,a.Zf)(t,i),o=n<0,c=0===n;return null===n?null:(0,l.jsx)("div",{className:r()("googlesitekit-change-badge",{"googlesitekit-change-badge--negative":o,"googlesitekit-change-badge--zero":c}),children:(0,a.Eo)(n,{style:"percent",signDisplay:"exceptZero",maximumFractionDigits:1})})}ChangeBadge.propTypes={isAbsolute:n().bool,previousValue:n().number.isRequired,currentValue:n().number.isRequired}},2522:(e,t,i)=>{i.d(t,{D:()=>o});var s=i(32091),n=i.n(s);function o(e,{dateRangeLength:t}){n()(Array.isArray(e),"report must be an array to partition."),n()(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)}}},3170:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s,n=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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},o.apply(null,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>n.createElement("svg",o({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 22 19"},e),s||(s=n.createElement("path",{fill:"currentColor",d:"M0 19h22L1
(0,a._n)("Select only %d answer","Select up to %d answers",s,"google-site-kit"),s)})}),(0,_.jsx)("div",{className:"googlesitekit-user-input__select-options",ref:M,children:C})]})}UserInputSelectOptions.propTypes={slug:n().string.isRequired,descriptions:n().shape({}),options:n().shape({}).isRequired,max:n().number,next:n().func,showInstructions:n().bool,alignLeftOptions:n().bool},UserInputSelectOptions.defaultProps={max:1,showInstructions:!1,alignLeftOptions:!1}},3714:(e,t,i)=>{i.d(t,{Kk:()=>o,SZ:()=>s,Yw:()=>r,oJ:()=>a,tT:()=>n});const s="body",n=[s,"display","headline","label","title"],o="small",r="medium",a=[o,r,"large"]},3782:(e,t,i)=>{i.d(t,{A:()=>CTAButton});var s=i(62688),n=i.n(s),o=i(49383),r=i(83366),a=i(62540);function CTAButton({label:e,ariaLabel:t,disabled:i,inProgress:s,onClick:n,href:l,external:c=!1,hideExternalIndicator:g=!1}){if(!e||!n&&!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||s,isSaving:s,onClick:n,href:l,target:c?"_blank":void 0,trailingIcon:d,children:e})}CTAButton.propTypes={label:n().string,ariaLabel:n().string,disabled:n().bool,inProgress:n().bool,onClick:n().func,href:n().string,dismissOnClick:n().bool,dismissOptions:n().shape({expiresInSeconds:n().number,skipHidingFromQueue:n().bool})}},4445:(e,t,i)=>{i.d(t,{A:()=>d});var s=i(62688),n=i.n(s),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 s=(0,o.useCallback)(()=>{setTimeout(()=>{const e=t?document.querySelector(t):g;e&&document.body.contains(e)&&e.focus(),t||(g=null)})},[t]),n=(0,r.A)(e);return(0,o.useEffect)(()=>(!0===n&&!1===e&&s(),()=>{s()}),[n,e,s]),(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:n().bool,refocusQuerySelector:n().string,...a.Dialog.propTypes};const d=RefocusableModalDialog},4884:(e,t,i)=>{i.d(t,{A:()=>d});var s=i(62688),n=i.n(s),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:s,ctaLink:n,ctaLabel:o,ctaLinkExternal:d,ctaType:u,error:p,onClick:m,"aria-label":h,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:"title",className:"googlesitekit-cta__title",children:e}),s&&"string"==typeof s&&(0,g.jsx)("p",{className:"googlesitekit-cta__description",children:s}),s&&"string"!=typeof s&&(0,g.jsx)("div",{className:"googlesitekit-cta__description",children:s}),o&&"button"===u&&(0,g.jsx)(a.Button,{"aria-label":h,href:n,onClick:m,children:o}),o&&"link"===u&&(0,g.jsx)(l.A,{href:n,onClick:m,"aria-label":h,external:d,hideExternalIndicator:d,arrow:!0,children:o}),f]})]})}CTA.propTypes={title:n().string.isRequired,headerText:n().string,description:n().oneOfType([n().string,n().node]),ctaLink:n().string,ctaLinkExternal:n().bool,ctaLabel:n().string,ctaType:n().string,"aria-label":n().string,error:n().bool,onClick:n().func,children:n().node,headerContent:n().node},CTA.defaultProps={title:"",headerText:"",headerContent:"",description:"",ctaLink:"",ctaLabel:"",ctaType:"link",error:!1,onClick:()=>{}};const d=CTA},6464:(e,t,i)=>{i.d(t,{i:()=>r});var s=i(63696),n=i(11106),o=i(65214);function r(e){const t=(0,s.useContext)(n.A);return(0,o.G)(e,t)}},6732:(e,t,i)=>{i.d(t,{A:()=>s
(0,c.__)("<strong>Note:</strong> %s","google-site-kit"),_),{strong:(0,u.jsx)("strong",{})})})]}),(0,u.jsxs)(g.DialogFooter,{children:[(0,u.jsx)(g.Button,{className:"mdc-dialog__cancel-button",onClick:i,disabled:k,tertiary:!0,children:(0,c.__)("Cancel","google-site-kit")}),A?(0,u.jsx)(g.Button,{href:A,onClick:m,target:"_blank",danger:y,children:f}):(0,u.jsx)(g.SpinnerButton,{onClick:m,danger:y,disabled:k,isSaving:k,children:f||(0,c.__)("Disconnect","google-site-kit")})]})]})}ModalDialog.displayName="Dialog",ModalDialog.propTypes={className:n().string,dialogActive:n().bool,handleDialog:n().func,handleConfirm:n().func.isRequired,onOpen:n().func,onClose:n().func,title:n().string,confirmButton:n().string,danger:n().bool,small:n().bool,medium:n().bool,buttonLink:n().string};const p=ModalDialog},9341:(e,t,i)=>{i.d(t,{A:()=>CircularProgress});var s=i(75762),n=i(62540);function CircularProgress(e){return(0,n.jsx)(s.A,{...e})}},9652:(e,t,i)=>{i.d(t,{A:()=>RecoverableModules});var s=i(62688),n=i.n(s),o=i(82871),r=i(50539),a=i(37226),l=i(4884),c=i(62540);function RecoverableModules({moduleSlugs:e}){const t=(0,r.useSelect)(t=>{const i=t(a.i).getModules();if(void 0!==i)return e.map(e=>i[e].name)});if(void 0===t)return null;const i=1===t.length?(0,o.sprintf)(/* translators: %s: Module name */ /* translators: %s: Module name */
(0,o.__)("%s data was previously shared by an admin who no longer has access. Please contact another admin to restore it.","google-site-kit"),t[0]):(0,o.sprintf)(/* translators: %s: List of module names */ /* translators: %s: List of module names */
(0,o.__)("The data for the following modules was previously shared by an admin who no longer has access: %s. Please contact another admin to restore it.","google-site-kit"),t.join((0,o._x)(", ","Recoverable modules","google-site-kit")));return(0,c.jsx)(l.A,{title:(0,o.__)("Data Unavailable","google-site-kit"),description:i})}RecoverableModules.propTypes={moduleSlugs:n().arrayOf(n().string).isRequired}},10072:(e,t,i)=>{i.d(t,{A:()=>ModuleIcon});var s=i(62688),n=i.n(s),o=i(50539),r=i(37226),a=i(62540);function ModuleIcon({slug:e,size:t,...i}){const s=(0,o.useSelect)(t=>t(r.i).getModuleIcon(e));return s?(0,a.jsx)(s,{width:t,height:t,...i}):null}ModuleIcon.propTypes={slug:n().string.isRequired,size:n().number},ModuleIcon.defaultProps={size:33}},10804:(e,t,i)=>{i.d(t,{A:()=>AdBlockerWarning});var s,n=i(62688),o=i.n(n),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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},p.apply(null,arguments)}const m=e=>u.createElement("svg",p({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 13 14"},e),s||(s=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 h=i(80035),f=i(62540);function AdBlockerWarningMessage({getHelpLink:e="",warningMessage:t=null}){return t?(0,f.jsx)(h.A,{className:"googlesitekit-notice--small",type:h.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)(m,{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)),s=(0,r.useSelect)(e=>e(i)?.getAdBlockerWarningMessage()),n=(0,r.useSelect)(t=>t(a.O4).getDocumentationLinkURL(`${e}-ad-blocker-detected`));return(0,f.jsx)(AdBlockerWarningMessage,{className:t,getHelpLink:n,warningMessage:s})}AdBlockerWarningMessage.propTypes={getHelpLink:o().string,warningMessage:o().string},AdBlockerWarning.propTypes={className:o().string,moduleSlug:o().string.isRequired}},10953:(e,t,i)=>{i.d(t,{A:()=>InfoTooltip});var s,n=i(4452),o=i.n(n),r=i(62688),a=i.n(r),l=i(49383),c=i(63696);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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},g.apply(null,arguments)}const d=e=>c.createElement("svg",g({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 16"},e),s||(s=c.createElement("path",{fill:"currentColor",d:"M7.334 11.333h1.333v-4H7.334zM8.001 6a.658.658 0 0 0 .667-.667.6.6 0 0 0-.2-.467.6.6 0 0 0-.467-.2.66.66 0 0 0-.667.667q0 .284.183.483A.7.7 0 0 0 8.001 6m0 8.666a6.6 6.6 0 0 1-2.6-.516 6.9 6.9 0 0 1-2.117-1.434A6.9 6.9 0 0 1 1.851 10.6 6.6 6.6 0 0 1 1.334 8q0-1.385.517-2.6a6.9 6.9 0 0 1 1.433-2.117q.9-.9 2.117-1.417A6.4 6.4 0 0 1 8 1.333q1.383 0 2.6.533a6.6 6.6 0 0 1 2.116 1.417q.9.9 1.417 2.117.533 1.215.533 2.6 0 1.383-.533 2.6a6.6 6.6 0 0 1-1.417 2.116 6.9 6.9 0 0 1-2.116 1.434 6.6 6.6 0 0 1-2.6.516m0-1.333q2.233 0 3.783-1.55T13.334 8t-1.55-3.784-3.783-1.55-3.784 1.55T2.667 8t1.55 3.783 3.784 1.55"})));var u=i(62540);function InfoTooltip({onOpen:e,title:t,tooltipClassName:i}){return t?(0,u.jsx)(l.Tooltip,{className:"googlesitekit-info-tooltip",tooltipClassName:o()("googlesitekit-info-tooltip__content",i),title:t,placement:"top",enterTouchDelay:0,leaveTouchDelay:5e3,onOpen:e,interactive:!0,children:(0,u.jsx)("span",{children:(0,u.jsx)(d,{width:"16",height:"16"})})}):null}InfoTooltip.propTypes={onOpen:a().func,title:a().oneOfType([a().string,a().element]),tooltipClassName:a().string}},11106:(e,t,i)=>{i.d(t,{A:()=>o});var s=i(63696),n=i(65214);const o=(0,s.createContext)(n.t)},11345:(e,t,i)=>{i.d(t,{A:()=>ReportError});var s=i(62688),n=i.n(s),o=i(17243),r=i(63696),a=i(82871),l=i(81375),c=i(50539),g=i(37226),d=i(67150),u=i(65311),p=i(15210),m=i(4884),h=i(35902),f=i(35323),_=i(77967),y=i(62540);function ReportError({moduleSlug:e,error:t}){const i=(0,f.A)(),s=(0,c.useSelect)(t=>t(g.i).getModule(e)),n=Array.isArray(t)?t:[t];let k;function v(e){return(0,d.SG)(e)?i?(k=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,a.__)("Access lost to %s","google-site-kit"),s?.name),(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,a.__)("The administrator sharing this module with you has lost access to the %s service, so you wont be able to see stats from it on the Site Kit dashboard. You can contact them or another administrator to restore access.","google-site-kit"),s?.name)):(k=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,a.__)("Insufficient permissions in %s","google-site-kit"),s?.name),(0,u.c)(e.message,s)):(0,d.e4)(e)}const x=(0,o.uniqWith)(n.map(e=>({...e,message:v(e),reconnectURL:e.data?.reconnectURL?(0,l.m)(e.data.reconnectURL,"code"):void 0})),(e,t)=>e.message===t.message&&e.reconnectURL===t.reconnectURL),A=n.some(e=>(0,d.SG)(e));A||1!==x.length?!A&&x.length>1&&(k=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,a.__)("Data errors in %s","google-site-kit"),s?.name)):k=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,a.__)("Data error in %s","google-site-kit"),s?.name);const j=(0,y.jsx)(r.Fragment,{children:x.map(e=>{const t=e?.data?.reconnectURL;return t?(0,y.jsx)(_.A,{error:e,message:e.message},e.message):(0,y.jsx)("p",{children:p.O.sanitize(e.message,{ALLOWED_TAGS:[]})},e.message)})});return(0,y.jsx)(m.A,{title:k,description:j,error:!0,children:(0,y.jsx)(h.A,{moduleSlug:e,error:t})})}ReportError.propTypes={moduleSlug:n().string.isRequired,error:n().oneOfType([n().arrayOf(n().object),n().object]).isRequired}},12108:(e,t,i)=>{i.d(t,{YJ:()=>o,Eq:()=>r});var s=i(32947),n=i(17243);function o(e,t){const s=document.querySelector(e);if(!s)return 0;const n=s.getBoundingClientRect().top,o=r(t);return n+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===s.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!==s.mp)return t.offsetHeight;return 0}(e);return t=function(e){return(0,n.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 s=i(62688),n=i.n(s),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),m=i(12850),h=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,m.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,h.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,h.jsxs)(a.Fragment,{children:[(0,h.jsx)(d.A,{message:t.message,componentStack:i.componentStack}),(0,h.jsxs)("pre",{className:"googlesitekit-overflow-auto",children:[t.message,i.componentStack]})]})}):e}}ErrorHandler.contextType=u.Ay,ErrorHandler.propTypes={children:n().node.isRequired};const f=ErrorHandler;var _=i(11106);const{Consumer:y,Provider:k}=_.A,v=k;var x=i(65214),A=i(4445),j=i(78340),I=i(45472),M=i(58116),b=i(64067),N=i(14007);const S=function AuthenticatedPermissionsModal(){const e=(0,l.useRegistry)(),t=(0,l.useSelect)(e=>e(M.oR).getPermissionScopeError()),s=(0,l.useSelect)(e=>e(M.oR).getUnsatisfiedScopes()),n=(0,l.useSelect)(e=>e(M.oR).getConnectURL({additionalScopes:t?.data?.scopes,redirectURL:t?.data?.redirectURL||i.g.location.href,errorRedirectURL:t?.data?.errorRedirectURL})),{clearPermissionScopeError:o}=(0,l.useDispatch)(M.oR),{navigateTo:r}=(0,l.useDispatch)(I.M),{setValues:c}=(0,l.useDispatch)(j.s),d=(0,a.useCallback)(()=>{o()},[o]),u=(0,a.useCallback)(async()=>{c(M.$8,{permissionsError:t}),await(0,b.mR)(e),r(n)},[e,n,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||s&&t?.data?.scopes.every(e=>s.includes(e))?null:(0,h.jsx)(N.A,{children:(0,h.jsx)(A.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 the PermissionsModal. permissionsError was:",t),null):null};const E=function PermissionsModal(){return(0,l.useSelect)(e=>e(M.oR).isAuthenticated())?(0,h.jsx)(S,{}):null};const w=function RestoreSnapshots({children:e}){const t=(0,l.useRegistry)(),[i,s]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{i||(async()=>{await(0,b.P9)(t),s(!0)})()},[t,i]),i?e:null};var C=i(15844
(0,g.__)("Google Account for %1$s (Email: %2$s)","google-site-kit"),n,i)),n&&!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"),n)),!n&&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,j.jsxs)(d.Fragment,{children:[(0,j.jsxs)("div",{ref:I,className:"googlesitekit-user-selector googlesitekit-dropdown-menu googlesitekit-dropdown-menu__icon-menu mdc-menu-surface--anchor",children:[(0,j.jsx)(_.Button,{disabled:r,ref:b,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:C,icon:!!s&&(0,j.jsx)("i",{className:"mdc-button__icon mdc-button__account","aria-hidden":"true",children:(0,j.jsx)("img",{className:"mdc-button__icon--image",src:s,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,j.jsxs)("span",{"aria-label":Z,children:[(0,j.jsx)("strong",{children:(0,g.__)("Google Account","google-site-kit")}),(0,j.jsx)("br",{}),(0,j.jsx)("br",{}),n,n&&(0,j.jsx)("br",{}),i]}),text:!0,tooltip:!0}),(0,j.jsxs)(_.Menu,{className:"googlesitekit-user-menu",menuOpen:c,onSelected:z,id:"user-menu",children:[(0,j.jsx)("li",{children:(0,j.jsx)(Details,{})}),e&&(0,j.jsx)("li",{id:"manage-email-reports",className:"mdc-list-item",role:"menuitem",children:(0,j.jsx)(Item,{icon:(0,j.jsx)(O,{width:"24"}),label:(0,g.__)("Manage email reports","google-site-kit")})}),!!t&&(0,j.jsx)("li",{id:"manage-sites",className:"mdc-list-item",role:"menuitem",children:(0,j.jsx)(Item,{icon:(0,j.jsx)(T,{width:"24"}),label:(0,g.__)("Manage Sites","google-site-kit")})}),(0,j.jsx)("li",{id:"disconnect",className:"mdc-list-item",role:"menuitem",children:(0,j.jsx)(Item,{icon:(0,j.jsx)(M,{width:"24"}),label:(0,g.__)("Disconnect","google-site-kit")})})]})]}),(0,j.jsx)(x.A,{children:(0,j.jsx)(y.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),Q=i(35323),q=i(29898),K=i(15844),$=i(39525),X=i(30521),J=i(24558),ee=i(73874),te=i(12108),ie=i(32947);var se=i(44949),ne=i(86134);const oe={[ee.Oo]:{[J.SH]:se.CONTEXT_MAIN_DASHBOARD_KEY_METRICS,[J.OT]:se.CONTEXT_MAIN_DASHBOARD_TRAFFIC,[J.en]:se.CONTEXT_MAIN_DASHBOARD_CONTENT,[J.Ej]:se.CONTEXT_MAIN_DASHBOARD_SPEED,[J.Gw]:se.CONTEXT_MAIN_DASHBOARD_MONETIZATION},[ee.oE]:{[J.OT]:se.CONTEXT_ENTITY_DASHBOARD_TRAFFIC,[J.en]:se.CONTEXT_ENTITY_DASHBOARD_CONTENT,[J.Ej]:se.CONTEXT_ENTITY_DASHBOARD_SPEED,[J.Gw]:se.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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},pe.apply(null,arguments)}const me=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 h
(0,g.__)("Shared by <strong>%s</strong>","google-site-kit"),s.login),{strong:(0,j.jsx)("strong",{title:s.login})})})]})}Service.propTypes={module:r().string.isRequired};var Pe=i(15167);function SharedServices(){const e=(0,u.useSelect)(e=>e(A.oR).getViewableModules());return void 0===e?null:(0,j.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,j.jsx)(Pe.A,{as:"h4",size:"large",type:"title",children:(0,g.__)("Shared services","google-site-kit")}),(0,j.jsx)("ul",{children:e.map(e=>(0,j.jsx)(Service,{module:e},e))})]})}var Be=i(82167);function Tracking(){const e=(0,F.A)();return(0,j.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,j.jsx)(we.A,{children:(0,Le.A)((0,g.__)("Thanks for using Site Kit!<br />Help us make it even better","google-site-kit"),{br:(0,j.jsx)("br",{})})}),(0,j.jsx)(Be.A,{trackEventCategory:`${e}_headerbar_viewonly`,alignCheckboxLeft:!0})]})}var Ue=i(74595);function ManageEmailReports(){const{setValue:e}=(0,Ue.wA)(B.n);return(0,j.jsxs)(d.Fragment,{children:[(0,j.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,j.jsx)("li",{className:"googlesitekit-view-only-menu__list-item googlesitekit-view-only-menu__email-reporting",children:(0,j.jsx)("ul",{className:"googlesitekit-view-only-menu",children:(0,j.jsx)("li",{className:"googlesitekit-view-only-menu__email-reporting-item",children:(0,j.jsx)(_.Button,{onClick:()=>e(V.Q,!0),icon:(0,j.jsx)("span",{className:"googlesitekit-view-only-menu__email-reporting-item--icon",children:(0,j.jsx)(O,{width:"24"})}),tertiary:!0,children:(0,j.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,Y.i)("proactiveUserEngagement"),[t,i]=(0,d.useState)(!1),s=(0,d.useRef)(),n=(0,F.A)();(0,m.A)(s,()=>i(!1)),(0,W.l)([f._f,f.wn],s,()=>i(!1));const o=(0,d.useCallback)(()=>{t||(0,k.sx)(`${n}_headerbar`,"open_viewonly"),i(!t)},[t,n]),r=(0,u.useSelect)(e=>e(A.oR).hasCapability(A.ej));return(0,j.jsxs)("div",{ref:s,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,j.jsx)(_.Button,{className:"googlesitekit-header__dropdown mdc-button--dropdown googlesitekit-border-radius-round--phone googlesitekit-button-icon",onClick:o,icon:(0,j.jsx)("span",{className:"mdc-button__icon","aria-hidden":"true",children:(0,j.jsx)(ze,{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,j.jsxs)(_.Menu,{menuOpen:t,onSelected:o,id:"view-only-menu",nonInteractive:!0,children:[(0,j.jsx)(Description,{}),(0,j.jsx)(SharedServices,{}),e&&(0,j.jsx)(ManageEmailReports,{}),(0,j.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,j.jsx)(Tracking,{})]})]})}var Ge=i(71423),Ve=i(53137),We=i(77513);function CoreSiteBannerNotification({id:e,...t}){const{dismissNotification:i,acceptNotification:s}=(0,u.useDispatch)(P.O4),n=(0,d.useCallback)(()=>{s(e)},[e,s]),o=(0,d.useCallback)(()=>{i(e)},[e,i]);return(0,j.jsx)(We.A,{onCTAClick:n,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 He=function CoreSiteBannerNotifications(){const e=(0,F.A)(),[t,i]=(0,d.useState)(!1),[s,n]=(0,d.useState)(!1),o=(0,d.useRef)(Date.now()),r=(0,u.useSelect)(e=>e(P.O4).isUsin
(0,k._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 S(e=""){if(!(0,s.isString)(e))return!1;if(3!==e.split("-").length)return!1;const t=new Date(e);return(0,s.isDate)(t)&&!isNaN(t)}function E(e){y()((0,s.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 w(e){y()(S(e),x);const[t,i,s]=e.split("-");return new Date(t,i-1,s)}function C(e,t){return E(D(e,t*M))}function T(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){y()(S(e)||(0,s.isDate)(e)&&!isNaN(e),x);const i=S(e)?Date.parse(e):e.getTime();return new Date(i-1e3*t)}var R=i(69743),z=i(94552),L=i(62540);function O(e,t={}){if(Number.isNaN(Number(e)))return"";const{invertColor:i=!1}=t;return(0,R.Ay)((0,L.jsx)(z.A,{direction:e>0?"up":"down",invertColor:i}))}function P(e,t){return e>0&&t>0?e/t-1:e>0?1:t>0?-1:0}var B=i(8143);function U(e){const t=parseFloat(e)||0;return!!Number.isInteger(t)&&t>0}function G(e){if("number"==typeof e)return!0;const t=(e||"").toString();return!!t&&!isNaN(t)}function V(e){return Array.isArray(e)?[...e].sort():e}var W=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 s=(t-e)/e;return Number.isNaN(s)||!Number.isFinite(s)?null:s}function H(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}}function Y(e){if(!e)return"";const t=e.replace(/&#(\d+);/g,(e,t)=>String.fromCharCode(t)).replace(/(\\)/g,"");return(0,s.unescape)(t)}},13465:(e,t,i)=>{i.d(t,{A:()=>ModuleSettingsWarning});var s=i(50539),n=i(37226),o=i(58116),r=i(10804),a=i(80035),l=i(62540);function ModuleSettingsWarning({slug:e}){const t=(0,s.useSelect)(t=>t(n.i)?.getCheckRequirementsError(e));return t?o.od===t.code?(0,l.jsx)(r.A,{moduleSlug:e}):(0,l.jsx)(a.A,{className:"googlesitekit-notice--small",type:a.A.TYPES.WARNING,description:t.message,hideIcon:!0}):null}},14007:(e,t,i)=>{i.d(t,{A:()=>l});var s=i(47209),n=i(62688),o=i.n(n),r=i(63696),a=i(78325);function Portal({children:e,slug:t}){const[i]=(0,r.useState)(document.createElement("div"));return(0,s.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},15135:(e,t,i)=>{i.d(t,{Gr:()=>r,We:()=>l,Y2:()=>a});var s=i(86134),n=i(73549),o=i(9652);const r={[s.N$.QUARTER]:3,[s.N$.HALF]:6,[s.N$.FULL]:12},a="googlesitekit-hidden",l=[n.A,o.A]},15167:(e,t,i)=>{i.d(t,{A:()=>Typography});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(3714),l=i(62540);function Typography({className:e,type:t,size:i,as:s="span",children:n,...o}){return(0,l.jsx)(s,{className:r()("googlesitekit-typography",e,{[`googlesitekit-typography--${t}`]:t&&a.tT.includes(t),[`googlesitekit-typography--${i}`]:i&&a.oJ.includes(i)}),...o,children:n})}Typography.propTypes={className:n().string,type:n().oneOf(a.tT),size:n().oneOf(a.oJ),as:n().oneOfType([n().string,n().elementType])}},15210:(e,t,i)=>{i.d(t,{O:()=>n});var s=i(31234);const n=i.n(s)()(i.g)},15577:(e,t,i)=>{i.d(t,{SO:()=>c});var s=i(55620),n=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,s._)("undefined"==typeof document?[l,c]:a,t,i);function u(){return d(a)}return(0,n.A)(r,"resize",u),(0,n.A)(r,"orientationchange",u),g}function c(e){return l(e)[0]}},15863:(e,t,i)=>{i.d(t,{i:()=>r});var s=i(63696),n=i(50539),o=i(7081);function r(e){const{setValue:t}=(0,n.useDispatch)(o.n);return(0,s.useCallback)(()=>{t("admin-screen-tooltip",{isToolt
(0,s.__)("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,s.sprintf)(/* translators: %s: owner name */ /* translators: %s: owner name */
(0,s.__)('This service was originally connected by the administrator "%s" — you can contact them for more information.',"google-site-kit"),a.login)),c||(c=(0,s.__)("This service was originally connected by an administrator — you can contact them for more information.","google-site-kit")),`${l} ${c}`}},66889:(e,t,i)=>{function s(e,t){const i=e.getBoundingClientRect(),s=t.getBoundingClientRect();return!(i.bottom<s.top||s.bottom<i.top||i.right<s.left||s.right<i.left)}i.d(t,{N:()=>s})},67150:(e,t,i)=>{i.d(t,{G:()=>c,HY:()=>d,SG:()=>g,db:()=>n,e4:()=>p,vl:()=>u});i(17243);var s=i(82871);const n="missing_required_scopes",o="insufficientPermissions",r="forbidden",a="internal_server_error",l="invalid_json";function c(e){return e?.code===n}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,s.__)("There was a critical error on this website while fetching data","google-site-kit"):e?.code===l?(0,s.__)("The server provided an invalid response","google-site-kit"):e?.message}},67768:(e,t,i)=>{i.d(t,{A:()=>SelectionPanelError});var s=i(62688),n=i.n(s),o=i(63696),r=i(66889),a=i(77967),l=i(62540);function SelectionPanelError({error:e,noPrefix:t=!0,skipRetryMessage:s=!0}){const n=(0,o.useRef)();return(0,o.useEffect)(()=>{if(e){const e=i.g.document.activeElement;e&&e.closest(".googlesitekit-selection-panel-item")&&(0,r.N)(n.current,e)&&e.scrollIntoView()}},[e]),e?(0,l.jsx)("div",{ref:n,children:(0,l.jsx)(a.A,{className:"googlesitekit-notice--square googlesitekit-selection-panel-error",error:e,noPrefix:t,skipRetryMessage:s})}):null}SelectionPanelError.propTypes={error:n().shape({message:n().string}),noPrefix:n().bool,skipRetryMessage:n().bool}},68485:(e,t,i)=>{i.d(t,{r:()=>AdminScreenTooltip,i:()=>s.i});var s=i(15863),n=i(63696),o=i(50539),r=i(62688),a=i(36703),l=i(40960),c=i(60592),g=i(14007),d=i(39771),u=i(32947),p=i(62540);function JoyrideTooltip(e){const{title:t,content:s,dismissLabel:o,disableOverlay:r=!0,target:m,cta:h=!1,className:f,styles:_={},slug:y="",placement:k="auto",onDismiss:v=()=>{},onView:x=()=>{},onTourStart:A=()=>{},onTourEnd:j=()=>{}}=e;function I(){return!!i.g.document.querySelector(m)}const[M,b]=(0,n.useState)(I),N=(0,u.dv)(),S=N===u.mp||N===u.Lg,[E,w]=(0,n.useState)(!0),C=(0,n.useRef)(S);if((0,l.A)(()=>{I()&&b(!0)},M?null:250),(0,n.useEffect)(()=>{let e=()=>{};if("function"==typeof i.g.ResizeObserver){const t=i.g.document.querySelector(m);if(t){const s=new ResizeObserver(()=>{i.g.dispatchEvent(new Event("resize"))});s.observe(t),e=()=>s.disconnect()}}return e},[m,M]),(0,n.useEffect)(()=>{let e;return C.current!==S&&(w(!1),e=setTimeout(()=>{w(!0)},50),C.current=S),()=>{e&&clearTimeout(e)}},[S]),!M)return null;const T=[{title:t,target:m,content:s,disableBeacon:!0,isFixed:!0,placement:k,cta:h,className:f}],D={close:o,last:o};return(0,p.jsx)(g.A,{slug:y,children:(0,p.jsx)(a.Ay,{callback:function({type:e}){switch(e){case a.qY.TOUR_START:A(),i.g.document.body.classList.add("googlesitekit-showing-tooltip");break;case a.qY.TOUR_END:j(),i.g.document.body.classList.remove("googlesitekit-showing-tooltip");break;case a.qY.STEP_AFTER:v();break;case a.qY.TOOLTIP:x()}},disableOverlay:r,spotlightPadding:0,floaterProps:d.ei,locale:D,steps:T,styles:{...d.R0,..._,options:{...d.R0.options,..._?.options},spotlight:{...d.R0.spotlight,..._?.spotlight}},tooltipComponent:c.A,run:E,disableScrolling:!0})})}JoyrideTooltip.propTypes={title:r.PropTypes.node,content:r.PropTypes.string,disableOverlay:r.PropTypes.bool,dismissLabel:r.PropTypes.string,target:r.PropTypes.string.isRequired,onDismiss:r.PropTypes.func,onShow:r.PropTypes.func,className:r.PropTypes.string,styles:r.PropTypes.object,slug:r.PropTypes.string,placement:r.PropTypes.string,onView:r.PropTypes.func};var m=i(7081),h=i(12850),f=i(77766);function AdminScreenTooltip(){const e=(0,f.A)(),{setValue:t}=(0,o.useDispatch)(m.n),i=(0,u.dv)(),{isTooltipVisible:s=!1,target:r,placement:a,className:l,tooltipSlug:c,title:g,content:d,dismissLabel:_}=(0,o.useSele
(0,o.__)("%s Gathering Data","google-site-kit"),t?.name),description:(0,o.sprintf)(/* translators: %s: Module name */ /* translators: %s: Module name */
(0,o.__)("%s data is not yet available, please check back later","google-site-kit"),t?.name)})}ReportZero.propTypes={moduleSlug:n().string.isRequired}},73589:(e,t,i)=>{i.d(t,{CX:()=>n,Py:()=>r,SM:()=>s,kj:()=>o});const s="adsense-connect-cta",n="adsense-connect-cta-tooltip-state",o="adsense-ga4-top-earnings-notice",r="adsense"},73874:(e,t,i)=>{i.d(t,{Ay:()=>a,Oo:()=>o,oE:()=>r});var s=i(24558),n=i(77766);const o=s.jU,r=s.f7;function a(){const e=(0,n.A)();return e===s.jU||e===s.Ax?o:e===s.f7||e===s.Is?r:null}},74595:(e,t,i)=>{i.d(t,{wA:()=>a.A,ws:()=>u.w,WM:()=>r.A});var s=i(29725),n=i(56805),o=i(78913),r=i(35470),a=i(63737),l=i(44319),c=i(31170),g=i(30043),d=i(66293),u=i(1102),p=i(47121),m=i(97241);const h=(0,s.I)({},i.g.wp?.data);h.combineStores=p.o3,h.commonActions=p.jU,h.commonControls=p._5,h.commonStore=p.x0,h.createReducer=function(e){return(0,m.Ay)(e)},h.useInViewSelect=u.w,h.controls=n.n,h.createRegistryControl=o.b,h.createRegistrySelector=o.N,h.useSelect=r.A,h.useDispatch=a.A,h.useRegistry=l.A,h.withSelect=c.A,h.withDispatch=g.A,h.RegistryProvider=d.Ay;const f=h;void 0===i.g.googlesitekit&&(i.g.googlesitekit={}),i.g.googlesitekit.data=f},74995:(e,t,i)=>{i.d(t,{A:()=>Notifications});var s=i(62688),n=i.n(s),o=i(50539),r=i(77766),a=i(71423),l=i(53137),c=i(50532),g=i.n(c),d=i(43569),u=i(62540);const p=g()(e=>({id:e,Notification:m(e)(d.A)}));function m(e){return t=>{function WithNotificationID(i){return(0,u.jsx)(t,{...i,id:e})}return WithNotificationID.displayName="WithNotificationID",(t.displayName||t.name)&&(WithNotificationID.displayName+=`(${t.displayName||t.name})`),WithNotificationID}}function Notifications({areaSlug:e,groupID:t=l.He.DEFAULT}){const i=(0,r.A)(),s=(0,o.useSelect)(e=>e(a.D).getQueuedNotifications(i,t));if(void 0===s?.[0]||s?.[0]?.areaSlug!==e)return null;const{id:n,Component:c}=s[0],g={...p(n)};return(0,u.jsx)(c,{...g})}Notifications.propTypes={viewContext:n().string,areaSlug:n().string}},75487:(e,t,i)=>{i.d(t,{fh:()=>Cell,xA:()=>u,fI:()=>g});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(62540);function Cell(e){const{className:t,alignTop:i,alignMiddle:s,alignBottom:n,alignRight:o,alignLeft:l,smAlignRight:c,mdAlignRight:g,lgAlignRight:d,smSize:u,smStart:p,smOrder:m,mdSize:h,mdStart:f,mdOrder:_,lgSize:y,lgStart:k,lgOrder:v,size:x,children:A,...j}=e;return(0,a.jsx)("div",{...j,className:r()(t,"mdc-layout-grid__cell",{"mdc-layout-grid__cell--align-top":i,"mdc-layout-grid__cell--align-middle":s,"mdc-layout-grid__cell--align-bottom":n,"mdc-layout-grid__cell--align-right":o,"mdc-layout-grid__cell--align-left":l,"mdc-layout-grid__cell--align-right-phone":c,"mdc-layout-grid__cell--align-right-tablet":g,"mdc-layout-grid__cell--align-right-desktop":d,[`mdc-layout-grid__cell--span-${x}`]:12>=x&&x>0,[`mdc-layout-grid__cell--span-${y}-desktop`]:12>=y&&y>0,[`mdc-layout-grid__cell--start-${k}-desktop`]:12>=k&&k>0,[`mdc-layout-grid__cell--order-${v}-desktop`]:12>=v&&v>0,[`mdc-layout-grid__cell--span-${h}-tablet`]:8>=h&&h>0,[`mdc-layout-grid__cell--start-${f}-tablet`]:8>=f&&f>0,[`mdc-layout-grid__cell--order-${_}-tablet`]:8>=_&&_>0,[`mdc-layout-grid__cell--span-${u}-phone`]:4>=u&&u>0,[`mdc-layout-grid__cell--start-${p}-phone`]:4>=p&&p>0,[`mdc-layout-grid__cell--order-${m}-phone`]:4>=m&&m>0}),children:A})}Cell.propTypes={smSize:n().number,smStart:n().number,smOrder:n().number,mdSize:n().number,mdStart:n().number,mdOrder:n().number,lgSize:n().number,lgStart:n().number,lgOrder:n().number,size:n().number,alignTop:n().bool,alignMiddle:n().bool,alignBottom:n().bool,alignRight:n().bool,alignLeft:n().bool,smAlignRight:n().bool,mdAlignRight:n().bool,lgAlignRight:n().bool,className:n().string,children:n().node},Cell.defaultProps={className:"",size:0,smSize:0,smStart:0,smOrder:0,mdSize:0,mdStart:0,mdOrder:0,lgSize:0,lgStart:0,lgOrder:0};var l=i(63696);const c=(0,l.forwardRef)(({className:e,children:t,...i},s)=>(0,a.jsx)("div",{ref:s,className:r()("mdc-layout-grid__inner",e),...i,children:t}));c.displayName="Row",c.propTypes={className:n().string,children:n().node},c.defaultProps={className:""};const g=c,d=(0,l.forwardRef)((
(0,u.__)("%s of total pageviews","google-site-kit"),(0,V.Eo)(l,{style:"percent",maximumFractionDigits:1})),metricValue:a.currentValue,Badge:()=>(0,P.jsx)(ot.A,{previousValue:a.previousValue,currentValue:a.currentValue})}),(0,P.jsx)(AudienceTileCitiesMetric,{TileIcon:Le,title:(0,u.__)("Cities with the most visitors","google-site-kit"),topCities:g}),(!j||S&&!m)&&(0,P.jsx)(AudienceTilePagesMetric,{audienceTileNumber:e,audienceSlug:t,TileIcon:Be,title:(0,u.__)("Top content by pageviews","google-site-kit"),topContentTitles:p,topContent:d,isTopContentPartialData:N})]})]})})}function AudienceTooltipMessage({audienceSlug:e,audienceName:t}){const i=(0,c.useSelect)(e=>e(Ve.O4).getDocumentationLinkURL("visitor-group-insights"));return(0,a.useMemo)(()=>{switch(e){case"new-visitors":return(0,L.A)((0,u.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
(0,u.__)('%s are people who visited your site for the first time. Note that under some circumstances it\'s possible for a visitor to be counted in both the "new" and "returning" groups. <link>Learn more</link>',"google-site-kit"),"<strong>New visitors</strong>"),{strong:(0,P.jsx)("strong",{}),link:(0,P.jsx)(O.A,{href:i,external:!0,hideExternalIndicator:!0})});case"returning-visitors":return(0,L.A)((0,u.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
(0,u.__)('%s are people who have visited your site at least once before. Note that under some circumstances it\'s possible for a visitor to be counted in both the "new" and "returning" groups. <link>Learn more</link>',"google-site-kit"),"<strong>Returning visitors</strong>"),{strong:(0,P.jsx)("strong",{}),link:(0,P.jsx)(O.A,{href:i,external:!0,hideExternalIndicator:!0})});default:return(0,L.A)((0,u.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
(0,u.__)("%s is an audience that already exists in your Analytics property. Note that it's possible for a visitor to be counted in more than one group. <link>Learn more</link>","google-site-kit"),`<strong>${t}</strong>`),{strong:(0,P.jsx)("strong",{}),link:(0,P.jsx)(O.A,{href:i,external:!0,hideExternalIndicator:!0})})}},[e,t,i])}var mt,ht,ft,_t,yt,kt,vt,xt,At,jt,It,Mt,bt,Nt,St,Et,wt,Ct,Tt,Dt,Rt,zt,Lt,Ot,Pt,Bt,Ut,Gt,Vt,Wt,Ft,Ht,Yt,Zt,Qt,qt,Kt,$t,Xt,Jt,ei,ti,ii,si,ni,oi,ri,ai,li,ci,gi,di,ui,pi,mi,hi,fi,_i,yi,ki,vi,xi,Ai,ji,Ii,Mi,bi,Ni,Si,Ei;function wi(){return wi=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},wi.apply(null,arguments)}AudienceTileZeroData.propTypes={Widget:r().elementType.isRequired,audienceSlug:r().string.isRequired,title:r().string.isRequired,infoTooltip:r().oneOfType([r().string,r().element]),isMobileBreakpoint:r().bool,isTileHideable:r().bool,onHideTile:r().func},AudienceTile.propTypes={audienceTileNumber:r().number,audienceSlug:r().string.isRequired,title:r().string.isRequired,infoTooltip:r().oneOfType([r().string,r().element]),visitors:r().object,visitsPerVisitor:r().object,pagesPerVisit:r().object,pageviews:r().object,percentageOfTotalPageViews:r().number,topCities:r().object,topContent:r().object,topContentTitles:r().object,hasInvalidCustomDimensionError:r().bool,Widget:r().elementType.isRequired,audienceResourceName:r().string.isRequired,isZeroData:r().bool,isPartialData:r().bool,isTileHideable:r().bool,onHideTile:r().func},AudienceTooltipMessage.propTypes={audienceSlug:r().string.isRequired};const Ci=e=>a.createElement("svg",wi({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 211 109"},e),mt||(mt=a.createElement("path",{fill:"#B8E6CA",d:"M2.675 72.31a29.3 29.3 0 0 0 5.678 8.74c9.451 9.955 23.416 10.799 36.223 8.308a88.8 88.8 0 0 0 35.776-15.752c6.09-4.513 12.104-10.113 20.167-10.363 3.027-.093 6.158.741 8.445 2.71 4.753 4.063 4.668 11.012 8.377 15.829 4.932 6.405 12.026 8.389 19.764 9.128 21.862 2.086 47.902-4.758 62.939-21.412 13.426-14.868 15.038-38.526-1.214-52.08-7.425-6.192-17.606-9.03-27.216-7.584-7.345 1.105-14.801 4.467-22.404 5.401-8.954 1.103-14.49-2.659-21.734-7.04C114.852.58 98.164-2.345 83.874 2.072 70.195 6.301 60.35 17.846 47.04 22.918c-11.502 4.385-25.089 3.717-35.082 10.86C.133 42.228-2.84 59.286 2.675 72.31"})),a.createElement("path",{fill:"#161B18",d:"M108.273 109c54.612 0 98.883-1.735 98.883-3.874s-44.271-3.875-98.883-3.875-98.882 1.735-98.882 3.875S53.66 109 108.273 109",opacity:.1,style:{mixBlendMode:"multiply"}}),ht||(ht=a.createElement("path",{fill:"#CBD0D3",d:"M108.273 109c54.612 0 98.883-1.735 98.883-3.874s-44.271-3.875-98.883-3.875-98.882 1.735-98.882 3.875S53.66 109 108.273 109"})),ft||(ft=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.472,d:"M134.765 53.225c-1.065 16.927-6.936 32.112-3.012 51.193h-4.468M139.814 104.418h-4.47l7.9-51.193"})),_t||(_t=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M120.504 36.651c-3.814 1.73-11.135 5.58-11.135 13.398M147.266 35.787c3.493 1.787 11.06 7.678 11.977 13.225"})),yt||(yt=a.createElement("path",{fill:"#77AD8C",d:"m151.555 75.952-3.102.282-18.926 1.719-11.063 1.002-1.049-24.735-1.825-43.046 34.528-1.262.697 32.058.094 4.316.642 29.565z"})),kt||(kt=a.createElement("path",{fill:"#5C9271",d:"m148.453 76.234 1.78-.162 1.323-.12-1.439-66.042-1.983.091 1.281 63.2-24.976 2.127.862-19.15-7.844-1.074.86 20.438.107 2.465.041.946 11.063-1.002 18.927-1.719z"})),vt||(vt=a.createElement("path",{fill:"#CBD0D3",d:"M135.891 70.752c.032.916-.392-20.197-.629-27.044-6.628-3.008-13.797-3.559-20.67-1.228l.628 27.043c6.874-2.33 14.043-1.779 20.671 1.23"})),xt||(xt=a.createElement("path",{fill:"#EBEEF0",d:"M135.926 70.752c.01.916-.547-20.194-.629-27.044 6.481-3.306 13.617-4.182 20.592-2.166l.629 27.043c-6.975-2.015-14.111-1.139-20.592 2.167"})),At||(At=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M133.233 60.796c-.083-3
(0,u._n)("Select at least %1$d group (%2$d selected)","Select at least %1$d groups (%2$d selected)",Ui,"google-site-kit"),Ui,r):r>Gi&&(l=(0,u.sprintf)(/* translators: 1: Maximum number of groups that can be selected. 2: Number of selected groups. */ /* translators: 1: Maximum number of groups that can be selected. 2: Number of selected groups. */
(0,u.__)("Select up to %1$d groups (%2$d selected)","google-site-kit"),Gi,r));const c=(0,a.useMemo)(()=>!(0,n.isEqual)((0,V.N9)(t),(0,V.N9)(e)),[t,e]);if(!l&&!o&&!i)return null;let g=o||i;return c&&l&&(g={message:l}),(0,P.jsx)(hs.A,{error:g})}function Panel(){const e=(0,W.A)(),t=(0,c.useSelect)(e=>e(d.n).getValue(Di)),i=(0,c.useSelect)(e=>e(Q.K9).isFetchingSyncAvailableAudiences()),s=(0,c.useInViewSelect)(e=>{const{getConfigurableAudiences:t}=e(Q.K9),{getConfiguredAudiences:i}=e(q.oR),s=i()||[],n=t()||[];return n.length&&s.length?n.filter(({name:e})=>s.includes(e)).map(({name:e})=>e):[]}),n=(0,Qe.A)(Wi,"autoSubmit"),{setValues:o}=(0,c.useDispatch)(Ge.s),{setValue:r}=(0,c.useDispatch)(d.n),l=(0,a.useCallback)(()=>{o(Ri,{[zi]:s,[Li]:!1}),(0,V.sx)(`${e}_audiences-sidebar`,"audiences_sidebar_view")},[s,o,e]),g=(0,a.useCallback)(()=>{t&&(r(Di,!1),r(Bi,!1))},[r,t]);return(0,P.jsxs)(ss.Ay,{className:"googlesitekit-audience-selection-panel",closePanel:g,isOpen:t||n,isLoading:i,onOpen:l,children:[(0,P.jsx)(Header_Header,{closePanel:g}),(0,P.jsx)(AudienceItems,{savedItemSlugs:s}),(0,P.jsx)(LearnMoreLink,{}),(0,P.jsx)(SaveErrorNotice,{savedItemSlugs:s}),(0,P.jsx)(SyncErrorNotice,{}),(0,P.jsx)(AudienceCreationSuccessNotice,{}),(0,P.jsx)(Footer,{closePanel:g,isOpen:t,savedItemSlugs:s})]})}function AudienceSelectionPanel(){const e=(0,c.useSelect)(e=>e(d.n).getValue(Di));return(0,P.jsx)(es.Ay,{value:{key:"AudienceSelectionPanel",value:!!e},children:(0,P.jsx)(Panel,{})})}var fs=i(91560);function AudienceAreaFooter(){const e=(0,pe.A)(),t=(0,c.useSelect)(e=>e(q.oR).getDateRangeDates({offsetDays:Q.f2})),i=(0,c.useSelect)(i=>e?null:i(Q.K9).getServiceReportURL("audiences",{dates:t}));return(0,c.useSelect)(e=>e(Fi.i).isModuleConnected(F.L1))?(0,P.jsx)(fs.A,{className:"googlesitekit-audience-widget__source",name:(0,u._x)("Analytics","Service name","google-site-kit"),href:i,external:!0}):null}var _s,ys,ks,vs,xs=i(674);function ChangeGroupsLink(){const e=(0,W.A)(),t=(0,c.useInViewSelect)(e=>e(Q.K9).getConfigurableAudiences(),[]),{setValue:i}=(0,c.useDispatch)(d.n),s=(0,a.useCallback)(()=>{i(Di,!0),(0,V.sx)(`${e}_audiences-sidebar`,"change_groups")},[i,e]);return Array.isArray(t)&&t?.length>0?(0,P.jsx)(O.A,{className:"googlesitekit-widget-area__cta-link",onClick:s,leadingIcon:(0,P.jsx)(xs.A,{width:22,height:22}),secondary:!0,linkButton:!0,children:(0,u.__)("Change groups","google-site-kit")}):null}function As(){return As=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},As.apply(null,arguments)}const js=e=>a.createElement("svg",As({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"-3 1 333.666 149.252"},e),_s||(_s=a.createElement("defs",null,a.createElement("filter",{id:"audience-connect-analytics-cta-graphic_svg__c",width:144.59,height:185.064,x:109.551,y:18.171,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},a.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),a.createElement("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),a.createElement("feOffset",{dy:4}),a.createElement("feGaussianBlur",{stdDeviation:8}),a.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),a.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),a.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_1731_24094"}),a.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_1731_24094",result:"shape"})),a.createElement("filter",{id:"audience-connect-analytics-cta-graphic_svg__d",width:144.59,height:185.064,x:236.859,y:18.171,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},a.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),a.createElement("feColorMatrix",{in:"SourceAlpha",result:"hardAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0"}),a.createElement("feOffset",{dy:4}),a.createElement("feGaussianBlur",{stdDeviation:8}),a.createElement("feComposit
(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:k?{label:(0,r.__)("Retry","google-site-kit"),onClick:y}:void 0,hideIcon:h})}ErrorNotice.propTypes={className:n().string,error:n().shape({message:n().string}),hasButton:n().bool,storeName:n().string,message:n().string,noPrefix:n().bool,skipRetryMessage:n().bool,hideIcon:n().bool}},78340:(e,t,i)=>{i.d(t,{s:()=>s});const s="core/forms"},78464:(e,t,i)=>{i.d(t,{Z:()=>C,A:()=>T});var s=i(62688),n=i.n(s),o=i(82871),r=i(39016),a=i(63696),l=i(50539),c=i(78340),g=i(58116),d=i(93896),u=i(71423),p=i(53137),m=i(72455),h=i(77766),f=i(68485),_=i(12850),y=i(33566),k=i(80869),v=i(34375);var x=i(99897),A=i(16196),j=i(93934),I=i(54349),M=i(49655),b=i(12108),N=i(32947),S=i(62540);const E="setup-success-notification-audiences";function AudienceSegmentationSetupSuccessSubtleNotification({id:e,Notification:t}){const s=(0,N.dv)(),{dismissNotification:n}=(0,l.useDispatch)(u.D),r=(0,l.useSelect)(e=>e(g.oR).isAudienceSegmentationWidgetHidden());return(0,a.useEffect)(()=>{r&&n(E)},[n,r]),void 0===r?null:(0,S.jsx)(t,{children:(0,S.jsx)(I.A,{notificationID:e,type:M.Q.SUCCESS,title:(0,o.__)("Success! Visitor groups added to your dashboard","google-site-kit"),description:(0,o.__)("Get to know how different types of visitors interact with your site, e.g. which pages they visit and for how long","google-site-kit"),ctaButton:{label:(0,o.__)("Show me","google-site-kit"),onClick:function(e){e.preventDefault(),n(E),setTimeout(()=>{i.g.scrollTo({top:(0,b.YJ)(".googlesitekit-widget-area--mainDashboardTrafficAudienceSegmentation",s),behavior:"smooth"})},50)}},dismissButton:!0})})}AudienceSegmentationSetupSuccessSubtleNotification.propTypes={id:n().string.isRequired,Notification:n().elementType.isRequired};var w=i(27333);const C="audience_segmentation_setup_cta-notification";function AudienceSegmentationSetupCTABanner({id:e,Notification:t}){const i=(0,h.A)(),s=`${i}_audiences-setup-cta-dashboard`,{dismissNotification:n,registerNotification:r,pinNotification:x}=(0,l.useDispatch)(u.D),{setValues:A}=(0,l.useDispatch)(c.s),j={tooltipSlug:e,title:(0,o.__)("You can always enable groups in Settings later","google-site-kit"),content:(0,o.__)("The visitors group section will be added to your dashboard once you set it up.","google-site-kit"),dismissLabel:(0,o.__)("Got it","google-site-kit")},I=(0,f.i)(j),M=(0,l.useSelect)(t=>t(u.D).isNotificationDismissalFinal(e)),b=(0,w.A)(m.PW,"autoSubmit"),[N,C]=(0,a.useState)(!1),T=(0,a.useCallback)(()=>{r(E,{Component:AudienceSegmentationSetupSuccessSubtleNotification,areaSlug:p.bI.DASHBOARD_TOP}),n(e)},[r,n,e]),D=(0,a.useCallback)(()=>{C(!0)},[C]),R=(0,a.useCallback)(()=>x(e,p.He.SETUP_CTAS),[e,x]),{apiErrors:z,failedAudiences:L,isSaving:O,onEnableGroups:P}=(0,y.A)({onSuccess:T,onError:D,onOAuthNavigation:R}),{clearPermissionScopeError:B}=(0,l.useDispatch)(g.oR),{setSetupErrorCode:U}=(0,l.useDispatch)(d.O4),G=(0,a.useCallback)(()=>{A(m.PW,{autoSubmit:!1}),B(),U(null),C(!1)},[B,U,A]),V=(0,l.useSelect)(e=>e(d.O4).getSetupErrorCode()),W=(0,l.useSelect)(e=>e(d.O4).getDocumentationLinkURL("visitor-groups")),F=b&&"access_denied"===V,H={gaTrackingEventArgs:{category:s}};return(0,S.jsxs)(a.Fragment,{children:[(0,S.jsx)(t,{...H,children:(0,S.jsx)(v.A,{notificationID:e,title:(0,o.__)("Learn how different types of visitors interact with your site","google-site-kit"),description:(0,o.__)('Understand what brings new visitors to your site and keeps them coming back. Site Kit can now group your site visitors into relevant segments like "new" and "returning". To set up these new groups, Site Kit needs to update your Google Analytics property.',"google-site-kit"),learnMoreLink:{href:W},ctaButton:{label:O?(0,o.__)("Enabling groups","google-site-kit"):(0,o.__)("Enable groups","google-site-kit"),onClick:P,disabled:O,inProgress:O},dismissButton:{label:M?(0,o.__)("Dont show again","go
(0,r._x)("%3$s %2$s %1$s","duration of time: hh mm ss","google-site-kit"),n?p(n,{...l,unit:"second"}):"",s?p(s,{...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"),n);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"),s),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"),n?t:"",s?o:"",i?a:"").trim()}}}(e,t);try{return i()}catch{return s()}}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,s.isPlainObject)(e)&&(t={...e}),t}function d(e,t={}){e=(0,s.isFinite)(e)?e:Number(e),(0,s.isFinite)(e)||(console.warn("Invalid number",e,typeof e),e=0);const i=g(t),{style:n="metric"}=i;return"metric"===n?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"===n?a(e,i):"durationISO"===n?function(e){let{hours:t,minutes:i,seconds:s}=l(e);return s=("0"+s).slice(-2),i=("0"+i).slice(-2),t=("0"+t).slice(-2),"00"===t?`${i}:${s}`:`${t}:${i}:${s}`}(e):p(e,i)}const u=o()(console.warn);function p(e,t={}){const{locale:i=h(),...s}=t;try{return new Intl.NumberFormat(i,s).format(e)}catch(t){u(`Site Kit numberFormat error: Intl.NumberFormat( ${JSON.stringify(i)}, ${JSON.stringify(s)} ).format( ${typeof e} )`,t.message)}const n={currencyDisplay:"narrow",currencySign:"accounting",style:"unit"},o=["signDisplay","compactDisplay"],r={};for(const[e,t]of Object.entries(s))n[e]&&t===n[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 m(e,t={}){const{locale:i=h(),style:s="long",type:n="conjunction"}=t;if(Intl.ListFormat){return new Intl.ListFormat(i,{style:s,type:n}).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 h(e=i.g){const t=(0,s.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:()=>k});var s,n=i(62688),o=i.n(n),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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}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),s||(s=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 m={[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=m[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 h=i(49383),f=i(83366);function CTAButton({label:e,disabled:t,inProgress:i,onClick:s,href:n,external:o=!1,hideExternalIndicator:r=!1}){let a;return o&&!r&&(a=(0,p.jsx)(f.A,{width:14,height:14})),(0,p.jsx)(h.SpinnerButton,{className:"googlesitekit-notice__cta",disabled:t,isSaving:i,onClick:s,href:n,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 _=i(82871);function DismissButton({label:e=(0,_.__)("Got it","google-site-kit"),onClick:t,disabled:i}){return(0,p.jsx)(h.Button,{onClick:t,disabled:i,tertiary:!0,children:e})}DismissButton.propTypes={label:o().string,onClick:o().func.isRequired,disabled:o().bool};const y=(0,l.forwardRef)(({className:e,title:t,description:i,dismissButton:s,ctaButton:n,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})]}),(s?.label||s?.onClick||n?.label&&(n?.onClick||n?.href)||r)&&(0,p.jsxs)("div",{className:"googlesitekit-notice__action",children:[r,(s?.label||s?.onClick)&&(0,p.jsx)(DismissButton,{label:s.label,onClick:s.onClick,disabled:s.disabled}),n?.label&&(n?.onClick||n?.href)&&(0,p.jsx)(CTAButton,{label:n.label,onClick:n.onClick,inProgress:n.inProgress,disabled:n.disabled,href:n.href,external:n.external,hideExternalIndicator:n.hideExternalIndicator})]})]}));y.TYPES=u.Q,y.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 k=y},80097:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s,n=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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},o.apply(null,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>n.createElement("svg",o({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 12 8"},e),s||(s=n.createElement("path
(0,c.__)("these active modules depend on consent mode and will be affected: %s","google-site-kit"),(0,R.K5)(n)):null;(0,D.A)(()=>{(0,R.sx)(`${i}_CoMo`,"view_modal")});let r=[(0,c.__)("Track how visitors interact with your site","google-site-kit")],a=(0,c.__)("Disabling consent mode may affect your ability in the European Economic Area, the UK and Switzerland to:","google-site-kit");return s&&(r=[(0,c.__)("Performance of your Ad campaigns","google-site-kit"),(0,c.__)("How visitors interact with your site via Analytics","google-site-kit")],a=(0,c.__)("Disabling consent mode may affect your ability to track these in the European Economic Area, the UK and Switzerland:","google-site-kit")),(0,P.jsx)(L.A,{className:"googlesitekit-settings-module__confirm-disconnect-modal",title:(0,c.__)("Disable consent mode?","google-site-kit"),subtitle:a,handleConfirm:e,handleCancel:t,onClose:t,provides:r,dependentModules:o,confirmButton:(0,c.__)("Disable","google-site-kit"),dialogActive:!0,danger:!0})}ConfirmDisableConsentModeDialog.propTypes={onConfirm:T().func.isRequired,onCancel:T().func.isRequired};var B=i(41617),U=i(77967),G=i(59323);function ConsentModeSwitch({loading:e}){const t=(0,O.A)(),[i,s]=(0,l.useState)(null),[n,o]=(0,l.useState)(!1),r=(0,m.useSelect)(e=>e(b.O4).isConsentModeEnabled()),a=(0,m.useSelect)(e=>e(b.O4).getDocumentationLinkURL("consent-mode")),d=(0,m.useSelect)(e=>e(b.O4).isFetchingSaveConsentModeSettings()),{setConsentModeEnabled:u,saveConsentModeSettings:p}=(0,m.useDispatch)(b.O4),{dismissPrompt:h,triggerSurvey:_}=(0,m.useDispatch)(f.oR),y=(0,m.useSelect)(e=>e(f.oR).isPromptDismissed(B.X));async function k(){s(null);const e=[p(),_("enable_como",{ttl:R.tt})],[{error:t}]=await Promise.all(e);t?s(t):y||await h(B.X)}return(0,P.jsxs)(l.Fragment,{children:[(0,P.jsxs)("div",{children:[(0,P.jsx)(w.A,{loading:e,width:"180px",height:"21.3px",children:(0,P.jsx)(g.Switch,{label:(0,c.__)("Enable consent mode","google-site-kit"),checked:r,disabled:e||d,onClick:()=>{r?((0,R.sx)(`${t}_CoMo`,"como_disable"),o(!0)):((0,R.sx)(`${t}_CoMo`,"como_enable"),u(!0),k())},hideLabel:!1})}),i&&(0,P.jsx)(U.A,{message:i.message}),!e&&r&&(0,P.jsx)("p",{className:"googlesitekit-settings-consent-mode-switch__enabled-notice",children:(0,c.__)("Site Kit added the necessary code to your tag to comply with consent mode.","google-site-kit")}),(0,P.jsx)(w.A,{className:"googlesitekit-settings-consent-mode-switch-description--loading",loading:e,width:"750px",height:"42px",smallWidth:"386px",smallHeight:"84px",tabletWidth:"540px",tabletHeight:"84px",children:(0,P.jsx)(G.A,{children:(0,S.A)((0,c.__)("Consent mode will help adjust tracking on your site, so only visitors who have explicitly given consent are tracked. <br />This is required in some parts of the world, like the European Economic Area. <a>Learn more</a>","google-site-kit"),{br:(0,P.jsx)("br",{}),a:(0,P.jsx)(E.A,{href:a,"aria-label":(0,c.__)("Learn more about consent mode","google-site-kit"),onClick:async()=>{await(0,R.sx)(`${t}_CoMo`,"como_learn_more")},external:!0})})})})]}),n&&(0,P.jsx)(ConfirmDisableConsentModeDialog,{onConfirm:()=>{(0,R.sx)(`${t}_CoMo`,"confirm_disconnect"),u(!1),o(!1),k()},onCancel:()=>{(0,R.sx)(`${t}_CoMo`,"cancel_disconnect"),o(!1)}})]})}var V=i(2390),W=i(15167);function WPConsentAPIRequirement({title:e,description:t,footer:i}){return(0,P.jsxs)("div",{className:"googlesitekit-settings-consent-mode-requirement",children:[(0,P.jsx)(W.A,{as:"h4",size:"large",type:"title",children:e}),(0,P.jsx)("p",{className:"googlesitekit-settings-consent-mode-requirement__description",children:t}),(0,P.jsx)("footer",{className:"googlesitekit-settings-consent-mode-requirement__footer",children:i})]})}WPConsentAPIRequirement.propTypes={title:T().string.isRequired,description:T().node.isRequired,footer:T().node.isRequired};var F=i(63972),H=i(80035);function WPConsentAPIRequirements(){const e=(0,O.A)(),t=(0,m.useSelect)(e=>e(b.O4).getDocumentationLinkURL("wp-consent-api")),i=(0,m.useSelect)(e=>e(b.O4).getDocumentationLinkURL("consent-management-platform")),{hasConsentAPI:s,wpConsentPlugin:n}=(
(0,c.__)("Complete setup for %s","google-site-kit"),A)}),(0,P.jsxs)("div",{className:I()("googlesitekit-settings-module__header",{"googlesitekit-settings-module__header--open":o}),id:`googlesitekit-settings-module__header--${e}`,type:"button",role:"tab","aria-selected":o,"aria-expanded":o,"aria-controls":`googlesitekit-settings-module__content--${e}`,to:"/connected-services"+(o?"":`/${e}`),onClick:o?k:y,ref:s,tabIndex:"0",children:[(0,P.jsx)(v.xA,{children:(0,P.jsxs)(v.fI,{children:[(0,P.jsxs)(v.fh,{lgSize:6,mdSize:4,smSize:4,className:"googlesitekit-settings-module__heading",children:[(0,P.jsx)(Ue.A,{slug:e,size:40,className:"googlesitekit-settings-module__heading-icon"}),(0,P.jsx)(W.A,{as:"h3",type:"title",size:"large",className:"googlesitekit-settings-module__title",children:A}),(0,P.jsxs)("div",{className:"googlesitekit-settings-module__heading-badges",children:[Pe.includes(e)&&(0,P.jsx)(N.A,{label:(0,c.__)("Experimental","google-site-kit"),hasLeftSpacing:!0}),Oe.includes(e)&&(0,P.jsx)(N.A,{className:"googlesitekit-badge--beta",label:(0,c.__)("Beta","google-site-kit"),hasLeftSpacing:!0}),Le.includes(e)&&(0,P.jsx)(Ge.A,{hasLeftSpacing:!0})]})]}),(0,P.jsx)(v.fh,{lgSize:6,mdSize:4,smSize:4,alignMiddle:!0,mdAlignRight:!0,children:(0,P.jsxs)("div",{className:I()("googlesitekit-settings-module__status",{"googlesitekit-settings-module__status--connected":j,"googlesitekit-settings-module__status--not-connected":!j}),children:[M,(0,P.jsx)("span",{className:I()("googlesitekit-settings-module__status-icon",{"googlesitekit-settings-module__status-icon--connected":j,"googlesitekit-settings-module__status-icon--not-connected":!j}),children:j?(0,P.jsx)(fe.A,{width:10,height:8}):(0,P.jsx)(Ve.A,{width:19,height:17})})]})})]})}),(0,P.jsx)(Fe.A,{children:(0,P.jsx)(We.A,{width:12,height:8,className:"icon-chevron-down"})})]})}Header_Header.propTypes={slug:T().string.isRequired};var Ze,Qe=i(21134);function qe(){return qe=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},qe.apply(null,arguments)}const Ke=e=>l.createElement("svg",qe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 10 10"},e),Ze||(Ze=l.createElement("path",{fill:"currentColor",d:"M0 7.917V10h2.083l6.144-6.144-2.083-2.083zm9.838-5.671a.553.553 0 0 0 0-.784l-1.3-1.3a.553.553 0 0 0-.784 0L6.738 1.18 8.82 3.262z"})));function FooterPrimaryAction({slug:e,isEditing:t,isSaving:i,handleConfirm:s,handleClose:n,handleEdit:o}){const r=(0,m.useSelect)(t=>t(h.i).getModule(e)),a=(0,m.useSelect)(t=>t(h.i).isModuleConnected(e)),d=(0,m.useSelect)(t=>t(h.i).areSettingsEditDependenciesLoaded(e)),u=(0,m.useSelect)(t=>t(h.i).canSubmitChanges(e)),p=(0,m.useSelect)(t=>t(h.i).haveSettingsChanged(e)),f=!!r?.SettingsEditComponent;return t||i?(0,P.jsxs)(l.Fragment,{children:[f&&a?(0,P.jsx)(g.SpinnerButton,{disabled:i||!d||!u&&p,onClick:s,isSaving:i,children:p?(0,c.__)("Confirm changes","google-site-kit"):(0,c.__)("Save","google-site-kit")}):(0,P.jsx)(g.Button,{onClick:n,children:(0,c.__)("Close","google-site-kit")}),f&&(0,P.jsx)(g.Button,{className:"googlesitekit-settings-module__footer-cancel",onClick:n,tertiary:!0,children:(0,c.__)("Cancel","google-site-kit")})]}):f||!r?.forceActive?(0,P.jsx)(E.A,{className:"googlesitekit-settings-module__edit-button",to:`/connected-services/${e}/edit`,onClick:o,"aria-label":(0,c.sprintf)(/* translators: %s is replaced with the module name */ /* translators: %s is replaced with the module name */
(0,c.__)("Edit %s settings","google-site-kit"),r?.name),trailingIcon:(0,P.jsx)(Ke,{className:"googlesitekit-settings-module__edit-button-icon",width:10,height:10}),children:(0,c.__)("Edit","google-site-kit")}):null}var $e;function Xe(){return Xe=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},Xe.apply(null,arguments)}const Je=e=>l.createElement("svg",Xe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 11 13"},e),$e||($e=l.createElement("path",{fill:"currentColor",d:"M.722 11.556c0 .794.65 1.444 1.445 1.444h5.777c.795 0 1.445-.65 1.445-1.444V2.889H.722zM10.112.722H7.582L6.861 0H3.25l-.722.722H0v1.445h10.111z"})));function FooterSecondaryAction({slug:e,isEditing:t,handleDialog:i}){const s=(0,m.useSelect)(t=>t(h.i).getModule(e)),n=(0,m.useSelect)(t=>t(h.i).getDetailsLinkURL(e));return t&&!s?.forceActive?(0,P.jsx)(E.A,{className:"googlesitekit-settings-module__remove-button",onClick:i,trailingIcon:(0,P.jsx)(Je,{className:"googlesitekit-settings-module__remove-button-icon",width:13,height:13}),danger:!0,children:(0,c.sprintf)(/* translators: %s is replaced with the module name */ /* translators: %s is replaced with the module name */
(0,c.__)("Disconnect %s from Site Kit","google-site-kit"),s?.name)}):!t&&s?.connected&&n?(0,P.jsx)(E.A,{href:n,className:"googlesitekit-settings-module__cta-button",external:!0,children:(0,c.sprintf)(/* translators: %s is replaced with the module name */ /* translators: %s is replaced with the module name */
(0,c.__)("See full details in %s","google-site-kit"),s?.name)}):null}function Footer({slug:e}){const t=(0,O.A)(),i=(0,a.W6)(),{action:s,moduleSlug:n}=(0,a.g)(),o="edit"===s&&n===e,r=`module-${e}-error`,c=`module-${e}-dialogActive`,g=`module-${e}-isSaving`,d=(0,m.useSelect)(e=>e(q.n).getValue(c)),u=(0,m.useSelect)(e=>e(q.n).getValue(g)),p=(0,m.useSelect)(t=>t(h.i).getModule(e)),{submitChanges:f}=(0,m.useDispatch)(h.i),{clearErrors:_}=(0,m.useDispatch)(p?.storeName)||{},{setValue:y}=(0,m.useDispatch)(q.n),k=(0,l.useCallback)(async()=>{await(0,R.sx)(`${t}_module-list`,"cancel_module_settings",e),await(_?.()),i.push(`/connected-services/${e}`)},[_,i,t,e]),x=(0,l.useCallback)(async s=>{s.preventDefault(),y(g,!0);const{error:n}=await f(e);y(g,!1),n?y(r,n):(await(0,R.sx)(`${t}_module-list`,"update_module_settings",e),y(r,void 0),await(_?.()),i.push(`/connected-services/${e}`),await(0,Qe.IL)())},[y,g,f,e,r,_,i,t]),A=(0,l.useCallback)(()=>{y(c,!d)},[d,c,y]),j=(0,l.useCallback)(()=>{(0,R.sx)(`${t}_module-list`,"edit_module_settings",e)},[e,t]);return p?(0,P.jsx)("footer",{className:"googlesitekit-settings-module__footer",children:(0,P.jsx)(v.xA,{children:(0,P.jsxs)(v.fI,{children:[(0,P.jsx)(v.fh,{lgSize:6,mdSize:8,smSize:4,children:(0,P.jsx)(FooterPrimaryAction,{slug:e,isEditing:o,isSaving:u,handleConfirm:x,handleClose:k,handleEdit:j})}),(0,P.jsx)(v.fh,{lgSize:6,mdSize:8,smSize:4,alignMiddle:!0,lgAlignRight:!0,children:(0,P.jsx)(FooterSecondaryAction,{slug:e,isEditing:o,handleDialog:A})})]})})}):null}Footer.propTypes={slug:T().string.isRequired};var et=i(31589);function ConfirmDisconnect({slug:e}){const t=(0,O.A)(),[i,s]=(0,l.useState)(!1),{setValue:n}=(0,m.useDispatch)(q.n),o=`module-${e}-dialogActive`,r=(0,m.useSelect)(t=>t(h.i).getModuleDependantNames(e)),a=(0,m.useSelect)(t=>t(h.i).getModuleFeatures(e)),g=(0,m.useSelect)(t=>t(h.i).getModule(e)),d=(0,m.useSelect)(e=>e(b.O4).getAdminURL("googlesitekit-settings")),u=(0,m.useSelect)(e=>e(q.n).getValue(o)),p=(0,l.useCallback)(()=>{n(o,!1)},[o,n]),f=(0,l.useCallback)(e=>{De._f===e.keyCode&&u&&p()},[u,p]);(0,et.A)("keydown",f);const{deactivateModule:_}=(0,m.useDispatch)(h.i),{navigateTo:y}=(0,m.useDispatch)(Q.M),k=(0,l.useCallback)(async()=>{if(g.forceActive)return;s(!0);const{error:i}=await _(e);i?s(!1):(await(0,Qe.IL)(),await(0,R.sx)(`${t}_module-list`,"deactivate_module",e),y(d))},[e,g?.forceActive,d,_,y,t]);if(!g||!u)return null;const{name:v}=g,x=(0,c.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,c.__)("Disconnect %s from Site Kit?","google-site-kit"),v);let A=null;return r.length>0&&(A=(0,c.sprintf)(/* translators: 1: module name, 2: list of dependent modules */ /* translators: 1: module name, 2: list of dependent modules */
(0,c.__)("these active modules depend on %1$s and will also be disconnected: %2$s","google-site-kit"),v,(0,R.K5)(r))),(0,P.jsx)(L.A,{className:"googlesitekit-settings-module__confirm-disconnect-modal",handleCancel:p,onClose:p,title:x,provides:a,handleConfirm:k,dependentModules:A,inProgress:i,dialogActive:!0,danger:!0})}function SettingsActiveModule(e){const{slug:t}=e,{action:i,moduleSlug:s}=(0,a.g)(),n="edit"===i,o=s===t,r=s!==t&&n,l=`module-${t}-error`,c=(0,m.useSelect)(e=>e(h.i).getErrorForAction("deactivateModule",[t])),g=(0,m.useSelect)(e=>e(q.n).getValue(l));return(0,P.jsxs)("div",{className:I()("googlesitekit-settings-module","googlesitekit-settings-module--active",`googlesitekit-settings-module--${t}`,{"googlesitekit-settings-module--error":(g||c)&&n}),children:[r&&(0,P.jsx)(Te,{compress:!o}),(0,P.jsx)(Header_Header,{slug:t}),o&&(0,P.jsxs)("div",{id:`googlesitekit-settings-module__content--${t}`,className:"googlesitekit-settings-module__content googlesitekit-settings-module__content--open",role:"tabpanel","aria-labelledby":`googlesitekit-settings-module__header--${t}`,children:[(0,P.jsx)(v.xA,{children:(0,P.jsx)(v.fI,{children:(0,P.jsx)(v.fh,{size:12,children:(0,P.jsx)(SettingsRenderer,{slug:t})})})}),(0,P.jsx)(Footer,{slug:t})]}),(0,P.jsx)(ConfirmDisconnect,{slug:t})]})}function SettingsActiveModules(){const e=(0,m.useSelect)(e=>e(h.i).getModules());if(!e)return null;const t=Object.keys(e).map(t=>e[t]).filter(({internal:e,active:t})=>!e&&t).sort((e,t)=>e.order-t.order);return(0,P.jsx)(p.A,{rounded:!0,children:t.map(({slug:e})=>(0,P.jsx)(SettingsActiveModule,{slug:e},e))})}ConfirmDisconnect.propTypes={slug:T().string.isRequired},SettingsActiveModule.propTypes={slug:T().string.isRequired};var tt=i(27240),it=i(13465);function SetupModule({slug:e,name:t,description:i}){const s=(0,O.A)(),[n,o]=(0,l.useState)(!1),{activateModule:r}=(0,m.useDispatch)(h.i),{navigateTo:a}=(0,m.useDispatch)(Q.M),{setInternalServerError:g}=(0,m.useDispatch)(b.O4),d=(0,l.useCallback)(async()=>{o(!0);const{error:t,response:i}=await r(e);t?(g({id:"activate-module-error",description:t.message}),o(!1)):(await(0,R.sx)(`${s}_module-list`,"activate_module",e),await(0,Qe.SO)("module_setup",e,{ttl:300}),a(i.moduleReauthURL))},[r,a,g,e,s]),u=(0,m.useSelect)(t=>t(h.i).canActivateModule(e));return(0,P.jsxs)("div",{className:I()("googlesitekit-settings-connect-module",`googlesitekit-settings-connect-module--${e}`),children:[(0,P.jsx)("div",{className:"googlesitekit-settings-connect-module__switch",children:(0,P.jsx)(tt.A,{isSaving:n})}),(0,P.jsx)("div",{className:"googlesitekit-settings-connect-module__logo",children:(0,P.jsx)(Ue.A,{slug:e})}),(0,P.jsxs)("div",{className:"googlesitekit-settings-connect-module__heading",children:[(0,P.jsx)(W.A,{as:"h3",type:"title",size:"small",className:" googlesitekit-subheading-1 googlesitekit-settings-connect-module__title ",children:t}),(0,P.jsxs)("div",{className:"googlesitekit-settings-connect-module__badges",children:[Pe.includes(e)&&(0,P.jsx)(N.A,{label:(0,c.__)("Experimental","google-site-kit")}),Oe.includes(e)&&(0,P.jsx)(N.A,{className:"googlesitekit-badge--beta",label:(0,c.__)("Beta","google-site-kit")}),Le.includes(e)&&(0,P.jsx)(Ge.A,{hasNoSpacing:!0})]})]}),(0,P.jsx)("p",{className:"googlesitekit-settings-connect-module__text",children:i}),(0,P.jsx)("p",{className:"googlesitekit-settings-connect-module__cta",children:(0,P.jsx)(E.A,{onClick:d,href:"",disabled:!u||n,arrow:!0,children:(0,c.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
(0,c.__)("Set up %s","google-site-kit"),t)})}),(0,P.jsx)(it.A,{slug:e})]},e)}function SettingsInactiveModules(){const e=(0,m.useSelect)(e=>e(h.i).getModules());if(!e)return null;const t=Object.keys(e).map(t=>e[t]).filter(({internal:e,active:t})=>!e&&!t).sort((e,t)=>e.order-t.order);return 0===t.length?(0,P.jsx)(H.A,{id:"no-more-modules",title:(0,c.__)("Congrats, youve connected all services!","google-site-kit"),description:(0,c.__)("Were working on adding new services to Site Kit by Google all the time, so please check back in the future","google-site-kit"),type:me.Q.SUCCESS}):(0,P.jsx)(p.A,{title:(0,c.__)("Connect More Services to Gain More Insights","google-site-kit"),header:!0,rounded:!0,relative:!0,children:(0,P.jsx)(v.xA,{children:(0,P.jsx)(v.fI,{children:t.map(({slug:e,name:t,description:i})=>(0,P.jsx)(v.fh,{size:4,children:(0,P.jsx)(SetupModule,{slug:e,name:t,description:i})},e))})})})}SetupModule.propTypes={slug:T().string.isRequired,name:T().string.isRequired,description:T().string.isRequired};const st=function SettingsModules(){const e=(0,m.useSelect)(e=>e(h.i).getModules());return void 0!==e&&Object.values(e).length?(0,P.jsxs)(a.dO,{children:[(0,P.jsx)(a.qh,{path:"/connected-services/:moduleSlug/:action",children:(0,P.jsx)(SettingsActiveModules,{})}),(0,P.jsx)(a.qh,{path:"/connected-services/:moduleSlug",children:(0,P.jsx)(SettingsActiveModules,{})}),(0,P.jsx)(a.qh,{path:"/connected-services",children:(0,P.jsx)(SettingsActiveModules,{})}),(0,P.jsx)(a.qh,{path:"/connect-more-services",children:(0,P.jsx)(SettingsInactiveModules,{})}),(0,P.jsx)(a.qh,{path:"/admin-settings",children:(0,P.jsx)(SettingsAdmin,{})}),(0,P.jsx)(a.rd,{from:"/settings/:moduleSlug/edit",to:"/connected-services/:moduleSlug/edit"}),(0,P.jsx)(a.rd,{from:"/settings/:moduleSlug",to:"/connected-services/:moduleSlug"}),(0,P.jsx)(a.rd,{from:"/settings",to:"/connected-services"}),(0,P.jsx)(a.rd,{from:"/connect",to:"/connect-more-services"}),(0,P.jsx)(a.rd,{from:"/admin",to:"/admin-settings"}),(0,P.jsx)(a.rd,{to:"/connected-services"})]}):null};var nt=i(84826),ot=i(89318),rt=i(89506);function SettingsApp(){const e=(0,a.zy)();const[,t]=e.pathname.split("/"),i=SettingsApp.basePathToTabIndex[t],n=(0,O.A)(),o=(0,Ee.i)("proactiveUserEngagement"),r=(0,l.useCallback)(()=>{(0,ot.sx)(n,"tab_select",t)},[t,n]);return(0,P.jsxs)(l.Fragment,{children:[(0,P.jsx)(d.A,{children:(0,P.jsx)(nt.A,{})}),(0,P.jsx)("div",{className:"googlesitekit-module-page",children:(0,P.jsx)(v.xA,{children:(0,P.jsxs)(v.fI,{children:[(0,P.jsx)(v.fh,{size:12,children:(0,P.jsx)(u.A,{title:(0,c.__)("Settings","google-site-kit")})}),(0,P.jsx)(v.fh,{size:12,children:(0,P.jsx)(p.A,{transparent:!0,rounded:!0,children:(0,P.jsxs)(g.TabBar,{activeIndex:i,className:"googlesitekit-tab-bar__settings",handleActiveIndexUpdate:r,children:[(0,P.jsx)(g.Tab,{tag:s.N_,to:"/connected-services",replace:!1,children:(0,P.jsx)("span",{className:"mdc-tab__text-label",children:(0,c.__)("Connected Services","google-site-kit")})}),(0,P.jsx)(g.Tab,{tag:s.N_,to:"/connect-more-services",replace:!1,children:(0,P.jsx)("span",{className:"mdc-tab__text-label",children:(0,c.__)("Connect More Services","google-site-kit")})}),(0,P.jsx)(g.Tab,{tag:s.N_,to:"/admin-settings",replace:!1,children:(0,P.jsx)("span",{className:"mdc-tab__text-label",children:(0,c.__)("Admin Settings","google-site-kit")})})]})})}),(0,P.jsx)(v.fh,{size:12,children:(0,P.jsx)(st,{})})]})})}),o&&(0,P.jsx)(rt.A,{})]})}SettingsApp.propTypes={},SettingsApp.basePathToTabIndex={"connected-services":0,"connect-more-services":1,"admin-settings":2};const at=(0,a.y)(SettingsApp);var lt=i(24558);(0,n.A)(()=>{const e=document.getElementById("js-googlesitekit-settings");e&&(0,o.render)((0,P.jsx)(r.A,{viewContext:lt.KK,children:(0,P.jsx)(s.I9,{children:(0,P.jsx)(at,{})})}),e)})},88933:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s,n=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 s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},o.apply(null,argumen
(0,s.__)("Sent every %s","google-site-kit"),function(e){const i=Number.isInteger(e)&&e>=0&&e<=6?e:1;return t[i]}(i)),d={weekly:{label:(0,s.__)("Weekly","google-site-kit"),period:(0,s.__)("Last 7 days","google-site-kit"),description:g},monthly:{label:(0,s.__)("Monthly","google-site-kit"),period:(0,s.__)("Last 28 days","google-site-kit"),description:(0,s.__)("Sent on the 1st of each month","google-site-kit")},quarterly:{label:(0,s.__)("Quarterly","google-site-kit"),period:(0,s.__)("Last 90 days","google-site-kit"),description:(0,s.__)("Sent on the 1st of each quarter","google-site-kit")}};return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsx)(A.A,{className:"googlesitekit-frequency-selector-title",type:"label",size:"small",as:"h3",children:(0,s.__)("Frequency","google-site-kit")}),(0,v.jsx)("div",{className:"googlesitekit-frequency-selector",role:"radiogroup","aria-label":(0,s.__)("Frequency","google-site-kit"),children:a.lV.map(t=>{const i=r===t,{label:s,period:n,description:o}=d[t]||{};return(0,v.jsxs)("div",{className:I()("googlesitekit-frequency-selector__card",{"googlesitekit-frequency-selector__card--selected":i}),role:"radio","aria-checked":i,tabIndex:0,onClick:()=>c(t),onKeyDown:e=>function(e,t){" "!==e.key&&"Spacebar"!==e.key&&"Enter"!==e.key||(e.preventDefault(),c(t))}(e,t),children:[(0,v.jsxs)("div",{className:"googlesitekit-frequency-selector__label-row",children:[(0,v.jsx)(A.A,{className:"googlesitekit-frequency-selector__label",type:"label",size:"large",as:"div",children:s}),l===t&&e&&(0,v.jsx)("div",{className:"googlesitekit-frequency-selector__saved-indicator",children:(0,v.jsx)(M.A,{className:"googlesitekit-frequency-selector__label-tick","aria-hidden":"true"})})]}),(0,v.jsx)(A.A,{className:"googlesitekit-frequency-selector__period",type:"body",size:"small",as:"div",children:n}),(0,v.jsx)(A.A,{className:"googlesitekit-frequency-selector__description",type:"body",size:"small",as:"div",children:o})]},t)})})]})}FrequencySelector.propTypes={isUserSubscribed:d().bool};var b=i(2390);const N={SUBSCRIBE:"subscribe",UNSUBSCRIBE:"unsubscribe",UPDATE_SETTINGS:"update_settings"};function SubscribeActions({isSubscribed:e,onSubscribe:t,onUnsubscribe:i,updateSettings:o,isLoading:r}){const[a,l]=(0,n.useState)("");function c(e){switch(l(e),e){case N.UPDATE_SETTINGS:o();break;case N.SUBSCRIBE:t();break;case N.UNSUBSCRIBE:i()}}return(0,v.jsxs)("div",{className:"googlesitekit-selection-panel-subscribe-actions",children:[e&&(0,v.jsx)(b.A,{onClick:()=>c(N.UNSUBSCRIBE),isSaving:r&&a===N.UNSUBSCRIBE,disabled:r,tertiary:!0,children:(0,s.__)("Unsubscribe","google-site-kit")}),(0,v.jsx)(b.A,{onClick:()=>c(e?N.UPDATE_SETTINGS:N.SUBSCRIBE),isSaving:r&&a!==N.UNSUBSCRIBE,disabled:r,children:e?(0,s.__)("Update Settings","google-site-kit"):(0,s.__)("Subscribe","google-site-kit")})]})}function PanelContent({notice:e,isUserSubscribed:t,isSavingSettings:i,onSaveCallback:r,onSubscribe:l,onUnsubscribe:c,onNoticeDismiss:g,closePanel:d}){const u=(0,o.useSelect)(e=>e(a.oR).getUser()),p=u?.wpEmail;return(0,v.jsxs)(n.Fragment,{children:[(0,v.jsxs)("div",{className:"googlesitekit-user-settings-selection__panel-content",children:[(0,v.jsx)(Header,{closePanel:d}),(0,v.jsx)("div",{className:"googlesitekit-user-settings-selection__panel-description",children:(0,v.jsxs)(_.A,{type:"body",size:"small",children:[(0,s.__)("Youll receive the report to your WordPress user email","google-site-kit"),p&&(0,v.jsx)(A.A,{type:"body",size:"medium",children:p})]})}),(0,v.jsx)(FrequencySelector,{isUserSubscribed:t}),(0,v.jsx)(SubscribeActions,{onSubscribe:l,onUnsubscribe:c,updateSettings:r,isSubscribed:t,isLoading:i})]}),(0,v.jsx)(SelectionPanelFooter,{notice:e,onNoticeDismiss:g})]})}function UserSettingsSelectionPanel(){const e=(0,o.useSelect)(e=>e(r.n).getValue(l.Q)),t=(0,o.useSelect)(t=>e?t(a.oR).getEmailReportingSettings():{}),i=(0,o.useSelect)(t=>!!e&&t(a.oR).isSavingEmailReportingSettings()),[g,d]=(0,n.useState)(null),{setValue:u}=(0,o.useDispatch)(r.n),{saveEmailReportingSettings:p,resetEmailReportingSettings:m}=(0,o.useDispatch)(a.oR),h=(0,n.useCallback)(()=>{e&&
(0,l.__)("Source: %s","google-site-kit"),`<a>${e}</a>`),{a:(0,d.jsx)(c.A,{href:t,external:s},"link")})})}SourceLink.propTypes={name:n().string,href:n().string,className:n().string,external:n().bool},SourceLink.defaultProps={name:"",href:"",className:"",external:!1};const u=SourceLink},91910:(e,t,i)=>{i.d(t,{a:()=>s});const s="sign-in-with-google"},92698:(e,t,i)=>{i.d(t,{A:()=>u});var s=i(63696),n=i(50539),o=i(93896),r=i(58116),a=i(37226),l=i(45472),c=i(21134),g=i(89318),d=i(77766);function u(e){const t=(0,d.A)(),i=(0,n.useSelect)(t=>t(a.i).getModule(e)),u=(0,n.useSelect)(e=>e(r.oR).hasCapability(r.HD)),{activateModule:p}=(0,n.useDispatch)(a.i),{navigateTo:m}=(0,n.useDispatch)(l.M),{setInternalServerError:h}=(0,n.useDispatch)(o.O4),f=(0,s.useCallback)(async()=>{const{error:i,response:s}=await p(e);i?h({id:`${e}-setup-error`,description:i.message}):(await(0,g.sx)(`${t}_widget-activation-cta`,"activate_module",e),await(0,c.SO)("module_setup",e,{ttl:300}),m(s.moduleReauthURL))},[p,e,m,h,t]);return i?.name&&u?f:null}},93515:(e,t,i)=>{i.d(t,{A:()=>CancelUserInputButton});var s=i(62688),n=i.n(s),o=i(82871),r=i(50539),a=i(49383),l=i(93896),c=i(45472),g=i(62540);function CancelUserInputButton({disabled:e}){const t=(0,r.useSelect)(e=>e(l.O4).getAdminURL("googlesitekit-dashboard")),{navigateTo:i}=(0,r.useDispatch)(c.M);return(0,g.jsx)(a.Button,{className:"googlesitekit-user-input__buttons--cancel",onClick:()=>i(t),disabled:e,tertiary:!0,children:(0,o.__)("Cancel","google-site-kit")})}CancelUserInputButton.propTypes={disabled:n().bool}},93896:(e,t,i)=>{i.d(t,{O4:()=>s,OQ:()=>o,qc:()=>n});const s="core/site",n="primary",o="secondary"},93934:(e,t,i)=>{i.d(t,{Y2:()=>s.Y2,DO:()=>g,c1:()=>d.c1,X9:()=>l,JS:()=>o,T5:()=>u,WP:()=>d.WP});var s=i(15135),n=i(81520);function o(e){return!!e&&e.Component===n.A}function r(e,t){if(9!==t)return[e,t];let i=(e=[...e]).length-1;for(;0!==t&&i>=0;)3===e[i]?(t-=3,e[i]=4):6===e[i]&&(t-=6,e[i]=8),i--;return[e,t]}function a(e,t){return(Array.isArray(t.width)?t.width:[t.width]).map(t=>({counter:e+s.Gr[t],width:t}))}function l(e,t){let i=[];const n=[];if(!e?.length)return{columnWidths:i,rowIndexes:n};let l=0,c=0;function g({counter:e},{counter:t}){return e-t}function d({counter:e},{counter:t}){return t-e}function u({counter:e}){return e<=12}return e.forEach((p,m)=>{if(o(t[p.slug]))return i.push(0),void n.push(c);let h=a(l,p);const f=function(e,t,i){for(;++e<t.length;)if(!o(i[t[e].slug]))return t[e];return null}(m,e,t);if(null===f||0===a(h.sort(g)[0].counter,f).filter(u).length){h.some(u)&&(h=h.sort(d),h=h.filter(u))}const _=h[0].width;n.push(c),l+=s.Gr[_],l>12?(l-=s.Gr[_],n[m]++,9===l&&([i,l]=r(i,l)),l=s.Gr[_],c++):12===l&&(l=0,c++),i.push(s.Gr[_])}),9===l&&([i,l]=r(i,l)),{columnWidths:i,rowIndexes:n}}var c=i(17243);function g(e,t,{columnWidths:i,rowIndexes:n}){const o=[],r=[...i];if(!e?.length)return{gridColumnWidths:r,overrideComponents:o};let a=null,l=-1,g=[];if(function(e,t){const i={};for(let n=0;n<e.length;n++){const o=e[n],r=t?.[o.slug],a=r?.Component,l=r?.metadata?.moduleSlug,c=s.We.includes(a);if(!a||!l||!c)return!1;if(i[l]){if(i[l]!==a)return!1}else i[l]=a}return!(Object.keys(i).length>1)}(e,t)){const i=Array.from({length:e.length-1}).fill(0);return{overrideComponents:[t[e[0].slug]],gridColumnWidths:[12,...i]}}return e.forEach((s,d)=>{if(o.push(null),a=t[s.slug],l=n[d],a)if(u=a,p=t[e[d+1]?.slug],m=l,h=n[d+1],m===h&&(0,c.isEqual)(u,p))g.push(i[d]),r[d]=0;else if(g.length>0){g.push(i[d]);const e=g.reduce((e,t)=>e+t,0);o[d]=a,r[d]=e,g=[]}var u,p,m,h}),{gridColumnWidths:r,overrideComponents:o}}var d=i(35001);function u(e){return(Array.isArray(e)?e:[e]).filter(e=>"string"==typeof e&&e.length>0)}},94552:(e,t,i)=>{i.d(t,{A:()=>l});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(62540);function ChangeArrow({direction:e,invertColor:t,width:i,height:s}){return(0,a.jsx)("svg",{className:r()("googlesitekit-change-arrow",`googlesitekit-change-arrow--${e}`,{"googlesitekit-change-arrow--inverted-color":t}),width:i,height:s,viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,a.jsx)("path",