- WordPress core y plugins - Tema Twenty Twenty-Four configurado - Plugin allow-unfiltered-html.php simplificado - .gitignore configurado para excluir wp-config.php y uploads 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
62 lines
435 KiB
JavaScript
Executable File
62 lines
435 KiB
JavaScript
Executable File
"use strict";(globalThis.__googlesitekit_webpackJsonp=globalThis.__googlesitekit_webpackJsonp||[]).push([[290,978],{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),d=i(78174),u=i(63696),g=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,u.useRef)();return(0,u.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,d.A)(e=>i&&g._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,focusTrapOptions:r().object},SelectionPanel.propTypes={children:r().node,isOpen:r().bool,isLoading:r().bool,onOpen:r().func,closePanel:r().func,className:r().string};var h=i(20898),f=i(72545),y=i(15167);function SelectionPanelHeader({children:e,title:t,onCloseClick:i}){return(0,m.jsxs)("header",{className:"googlesitekit-selection-panel-header",children:[(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-header__row",children:[(0,m.jsx)(y.A,{as:"h3",size:"small",type:"headline",children:t}),(0,m.jsx)(h.A,{className:"googlesitekit-selection-panel-header__close",onClick:i,linkButton:!0,children:(0,m.jsx)(f.A,{width:"15",height:"15"})})]}),e]})}SelectionPanelHeader.propTypes={children:r().node,title:r().string,onCloseClick:r().func};var v=i(82871),_=i(49383);function SelectionBox({badge:e,checked:t,children:i,disabled:s,id:o,onChange:r,title:a,value:l}){return(0,m.jsx)("div",{className:n()("googlesitekit-selection-box",{"googlesitekit-selection-box--disabled":s}),children:(0,m.jsx)(_.Checkbox,{checked:t,description:i,disabled:s,id:o,name:o,onChange:r,value:l,badge:e,children:a})})}SelectionBox.propTypes={badge:r().node,checked:r().bool,children:r().node,disabled:r().bool,id:r().string,onChange:r().func,title:r().string,value:r().string};var k=i(2362);function SelectionPanelItem({children:e,id:t,slug:i,title:s,description:n,isItemSelected:o,isItemDisabled:r,onCheckboxChange:a,subtitle:l,suffix:c,badge:d,isNewlyDetected:u}){return(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-item",children:[(0,m.jsxs)(SelectionBox,{badge:d,checked:o,disabled:r,id:t,onChange:a,title:s,value:i,children:[l&&(0,m.jsx)("span",{className:"googlesitekit-selection-panel-item__subtitle",children:l}),n,e]}),u&&(0,m.jsx)(k.A,{label:(0,v.__)("New","google-site-kit")}),c&&(0,m.jsx)("span",{className:"googlesitekit-selection-panel-item__suffix",children:c})]})}function SelectionPanelItems({currentSelectionTitle:e=(0,v.__)("Current selection","google-site-kit"),availableItemsTitle:t=(0,v.__)("Additional items","google-site-kit"),savedItemSlugs:i=[],availableSavedItems:s={},availableUnsavedItems:n={},ItemComponent:o,notice:r}){function a(e){return Object.keys(e).map(t=>(0,m.jsx)(o,{slug:t,savedItemSlugs:i,...e[t]},t))}const l=Object.keys(n).length;return(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-items",children:[0!==i.length&&(0,m.jsxs)(u.Fragment,{children:[(0,m.jsx)("p",{className:"googlesitekit-selection-panel-items__subheading",children:e}),(0,m.jsx)("div",{className:"googlesitekit-selection-panel-items__subsection",children:a(s)}),l>0&&(0,m.jsx)("p",{className:"googlesitekit-selection-panel-items__subheading",children:t})]}),l>0&&(0,m.jsx)("div",{className:"googlesitekit-selection-panel-items__subsection",children:a(n)}),r]})}SelectionPanelItem.propTypes={children:r().node,id:r().string,slug:r().string,title:r().string,description:r().string,isItemSelected:r().bool,isItemDisabled:r().bool,onCheckboxChange:r().func,subtitle:r().string,suffix:r().node,badge:r().node,isNewlyDetected:r().bool},SelectionPanelItems.propTypes={currentSelectionTitle:r().string,availableItemsTitle:r().string,savedItemSlugs:r().array,availableSavedItems:r().object,availableUnsavedItems:r().object,ItemComponent:r().elementType,notice:r().node};var x=i(17243),I=i(13606),A=i(50539),j=i(12850),M=i(72455),S=i(23224),b=i(80035);function SelectionPanelFooter({savedItemSlugs:e=[],selectedItemSlugs:t=[],saveSettings:i=()=>{},itemLimitError:s,minSelectedItemCount:n=0,maxSelectedItemCount:o=0,isBusy:r,onSaveSuccess:a=()=>{},onCancel:l=()=>{},isOpen:c,closePanel:d=()=>{}}){const[g,p]=(0,u.useState)(null),[h,f]=(0,u.useState)(!1),y=(0,A.useSelect)(e=>e(M.K9).isFetchingSyncAvailableAudiences()),k=(0,u.useMemo)(()=>!(0,x.isEqual)((0,j.N9)(t),(0,j.N9)(e)),[e,t]),N=e?.length>0&&k?(0,v.__)("Apply changes","google-site-kit"):(0,v.__)("Save selection","google-site-kit"),E=(0,u.useCallback)(async()=>{const{error:e}=await i(t);e||(a(),d(),p(N),f(!0))},[i,t,a,d,N]),w=(0,u.useCallback)(()=>{d(),l()},[d,l]),[C,T]=(0,u.useState)(null);(0,u.useEffect)(()=>{null!==C&&C!==c&&c&&(p(null),f(!1)),T(c)},[c,C]);const D=t?.length||0,R=y?(0,m.jsx)(S.A,{width:"89px",height:"20px"}):(0,m.jsx)("p",{className:"googlesitekit-selection-panel-footer__item-count",children:(0,I.A)((0,v.sprintf)(/* translators: 1: Number of selected items. 2: Maximum number of items that can be selected. */ /* translators: 1: Number of selected items. 2: Maximum number of items that can be selected. */
|
||
(0,v.__)("%1$d selected <MaxCount>(up to %2$d)</MaxCount>","google-site-kit"),D,o),{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:[k&&s?(0,m.jsx)(b.A,{type:b.A.TYPES.ERROR,description:s}):R,(0,m.jsxs)("div",{className:"googlesitekit-selection-panel-footer__actions",children:[(0,m.jsx)(_.Button,{onClick:w,disabled:r,tertiary:!0,children:(0,v.__)("Cancel","google-site-kit")}),(0,m.jsx)(_.SpinnerButton,{onClick:E,isSaving:r,disabled:D<n||D>o||r||!c&&h,children:g||N})]})]})})}SelectionPanelFooter.propTypes={savedItemSlugs:r().array,selectedItemSlugs:r().array,saveSettings:r().func,itemLimitError:r().string,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:()=>d});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 d=c},2390:(e,t,i)=>{i.d(t,{A:()=>SpinnerButton,k:()=>d});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 d={BEFORE:"before",AFTER:"after"};function SpinnerButton(e){const{className:t,onClick:i=()=>{},isSaving:s=!1,spinnerPosition:n=d.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===d.BEFORE,"googlesitekit-button-icon--spinner__after":n===d.AFTER}),icon:s&&n===d.BEFORE?(0,c.jsx)(l.A,{size:14}):void 0,trailingIcon:s&&n===d.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(d))}},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()),d=(0,n.A)(e=>e(a.n).getValue("forceInView"));return(0,o.useEffect)(()=>{t.value&&!i&&l(!0)},[i,t,l]),(0,o.useEffect)(()=>{d&&l(!0)},[d]),(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)}}},3288:(e,t,i)=>{i.d(t,{Q:()=>s});const s="emailReportingUserSettingsSelectionPanelOpened"},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(62540);function CTAButton({label:e,ariaLabel:t,disabled:i,inProgress:s,onClick:n,href:a}){return e&&(n||a)?(0,r.jsx)(o.SpinnerButton,{className:"googlesitekit-banner__cta","aria-label":t,disabled:i||s,isSaving:s,onClick:n,href:a,children:e}):null}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:()=>u});var s=i(62688),n=i.n(s),o=i(63696),r=i(81276),a=i(49383),l=i(8420),c=i(62540);let d=null;function RefocusableModalDialog({dialogActive:e=!1,refocusQuerySelector:t=null,...i}){const s=(0,o.useCallback)(()=>{setTimeout(()=>{const e=t?document.querySelector(t):d;e&&document.body.contains(e)&&e.focus(),t||(d=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")&&(d=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 u=RefocusableModalDialog},4884:(e,t,i)=>{i.d(t,{A:()=>u});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(49383),l=i(20898),c=i(15167),d=i(62540);function CTA({title:e,headerText:t,headerContent:i,description:s,ctaLink:n,ctaLabel:o,ctaLinkExternal:u,ctaType:g,error:p,onClick:m,"aria-label":h,children:f}){return(0,d.jsxs)("div",{className:r()("googlesitekit-cta",{"googlesitekit-cta--error":p}),children:[(t||i)&&(0,d.jsxs)("div",{className:"googlesitekit-cta__header",children:[t&&(0,d.jsx)(c.A,{as:"h2",size:"small",type:"label",className:"googlesitekit-cta__header_text",children:t}),i]}),(0,d.jsxs)("div",{className:"googlesitekit-cta__body",children:[e&&(0,d.jsx)(c.A,{as:"h3",size:"small",type:"title",className:"googlesitekit-cta__title",children:e}),s&&"string"==typeof s&&(0,d.jsx)("p",{className:"googlesitekit-cta__description",children:s}),s&&"string"!=typeof s&&(0,d.jsx)("div",{className:"googlesitekit-cta__description",children:s}),o&&"button"===g&&(0,d.jsx)(a.Button,{"aria-label":h,href:n,onClick:m,children:o}),o&&"link"===g&&(0,d.jsx)(l.A,{href:n,onClick:m,"aria-label":h,external:u,hideExternalIndicator:u,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 u=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});const s=(0,i(63696).createContext)(!1)},7070:(e,t,i)=>{i.d(t,{A:()=>r});var s=i(63696),n=i(77766),o=i(12850);function r(e,t,{viewAction:i="view_notification",confirmAction:r="confirm_notification",dismissAction:a="dismiss_notification",clickLearnMoreAction:l="click_learn_more_link"}={}){const c=(0,n.A)(),d=null!=t?t:`${c}_${e}`;return{view:(0,s.useCallback)((...e)=>(0,o.sx)(d,i,...e),[d,i]),confirm:(0,s.useCallback)((...e)=>(0,o.sx)(d,r,...e),[d,r]),dismiss:(0,s.useCallback)((...e)=>(0,o.sx)(d,a,...e),[d,a]),clickLearnMore:(0,s.useCallback)((...e)=>(0,o.sx)(d,l,...e),[d,l])}}},7081:(e,t,i)=>{i.d(t,{F:()=>n,n:()=>s});const s="core/ui",n="activeContextID"},7184:(e,t,i)=>{i.d(t,{A:()=>f});var s=i(4452),n=i.n(s),o=i(62688),r=i.n(o),a=i(63696),l=i(32947),c=i(62540);function TitleIcon({className:e,children:t}){return(0,c.jsx)("div",{className:n()("googlesitekit-banner__title-icon",e),children:t})}function Title({className:e,children:t}){return(0,c.jsx)("p",{className:n()("googlesitekit-banner__title",e),children:t})}TitleIcon.propTypes={className:r().string,children:r().node},Title.propTypes={className:r().string,children:r().node};var d=i(12850),u=i(30823);function Description({className:e,description:t,learnMoreLink:i,additionalDescription:s,children:o}){return(0,c.jsxs)("div",{className:n()("googlesitekit-banner__description",e),children:[(0,a.isValidElement)(t)?t:"string"==typeof t?(0,c.jsx)("span",{dangerouslySetInnerHTML:(0,d.p9)(t,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}):t," ",i?.href&&(0,c.jsx)(u.A,{...i}),s&&(0,c.jsx)("div",{className:"googlesitekit-banner__additional-description",children:s}),o]})}function HelpText({className:e,children:t}){return(0,c.jsx)("p",{className:n()("googlesitekit-banner__help-text",e),children:t})}Description.propTypes={className:r().string,description:r().oneOfType([r().string,r().node]),learnMoreLink:r().shape(u.A.propTypes),additionalDescription:r().oneOfType([r().string,r().node]),children:r().node},HelpText.propTypes={className:r().string,children:r().node};var g=i(3782),p=i(29584);function Footer({className:e,children:t}){return(0,c.jsx)("div",{className:n()("googlesitekit-banner__footer",e),children:t})}Footer.propTypes={className:r().string,children:r().node};var m=i(80035);const h=(0,a.forwardRef)(({className:e,titleIcon:t,title:i,description:s,additionalDescription:o,errorText:r,helpText:a,learnMoreLink:d,dismissButton:u,ctaButton:h,svg:f,footer:y},v)=>{const _=(0,l.dv)(),k=_===l.mp||_===l.Lg;let x=null;k&&f?.mobile?x=f.mobile:!k&&f?.desktop&&(x=f.desktop);const I=f?.verticalPosition?f.verticalPosition:"center";return(0,c.jsxs)("div",{ref:v,className:n()("googlesitekit-banner",e),children:[(0,c.jsxs)("div",{className:"googlesitekit-banner__content",children:[t&&(0,c.jsx)(TitleIcon,{children:t}),(0,c.jsx)(Title,{children:i}),(0,c.jsx)(Description,{description:s,learnMoreLink:d,additionalDescription:o}),a&&(0,c.jsx)(HelpText,{children:a}),r&&(0,c.jsx)(m.A,{type:"error",description:r}),(0,c.jsxs)("div",{className:"googlesitekit-notice__action",children:[h&&(0,c.jsx)(g.A,{...h}),u?.onClick&&(0,c.jsx)(p.A,{...u})]})]}),x&&(0,c.jsx)("div",{className:n()("googlesitekit-banner__svg-wrapper",{[`googlesitekit-banner__svg-wrapper--${I}`]:I}),style:{backgroundImage:`url(${x})`}}),y&&(0,c.jsx)(Footer,{children:y})]})});h.propTypes={titleIcon:r().node,title:r().string,description:r().oneOfType([r().string,r().node]),additionalDescription:r().oneOfType([r().string,r().node]),errorText:r().string,helpText:r().string,learnMoreLink:r().shape(u.A.propTypes),dismissButton:r().shape(p.A.propTypes),ctaButton:r().shape(g.A.propTypes),svg:r().shape({desktop:r().elementType,mobile:r().elementType,verticalPosition:r().oneOf(["top","center","bottom"])}),footer:r().node};const f=h},8143:(e,t,i)=>{i.d(t,{VZ:()=>o,dc:()=>r,pH:()=>n,r0:()=>a});var s=i(84024);function n(e){try{return new URL(e).pathname}catch{}return null}function o(e,t){try{return new URL(t,e).href}catch{}return("string"==typeof e?e:"")+("string"==typeof t?t:"")}function r(e){return"string"!=typeof e?e:e.replace(/^https?:\/\/(www\.)?/i,"").replace(/\/$/,"")}function a(e,t){if(!(0,s.m)(e))return e;if(e.length<=t)return e;const i=new URL(e),n=e.replace(i.origin,"");if(n.length<t)return n;const o=n.length-Math.floor(t)+1;return"…"+n.substr(o)}},8420:(e,t,i)=>{i.d(t,{A:()=>p});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(52684),l=i(13606),c=i(82871),d=i(49383),u=i(85149),g=i(62540);function ModalDialog({className:e="",dialogActive:t=!1,handleCancel:i=null,onOpen:s=null,onClose:n=null,title:o=null,provides:p,handleConfirm:m,subtitle:h,confirmButton:f=null,dependentModules:y,danger:v=!1,inProgress:_=!1,small:k=!1,medium:x=!1,buttonLink:I=null}){const A=`googlesitekit-dialog-description-${(0,a.A)(ModalDialog)}`,j=!(!p||!p.length);return(0,g.jsxs)(d.Dialog,{open:t,onOpen:s,onClose:n,"aria-describedby":j?A:void 0,tabIndex:"-1",className:r()(e,{"googlesitekit-dialog-sm":k,"googlesitekit-dialog-md":x}),children:[(0,g.jsxs)(d.DialogTitle,{children:[v&&(0,g.jsx)(u.A,{width:28,height:28}),o]}),h?(0,g.jsx)("p",{className:"mdc-dialog__lead",children:h}):[],(0,g.jsxs)(d.DialogContent,{children:[j&&(0,g.jsx)("section",{id:A,className:"mdc-dialog__provides",children:(0,g.jsx)("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive",children:p.map(e=>(0,g.jsx)("li",{className:"mdc-list-item",children:(0,g.jsx)("span",{className:"mdc-list-item__text",children:e})},e))})}),y&&(0,g.jsx)("p",{className:"mdc-dialog__dependencies",children:(0,l.A)((0,c.sprintf)(/* translators: %s is replaced with the dependent modules. */ /* translators: %s is replaced with the dependent modules. */
|
||
(0,c.__)("<strong>Note:</strong> %s","google-site-kit"),y),{strong:(0,g.jsx)("strong",{})})})]}),(0,g.jsxs)(d.DialogFooter,{children:[(0,g.jsx)(d.Button,{className:"mdc-dialog__cancel-button",onClick:i,disabled:_,tertiary:!0,children:(0,c.__)("Cancel","google-site-kit")}),I?(0,g.jsx)(d.Button,{href:I,onClick:m,target:"_blank",danger:v,children:f}):(0,g.jsx)(d.SpinnerButton,{onClick:m,danger:v,disabled:_,isSaving:_,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}},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 d(){return d=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},d.apply(null,arguments)}const u=e=>c.createElement("svg",d({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 g=i(62540);function InfoTooltip({onOpen:e,title:t,tooltipClassName:i}){return t?(0,g.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,g.jsx)("span",{children:(0,g.jsx)(u,{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)},11253:(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 16 12"},e),s||(s=n.createElement("g",{fill:"currentColor",fillRule:"evenodd"},n.createElement("path",{d:"M0 6.414 1.415 5l5.292 5.292-1.414 1.415z"}),n.createElement("path",{d:"m14.146.146 1.415 1.414L5.414 11.707 4 10.292z"}))))},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(50539),c=i(37226),d=i(67150),u=i(65311),g=i(15210),p=i(4884),m=i(35902),h=i(35323),f=i(77967),y=i(62540);function ReportError({moduleSlug:e,error:t}){const i=(0,h.A)(),s=(0,l.useSelect)(t=>t(c.i).getModule(e)),n=Array.isArray(t)?t:[t];let v;function _(e){return(0,d.SG)(e)?i?(v=(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 won’t 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)):(v=(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 k=(0,o.uniqWith)(n.map(e=>({...e,message:_(e),reconnectURL:e.data?.reconnectURL})),(e,t)=>e.message===t.message&&e.reconnectURL===t.reconnectURL),x=n.some(e=>(0,d.SG)(e));x||1!==k.length?!x&&k.length>1&&(v=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
|
||
(0,a.__)("Data errors in %s","google-site-kit"),s?.name)):v=(0,a.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
|
||
(0,a.__)("Data error in %s","google-site-kit"),s?.name);const I=(0,y.jsx)(r.Fragment,{children:k.map(e=>{const t=e?.data?.reconnectURL;return t?(0,y.jsx)(f.A,{error:e,message:e.message},e.message):(0,y.jsx)("p",{children:g.O.sanitize(e.message,{ALLOWED_TAGS:[]})},e.message)})});return(0,y.jsx)(p.A,{title:v,description:I,error:!0,children:(0,y.jsx)(m.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),d=i(82871),u=i(54312),g=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,d.__)("Site Kit encountered an error","google-site-kit"),description:(0,h.jsxs)(a.Fragment,{children:[(0,h.jsx)(u.A,{message:t.message,componentStack:i.componentStack}),(0,h.jsxs)("pre",{className:"googlesitekit-overflow-auto",children:[t.message,i.componentStack]})]})}):e}}ErrorHandler.contextType=g.Ay,ErrorHandler.propTypes={children:n().node.isRequired};const f=ErrorHandler;var y=i(11106);const{Consumer:v,Provider:_}=y.A,k=_;var x=i(65214),I=i(4445),A=i(78340),j=i(45472),M=i(58116),S=i(64067),b=i(14007);const N=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)(j.M),{setValues:c}=(0,l.useDispatch)(A.s),u=(0,a.useCallback)(()=>{o()},[o]),g=(0,a.useCallback)(async()=>{c(M.$8,{permissionsError:t}),await(0,S.mR)(e),r(n)},[e,n,r,t,c]);return(0,a.useEffect)(()=>{!async function(){t?.data?.skipModal&&t?.data?.scopes?.length&&await g()}()},[g,t]),t?t?.data?.scopes?.length?t?.data?.skipModal||s&&t?.data?.scopes.every(e=>s.includes(e))?null:(0,h.jsx)(b.A,{children:(0,h.jsx)(I.A,{title:(0,d.__)("Additional Permissions Required","google-site-kit"),subtitle:t.message,confirmButton:(0,d.__)("Proceed","google-site-kit"),handleConfirm:g,handleCancel:u,onClose:u,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)(N,{}):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,S.P9)(t),s(!0)})()},[t,i]),i?e:null};var C=i(15844),T=i(77766),D=i(39771);function FeatureTours(){const e=(0,T.A)(),{triggerTourForView:t}=(0,l.useDispatch)(M.oR);(0,C.A)(()=>{t(e)});const s=(0,l.useSelect)(e=>e(M.oR).getCurrentTour());return(0,a.useEffect)(()=>{if(!s)return()=>{};const e=document.getElementById("js-googlesitekit-main-dashboard");if(!e)return()=>{};const t=new ResizeObserver(()=>{i.g.dispatchEvent(new Event("resize"))});return t.observe(e),()=>{t.disconnect()}},[s]),s?(0,h.jsx)(D.Ay,{tourID:s.slug,steps:s.steps,gaEventCategory:s.gaEventCategory,callback:s.callback}):null}var R=i(68869),O=i(22821);function Root({children:e,registry:t,viewContext:i=null}){const s=o.D,[n]=(0,a.useState)({key:"Root",value:!0});return(0,h.jsx)(a.StrictMode,{children:(0,h.jsx)(R.Ay,{value:n,children:(0,h.jsx)(l.RegistryProvider,{value:t,children:(0,h.jsx)(k,{value:x.t,children:(0,h.jsx)(g.Kq,{value:i,children:(0,h.jsx)(r.A,{theme:s(),children:(0,h.jsxs)(f,{children:[(0,h.jsxs)(w,{children:[e,i&&(0,h.jsx)(FeatureTours,{})]}),(0,O.A)(i)&&(0,h.jsx)(E,{})]})})})})})})})}Root.propTypes={children:n().node,registry:n().object,viewContext:n().string.isRequired},Root.defaultProps={registry:c()}},12755:(e,t,i)=>{i.d(t,{A:()=>qe});var s,n,o=i(62688),r=i.n(o),a=i(4452),l=i.n(a),c=i(41814),d=i(82871),u=i(63696),g=i(50539),p=i(99455),m=i(21795),h=i(31589),f=i(19266),y=i(49383),v=i(8420),_=i(12850),k=i(21134),x=i(14007),I=i(58116),A=i(62540);function Details(){const e=(0,g.useSelect)(e=>e(I.oR).getPicture()),t=(0,g.useSelect)(e=>e(I.oR).getFullName()),i=(0,g.useSelect)(e=>e(I.oR).getEmail());return(0,A.jsxs)("div",{className:"googlesitekit-user-menu__details","aria-label":(0,d.__)("Google account","google-site-kit"),children:[!!e&&(0,A.jsx)("img",{className:"googlesitekit-user-menu__details-avatar",src:e,alt:""}),(0,A.jsxs)("div",{className:"googlesitekit-user-menu__details-info",children:[(0,A.jsx)("p",{className:"googlesitekit-user-menu__details-info__name",children:t}),(0,A.jsx)("p",{className:"googlesitekit-user-menu__details-info__email","aria-label":(0,d.__)("Email","google-site-kit"),children:i})]})]})}function Item({icon:e,label:t}){return(0,A.jsxs)("div",{className:"googlesitekit-user-menu__item",children:[(0,A.jsx)("div",{className:"googlesitekit-user-menu__item-icon",children:e}),(0,A.jsx)("span",{className:"googlesitekit-user-menu__item-label",children:t})]})}function j(){return j=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},j.apply(null,arguments)}Item.propTypes={icon:r().node,label:r().string};const M=e=>u.createElement("svg",j({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},e),s||(s=u.createElement("path",{stroke:"#6C726E",strokeLinecap:"round",strokeWidth:1.7,d:"m11.775 5.701.58-.58a4.547 4.547 0 0 1 6.43 0v0a4.547 4.547 0 0 1 0 6.43l-.598.599m-12.504-.357-.562.562a4.547 4.547 0 0 0 0 6.43v0a4.547 4.547 0 0 0 6.43 0l.58-.58"})),n||(n=u.createElement("path",{stroke:"#6C726E",strokeLinecap:"round",strokeWidth:1.5,d:"m8.543 15.363 1.118-1.118m5.684-5.684L14.226 9.68M5.107 5.134l13.664 13.664"})));var S,b,N,E,w;function C(){return C=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},C.apply(null,arguments)}const T=e=>u.createElement("svg",C({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},e),S||(S=u.createElement("rect",{width:18,height:13,x:3,y:4,stroke:"#6C726E",strokeWidth:1.5,rx:2})),b||(b=u.createElement("path",{fill:"#6C726E",d:"M9 17h6v3H9z"})),N||(N=u.createElement("path",{stroke:"#6C726E",strokeLinecap:"round",strokeWidth:1.5,d:"M10 9h7M10 12h7"})),E||(E=u.createElement("circle",{cx:7,cy:9,r:1,fill:"#6C726E"})),w||(w=u.createElement("circle",{cx:7,cy:12,r:1,fill:"#6C726E"})));var D,R,O;function z(){return z=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},z.apply(null,arguments)}const L=e=>u.createElement("svg",z({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24"},e),D||(D=u.createElement("rect",{width:18,height:12,x:3,y:6,stroke:"#6C726E",strokeWidth:1.5,rx:2})),R||(R=u.createElement("path",{stroke:"#6C726E",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"m3.566 7.5 7.086 7.086a2 2 0 0 0 2.829 0l7.019-7.02"})),O||(O=u.createElement("path",{stroke:"#6C726E",strokeLinecap:"round",strokeWidth:1.5,d:"M20.246 17.5 15.5 12.754M4 17.5l4.746-4.746"})));var B=i(93896),P=i(7081),G=i(45472),U=i(72455),V=i(3288),F=i(99235),W=i(77766),H=i(27333),Y=i(6464);function UserMenu(){const e=(0,Y.i)("proactiveUserEngagement"),t=(0,g.useSelect)(e=>e(B.O4).getProxyPermissionsURL()),i=(0,g.useSelect)(e=>e(I.oR).getEmail()),s=(0,g.useSelect)(e=>e(I.oR).getPicture()),n=(0,g.useSelect)(e=>e(I.oR).getFullName()),o=(0,g.useSelect)(e=>e(B.O4).getAdminURL("googlesitekit-splash",{googlesitekit_context:"revoked"})),r=(0,H.A)(U.CV,"isAutoCreatingCustomDimensionsForAudience"),[a,l]=(0,u.useState)(!1),[c,p]=(0,u.useState)(!1),j=(0,u.useRef)(),S=(0,u.useRef)(),b=(0,W.A)(),{navigateTo:N}=(0,g.useDispatch)(G.M);(0,m.A)(j,()=>p(!1)),(0,F.l)([f._f,f.wn],j,()=>{p(!1),S.current?.focus()});const E=(0,u.useCallback)(()=>{l(!1),p(!1)},[l,p]),w=(0,u.useCallback)(e=>{f._f===e.keyCode&&E()},[E]);(0,h.A)("keyup",w);const C=(0,u.useCallback)(()=>{c||(0,_.sx)(`${b}_headerbar`,"open_usermenu"),p(!c)},[c,b]),D=(0,u.useCallback)(()=>{l(!a),p(!1)},[a]),{setValue:R}=(0,g.useDispatch)(P.n),O=(0,u.useCallback)(async(e,i)=>{const{detail:{item:s}}=i;switch(s?.id){case"manage-sites":t&&(await(0,_.sx)(`${b}_headerbar_usermenu`,"manage_sites"),N(t));break;case"disconnect":D();break;case"manage-email-reports":R(V.Q,!0);break;default:C()}},[t,C,D,N,R,b]),z=(0,u.useCallback)(async()=>{l(!1),await(0,k.IL)(),await(0,_.sx)(`${b}_headerbar_usermenu`,"disconnect_user"),N(o)},[o,N,b]);if(!i)return null;let Z;return n&&i&&(Z=(0,d.sprintf)(/* translators: Account info text. 1: User's (full) name 2: User's email address. */ /* translators: Account info text. 1: User's (full) name 2: User's email address. */
|
||
(0,d.__)("Google Account for %1$s (Email: %2$s)","google-site-kit"),n,i)),n&&!i&&(Z=(0,d.sprintf)(/* translators: Account info text. 1: User's (full) name. */ /* translators: Account info text. 1: User's (full) name. */
|
||
(0,d.__)("Google Account for %1$s","google-site-kit"),n)),!n&&i&&(Z=(0,d.sprintf)(/* translators: Account info text. 1: User's email address. */ /* translators: Account info text. 1: User's email address. */
|
||
(0,d.__)("Google Account (Email: %1$s)","google-site-kit"),i)),(0,A.jsxs)(u.Fragment,{children:[(0,A.jsxs)("div",{ref:j,className:"googlesitekit-user-selector googlesitekit-dropdown-menu googlesitekit-dropdown-menu__icon-menu mdc-menu-surface--anchor",children:[(0,A.jsx)(y.Button,{disabled:r,ref:S,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,A.jsx)("i",{className:"mdc-button__icon mdc-button__account","aria-hidden":"true",children:(0,A.jsx)("img",{className:"mdc-button__icon--image",src:s,alt:(0,d.__)("User Avatar","google-site-kit")})}),"aria-haspopup":"menu","aria-expanded":c,"aria-controls":"user-menu","aria-label":r?void 0:(0,d.__)("Account","google-site-kit"),tooltipEnterDelayInMS:500,customizedTooltip:r?null:(0,A.jsxs)("span",{"aria-label":Z,children:[(0,A.jsx)("strong",{children:(0,d.__)("Google Account","google-site-kit")}),(0,A.jsx)("br",{}),(0,A.jsx)("br",{}),n,n&&(0,A.jsx)("br",{}),i]}),text:!0,tooltip:!0}),(0,A.jsxs)(y.Menu,{className:"googlesitekit-user-menu",menuOpen:c,onSelected:O,id:"user-menu",children:[(0,A.jsx)("li",{children:(0,A.jsx)(Details,{})}),e&&(0,A.jsx)("li",{id:"manage-email-reports",className:"mdc-list-item",role:"menuitem",children:(0,A.jsx)(Item,{icon:(0,A.jsx)(L,{width:"24"}),label:(0,d.__)("Manage email reports","google-site-kit")})}),!!t&&(0,A.jsx)("li",{id:"manage-sites",className:"mdc-list-item",role:"menuitem",children:(0,A.jsx)(Item,{icon:(0,A.jsx)(T,{width:"24"}),label:(0,d.__)("Manage Sites","google-site-kit")})}),(0,A.jsx)("li",{id:"disconnect",className:"mdc-list-item",role:"menuitem",children:(0,A.jsx)(Item,{icon:(0,A.jsx)(M,{width:"24"}),label:(0,d.__)("Disconnect","google-site-kit")})})]})]}),(0,A.jsx)(x.A,{children:(0,A.jsx)(v.A,{dialogActive:a,handleConfirm:z,handleCancel:E,onClose:E,title:(0,d.__)("Disconnect","google-site-kit"),subtitle:(0,d.__)("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,d.__)("Disconnect","google-site-kit"),danger:!0,small:!0})})]})}var Z=i(55527),Q=i(35323),q=i(29898),K=i(15844),X=i(39525),$=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=>u.createElement("svg",ae({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 18 18"},e),re||(re=u.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,de,ue,ge;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=>u.createElement("svg",pe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 13 12"},e),ce||(ce=u.createElement("rect",{width:5,height:5,x:.5,fill:"currentColor",rx:1})),de||(de=u.createElement("rect",{width:5,height:5,x:7.5,fill:"currentColor",rx:1})),ue||(ue=u.createElement("rect",{width:5,height:5,x:.5,y:7,fill:"currentColor",rx:1})),ge||(ge=u.createElement("rect",{width:5,height:5,x:7.5,y:7,fill:"currentColor",rx:1})));var he;function fe(){return fe=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},fe.apply(null,arguments)}const ye=e=>u.createElement("svg",fe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 23 12"},e),he||(he=u.createElement("path",{fill:"currentColor",d:"M16.1 0v2h2.967l-5.946 5.17-4.6-4L0 10.59 1.622 12l6.9-6 4.6 4L20.7 3.42V6H23V0z"})));var ve,_e;function ke(){return ke=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},ke.apply(null,arguments)}const xe=e=>u.createElement("svg",ke({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 16"},e),ve||(ve=u.createElement("path",{fill:"currentColor",d:"m18.378 4.543-1.232 1.854a8.02 8.02 0 0 1-.22 7.598H3.043A8.02 8.02 0 0 1 4.154 4.49 8.01 8.01 0 0 1 13.57 2.82l1.853-1.233A10.01 10.01 0 0 0 3.117 2.758a10.026 10.026 0 0 0-1.797 12.24A2 2 0 0 0 3.043 16h13.873a2 2 0 0 0 1.742-1.002 10.03 10.03 0 0 0-.27-10.465z"})),_e||(_e=u.createElement("path",{fill:"currentColor",d:"M8.572 11.399a2.003 2.003 0 0 0 2.835 0l5.669-8.51-8.504 5.673a2.005 2.005 0 0 0 0 2.837"})));var Ie;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 je=e=>u.createElement("svg",Ae({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 18 16"},e),Ie||(Ie=u.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M7 0h3.971v16H7zM0 8h4v8H0zm18-3h-4v11h4z",clipRule:"evenodd"})));function Navigation(){const e=(0,ee.Ay)(),t=(0,u.useRef)(),s=(0,W.A)(),n=function(){const e=(0,ee.Ay)(),t=(0,Q.A)();return(0,g.useSelect)(i=>{const s=t?i(I.oR).getViewableModules():null,n=i(I.oR).isKeyMetricsWidgetHidden(),o={modules:s||void 0};return Object.keys(oe[e]).reduce((t,s)=>(s===J.SH&&n||i(ne.aO).isWidgetContextActive(oe[e][s],o)&&t.push(s),t),[])})}(),{calculateScrollPosition:o,defaultChipID:r,findClosestSection:a,isValidChipID:c,scrollToChip:p,updateURLHash:m}=function({visibleSections:e}){const t=(0,ie.dv)(),s=(0,Q.A)(),n=(0,u.useCallback)(()=>e.includes(J.SH)?J.SH:s?e[0]||"":J.OT,[s,e])(),o=(0,u.useCallback)(t=>e.includes(t),[e]),r=(0,u.useCallback)(e=>{i.g.history.replaceState({},"",`#${e}`)},[]),a=(0,u.useCallback)(e=>e!==n?(0,te.YJ)(`#${e}`,t):0,[t,n]),l=(0,u.useCallback)(e=>{i.g.scrollTo({top:a(e,t,n),behavior:"smooth"})},[t,a,n]),c=(0,u.useCallback)(t=>{var i;const s=document.querySelector(".googlesitekit-entity-header")?.getBoundingClientRect?.()?.bottom,{bottom:o}=null!==(i=t?.current?.getBoundingClientRect?.())&&void 0!==i?i:{};let r,a=n;for(const t of e){const e=document.getElementById(t);if(!e)continue;const i=e.getBoundingClientRect().top-20-(s||o||0);i<0&&(void 0===r||r<i)&&(r=i,a=t)}return a},[n,e]);return{calculateScrollPosition:a,defaultChipID:n,findClosestSection:c,isValidChipID:o,scrollToChip:l,updateURLHash:r}}({visibleSections:n}),f=i.g.location.hash?.substring(1),[y,v]=(0,u.useState)(f||void 0),[k,x]=(0,u.useState)(!1),[j,M]=(0,u.useState)(f),{setValue:S}=(0,g.useDispatch)(P.n),b=(0,u.useCallback)(({target:e})=>{const t=e.closest(".mdc-chip"),i=t?.dataset?.contextId;m(i),v(i),p(i),(0,_.sx)(`${s}_navigation`,"tab_select",i),setTimeout(()=>{S(P.F,i)},50)},[p,S,m,s]),N=(0,u.useCallback)(()=>{if(!t?.current)return;const{top:e}=t?.current?.getBoundingClientRect();if(0===i.g.scrollY)x(!1);else{const t=document.querySelector(".googlesitekit-header")?.getBoundingClientRect?.()?.bottom;x(e===t)}},[]),E=(0,u.useCallback)(e=>{function n(e){S(P.F,void 0),M(e),v(void 0)}const o=a(t);if(y)y===o&&n(o);else{const{hash:t}=i.g.location;o!==t?.substring(1)&&(e&&(0,_.sx)(`${s}_navigation`,"tab_scroll",o),m(o),n(o))}},[a,y,S,m,s]);(0,K.A)(()=>{if(!f)return M(r),void setTimeout(()=>m(r));const e=c(f)?f:r;M(e),S(P.F,e),setTimeout(()=>{const t=o(e);i.g.scrollY!==t?p(e):S(P.F,void 0)},50)});const w=(0,u.useCallback)(e=>{N(),E(e)},[E,N]),C=(0,$.A)(w,150);(0,h.A)("scroll",C);const T={[J.SH]:{label:(0,d.__)("Key metrics","google-site-kit"),icon:(0,A.jsx)(me,{width:"18",height:"16"})},[J.OT]:{label:(0,d.__)("Traffic","google-site-kit"),icon:(0,A.jsx)(je,{width:"18",height:"16"})},[J.en]:{label:(0,d.__)("Content","google-site-kit"),icon:(0,A.jsx)(le,{width:"18",height:"18"})},[J.Ej]:{label:(0,d.__)("Speed","google-site-kit"),icon:(0,A.jsx)(xe,{width:"20",height:"16"})},[J.Gw]:{label:(0,d.__)("Monetization","google-site-kit"),icon:(0,A.jsx)(ye,{width:"18",height:"16"})}};return(0,A.jsx)("nav",{className:l()("mdc-chip-set","googlesitekit-navigation",`googlesitekit-navigation--${e}`,{"googlesitekit-navigation--is-sticky":k}),ref:t,children:n.map(e=>(0,A.jsx)(X.Chip,{id:e,label:T[e].label,leadingIcon:T[e].icon,onClick:b,selected:j===e,"data-context-id":e},e))})}function DashboardNavigation(){const e=(0,Q.A)(),t=(0,g.useSelect)(t=>e?t(I.oR).getViewableModules():null),i=(0,g.useSelect)(e=>e(I.oR).getKeyMetrics());return(0,A.jsx)(q.A,{loading:void 0===t||void 0===i,width:"100%",smallHeight:"59px",height:"71px",children:(0,A.jsx)(Navigation,{})})}var Me,Se;function be(){return be=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},be.apply(null,arguments)}const Ne=e=>u.createElement("svg",be({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},e),Me||(Me=u.createElement("path",{fill:"none",d:"M0 0h24v24H0z"})),Se||(Se=u.createElement("path",{fill:"currentColor",d:"M21 11H6.83l3.58-3.59L9 6l-6 6 6 6 1.41-1.41L6.83 13H21z"})));var Ee=i(20898),we=i(59323),Ce=i(8143);const Te=function EntityHeader(){const e=(0,W.A)(),t=(0,ee.Ay)(),s=(0,g.useSelect)(e=>e(B.O4).getCurrentEntityTitle()),n=(0,g.useSelect)(e=>e(B.O4).getCurrentEntityURL()),o=(0,u.useRef)(),[r,a]=(0,u.useState)(n),l=(0,u.useCallback)(()=>{if(!o.current)return;const e=o.current.clientWidth-40,t=i.g.getComputedStyle(o.current.lastChild,null).getPropertyValue("font-size"),s=2*e/parseFloat(t);a((0,Ce.r0)(n,s))},[n]),c=(0,$.A)(l,150);(0,h.A)("resize",c);const{navigateTo:p}=(0,g.useDispatch)(G.M),m=(0,g.useSelect)(e=>e(B.O4).getAdminURL("googlesitekit-dashboard")),f=(0,u.useCallback)(()=>{(0,_.sx)(`${e}_navigation`,"return_to_dashboard"),p(m)},[m,p,e]);return ee.oE!==t||null===n||null===s?null:(0,A.jsxs)("div",{className:"googlesitekit-entity-header",children:[(0,A.jsx)("div",{className:"googlesitekit-entity-header__back",children:(0,A.jsx)(y.Button,{icon:(0,A.jsx)(Ne,{width:24,height:24}),"aria-label":(0,d.__)("Back to dashboard","google-site-kit"),onClick:f,text:!0,tertiary:!0,children:(0,d.__)("Back to dashboard","google-site-kit")})}),(0,A.jsxs)("div",{ref:o,className:"googlesitekit-entity-header__details",children:[(0,A.jsx)(we.A,{children:s}),(0,A.jsx)(Ee.A,{href:n,"aria-label":n,secondary:!0,external:!0,children:r})]})]})};var De;function Re(){return Re=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},Re.apply(null,arguments)}const Oe=e=>u.createElement("svg",Re({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 16 10"},e),De||(De=u.createElement("path",{fill:"currentColor",d:"M8 1.333c2.756 0 5.214 1.42 6.415 3.667-1.2 2.247-3.659 3.667-6.415 3.667S2.785 7.247 1.585 5C2.785 2.753 5.244 1.333 8 1.333M8 0C4.364 0 1.258 2.073 0 5c1.258 2.927 4.364 5 8 5s6.742-2.073 8-5c-1.258-2.927-4.364-5-8-5m0 3.333c1.004 0 1.818.747 1.818 1.667S9.004 6.667 8 6.667 6.182 5.92 6.182 5 6.996 3.333 8 3.333M8 2C6.196 2 4.727 3.347 4.727 5S6.197 8 8 8s3.273-1.347 3.273-3S9.803 2 8 2"})));var ze=i(13606);function Description(){const e=(0,W.A)(),t=(0,g.useSelect)(e=>e(I.oR).hasCapability(I.ej)),i=(0,g.useSelect)(e=>e(B.O4).getProxySetupURL()),s=(0,g.useSelect)(e=>e(B.O4).getDocumentationLinkURL("dashboard-sharing")),{navigateTo:n}=(0,g.useDispatch)(G.M),o=(0,u.useCallback)(async t=>{t.preventDefault(),await Promise.all([(0,k.SO)("start_user_setup",!0),(0,_.sx)(`${e}_headerbar_viewonly`,"start_user_setup",i?"proxy":"custom-oauth")]),n(i)},[i,n,e]),r=(0,u.useCallback)(()=>{(0,_.sx)(`${e}_headerbar_viewonly`,"click_learn_more_link")},[e]),a=t?(0,ze.A)((0,d.__)("You can see stats from all shared Google services, but you can't make any changes. <strong>Sign in to connect more services and control sharing access.</strong>","google-site-kit"),{strong:(0,A.jsx)("strong",{})}):(0,ze.A)((0,d.__)("You can see stats from all shared Google services, but you can't make any changes. <a>Learn more</a>","google-site-kit"),{a:(0,A.jsx)(Ee.A,{href:s,onClick:r,"aria-label":(0,d.__)("Learn more about dashboard sharing","google-site-kit"),external:!0})});return(0,A.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item googlesitekit-view-only-menu__description",children:[(0,A.jsx)(we.A,{children:a}),t&&(0,A.jsx)(y.Button,{onClick:o,children:(0,d._x)("Sign in with Google","Service name","google-site-kit")})]})}var Le=i(37226);function Service({module:e}){const t=(0,g.useSelect)(e=>e(I.oR).hasCapability(I.ej)),{name:i,owner:s}=(0,g.useSelect)(t=>t(Le.i).getModule(e)||{}),n=(0,g.useSelect)(t=>t(Le.i).getModuleIcon(e));return(0,A.jsxs)("li",{className:"googlesitekit-view-only-menu__service",children:[(0,A.jsx)("span",{className:"googlesitekit-view-only-menu__service--icon",children:(0,A.jsx)(n,{height:26})}),(0,A.jsx)("span",{className:"googlesitekit-view-only-menu__service--name",children:i}),t&&s?.login&&(0,A.jsx)("span",{className:"googlesitekit-view-only-menu__service--owner",children:(0,ze.A)((0,d.sprintf)(/* translators: %s: module owner Google Account email address */ /* translators: %s: module owner Google Account email address */
|
||
(0,d.__)("Shared by <strong>%s</strong>","google-site-kit"),s.login),{strong:(0,A.jsx)("strong",{title:s.login})})})]})}Service.propTypes={module:r().string.isRequired};var Be=i(15167);function SharedServices(){const e=(0,g.useSelect)(e=>e(I.oR).getViewableModules());return void 0===e?null:(0,A.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,A.jsx)(Be.A,{as:"h4",size:"large",type:"title",children:(0,d.__)("Shared services","google-site-kit")}),(0,A.jsx)("ul",{children:e.map(e=>(0,A.jsx)(Service,{module:e},e))})]})}var Pe=i(82167);function Tracking(){const e=(0,W.A)();return(0,A.jsxs)("li",{className:"googlesitekit-view-only-menu__list-item",children:[(0,A.jsx)(we.A,{children:(0,ze.A)((0,d.__)("Thanks for using Site Kit!<br />Help us make it even better","google-site-kit"),{br:(0,A.jsx)("br",{})})}),(0,A.jsx)(Pe.A,{trackEventCategory:`${e}_headerbar_viewonly`,alignCheckboxLeft:!0})]})}var Ge=i(74595);function ManageEmailReports(){const{setValue:e}=(0,Ge.wA)(P.n);return(0,A.jsxs)(u.Fragment,{children:[(0,A.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,A.jsx)("li",{className:"googlesitekit-view-only-menu__list-item googlesitekit-view-only-menu__email-reporting",children:(0,A.jsx)("ul",{className:"googlesitekit-view-only-menu",children:(0,A.jsx)("li",{className:"googlesitekit-view-only-menu__email-reporting-item",children:(0,A.jsx)(y.Button,{onClick:()=>e(V.Q,!0),icon:(0,A.jsx)("span",{className:"googlesitekit-view-only-menu__email-reporting-item--icon",children:(0,A.jsx)(L,{width:"24"})}),tertiary:!0,children:(0,A.jsx)("span",{className:"googlesitekit-view-only-menu__email-reporting-item--name",children:(0,d.__)("Manage email reports","google-site-kit")})})})})})]})}function ViewOnlyMenu(){const e=(0,Y.i)("proactiveUserEngagement"),[t,i]=(0,u.useState)(!1),s=(0,u.useRef)(),n=(0,W.A)();(0,m.A)(s,()=>i(!1)),(0,F.l)([f._f,f.wn],s,()=>i(!1));const o=(0,u.useCallback)(()=>{t||(0,_.sx)(`${n}_headerbar`,"open_viewonly"),i(!t)},[t,n]),r=(0,g.useSelect)(e=>e(I.oR).hasCapability(I.ej));return(0,A.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,A.jsx)(y.Button,{className:"googlesitekit-header__dropdown mdc-button--dropdown googlesitekit-border-radius-round--phone googlesitekit-button-icon",onClick:o,icon:(0,A.jsx)("span",{className:"mdc-button__icon","aria-hidden":"true",children:(0,A.jsx)(Oe,{className:"mdc-button__icon--image"})}),"aria-haspopup":"menu","aria-expanded":t,"aria-controls":"view-only-menu","aria-label":(0,d.__)("View only","google-site-kit"),tooltipEnterDelayInMS:500,text:!0,tooltip:!0,children:(0,d.__)("View only","google-site-kit")}),(0,A.jsxs)(y.Menu,{menuOpen:t,onSelected:o,id:"view-only-menu",nonInteractive:!0,children:[(0,A.jsx)(Description,{}),(0,A.jsx)(SharedServices,{}),e&&(0,A.jsx)(ManageEmailReports,{}),(0,A.jsx)("li",{className:"mdc-list-divider",role:"separator"}),(0,A.jsx)(Tracking,{})]})]})}var Ue=i(71423),Ve=i(53137),Fe=i(77513);function CoreSiteBannerNotification({id:e,...t}){const{dismissNotification:i,acceptNotification:s}=(0,g.useDispatch)(B.O4),n=(0,u.useCallback)(()=>{s(e)},[e,s]),o=(0,u.useCallback)(()=>{i(e)},[e,i]);return(0,A.jsx)(Fe.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,d.__)("OK, Got it!","google-site-kit"),dismissible:!0,learnMoreLabel:"",learnMoreURL:""};const We=CoreSiteBannerNotification;const He=function CoreSiteBannerNotifications(){const e=(0,W.A)(),[t,i]=(0,u.useState)(!1),[s,n]=(0,u.useState)(!1),o=(0,u.useRef)(Date.now()),r=(0,g.useSelect)(e=>e(B.O4).isUsingProxy()&&!1===e(I.oR).areSurveysOnCooldown()?e(I.oR).getCurrentSurvey():null),[a,l]=(0,u.useState)([]),{registerNotification:c}=(0,g.useDispatch)(Ue.D),d=(0,g.useSelect)(e=>e(B.O4).getNotifications());return(0,u.useEffect)(()=>{const e=setTimeout(()=>{s||i(!0)},5e3);return()=>{clearTimeout(e)}},[s]),(0,u.useEffect)(()=>{Math.floor((Date.now()-o.current)/1e3)<5&&r&&n(!0)},[o,r,n]),(0,u.useEffect)(()=>{t&&!s&&d?.forEach(t=>{if(a.includes(t.id))return;const i={category:`${e}_remote-site-notification`,label:t.id};c(t.id,{Component:({Notification:e})=>(0,A.jsx)(e,{gaTrackingEventArgs:i,children:(0,A.jsx)(We,{...t,gaTrackingEventArgs:i})}),priority:t.priority,areaSlug:Ve.bI.HEADER,isDismissible:t.dismissible}),l(e=>(e.push(t.id),e))})},[e,s,d,c,a,t]),null};var Ye=i(90007),Ze=i(43569);function InternalServerError(){const e=(0,g.useSelect)(e=>e(B.O4).getInternalServerError());return e?(0,A.jsx)(Ze.A,{id:"internal-server-error",children:(0,A.jsx)(Ye.A,{notificationID:"internal-server-error",type:Ye.Q.ERROR,title:e.title,description:e.description})}):null}function LegacyNotifications(){const e=(0,Q.A)(),t=(0,ee.Ay)(),i=(0,g.useSelect)(e=>e(I.oR).isAuthenticated());return(0,A.jsxs)(u.Fragment,{children:[(0,A.jsx)(InternalServerError,{}),!e&&t===ee.Oo&&i&&(0,A.jsx)(He,{})]})}var Qe=i(74995);function Header({children:e,subHeader:t,showNavigation:i}){const s=!!(0,ee.Ay)(),n=(0,Q.A)();!function(){const e=(0,W.A)(),t=(0,g.useSelect)(e=>e(B.O4).isUsingProxy()),i=(0,g.useSelect)(e=>e(B.O4).getSetupErrorMessage());(0,u.useEffect)(()=>{i||void 0===t||async function(){const i=await(0,k.Gq)("start_user_setup"),s=await(0,k.Gq)("start_site_setup");i.cacheHit&&(await(0,k.LD)("start_user_setup"),(0,_.sx)(`${e}_setup`,"complete_user_setup",t?"proxy":"custom-oauth")),s.cacheHit&&(await(0,k.LD)("start_site_setup"),(0,_.sx)(`${e}_setup`,"complete_site_setup",t?"proxy":"custom-oauth"))}()},[e,t,i])}();const o=(0,g.useSelect)(e=>e(B.O4).getAdminURL("googlesitekit-dashboard")),r=(0,g.useSelect)(e=>e(I.oR).isAuthenticated()),[a,m]=(0,c.A)({childList:!0}),h=!!m.target?.childElementCount;return(0,A.jsxs)(u.Fragment,{children:[(0,A.jsx)("header",{className:l()("googlesitekit-header",{"googlesitekit-header--has-subheader":h,"googlesitekit-header--has-navigation":i}),children:(0,A.jsx)(Z.xA,{children:(0,A.jsxs)(Z.fI,{children:[(0,A.jsx)(Z.fh,{smSize:1,mdSize:2,lgSize:4,className:"googlesitekit-header__logo",alignMiddle:!0,children:(0,A.jsx)(Ee.A,{"aria-label":(0,d.__)("Go to dashboard","google-site-kit"),className:"googlesitekit-header__logo-link",href:o,children:(0,A.jsx)(p.A,{})})}),(0,A.jsxs)(Z.fh,{smSize:3,mdSize:6,lgSize:8,className:"googlesitekit-header__children",alignMiddle:!0,children:[e,!r&&s&&n&&(0,A.jsx)(ViewOnlyMenu,{}),r&&!n&&(0,A.jsx)(UserMenu,{})]})]})})}),(0,A.jsx)("div",{className:"googlesitekit-subheader",ref:a,children:t}),i&&(0,A.jsx)(DashboardNavigation,{}),(0,A.jsx)(Te,{}),(0,A.jsx)(LegacyNotifications,{}),(0,A.jsx)(Qe.A,{areaSlug:Ve.bI.HEADER})]})}Header.displayName="Header",Header.propTypes={children:r().node,subHeader:r().element,showNavigation:r().bool},Header.defaultProps={children:null,subHeader:null};const qe=Header},12850:(e,t,i)=>{i.d(t,{tt:()=>M,Jg:()=>j,Gp:()=>I,GH:()=>x,r0:()=>A,Du:()=>S,Zf:()=>W,Cn:()=>B,G7:()=>f,vH:()=>h,N_:()=>D,zh:()=>Y,mK:()=>d.mK,Ql:()=>b,vY:()=>L,sq:()=>E,VZ:()=>P.VZ,JK:()=>d.JK,IS:()=>C,pH:()=>P.pH,kf:()=>U,O5:()=>T,Qr:()=>N,x6:()=>G,K5:()=>d.K5,S_:()=>m,dc:()=>P.dc,Eo:()=>d.Eo,jq:()=>d.jq,DK:()=>F.D,N9:()=>V,p9:()=>o.p,XH:()=>w,Zm:()=>l,sx:()=>n.sx,BI:()=>n.BI,CZ:()=>o.C,BG:()=>H});var s=i(17243),n=i(89318),o=i(82046),r=i(10523),a=i.n(r);function l(e){return a()(JSON.stringify(c(e)))}function c(e){const t={};return Object.keys(e).sort().forEach(i=>{let s=e[i];s&&"object"==typeof s&&!Array.isArray(s)&&(s=c(s)),t[i]=s}),t}var d=i(79829);function u(e){return e.replace(new RegExp("\\[([^\\]]+)\\]\\((https?://[^/]+\\.\\w+/?.*?)\\)","gi"),'<a href="$2" target="_blank" rel="noopener noreferrer">$1</a>')}function g(e){return`<p>${e.replace(/\n{2,}/g,"</p><p>")}</p>`}function p(e){return e.replace(/\n/gi,"<br>")}function m(e){const t=[u,g,p];let i=e;for(const e of t)i=e(i);return i}function h(e){return e=parseFloat(e),isNaN(e)||0===e?[0,0,0,0]:[Math.floor(e/60/60),Math.floor(e/60%60),Math.floor(e%60),Math.floor(1e3*e)-1e3*Math.floor(e)]}function f(e){const t=e&&!Number.isInteger(e)?new Date(e).getTime():e;return isNaN(t)||!t?0:t}var y=i(32091),v=i.n(y),_=i(82871);const k="Date param must construct to a valid date instance or be a valid date instance itself.",x="Invalid dateString parameter, it must be a string.",I='Invalid date range, it must be a string with the format "last-x-days".',A=60,j=60*A,M=24*j,S=7*M;function b(){function e(e){return(0,_.sprintf)(/* translators: %s: number of days */ /* translators: %s: number of days */
|
||
(0,_._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 N(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){v()((0,s.isDate)(e)&&!isNaN(e),k);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){v()(N(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){v()(N(e)||(0,s.isDate)(e)&&!isNaN(e),x);const i=N(e)?Date.parse(e):e.getTime();return new Date(i-1e3*t)}var R=i(69743),O=i(94552),z=i(62540);function L(e,t={}){if(Number.isNaN(Number(e)))return"";const{invertColor:i=!1}=t;return(0,R.Ay)((0,z.jsx)(O.A,{direction:e>0?"up":"down",invertColor:i}))}function B(e,t){return e>0&&t>0?e/t-1:e>0?1:t>0?-1:0}var P=i(8143);function G(e){const t=parseFloat(e)||0;return!!Number.isInteger(t)&&t>0}function U(e){if("number"==typeof e)return!0;const t=(e||"").toString();return!!t&&!isNaN(t)}function V(e){return Array.isArray(e)?[...e].sort():e}var F=i(2522);function W(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)}},13719:(e,t,i)=>{i.d(t,{A:()=>ModuleDashboardEffects});var s=i(50539),n=i(37226),o=i(73874),r=i(62540);const a={[o.Oo]:"DashboardMainEffectComponent",[o.oE]:"DashboardEntityEffectComponent"};function ModuleDashboardEffects(){const e=(0,o.Ay)(),t=(0,s.useSelect)(e=>e(n.i).getModules());if(!t)return null;const i=a[e];return Object.values(t).reduce((e,t)=>{const s=t[i];return t.active&&s?[...e,(0,r.jsx)(s,{},t.slug)]:e},[])}},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,[d,u]=(0,s._)("undefined"==typeof document?[l,c]:a,t,i);function g(){return u(a)}return(0,n.A)(r,"resize",g),(0,n.A)(r,"orientationchange",g),d}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",{isTooltipVisible:!0,...e})},[t,e])}},16196:(e,t,i)=>{i.d(t,{A:()=>a});var s=i(50539),n=i(37226),o=i(71769),r=i(62540);function a({moduleName:e,FallbackComponent:t,IncompleteComponent:i}){return a=>{function WhenActiveComponent(o){const l=(0,s.useSelect)(t=>t(n.i).getModule(e),[e]);if(!l)return null;const c=t||o.WidgetNull||null;if(!1===l.active)return c&&(0,r.jsx)(c,{...o});if(!1===l.connected){const e=i||c;return e&&(0,r.jsx)(e,{...o})}return(0,r.jsx)(a,{...o})}return WhenActiveComponent.displayName=`When${(0,o.Uf)(e)}Active`,(a.displayName||a.name)&&(WhenActiveComponent.displayName+=`(${a.displayName||a.name})`),WhenActiveComponent}}},16834:(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 VisuallyHidden({className:e,children:t,...i}){return t?(0,a.jsx)("span",{...i,className:r()("screen-reader-text",e),children:t}):null}VisuallyHidden.propTypes={className:n().string,children:n().node},VisuallyHidden.defaultProps={className:""};const l=VisuallyHidden},19793:(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",fill:"none",viewBox:"0 0 24 24"},e),s||(s=n.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M12 1C5.925 1 1 5.925 1 12s4.925 11 11 11 11-4.925 11-11S18.075 1 12 1m4.806 8.592.592-.806-1.612-1.184-.592.806-3.89 5.296c-.166.226-.36.296-.512.296s-.346-.07-.512-.296l-1.474-2.007-.592-.806-1.612 1.184.592.806 1.474 2.007C9.191 15.6 9.971 16 10.792 16s1.6-.4 2.124-1.112z",clipRule:"evenodd"})))},20068:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s=i(63696),n=i(82286),o=i(44451);const __WEBPACK_DEFAULT_EXPORT__=function(e,t,r=i.g){const[a,l]=(0,s.useState)((0,n.d)(r.location.href,e)||t);return[a,function(t){l(t);const i=(0,o.F)(r.location.href,{[e]:t});r.history.replaceState(null,"",i)}]}},20898:(e,t,i)=>{i.d(t,{A:()=>N});var s,n=i(4452),o=i.n(n),r=i(62688),a=i.n(r),l=i(39941),c=i(63696),d=i(82871);function u(){return u=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},u.apply(null,arguments)}const g=e=>c.createElement("svg",u({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 13 13"},e),s||(s=c.createElement("g",{fill:"none",fillRule:"evenodd"},c.createElement("circle",{cx:6.5,cy:6.5,r:6.5,fill:"currentColor"}),c.createElement("path",{fill:"#FFF",d:"M3.461 6.96h5.15L6.36 9.21a.464.464 0 0 0 .325.79.46.46 0 0 0 .325-.135l3.037-3.038a.46.46 0 0 0 0-.65L7.015 3.135a.46.46 0 0 0-.65.65L8.61 6.039H3.461a.46.46 0 0 0-.461.46c0 .254.207.462.461.462z"}),".")));var p;function m(){return m=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},m.apply(null,arguments)}const h=e=>c.createElement("svg",m({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 13 13"},e),p||(p=c.createElement("g",{fill:"none",fillRule:"evenodd"},c.createElement("circle",{cx:6.5,cy:6.5,r:6.5,fill:"#FFF"}),c.createElement("path",{fill:"currentColor",d:"M3.461 6.96h5.15L6.36 9.21a.464.464 0 0 0 .325.79.46.46 0 0 0 .325-.135l3.037-3.038a.46.46 0 0 0 0-.65L7.015 3.135a.46.46 0 0 0-.65.65L8.61 6.039H3.461a.46.46 0 0 0-.461.46c0 .254.207.462.461.462z"}),".")));var f;function y(){return y=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},y.apply(null,arguments)}const v=e=>c.createElement("svg",y({xmlns:"http://www.w3.org/2000/svg",fill:"currentColor",viewBox:"0 0 24 24"},e),f||(f=c.createElement("path",{d:"m12 20-8-8 8-8 1.425 1.4-5.6 5.6H20v2H7.825l5.6 5.6z"})));var _=i(83366),k=i(84385),x=i(62540);const I="BUTTON",A="BUTTON_DISABLED",j="EXTERNAL_LINK",M="LINK",S="ROUTER_LINK",b=(0,c.forwardRef)((e,t)=>{const{"aria-label":i,secondary:s=!1,arrow:n=!1,back:r=!1,caps:a=!1,children:c,className:u="",danger:p=!1,disabled:m=!1,external:f=!1,hideExternalIndicator:y=!1,href:b="",inverse:N=!1,noFlex:E=!1,onClick:w,small:C=!1,standalone:T=!1,linkButton:D=!1,to:R,leadingIcon:O,trailingIcon:z,...L}=e;const B=b||R||!w?R?S:f?j:M:m?A:I;const P=B===I||B===A?"button":B===S?l.N_:"a",G=function(){let e;return B===j&&(e=(0,d._x)("(opens in a new tab)","screen reader text","google-site-kit")),B===A&&(e=(0,d._x)("(disabled)","screen reader text","google-site-kit")),e?i?`${i} ${e}`:"string"==typeof c?`${c} ${e}`:void 0:i}();let U=O,V=z;return r&&(U=(0,x.jsx)(v,{width:14,height:14})),f&&!y&&(V=(0,x.jsx)(_.A,{width:14,height:14})),n&&!N&&(V=(0,x.jsx)(g,{width:14,height:14})),n&&N&&(V=(0,x.jsx)(h,{width:14,height:14})),(0,x.jsxs)(P,{"aria-label":G,className:o()("googlesitekit-cta-link",u,{"googlesitekit-cta-link--secondary":s,"googlesitekit-cta-link--inverse":N,"googlesitekit-cta-link--small":C,"googlesitekit-cta-link--caps":a,"googlesitekit-cta-link--danger":p,"googlesitekit-cta-link--disabled":m,"googlesitekit-cta-link--standalone":T,"googlesitekit-cta-link--link-button":D,"googlesitekit-cta-link--no-flex":!!E}),disabled:m,href:B!==M&&B!==j||m?void 0:b,onClick:w,rel:B===j?"noopener noreferrer":void 0,ref:t,target:B===j?"_blank":void 0,to:R,...L,children:[!!U&&(0,x.jsx)(k.A,{marginRight:5,children:U}),(0,x.jsx)("span",{className:"googlesitekit-cta-link__contents",children:c}),!!V&&(0,x.jsx)(k.A,{marginLeft:5,children:V})]})});b.propTypes={arrow:a().bool,back:a().bool,caps:a().bool,children:a().node,className:a().string,danger:a().bool,disabled:a().bool,external:a().bool,hideExternalIndicator:a().bool,href:a().string,inverse:a().bool,leadingIcon:a().node,linkButton:a().bool,noFlex:a().bool,onClick:a().func,small:a().bool,standalone:a().bool,to:a().string,trailingIcon:a().node};const N=b},21134:(e,t,i)=>{i.d(t,{Gq:()=>u,IL:()=>h,LD:()=>p,SO:()=>g,a2:()=>n,xD:()=>m});var s=i(12850);const n="googlesitekit_",o=`${n}1.165.0_${i.g._googlesitekitBaseData.storagePrefix}_`,r=["sessionStorage","localStorage"];let a,l=[...r];async function c(e){const t=i.g[e];if(!t)return!1;try{const e="__storage_test__";return t.setItem(e,e),t.removeItem(e),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==t.length}}async function d(){if(void 0!==a)return a;for(const e of l)a||await c(e)&&(a=i.g[e]);return void 0===a&&(a=null),a}async function u(e){const t=await d();if(t){const i=t.getItem(`${o}${e}`);if(i){const e=JSON.parse(i),{timestamp:t,ttl:s,value:n,isError:o}=e;if(t&&(!s||Math.round(Date.now()/1e3)-t<s))return{cacheHit:!0,value:n,isError:o}}}return{cacheHit:!1,value:void 0}}async function g(e,t,{ttl:n=s.Jg,timestamp:r=Math.round(Date.now()/1e3),isError:a=!1}={}){const l=await d();if(l)try{return l.setItem(`${o}${e}`,JSON.stringify({timestamp:r,ttl:n,value:t,isError:a})),!0}catch(e){return i.g.console.warn("Encountered an unexpected storage error:",e),!1}return!1}async function p(e){const t=await d();if(t)try{const i=e.startsWith(n)?e:`${o}${e}`;return t.removeItem(i),!0}catch(e){return i.g.console.warn("Encountered an unexpected storage error:",e),!1}return!1}async function m(){const e=await d();if(e)try{const t=[];for(let i=0;i<e.length;i++){const s=e.key(i);0===s.indexOf(n)&&t.push(s)}return t}catch(e){return i.g.console.warn("Encountered an unexpected storage error:",e),[]}return[]}async function h(){if(await d()){const e=await m();for(const t of e)await p(t);return!0}return!1}},22821:(e,t,i)=>{i.d(t,{A:()=>n});var s=i(24558);function n(e){return s.kz.includes(e)}},23141:(e,t,i)=>{i.d(t,{A:()=>WidgetRecoverableModules});var s=i(62688),n=i.n(s),o=i(63696),r=i(47345),a=i(9652),l=i(62540);function WidgetRecoverableModules({widgetSlug:e,moduleSlugs:t,...i}){const s=(0,o.useMemo)(()=>({moduleSlug:[...t].sort().join(","),moduleSlugs:t}),[t]);return(0,r.A)(e,a.A,s),(0,l.jsx)(a.A,{moduleSlugs:t,...i})}WidgetRecoverableModules.propTypes={widgetSlug:n().string.isRequired,...a.A.propTypes}},23224:(e,t,i)=>{i.d(t,{A:()=>c});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(32947),l=i(62540);function PreviewBlock({className:e,width:t,height:i,shape:s,padding:n,smallWidth:o,smallHeight:c,tabletWidth:d,tabletHeight:u,desktopWidth:g,desktopHeight:p}){const m=(0,a.dv)(),h={width:{[a.mp]:o,[a.Lg]:d,[a.Fo]:g,[a.Qb]:g},height:{[a.mp]:c,[a.Lg]:u,[a.Fo]:p,[a.Qb]:g}};return(0,l.jsx)("div",{className:r()("googlesitekit-preview-block",e,{"googlesitekit-preview-block--padding":n}),style:{width:h.width[m]||t,height:h.height[m]||i},children:(0,l.jsx)("div",{className:r()("googlesitekit-preview-block__wrapper",{"googlesitekit-preview-block__wrapper--circle":"circular"===s})})})}PreviewBlock.propTypes={className:n().string,width:n().string,height:n().string,shape:n().string,padding:n().bool,smallWidth:n().string,smallHeight:n().string,tabletWidth:n().string,tabletHeight:n().string,desktopWidth:n().string,desktopHeight:n().string},PreviewBlock.defaultProps={className:void 0,width:"100px",height:"100px",shape:"square",padding:!1,smallWidth:void 0,smallHeight:void 0,tabletWidth:void 0,tabletHeight:void 0,desktopWidth:void 0,desktopHeight:void 0};const c=PreviewBlock},24288:(e,t,i)=>{i.d(t,{hk:()=>o,tm:()=>n,zP:()=>s});const s="editing-user-role-select-slug-key",n="dashboardSharingDialogOpen",o="resetSharingDialogOpen"},24452:(e,t,i)=>{i.d(t,{A:()=>G});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(50539),l=i(63696),c=i(93934),d=i(12108),u=i(86134),g=i(7081),p=i(55527),m=i(32947),h=i(68869),f=i(17243),y=i(37226),v=i(39828),_=i(23141),k=i(15135),x=i(35323),I=i(62540);function WidgetRenderer({slug:e,OverrideComponent:t}){const i=(0,a.useSelect)(t=>t(u.aO).getWidget(e)),s=(0,m.dv)(),n=(0,c.c1)(e),{Widget:o,WidgetNull:r}=n,d=(0,a.useSelect)(e=>e(y.i).getRecoverableModules()),g=(0,x.A)(),p=(0,l.useMemo)(()=>i&&d&&(0,f.intersection)(i.modules,Object.keys(d)),[d,i]),h=(0,a.useSelect)(t=>t(u.aO).isWidgetPreloaded(e));if(!i||void 0===p||i?.hideOnBreakpoints?.includes(s))return(0,I.jsx)(r,{});const{Component:A,wrapWidget:j}=i;let M=(0,I.jsx)(A,{...n});return g&&p?.length&&(M=(0,I.jsx)(_.A,{widgetSlug:e,moduleSlugs:p})),t?M=(0,I.jsxs)(l.Fragment,{children:[(0,I.jsx)(v.A,{widgetSlug:"overridden",children:(0,I.jsx)(t,{})}),(0,I.jsx)("div",{className:k.Y2,children:M})]}):j&&(M=(0,I.jsx)(o,{children:M})),h?(0,I.jsx)("div",{className:k.Y2,children:M}):M}WidgetRenderer.propTypes={slug:n().string.isRequired,OverrideComponent:n().elementType};const A=WidgetRenderer;function WidgetCellWrapper({gridColumnWidth:e,children:t}){return 0===e?(0,I.jsx)("div",{className:k.Y2,children:t}):e<6?(0,I.jsx)(p.fh,{lgSize:e,mdSize:4,smSize:2,children:t}):e<8?(0,I.jsx)(p.fh,{lgSize:e,mdSize:8,children:t}):(0,I.jsx)(p.fh,{size:e,children:t})}WidgetCellWrapper.propTypes={gridColumnWidth:n().number.isRequired,children:n().element.isRequired};const j=WidgetCellWrapper;var M=i(38021),S=i.n(M),b=i(82871),N=i(4884),E=i(54312),w=i(61991),C=i(12850),T=i(59323);class WidgetErrorHandler extends l.Component{constructor(e){super(e),this.state={error:null,info:null},this.onErrorClick=this.onErrorClick.bind(this)}componentDidCatch(e,t){i.g.console.error("Widget error:",e,t),this.setState({error:e,info:t}),(0,C.sx)("widget_error",`handle_${this.context||"unknown"}_error`,`${this.props.slug}_${e?.message}\n${t?.componentStack}`.slice(0,500-this.props.slug.length-1))}onErrorClick(){const{error:e,info:t}=this.state;S()(`\`${e?.message}\n${t?.componentStack}\``)}render(){const{children:e}=this.props,{error:t,info:i}=this.state;return t?(0,I.jsx)("div",{className:"googlesitekit-widget-error-handler",children:(0,I.jsx)(N.A,{description:(0,I.jsxs)(l.Fragment,{children:[(0,I.jsx)(T.A,{children:(0,b.__)("An error prevented this Widget from being displayed properly. Report the exact contents of the error on the support forum to find out what caused it.","google-site-kit")}),(0,I.jsx)(E.A,{message:t.message,componentStack:i.componentStack})]}),onErrorClick:this.onErrorClick,onClick:this.onErrorClick,title:(0,b.__)("Error in Widget","google-site-kit"),error:!0})}):e}}WidgetErrorHandler.contextType=w.Ay,WidgetErrorHandler.propTypes={children:n().node.isRequired};const D=WidgetErrorHandler;var R=i(58116),O=i(89362),z=i(98652);function WidgetNewBadge({slug:e}){const t=(0,a.useSelect)(t=>t(u.aO).getWidgetArea(e)),{hasNewBadge:i}=t,s=`widget-area-expirable-new-badge-${e}`,n=(0,a.useSelect)(e=>e(R.oR).hasExpirableItem(s)),o=(0,a.useSelect)(e=>e(R.oR).isExpirableItemActive(s)),r=i&&(!1===n||o),{setExpirableItemTimers:c}=(0,a.useDispatch)(R.oR);return(0,l.useEffect)(()=>{void 0!==n&&void 0!==o&&i&&!n&&c([{slug:s,expiresInSeconds:4*C.Du}])},[i,s,n,o,c]),!!r&&(0,I.jsx)(z.A,{})}WidgetNewBadge.propTypes={slug:n().string.isRequired};var L=i(15577),B=i(15167);function WidgetAreaHeader({slug:e,Icon:t=!1,title:i="",subtitle:s="",CTA:n}){const o=(0,L.SO)(),r=n&&o>=783,a="function"==typeof s?s:void 0;return(0,I.jsxs)(l.Fragment,{children:[t&&(0,I.jsx)(t,{width:33,height:33}),i&&(0,I.jsxs)(B.A,{as:"h3",type:"headline",size:"small",className:"googlesitekit-widget-area-header__title",children:[i,(0,I.jsx)(WidgetNewBadge,{slug:e})]}),(s||n)&&(0,I.jsxs)("div",{className:"googlesitekit-widget-area-header__details",children:[s&&(0,I.jsxs)(B.A,{as:"h4",size:"medium",type:"body",className:"googlesitekit-widget-area-header__subtitle",children:[a&&(0,I.jsx)(a,{}),!a&&s,!i&&(0,I.jsx)(WidgetNewBadge,{slug:e})]}),r&&(0,I.jsx)("div",{className:"googlesitekit-widget-area-header__cta",children:(0,I.jsx)(n,{})})]})]})}function P(e){const t={[m.Qb]:48,[m.Fo]:48,[m.Lg]:32,[m.mp]:32}[e];return`${-Math.abs((0,d.Eq)(e)+t)}px ${-t}px ${-t}px ${-t}px`}function WidgetAreaRenderer({slug:e,contextID:t}){const i=(0,x.A)(),s=(0,a.useSelect)(e=>i?e(R.oR).getViewableModules():null),n=(0,L.SO)(),o=(0,m.dv)(),d=(0,l.useRef)(),f=(0,O.A)(d,{rootMargin:P(o),threshold:0}),y=(0,a.useSelect)(t=>t(u.aO).getWidgetArea(e)),{Icon:v,title:_,style:k,subtitle:M,CTA:S,Footer:b}=y,N=(0,a.useSelect)(t=>t(u.aO).getWidgets(e,{modules:s||void 0})),E=(0,a.useSelect)(e=>e(u.aO).getWidgetStates()),w=(0,a.useSelect)(t=>t(u.aO).isWidgetAreaActive(e,{modules:s||void 0})),C=(0,a.useSelect)(e=>e(g.n).getValue(g.F)),[T,z]=(0,l.useState)({key:`WidgetAreaRenderer-${e}`,value:C?C===t:!!f?.intersectionRatio});(0,l.useEffect)(()=>{z({key:`WidgetAreaRenderer-${e}`,value:C?C===t:!!f?.intersectionRatio})},[f,e,C,t]);const B=S&&n<=782;if(void 0===s)return null;const{columnWidths:G,rowIndexes:U}=(0,c.X9)(N,E),{gridColumnWidths:V,overrideComponents:F}=(0,c.DO)(N,E,{columnWidths:G,rowIndexes:U}),W=N.map((e,t)=>(0,I.jsx)(j,{gridColumnWidth:V[t],children:(0,I.jsx)(D,{slug:e.slug,children:(0,I.jsx)(A,{OverrideComponent:F[t]?()=>{const{Component:e,metadata:i}=F[t];return(0,I.jsx)(e,{...i})}:void 0,slug:e.slug})})},`${e.slug}-wrapper`));return(0,I.jsxs)(h.Ay,{value:T,children:[!!w&&(0,I.jsxs)(p.xA,{className:r()("googlesitekit-widget-area",`googlesitekit-widget-area--${e}`,`googlesitekit-widget-area--${k}`),ref:d,children:[(0,I.jsx)(p.fI,{children:(0,I.jsx)(p.fh,{className:"googlesitekit-widget-area-header",size:12,children:(0,I.jsx)(WidgetAreaHeader,{slug:e,Icon:v,title:_,subtitle:M,CTA:S})})}),(0,I.jsx)("div",{className:"googlesitekit-widget-area-widgets",children:(0,I.jsxs)(p.fI,{children:[k===u.qB.BOXES&&W,k===u.qB.COMPOSITE&&(0,I.jsx)(p.fh,{size:12,children:(0,I.jsx)(p.xA,{children:(0,I.jsx)(p.fI,{children:W})})})]})}),(0,I.jsxs)(p.fI,{children:[B&&(0,I.jsx)(p.fh,{className:"googlesitekit-widget-area-footer",lgSize:12,mdSize:4,smSize:2,children:(0,I.jsx)("div",{className:"googlesitekit-widget-area-footer__cta",children:(0,I.jsx)(S,{})})}),b&&(0,I.jsx)(p.fh,{className:"googlesitekit-widget-area-footer",lgSize:12,mdSize:B?4:8,smSize:B?2:4,children:(0,I.jsx)(b,{})})]})]}),!w&&(0,I.jsx)(p.xA,{className:r()(c.Y2,"googlesitekit-widget-area",{[`googlesitekit-widget-area--${e}`]:!!e,[`googlesitekit-widget-area--${k}`]:!!k}),ref:d,children:W})]})}function WidgetContextRenderer(e){const{id:t,slug:i,className:s,Header:n,Footer:o}=e,l=(0,x.A)(),c=(0,a.useSelect)(e=>l?e(R.oR).getViewableModules():null),d=(0,a.useSelect)(e=>i?e(u.aO).getWidgetAreas(i):null),g=(0,a.useSelect)(e=>!!i&&e(u.aO).isWidgetContextActive(i,{modules:c||void 0}));return void 0===c?null:(0,I.jsxs)("div",{id:t,className:r()("googlesitekit-widget-context",{"googlesitekit-hidden":!g},s),children:[n&&g&&(0,I.jsx)(p.xA,{children:(0,I.jsx)(p.fI,{children:(0,I.jsx)(p.fh,{size:12,children:(0,I.jsx)(n,{})})})}),d&&d.map(e=>(0,I.jsx)(WidgetAreaRenderer,{slug:e.slug,contextID:t},e.slug)),o&&g&&(0,I.jsx)(p.xA,{children:(0,I.jsx)(p.fI,{children:(0,I.jsx)(p.fh,{size:12,children:(0,I.jsx)(o,{})})})})]})}WidgetAreaHeader.propTypes={slug:n().string.isRequired,Icon:n().bool,title:n().oneOfType([n().string,n().element]),subtitle:n().oneOfType([n().string,n().elementType]),CTA:n().elementType},WidgetAreaRenderer.propTypes={slug:n().string.isRequired,contextID:n().string},WidgetContextRenderer.propTypes={id:n().string,slug:n().string,className:n().string,Header:n().elementType,Footer:n().elementType};const G=WidgetContextRenderer},24558:(e,t,i)=>{i.d(t,{Ax:()=>o,CZ:()=>d,Ej:()=>A,Gw:()=>j,Is:()=>r,KK:()=>g,Nn:()=>S,OT:()=>x,SH:()=>k,Y$:()=>p,ZS:()=>a,bg:()=>f,en:()=>I,ep:()=>h,f7:()=>n,hi:()=>m,jU:()=>s,k$:()=>v,kz:()=>M,ly:()=>l,mo:()=>y,s3:()=>_,uR:()=>c,zx:()=>u});const s="mainDashboard",n="entityDashboard",o="mainDashboardViewOnly",r="entityDashboardViewOnly",a="userInput",l="activation",c="splash",d="adminBar",u="adminBarViewOnly",g="settings",p="adBlockingRecovery",m="wpDashboard",h="wpDashboardViewOnly",f="moduleSetup",y="metricSelection",v="wpBlockEditor",_="keyMetricsSetup",k="key-metrics",x="traffic",I="content",A="speed",j="monetization",M=[s,n,o,r,a,c,g,f,y],S=[o,r,u,h]},25623:(e,t,i)=>{i.d(t,{G:()=>u});var s=i(82871),n=i(58116),o=i(93896),r=i(72455);function a({select:e,slug:t}){return e(r.K9).hasConversionReportingEvents(this.requiredConversionEventName)||e(n.oR).isKeyMetricActive(t)}var l=i(50111);function c({select:e,isViewOnlyDashboard:t}){return!t||!(!t||!e(r.K9).getAdSenseLinked())}function d({select:e,isViewOnlyDashboard:t}){return!t||e(r.K9).hasCustomDimensions(this.requiredCustomDimensions)}const u={[n.p3]:{title:(0,s.__)("Top earning pages","google-site-kit"),description:(0,s.__)("Pages that generated the most AdSense revenue","google-site-kit"),infoTooltip:(0,s.__)("Pages that generated the most AdSense revenue","google-site-kit"),displayInSelectionPanel:c,displayInList:c,metadata:{group:l.hs.SLUG}},[n.BT]:{title:(0,s.__)("Top recent trending pages","google-site-kit"),description:(0,s.__)("Pages with the most pageviews published in the last 3 days","google-site-kit"),infoTooltip:(0,s.__)("Pages with the most pageviews published in the last 3 days","google-site-kit"),requiredCustomDimensions:["googlesitekit_post_date"],displayInSelectionPanel:d,displayInWidgetArea:d,displayInList:d,metadata:{group:l.hs.SLUG}},[n.tB]:{title:(0,s.__)("Most popular authors by pageviews","google-site-kit"),description:(0,s.__)("Authors whose posts got the most visits","google-site-kit"),infoTooltip:(0,s.__)("Authors whose posts got the most visits","google-site-kit"),requiredCustomDimensions:["googlesitekit_post_author"],displayInSelectionPanel:d,displayInWidgetArea:d,displayInList:d,metadata:{group:l.hs.SLUG}},[n.t1]:{title:(0,s.__)("Top categories by pageviews","google-site-kit"),description:(0,s.__)("Categories that your site visitors viewed the most","google-site-kit"),infoTooltip:(0,s.__)("Categories that your site visitors viewed the most","google-site-kit"),requiredCustomDimensions:["googlesitekit_post_categories"],displayInSelectionPanel:d,displayInWidgetArea:d,displayInList:d,metadata:{group:l.hs.SLUG}},[n.ep]:{title:(0,s.__)("Most popular content by pageviews","google-site-kit"),description:(0,s.__)("Pages that brought in the most visitors","google-site-kit"),infoTooltip:(0,s.__)("Pages your visitors read the most","google-site-kit"),metadata:{group:l.hs.SLUG}},[n.pG]:{title:(0,s.__)("Most popular products by pageviews","google-site-kit"),description:(0,s.__)("Products that brought in the most visitors","google-site-kit"),requiredCustomDimensions:["googlesitekit_post_type"],displayInSelectionPanel:({select:e})=>e(n.oR).isKeyMetricActive(n.pG)||e(o.O4).getProductPostType(),displayInWidgetArea:d,metadata:{group:l.GF.SLUG}},[n.nH]:{title:(0,s.__)("Pages per visit","google-site-kit"),description:(0,s.__)("Number of pages visitors viewed per session on average","google-site-kit"),infoTooltip:(0,s.__)("Number of pages visitors viewed per session on average","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.J5]:{title:(0,s.__)("Visit length","google-site-kit"),description:(0,s.__)("Average duration of engaged visits","google-site-kit"),infoTooltip:(0,s.__)("Average duration of engaged visits","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.Yw]:{title:(0,s.__)("Visits per visitor","google-site-kit"),description:(0,s.__)("Average number of sessions per site visitor","google-site-kit"),infoTooltip:(0,s.__)("Average number of sessions per site visitor","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.UY]:{title:(0,s.__)("Most engaging pages","google-site-kit"),description:(0,s.__)("Pages with the highest engagement rate","google-site-kit"),infoTooltip:(0,s.__)("Pages with the highest engagement rate","google-site-kit"),metadata:{group:l.hs.SLUG}},[n.gC]:{title:(0,s.__)("Least engaging pages","google-site-kit"),description:(0,s.__)("Pages with the highest percentage of visitors that left without engagement with your site","google-site-kit"),infoTooltip:(0,s.__)("Percentage of visitors that left without engagement with your site","google-site-kit"),metadata:{group:l.hs.SLUG}},[n.tK]:{title:(0,s.__)("Top pages by returning visitors","google-site-kit"),description:(0,s.__)("Pages that attracted the most returning visitors","google-site-kit"),infoTooltip:(0,s.__)("Pages that attracted the most returning visitors","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.fu]:{title:(0,s.__)("New visitors","google-site-kit"),description:(0,s.__)("How many new visitors you got and how the overall audience changed","google-site-kit"),infoTooltip:(0,s.__)("Portion of visitors who visited your site for the first time in this timeframe","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.dX]:{title:(0,s.__)("Returning visitors","google-site-kit"),description:(0,s.__)("Portion of people who visited your site more than once","google-site-kit"),infoTooltip:(0,s.__)("Portion of your site’s visitors that returned at least once in this timeframe","google-site-kit"),metadata:{group:l.IX.SLUG}},[n.SS]:{title:(0,s.__)("Top traffic source","google-site-kit"),description:(0,s.__)("Channel which brought in the most visitors to your site","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in the most visitors to your site","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.Vl]:{title:(0,s.__)("Top traffic source driving add to cart","google-site-kit"),description:(0,s.__)("Channel which brought in the most add to cart events to your site","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in the most add to cart events to your site","google-site-kit"),requiredConversionEventName:[r.nc.ADD_TO_CART],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.GF.SLUG}},[n.u_]:{title:(0,s.__)("Top traffic source driving leads","google-site-kit"),description:(0,s.__)("Channel which brought in the most leads to your site","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in the most leads to your site","google-site-kit"),requiredConversionEventName:[r.nc.SUBMIT_LEAD_FORM,r.nc.CONTACT,r.nc.GENERATE_LEAD],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.XU.SLUG}},[n.HA]:{title:(0,s.__)("Top traffic source driving purchases","google-site-kit"),description:(0,s.__)("Channel which brought in the most purchases to your site","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in the most purchases to your site","google-site-kit"),requiredConversionEventName:[r.nc.PURCHASE],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.GF.SLUG}},[n.GT]:{title:(0,s.__)("Most engaged traffic source","google-site-kit"),description:(0,s.__)("Visitors coming via this channel spent the most time on your site","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in the most visitors who had a meaningful engagement with your site","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.qy]:{title:(0,s.__)("Top converting traffic source","google-site-kit"),description:(0,s.__)("Channel which brought in the most visits that resulted in key events","google-site-kit"),infoTooltip:(0,s.__)("Channel (e.g. social, paid, search) that brought in visitors who generated the most key events","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.GM]:{title:(0,s.__)("Top cities driving traffic","google-site-kit"),description:(0,s.__)("Which cities you get the most visitors from","google-site-kit"),infoTooltip:(0,s.__)("The cities where most of your visitors came from","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.CQ]:{title:(0,s.__)("Top cities driving leads","google-site-kit"),description:(0,s.__)("Cities driving the most contact form submissions","google-site-kit"),infoTooltip:(0,s.__)("Cities driving the most contact form submissions","google-site-kit"),requiredConversionEventName:[r.nc.SUBMIT_LEAD_FORM,r.nc.CONTACT,r.nc.GENERATE_LEAD],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.XU.SLUG}},[n.Xq]:{title:(0,s.__)("Top cities driving add to cart","google-site-kit"),description:(0,s.__)("Cities where visitors most frequently add products to their carts","google-site-kit"),infoTooltip:(0,s.__)("Cities where visitors most frequently add products to their carts","google-site-kit"),requiredConversionEventName:[r.nc.ADD_TO_CART],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.GF.SLUG}},[n.JF]:{title:(0,s.__)("Top cities driving purchases","google-site-kit"),description:(0,s.__)("Cities driving the most purchases","google-site-kit"),infoTooltip:(0,s.__)("Cities driving the most purchases","google-site-kit"),requiredConversionEventName:[r.nc.PURCHASE],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.GF.SLUG}},[n.YQ]:{title:(0,s.__)("Top device driving purchases","google-site-kit"),description:(0,s.__)("Top device driving the most purchases","google-site-kit"),infoTooltip:(0,s.__)("Top device driving the most purchases","google-site-kit"),requiredConversionEventName:[r.nc.PURCHASE],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.GF.SLUG}},[n.dV]:{title:(0,s.__)("Top countries driving traffic","google-site-kit"),description:(0,s.__)("Which countries you get the most visitors from","google-site-kit"),infoTooltip:(0,s.__)("The countries where most of your visitors came from","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.t7]:{title:(0,s.__)("Top performing keywords","google-site-kit"),description:(0,s.__)("What people searched for before they came to your site","google-site-kit"),infoTooltip:(0,s.__)("The top search queries for your site by highest clickthrough rate","google-site-kit"),metadata:{group:l.wb.SLUG}},[n.HP]:{title:(0,s.__)("Top pages driving leads","google-site-kit"),description:(0,s.__)("Pages on which forms are most frequently submitted","google-site-kit"),requiredConversionEventName:[r.nc.SUBMIT_LEAD_FORM,r.nc.CONTACT,r.nc.GENERATE_LEAD],displayInSelectionPanel:a,displayInList:a,metadata:{group:l.XU.SLUG}}}},25874:(e,t,i)=>{i.d(t,{A:()=>f});var s=i(62688),n=i.n(s),o=i(47485),r=i(63696),a=i(82871),l=i(55527),c=i(4452),d=i.n(c),u=i(62540);const g=(0,r.forwardRef)(({children:e,href:t,text:i,className:s,danger:n,disabled:o,target:r,"aria-label":a,inverse:l,tertiary:c,callout:g,calloutStyle:p,...m},h)=>{const f=t&&!o?"a":"button";return(0,u.jsx)(f,{className:d()("mdc-button",s,{"mdc-button--raised":!i&&!c&&!g,"mdc-button--danger":n,"mdc-button--inverse":l,"mdc-button--tertiary":c,"mdc-button--callout":g,"mdc-button--callout-primary":g||"primary"===p,"mdc-button--callout-warning":"warning"===p,"mdc-button--callout-error":"error"===p}),href:o?void 0:t,ref:h,disabled:!!o,"aria-label":a,target:r||"_self",role:"a"===f?"button":void 0,...m,children:e})});g.propTypes={children:n().node,href:n().string,text:n().bool,className:n().string,danger:n().bool,disabled:n().bool,target:n().string,"aria-label":n().string,inverse:n().bool,tertiary:n().bool,callout:n().bool,calloutStyle:n().oneOf(["primary","warning","error"])};const p=g;var m=i(59020);function MaybeTooltip({children:e,disabled:t=!1,tooltip:i=!1,tooltipTitle:s=null,hasIconOnly:n=!1,tooltipEnterDelayInMS:o=100}){return!t&&(i&&s||n&&s)?(0,u.jsx)(m.A,{title:s,enterDelay:o,children:e}):e}MaybeTooltip.propTypes={children:n().node.isRequired,disabled:n().bool,tooltip:n().bool,tooltipTitle:n().oneOfType([n().string,n().element]),hasIconOnly:n().bool,tooltipEnterDelayInMS:n().number};const h=(0,r.forwardRef)(({children:e,href:t=null,text:i=!1,className:s="",danger:n=!1,disabled:c=!1,target:d,icon:g=null,trailingIcon:m=null,"aria-label":h,title:f=null,customizedTooltip:y=null,tooltip:v=!1,inverse:_=!1,hideTooltipTitle:k=!1,tooltipEnterDelayInMS:x=100,tertiary:I=!1,callout:A=!1,calloutStyle:j=null,...M},S)=>{const b=(0,r.useCallback)(e=>{null!==e&&l.Nv.attachTo(e)},[]),N=(0,o.A)(S,b);const E=k?null:f||y||h;return(0,u.jsx)(MaybeTooltip,{disabled:c,tooltip:v,tooltipTitle:E,hasIconOnly:!!g&&void 0===e,tooltipEnterDelayInMS:x,children:(0,u.jsxs)(p,{href:t,disabled:c,className:s,danger:n,text:i,tertiary:I,inverse:_,callout:A,calloutStyle:j,ref:N,"aria-label":function(){let t=h;if("_blank"!==d)return t;const i=(0,a._x)("(opens in a new tab)","screen reader text","google-site-kit");return"string"==typeof e&&(t=t||e),t?`${t} ${i}`:i}(),target:d||"_self",...M,children:[g,e&&(0,u.jsx)("span",{className:"mdc-button__label",children:e}),m]})})});h.propTypes={onClick:n().func,children:n().node,href:n().string,text:n().bool,className:n().string,danger:n().bool,disabled:n().bool,icon:n().element,trailingIcon:n().element,title:n().string,customizedTooltip:n().element,tooltip:n().bool,inverse:n().bool,hideTooltipTitle:n().bool,callout:n().bool,calloutStyle:n().oneOf(["primary","warning","error"])};const f=h},27134:(e,t,i)=>{i.d(t,{A:()=>PanelContent});var s=i(4452),n=i.n(s),o=i(17243),r=i(62688),a=i.n(r),l=i(63696),c=i(82871),d=i(81276),u=i(50539),g=i(58116),p=i(72455),m=i(99897),h=i(50111),f=i(25623),y=i(66889),v=i(16196),_=i(27333),k=i(59323),x=i(62540);const I=(0,v.A)({moduleName:m.L1})(function CustomDimensionsNotice(){const e=(0,_.A)(h.Is,h.Y0),t=e?.flatMap(e=>{const t=f.G[e];return t?.requiredCustomDimensions||[]}),s=(0,u.useInViewSelect)(e=>!!t?.length&&!e(p.K9).hasCustomDimensions(t),[t]),n=(0,u.useInViewSelect)(e=>e(g.oR).hasScope(p.S9));(0,u.useInViewSelect)(e=>e(p.K9).getAvailableCustomDimensions());const o=(0,d.A)(s),r=(0,l.useRef)();if((0,l.useEffect)(()=>{if(s&&!1===o){const e=i.g.document.activeElement;e&&e.closest(".googlesitekit-selection-panel-item")&&(0,y.N)(r.current,e)&&e.scrollIntoView()}},[s,o]),!1===s)return null;const a=n?(0,c.__)("The metrics you selected require more data tracking. We will update your Analytics property after saving your selection.","google-site-kit"):(0,c.__)("The metrics you selected require more data tracking. You will be directed to update your Analytics property after saving your selection.","google-site-kit");return(0,x.jsx)("div",{className:"googlesitekit-selection-panel-notice",ref:r,children:(0,x.jsx)(k.A,{children:a})})});var A=i(13606),j=i(45472),M=i(93896),S=i(20898),b=i(718),N=i(35323);function Header({closePanel:e}){const t=(0,N.A)(),i=(0,u.useSelect)(e=>e(M.O4).getSiteKitAdminSettingsURL()),s=(0,u.useSelect)(e=>e(g.oR).isSavingKeyMetricsSettings()),{navigateTo:n}=(0,u.useDispatch)(j.M),o=(0,l.useCallback)(()=>n(i),[i,n]);return(0,x.jsx)(b.W4,{title:(0,c.sprintf)(/* translators: %d: number of max allowed metrics */ /* translators: %d: number of max allowed metrics */
|
||
(0,c.__)("Select up to %d metrics","google-site-kit"),h.Hl),onCloseClick:e,children:!t&&(0,x.jsx)(k.A,{children:(0,A.A)((0,c.__)("Edit your personalized goals or deactivate this widget in <link><strong>Settings</strong></link>","google-site-kit"),{link:(0,x.jsx)(S.A,{onClick:o,disabled:s,secondary:!0}),strong:(0,x.jsx)("strong",{})})})})}Header.propTypes={closePanel:a().func.isRequired};var E=i(78340),w=i(37226),C=i(67150),T=i(77766),D=i(64067),R=i(12850),O=i(49383),z=i(23224);function SelectionPanelFooter({savedItemSlugs:e=[],selectedItemSlugs:t=[],saveSettings:i=()=>{},minSelectedItemCount:s=0,maxSelectedItemCount:n=0,isBusy:r,onSaveSuccess:a=()=>{},onCancel:d=()=>{},isOpen:g,closePanel:m=()=>{},isFullScreen:h=!1}){const[f,y]=(0,l.useState)(null),[v,_]=(0,l.useState)(!1),k=(0,u.useSelect)(e=>e(p.K9).isFetchingSyncAvailableAudiences()),I=(0,l.useMemo)(()=>!(0,o.isEqual)((0,R.N9)(t),(0,R.N9)(e)),[e,t]);let j=e?.length>0&&I?(0,c.__)("Apply changes","google-site-kit"):(0,c.__)("Save selection","google-site-kit");h&&(j=(0,c.__)("Complete setup","google-site-kit"));const M=(0,l.useCallback)(async()=>{const{error:e}=await i(t);e||(a(),m(),h||(y(j),_(!0)))},[i,t,a,m,h,j]),S=(0,l.useCallback)(()=>{m(),d()},[m,d]),[b,N]=(0,l.useState)(null);(0,l.useEffect)(()=>{null!==b&&b!==g&&g&&(y(null),_(!1)),N(g)},[g,b]);const E=t?.length||0,w=k?(0,x.jsx)(z.A,{width:"89px",height:"20px"}):(0,x.jsx)("p",{className:"googlesitekit-selection-panel-footer__item-count",children:(0,A.A)((0,c.sprintf)(/* translators: 1: Number of selected items. 2: Maximum number of items that can be selected. */ /* translators: 1: Number of selected items. 2: Maximum number of items that can be selected. */
|
||
(0,c.__)("%1$d selected <MaxCount>(up to %2$d)</MaxCount>","google-site-kit"),E,n),{MaxCount:(0,x.jsx)("span",{className:"googlesitekit-selection-panel-footer__item-count--max-count"})})});return(0,x.jsx)("footer",{className:"googlesitekit-selection-panel-footer",children:(0,x.jsx)("div",{className:"googlesitekit-selection-panel-footer__content",children:(0,x.jsxs)("div",{className:"googlesitekit-selection-panel-footer__actions",children:[(0,x.jsx)(O.Button,{onClick:S,disabled:r,tertiary:!0,children:(0,c.__)("Cancel","google-site-kit")}),w,(0,x.jsx)(O.SpinnerButton,{onClick:M,isSaving:r,disabled:E<s||E>n||r||!g&&v,children:f||j})]})})})}function Footer({isOpen:e,closePanel:t=o.noop,savedMetrics:i,onNavigationToOAuthURL:s=()=>{},isFullScreen:n=!1}){const r=(0,u.useRegistry)(),a=(0,T.A)(),d=(0,_.A)(h.Is,h.Y0),y=(0,u.useSelect)(e=>e(g.oR).isSavingKeyMetricsSettings()),v=`${a}_kmw-sidebar`,k=d?.flatMap(e=>{const t=f.G[e];return t?.requiredCustomDimensions||[]}),I=(0,u.useInViewSelect)(e=>{if(!k?.length)return!1;return!e(p.K9).hasCustomDimensions(k)},[k]),A=(0,u.useInViewSelect)(e=>e(g.oR).hasScope(p.S9)),S=(0,u.useSelect)(e=>e(w.i).isModuleConnected(m.L1)),b=(0,u.useSelect)(e=>e(M.O4).getAdminURL("googlesitekit-dashboard",{notification:"custom_dimensions"})),N=(0,u.useSelect)(e=>{const t=e(g.oR).getConnectURL({additionalScopes:[p.S9],redirectURL:b});return!!t&&e(j.M).isNavigatingTo(t)}),O=(0,u.useSelect)(e=>e(M.O4).getAdminURL("googlesitekit-dashboard")),z=(0,u.useSelect)(e=>!!O&&e(j.M).isNavigatingTo(O)),{saveKeyMetricsSettings:L,setPermissionScopeError:B}=(0,u.useDispatch)(g.oR),{setValues:P}=(0,u.useDispatch)(E.s),{navigateTo:G}=(0,u.useDispatch)(j.M),U=(0,u.useSelect)(e=>e(p.K9).getKeyMetricsConversionEventWidgets()),V=(0,l.useCallback)(async e=>{const{error:t}=await L({widgetSlugs:e});return{error:t}},[L]),F=(0,l.useCallback)(async e=>{if(Object.values(U).flat().some(t=>e.includes(t))?(0,R.sx)(v,"metrics_sidebar_save","conversion_reporting"):(0,R.sx)(v,"metrics_sidebar_save"),S&&I){if(P(p.Kr,{autoSubmit:!0}),!A)return s(),t(),void B({code:C.db,message:(0,c.__)("Additional permissions are required to create new Analytics custom dimensions","google-site-kit"),data:{status:403,scopes:[p.S9],skipModal:!0,redirectURL:b}});n&&await(0,D.mR)(r)}n&&G(O)},[U,S,I,n,v,P,A,s,t,B,b,r,G,O]),W=(0,l.useCallback)(()=>{(0,R.sx)(v,"metrics_sidebar_cancel"),n&&G(O)},[n,O,G,v]);return(0,x.jsx)(SelectionPanelFooter,{savedItemSlugs:i,selectedItemSlugs:d,saveSettings:V,minSelectedItemCount:h.LO,maxSelectedItemCount:h.Hl,isBusy:y||N||z&&n,onSaveSuccess:()=>{F(d)},onCancel:W,isOpen:e,closePanel:t,isFullScreen:n})}SelectionPanelFooter.propTypes={savedItemSlugs:a().array,selectedItemSlugs:a().array,saveSettings:a().func,saveError:a().object,itemLimitError:a().string,minSelectedItemCount:a().number,maxSelectedItemCount:a().number,isBusy:a().bool,onSaveSuccess:a().func,onCancel:a().func,isOpen:a().bool,closePanel:a().func,isFullScreen:a().bool},Footer.propTypes={isOpen:a().bool,closePanel:a().func,savedMetrics:a().array,onNavigationToOAuthURL:a().func,isFullScreen:a().bool};var L=i(54593);function SelectionPanelItems({savedItemSlugs:e=[],allMetricItems:t}){return(0,x.jsx)("div",{className:"googlesitekit-selection-panel-items",children:(0,x.jsx)(L.A,{savedItemSlugs:e,allMetricItems:t})})}function MetricItems({savedMetrics:e}){const t=(0,N.A)(),{isKeyMetricAvailable:i}=(0,u.useSelect)(e=>e(g.oR)),s=(0,u.useInViewSelect)(e=>i=>f.G[i].displayInSelectionPanel({select:e,isViewOnlyDashboard:t,slug:i}),[t]);const n=Object.keys(f.G).reduce(function(e,t){if(!i(t))return e;if(void 0===s||"function"==typeof f.G[t].displayInSelectionPanel&&!s(t))return e;const{title:n,description:o,metadata:{group:r}}=f.G[t];return{...e,[t]:{title:n,description:o,group:r}}},{});return(0,x.jsx)(SelectionPanelItems,{savedItemSlugs:e,allMetricItems:n})}SelectionPanelItems.propTypes={savedItemSlugs:a().array,allMetricItems:a().object.isRequired},MetricItems.propTypes={savedMetrics:a().array};var B=i(67768);const P=(0,v.A)({moduleName:m.L1})(function KeyMetricsError({savedMetrics:e}){const t=(0,_.A)(h.Is,h.Y0),i=(0,u.useInViewSelect)(e=>e(g.oR).getKeyMetricsSettings()),s=(0,l.useMemo)(()=>!(0,o.isEqual)((0,R.N9)(t),(0,R.N9)(e)),[e,t]),n=(0,u.useSelect)(e=>e(g.oR).getErrorForAction("saveKeyMetricsSettings",[{...i,widgetSlugs:t}])),r=t?.length||0;let a;r<h.LO?a=(0,c.sprintf)(/* translators: 1: Minimum number of metrics that can be selected. 2: Number of selected metrics. */ /* translators: 1: Minimum number of metrics that can be selected. 2: Number of selected metrics. */
|
||
(0,c.__)("Select at least %1$d metrics (%2$d selected)","google-site-kit"),h.LO,r):r>h.Hl&&(a=(0,c.sprintf)(/* translators: 1: Maximum number of metrics that can be selected. 2: Number of selected metrics. */ /* translators: 1: Maximum number of metrics that can be selected. 2: Number of selected metrics. */
|
||
(0,c.__)("Select up to %1$d metrics (%2$d selected)","google-site-kit"),h.Hl,r));let d=n;return s&&a&&(d={message:a}),(0,x.jsx)(B.A,{error:d,skipRetryMessage:!!a})});function PanelContent({isOpen:e=!1,closePanel:t,savedViewableMetrics:i,showHeader:s=!0,setIsNavigatingToOAuthURL:r=o.noop,isFullScreen:a=!1}){return(0,x.jsxs)(l.Fragment,{children:[s&&(0,x.jsx)(Header,{closePanel:t}),(0,x.jsx)(MetricItems,{savedMetrics:i}),(0,x.jsx)(I,{}),(0,x.jsxs)("div",{className:n()("googlesitekit-user-input__footer-container",{"googlesitekit-user-input__footer-container--fullscreen":a}),children:[(0,x.jsx)(P,{savedMetrics:i}),(0,x.jsx)(Footer,{isOpen:e,closePanel:t,savedMetrics:i,onNavigationToOAuthURL:()=>{r(!0)},isFullScreen:a})]})]})}PanelContent.propTypes={isOpen:a().bool,closePanel:a().func,savedViewableMetrics:a().array,showHeader:a().bool,setIsNavigatingToOAuthURL:a().func,isFullScreen:a().bool}},27333:(e,t,i)=>{i.d(t,{A:()=>o});var s=i(35470),n=i(78340);function o(e,t){return(0,s.A)(i=>{const{getValue:s}=i(n.s);return s(e,t)},[e,t])}},28663:(e,t,i)=>{i.d(t,{W:()=>j,A:()=>AudienceSegmentationIntroductoryOverlayNotification});var s,n,o=i(62688),r=i.n(o),a=i(82871),l=i(50539),c=i(63696);function d(){return d=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},d.apply(null,arguments)}const u=e=>c.createElement("svg",d({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 296 163"},e),s||(s=c.createElement("g",{clipPath:"url(#audience-segmentation-introductory-graphic-desktop_svg__a)"},c.createElement("path",{fill:"#B8E6CA",d:"M0 16C0 7.163 7.163 0 16 0h264c8.837 0 16 7.163 16 16v147H0z"}),c.createElement("g",{filter:"url(#audience-segmentation-introductory-graphic-desktop_svg__b)"},c.createElement("rect",{width:153,height:174,x:-10,y:25,fill:"#fff",rx:11})),c.createElement("rect",{width:53.016,height:9.516,x:9.031,y:110.641,fill:"#EBEEF0",rx:4.758}),c.createElement("rect",{width:19.031,height:9.516,x:9.031,y:95.688,fill:"#EBEEF0",rx:4.758}),c.createElement("rect",{width:19.031,height:9.516,x:9.031,y:148.703,fill:"#EBEEF0",rx:4.758}),c.createElement("path",{fill:"#B8E6CA",d:"M94.672 108.602a8.836 8.836 0 0 1 8.836-8.836h13.594a8.836 8.836 0 0 1 0 17.672h-13.594a8.836 8.836 0 0 1-8.836-8.836"}),c.createElement("rect",{width:36,height:9,x:9,y:46,fill:"#EBEEF0",rx:4.5}),c.createElement("path",{fill:"#FFDED3",d:"M94.672 161.617a8.836 8.836 0 0 1 8.836-8.836h13.594a8.836 8.836 0 1 1 0 17.672h-13.594a8.836 8.836 0 0 1-8.836-8.836"}),c.createElement("g",{filter:"url(#audience-segmentation-introductory-graphic-desktop_svg__c)"},c.createElement("rect",{width:153,height:174,x:152,y:25,fill:"#fff",rx:11})),c.createElement("rect",{width:52.805,height:9.516,x:170.955,y:110.641,fill:"#EBEEF0",rx:4.758}),c.createElement("rect",{width:18.956,height:9.516,x:170.955,y:95.688,fill:"#EBEEF0",rx:4.758}),c.createElement("rect",{width:18.956,height:9.516,x:170.955,y:148.703,fill:"#EBEEF0",rx:4.758}),c.createElement("path",{fill:"#B8E6CA",d:"M256.256 108.602a8.836 8.836 0 0 1 8.836-8.836h13.47a8.836 8.836 0 0 1 8.835 8.836 8.836 8.836 0 0 1-8.835 8.836h-13.47a8.836 8.836 0 0 1-8.836-8.836"}),c.createElement("rect",{width:36,height:9,x:171,y:46,fill:"#EBEEF0",rx:4.5}),c.createElement("path",{stroke:"#EBEEF0",strokeWidth:2,d:"M295 73.5H152"}),c.createElement("path",{fill:"#FFDED3",d:"M256.256 161.617a8.836 8.836 0 0 1 8.836-8.836h13.47a8.836 8.836 0 0 1 8.835 8.836 8.836 8.836 0 0 1-8.835 8.836h-13.47a8.836 8.836 0 0 1-8.836-8.836"}),c.createElement("path",{stroke:"#EBEEF0",strokeWidth:2,d:"M143 73.5H0"}))),n||(n=c.createElement("defs",null,c.createElement("filter",{id:"audience-segmentation-introductory-graphic-desktop_svg__b",width:185,height:206,x:-26,y:13,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},c.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),c.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"}),c.createElement("feOffset",{dy:4}),c.createElement("feGaussianBlur",{stdDeviation:8}),c.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),c.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),c.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_1395_20972"}),c.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_1395_20972",result:"shape"})),c.createElement("filter",{id:"audience-segmentation-introductory-graphic-desktop_svg__c",width:185,height:206,x:136,y:13,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},c.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),c.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"}),c.createElement("feOffset",{dy:4}),c.createElement("feGaussianBlur",{stdDeviation:8}),c.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),c.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),c.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_1395_20972"}),c.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_1395_20972",result:"shape"})),c.createElement("clipPath",{id:"audience-segmentation-introductory-graphic-desktop_svg__a"},c.createElement("path",{fill:"#fff",d:"M0 16C0 7.163 7.163 0 16 0h264c8.837 0 16 7.163 16 16v147H0z"})))));var g,p,m,h;function f(){return f=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},f.apply(null,arguments)}const y=e=>c.createElement("svg",f({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 343 123"},e),c.createElement("g",{clipPath:"url(#audience-segmentation-introductory-graphic-mobile_svg__a)"},g||(g=c.createElement("path",{fill:"#B8E6CA",d:"M41.064 27.146a64 64 0 0 1 6.51-5.868C69.418 4.126 87.464 4.153 112.45 7.283c16.891 2.116 26.759 10.167 49.788 8.9s28.929-7.127 57.117-5.25c22.315 1.487 32.324 5.897 52.163 16.213 18.36 9.549 35.031 26.324 43.408 48.509 14.361 38.026-11.243 106.466-45.58 109.693-24.881 2.339-45.414-25.243-70.527-18.855-15.47 3.936-24.646 20.444-36.581 31.339-13.925 12.711-43.922 11.912-60.227 5.129-15.538-6.464-30.653-19.276-35.728-38.145-3.863-14.369-4.916-31.498-15.733-44.622-13.09-15.883-21.087-22.968-25.581-44.54-3.903-18.734 4.494-36.505 16.095-48.508"})),c.createElement("mask",{id:"audience-segmentation-introductory-graphic-mobile_svg__b",width:295,height:203,x:24,y:5,maskUnits:"userSpaceOnUse",style:{maskType:"alpha"}},p||(p=c.createElement("path",{fill:"#B8E6CA",d:"M41.064 27.146a64 64 0 0 1 6.51-5.868C69.418 4.126 87.464 4.153 112.45 7.283c16.891 2.116 26.759 10.167 49.788 8.9s28.929-7.127 57.117-5.25c22.315 1.487 32.324 5.897 52.163 16.213 18.36 9.549 35.031 26.324 43.408 48.509 14.361 38.026-11.243 106.466-45.58 109.693-24.881 2.339-45.414-25.243-70.527-18.855-15.47 3.936-24.646 20.444-36.581 31.339-13.925 12.711-43.922 11.912-60.227 5.129-15.538-6.464-30.653-19.276-35.728-38.145-3.863-14.369-4.916-31.498-15.733-44.622-13.09-15.883-21.087-22.968-25.581-44.54-3.903-18.734 4.494-36.505 16.095-48.508"}))),m||(m=c.createElement("g",{mask:"url(#audience-segmentation-introductory-graphic-mobile_svg__b)"},c.createElement("g",{filter:"url(#audience-segmentation-introductory-graphic-mobile_svg__c)"},c.createElement("rect",{width:100.401,height:136.493,x:71.449,y:21.433,fill:"#fff",rx:7.218})),c.createElement("rect",{width:34.79,height:6.244,x:83.941,y:77.631,fill:"#EBEEF0",rx:3.122}),c.createElement("rect",{width:12.489,height:6.244,x:83.941,y:67.819,fill:"#EBEEF0",rx:3.122}),c.createElement("rect",{width:12.489,height:6.244,x:83.941,y:99.983,fill:"#EBEEF0",rx:3.122}),c.createElement("path",{fill:"#B8E6CA",d:"M140.133 76.293a5.8 5.8 0 0 1 5.798-5.798h8.921a5.798 5.798 0 0 1 0 11.596h-8.921a5.8 5.8 0 0 1-5.798-5.798"}),c.createElement("rect",{width:23.624,height:5.906,x:83.926,y:35.213,fill:"#EBEEF0",rx:2.953}),c.createElement("path",{fill:"#FFDED3",d:"M140.133 108.458a5.8 5.8 0 0 1 5.798-5.798h8.921a5.798 5.798 0 0 1 0 11.597h-8.921a5.8 5.8 0 0 1-5.798-5.799"}),c.createElement("rect",{width:36.574,height:6.244,x:83.043,y:109.796,fill:"#EBEEF0",rx:3.122}),c.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.312,d:"M171.848 53.259H72.103"}),c.createElement("g",{filter:"url(#audience-segmentation-introductory-graphic-mobile_svg__d)"},c.createElement("rect",{width:100.401,height:136.493,x:184.973,y:21.433,fill:"#fff",rx:7.218})),c.createElement("rect",{width:34.652,height:6.244,x:197.414,y:77.631,fill:"#EBEEF0",rx:3.122}),c.createElement("rect",{width:12.439,height:6.244,x:197.414,y:67.819,fill:"#EBEEF0",rx:3.122}),c.createElement("rect",{width:12.439,height:6.244,x:197.41,y:99.983,fill:"#EBEEF0",rx:3.122}),c.createElement("path",{fill:"#B8E6CA",d:"M253.391 76.293a5.8 5.8 0 0 1 5.798-5.798h8.839a5.798 5.798 0 0 1 0 11.596h-8.839a5.8 5.8 0 0 1-5.798-5.798"}),c.createElement("rect",{width:23.624,height:5.906,x:197.449,y:35.213,fill:"#EBEEF0",rx:2.953}),c.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.312,d:"M278.82 53.259h-93.838"}),c.createElement("path",{fill:"#FFDED3",d:"M253.391 108.458a5.8 5.8 0 0 1 5.798-5.798h8.839a5.798 5.798 0 0 1 0 11.597h-8.839a5.8 5.8 0 0 1-5.798-5.799"}),c.createElement("rect",{width:36.429,height:6.244,x:196.523,y:109.796,fill:"#EBEEF0",rx:3.122})))),h||(h=c.createElement("defs",null,c.createElement("filter",{id:"audience-segmentation-introductory-graphic-mobile_svg__c",width:132.402,height:168.493,x:55.449,y:9.433,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},c.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),c.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"}),c.createElement("feOffset",{dy:4}),c.createElement("feGaussianBlur",{stdDeviation:8}),c.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),c.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),c.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_2898_16651"}),c.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2898_16651",result:"shape"})),c.createElement("filter",{id:"audience-segmentation-introductory-graphic-mobile_svg__d",width:132.402,height:168.493,x:168.973,y:9.433,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},c.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),c.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"}),c.createElement("feOffset",{dy:4}),c.createElement("feGaussianBlur",{stdDeviation:8}),c.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),c.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),c.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_2898_16651"}),c.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2898_16651",result:"shape"})),c.createElement("clipPath",{id:"audience-segmentation-introductory-graphic-mobile_svg__a"},c.createElement("path",{fill:"#fff",d:"M0 0h343v128H0z"})))));var v=i(76422),_=i(12108),k=i(32947),x=i(71423),I=i(77766),A=i(62540);const j="audienceSegmentationIntroductoryOverlayNotification";function AudienceSegmentationIntroductoryOverlayNotification({id:e,Notification:t}){const s=(0,I.A)(),n=(0,k.dv)(),{dismissNotification:o}=(0,l.useDispatch)(x.D);const r={category:`${s}_audiences-secondary-user-intro`};return(0,A.jsx)(t,{gaTrackingEventArgs:r,children:(0,A.jsx)(v.A,{notificationID:e,title:(0,a.__)("New! Visitor groups","google-site-kit"),description:(0,a.__)("You can now learn more about your site visitor groups by comparing different metrics.","google-site-kit"),GraphicDesktop:u,GraphicMobile:y,ctaButton:{label:(0,a.__)("Show me","google-site-kit"),onClick:function(t){t.preventDefault(),setTimeout(()=>{i.g.scrollTo({top:(0,_.YJ)(".googlesitekit-widget-area--mainDashboardTrafficAudienceSegmentation",n),behavior:"smooth"})},0),o(e)}},dismissButton:{label:(0,a.__)("Got it","google-site-kit")},gaTrackingEventArgs:r})})}AudienceSegmentationIntroductoryOverlayNotification.propTypes={id:r().string.isRequired,Notification:r().elementType.isRequired}},29507:(e,t,i)=>{i.d(t,{A:()=>DateRangeSelector});var s,n=i(21795),o=i(4452),r=i.n(o),a=i(63696),l=i(19266),c=i(82871),d=i(50539),u=i(49383);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 p=e=>a.createElement("svg",g({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 18 20"},e),s||(s=a.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M6 9H4v2h2zm4 0H8v2h2zm4 0h-2v2h2zm2-7h-1V0h-2v2H5V0H3v2H2C.89 2 .01 2.9.01 4L0 18a2 2 0 0 0 2 2h14c1.1 0 2-.9 2-2V4c0-1.1-.9-2-2-2m0 16H2V7h14z"})));var m=i(58116),h=i(99235),f=i(12850),y=i(7081),v=i(77766),_=i(62540);function DateRangeSelector(){const e=(0,f.Ql)(),t=(0,d.useSelect)(e=>e(m.oR).getDateRange()),{setDateRange:i}=(0,d.useDispatch)(m.oR),{resetInViewHook:s}=(0,d.useDispatch)(y.n),[o,g]=(0,a.useState)(!1),k=(0,a.useRef)(),x=(0,v.A)();(0,n.A)(k,()=>g(!1)),(0,h.l)([l._f,l.wn],k,()=>g(!1));const I=(0,a.useCallback)(()=>{g(!o)},[o]),A=(0,a.useCallback)(n=>{const o=Object.values(e)[n].slug;t!==o&&(0,f.sx)(`${x}_headerbar`,"change_daterange",o),s(),i(o),g(!1)},[e,t,s,i,x]),j=e[t]?.label,M=Object.values(e).map(e=>e.label);return(0,_.jsxs)("div",{ref:k,className:"googlesitekit-date-range-selector googlesitekit-dropdown-menu mdc-menu-surface--anchor",children:[(0,_.jsx)(u.Button,{className:r()("mdc-button--dropdown","googlesitekit-header__dropdown","googlesitekit-header__date-range-selector-menu","googlesitekit-border-radius-round--phone","googlesitekit-button-icon--phone"),onClick:I,icon:(0,_.jsx)(p,{width:"20",height:"20"}),"aria-haspopup":"menu","aria-expanded":o,"aria-controls":"date-range-selector-menu",title:(0,c.__)("Date range","google-site-kit"),tooltipEnterDelayInMS:500,text:!0,tooltip:!0,children:j}),(0,_.jsx)(u.Menu,{menuOpen:o,menuItems:M,onSelected:A,id:"date-range-selector-menu",className:"googlesitekit-width-auto"})]})}},29584:(e,t,i)=>{i.d(t,{A:()=>DismissButton});var s=i(62688),n=i.n(s),o=i(82871),r=i(49383),a=i(62540);function DismissButton({className:e,label:t=(0,o.__)("Maybe later","google-site-kit"),onClick:i,disabled:s,tertiary:n=!0}){return i?(0,a.jsx)(r.Button,{className:e,onClick:i,disabled:s,tertiary:n,children:t}):null}DismissButton.propTypes={className:n().string,label:n().string,onClick:n().func,disabled:n().bool,tertiary:n().bool,dismissOptions:n().shape({expiresInSeconds:n().number,skipHidingFromQueue:n().bool})}},29877:(e,t,i)=>{function s(e,t=3){return e.filter(({dimensionValues:e})=>"(not set)"!==e[0].value&&""!==e[0].value).slice(0,t)}i.d(t,{S:()=>s})},29898:(e,t,i)=>{i.d(t,{A:()=>LoadingWrapper});var s=i(62688),n=i.n(s),o=i(23224),r=i(62540);function LoadingWrapper({loading:e,children:t,...i}){return e?(0,r.jsx)(o.A,{...i}):t}LoadingWrapper.propTypes={loading:n().bool,children:n().node,...o.A.propTypes}},30823:(e,t,i)=>{i.d(t,{A:()=>LearnMoreLink});var s=i(62688),n=i.n(s),o=i(82871),r=i(20898),a=i(62540);function LearnMoreLink({href:e,className:t,label:i=(0,o.__)("Learn more","google-site-kit"),external:s=!0,onClick:n=()=>{}}){return e?(0,a.jsx)(r.A,{href:e,className:t,onClick:n,external:s,children:i}):null}LearnMoreLink.propTypes={href:n().string.isRequired,className:n().string,label:n().string,external:n().bool,onClick:n().func}},32947:(e,t,i)=>{i.d(t,{Fo:()=>o,Lg:()=>r,Qb:()=>n,dv:()=>l,mp:()=>a});var s=i(15577);const n="xlarge",o="desktop",r="tablet",a="small";function l(){const e=(0,s.SO)();return e>1280?n:e>960?o:e>600?r:a}},33566:(e,t,i)=>{i.d(t,{A:()=>p});var s=i(99408),n=i(82871),o=i(63696),r=i(44451),a=i(50539),l=i(78340),c=i(58116),d=i(67150),u=i(72455),g=i(27333);function p({redirectURL:e,onSuccess:t,onError:p,onOAuthNavigation:m}={}){const h=(0,s.A)(),[f,y]=(0,o.useState)([]),[v,_]=(0,o.useState)([]),[k,x]=(0,o.useState)(!1),I=(0,a.useSelect)(e=>e(c.oR).hasScope(u.S9)),A=(0,g.A)(u.PW,"autoSubmit"),{setValues:j}=(0,a.useDispatch)(l.s),{setPermissionScopeError:M}=(0,a.useDispatch)(c.oR),{enableAudienceGroup:S,fetchSyncAvailableCustomDimensions:b,determineNeedForAnalytics4EditScope:N,syncAvailableAudiences:E}=(0,a.useDispatch)(u.K9);e||(e=(0,r.F)(i.g.location.href,{notification:"audience_segmentation"}));const w=(0,o.useCallback)(async()=>{const{error:e}=await E();if(e)return{error:e};const{error:t}=await b();if(t)return{error:t};if(!I){const{error:e,needsScope:t}=await N();if(e)return{error:e};if(t)return{needsScope:!0}}j(u.PW,{autoSubmit:!1});const{error:i,failedSiteKitAudienceSlugs:s}=await S(v)||{};return{error:i,failedSiteKitAudienceSlugs:s}},[S,v,b,I,N,j,E]),C=(0,o.useCallback)(async()=>{x(!0);const{error:s,needsScope:o,failedSiteKitAudienceSlugs:r}=await w();if(o)return j(u.PW,{autoSubmit:!0}),await(m?.()),void M({code:d.db,message:(0,n.__)("Additional permissions are required to create new audiences in Analytics.","google-site-kit"),data:{status:403,scopes:[u.S9],skipModal:!0,skipDefaultErrorNotifications:!0,redirectURL:e,errorRedirectURL:i.g.location.href}});if(s||r?p?.():t?.(),h()){function a(e){return e.length?[]:e}s?(y([s]),_(a)):Array.isArray(r)?(_(r),y(a)):(y(a),_(a)),x(!1)}},[w,h,j,m,M,e,p,t]);return(0,o.useEffect)(()=>{I&&A&&C()},[I,A,C]),{apiErrors:f,failedAudiences:v,isSaving:k,onEnableGroups:C}}},34375:(e,t,i)=>{i.d(t,{A:()=>SetupCTA});var s=i(4452),n=i.n(s),o=i(62688),r=i.n(o),a=i(63696),l=i(50539),c=i(71423),d=i(7070),u=i(7184),g=i(30823),p=i(3782),m=i(29584),h=i(55527),f=i(49383),y=i(62540);function SetupCTA({notificationID:e,title:t,description:i,errorText:s,helpText:o,learnMoreLink:r,dismissButton:g,ctaButton:p,svg:m,footer:v,gaTrackingEventArgs:_,waitingProgress:k,...x}){const I=(0,d.A)(e,_?.category),{dismissNotification:A}=(0,l.useDispatch)(c.D);return(0,y.jsxs)(a.Fragment,{children:[!!k&&(0,y.jsx)(f.ProgressBar,{className:"googlesitekit-banner__progress-bar",...k}),(0,y.jsx)("div",{className:n()("googlesitekit-widget-context",{"googlesitekit-widget-context--with-progress-bar":!!k}),children:(0,y.jsx)(h.xA,{children:(0,y.jsx)(h.fI,{children:(0,y.jsx)(h.fh,{size:12,children:(0,y.jsx)(u.A,{className:"googlesitekit-banner--setup-cta",title:t,description:i,errorText:s,helpText:o,learnMoreLink:r&&{...r,onClick:async function(e){I.clickLearnMore(_?.label,_?.value),await(r?.onClick?.(e))}},dismissButton:g&&{...g,onClick:async function(t){await(g?.onClick?.(t)),I.dismiss(_?.label,_?.value),A(e,{...g?.dismissOptions})}},ctaButton:p&&{...p,onClick:async function(t){I.confirm(_?.label,_?.value),await(p?.onClick?.(t)),p?.dismissOnClick&&A(e,{...p?.dismissOptions})}},svg:m,footer:v,...x})})})})})]})}SetupCTA.propTypes={notificationID:r().string,title:r().string,description:r().oneOfType([r().string,r().node]),errorText:r().string,helpText:r().string,learnMoreLink:r().shape(g.A.propTypes),dismissButton:r().shape(m.A.propTypes),ctaButton:r().shape(p.A.propTypes),svg:r().shape({desktop:r().elementType,mobile:r().elementType,verticalPosition:r().oneOf(["top","center","bottom"])}),footer:r().node,gaTrackingEventArgs:r().shape({category:r().string,label:r().string,value:r().number}),waitingProgress:r().shape(f.ProgressBar.propTypes)}},35001:(e,t,i)=>{i.d(t,{c1:()=>_,V8:()=>I,WP:()=>x});var s=i(50532),n=i.n(s),o=i(39828),r=i(62688),a=i.n(r),l=i(63696),c=i(47345),d=i(73549),u=i(62540);function WidgetReportZero({widgetSlug:e,moduleSlug:t,...i}){const s=(0,l.useMemo)(()=>({moduleSlug:t}),[t]);return(0,c.A)(e,d.A,s),(0,u.jsx)(d.A,{moduleSlug:t,...i})}WidgetReportZero.propTypes={widgetSlug:a().string.isRequired,...d.A.propTypes};var g=i(11345);function WidgetReportError({widgetSlug:e,...t}){return(0,u.jsx)(g.A,{...t})}WidgetReportError.propTypes={widgetSlug:a().string.isRequired,...g.A.propTypes};var p=i(84093),m=i(23141),h=i(17064),f=i(52684),y=i(50539),v=i(7081);function WPDashboardReportError({moduleSlug:e,error:t}){const i=(0,f.A)(WPDashboardReportError,"WPDashboardReportError"),{setValue:s}=(0,y.useDispatch)(v.n),n=t.message,o=(0,y.useSelect)(t=>t(v.n).getValue(`WPDashboardReportError-${e}-${n}`));return(0,h.A)(()=>{s(`WPDashboardReportError-${e}-${n}`,i)},()=>{s(`WPDashboardReportError-${e}-${n}`,void 0)}),o!==i?null:(0,u.jsx)(g.A,{moduleSlug:e,error:t})}WPDashboardReportError.propTypes={moduleSlug:a().string.isRequired,error:a().object.isRequired};const _=n()(e=>({widgetSlug:e,Widget:k(e)(o.A),WidgetRecoverableModules:k(e)(m.A),WidgetReportZero:k(e)(WidgetReportZero),WidgetReportError:k(e)(WidgetReportError),WidgetNull:k(e)(p.A)}));function k(e){return t=>{const i=(0,l.forwardRef)((i,s)=>(0,u.jsx)(t,{...i,ref:s,widgetSlug:e}));return i.displayName="WithWidgetSlug",(t.displayName||t.name)&&(i.displayName+=`(${t.displayName||t.name})`),i}}function x(e){const t=_(e);return e=>{function DecoratedComponent(i){return(0,u.jsx)(e,{...i,...t})}return DecoratedComponent.displayName="WithWidgetComponentProps",(e.displayName||e.name)&&(DecoratedComponent.displayName+=`(${e.displayName||e.name})`),DecoratedComponent}}function I(e){return t=>{function DecoratedComponent(i){return(0,u.jsx)(t,{...i,WPDashboardReportError:k(e)(WPDashboardReportError)})}return DecoratedComponent.displayName="WithWPDashboardWidgetComponentProps",(t.displayName||t.name)&&(DecoratedComponent.displayName+=`(${t.displayName||t.name})`),DecoratedComponent}}},35323:(e,t,i)=>{i.d(t,{A:()=>o});var s=i(24558),n=i(77766);function o(){const e=(0,n.A)();return s.Nn.includes(e)}},35902:(e,t,i)=>{i.d(t,{A:()=>ReportErrorActions});var s=i(62688),n=i.n(s),o=i(63696),r=i(13606),a=i(82871),l=i(50539),c=i(49383),d=i(93896),u=i(37226),g=i(67150),p=i(35323),m=i(20898),h=i(62540);function ReportErrorActions(e){const{moduleSlug:t,error:i,GetHelpLink:s,hideGetHelpLink:n,buttonVariant:f,onRetry:y,onRequestAccess:v,getHelpClassName:_,RequestAccessButton:k,RetryButton:x}=e,I=(0,p.A)(),A=(0,l.useSelect)(e=>e(u.i).getModuleStoreName(t)),j=(0,l.useSelect)(e=>"function"==typeof e(A)?.getServiceEntityAccessURL?e(A).getServiceEntityAccessURL():null),M=Array.isArray(i)?i:[i],S=(0,l.useSelect)(e=>M.map(t=>{const i=e(A)?.getSelectorDataForError(t);return{...t,selectorData:i}})),b=S?.filter(e=>(0,g.vl)(e,e.selectorData)&&"getReport"===e.selectorData.name),N=!!b.length,E=(0,l.useSelect)(e=>{const i={...N?b[0]:M[0]};return(0,g.SG)(i)&&(i.code=`${t}_insufficient_permissions`),e(d.O4).getErrorTroubleshootingLinkURL(i)}),w=(0,l.useDispatch)(),C=M.some(e=>(0,g.SG)(e)),T=(0,o.useCallback)(()=>{b.forEach(e=>{const{selectorData:t}=e;w(t.storeName).invalidateResolution(t.name,t.args)}),y?.()},[w,b,y]),D=j&&C&&!I;return(0,h.jsxs)("div",{className:"googlesitekit-report-error-actions",children:[D&&("function"==typeof k?(0,h.jsx)(k,{requestAccessURL:j}):(0,h.jsx)(c.Button,{onClick:v,href:j,target:"_blank",danger:"danger"===f,tertiary:"tertiary"===f,children:(0,a.__)("Request access","google-site-kit")})),N&&(0,h.jsxs)(o.Fragment,{children:["function"==typeof x?(0,h.jsx)(x,{handleRetry:T}):(0,h.jsx)(c.Button,{onClick:T,danger:"danger"===f,tertiary:"tertiary"===f,children:(0,a.__)("Retry","google-site-kit")}),!n&&(0,h.jsx)("span",{className:"googlesitekit-error-retry-text",children:(0,r.A)((0,a.__)("Retry didn’t work? <HelpLink />","google-site-kit"),{HelpLink:(0,h.jsx)(m.A,{href:E,external:!0,hideExternalIndicator:!0,children:(0,a.__)("Get help","google-site-kit")})})})]}),!N&&!n&&(0,h.jsx)("div",{className:_,children:"function"==typeof s?(0,h.jsx)(s,{linkURL:E}):(0,h.jsx)(m.A,{href:E,external:!0,hideExternalIndicator:!0,children:(0,a.__)("Get help","google-site-kit")})})]})}ReportErrorActions.propTypes={moduleSlug:n().string.isRequired,error:n().oneOfType([n().arrayOf(n().object),n().object]).isRequired,GetHelpLink:n().elementType,hideGetHelpLink:n().bool,buttonVariant:n().string,onRetry:n().func,onRequestAccess:n().func,getHelpClassName:n().string,RequestAccessButton:n().elementType,RetryButton:n().elementType}},37226:(e,t,i)=>{i.d(t,{U:()=>n,i:()=>s});const s="core/modules",n="insufficient_module_dependencies"},39771:(e,t,i)=>{i.d(t,{Ay:()=>TourTooltips,R0:()=>h,ei:()=>y});var s=i(15844),n=i(36703),o=i(62688),r=i.n(o),a=i(82871),l=i(50539),c=i(7081),d=i(58116),u=i(89318),g=i(60592),p=i(77766),m=i(62540);const h={options:{arrowColor:"#3c7251",backgroundColor:"#3c7251",overlayColor:"rgba(0, 0, 0, 0.6)",textColor:"#fff",zIndex:2e4},spotlight:{border:"2px solid #3c7251",backgroundColor:"#fff"}},f={back:(0,a.__)("Back","google-site-kit"),close:(0,a.__)("Close","google-site-kit"),last:(0,a.__)("Got it","google-site-kit"),next:(0,a.__)("Next","google-site-kit")},y={disableAnimation:!0,styles:{arrow:{length:8,margin:56,spread:16},floater:{filter:"drop-shadow(rgba(60, 64, 67, 0.3) 0px 1px 2px) drop-shadow(rgba(60, 64, 67, 0.15) 0px 2px 6px)"}}},v={VIEW:"feature_tooltip_view",NEXT:"feature_tooltip_advance",PREV:"feature_tooltip_return",DISMISS:"feature_tooltip_dismiss",COMPLETE:"feature_tooltip_complete"};function TourTooltips({steps:e,tourID:t,gaEventCategory:o,callback:r}){const a=`${t}-step`,_=`${t}-run`,{setValue:k}=(0,l.useDispatch)(c.n),{dismissTour:x}=(0,l.useDispatch)(d.oR),I=(0,l.useRegistry)(),A=(0,p.A)(),j=(0,l.useSelect)(e=>e(c.n).getValue(a)||0),M=(0,l.useSelect)(e=>e(c.n).getValue(_)&&!1===e(d.oR).isTourDismissed(t));(0,s.A)(function(){i.g.document.body.classList.add("googlesitekit-showing-feature-tour",`googlesitekit-showing-feature-tour--${t}`),k(_,!0)});const S=e.map(e=>({disableBeacon:!0,isFixed:!0,placement:"auto",...e}));return(0,m.jsx)(n.Ay,{callback:function(e){!function({index:e,action:t,lifecycle:i,size:s,status:r,type:a}){const l=e+1,c="function"==typeof o?o(A):o;a===n.qY.TOOLTIP&&i===n.VD.TOOLTIP?(0,u.sx)(c,v.VIEW,l):t===n.kl.CLOSE&&i===n.VD.COMPLETE?(0,u.sx)(c,v.DISMISS,l):t===n.kl.NEXT&&r===n.XQ.FINISHED&&a===n.qY.TOUR_END&&s===l&&(0,u.sx)(c,v.COMPLETE,l),i===n.VD.COMPLETE&&r!==n.XQ.FINISHED&&(t===n.kl.PREV&&(0,u.sx)(c,v.PREV,l),t===n.kl.NEXT&&(0,u.sx)(c,v.NEXT,l))}(e);const{action:s,index:l,status:c,step:d,type:g}=e,p=s===n.kl.CLOSE,m=!p&&[n.qY.STEP_AFTER,n.qY.TARGET_NOT_FOUND].includes(g),h=[n.XQ.FINISHED,n.XQ.SKIPPED].includes(c),f=p&&g===n.qY.STEP_AFTER,y=h||f;if(n.qY.STEP_BEFORE===g){let e=d.target;"string"==typeof d.target&&(e=i.g.document.querySelector(d.target)),e?.scrollIntoView?.({block:"center"})}m?function(e,t){k(a,e+(t===n.kl.PREV?-1:1))}(l,s):y&&(i.g.document.body.classList.remove("googlesitekit-showing-feature-tour",`googlesitekit-showing-feature-tour--${t}`),x(t)),r&&r(e,I)},floaterProps:y,locale:f,run:M,stepIndex:j,steps:S,styles:h,tooltipComponent:g.A,continuous:!0,disableOverlayClose:!0,disableScrolling:!0,showProgress:!0})}TourTooltips.propTypes={steps:r().arrayOf(r().object).isRequired,tourID:r().string.isRequired,gaEventCategory:r().oneOfType([r().string,r().func]).isRequired,callback:r().func}},39828:(e,t,i)=>{i.d(t,{A:()=>d});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)(({children:e,className:t,widgetSlug:i,noPadding:s,Header:o,Footer:r},a)=>(0,l.jsxs)("div",{className:n()("googlesitekit-widget",`googlesitekit-widget--${i}`,{"googlesitekit-widget--no-padding":s},{"googlesitekit-widget--with-header":o},t),ref:a,children:[o&&(0,l.jsx)("div",{className:"googlesitekit-widget__header",children:(0,l.jsx)(o,{})}),(0,l.jsx)("div",{className:"googlesitekit-widget__body",children:e}),r&&(0,l.jsx)("div",{className:"googlesitekit-widget__footer",children:(0,l.jsx)(r,{})})]}));c.defaultProps={children:void 0,noPadding:!1},c.propTypes={children:r().node,widgetSlug:r().string.isRequired,noPadding:r().bool,Header:r().elementType,Footer:r().elementType};const d=c},40409:(e,t,i)=>{i.d(t,{A:()=>ProgressIndicator});var s=i(4452),n=i.n(s),o=i(62688),r=i.n(o),a=i(62540);function ProgressIndicator({currentSegment:e=0,totalSegments:t=0,className:i}){return(0,a.jsxs)("div",{style:{gridTemplateColumns:`46px repeat(${t||1}, 1fr)`},className:n()("googlesitekit-progress-indicator",i),children:[(0,a.jsx)("div",{className:n()("googlesitekit-progress-indicator__segment")}),t>0&&Array.from(Array(e+1).keys()).map(i=>(0,a.jsx)("div",{className:n()("googlesitekit-progress-indicator__segment",{"googlesitekit-progress-indicator__segment--final":e+1===t})},i))]})}ProgressIndicator.propTypes={currentSegment:r().number,totalSegments:r().number,className:r().string}},42343:(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",fill:"none",viewBox:"0 0 24 24"},e),s||(s=n.createElement("path",{fill:"currentColor",d:"m5.825 22 2.325-7.6L2 10h7.6L12 2l2.4 8H22l-6.15 4.4 2.325 7.6L12 17.3z"})))},42926:(e,t,i)=>{i.d(t,{A:()=>d});var s=i(19371),n=i(31638);const o=function(e){const t=Object.keys(e).reduce((t,i)=>(t[(0,n.getStablePath)(i)]=e[i],t),{});let i=!1;return(e,s)=>{if(i)return s(e);setTimeout(()=>{i=!0},3e3);const{parse:o=!0}=e,r=e.path;if("string"==typeof e.path){const i=e.method?.toUpperCase()||"GET",s=(0,n.getStablePath)(r);if(o&&"GET"===i&&t[s]){const e=Promise.resolve(t[s].body);return delete t[s],e}if("OPTIONS"===i&&t[i]&&t[i][s]){const e=Promise.resolve(t[i][s]);return delete t[i][s],e}}return s(e)}},{nonce:r,nonceEndpoint:a,preloadedData:l,rootURL:c}=i.g._googlesitekitAPIFetchData||{};s.default.nonceEndpoint=a,s.default.nonceMiddleware=s.default.createNonceMiddleware(r),s.default.rootURLMiddleware=s.default.createRootURLMiddleware(c),s.default.preloadingMiddleware=o(l),s.default.use(s.default.nonceMiddleware),s.default.use(s.default.mediaUploadMiddleware),s.default.use(s.default.rootURLMiddleware),s.default.use(s.default.preloadingMiddleware);const d=s.default},43427:(e,t,i)=>{i.r(t),i.d(t,{AREA_ENTITY_DASHBOARD_CONTENT_PRIMARY:()=>d,AREA_ENTITY_DASHBOARD_MONETIZATION_PRIMARY:()=>g,AREA_ENTITY_DASHBOARD_SPEED_PRIMARY:()=>u,AREA_ENTITY_DASHBOARD_TRAFFIC_PRIMARY:()=>c,AREA_MAIN_DASHBOARD_CONTENT_PRIMARY:()=>r,AREA_MAIN_DASHBOARD_KEY_METRICS_PRIMARY:()=>s,AREA_MAIN_DASHBOARD_MONETIZATION_PRIMARY:()=>l,AREA_MAIN_DASHBOARD_SPEED_PRIMARY:()=>a,AREA_MAIN_DASHBOARD_TRAFFIC_AUDIENCE_SEGMENTATION:()=>o,AREA_MAIN_DASHBOARD_TRAFFIC_PRIMARY:()=>n,default:()=>p});const s="mainDashboardKeyMetricsPrimary",n="mainDashboardTrafficPrimary",o="mainDashboardTrafficAudienceSegmentation",r="mainDashboardContentPrimary",a="mainDashboardSpeedPrimary",l="mainDashboardMonetizationPrimary",c="entityDashboardTrafficPrimary",d="entityDashboardContentPrimary",u="entityDashboardSpeedPrimary",g="entityDashboardMonetizationPrimary",p={AREA_MAIN_DASHBOARD_KEY_METRICS_PRIMARY:s,AREA_MAIN_DASHBOARD_TRAFFIC_PRIMARY:n,AREA_MAIN_DASHBOARD_CONTENT_PRIMARY:r,AREA_MAIN_DASHBOARD_SPEED_PRIMARY:a,AREA_MAIN_DASHBOARD_MONETIZATION_PRIMARY:l,AREA_ENTITY_DASHBOARD_TRAFFIC_PRIMARY:c,AREA_ENTITY_DASHBOARD_CONTENT_PRIMARY:d,AREA_ENTITY_DASHBOARD_SPEED_PRIMARY:u,AREA_ENTITY_DASHBOARD_MONETIZATION_PRIMARY:g}},43569:(e,t,i)=>{i.d(t,{A:()=>Notification});var s=i(62688),n=i.n(s),o=i(63696),r=i(50539),a=i(7081),l=i(71423),c=i(89362);function d(e){return`notification/${e}/viewed`}function u(e){return(0,r.useSelect)(t=>!!t(a.n).getValue(d(e)),[e])}function ViewedStateObserver({id:e,observeRef:t,threshold:i}){const s=(0,c.A)(t,{threshold:i}),{setValue:n}=(0,r.useDispatch)(a.n),{markNotificationSeen:d}=(0,r.useDispatch)(l.D),g=!!s?.isIntersecting,p=u(e),m=(0,o.useRef)();function h(){m.current&&clearTimeout(m.current)}return(0,o.useEffect)(()=>(!p&&g?(h(),m.current=setTimeout(()=>{s?.isIntersecting&&(n(u.getKey(e),!0),d(e))},3e3)):!g&&m.current&&h(),()=>{h()}),[p,g,n,d,e,s]),null}u.getKey=d,ViewedStateObserver.propTypes={id:n().string,observeRef:n().object,threshold:n().number};var g=i(7070),p=i(62540);function Notification({id:e,className:t,gaTrackingEventArgs:i,children:s,onView:n}){const a=(0,o.useRef)(),c=u(e),d=(0,g.A)(e,i?.category,{viewAction:i?.viewAction}),[m,h]=(0,o.useState)(!1),f=(0,r.useSelect)(t=>t(l.D).getNotificationSeenDates(e)),{dismissNotification:y}=(0,r.useDispatch)(l.D);return(0,o.useEffect)(()=>{!m&&c&&(d.view(i?.label,i?.value),n?.(),h(!0)),f?.length>=3&&y(e,{skipHidingFromQueue:!0})},[c,d,m,i,n,f,y,e]),(0,p.jsxs)("section",{id:e,ref:a,className:t,children:[s,!c&&(0,p.jsx)(ViewedStateObserver,{id:e,observeRef:a,threshold:.5})]})}Notification.propTypes={id:n().string,className:n().string,gaTrackingEventArgs:n().shape({category:n().string,viewAction:n().string,label:n().string,value:n().string}),children:n().node,onView:n().func}},44949:(e,t,i)=>{i.r(t),i.d(t,{CONTEXT_ENTITY_DASHBOARD_CONTENT:()=>c,CONTEXT_ENTITY_DASHBOARD_MONETIZATION:()=>u,CONTEXT_ENTITY_DASHBOARD_SPEED:()=>d,CONTEXT_ENTITY_DASHBOARD_TRAFFIC:()=>l,CONTEXT_MAIN_DASHBOARD_CONTENT:()=>o,CONTEXT_MAIN_DASHBOARD_KEY_METRICS:()=>s,CONTEXT_MAIN_DASHBOARD_MONETIZATION:()=>a,CONTEXT_MAIN_DASHBOARD_SPEED:()=>r,CONTEXT_MAIN_DASHBOARD_TRAFFIC:()=>n,default:()=>g});const s="mainDashboardKeyMetrics",n="mainDashboardTraffic",o="mainDashboardContent",r="mainDashboardSpeed",a="mainDashboardMonetization",l="entityDashboardTraffic",c="entityDashboardContent",d="entityDashboardSpeed",u="entityDashboardMonetization",g={CONTEXT_MAIN_DASHBOARD_KEY_METRICS:s,CONTEXT_MAIN_DASHBOARD_TRAFFIC:n,CONTEXT_MAIN_DASHBOARD_CONTENT:o,CONTEXT_MAIN_DASHBOARD_SPEED:r,CONTEXT_MAIN_DASHBOARD_MONETIZATION:a,CONTEXT_ENTITY_DASHBOARD_TRAFFIC:l,CONTEXT_ENTITY_DASHBOARD_CONTENT:c,CONTEXT_ENTITY_DASHBOARD_SPEED:d,CONTEXT_ENTITY_DASHBOARD_MONETIZATION:u}},45472:(e,t,i)=>{i.d(t,{M:()=>s});const s="core/location"},45512:(e,t,i)=>{i.d(t,{f:()=>n,n:()=>s});const s="modules/search-console",n=1},47121:(e,t,i)=>{i.d(t,{$C:()=>b,RF:()=>S,WI:()=>j,_5:()=>x,jU:()=>k,o3:()=>_,x0:()=>A});var s=i(32091),n=i.n(s),o=i(50532),r=i.n(o),a=i(17243),l=i(78913);const c="GET_REGISTRY",d="AWAIT";function u(...e){const t=e.reduce((e,t)=>({...e,...t}),{}),i=I(e.reduce((e,t)=>[...e,...Object.keys(t)],[]));return n()(0===i.length,`collect() cannot accept collections with duplicate keys. Your call to collect() contains the following duplicated functions: ${i.join(", ")}. Check your data stores for duplicates.`),t}const g=u,p=u;function m(...e){const t=[...e];let i;return"function"!=typeof t[0]&&(i=t.shift()),(e=i,s={})=>t.reduce((e,t)=>t(e,s),e)}const h=u,f=u,y=u;function v(e){return e}function _(...e){const t=y(...e.map(e=>e.initialState||{}));return{initialState:t,controls:p(...e.map(e=>e.controls||{})),actions:g(...e.map(e=>e.actions||{})),reducer:m(t,...e.map(e=>e.reducer||v)),resolvers:h(...e.map(e=>e.resolvers||{})),selectors:f(...e.map(e=>e.selectors||{}))}}const k={getRegistry:()=>({payload:{},type:c}),*await(e){return{payload:{value:e},type:d}}},x={[c]:(0,l.b)(e=>()=>e),[d]:({payload:e})=>e.value};function I(e){const t=[],i={};for(let s=0;s<e.length;s++){const n=e[s];i[n]=i[n]>=1?i[n]+1:1,i[n]>1&&t.push(n)}return t}const A={actions:k,controls:x,reducer:v};function j(e){return t=>M(e(t))}const M=r()(e=>(0,a.mapValues)(e,(e,t)=>(...i)=>{const s=e(...i);return n()(void 0!==s,`${t}(...) is not resolved`),s}));function S(e,{negate:t=!1}={}){return{safeSelector:(0,l.N)(i=>(s,...n)=>{const o=!t,r=!!t;try{return e(i,s,...n),o}catch{return r}}),dangerousSelector:(0,l.N)(t=>(i,...s)=>{e(t,i,...s)})}}function b(e,t){return n()("function"==typeof e,"a validator function is required."),n()("function"==typeof t,"an action creator function is required."),n()("Generator"!==e[Symbol.toStringTag]&&"GeneratorFunction"!==e[Symbol.toStringTag],"an action’s validator function must not be a generator."),(...i)=>(e(...i),t(...i))}},47345:(e,t,i)=>{i.d(t,{A:()=>r});var s=i(63696),n=i(50539),o=i(86134);function r(e,t,i){const{setWidgetState:r,unsetWidgetState:a}=(0,n.useDispatch)(o.aO);(0,s.useEffect)(()=>(r(e,t,i),()=>{a(e,t,i)}),[e,t,i,r,a])}},49383:e=>{e.exports=googlesitekit.components},49655:(e,t,i)=>{i.d(t,{Q:()=>s});const s={NEW:"new",SUCCESS:"success",WARNING:"warning",INFO:"info",INFO_ALT:"info-alt",ERROR:"error"}},50111:(e,t,i)=>{i.d(t,{EA:()=>o,GF:()=>y,Hl:()=>u,IX:()=>m,Is:()=>r,KD:()=>p,LO:()=>d,NO:()=>c,Nl:()=>l,QJ:()=>g,Uf:()=>n,XU:()=>f,Y0:()=>a,hs:()=>v,wb:()=>h});var s=i(82871);const n="key-metrics-setup-cta-widget",o="googlesitekit-key-metrics-selection-panel-opened",r="key-metrics-selection-form",a="key-metrics-selected",l="key-metrics-effective-selection",c="key-metrics-unstaged-selection",d=2,u=8,g={SLUG:"current-selection",LABEL:(0,s.__)("Current selection","google-site-kit")},p={SLUG:"suggested",LABEL:(0,s.__)("Suggested","google-site-kit")},m={SLUG:"visitors",LABEL:(0,s.__)("Visitors","google-site-kit")},h={SLUG:"driving-traffic",LABEL:(0,s.__)("Driving traffic","google-site-kit")},f={SLUG:"generating-leads",LABEL:(0,s.__)("Generating leads","google-site-kit")},y={SLUG:"selling-products",LABEL:(0,s.__)("Selling products","google-site-kit")},v={SLUG:"content-performance",LABEL:(0,s.__)("Content performance","google-site-kit")}},50234:(e,t,i)=>{i.d(t,{A:()=>u});var s=i(50539),n=i(37226),o=i(58116),r=i(50111),a=i(72455),l=i(99897),c=i(45512),d=i(97398);function u(){return(0,s.useSelect)(e=>{const t=e(o.oR).isItemDismissed(r.Uf),i=e(o.oR).isDismissingItem(r.Uf),s=g(e,d.Y,c.n),n=g(e,l.L1,a.K9);return!1===t&&!1===i&&s&&n},[])}function g(e,t,i){if(e(n.i).isModuleConnected(t)){const{isGatheringData:t,isDataAvailableOnLoad:s}=e(i);return t(),s()}return!1}},50539:e=>{e.exports=googlesitekit.data},50787:(e,t,i)=>{i.d(t,{d:()=>r});var s=i(18117),n=i(17243),o=i(63696);function r(...e){const t=(0,s.MA)(()=>(0,n.debounce)(...e),e);return(0,o.useEffect)(()=>()=>t.cancel(),[t]),t}},53137:(e,t,i)=>{i.d(t,{FQ:()=>o,He:()=>a,bI:()=>r,rq:()=>n,ui:()=>s});const s="warning-notification-gtg",n="gtg-setup-cta",o={ERROR_HIGH:30,ERROR_LOW:60,WARNING:100,INFO:150,SETUP_CTA_HIGH:150,SETUP_CTA_LOW:200},r={HEADER:"notification-area-header",DASHBOARD_TOP:"notification-area-dashboard-top",OVERLAYS:"notification-area-overlays"},a={DEFAULT:"default",SETUP_CTAS:"setup-ctas"}},54312:(e,t,i)=>{i.d(t,{A:()=>GenericErrorHandlerActions});var s=i(62688),n=i.n(s),o=i(82871),r=i(20898),a=i(38021),l=i.n(a),c=i(63696),d=i(12417),u=i(1027),g=i(65123),p=i(49383),m=i(62540);function ReportErrorButton({message:e,componentStack:t}){const[i,s]=(0,c.useState)(!1);return(0,m.jsx)(p.Button,{"aria-label":i?(0,o.__)("Error message copied to clipboard. Click to copy the error message again.","google-site-kit"):void 0,onClick:function(){l()(`\`\`\`\n${e}\n${t}\n\`\`\``),s(!0)},trailingIcon:(0,m.jsx)(d.A,{className:"mdc-button__icon",icon:i?u.A:g.A}),children:i?(0,o.__)("Copied to clipboard","google-site-kit"):(0,o.__)("Copy error contents","google-site-kit")})}ReportErrorButton.propTypes={message:n().string,componentStack:n().string};const h=ReportErrorButton;function GenericErrorHandlerActions({message:e,componentStack:t}){return(0,m.jsxs)("div",{className:"googlesitekit-generic-error-handler-actions",children:[(0,m.jsx)(h,{message:e,componentStack:t}),(0,m.jsx)(r.A,{href:"https://wordpress.org/support/plugin/google-site-kit/",external:!0,children:(0,o.__)("Report this problem","google-site-kit")})]})}GenericErrorHandlerActions.propTypes={message:n().string,componentStack:n().string}},54349:(e,t,i)=>{i.d(t,{A:()=>NoticeNotification});var s=i(80035),n=i(7070),o=i(50539),r=i(71423),a=i(55527),l=i(62688),c=i.n(l),d=i(62540);function NoticeNotification({notificationID:e,children:t,dismissButton:i,ctaButton:l,gaTrackingEventArgs:c,...u}){const g=(0,n.A)(e),{dismissNotification:p}=(0,o.useDispatch)(r.D);return(0,d.jsx)(a.xA,{children:(0,d.jsx)(a.fI,{children:(0,d.jsx)(a.fh,{size:12,alignMiddle:!0,children:(0,d.jsx)(s.A,{dismissButton:{...i,onClick:async function(t){await(i?.onClick?.(t)),g.dismiss(c?.label,c?.value),p(e,{...i?.dismissOptions||{}})}},ctaButton:{...l,onClick:async function(t){g.confirm(c?.label,c?.value),await(l?.onClick?.(t)),l?.dismissOnClick&&p(e,{...l?.dismissOptions})}},...u,children:t})})})})}NoticeNotification.propTypes={notificationID:c().string.isRequired,children:c().node,dismissButton:c().oneOfType([c().bool,c().object]),ctaButton:c().object,gaTrackingEventArgs:c().object}},54419:e=>{e.exports=googlesitekit.api},54593:(e,t,i)=>{i.d(t,{A:()=>ChipTabGroup});var s=i(63696),n=i(81276),o=i(50539),r=i(50111),a=i(78340),l=i(72455),c=i(99897),d=i(7081),u=i(58116),g=i(37226),p=i(32947),m=i(27333);var h=i(31589),f=i(50787);var y=i(62688),v=i.n(y),_=i(49383),k=i(4452),x=i.n(k),I=i(80452),A=i(42343),j=i(81520),M=i(62540);const S={[r.QJ.SLUG]:I.A,[r.KD.SLUG]:A.A};function Chip({slug:e,label:t,isActive:i,onClick:s,hasNewBadge:n=!1,selectedCount:o=0}){const r=S[e]||j.A;return(0,M.jsxs)(_.Button,{className:x()("googlesitekit-chip-tab-group__chip-item",{"googlesitekit-chip-tab-group__chip-item--active":i}),icon:(0,M.jsx)(r,{width:12,height:12,className:`googlesitekit-chip-tab-group__chip-item-svg googlesitekit-chip-tab-group__chip-item-svg__${e}`}),trailingIcon:o>0?(0,M.jsxs)("span",{className:"googlesitekit-chip-tab-group__chip-item-count",children:["(",o,")"]}):null,onClick:()=>s(e),children:[t,n&&(0,M.jsx)("span",{className:"googlesitekit-chip-tab-group__chip-item-new-dot"})]})}Chip.propTypes={slug:v().string.isRequired,label:v().string.isRequired,isActive:v().bool,hasNewBadge:v().bool,selectedCount:v().number,onClick:v().func.isRequired};const b={[r.QJ.SLUG]:I.A,[r.KD.SLUG]:A.A};function TabItems({containerRef:e,isMobileBreakpoint:t,chipItemRows:i,allGroups:s,isActive:n,onChipChange:o,selectedCounts:r,newlyDetectedMetrics:a,activeGroupIndex:l}){return(0,M.jsxs)("div",{className:"googlesitekit-chip-tab-group__tab-items",ref:e,children:[!t&&i.map(e=>(0,M.jsx)("div",{className:"googlesitekit-chip-tab-group__tab-items-row",children:e.map(e=>(0,M.jsx)(Chip,{slug:e.SLUG,label:e.LABEL,hasNewBadge:!!a?.[e.SLUG],isActive:e.SLUG===n,onClick:o,selectedCount:r[e.SLUG]},e.SLUG))},`row-${e[0].SLUG}`)),t&&(0,M.jsx)(_.TabBar,{activeIndex:l,handleActiveIndexUpdate:e=>o(null,e),children:s.map((e,t)=>{const i=b[e.SLUG]||j.A;return(0,M.jsxs)(_.Tab,{"aria-label":e.LABEL,children:[(0,M.jsx)(i,{width:12,height:12,className:`googlesitekit-chip-tab-group__chip-item-svg googlesitekit-chip-tab-group__tab-item-mobile-svg googlesitekit-chip-tab-group__chip-item-svg__${e.SLUG}`}),e.LABEL,r[e.SLUG]>0&&(0,M.jsxs)("span",{className:"googlesitekit-chip-tab-group__chip-item-count",children:["(",r[e.SLUG],")"]}),!!a?.[e.SLUG]&&(0,M.jsx)("span",{className:"googlesitekit-chip-tab-group__chip-item-new-dot"})]},t)})})]})}TabItems.propTypes={containerRef:v().object,isMobileBreakpoint:v().bool,chipItemRows:v().array.isRequired,allGroups:v().array.isRequired,isActive:v().string.isRequired,onChipChange:v().func.isRequired,selectedCounts:v().object.isRequired,newlyDetectedMetrics:v().object.isRequired,activeGroupIndex:v().number.isRequired};var N,E,w,C,T,D,R,O,z,L,B,P,G,U,V,F,W,H,Y,Z,Q,q,K=i(82871),X=i(86134),$=i(718);function MetricItem({slug:e,title:t,description:i,isNewlyDetected:n,savedItemSlugs:l=[]}){const c=(0,o.useSelect)(t=>{const{getModule:i}=t(g.i),s=t(X.aO).getWidget(e);return s?.modules.reduce((e,t)=>{const s=i(t);return s?.connected||!s?.name?e:[...e,s.name]},[])}),d=(0,m.A)(r.Is,r.Y0),{getValue:u}=(0,o.useSelect)(e=>e(a.s)),{setValues:p}=(0,o.useDispatch)(a.s),h=(0,s.useCallback)(t=>{const i=u(r.Is,r.Y0),s=t.target.checked?i.concat([e]):i.filter(t=>t!==e);p(r.Is,{[r.Y0]:s,[r.NO]:s})},[u,p,e]),f=d?.includes(e),y=!l.includes(e)&&c.length>0,v=`key-metric-selection-checkbox-${e}`;return(0,M.jsx)($.y3,{id:v,slug:e,title:t,description:i,isNewlyDetected:n,isItemSelected:f,isItemDisabled:y,onCheckboxChange:h,children:c.length>0&&(0,M.jsx)("div",{className:"googlesitekit-selection-panel-item-error",children:(0,K.sprintf)(/* translators: %s: module names. */ /* translators: %s: module names. */
|
||
(0,K._n)("%s is disconnected, no data to show","%s are disconnected, no data to show",c.length,"google-site-kit"),c.join((0,K.__)(" and ","google-site-kit")))})})}function J(){return J=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},J.apply(null,arguments)}MetricItem.propTypes={slug:v().string.isRequired,title:v().string.isRequired,description:v().string.isRequired,isNewlyDetected:v().bool,savedItemSlugs:v().array};const key_metrics_no_selected_items=e=>s.createElement("svg",J({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 383 238"},e),N||(N=s.createElement("path",{fill:"#B8E6CA",d:"M59.238 58.571c-2.136 20.178 4.272 29.099 20.48 53.216 16.209 24.118-29.092 62.914 5.475 101.268 33.827 37.532 69.419.009 111.314-4.555 29.443-3.208 57.819 12.98 90.86 5.9s46.385-42.599 43.153-68.059c-5.59-44.041-26.24-49.107-34.893-66.461s2.902-52.997-30.287-73.16-76.71 14.42-112.503 12.37c-20.651-1.182-40.932-4.995-59.264.86-18.53 5.918-32.662 22.571-34.335 38.621"})),E||(E=s.createElement("g",{filter:"url(#key-metrics-no-selected-items_svg__a)"},s.createElement("rect",{width:130.621,height:89.651,x:242.455,y:45.266,fill:"#fff",rx:10.957,transform:"rotate(15 242.455 45.266)"}))),w||(w=s.createElement("rect",{width:24.903,height:7.969,x:253.726,y:64.785,fill:"#EBEEF0",rx:3.985,transform:"rotate(15 253.726 64.785)"})),C||(C=s.createElement("rect",{width:49.806,height:19.923,x:249.342,y:81.144,fill:"#FFDED3",rx:9.961,transform:"rotate(15 249.342 81.144)"})),T||(T=s.createElement("rect",{width:99.428,height:8.773,x:240.436,y:114.357,fill:"#EBEEF0",rx:3.985,transform:"rotate(15 240.436 114.357)"})),D||(D=s.createElement("path",{stroke:"#fff",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.494,d:"m256.195 90.198 4.644 8.044m0 0 1.412-4.986m-1.412 4.986-5.023-1.27"})),R||(R=s.createElement("rect",{width:19.923,height:5.977,x:268.706,y:93.551,fill:"#fff",rx:1.992,transform:"rotate(15 268.706 93.55)"})),O||(O=s.createElement("g",{filter:"url(#key-metrics-no-selected-items_svg__b)"},s.createElement("rect",{width:130.621,height:89.68,x:13.887,y:79.094,fill:"#fff",rx:10.957,transform:"rotate(-15 13.887 79.094)"}))),z||(z=s.createElement("rect",{width:62.386,height:7.798,x:32.989,y:90.122,fill:"#EBEEF0",rx:3.899,transform:"rotate(-15 32.99 90.122)"})),L||(L=s.createElement("rect",{width:49.806,height:19.923,x:37.691,y:106.902,fill:"#FFDED3",rx:9.961,transform:"rotate(-15 37.691 106.902)"})),B||(B=s.createElement("rect",{width:99.428,height:7.798,x:46.612,y:140.967,fill:"#EBEEF0",rx:3.899,transform:"rotate(-15 46.612 140.967)"})),P||(P=s.createElement("path",{stroke:"#fff",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.494,d:"m48.152 111.318 8.044 4.645m0 0-1.27-5.024m1.27 5.024-4.986 1.411"})),G||(G=s.createElement("rect",{width:19.923,height:5.977,x:60.663,y:107.966,fill:"#fff",rx:1.992,transform:"rotate(-15 60.663 107.966)"})),U||(U=s.createElement("g",{filter:"url(#key-metrics-no-selected-items_svg__c)"},s.createElement("rect",{width:130.621,height:89.68,x:126.251,y:37.4,fill:"#fff",rx:10.957}))),V||(V=s.createElement("rect",{width:98.333,height:7.867,x:143.013,y:53.134,fill:"#EBEEF0",rx:3.933})),F||(F=s.createElement("rect",{width:49.806,height:19.923,x:142.369,y:70.423,fill:"#B8E6CA",rx:9.961})),W||(W=s.createElement("rect",{width:33.04,height:7.867,x:143.013,y:105.84,fill:"#EBEEF0",rx:3.933})),H||(H=s.createElement("path",{stroke:"#fff",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.494,d:"m151.336 84.036 6.568-6.567m0 0-5.182-.073m5.182.073.073 5.18"})),Y||(Y=s.createElement("rect",{width:19.923,height:5.977,x:164.287,y:77.395,fill:"#fff",rx:1.992})),s.createElement("mask",{id:"key-metrics-no-selected-items_svg__d",width:273,height:230,x:58,y:0,maskUnits:"userSpaceOnUse",style:{maskType:"alpha"}},Z||(Z=s.createElement("path",{fill:"#B8E6CA",d:"M59.237 58.571C57.1 78.75 63.509 87.67 79.717 111.787c16.209 24.118-29.091 62.914 5.475 101.268 33.827 37.532 69.419.009 111.314-4.555 29.444-3.208 57.82 12.98 90.86 5.9s46.385-42.599 43.153-68.059c-5.59-44.041-26.24-49.107-34.893-66.461s2.902-52.997-30.287-73.16-76.71 14.42-112.503 12.37c-20.651-1.182-40.932-4.995-59.264.86C75.042 25.868 60.91 42.52 59.237 58.57"}))),Q||(Q=s.createElement("g",{mask:"url(#key-metrics-no-selected-items_svg__d)"},s.createElement("path",{stroke:"#CBD0D3",strokeMiterlimit:10,strokeWidth:3.147,d:"m227.674 108.973 11.312-8.418M218.925 98.852l2.868-12.68M205.623 102.87l-5.375-13.037"}),s.createElement("path",{stroke:"#3C7251",strokeLinejoin:"round",strokeWidth:9.44,d:"M63.953 190.487c16.127 12.193 38.716 10.349 55.335 5.162 16.618-5.187 31.107-14.61 45.314-23.791 6.717-4.337 13.617-8.738 21.496-11.119s17.057-2.39 22.958 1.658c3.392 2.328 5.205 5.923 5.36 9.702"}),s.createElement("path",{stroke:"#CBD0D3",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:9.44,d:"m215.831 109.67-19.169 71.73"}),s.createElement("path",{stroke:"#161B18",strokeMiterlimit:10,strokeWidth:9.44,d:"m213.975 116.472-19.169 71.731"}))),q||(q=s.createElement("defs",null,s.createElement("filter",{id:"key-metrics-no-selected-items_svg__a",width:176.33,height:147.36,x:205.773,y:35.772,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},s.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),s.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"}),s.createElement("feOffset",{dy:3.985}),s.createElement("feGaussianBlur",{stdDeviation:7.969}),s.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),s.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),s.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_2200_11981"}),s.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2200_11981",result:"shape"})),s.createElement("filter",{id:"key-metrics-no-selected-items_svg__b",width:176.337,height:147.388,x:.409,y:35.793,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},s.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),s.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"}),s.createElement("feOffset",{dy:3.985}),s.createElement("feGaussianBlur",{stdDeviation:7.969}),s.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),s.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),s.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_2200_11981"}),s.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2200_11981",result:"shape"})),s.createElement("filter",{id:"key-metrics-no-selected-items_svg__c",width:162.497,height:121.556,x:110.313,y:25.447,colorInterpolationFilters:"sRGB",filterUnits:"userSpaceOnUse"},s.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),s.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"}),s.createElement("feOffset",{dy:3.985}),s.createElement("feGaussianBlur",{stdDeviation:7.969}),s.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),s.createElement("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.15 0"}),s.createElement("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_2200_11981"}),s.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2200_11981",result:"shape"})))));var ee=i(59323);function TabContent({activeMetricItems:e,newlyDetectedMetrics:t,savedItemSlugs:i}){return(0,M.jsxs)("div",{className:"googlesitekit-chip-tab-group__tab-item",children:[Object.keys(e).map(s=>{const n=e[s].group,o=t?.[n]?.includes(s);return(0,M.jsx)(MetricItem,{slug:s,savedItemSlugs:i,isNewlyDetected:o,...e[s]},s)}),!Object.keys(e).length&&(0,M.jsxs)("div",{className:"googlesitekit-chip-tab-group__graphic",children:[(0,M.jsx)(key_metrics_no_selected_items,{height:250}),(0,M.jsx)(ee.A,{children:(0,K.__)("No metrics were selected yet","google-site-kit")})]})]})}TabContent.propTypes={activeMetricItems:v().object.isRequired,newlyDetectedMetrics:v().object.isRequired,savedItemSlugs:v().array};const te=Object.freeze([]);function ChipTabGroup({allMetricItems:e,savedItemSlugs:t}){const i=(0,s.useRef)(),[y,v]=(0,s.useState)(r.QJ.SLUG),[_,k]=(0,s.useState)(0),x=(0,p.dv)()===p.mp,I=(0,m.A)(r.Is,r.Y0),A=(0,m.A)(r.Is,r.Nl)||te,j=(0,m.A)(r.Is,r.NO)||te,S=(0,o.useSelect)(e=>e(u.oR).isUserInputCompleted()),b=(0,o.useSelect)(e=>{const t=e(u.oR).getUserPickedMetrics();if(t?.length){const i=e(l.K9).getKeyMetricsConversionEventWidgets();return Object.keys(i).filter(e=>t.some(t=>i[e].includes(t)))}const i=e(u.oR).getUserInputSettings();return i?.includeConversionEvents?.values}),N=(0,o.useSelect)(e=>e(g.i).isModuleConnected(c.L1)),E=(0,o.useSelect)(e=>N?e(l.K9).getDetectedEvents():[]),w=(0,o.useSelect)(e=>e(u.oR).getAnswerBasedMetrics(null,[...b||[],...E||[]])),{keyMetricsGroups:C,dynamicGroups:T}=function({detectedEvents:e=[],currentlyActiveEvents:t=[],isUserInputCompleted:i,answerBasedMetrics:n=[]}){const o=[l.nc.SUBMIT_LEAD_FORM,l.nc.CONTACT,l.nc.GENERATE_LEAD].filter(i=>e?.includes(i)||t?.includes(i)),a=[l.nc.ADD_TO_CART,l.nc.PURCHASE].filter(i=>e?.includes(i)||t?.includes(i)),c=(0,s.useMemo)(()=>[r.IX,r.wb,...o?.length?[r.XU]:[],...a?.length?[r.GF]:[],r.hs],[o,a]),d=(0,s.useMemo)(()=>i&&n?.length?[r.QJ,r.KD]:[r.QJ],[i,n]);return{hasGeneratingLeadsGroup:o,hasSellingProductsGroup:a,keyMetricsGroups:c,dynamicGroups:d}}({detectedEvents:E,currentlyActiveEvents:b,isUserInputCompleted:S,answerBasedMetrics:w}),D=(0,s.useMemo)(()=>[...T,...C],[T,C]),R=(0,o.useSelect)(e=>{if(!e(g.i).isModuleConnected(c.L1))return[];const t=e(l.K9).getDetectedEvents(),i=e(l.K9).getNewBadgeEvents();if(t?.length&&i?.length){const e=t.filter(e=>l.fV.includes(e)),s=i.filter(e=>l.fV.includes(e)),n=i.filter(e=>!l.fV.includes(e));if(e?.length>1&&s.length>0)return n}return i}),O=(0,o.useSelect)(e=>N?e(l.K9).getKeyMetricsConversionEventWidgets():[]),{selectedCounts:z,activeMetricItems:L,newlyDetectedMetrics:B}=function({allMetricItems:e={},isActive:t,effectiveSelection:i=[],answerBasedMetrics:n=[],selectedMetrics:o=[],newBadgeEvents:a=[],conversionReportingEventWidgets:l={}}){return(0,s.useMemo)(()=>{const s={[r.QJ.SLUG]:0},c={},d={};for(const g in e){const p=e[g].group;if((p===t||t===r.QJ.SLUG&&i.includes(g))&&(c[g]=e[g]),t===r.KD.SLUG&&n.includes(g)&&n.includes(g)&&(c[g]=e[g]),!s[p]){const t=Object.keys(e).filter(t=>!(e[t].group!==p||!o?.includes(t))).length;s[p]=t}var u;if(a?.length)a.some(e=>l[e].includes(g))&&(d[p]=[...null!==(u=d[p])&&void 0!==u?u:[],g])}return{selectedCounts:s,activeMetricItems:c,newlyDetectedMetrics:d}},[e,t,i,n,o,a,l])}({allMetricItems:e,isActive:y,effectiveSelection:A,answerBasedMetrics:w,selectedMetrics:I,newBadgeEvents:R,conversionReportingEventWidgets:O}),{setValues:P}=(0,o.useDispatch)(a.s),G=(0,s.useCallback)(()=>{P(r.Is,{[r.Y0]:I,[r.Nl]:[...A,...j],[r.NO]:[]})},[I,A,j,P]),U=(0,s.useCallback)((e,t)=>{if(e)v(e);else{const e=D[t];k(t),v(e.SLUG)}j.length&&G()},[D,j,v,G]),V=(0,o.useSelect)(e=>e(d.n).getValue(r.EA)),F=(0,n.A)(V),W=Object.keys(B);(0,s.useEffect)(()=>{if(!F&&V)if(v(r.QJ.SLUG),k(0),W.length&&x){const e=D.find(e=>e.SLUG===W[0]);k(D.indexOf(e)),v(e.SLUG)}else k(0),v(r.QJ.SLUG);F&&!V&&G()},[V,F,j,D,x,W,G]),function({containerRef:e,isMobileBreakpoint:t,isSelectionPanelOpen:i,isSelectionPanelOpenPrevious:n}){const o=(0,s.useCallback)(()=>{const i=e.current?.querySelector(".mdc-tab-scroller__scroll-content");if(!t)return;const s=e.current?.querySelectorAll(".googlesitekit-chip-tab-group__tab-items .mdc-tab");if(!s?.length||!i)return;const n=e.current?.getBoundingClientRect(),r=[];s.forEach((e,t)=>{const i=e.getBoundingClientRect();i.left>=n.left&&i.right<=n.right&&r.push(t)});const a=s[r.length];if(!a)return;const l=a.getBoundingClientRect();(l.left>=n.right||l.left-n.right<0&&-(l.left-n.right)<=20)&&("2px"===i.style.columnGap?i.style.columnGap="20px":i.style.columnGap="2px",o())},[e,t]),r=(0,f.d)(o,50);(0,h.A)("resize",r),(0,s.useEffect)(()=>{!n&&i&&o()},[i,n,o])}({containerRef:i,isMobileBreakpoint:x,isSelectionPanelOpen:V,isSelectionPanelOpenPrevious:F});const H=[[...T,...C.slice(0,2)],[...C.slice(2)]];return(0,M.jsxs)("div",{className:"googlesitekit-chip-tab-group",children:[(0,M.jsx)(TabItems,{containerRef:i,isMobileBreakpoint:x,chipItemRows:H,allGroups:D,isActive:y,onChipChange:U,selectedCounts:z,newlyDetectedMetrics:B,activeGroupIndex:_}),(0,M.jsx)(TabContent,{activeMetricItems:L,newlyDetectedMetrics:B,savedItemSlugs:t})]})}},55527:(e,t,i)=>{i.d(t,{$z:()=>n.$,CR:()=>a.C,Cf:()=>l.DialogContent,Es:()=>l.DialogFooter,Nv:()=>s.N,P3:()=>r.P,Si:()=>o.S,fI:()=>d.fI,fh:()=>d.fh,lG:()=>c.a,xA:()=>d.xA});var s=i(91046),n=i(3412),o=i(30454),r=i(26569),a=i(56655),l=i(12786),c=i.n(l),d=i(75487)},58116:(e,t,i)=>{i.d(t,{$8:()=>r,$Q:()=>p,BT:()=>D,CQ:()=>S,DF:()=>Y,GM:()=>M,GT:()=>v,HA:()=>L,HD:()=>g,HP:()=>T,J5:()=>P,JF:()=>N,JK:()=>f,Ml:()=>h,SS:()=>R,UF:()=>d,UY:()=>F,Vl:()=>O,W6:()=>H,Xq:()=>b,YQ:()=>E,Yw:()=>V,dV:()=>C,dX:()=>j,ej:()=>c,em:()=>o,ep:()=>I,fu:()=>k,gC:()=>_,hz:()=>m,jx:()=>u,lV:()=>l,nH:()=>B,oR:()=>s,od:()=>a,p3:()=>y,pG:()=>A,qv:()=>n,qy:()=>w,t1:()=>W,t7:()=>U,tB:()=>x,tK:()=>G,u_:()=>z});const s="core/user",n="connected_url_mismatch",o="__global",r="temporary_persist_permission_error",a="adblocker_active",l=["weekly","monthly","quarterly"],c="googlesitekit_authenticate",d="googlesitekit_setup",u="googlesitekit_view_dashboard",g="googlesitekit_manage_options",p="googlesitekit_read_shared_module_data",m="googlesitekit_manage_module_sharing_options",h="googlesitekit_delegate_module_sharing_management",f="googlesitekit_update_plugins",y="kmAnalyticsAdSenseTopEarningContent",v="kmAnalyticsEngagedTrafficSource",_="kmAnalyticsLeastEngagingPages",k="kmAnalyticsNewVisitors",x="kmAnalyticsPopularAuthors",I="kmAnalyticsPopularContent",A="kmAnalyticsPopularProducts",j="kmAnalyticsReturningVisitors",M="kmAnalyticsTopCities",S="kmAnalyticsTopCitiesDrivingLeads",b="kmAnalyticsTopCitiesDrivingAddToCart",N="kmAnalyticsTopCitiesDrivingPurchases",E="kmAnalyticsTopDeviceDrivingPurchases",w="kmAnalyticsTopConvertingTrafficSource",C="kmAnalyticsTopCountries",T="kmAnalyticsTopPagesDrivingLeads",D="kmAnalyticsTopRecentTrendingPages",R="kmAnalyticsTopTrafficSource",O="kmAnalyticsTopTrafficSourceDrivingAddToCart",z="kmAnalyticsTopTrafficSourceDrivingLeads",L="kmAnalyticsTopTrafficSourceDrivingPurchases",B="kmAnalyticsPagesPerVisit",P="kmAnalyticsVisitLength",G="kmAnalyticsTopReturningVisitorPages",U="kmSearchConsolePopularKeywords",V="kmAnalyticsVisitsPerVisitor",F="kmAnalyticsMostEngagingPages",W="kmAnalyticsTopCategories",H=[y,v,_,k,x,I,A,j,W,M,S,b,N,E,w,C,D,R,O,B,P,G,V,F,W],Y=[...H,U]},59020:(e,t,i)=>{i.d(t,{A:()=>Tooltip});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(90295),l=i(63696),c=i(62540);function Tooltip({children:e,popperClassName:t,tooltipClassName:i,onOpen:s,onClose:n,...o}){const d=(0,l.useRef)(!1),u=s?()=>{d.current||(d.current=!0,s?.())}:void 0,g=s?()=>{d.current=!1,n?.()}:n;return(0,c.jsx)(a.Ay,{classes:{popper:r()("googlesitekit-tooltip-popper",t),tooltip:r()("googlesitekit-tooltip",i)},onOpen:u,onClose:g,...o,arrow:!0,children:e})}Tooltip.propTypes={children:n().node,popperClassName:n().string,tooltipClassName:n().string,onOpen:n().func,onClose:n().func}},59323:(e,t,i)=>{i.d(t,{A:()=>c});var s=i(62688),n=i.n(s),o=i(32947),r=i(15167),a=i(3714),l=i(62540);function c({type:e=a.SZ,size:t,children:i,...s}){const n=(0,o.dv)();return(0,l.jsx)(r.A,{as:"p",type:e,size:t||(n===o.mp?a.Kk:a.Yw),...s,children:i})}c.propTypes={type:n().oneOf(a.tT),size:n().oneOf(a.oJ)}},60072:(e,t,i)=>{i.d(t,{A:()=>DashboardSharingSettingsButton});var s=i(82871),n=i(63696),o=i(50539),r=i(49383),a=i(69195),l=i(77766),c=i(12850),d=i(7081),u=i(93896),g=i(72455),p=i(24288),m=i(81042),h=i(31589),f=i(78174),y=i(4452),v=i.n(y),_=i(13606),k=i(19266),x=i(12417),I=i(82218),A=i(37226),j=i(32947),M=i(14007),S=i(55527),b=i(20898),N=i(87251),E=i(62688),w=i.n(E),C=i(62540);function Notice(){const e=(0,o.useSelect)(e=>e(A.i).canSubmitSharingChanges()),t=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsExpanded("management")),i=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsExpanded("sharedRoles"));return(0,C.jsxs)("p",{className:"googlesitekit-dashboard-sharing-settings__notice",children:[t&&e&&(0,C.jsx)("span",{children:(0,_.A)((0,s.__)("By clicking <strong>Apply</strong>, you will give other authenticated admins of your site permission to manage view-only access to Site Kit dashboard data from the chosen Google service","google-site-kit"),{strong:(0,C.jsx)("strong",{})})}),!t&&e&&i&&(0,C.jsx)("span",{children:(0,_.A)((0,s.__)("By clicking <strong>Apply</strong>, you’re granting the selected roles view-only access to data from the Google services you’ve connected via your account","google-site-kit"),{strong:(0,C.jsx)("strong",{})})})]})}var T=i(77967);function Footer({closeDialog:e,openResetDialog:t}){const i=(0,l.A)(),[a,u]=(0,n.useState)(null),[g,m]=(0,n.useState)(!1),h=(0,o.useSelect)(e=>e(A.i).canSubmitSharingChanges()),f=(0,o.useSelect)(e=>e(A.i).isDoingSubmitSharingChanges()),y=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsExpanded("management")),v=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsExpanded("sharedRoles")),_=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsUpdated()),k=(0,o.useSelect)(e=>!!e(d.n).getValue(p.tm)),x=(0,o.useSelect)(e=>!!e(d.n).getValue(p.hk)),{resetSharingSettings:I,saveSharingSettings:j}=(0,o.useDispatch)(A.i),{setValue:M}=(0,o.useDispatch)(d.n),S=(0,n.useCallback)(async()=>{u(null);const{error:t}=await j();t?u(t.message):((0,c.sx)(`${i}_sharing`,"settings_confirm"),M(p.zP,void 0),e())},[i,j,M,e]),N=(0,n.useCallback)(async()=>{u(null),m(!0);const{error:t}=await I();t?u(t.message):(m(!1),e())},[e,I]),E=(0,n.useCallback)(()=>{(0,c.sx)(`${i}_sharing`,"settings_cancel"),e()},[e,i]),w=a||y||v;return(0,C.jsxs)("div",{className:"googlesitekit-dashboard-sharing-settings__footer",children:[w&&(0,C.jsxs)("div",{className:"googlesitekit-dashboard-sharing-settings__footer-notice",children:[a&&(0,C.jsx)(T.A,{message:a}),!a&&(0,C.jsx)(Notice,{})]}),(0,C.jsxs)("div",{className:"googlesitekit-dashboard-sharing-settings__footer-actions",children:[_&&k&&!w&&(0,C.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__footer-actions-left",children:(0,C.jsx)(b.A,{onClick:t,className:"googlesitekit-reset-sharing-permissions-button",danger:!0,children:(0,s.__)("Reset sharing permissions","google-site-kit")})}),(0,C.jsxs)("div",{className:"googlesitekit-dashboard-sharing-settings__footer-actions-right",children:[(0,C.jsx)(r.Button,{onClick:E,tertiary:!0,children:(0,s.__)("Cancel","google-site-kit")}),k&&(0,C.jsx)(r.SpinnerButton,{onClick:S,disabled:f||!h,isSaving:f,children:(0,s.__)("Apply","google-site-kit")}),x&&(0,C.jsx)(r.SpinnerButton,{onClick:N,disabled:g,isSaving:g,danger:!0,children:(0,s.__)("Reset","google-site-kit")})]})]})]})}Footer.propTypes={closeDialog:w().func.isRequired,openResetDialog:w().func.isRequired};var D=i(15167);function DashboardSharingDialog(){const[e,t]=(0,n.useState)(!1),i=(0,n.useRef)(void 0),l=(0,j.dv)(),{y:c}=(0,m.A)(),{setValue:g}=(0,o.useDispatch)(d.n),{rollbackSharingSettings:y}=(0,o.useDispatch)(A.i),E=(0,o.useSelect)(e=>!!e(d.n).getValue(p.tm)),w=(0,o.useSelect)(e=>!!e(d.n).getValue(p.hk)),T=(0,o.useSelect)(e=>e(d.n).getValue(p.zP)),R=(0,o.useSelect)(e=>e(A.i).haveSharingSettingsChanged()),O=(0,o.useSelect)(e=>e(u.O4).getDocumentationLinkURL("dashboard-sharing"));(0,n.useEffect)(()=>{if(e){const e=document.querySelector(".googlesitekit-reset-sharing-permissions-button");e&&e.focus(),t(!1)}},[e]);const z={};l===j.mp&&(z.top=(c<46?46-c:0)+"px",z.height=`calc(100% - 46px + ${c<46?c:46}px)`),(0,n.useEffect)(()=>{!E&&R&&y()},[E,R,y]);const L=(0,n.useCallback)(()=>{g(p.tm,!0)},[g]),B=(0,n.useCallback)(()=>{g(p.tm,!1),g(p.zP,void 0)},[g]),P=(0,n.useCallback)(()=>{B(),g(p.hk,!0)},[B,g]),G=(0,n.useCallback)(()=>{g(p.hk,!1),L(),t(!0)},[L,g]),U=(0,n.useCallback)(()=>{w?G():B()},[G,B,w]),V=(0,n.useCallback)(e=>{w&&e.target.classList.contains("mdc-dialog__scrim")&&G()},[w,G]);return(0,h.A)("click",V),(0,f.A)(e=>w&&k._f===e.keyCode,G),(0,C.jsx)(M.A,{children:(0,C.jsxs)(S.lG,{open:E||w,onClose:U,className:"googlesitekit-dialog googlesitekit-sharing-settings-dialog",style:z,escapeKeyAction:void 0!==T||w?"":"close",scrimClickAction:void 0!==T||w?"":"close",children:[(0,C.jsx)("div",{className:"googlesitekit-dialog__back-wrapper","aria-hidden":l!==j.mp,ref:i,children:(0,C.jsx)(r.Button,{"aria-label":(0,s.__)("Back","google-site-kit"),className:"googlesitekit-dialog__back",onClick:U,children:(0,C.jsx)(x.A,{icon:I.A})})}),(0,C.jsxs)(S.Cf,{className:"googlesitekit-dialog__content",children:[(0,C.jsxs)("div",{className:"googlesitekit-dialog__header",children:[E&&(0,C.jsx)("div",{className:"googlesitekit-dialog__header-icon","aria-hidden":l===j.mp,children:(0,C.jsx)("span",{children:(0,C.jsx)(a.A,{width:20,height:20})})}),(0,C.jsxs)("div",{className:"googlesitekit-dialog__header-titles",children:[(0,C.jsxs)(D.A,{as:"h2",className:"googlesitekit-dialog__title",size:"medium",type:"headline",children:[E&&(0,C.jsx)("span",{children:(0,s.__)("Dashboard sharing & permissions","google-site-kit")}),w&&(0,C.jsx)("span",{children:(0,s.__)("Reset dashboard sharing permissions","google-site-kit")})]}),(0,C.jsxs)("p",{className:v()("googlesitekit-dialog__subtitle",{"googlesitekit-dialog__subtitle--emphasis":w}),children:[E&&(0,C.jsx)("span",{children:(0,_.A)((0,s.__)("Share a view-only version of your Site Kit dashboard with other WordPress roles. <a>Learn more</a>","google-site-kit"),{a:(0,C.jsx)(b.A,{"aria-label":(0,s.__)("Learn more about dashboard sharing","google-site-kit"),href:O,external:!0})})}),w&&(0,C.jsx)("span",{children:(0,s.__)("Warning: Resetting these permissions will remove view-only access for all users. Are you sure you want to reset all dashboard sharing permissions?","google-site-kit")})]})]})]}),E&&(0,C.jsx)("div",{className:"googlesitekit-dialog__main",children:(0,C.jsx)(N.A,{})})]}),(0,C.jsx)(S.Es,{className:"googlesitekit-dialog__footer",children:(0,C.jsx)(Footer,{closeDialog:U,openResetDialog:P})})]})})}var R=i(27333);function DashboardSharingSettingsButton(){const e=(0,l.A)(),{setValue:t}=(0,o.useDispatch)(d.n),i=(0,o.useSelect)(e=>e(u.O4).hasMultipleAdmins()),m=(0,R.A)(g.CV,"isAutoCreatingCustomDimensionsForAudience"),h=(0,n.useCallback)(()=>{(0,c.sx)(`${e}_headerbar`,"open_sharing",i?"advanced":"simple"),t(p.tm,!0)},[t,e,i]);return(0,C.jsxs)(n.Fragment,{children:[(0,C.jsx)(r.Button,{"aria-label":(0,s.__)("Open sharing settings","google-site-kit"),className:"googlesitekit-sharing-settings__button googlesitekit-header__dropdown googlesitekit-border-radius-round googlesitekit-button-icon",onClick:h,icon:(0,C.jsx)(a.A,{width:20,height:20}),tooltipEnterDelayInMS:500,disabled:m}),(0,C.jsx)(DashboardSharingDialog,{})]})}},60592:(e,t,i)=>{i.d(t,{A:()=>TourTooltip});var s=i(28056),n=i.n(s),o=i(4452),r=i.n(o),a=i(62688),l=i.n(a),c=i(82871),d=i(49383);var u=i(72545),g=i(15167),p=i(62540);function TourTooltip({backProps:e,closeProps:t,index:i,primaryProps:o,size:a,step:l,tooltipProps:m}){const h=a>1?function(e){return new Array(null!=e?e:0).fill().map((e,t)=>t)}(a):[];function f(e){return r()("googlesitekit-tooltip-indicator",{active:e===i})}return(0,p.jsx)("div",{className:r()("googlesitekit-tour-tooltip",l.className),...m,children:(0,p.jsxs)(n(),{className:"googlesitekit-tooltip-card",children:[(0,p.jsxs)("div",{className:"googlesitekit-tooltip-body",children:[(0,p.jsx)(g.A,{as:"h2",className:"googlesitekit-tooltip-title",size:"medium",type:"title",children:l.title}),(0,p.jsx)("div",{className:"googlesitekit-tooltip-content",children:l.content})]}),(0,p.jsxs)(s.CardActions,{className:"googlesitekit-tooltip-actions",children:[(0,p.jsx)("ul",{className:"googlesitekit-tooltip-indicators",children:h.map(e=>(0,p.jsx)("li",{className:f(e)},`indicator-${e}`))}),(0,p.jsxs)("div",{className:"googlesitekit-tooltip-buttons",children:[0!==i&&(0,p.jsx)(d.Button,{className:"googlesitekit-tooltip-button",text:!0,...e,children:e.title}),l.cta,o.title&&(0,p.jsx)(d.Button,{className:"googlesitekit-tooltip-button",text:!0,...o,children:o.title})]})]}),(0,p.jsx)(d.Button,{className:"googlesitekit-tooltip-close",icon:(0,p.jsx)(u.A,{width:"14",height:"14"}),onClick:t.onClick,"aria-label":(0,c.__)("Close","google-site-kit"),text:!0,hideTooltipTitle:!0})]})})}TourTooltip.propTypes={backProps:l().object.isRequired,closeProps:l().object.isRequired,index:l().number.isRequired,isLastStep:l().bool.isRequired,primaryProps:l().object.isRequired,size:l().number.isRequired,step:l().shape({content:l().node,title:l().node,cta:l().oneOfType([l().element,l().bool]),className:l().string}).isRequired,tooltipProps:l().object.isRequired}},61046:(e,t,i)=>{i.d(t,{A:()=>l});var s=i(63560),n=i(62688),o=i.n(n),r=i(63696),a=i(62540);function l(e){function WithIntersectionObserverComponent({onInView:t,...i}){const n=(0,r.useRef)(),o=(0,s.A)(n,{root:null,threshold:.45}),[l,c]=(0,r.useState)(!1),d=!!o?.isIntersecting&&!!o?.intersectionRatio;return(0,r.useEffect)(()=>{o&&d&&!l&&(t(),c(!0))},[l,d,o,t]),(0,a.jsx)(e,{ref:n,...i})}return WithIntersectionObserverComponent.displayName="WithIntersectionObserverComponent",(e.displayName||e.name)&&(WithIntersectionObserverComponent.displayName+=`(${e.displayName||e.name})`),WithIntersectionObserverComponent.propTypes={onInView:o().func.isRequired,...e.propTypes},WithIntersectionObserverComponent}},61991:(e,t,i)=>{i.d(t,{Ay:()=>r,Kq:()=>o});const s=(0,i(63696).createContext)(""),{Consumer:n,Provider:o}=s,r=s},63972:(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",fill:"none",viewBox:"0 0 11 9"},e),s||(s=n.createElement("path",{stroke:"currentColor",strokeWidth:1.5,d:"M1 3.838 4.106 7 10 1"})))},64067:(e,t,i)=>{i.d(t,{P9:()=>y,k:()=>m,mR:()=>f});var s=i(32091),n=i.n(s),o=i(17243),r=i(50539),a=i.n(r),l=i(21134),c=i(12850);const d="CREATE_SNAPSHOT",u="DELETE_SNAPSHOT",g="RESTORE_SNAPSHOT",p="SET_STATE_FROM_SNAPSHOT";function m(e,{keysToSnapshot:t}={}){n()(e,"storeName is required to create a snapshot store.");const i={},s={*deleteSnapshot(){return yield{payload:{},type:u}},*restoreSnapshot(e={}){const{clearAfterRestore:t=!0}=e,{cacheHit:i,value:s}=yield{payload:{},type:g};return i&&(yield{payload:{snapshot:s},type:p},t&&(yield{payload:{},type:u})),i},*createSnapshot(){return yield{payload:{},type:d}}},a={[u]:()=>(0,l.LD)(`datastore::cache::${e}`),[d]:(0,r.createRegistryControl)(i=>()=>{const s=i.stores[e].store.getState(),n=t?.length>0?(0,o.pick)(s,t):s;return(0,l.SO)(`datastore::cache::${e}`,n)}),[g]:()=>(0,l.Gq)(`datastore::cache::${e}`,c.Jg)};return{initialState:i,actions:s,controls:a,reducer:function(e=i,{type:s,payload:n}){if(s===p){const{snapshot:i}=n,{error:s,...o}=i;return t?.length>0?{...e,...o}:o}return e}}}function h(e=a()){return Object.values(e.stores).filter(e=>Object.keys(e.getActions()).includes("restoreSnapshot"))}function f(e=a()){return Promise.all(h(e).map(e=>e.getActions().createSnapshot()))}function y(e=a()){return Promise.all(h(e).map(e=>e.getActions().restoreSnapshot()))}},65214:(e,t,i)=>{i.d(t,{G:()=>n,t:()=>s});const s=new Set(i.g?._googlesitekitBaseData?.enabledFeatures||[]);function n(e,t=s){return t instanceof Set&&t.has(e)}},65311:(e,t,i)=>{i.d(t,{c:()=>r});var s=i(82871),n=i(97398),o=i(99897);function r(e="",t={}){const{slug:i="",name:r="",owner:a={}}=t||{};if(!i||!r)return e;let l="",c="";return o.L1===i?e.match(/account/i)?l=(0,s.__)("Your Google account does not have sufficient permissions for this Analytics account, so you won’t be able to see stats from it on the Site Kit dashboard.","google-site-kit"):e.match(/property/i)?l=(0,s.__)("Your Google account does not have sufficient permissions for this Analytics property, so you won’t be able to see stats from it on the Site Kit dashboard.","google-site-kit"):e.match(/view/i)&&(l=(0,s.__)("Your Google account does not have sufficient permissions for this Analytics view, so you won’t be able to see stats from it on the Site Kit dashboard.","google-site-kit")):n.Y===i&&(l=(0,s.__)("Your Google account does not have sufficient permissions for this Search Console property, so you won’t be able to see stats from it on the Site Kit dashboard.","google-site-kit")),l||(l=(0,s.sprintf)(/* translators: %s: module name */ /* translators: %s: module name */
|
||
(0,s.__)("Your Google account does not have sufficient permissions to access %s data, so you won’t 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}`}},66201:(e,t,i)=>{i.d(t,{Z:()=>c});var s=i(31589),n=i(40960),o=i(42926),r=i(63696),a=i(50539),l=i(7081);function c(){const{setIsOnline:e}=(0,a.useDispatch)(l.n),t=(0,a.useSelect)(e=>e(l.n).getIsOnline()),i=(0,r.useCallback)(async()=>{if(navigator.onLine){try{await(0,o.A)({path:"/google-site-kit/v1/"})}catch(t){if("fetch_error"===t?.code)return void e(!1)}e(!0)}else e(!1)},[e]);(0,s.A)("online",i),(0,s.A)("offline",i),(0,n.A)(i,t?12e4:15e3)}},66847:(e,t,i)=>{i.d(t,{A:()=>ScrollEffect});var s=i(81042),n=i(63696);function ScrollEffect(){return function(){const{y:e}=(0,s.A)(),[t,o]=(0,n.useState)(!1),r="googlesitekit-plugin--has-scrolled";(0,n.useEffect)(()=>{t?i.g.document.body.classList.add(r):i.g.document.body.classList.remove(r)},[t]),e>0&&!t?o(!0):0===e&&t&&o(!1)}(),null}},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:()=>u,SG:()=>d,db:()=>n,e4:()=>p,vl:()=>g});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 d(e){return[o,r].includes(e?.data?.reason)}function u(e){return!!e?.data?.reconnectURL}function g(e,t){return!(!t?.storeName||d(e)||c(e)||u(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),d=i(14007),u=i(39771),g=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:y={},slug:v="",placement:_="auto",onDismiss:k=()=>{},onView:x=()=>{},onTourStart:I=()=>{},onTourEnd:A=()=>{}}=e;function j(){return!!i.g.document.querySelector(m)}const[M,S]=(0,n.useState)(j),b=(0,g.dv)(),N=b===g.mp||b===g.Lg,[E,w]=(0,n.useState)(!0),C=(0,n.useRef)(N);if((0,l.A)(()=>{j()&&S(!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!==N&&(w(!1),e=setTimeout(()=>{w(!0)},50),C.current=N),()=>{e&&clearTimeout(e)}},[N]),!M)return null;const T=[{title:t,target:m,content:s,disableBeacon:!0,isFixed:!0,placement:_,cta:h,className:f}],D={close:o,last:o};return(0,p.jsx)(d.A,{slug:v,children:(0,p.jsx)(a.Ay,{callback:function({type:e}){switch(e){case a.qY.TOUR_START:I(),i.g.document.body.classList.add("googlesitekit-showing-tooltip");break;case a.qY.TOUR_END:A(),i.g.document.body.classList.remove("googlesitekit-showing-tooltip");break;case a.qY.STEP_AFTER:k();break;case a.qY.TOOLTIP:x()}},disableOverlay:r,spotlightPadding:0,floaterProps:u.ei,locale:D,steps:T,styles:{...u.R0,...y,options:{...u.R0.options,...y?.options},spotlight:{...u.R0.spotlight,...y?.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,g.dv)(),{isTooltipVisible:s=!1,target:r,placement:a,className:l,tooltipSlug:c,title:d,content:u,dismissLabel:y}=(0,o.useSelect)(e=>e(m.n).getValue("admin-screen-tooltip")||{isTooltipVisible:!1});const v=(0,n.useCallback)(()=>{c&&(0,h.sx)(`${e}_${c}`,"tooltip_dismiss"),t("admin-screen-tooltip",void 0)},[t,c,e]);if(!s)return null;const _=i===g.mp||i===g.Lg,k=null!=r?r:'#adminmenu [href*="page=googlesitekit-settings"]',x=null!=a?a:"right";return(0,p.jsx)(JoyrideTooltip,{target:_?"body":k,placement:_?"center":x,className:_?"googlesitekit-tour-tooltip__modal_step":l||(r?void 0:"googlesitekit-tour-tooltip__fixed-settings-tooltip"),disableOverlay:!_,slug:"admin-screen-tooltip",title:d,content:u,dismissLabel:y,onView:function(){(0,h.sx)(`${e}_${c}`,"tooltip_view")},onDismiss:v})}},68869:(e,t,i)=>{i.d(t,{Ay:()=>r});var s=i(6732);const{Consumer:n,Provider:o}=s.A,r=o},69195:(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",fill:"none",viewBox:"0 0 20 20"},e),s||(s=n.createElement("path",{fill:"currentColor",d:"M16.666 7.5V5H15v2.5h-2.5v1.666H15v2.5h1.666v-2.5h2.5V7.5zM7.5 10a3.332 3.332 0 1 0 0-6.667A3.332 3.332 0 1 0 7.5 10m0-5c.916 0 1.666.75 1.666 1.666 0 .917-.75 1.667-1.666 1.667-.917 0-1.667-.75-1.667-1.667C5.833 5.75 6.583 5 7.5 5m5.325 7.133c-1.4-.717-3.217-1.3-5.325-1.3s-3.925.583-5.325 1.3A2.48 2.48 0 0 0 .833 14.35v2.316h13.333V14.35c0-.934-.508-1.792-1.341-2.217M12.5 15h-10v-.65c0-.317.166-.6.433-.734A10.1 10.1 0 0 1 7.5 12.5c1.975 0 3.575.608 4.566 1.116a.81.81 0 0 1 .434.734z"})))},71423:(e,t,i)=>{i.d(t,{$:()=>o,D:()=>n});var s=i(24558);const n="core/notifications",o=[s.uR,s.jU,s.f7,s.Ax,s.Is]},71769:(e,t,i)=>{function s(e){return e.charAt(0).toUpperCase()+e.slice(1)}function n(e){return e.replace(/([a-z0-9]{1})([A-Z]{1})/g,"$1_$2").toUpperCase()}function o(e){return e.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join("")}i.d(t,{Uf:()=>o,m2:()=>s,sP:()=>n})},72455:(e,t,i)=>{i.d(t,{CV:()=>b,Cu:()=>I,K9:()=>s,Kr:()=>h,Lf:()=>p,Oh:()=>r,PW:()=>S,Rx:()=>T,S9:()=>f,TQ:()=>u,Vt:()=>w,Wl:()=>k,ZC:()=>n,ZY:()=>a,_p:()=>C,ag:()=>m,aj:()=>g,bz:()=>N,dq:()=>E,f2:()=>c,fB:()=>M,fV:()=>j,iB:()=>d,kc:()=>l,mo:()=>v,nc:()=>A,rm:()=>x,to:()=>o,wo:()=>y,yn:()=>_});const s="modules/analytics-4",n="account_create",o="property_create",r="webdatastream_create",a="analyticsSetup",l=10,c=1,d="https://www.googleapis.com/auth/tagmanager.readonly",u="enhanced-measurement-form",g="enhanced-measurement-enabled",p="enhanced-measurement-should-dismiss-activation-banner",m="analyticsAccountCreate",h="analyticsCustomDimensionsCreate",f="https://www.googleapis.com/auth/analytics.edit",y="dashboardAllTrafficWidgetDimensionName",v="dashboardAllTrafficWidgetDimensionColor",_="dashboardAllTrafficWidgetDimensionValue",k="dashboardAllTrafficWidgetActiveRowIndex",x="dashboardAllTrafficWidgetLoaded",I={googlesitekit_post_date:{parameterName:"googlesitekit_post_date",displayName:"WordPress Post Date",description:"Created by Site Kit: Date when a post was published",scope:"EVENT"},googlesitekit_post_author:{parameterName:"googlesitekit_post_author",displayName:"WordPress Post Author",description:"Created by Site Kit: WordPress name of the post author",scope:"EVENT"},googlesitekit_post_categories:{parameterName:"googlesitekit_post_categories",displayName:"WordPress Post Categories",description:"Created by Site Kit: Names of categories assigned to a post",scope:"EVENT"},googlesitekit_post_type:{parameterName:"googlesitekit_post_type",displayName:"WordPress Post Type",description:"Created by Site Kit: Content type of a post",scope:"EVENT"}},A={ADD_TO_CART:"add_to_cart",PURCHASE:"purchase",SUBMIT_LEAD_FORM:"submit_lead_form",GENERATE_LEAD:"generate_lead",CONTACT:"contact"},j=[A.CONTACT,A.GENERATE_LEAD,A.SUBMIT_LEAD_FORM],M={"new-visitors":{description:"People who visited the site for the first time",displayName:"New visitors",membershipDurationDays:-1,filterClauses:[{clauseType:"INCLUDE",simpleFilter:{scope:"AUDIENCE_FILTER_SCOPE_ACROSS_ALL_SESSIONS",filterExpression:{andGroup:{filterExpressions:[{orGroup:{filterExpressions:[{dimensionOrMetricFilter:{fieldName:"newVsReturning",stringFilter:{matchType:"EXACT",value:"new"}}}]}},{orGroup:{filterExpressions:[{notExpression:{dimensionOrMetricFilter:{fieldName:"groupId",stringFilter:{matchType:"EXACT",value:"created_by_googlesitekit:new_visitors"}}}}]}}]}}}}]},"returning-visitors":{description:"People who have visited your site at least once before",displayName:"Returning visitors",membershipDurationDays:-1,filterClauses:[{clauseType:"INCLUDE",simpleFilter:{scope:"AUDIENCE_FILTER_SCOPE_ACROSS_ALL_SESSIONS",filterExpression:{andGroup:{filterExpressions:[{orGroup:{filterExpressions:[{dimensionOrMetricFilter:{fieldName:"newVsReturning",stringFilter:{matchType:"EXACT",value:"returning"}}}]}},{orGroup:{filterExpressions:[{notExpression:{dimensionOrMetricFilter:{fieldName:"groupId",stringFilter:{matchType:"EXACT",value:"created_by_googlesitekit:returning_visitors"}}}}]}}]}}}}]}},S="audiencePermissionsSetup",b="audienceTileCustomDimensionCreate",N="audience-selection-panel-expirable-new-badge-",E="audience",w="customDimension",C="property",T=[E,w,C]},72545:(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",fill:"none",viewBox:"0 0 14 14"},e),s||(s=n.createElement("path",{fill:"currentColor",d:"M14 1.41 12.59 0 7 5.59 1.41 0 0 1.41 5.59 7 0 12.59 1.41 14 7 8.41 12.59 14 14 12.59 8.41 7z"})))},73549:(e,t,i)=>{i.d(t,{A:()=>ReportZero});var s=i(62688),n=i.n(s),o=i(82871),r=i(50539),a=i(37226),l=i(4884),c=i(62540);function ReportZero({moduleSlug:e}){const t=(0,r.useSelect)(t=>t(a.i).getModule(e));return(0,c.jsx)(l.A,{title:(0,o.sprintf)(/* translators: %s: Module name */ /* translators: %s: Module name */
|
||
(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:()=>g.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),d=i(30043),u=i(66293),g=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=g.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=d.A,h.RegistryProvider=u.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),d=i.n(c),u=i(43569),g=i(62540);const p=d()(e=>({id:e,Notification:m(e)(u.A)}));function m(e){return t=>{function WithNotificationID(i){return(0,g.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],d={...p(n)};return(0,g.jsx)(c,{...d})}Notifications.propTypes={viewContext:n().string,areaSlug:n().string}},75487:(e,t,i)=>{i.d(t,{fh:()=>Cell,xA:()=>g,fI:()=>d});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:d,lgAlignRight:u,smSize:g,smStart:p,smOrder:m,mdSize:h,mdStart:f,mdOrder:y,lgSize:v,lgStart:_,lgOrder:k,size:x,children:I,...A}=e;return(0,a.jsx)("div",{...A,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":d,"mdc-layout-grid__cell--align-right-desktop":u,[`mdc-layout-grid__cell--span-${x}`]:12>=x&&x>0,[`mdc-layout-grid__cell--span-${v}-desktop`]:12>=v&&v>0,[`mdc-layout-grid__cell--start-${_}-desktop`]:12>=_&&_>0,[`mdc-layout-grid__cell--order-${k}-desktop`]:12>=k&&k>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-${y}-tablet`]:8>=y&&y>0,[`mdc-layout-grid__cell--span-${g}-phone`]:4>=g&&g>0,[`mdc-layout-grid__cell--start-${p}-phone`]:4>=p&&p>0,[`mdc-layout-grid__cell--order-${m}-phone`]:4>=m&&m>0}),children:I})}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 d=c,u=(0,l.forwardRef)(({alignLeft:e,fill:t,className:i,children:s,collapsed:n,...o},l)=>(0,a.jsx)("div",{className:r()("mdc-layout-grid",i,{"mdc-layout-grid--align-left":e,"mdc-layout-grid--collapsed":n,"mdc-layout-grid--fill":t}),...o,ref:l,children:s}));u.displayName="Grid",u.propTypes={alignLeft:n().bool,fill:n().bool,className:n().string,collapsed:n().bool,children:n().node},u.defaultProps={className:""};const g=u},75949:(e,t,i)=>{i.d(t,{A:()=>E});var s,n=i(15844),o=i(79257),r=i(52684),a=i(63696),l=i(82871),c=i(50539),d=i(49383),u=i(16834);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 p=e=>a.createElement("svg",g({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),s||(s=a.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M16 9.5c0 1.407-.45 2.714-1.218 3.783L20.49 19 19 20.49l-5.717-5.708A6.46 6.46 0 0 1 9.5 16 6.5 6.5 0 1 1 16 9.5m-11 0C5 11.99 7.01 14 9.5 14S14 11.99 14 9.5 11.99 5 9.5 5 5 7.01 5 9.5",clipRule:"evenodd"})));var m;function h(){return h=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},h.apply(null,arguments)}const f=e=>a.createElement("svg",h({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),m||(m=a.createElement("path",{fill:"currentColor",d:"m15.833 5.342-1.175-1.175L10 8.825 5.342 4.167 4.167 5.342 8.825 10l-4.658 4.658 1.175 1.175L10 11.175l4.658 4.658 1.175-1.175L11.175 10z"})));var y=i(62688),v=i.n(y),_=i(82351),k=i(19266),x=i(54419);var I=i(93896),A=i(62540);function j(){}function PostSearcherAutoSuggest({id:e,match:t,setMatch:i,isLoading:s,showDropdown:n=!0,setIsLoading:o=j,setIsActive:r=j,autoFocus:d,setCanSubmit:u=j,onClose:g=j,placeholder:p=""}){const m=(0,a.useRef)(),[h,f]=(0,a.useState)(""),y=t?.title,v=function(e,t){const[i,s]=(0,a.useState)(e);return(0,a.useEffect)(()=>{const i=setTimeout(()=>{s(e)},t);return()=>{clearTimeout(i)}},[e,t]),i}(h,h===y?0:200),[M,S]=(0,a.useState)([]),b=(0,l.__)("No results found","google-site-kit"),N=(0,c.useSelect)(e=>e(I.O4).getCurrentEntityTitle()),E=(0,a.useRef)(null),w=(0,a.useCallback)(()=>{r(!0)},[r]),C=(0,a.useCallback)(e=>{var t,i;e.relatedTarget?.classList.contains("autocomplete__option--result")||(r(!1),f(null!==(t=null!==(i=E.current)&&void 0!==i?i:N)&&void 0!==t?t:""))},[N,r]),T=(0,a.useCallback)(e=>{if(Array.isArray(M)&&e!==b){const t=M.find(t=>t.title.toLowerCase()===e.toLowerCase());t?(E.current=t.title,u(!0),i(t),f(t.title)):E.current=null}else E.current=null,u(!1)},[M,u,i,b,f]),D=(0,a.useCallback)(e=>{u(!1),f(e.target.value)},[u]);(0,a.useEffect)(()=>{if(""!==v&&v!==N&&v?.toLowerCase()!==y?.toLowerCase()){const e="undefined"==typeof AbortController?void 0:new AbortController;return async function(){o(!0);const t=(0,x.get)("core","search","entity-search",{query:encodeURIComponent(v)},{useCache:!1,signal:e?.signal});m.current=t;try{const e=await t;S(e)}catch{S(null)}finally{t===m.current&&o(!1)}}(),()=>e?.abort()}return()=>{}},[v,o,N,y]),(0,a.useEffect)(()=>{h||S([])},[h]),(0,a.useEffect)(()=>{N&&f(N)},[N]);const R=(0,a.useRef)(),O=(0,a.useCallback)(e=>{const t=R.current;switch(e.keyCode){case k.yZ:t?.value&&(e.preventDefault(),t.selectionStart=0,t.selectionEnd=0);break;case k.Kp:t?.value&&(e.preventDefault(),t.selectionStart=t.value.length,t.selectionEnd=t.value.length)}switch(e.keyCode){case k._f:g();break;case k.Fm:T(h)}},[g,T,h]);return(0,A.jsxs)(_.G3,{className:"autocomplete__wrapper",onSelect:T,children:[(0,A.jsx)(_.oK,{ref:R,id:e,className:"autocomplete__input autocomplete__input--default",type:"text",onBlur:C,onChange:D,onFocus:w,placeholder:p,onKeyDown:O,value:h,autoFocus:d}),!s&&n&&v!==N&&""!==v&&0===M?.length&&(0,A.jsx)(_.Nf,{portal:!1,children:(0,A.jsx)(_.ex,{className:"autocomplete__menu autocomplete__menu--inline",children:(0,A.jsx)(_.jO,{value:b,className:"autocomplete__option autocomplete__option--no-results"})})}),n&&""!==v&&v!==N&&M?.length>0&&(0,A.jsx)(_.Nf,{portal:!1,children:(0,A.jsx)(_.ex,{className:"autocomplete__menu autocomplete__menu--inline",children:M.map(({id:e,title:t})=>(0,A.jsx)(_.jO,{value:t,className:"autocomplete__option autocomplete__option--result"},e))})})]})}PostSearcherAutoSuggest.propTypes={id:v().string,match:v().object,setCanSubmit:v().func,setMatch:v().func,isLoading:v().bool,setIsLoading:v().func,onKeyDown:v().func,autoFocus:v().bool,placeholder:v().string};var M=i(45472),S=i(12850),b=i(73874),N=i(77766);const E=function EntitySearchInput(){const e=(0,r.A)(EntitySearchInput,"EntitySearchInput"),[t,i]=(0,a.useState)(!1),[s,g]=(0,a.useState)(!1),[m,h]=(0,a.useState)(!1),y=(0,N.A)(),v=(0,b.Ay)(),_=(0,a.useRef)(),k=(0,a.useCallback)(()=>{(0,S.sx)(`${y}_headerbar`,"open_urlsearch"),i(!0)},[y]),x=(0,a.useCallback)(()=>{(0,S.sx)(`${y}_headerbar`,"close_urlsearch"),i(!1)},[y]),[j,E]=(0,a.useState)({}),w=(0,c.useSelect)(e=>j?.url?e(I.O4).getAdminURL("googlesitekit-dashboard",{permaLink:j.url}):null),{navigateTo:C}=(0,c.useDispatch)(M.M);return(0,a.useEffect)(()=>{w&&(0,S.sx)(`${y}_headerbar_urlsearch`,"open_urldetails").finally(()=>{C(w)})},[w,C,y]),(0,n.A)(()=>{v===b.oE&&i(!0)}),(0,o.A)(()=>{t||_?.current?.focus()},[t]),t?(0,A.jsxs)("div",{className:"googlesitekit-entity-search googlesitekit-entity-search--is-open",children:[(0,A.jsx)(u.A,{children:(0,A.jsx)("label",{htmlFor:e,children:(0,l.__)("Page/URL Search","google-site-kit")})}),(0,A.jsx)(PostSearcherAutoSuggest,{id:e,match:j,setIsActive:h,setMatch:E,placeholder:(0,l.__)("Enter title or URL…","google-site-kit"),isLoading:s,setIsLoading:g,showDropdown:m,onClose:x,autoFocus:!0}),s&&m&&(0,A.jsx)(d.ProgressBar,{className:"googlesitekit-entity-search__loading",compress:!0}),(0,A.jsx)("div",{className:"googlesitekit-entity-search__actions",children:(0,A.jsx)(d.Button,{onClick:x,trailingIcon:(0,A.jsx)(f,{width:"30",height:"20"}),className:"googlesitekit-entity-search__close",title:(0,l.__)("Close","google-site-kit"),tooltipEnterDelayInMS:500,text:!0,tooltip:!0})})]}):(0,A.jsx)("div",{className:"googlesitekit-entity-search",children:(0,A.jsx)(d.Button,{className:"googlesitekit-border-radius-round--phone googlesitekit-button-icon--phone",onClick:k,ref:_,title:(0,l.__)("Search","google-site-kit"),trailingIcon:(0,A.jsx)(p,{width:"20",height:"20"}),tooltipEnterDelayInMS:500,text:!0,tooltip:!0,children:(0,l.__)("URL Search","google-site-kit")})})}},76283:(e,t,i)=>{i.d(t,{Fs:()=>AudienceAreaFooter,Oc:()=>s.A,AG:()=>Z.A,Rl:()=>AudienceSelectionPanel,c9:()=>$i,x_:()=>ChangeGroupsLink,H8:()=>ConnectAnalyticsCTAWidget,xE:()=>Ds,vw:()=>PrimaryUserSetupWidget,VR:()=>SecondaryUserSetupWidget});var s=i(80869),n=i(17243),o=i(62688),r=i.n(o),a=i(63696),l=i(16196),c=i(50539),d=i(67150),u=i(7081),g=i(82871);const p="audience-segmentation-info-notice-ui",m="audience-segmentation-info-notice",h=[{slug:"new-visitors",content:(0,g.__)("The higher the portion of new visitors you have, the more your audience is growing. Looking at what content brings them to your site may give you insights on how to reach even more people.","google-site-kit")},{slug:"compare-metrics",content:(0,g.__)("Select up to three visitor groups to display on the dashboard and easily compare metrics between them.","google-site-kit")},{slug:"custom-audiences",content:(0,g.__)("Configure your own custom audiences in Analytics to gain deeper insights into visitor behavior, for example consider creating an “Existing customers” or “Subscribers” segment, depending on what goals you have for your site.","google-site-kit")},{slug:"purchasers",content:(0,g.__)("Select the Purchasers visitor group to gain insights into which visitors bring the most revenue to your site.","google-site-kit")},{slug:"returning-visitors",content:(0,g.__)("The more returning visitors your site has, the stronger and more loyal an audience you’re building. Check which content brings people back to your site - it might help you create a strategy to build a community.","google-site-kit")},{slug:"compare-new-returning",content:(0,g.__)("Compare the ratio of “new” to “returning” visitors – this can give you insights on whether you have more people stopping by as a one-off, or more loyal visitors.","google-site-kit")},{slug:"compare-cities",content:(0,g.__)("Check the cities which bring you more new vs more returning visitors – there might be new audiences you could engage with in locations you hadn’t thought about.","google-site-kit")}];var f,y,v,_,k,x,I,A,j,M,S,b,N=i(55527),E=i(32947);function w(){return w=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},w.apply(null,arguments)}const C=e=>a.createElement("svg",w({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 233 117"},e),f||(f=a.createElement("path",{fill:"#F3F5F7",d:"M2.956 80.014a32.4 32.4 0 0 0 6.283 9.673c10.459 11.015 25.911 11.949 40.083 9.193A98.3 98.3 0 0 0 88.91 81.449c6.738-4.994 13.394-11.19 22.316-11.467 3.35-.103 6.814.82 9.345 2.998 5.259 4.497 5.165 12.186 9.269 17.516 5.458 7.088 13.308 9.283 21.87 10.101 24.191 2.309 53.006-5.265 69.646-23.694 14.857-16.452 16.64-42.63-1.343-57.629-8.216-6.852-19.483-9.992-30.117-8.392-8.127 1.223-16.378 4.942-24.791 5.977-9.908 1.22-16.033-2.943-24.05-7.79C127.086.641 108.62-2.597 92.807 2.292 77.671 6.972 66.777 19.747 52.048 25.36c-12.727 4.852-27.761 4.114-38.82 12.017C.143 46.727-3.146 65.603 2.956 80.014"})),a.createElement("path",{fill:"#161B18",d:"M118.945 116.194c32.642 0 59.104-1.654 59.104-3.694s-26.462-3.694-59.104-3.694c-32.643 0-59.105 1.654-59.105 3.694s26.462 3.694 59.105 3.694",opacity:.1,style:{mixBlendMode:"multiply"}}),y||(y=a.createElement("path",{fill:"#CBD0D3",d:"M118.945 116.194c32.642 0 59.104-1.654 59.104-3.694s-26.462-3.694-59.104-3.694c-32.643 0-59.105 1.654-59.105 3.694s26.462 3.694 59.105 3.694"})),v||(v=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.396,d:"M99.725 51.387c1.758 6.518 7.872 11.126 14.356 13.01 6.484 1.882 13.377 1.514 20.12 1.177 3.188-.158 6.449-.298 9.503.627s5.912 3.137 6.724 6.222c.466 1.773.121 3.686-.787 5.274"})),_||(_=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.4,d:"M87.114 62.487c-1.015 16.075-6.61 30.497-2.87 48.618h-4.26M91.929 111.105h-4.261l7.53-48.618"})),k||(k=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.396,d:"M73.527 57.419c-3.635 1.642-10.613 5.299-10.613 12.724"})),x||(x=a.createElement("path",{fill:"#CBD0D3",d:"m103.118 84.07-2.957.269-18.04 1.632-10.545.952-1-23.491-1.74-40.88 32.912-1.199.664 30.445.09 4.099.612 28.078z"})),I||(I=a.createElement("path",{fill:"#999F9B",d:"m100.163 84.339 1.697-.155 1.261-.114-1.371-62.719-1.891.087 1.017 59.457-29.439 2.786.103 2.34.04.9 10.545-.952 18.04-1.632z"})),A||(A=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.396,d:"M62.912 70.143c0 4.321 4.917 7.437 8.424 5.913"})),j||(j=a.createElement("path",{stroke:"#7B807D",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:3.607,d:"m159.169 21.79-22.985 89.068"})),M||(M=a.createElement("path",{fill:"#E77D5B",d:"m157.57 14.897-34.151 34.35a3.61 3.61 0 0 0 .016 5.1 3.6 3.6 0 0 0 1.62.929l46.822 12.4a3.606 3.606 0 0 0 4.404-4.435l-12.674-46.745a3.6 3.6 0 0 0-2.557-2.542 3.6 3.6 0 0 0-3.48.942"})),S||(S=a.createElement("path",{fill:"#962C0A",d:"m153.345 35.252 2.003-7.566 3.905 1.034-2.003 7.566-2.874 9.163-3.103-.822zm-2.709 18.123a2.77 2.77 0 0 1-1.715-1.274 2.77 2.77 0 0 1-.259-2.121q.296-1.116 1.265-1.68a2.77 2.77 0 0 1 2.121-.259q1.116.296 1.68 1.266t.268 2.085a2.77 2.77 0 0 1-1.275 1.715q-.97.564-2.085.268"})),b||(b=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.396,d:"M149.639 77.697a6.85 6.85 0 0 1-3.747 3.098c-3.335 1.14-7.399-.673-8.778-3.916"})));var T=i(15167),D=i(59323),R=i(49383),O=i(35902),z=i(13606),L=i(20898),B=i(62540);function GetHelpLink({linkURL:e}){return(0,z.A)((0,g.__)("Contact your administrator. Trouble getting access? <HelpLink />","google-site-kit"),{HelpLink:(0,B.jsx)(L.A,{href:e,external:!0,hideExternalIndicator:!0,children:(0,g.__)("Get help","google-site-kit")})})}function ErrorWidgetDetails({failedAudiences:e,showRetryButton:t,onRetry:i,onRequestAccess:s,errors:n,hasInsufficientPermissionsError:o}){return e?.length?(0,B.jsxs)("div",{children:[(0,B.jsx)(D.A,{children:(0,g.__)("Failed to create the following audiences:","google-site-kit")}),(0,B.jsx)("ul",{className:"googlesitekit-widget-audience-segmentation-error__failed-audiences",children:e.map(e=>(0,B.jsx)("li",{children:e},e))}),(0,B.jsx)(R.Button,{onClick:i,danger:!0,children:(0,g.__)("Retry","google-site-kit")})]}):t&&i?(0,B.jsx)(R.Button,{onClick:i,danger:!0,children:(0,g.__)("Retry","google-site-kit")}):(0,B.jsx)(O.A,{moduleSlug:"analytics-4",error:n,GetHelpLink:o?GetHelpLink:void 0,hideGetHelpLink:!o,buttonVariant:"danger",getHelpClassName:"googlesitekit-error-retry-text",onRetry:i,onRequestAccess:s})}GetHelpLink.propTypes={linkURL:r().string.isRequired},ErrorWidgetDetails.propTypes={errors:r().arrayOf(r().object).isRequired,onRetry:r().func.isRequired,onRequestAccess:r().func.isRequired,showRetryButton:r().bool,failedAudiences:r().arrayOf(r().string),hasInsufficientPermissionsError:r().bool};const P=(0,a.forwardRef)(({Widget:e,errors:t,onRetry:i,onRequestAccess:s,showRetryButton:n,failedAudiences:o},r)=>{const a=(0,E.dv)(),l=a===E.mp,c=a===E.Lg,u=t.some(d.SG);return(0,B.jsx)(e,{ref:r,className:"googlesitekit-audience-segmentation-error-widget",noPadding:!0,children:(0,B.jsx)(N.xA,{className:"googlesitekit-audience-segmentation-error__widget-primary-cell",collapsed:!0,children:(0,B.jsxs)(N.fI,{children:[(0,B.jsxs)(N.fh,{smSize:6,mdSize:8,lgSize:7,children:[(0,B.jsx)(T.A,{as:"h3",type:"title",size:"large",children:u?(0,g.__)("Insufficient permissions","google-site-kit"):(0,g.__)("Your visitor groups data loading failed","google-site-kit")}),(0,B.jsx)("div",{className:"googlesitekit-widget-audience-segmentation-error__actions",children:(0,B.jsx)(ErrorWidgetDetails,{failedAudiences:o,showRetryButton:n,onRetry:i,onRequestAccess:s,errors:t,hasInsufficientPermissionsError:u})})]}),!l&&!c&&(0,B.jsx)(N.fh,{className:"googlesitekit-widget-audience-segmentation-error__svg-wrapper",smSize:6,mdSize:3,lgSize:5,children:(0,B.jsx)(C,{width:"233px"})}),c&&(0,B.jsx)(N.fh,{className:"googlesitekit-widget-audience-segmentation-error__svg-wrapper",mdSize:8,children:(0,B.jsx)(C,{width:"233px"})}),l&&(0,B.jsx)(N.fh,{className:"googlesitekit-widget-audience-segmentation-error__svg-wrapper",smSize:8,children:(0,B.jsx)(C,{width:"233px"})})]})})})});P.propTypes={Widget:r().elementType.isRequired,errors:r().arrayOf(r().object).isRequired,onRetry:r().func.isRequired,onRequestAccess:r().func.isRequired,showRetryButton:r().bool,failedAudiences:r().arrayOf(r().string)};const G=P;var U=i(61046),V=i(12850),F=i(77766),W=i(99897);const H=(0,U.A)(G);function AudienceSegmentationErrorWidget({Widget:e,errors:t,onRetry:i,showRetryButton:s,failedAudiences:o}){const r=(0,F.A)(),{setValue:l}=(0,c.useDispatch)(u.n),g=t?(0,n.castArray)(t):[],m=g.some(d.SG);return(0,a.useEffect)(()=>{l(p,!0)},[l]),(0,B.jsx)(H,{Widget:e,errors:g,onRetry:function(){(0,V.sx)(`${r}_audiences-all-tiles`,"data_loading_error_retry").finally(()=>{l(p,!1),i?.()})},failedAudiences:o,onRequestAccess:()=>{(0,V.sx)(`${r}_audiences-all-tiles`,"insufficient_permissions_error_request_access")},showRetryButton:s,onInView:()=>{const e=m?"insufficient_permissions_error":"data_loading_error";(0,V.sx)(`${r}_audiences-all-tiles`,e)}})}AudienceSegmentationErrorWidget.propTypes={Widget:r().elementType.isRequired,errors:r().oneOfType([r().object,r().arrayOf(r().object)]).isRequired,onRetry:r().func,showRetryButton:r().bool,failedAudiences:r().arrayOf(r().string)};const Y=(0,l.A)({moduleName:W.L1})(AudienceSegmentationErrorWidget);var Z=i(28663),Q=(i(78464),i(72455)),q=i(58116),K=i(133),X=i(29877);function $(e,t){return(0,c.useSelect)(i=>t.reduce((t,s)=>{const n=i(Q.K9).getPartialDataSiteKitAudience(s);if(void 0===n)return{};const o={};n?o.newVsReturning="new-visitors"===n.audienceSlug?"new":"returning":o.audienceResourceName=s;const r=i(Q.K9).hasFinishedResolution("getReport",[{...e,dimensionFilters:{...e.dimensionFilters,...o}}]);return t[s]=r,t},{}))}function J(e,t){return(0,c.useSelect)(i=>t.reduce((t,s)=>{const n=i(Q.K9).getPartialDataSiteKitAudience(s);if(void 0===n)return t;const o={};n?o.newVsReturning="new-visitors"===n.audienceSlug?"new":"returning":o.audienceResourceName=s;const r=i(Q.K9).getErrorForSelector("getReport",[{...e,dimensionFilters:{...e.dimensionFilters,...o}}]);return r&&(t[s]=r),t},{}))}function ee({isSiteKitAudiencePartialData:e,siteKitAudiences:t,otherAudiences:i}){const s=(0,c.useSelect)(e=>e(q.oR).getConfiguredAudiences()),n={audienceResourceName:s},o=(0,c.useSelect)(e=>e(q.oR).getDateRangeDates({offsetDays:Q.f2,compare:!0})),{startDate:r,endDate:a}=o,l=void 0===e?void 0:i.length>0||!1===e,d=t.length>0&&e,u={...o,dimensions:[{name:"audienceResourceName"}],dimensionFilters:n,metrics:[{name:"totalUsers"},{name:"sessionsPerUser"},{name:"screenPageViewsPerSession"},{name:"screenPageViews"}],reportID:"audience-segmentation_use-audience-tiles-reports_hook_reportOptions"},g=(0,c.useInViewSelect)(e=>{if(void 0!==l)return l?e(Q.K9).getReport(u):null},[l,u]),p=(0,c.useSelect)(e=>{if(void 0!==l)return!l||e(Q.K9).hasFinishedResolution("getReport",[u])}),m=(0,c.useSelect)(e=>{if(void 0!==l)return l?e(Q.K9).getErrorForSelector("getReport",[u]):null}),h={...o,dimensions:[{name:"newVsReturning"}],dimensionFilters:{newVsReturning:["new","returning"]},metrics:[{name:"totalUsers"},{name:"sessionsPerUser"},{name:"screenPageViewsPerSession"},{name:"screenPageViews"}],reportID:"audience-segmentation_use-audience-tiles-reports_hook_newVsReturningReportOptions"},f=(0,c.useInViewSelect)(e=>{if(void 0!==d)return d?e(Q.K9).getReport(h):null},[d,h]),y=(0,c.useSelect)(e=>{if(void 0!==d)return!d||e(Q.K9).hasFinishedResolution("getReport",[h])}),v=(0,c.useSelect)(e=>{if(void 0!==d)return d?e(Q.K9).getErrorForSelector("getReport",[h]):null}),_={startDate:r,endDate:a,metrics:[{name:"screenPageViews"}],reportID:"audience-segmentation_use-audience-tiles-reports_hook_totalPageviewsReportOptions"},k=(0,c.useInViewSelect)(e=>e(Q.K9).getReport(_)),x=(0,c.useSelect)(e=>e(Q.K9).hasFinishedResolution("getReport",[_])),I=(0,c.useSelect)(e=>e(Q.K9).getErrorForSelector("getReport",[_])),A=Number(k?.totals?.[0]?.metricValues?.[0]?.value)||0,j={startDate:r,endDate:a,dimensions:["city"],metrics:[{name:"totalUsers"}],orderby:[{metric:{metricName:"totalUsers"},desc:!0}],limit:4,reportID:"audience-segmentation_use-audience-tiles-reports_hook_topCitiesReportOptions"},M=(0,c.useInViewSelect)(e=>e(Q.K9).getReportForAllAudiences(j,s)),S=$(j,s),b=J(j,s),N={startDate:r,endDate:a,dimensions:["pagePath"],metrics:[{name:"screenPageViews"}],dimensionFilters:{"customEvent:googlesitekit_post_type":{filterType:"stringFilter",matchType:"EXACT",value:"post"}},orderby:[{metric:{metricName:"screenPageViews"},desc:!0}],limit:3,reportID:"audience-segmentation_use-audience-tiles-reports_hook_topContentReportOptions"},E=(0,c.useInViewSelect)(e=>e(Q.K9).getReportForAllAudiences(N,s)),w=$(N,s),C=J(N,s),T={startDate:r,endDate:a,dimensions:["pagePath","pageTitle"],metrics:[{name:"screenPageViews"}],dimensionFilters:{"customEvent:googlesitekit_post_type":{filterType:"stringFilter",matchType:"EXACT",value:"post"}},orderby:[{metric:{metricName:"screenPageViews"},desc:!0}],limit:15,reportID:"audience-segmentation_use-audience-tiles-reports_hook_topContentPageTitlesReportOptions"};return{report:g,reportLoaded:p,reportError:m,siteKitAudiencesReport:f,siteKitAudiencesReportLoaded:y,siteKitAudiencesReportError:v,totalPageviews:A,totalPageviewsReportLoaded:x,totalPageviewsReportError:I,topCitiesReport:M,topCitiesReportsLoaded:S,topCitiesReportErrors:b,topContentReport:E,topContentReportsLoaded:w,topContentReportErrors:C,topContentPageTitlesReport:(0,c.useInViewSelect)(e=>e(Q.K9).getReportForAllAudiences(T,s)),topContentPageTitlesReportsLoaded:$(T,s),topContentPageTitlesReportErrors:J(T,s)}}var te,ie,se,ne,oe,re,ae,le,ce,de,ue,ge,pe=i(35323),me=i(23224);function AudienceTileLoading(){return(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-loading",children:[(0,B.jsx)(me.A,{width:"100%",height:"20px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"}),(0,B.jsx)(me.A,{width:"100%",height:"52px"})]})}function he(){return he=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},he.apply(null,arguments)}const fe=e=>a.createElement("svg",he({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 190 142"},e),te||(te=a.createElement("path",{fill:"#F3F5F7",d:"M11.755 110.799a44 44 0 0 0 4.457 4.095c14.958 11.965 27.316 11.946 44.424 9.762 15.862-2.025 17.862-10.923 35.362-10.923s25.665 6.38 46 5 38.081-23.761 44.757-41.774c9.833-26.528-4.519-57.596-24.82-66.096-18.699-8.5-31.437.01-51.437-3.63C84.998 2.59 79.998-4.051 60.636 4c-20.53 8.701-20.455 23.533-32.699 38.667C18.974 53.747 4.956 56.312.734 76.959c-2.673 13.07 3.077 25.467 11.021 33.84"})),a.createElement("path",{fill:"#161B18",d:"M96.07 141.772c39.765 0 72-2.014 72-4.5 0-2.485-32.235-4.5-72-4.5s-72 2.015-72 4.5c0 2.486 32.236 4.5 72 4.5",opacity:.1,style:{mixBlendMode:"multiply"}}),ie||(ie=a.createElement("path",{fill:"#CBD0D3",d:"M96.07 141.772c39.765 0 72-2.014 72-4.5 0-2.485-32.235-4.5-72-4.5s-72 2.015-72 4.5c0 2.486 32.236 4.5 72 4.5"})),se||(se=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.7,d:"M72.657 62.826c2.14 7.94 9.59 13.553 17.488 15.847 7.898 2.295 16.295 1.846 24.51 1.435 3.883-.192 7.855-.363 11.576.764s7.202 3.821 8.191 7.58c.568 2.16.147 4.49-.959 6.424"})),ne||(ne=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.705,d:"M57.306 76.348c-1.237 19.582-8.053 37.15-3.497 59.224h-5.188M63.171 135.572h-5.19l9.173-59.224"})),oe||(oe=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.7,d:"M40.754 70.174c-4.429 2-12.93 6.455-12.929 15.5"})),re||(re=a.createElement("path",{fill:"#CBD0D3",d:"m76.804 102.64-3.602.327-21.976 1.988-12.845 1.16-1.22-28.616-2.118-49.8 40.092-1.46.81 37.088.109 4.993.745 34.204z"})),ae||(ae=a.createElement("path",{fill:"#999F9B",d:"m73.203 102.967 2.067-.188 1.537-.139-1.671-76.403-2.303.105 1.24 72.43-35.862 3.393.125 2.852.048 1.095 12.845-1.159 21.977-1.989z"})),le||(le=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.7,d:"M27.827 85.674c0 5.264 5.99 9.06 10.262 7.203"})),ce||(ce=a.createElement("path",{stroke:"#7B807D",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:4.393,d:"m145.07 26.773-28 108.499"})),de||(de=a.createElement("path",{fill:"#E77D5B",d:"M143.121 18.374 101.519 60.22a4.39 4.39 0 0 0-1.124 4.247 4.4 4.4 0 0 0 3.116 3.096l57.038 15.105a4.394 4.394 0 0 0 5.365-5.402l-15.439-56.943a4.393 4.393 0 0 0-7.354-1.949"})),ue||(ue=a.createElement("path",{fill:"#962C0A",d:"m138.137 42.556 2.44-9.216 4.756 1.26-2.44 9.215-3.501 11.163-3.78-1.001zm-3.301 22.078a3.37 3.37 0 0 1-2.088-1.553 3.37 3.37 0 0 1-.316-2.584q.36-1.359 1.541-2.046a3.38 3.38 0 0 1 2.584-.316q1.359.36 2.046 1.542t.327 2.54a3.38 3.38 0 0 1-1.553 2.09q-1.182.686-2.541.327"})),ge||(ge=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.7,d:"M133.461 94.876a8.35 8.35 0 0 1-4.565 3.774c-4.063 1.39-9.013-.82-10.694-4.77"}))),ye=(0,a.forwardRef)(({errors:e,onRetry:t,onRequestAccess:i},s)=>{const n=e.some(e=>(0,d.SG)(e));return(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-error",ref:s,children:(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-error__container",children:[(0,B.jsx)(fe,{className:"googlesitekit-audience-segmentation-tile-error__image"}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-error__body",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-error__message",children:(0,B.jsx)(T.A,{as:"h3",type:"headline",size:"small",className:"googlesitekit-audience-segmentation-tile-error__title",children:n?(0,g.__)("Insufficient permissions","google-site-kit"):(0,g.__)("Data loading failed","google-site-kit")})}),(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-error__actions",children:(0,B.jsx)(O.A,{moduleSlug:"analytics-4",error:e,GetHelpLink:n?GetHelpLink:void 0,hideGetHelpLink:!n,buttonVariant:"danger",onRetry:t,onRequestAccess:i})})]})]})})});ye.propTypes={errors:r().array.isRequired,onRetry:r().func.isRequired,onRequestAccess:r().func.isRequired};const ve=ye,_e=(0,U.A)(ve);function AudienceTileError({audienceSlug:e,errors:t}){const i=(0,F.A)(),s=t.some(e=>(0,d.SG)(e));return(0,B.jsx)(_e,{errors:t,onInView:()=>{const t=s?"insufficient_permissions_error":"data_loading_error";(0,V.sx)(`${i}_audiences-tile`,t,e)},onRetry:()=>{(0,V.sx)(`${i}_audiences-tile`,"data_loading_error_retry",e)},onRequestAccess:()=>{(0,V.sx)(`${i}_audiences-tile`,"insufficient_permissions_error_request_access",e)}})}AudienceTileError.propTypes={audienceSlug:r().string.isRequired,errors:r().array.isRequired};var ke,xe=i(4452),Ie=i.n(xe);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 je=e=>a.createElement("svg",Ae({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),ke||(ke=a.createElement("path",{fill:"currentColor",d:"M.833 16.667v-2.334q0-.708.354-1.291a2.5 2.5 0 0 1 .98-.917q1.29-.646 2.624-.958a11 11 0 0 1 2.709-.333q1.375 0 2.708.333 1.333.313 2.625.958.604.313.958.917.375.584.375 1.292v2.333zm15 0v-2.5q0-.917-.52-1.75-.5-.855-1.438-1.458 1.062.125 2 .437a10 10 0 0 1 1.75.73q.75.416 1.145.937.396.5.396 1.104v2.5zM7.5 10a3.2 3.2 0 0 1-2.354-.979 3.2 3.2 0 0 1-.98-2.354q0-1.376.98-2.354a3.2 3.2 0 0 1 2.354-.98 3.2 3.2 0 0 1 2.354.98 3.2 3.2 0 0 1 .979 2.354 3.2 3.2 0 0 1-.98 2.354 3.2 3.2 0 0 1-2.353.98m8.333-3.333a3.2 3.2 0 0 1-.98 2.354 3.2 3.2 0 0 1-2.353.98q-.23 0-.584-.042a7 7 0 0 1-.583-.125q.563-.667.854-1.48a4.7 4.7 0 0 0 .313-1.687q0-.875-.313-1.688a4.8 4.8 0 0 0-.854-1.479q.292-.104.583-.125a4 4 0 0 1 .584-.042 3.2 3.2 0 0 1 2.354.98 3.2 3.2 0 0 1 .979 2.354M2.5 15h10v-.666a.74.74 0 0 0-.125-.417.74.74 0 0 0-.292-.292 10.5 10.5 0 0 0-2.27-.833 9.34 9.34 0 0 0-4.626 0q-1.146.27-2.27.833a.9.9 0 0 0-.313.292.84.84 0 0 0-.104.417zm5-6.666q.687 0 1.166-.48.5-.5.5-1.187t-.5-1.167Q8.186 5 7.5 5q-.688 0-1.188.5-.48.48-.479 1.167 0 .687.48 1.187.499.48 1.187.48"})));var Me;function Se(){return Se=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},Se.apply(null,arguments)}const be=e=>a.createElement("svg",Se({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),Me||(Me=a.createElement("path",{fill:"currentColor",d:"M10 17.5a7.4 7.4 0 0 1-2.937-.583 8 8 0 0 1-2.375-1.605 8 8 0 0 1-1.605-2.374A7.4 7.4 0 0 1 2.5 10q0-1.563.583-2.917a7.7 7.7 0 0 1 1.604-2.375 7.6 7.6 0 0 1 2.375-1.604A7.2 7.2 0 0 1 10 2.5q1.708 0 3.23.73a7.25 7.25 0 0 1 2.603 2.062V3.333H17.5v5h-5V6.667h2.292a6.2 6.2 0 0 0-2.104-1.834A5.6 5.6 0 0 0 10 4.167q-2.437 0-4.146 1.708Q4.167 7.563 4.167 10t1.687 4.146q1.71 1.687 4.146 1.687 2.188 0 3.813-1.416 1.646-1.418 1.937-3.584h1.708q-.312 2.854-2.458 4.771-2.125 1.896-5 1.896m2.333-4-3.166-3.167v-4.5h1.666v3.834l2.667 2.666z"})));var Ne;function Ee(){return Ee=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},Ee.apply(null,arguments)}const we=e=>a.createElement("svg",Ee({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),Ne||(Ne=a.createElement("path",{fill:"currentColor",d:"M13.125 16.667H3.334q-.689 0-1.188-.48-.48-.5-.479-1.187V5q0-.687.48-1.166.498-.5 1.187-.5h13.333q.687 0 1.167.5.5.479.5 1.166v10q0 .688-.5 1.188-.48.48-1.167.479H15.5l-3.916-3.917q-.437.292-.959.438-.5.146-1.041.146-1.562 0-2.667-1.084-1.083-1.104-1.083-2.666 0-1.563 1.083-2.646a3.63 3.63 0 0 1 2.667-1.104q1.562 0 2.646 1.104 1.104 1.083 1.104 2.646 0 .563-.146 1.062a3.4 3.4 0 0 1-.438.938L16.167 15h.5V5H3.334v10h8.125zm-3.541-5q.874 0 1.479-.604.604-.604.604-1.48 0-.875-.604-1.479a2.01 2.01 0 0 0-1.48-.604q-.874 0-1.479.604a2.01 2.01 0 0 0-.604 1.48q0 .875.604 1.479.604.603 1.48.604M3.334 15V5z"})));var Ce;function Te(){return Te=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},Te.apply(null,arguments)}const De=e=>a.createElement("svg",Te({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),Ce||(Ce=a.createElement("path",{fill:"currentColor",d:"M4.167 17.5q-.688 0-1.188-.48-.48-.498-.479-1.187V4.167q0-.689.48-1.167.499-.5 1.187-.5h11.666q.688 0 1.167.5.5.48.5 1.167v11.666q0 .688-.5 1.188-.48.48-1.167.479zm0-1.667h11.666v-10H4.167zM10 14.167q-1.709 0-3.062-.917A5.4 5.4 0 0 1 5 10.833a5.27 5.27 0 0 1 1.938-2.395Q8.29 7.499 10 7.5q1.709 0 3.042.938A5.23 5.23 0 0 1 15 10.833a5.35 5.35 0 0 1-1.958 2.417q-1.334.917-3.042.917m0-1.25q1.167 0 2.125-.542a4 4 0 0 0 1.5-1.542 3.85 3.85 0 0 0-1.5-1.52A4.1 4.1 0 0 0 10 8.75a4.1 4.1 0 0 0-2.125.563 3.85 3.85 0 0 0-1.5 1.52 4 4 0 0 0 1.5 1.542 4.24 4.24 0 0 0 2.125.542m0-.834a1.26 1.26 0 0 1-.896-.354 1.26 1.26 0 0 1-.354-.896q0-.52.354-.875.375-.375.896-.375.52 0 .875.375.375.354.375.875t-.375.896a1.2 1.2 0 0 1-.875.354"})));var Re;function Oe(){return Oe=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},Oe.apply(null,arguments)}const ze=e=>a.createElement("svg",Oe({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),Re||(Re=a.createElement("path",{fill:"currentColor",d:"M10 18.333a.78.78 0 0 1-.5-.166 1 1 0 0 1-.312-.438 11.6 11.6 0 0 0-1-2.187q-.585-1.022-1.646-2.396-1.062-1.376-1.73-2.625-.645-1.25-.645-3.021 0-2.437 1.687-4.125Q7.564 1.666 10 1.667q2.438 0 4.125 1.708 1.71 1.688 1.709 4.125 0 1.896-.73 3.166-.708 1.25-1.645 2.48-1.125 1.5-1.709 2.5a11.8 11.8 0 0 0-.937 2.083.94.94 0 0 1-.334.458.8.8 0 0 1-.479.146m0-2.979q.354-.708.792-1.396.459-.688 1.333-1.833a20 20 0 0 0 1.459-2.146q.583-1 .583-2.48 0-1.728-1.23-2.937Q11.73 3.332 10 3.333t-2.958 1.23Q5.833 5.77 5.834 7.5q0 1.479.562 2.479.584.98 1.48 2.146.874 1.146 1.312 1.833.458.688.812 1.396m0-5.77q.876 0 1.48-.605.603-.604.604-1.48 0-.874-.604-1.478A2.01 2.01 0 0 0 10 5.417q-.875-.001-1.479.604A2.01 2.01 0 0 0 7.917 7.5q0 .875.604 1.479t1.48.604"})));var Le;function Be(){return Be=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},Be.apply(null,arguments)}const Pe=e=>a.createElement("svg",Be({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),Le||(Le=a.createElement("path",{fill:"currentColor",d:"M3.334 16.667q-.689 0-1.188-.48-.48-.5-.479-1.187V5q0-.687.48-1.166.498-.5 1.187-.5h13.333q.687 0 1.167.5.5.479.5 1.166v10q0 .688-.5 1.188-.48.48-1.167.479zm0-1.667h8.75v-2.916h-8.75zm10.416 0h2.917V7.5H13.75zM3.334 10.417h8.75V7.5h-8.75z"})));function AudienceTileMetric({TileIcon:e,title:t,metricValue:i,Badge:s,metricValueFormat:n}){return(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__icon",children:(0,B.jsx)(e,{})}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__container",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__value",children:(0,V.Eo)(i,n)}),(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__title",children:t})]}),(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__badge-container",children:(0,B.jsx)(s,{})})]})}function AudienceTileNoData(){return(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile__no-data",children:(0,g.__)("No data to show yet","google-site-kit")})}function AudienceTileCitiesMetric({TileIcon:e,title:t,topCities:i}){const s=i?.dimensionValues?.filter(Boolean)||[],n=!!s.length;return(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric googlesitekit-audience-segmentation-tile-metric--cities",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__icon",children:(0,B.jsx)(e,{})}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__container",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__title",children:t}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__content",children:[!n&&(0,B.jsx)(AudienceTileNoData,{}),n&&s.map((e,t)=>(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__cities-metric",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__cities-metric-name",children:e?.value}),(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__cities-metric-value",children:(0,V.Eo)(i?.metricValues[t]?.value/i?.total,{style:"percent",maximumFractionDigits:1})})]},e?.value))]})]})]})}AudienceTileMetric.propTypes={TileIcon:r().elementType.isRequired,title:r().string.isRequired,metricValue:r().number.isRequired,Badge:r().elementType.isRequired,metricValueFormat:r().object},AudienceTileCitiesMetric.propTypes={TileIcon:r().elementType.isRequired,title:r().string.isRequired,topCities:r().object};var Ge=i(44451),Ue=i(78340),Ve=i(93896),Fe=i(10953);function BadgeWithTooltip({className:e="",label:t,onTooltipOpen:i,tooltipTitle:s}){return(0,B.jsxs)("span",{className:Ie()("googlesitekit-badge-with-tooltip","googlesitekit-badge",e),children:[t,s&&(0,B.jsx)(Fe.A,{onOpen:i,title:s})]})}function PartialDataNotice({content:e}){return(0,B.jsx)("span",{className:"googlesitekit-audience-segmentation-partial-data-notice",children:e})}BadgeWithTooltip.propTypes={onTooltipOpen:r().func,tooltipTitle:r().node,className:r().string,label:r().node.isRequired},PartialDataNotice.propTypes={content:r().node};const We=(0,a.forwardRef)(({onClick:e,isSaving:t},i)=>(0,B.jsxs)("div",{ref:i,className:"googlesitekit-audience-segmentation-tile-metric__no-data",children:[(0,g.__)("No data to show","google-site-kit"),(0,B.jsx)(D.A,{children:(0,g.__)("Update Analytics to track metric","google-site-kit")}),(0,B.jsx)(R.SpinnerButton,{onClick:e,isSaving:t,disabled:t,danger:!0,children:(0,g.__)("Update","google-site-kit")})]}));We.propTypes={onClick:r().func.isRequired,isSaving:r().bool};const He=We,Ye=(0,U.A)(He);function AudienceTilePagesMetricContent({topContentTitles:e,topContent:t,isTopContentPartialData:i,hasCustomDimension:s,onCreateCustomDimension:n,isSaving:o}){const r=(0,F.A)(),a=(0,pe.A)(),l=(0,E.dv)(),d=[E.mp,E.Lg].includes(l),u=t?.dimensionValues?.filter(Boolean)||[],p=!!u.length,m=(0,c.useSelect)(e=>e(q.oR).getDateRangeDates({offsetDays:Q.f2}));function ContentLinkComponent({content:t}){const i=e[t?.value],s=t?.value,n=(0,c.useSelect)(e=>a?null:e(Q.K9).getServiceReportURL("all-pages-and-screens",{filters:{unifiedPagePathScreen:s},dates:m}));return a?(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile__top-content-metric-name",children:i}):(0,B.jsx)(L.A,{href:n,title:i,external:!0,hideExternalIndicator:!0,children:i})}return(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__content",children:[!s&&(0,B.jsx)(Ye,{onClick:function(){(0,V.sx)(`${r}_audiences-top-content-cta`,"create_custom_dimension").finally(n)},isSaving:o,onInView:()=>{(0,V.sx)(`${r}_audiences-top-content-cta`,"view_cta")}}),s&&!p&&(0,B.jsx)(AudienceTileNoData,{}),s&&p&&u.map((e,i)=>(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__page-metric-container",children:[(0,B.jsx)(ContentLinkComponent,{content:e}),(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__page-metric-value",children:(0,V.Eo)(t?.metricValues[i]?.value)})]},e?.value)),d&&i&&(0,B.jsx)(PartialDataNotice,{content:(0,g.__)("Still collecting full data for this timeframe, partial data is displayed for this metric","google-site-kit")})]})}AudienceTilePagesMetricContent.propTypes={topContentTitles:r().object,topContent:r().object,isTopContentPartialData:r().bool,hasCustomDimension:r().bool,onCreateCustomDimension:r().func,isSaving:r().bool};var Ze=i(43427),Qe=i(27333);function AudienceTilePagesMetric({audienceTileNumber:e,audienceSlug:t,TileIcon:n,title:o,topContent:r,topContentTitles:l,isTopContentPartialData:u}){const p=(0,E.dv)(),m=(0,F.A)(),h=Q.Cu.googlesitekit_post_type.parameterName,f=(0,c.useSelect)(e=>!e(Q.K9).hasCustomDimensions(h)),y=(0,c.useSelect)(e=>e(q.oR).hasScope(Q.S9)),v=(0,Ge.F)(i.g.location.href,{notification:"audience_segmentation",widgetArea:Ze.AREA_MAIN_DASHBOARD_TRAFFIC_AUDIENCE_SEGMENTATION}),_=(0,Ge.F)(i.g.location.href,{widgetArea:Ze.AREA_MAIN_DASHBOARD_TRAFFIC_AUDIENCE_SEGMENTATION}),k=(0,Qe.A)(Q.CV,"isAutoCreatingCustomDimensionsForAudience"),x=(0,c.useSelect)(e=>e(Q.K9).isCreatingCustomDimension(h)),I=(0,c.useSelect)(e=>e(Q.K9).isFetchingSyncAvailableCustomDimensions()),A=(0,c.useSelect)(e=>e(Q.K9).getCreateCustomDimensionError(h)),j=(0,c.useSelect)(e=>e(Q.K9).getPropertyID()),{clearError:M}=(0,c.useDispatch)(Q.K9),{setValues:S}=(0,c.useDispatch)(Ue.s),{setPermissionScopeError:b,clearPermissionScopeError:N}=(0,c.useDispatch)(q.oR),w=(0,Qe.A)(Q.CV,"isRetrying"),C=(0,Qe.A)(Q.CV,"autoSubmit"),T=(0,c.useSelect)(e=>e(Ve.O4).getSetupErrorCode()),{setSetupErrorCode:D}=(0,c.useDispatch)(Ve.O4),R=C&&"access_denied"===T,O=(0,a.useCallback)(({isRetrying:e}={})=>{S(Q.CV,{autoSubmit:!0,isRetrying:e}),y||b({code:d.db,message:(0,g.__)("Additional permissions are required to create new audiences in Analytics.","google-site-kit"),data:{status:403,scopes:[Q.S9],skipModal:!0,skipDefaultErrorNotifications:!0,redirectURL:v,errorRedirectURL:_}})},[y,v,_,b,S]),z=(0,a.useCallback)(()=>{S(Q.CV,{autoSubmit:!1,isRetrying:!1}),D(null),N(),M("createCustomDimension",[j,Q.Cu.googlesitekit_post_type])},[M,N,j,D,S]),L=[E.mp,E.Lg].includes(p),P=k||x||I;return(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric googlesitekit-audience-segmentation-tile-metric--top-content",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile-metric__icon",children:(0,B.jsx)(n,{})}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__container",children:[(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-metric__title",children:[o,!L&&u&&(0,B.jsx)(BadgeWithTooltip,{className:"googlesitekit-audience-segmentation-partial-data-badge",label:(0,g.__)("Partial data","google-site-kit"),onTooltipOpen:()=>{(0,V.sx)(`${m}_audiences-tile`,"view_top_content_partial_data_tooltip",t)},tooltipTitle:(0,g.__)("Still collecting full data for this timeframe, partial data is displayed for this metric","google-site-kit")})]}),(0,B.jsx)(AudienceTilePagesMetricContent,{topContentTitles:l,topContent:r,isTopContentPartialData:u,hasCustomDimension:!f,onCreateCustomDimension:O,isSaving:P}),0===e&&(A&&!P||w&&!k||R)&&(0,B.jsx)(s.A,{apiErrors:[A],title:(0,g.__)("Failed to enable metric","google-site-kit"),description:(0,g.__)("Oops! Something went wrong. Retry enabling the metric.","google-site-kit"),onRetry:()=>O({isRetrying:!0}),onCancel:z,inProgress:P,hasOAuthError:R,trackEventCategory:`${m}_audiences-top-content-cta`})]})]})}AudienceTilePagesMetric.propTypes={audienceTileNumber:r().number,audienceSlug:r().string.isRequired,TileIcon:r().elementType.isRequired,title:r().string.isRequired,topContent:r().object,topContentTitles:r().object,isTopContentPartialData:r().bool};var qe,Ke,Xe,$e,Je,et,tt,it,st,nt,ot=i(2478);function rt(){return rt=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},rt.apply(null,arguments)}const at=e=>a.createElement("svg",rt({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 109 94"},e),qe||(qe=a.createElement("path",{fill:"#EBEEF0",d:"M54.323 93.529c21.908 0 39.667-17.76 39.667-39.667 0-21.908-17.76-39.667-39.667-39.667s-39.667 17.76-39.667 39.667 17.76 39.667 39.667 39.667"})),Ke||(Ke=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.578,d:"m37.717 38.469 52.162 18.445a12.955 12.955 0 0 0 16.533-7.896v0a12.95 12.95 0 0 0-3.553-13.955 13 13 0 0 0-4.349-2.582L87.024 28.42l-.014.042c.3-1.877.323-3.787.07-5.67"})),Xe||(Xe=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2.578,d:"M70.947 38.469 18.785 56.914A12.955 12.955 0 0 1 2.25 49.018v0a12.955 12.955 0 0 1 7.902-16.537L21.64 28.42l.016.042a19.4 19.4 0 0 1-.07-5.668"})),$e||($e=a.createElement("path",{fill:"#70B2F5",d:"m27.61.51.497 83.126a39.625 39.625 0 0 0 53.598-1.071l1.19-82.11z"})),Je||(Je=a.createElement("path",{fill:"#77AD8C",d:"m27.61.51.497 83.126a39.625 39.625 0 0 0 53.598-1.071l1.19-82.11z"})),a.createElement("path",{fill:"#77AD8C",d:"m82.648 17.112.24-16.66h-5.853l-1.033 86.633a40 40 0 0 0 5.702-4.526z",opacity:.2,style:{mixBlendMode:"multiply"}}),et||(et=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.785,d:"M44.723 46.377c4.916 3.946 11.868 4.892 19.218.273"})),tt||(tt=a.createElement("path",{fill:"#7B807D",d:"M80.38 24.992c0-9.563-11.446-17.056-26.059-17.056s-26.06 7.49-26.06 17.056z"})),it||(it=a.createElement("path",{fill:"#fff",stroke:"#464B48",strokeLinejoin:"round",strokeWidth:4.363,d:"M39.588 39.737c8.143 0 14.744-6.602 14.744-14.745s-6.601-14.744-14.744-14.744-14.744 6.601-14.744 14.744 6.601 14.744 14.744 14.744Z"})),st||(st=a.createElement("path",{fill:"#fff",stroke:"#464B48",strokeLinejoin:"round",strokeWidth:4.363,d:"M69.076 39.737c8.143 0 14.745-6.602 14.745-14.745s-6.602-14.744-14.745-14.744-14.744 6.601-14.744 14.744 6.601 14.744 14.744 14.744Z"})),nt||(nt=a.createElement("path",{stroke:"#B8BDB9",strokeLinejoin:"round",strokeWidth:3.173,d:"M30.86 24.992a8.74 8.74 0 0 1 8.726-8.726M60.348 24.992a8.74 8.74 0 0 1 8.726-8.726"})));function AudienceTileCollectingData(){return(0,B.jsxs)(a.Fragment,{children:[(0,B.jsx)(at,{className:"googlesitekit-audience-segmentation-tile__zero-data-image"}),(0,B.jsx)("p",{className:"googlesitekit-audience-segmentation-tile__zero-data-description",children:(0,g.__)("Site Kit is collecting data for this group.","google-site-kit")})]})}var lt;function ct(){return ct=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},ct.apply(null,arguments)}const dt=e=>a.createElement("svg",ct({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 19 19"},e),lt||(lt=a.createElement("path",{fill:"currentColor",d:"m12.907 10.523-1.088-1.088q.17-.88-.506-1.65-.675-.768-1.743-.6L8.482 6.098q.319-.15.638-.225.337-.075.712-.075 1.407 0 2.381.994.994.975.994 2.381 0 .375-.075.712-.075.319-.225.638m2.4 2.362-1.088-1.05a8 8 0 0 0 1.257-1.18 6.7 6.7 0 0 0 .956-1.482 7.3 7.3 0 0 0-2.7-3q-1.743-1.125-3.9-1.125-.544 0-1.069.075t-1.031.225L6.57 4.185a8 8 0 0 1 1.575-.468 8.2 8.2 0 0 1 1.687-.169q2.831 0 5.044 1.575a8.87 8.87 0 0 1 3.206 4.05 8.8 8.8 0 0 1-1.144 2.063 8.2 8.2 0 0 1-1.631 1.65m.375 4.613-3.15-3.113a10 10 0 0 1-1.331.32 10 10 0 0 1-1.369.093q-2.831 0-5.044-1.556a9 9 0 0 1-3.206-4.07 8.7 8.7 0 0 1 .994-1.837q.6-.862 1.369-1.537l-2.063-2.1 1.05-1.05 13.8 13.8zM4.995 6.848A8 8 0 0 0 4 7.917q-.45.58-.769 1.256a7.46 7.46 0 0 0 2.681 3.019q1.763 1.106 3.919 1.106.375 0 .731-.038.357-.056.731-.112l-.675-.713a6 6 0 0 1-.393.094 4 4 0 0 1-.394.019q-1.405 0-2.4-.975-.975-.994-.975-2.4 0-.207.019-.394.037-.187.094-.394z"})));function AudienceTileCollectingDataHideable({onHideTile:e}){return(0,B.jsxs)(a.Fragment,{children:[(0,B.jsx)("p",{className:"googlesitekit-audience-segmentation-tile__zero-data-description",children:(0,g.__)("You can hide this group until data is available.","google-site-kit")}),(0,B.jsx)(L.A,{className:"googlesitekit-audience-segmentation-tile-hide-cta",onClick:e,leadingIcon:(0,B.jsx)(dt,{width:22,height:22}),secondary:!0,linkButton:!0,children:(0,g.__)("Temporarily hide","google-site-kit")})]})}AudienceTileCollectingDataHideable.propTypes={onHideTile:r().func.isRequired};const ut=(0,a.forwardRef)(({Widget:e,audienceSlug:t,title:i,infoTooltip:s,isMobileBreakpoint:n,isTileHideable:o,onHideTile:r},a)=>{const l=(0,F.A)();return(0,B.jsx)(e,{ref:a,noPadding:!0,children:(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile",children:(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__zero-data-container",children:[!n&&(0,B.jsx)("div",{className:"googlesitekit-audience-segmentation-tile__header",children:(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__header-title",children:[i,s&&(0,B.jsx)(Fe.A,{title:s,tooltipClassName:"googlesitekit-info-tooltip__content--audience",onOpen:()=>(0,V.sx)(`${l}_audiences-tile`,"view_tile_tooltip",t)})]})}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__zero-data-content",children:[(0,B.jsx)(AudienceTileCollectingData,{}),o&&(0,B.jsx)(AudienceTileCollectingDataHideable,{onHideTile:r})]})]})})})});ut.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};const gt=ut,pt=(0,U.A)(gt);function AudienceTileZeroData({Widget:e,audienceSlug:t,title:i,infoTooltip:s,isMobileBreakpoint:n,isTileHideable:o,onHideTile:r}){const a=(0,F.A)();return(0,B.jsx)(pt,{Widget:e,audienceSlug:t,title:i,infoTooltip:s,isMobileBreakpoint:n,isTileHideable:o,onHideTile:function(){(0,V.sx)(`${a}_audiences-tile`,"temporarily_hide",t).finally(r)},onInView:()=>{(0,V.sx)(`${a}_audiences-tile`,"view_tile_collecting_data",t)}})}function AudienceTile({audienceTileNumber:e=0,audienceSlug:t,title:i,infoTooltip:s,visitors:n,visitsPerVisitor:o,pagesPerVisit:r,pageviews:a,percentageOfTotalPageViews:l,topCities:d,topContent:u,topContentTitles:p,hasInvalidCustomDimensionError:m,Widget:h,audienceResourceName:f,isZeroData:y,isPartialData:v,isTileHideable:_,onHideTile:k}){const x=(0,E.dv)(),I=(0,F.A)(),A=(0,pe.A)(),j=(0,c.useInViewSelect)(e=>{const t=e(Q.K9).getPropertyID();return t&&e(Q.K9).isPropertyPartialData(t)}),M=(0,c.useSelect)(e=>e(Q.K9).isSiteKitAudience(f)),S=(0,c.useInViewSelect)(e=>!M&&void 0!==j&&(!j&&f&&e(Q.K9).isAudiencePartialData(f)),[j,M,f]),b=(0,c.useInViewSelect)(e=>void 0!==j&&(!j&&!S&&e(Q.K9).isCustomDimensionPartialData("googlesitekit_post_type")),[S]),N=(0,c.useInViewSelect)(e=>e(Q.K9).hasCustomDimensions("googlesitekit_post_type"),[]),w=[E.mp,E.Lg].includes(x);return v&&y?(0,B.jsx)(AudienceTileZeroData,{Widget:h,audienceSlug:t,title:i,infoTooltip:s,isMobileBreakpoint:w,isTileHideable:_,onHideTile:k}):(0,B.jsx)(h,{noPadding:!0,children:(0,B.jsxs)("div",{className:Ie()("googlesitekit-audience-segmentation-tile",{"googlesitekit-audience-segmentation-tile--partial-data":S}),children:[!w&&(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__header",children:[(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__header-title",children:[i,s&&(0,B.jsx)(Fe.A,{title:s,tooltipClassName:"googlesitekit-info-tooltip__content--audience",onOpen:()=>(0,V.sx)(`${I}_audiences-tile`,"view_tile_tooltip",t)})]}),S&&(0,B.jsx)(BadgeWithTooltip,{className:"googlesitekit-audience-segmentation-partial-data-badge",label:(0,g.__)("Partial data","google-site-kit"),tooltipTitle:(0,g.__)("Still collecting full data for this timeframe, partial data is displayed for this group","google-site-kit"),onTooltipOpen:()=>{(0,V.sx)(`${I}_audiences-tile`,"view_tile_partial_data_tooltip",t)}})]}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile__metrics",children:[w&&S&&(0,B.jsx)(PartialDataNotice,{content:(0,g.__)("Still collecting full data for this timeframe, partial data is displayed for this group","google-site-kit")}),(0,B.jsx)(AudienceTileMetric,{TileIcon:je,title:(0,g.__)("Visitors","google-site-kit"),metricValue:n.currentValue,Badge:()=>(0,B.jsx)(ot.A,{previousValue:n.previousValue,currentValue:n.currentValue})}),(0,B.jsx)(AudienceTileMetric,{TileIcon:be,title:(0,g.__)("Visits per visitor","google-site-kit"),metricValue:o.currentValue,Badge:()=>(0,B.jsx)(ot.A,{previousValue:o.previousValue,currentValue:o.currentValue})}),(0,B.jsx)(AudienceTileMetric,{TileIcon:we,title:(0,g.__)("Pages per visit","google-site-kit"),metricValue:r.currentValue,Badge:()=>(0,B.jsx)(ot.A,{previousValue:r.previousValue,currentValue:r.currentValue}),metricValueFormat:{style:"decimal",maximumFractionDigits:2}}),(0,B.jsx)(AudienceTileMetric,{TileIcon:De,title:(0,g.sprintf)(/* translators: %s: is a percentage value such as 33.3%. */ /* translators: %s: is a percentage value such as 33.3%. */
|
||
(0,g.__)("%s of total pageviews","google-site-kit"),(0,V.Eo)(l,{style:"percent",maximumFractionDigits:1})),metricValue:a.currentValue,Badge:()=>(0,B.jsx)(ot.A,{previousValue:a.previousValue,currentValue:a.currentValue})}),(0,B.jsx)(AudienceTileCitiesMetric,{TileIcon:ze,title:(0,g.__)("Cities with the most visitors","google-site-kit"),topCities:d}),(!A||N&&!m)&&(0,B.jsx)(AudienceTilePagesMetric,{audienceTileNumber:e,audienceSlug:t,TileIcon:Pe,title:(0,g.__)("Top content by pageviews","google-site-kit"),topContentTitles:p,topContent:u,isTopContentPartialData:b})]})]})})}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,z.A)((0,g.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
|
||
(0,g.__)('%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,B.jsx)("strong",{}),link:(0,B.jsx)(L.A,{href:i,external:!0,hideExternalIndicator:!0})});case"returning-visitors":return(0,z.A)((0,g.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
|
||
(0,g.__)('%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,B.jsx)("strong",{}),link:(0,B.jsx)(L.A,{href:i,external:!0,hideExternalIndicator:!0})});default:return(0,z.A)((0,g.sprintf)(/* translators: %s: is the audience name */ /* translators: %s: is the audience name */
|
||
(0,g.__)("%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,B.jsx)("strong",{}),link:(0,B.jsx)(L.A,{href:i,external:!0,hideExternalIndicator:!0})})}},[e,t,i])}var mt,ht,ft,yt,vt,_t,kt,xt,It,At,jt,Mt,St,bt,Nt,Et,wt,Ct,Tt,Dt,Rt,Ot,zt,Lt,Bt,Pt,Gt,Ut,Vt,Ft,Wt,Ht,Yt,Zt,Qt,qt,Kt,Xt,$t,Jt,ei,ti,ii,si,ni,oi,ri,ai,li,ci,di,ui,gi,pi,mi,hi,fi,yi,vi,_i,ki,xi,Ii,Ai,ji,Mi,Si,bi,Ni,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"})),yt||(yt=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"})),vt||(vt=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"})),_t||(_t=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"})),kt||(kt=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"})),It||(It=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M133.233 60.796c-.083-3.907-.202-9.298-.333-14.96l.196-.005a8404 8404 0 0 1 .43 19.559l.023 1.18.004.262v.05l-.001.008a.18.18 0 0 1-.093.083.18.18 0 0 1-.1-.08l-.002-.007v-.007l-.001-.02h.001v-.025l-.004-.26-.023-1.18zm.126 6.063a.2.2 0 0 1 .093-.08.2.2 0 0 1 .097.073zm.194.01v-.001zM130.917 60.007c-.084-3.912-.203-9.29-.334-14.911l.197-.004a10935 10935 0 0 1 .432 19.528l.024 1.198.004.271.001.05v.008l-.004.02c-.054.062-.17.035-.189-.002l-.003-.015-.001-.005v-.053000000000000005l-.005-.27-.024-1.198c-.022-1.071-.055-2.66-.098-4.617m.129 6.12.193-.006-.001-.006c-.02-.037-.135-.063-.19-.002zM128.613 59.401c-.086-3.923-.206-9.285-.335-14.834l.197-.005a9890 9890 0 0 1 .459 20.704l.005.284.001.055v.008l-.001.006a.18.18 0 0 1-.094.087.2.2 0 0 1-.1-.082l-.001-.007-.001-.017h.001l-.001-.047-.005-.283-.025-1.221zm.131 6.199.195-.007a.2.2 0 0 0-.1-.081.2.2 0 0 0-.095.086zM126.303 58.977c-.087-3.938-.207-9.284-.334-14.744l.196-.005c.127 5.46.248 10.807.335 14.744l.102 4.688.032 1.545.001.061v.012l-.001.009c-.005.02-.109.084-.191.017l-.004-.02v-.008l-.001-.007h.001v-.001l-.001-.06-.006-.296-.026-1.248zm.136 6.292.195-.007-.004-.018c-.081-.066-.186-.003-.19.017zM124.002 58.73c-.088-3.958-.209-9.292-.334-14.653l.196-.004a14129 14129 0 0 1 .439 19.391l.028 1.28.006.312.002.068v.015l-.002.014c-.08.078-.19.014-.194-.004l-.001-.007v-.009000000000000001l.196-.006v-.005c-.005-.018-.114-.082-.194-.004l-.002.014v.001-.007l-.001-.066-.006-.312-.028-1.28zM121.709 58.698c-.09-3.97-.211-9.281-.333-14.54l.196-.005a15731 15731 0 0 1 .44 19.316l.029 1.306.006.327.002.074v.021a.2.2 0 0 1-.021.056.17.17 0 0 1-.175-.05v-.006l-.001-.004.197-.007-.001-.003a.16.16 0 0 0-.174-.05.2.2 0 0 0-.021.056v.003l-.001-.013-.001-.073-.007-.326-.028-1.307zM119.414 58.855c-.091-3.986-.212-9.28-.332-14.44l.196-.005c.12 5.16.242 10.454.333 14.44l.109 4.818.03 1.336.008.34.001.082.001.017v.006c0 .004-.098.096-.196.009l-.001-.007v-.002l.197-.006-.001-.006c-.098-.087-.196.005-.196.01v.001-.018000000000000002l-.002-.081-.007-.34-.03-1.336zM116.797 44.873l.196-.004.489 21.033h-.01l-.186.005z",clipRule:"evenodd"})),At||(At=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"M133.317 67.22c-5.153-1.86-10.563-2.237-15.85-.939a.388.388 0 1 1-.188-.754c5.447-1.338 11.016-.948 16.306.963a.388.388 0 1 1-.268.73M133.267 64.222c-5.159-1.867-10.574-2.245-15.866-.946a.388.388 0 1 1-.189-.754c5.454-1.34 11.027-.947 16.323.97a.387.387 0 0 1 .234.498.39.39 0 0 1-.502.232M133.204 61.217c-5.162-1.867-10.576-2.245-15.866-.946a.393.393 0 0 1-.475-.284.39.39 0 0 1 .287-.47c5.45-1.339 11.023-.946 16.323.97a.39.39 0 0 1 .234.498.393.393 0 0 1-.503.232M133.134 58.212c-5.163-1.866-10.576-2.245-15.866-.946a.388.388 0 1 1-.189-.755c5.451-1.338 11.024-.945 16.323.97a.386.386 0 0 1 .234.499.39.39 0 0 1-.502.232M133.071 55.213c-5.163-1.872-10.584-2.252-15.881-.95a.388.388 0 1 1-.189-.754c5.459-1.342 11.038-.947 16.339.974a.39.39 0 0 1 .234.498.393.393 0 0 1-.503.232M133.001 52.208c-5.164-1.87-10.584-2.251-15.882-.95a.389.389 0 1 1-.188-.755c5.458-1.34 11.038-.945 16.339.975a.388.388 0 1 1-.269.73",clipRule:"evenodd"})),jt||(jt=a.createElement("path",{fill:"#B8BDB9",d:"M116.886 44.87c5.378-1.32 10.878-.934 16.11.963l.054 2.999c-5.227-1.891-10.721-2.276-16.094-.957z"})),Mt||(Mt=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"m117.284 45.176.051 2.21c5.118-1.161 10.331-.806 15.312.893l-.039-2.17c-4.989-1.759-10.21-2.127-15.324-.934m-.494-.682c5.459-1.341 11.038-.947 16.339.975l.253.091.069 3.832-.536-.194c-5.159-1.867-10.574-2.245-15.866-.945l-.475.116-.089-3.8z",clipRule:"evenodd"})),St||(St=a.createElement("path",{fill:"#EBEEF0",fillRule:"evenodd",d:"M137.87 60.692a7073 7073 0 0 1-.362-14.961l.196-.005a8741 8741 0 0 0 .48 19.558l.04 1.44v.025h.001l.001.02-.001.003v.012a.2.2 0 0 1-.097.084.18.18 0 0 1-.097-.08l-.002-.008v-.003l-.002-.046-.008-.262-.032-1.18c-.028-1.06-.068-2.644-.117-4.597m.352 6.057a.2.2 0 0 0-.096-.076.2.2 0 0 0-.093.078zm-.193.018v.001zM140.148 59.798c-.098-3.912-.228-9.29-.359-14.91l.196-.005a10307 10307 0 0 0 .507 20.724l.008.27.001.036h.001v.023l-.002.015c-.018.038-.132.07-.189.01l-.005-.02v-.008l-.002-.05-.008-.27-.032-1.199c-.027-1.07-.068-2.66-.116-4.616m.352 6.115-.003-.014c-.057-.06-.172-.027-.189.01l-.001.006zM142.426 59.088c-.097-3.923-.227-9.285-.356-14.835l.197-.004c.129 5.55.258 10.911.355 14.834l.116 4.647.032 1.22.008.284.002.047v.024a.2.2 0 0 1-.096.086.2.2 0 0 1-.099-.082l-.001-.006v-.008l-.002-.055-.008-.284-.032-1.22zm.353 6.193v-.002a.2.2 0 0 0-.099-.082.18.18 0 0 0-.095.086zM144.711 58.559c-.096-3.937-.225-9.283-.352-14.744l.197-.004c.127 5.46.255 10.806.351 14.743l.115 4.688.032 1.247.008.297.002.059v.001h.001v.011000000000000001l-.001.004-.003.02c-.078.07-.186.012-.191-.008l-.002-.01v-.011l-.002-.06-.008-.298-.032-1.248zm.353 6.287-.001-.008c-.006-.02-.113-.078-.191-.008l-.004.018zm-.196.007",clipRule:"evenodd"})),bt||(bt=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M137.979 66.391c5.195-2.149 10.74-2.792 16.244-1.703a.389.389 0 1 1-.153.762c-5.342-1.057-10.728-.435-15.789 1.659a.394.394 0 0 1-.513-.21.39.39 0 0 1 .211-.508M137.889 63.393c5.201-2.155 10.751-2.8 16.261-1.71a.39.39 0 0 1 .308.457.39.39 0 0 1-.461.305c-5.348-1.058-10.739-.434-15.806 1.665a.39.39 0 0 1-.512-.209.387.387 0 0 1 .21-.508M137.823 60.389c5.2-2.155 10.749-2.8 16.256-1.71a.388.388 0 1 1-.153.762c-5.345-1.057-10.735-.434-15.801 1.665a.394.394 0 0 1-.513-.21.39.39 0 0 1 .211-.508M137.749 57.383c5.2-2.154 10.748-2.8 16.256-1.71a.388.388 0 1 1-.154.762c-5.344-1.057-10.735-.433-15.8 1.665a.393.393 0 0 1-.513-.209.39.39 0 0 1 .211-.508M137.663 54.385c5.206-2.16 10.761-2.807 16.276-1.716a.389.389 0 1 1-.153.763c-5.352-1.06-10.75-.434-15.821 1.67a.394.394 0 0 1-.513-.208.39.39 0 0 1 .211-.509M137.596 51.38c5.206-2.16 10.762-2.808 16.277-1.716a.39.39 0 0 1 .308.457.393.393 0 0 1-.462.305c-5.352-1.06-10.749-.432-15.82 1.67a.393.393 0 0 1-.513-.208.387.387 0 0 1 .21-.508M137.542 48.368c5.201-2.154 10.751-2.8 16.26-1.71a.389.389 0 1 1-.153.763c-5.346-1.058-10.739-.434-15.805 1.665a.393.393 0 0 1-.513-.21.39.39 0 0 1 .211-.508M137.456 45.37c5.206-2.16 10.761-2.808 16.276-1.716a.39.39 0 0 1 .308.457.39.39 0 0 1-.461.306c-5.353-1.06-10.75-.434-15.821 1.67a.394.394 0 0 1-.513-.209.39.39 0 0 1 .211-.508",clipRule:"evenodd"})),Nt||(Nt=a.createElement("path",{fill:"#CBD0D3",d:"M137.608 45.729c5.139-2.133 10.618-2.768 16.049-1.693l.21 9.014c-5.434-1.075-10.91-.439-16.049 1.693z"})),Et||(Et=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"m138.005 45.986.19 8.184c4.901-1.928 10.097-2.52 15.267-1.592l-.191-8.22c-5.162-.96-10.364-.356-15.266 1.628m-.55-.616c5.206-2.16 10.765-2.807 16.277-1.716a.39.39 0 0 1 .315.372l.21 9.015a.39.39 0 0 1-.14.307.4.4 0 0 1-.329.083c-5.352-1.06-10.749-.434-15.82 1.67a.4.4 0 0 1-.365-.032.39.39 0 0 1-.178-.317l-.21-9.015a.39.39 0 0 1 .24-.367",clipRule:"evenodd"})),wt||(wt=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M159.24 49.011c.761 4.603-4.117 7.506-7.486 6.434M109.37 50.05c.001 4.55 5.159 7.83 8.838 6.226"})),Ct||(Ct=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.472,d:"m31.757 63.326-5.175 13.74a23 23 0 0 0-.534 1.593c-1.686 5.718-.919 11.872 1.862 17.155l4.678 8.598h-4.473"})),Tt||(Tt=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:1.472,d:"m39.988 67.196.768 37.221"})),Dt||(Dt=a.createElement("path",{stroke:"#1967D2",strokeLinejoin:"round",strokeWidth:2.748,d:"M31.757 63.326a27.5 27.5 0 0 0-2.058 5.225"})),Rt||(Rt=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M47.8 52.642c4.738 2.161 9.71 4.53 10.766 11.237M13.781 61.718c-2.557 3.62-6.986 9.225-5.039 14.72"})),Ot||(Ot=a.createElement("path",{fill:"#70B2F5",d:"M1.535 51.315 54.34 35.316s5.107 29.415-22.04 34.95c-.009 0-18.561 4.185-30.764-18.952"})),zt||(zt=a.createElement("path",{fill:"#77AD8C",d:"M1.535 51.315 54.34 35.316s5.107 29.415-22.04 34.95c-.009 0-18.561 4.185-30.764-18.952"})),Lt||(Lt=a.createElement("path",{fill:"#5C9271",d:"M33.856 67.557S16.354 71.503 4.163 50.52l-2.628.795C13.738 74.452 32.29 70.266 32.29 70.266c10.329-2.105 15.985-7.67 19.032-13.753-3.297 4.975-8.696 9.256-17.466 11.044"})),Bt||(Bt=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.472,d:"M45.22 104.418h-4.47"})),Pt||(Pt=a.createElement("path",{fill:"#CBD0D3",d:"M38.095 85.802c.172.861-3.494-19.049-4.776-25.49-6.736-1.845-13.604-1.284-19.746 1.959l4.776 25.49c6.143-3.243 13.01-3.804 19.746-1.96"})),Gt||(Gt=a.createElement("path",{fill:"#EBEEF0",d:"M38.129 85.796c.152.865-3.64-19.022-4.776-25.491 5.62-4.106 12.236-6.013 19.146-5.159l4.776 25.49c-6.91-.853-13.525 1.053-19.146 5.16"})),Ut||(Ut=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M34.042 76.784c-.683-3.684-1.629-8.766-2.629-14.104l.185-.033A7852 7852 0 0 1 35.233 82.2l.052.29v.011a.17.17 0 0 1-.075.093.18.18 0 0 1-.106-.06l-.003-.007v-.003l-.001-.003v-.001l-.004-.019-.003-.023-.045-.246-.204-1.113c-.184-1-.46-2.493-.802-4.335m1.057 5.717a.18.18 0 0 1 .075-.09c.05.007.09.041.103.055zM31.73 76.387A9015 9015 0 0 0 29.11 62.33l.184-.034a9008 9008 0 0 1 3.637 19.54l.055.307v.024c-.042.066-.155.058-.18.026l-.004-.013-.001-.006-.004-.016h.001l-.006-.034-.046-.255-.208-1.13zm1.068 5.77.181-.035-.002-.005c-.024-.032-.137-.04-.178.026zM29.454 76.162c-.688-3.698-1.63-8.753-2.61-13.984l.184-.033a10403 10403 0 0 1 3.636 19.517l.058.32v.008l.001.006a.18.18 0 0 1-.076.096.18.18 0 0 1-.107-.063l-.002-.006-.003-.016-.007-.045-.049-.267-.212-1.15zm1.082 5.845.183-.035a.18.18 0 0 0-.107-.063.18.18 0 0 0-.076.096zM27.204 76.11c-.69-3.712-1.631-8.752-2.596-13.898l.185-.034a13168 13168 0 0 1 3.687 19.775l.01.057.002.007v.013c0 .02-.09.095-.177.045l-.008-.023v-.003l-.002-.007-.01-.057-.051-.28-.218-1.176zm1.101 5.932.184-.035-.006-.017c-.088-.05-.177.025-.178.045zm.185-.03v-.001M24.99 76.224c-.695-3.732-1.634-8.76-2.58-13.813l.184-.033a16041 16041 0 0 1 3.637 19.486l.055.294q.008.046.011.064l.003.028c-.063.086-.176.042-.183.025l-.002-.006v-.003l-.002-.005.184-.036v-.005c-.008-.016-.12-.06-.184.026v.013999999999999999-.006l-.066-.357-.224-1.206zM22.813 76.54c-.698-3.743-1.634-8.749-2.563-13.706l.185-.034a20173 20173 0 0 1 3.701 19.818l.003.014v.005a.2.2 0 0 1-.01.057c-.09.047-.172-.018-.174-.022v-.006l-.002-.002.185-.037-.001-.003c-.001-.004-.083-.069-.173-.021a.2.2 0 0 0-.01.059l-.003-.012-.012-.07-.057-.307-.23-1.232zM20.668 77.034l-2.547-13.61.184-.034a29372 29372 0 0 1 3.69 19.733l.015.076.003.017v.005c.001.004-.077.105-.183.038l-.001-.006v-.002l.184-.035-.002-.006c-.106-.067-.184.035-.183.038v.002-.002l-.003-.016-.014-.076-.06-.32-.235-1.26zM16.023 64.202l.185-.034 3.715 19.826-.01.001-.165.03-.01.002z",clipRule:"evenodd"})),Vt||(Vt=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"M35.112 82.85c-5.163-.983-10.34-.522-15.14 1.505a.377.377 0 0 1-.493-.197.37.37 0 0 1 .198-.488c4.947-2.089 10.276-2.56 15.576-1.551a.373.373 0 0 1 .298.436.375.375 0 0 1-.44.295M34.601 80.02c-5.17-.987-10.35-.527-15.157 1.502a.377.377 0 0 1-.493-.197.37.37 0 0 1 .198-.488c4.953-2.09 10.287-2.561 15.593-1.548a.373.373 0 0 1 .299.436.375.375 0 0 1-.44.296M34.078 77.187c-5.173-.986-10.353-.526-15.157 1.501a.377.377 0 0 1-.493-.197.37.37 0 0 1 .198-.488c4.95-2.09 10.283-2.56 15.593-1.547a.373.373 0 1 1-.141.731M33.547 74.355c-5.173-.986-10.354-.527-15.157 1.5a.377.377 0 0 1-.493-.196.37.37 0 0 1 .198-.489c4.95-2.089 10.282-2.559 15.593-1.547a.373.373 0 0 1 .298.436.375.375 0 0 1-.44.296M33.023 71.527c-5.175-.991-10.362-.532-15.172 1.5a.377.377 0 0 1-.493-.197.37.37 0 0 1 .198-.489c4.957-2.093 10.296-2.563 15.609-1.545a.373.373 0 1 1-.142.73M32.492 68.695c-5.175-.99-10.362-.532-15.172 1.5a.377.377 0 0 1-.494-.198.37.37 0 0 1 .198-.488c4.957-2.093 10.297-2.562 15.61-1.546a.373.373 0 1 1-.142.732",clipRule:"evenodd"})),Ft||(Ft=a.createElement("path",{fill:"#B8BDB9",d:"M16.109 64.187c4.884-2.062 10.147-2.527 15.39-1.523l.515 2.83c-5.238-1-10.495-.535-15.374 1.525z"})),Wt||(Wt=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"m16.538 64.414.39 2.084c4.663-1.872 9.65-2.323 14.625-1.468l-.373-2.047c-4.991-.91-9.988-.47-14.642 1.431m-.572-.57c4.957-2.093 10.297-2.563 15.609-1.545l.253.048.658 3.614-.538-.102c-5.169-.987-10.35-.527-15.157 1.502l-.43.182-.672-3.582z",clipRule:"evenodd"})),Ht||(Ht=a.createElement("path",{fill:"#EBEEF0",fillRule:"evenodd",d:"M38.41 75.985c-.698-3.682-1.656-8.762-2.656-14.1l.185-.033a7932 7932 0 0 0 3.477 18.43l.26 1.357.005.023h.001l.004.022v.011a.17.17 0 0 1-.077.094.18.18 0 0 1-.105-.06l-.003-.01-.009-.044-.048-.246-.212-1.112zm1.269 5.677a.2.2 0 0 0-.102-.057.2.2 0 0 0-.077.088zm-.18.046v.002zM40.426 74.796c-.697-3.687-1.652-8.755-2.645-14.053l.185-.034a9326 9326 0 0 0 3.684 19.53l.049.255.006.034h.001l.003.016v.019c-.01.04-.113.087-.176.04l-.008-.023-.001-.004-.01-.046-.049-.256c-.046-.242-.12-.624-.215-1.128zm1.278 5.732-.005-.013c-.063-.047-.166 0-.177.039v.005zM42.474 73.78c-.698-3.697-1.65-8.75-2.63-13.98l.184-.034a10586 10586 0 0 0 3.678 19.51l.05.266.01.044.003.016v.006a.18.18 0 0 1-.077.097.18.18 0 0 1-.106-.063l-.002-.006-.001-.008-.01-.051-.052-.267-.219-1.15c-.194-1.023-.48-2.532-.828-4.38m1.291 5.806v-.001a.18.18 0 0 0-.106-.063.18.18 0 0 0-.077.096zM44.553 72.934c-.7-3.71-1.647-8.748-2.612-13.895l.185-.034a13097 13097 0 0 0 3.722 19.768l.011.055v.001l.002.007v.027c-.062.078-.172.039-.181.021l-.005-.02-.011-.056a265 265 0 0 1-.277-1.456zm1.306 5.895-.002-.007c-.008-.017-.119-.057-.182.021v.018zm-.184.037",clipRule:"evenodd"})),Yt||(Yt=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M39.398 81.36c4.582-2.818 9.729-4.263 15.104-4.064.208.007.37.18.362.386a.374.374 0 0 1-.389.358c-5.217-.193-10.217 1.208-14.681 3.953a.38.38 0 0 1-.517-.12.37.37 0 0 1 .12-.513M38.848 78.538c4.587-2.825 9.738-4.273 15.12-4.074.207.007.369.18.361.386a.374.374 0 0 1-.389.358c-5.222-.193-10.227 1.211-14.695 3.962a.38.38 0 0 1-.518-.12.37.37 0 0 1 .12-.513M38.316 75.705c4.587-2.824 9.737-4.272 15.115-4.073.208.007.37.18.362.386a.374.374 0 0 1-.389.358c-5.22-.193-10.223 1.211-14.69 3.962a.38.38 0 0 1-.518-.12.37.37 0 0 1 .12-.513M37.789 72.873c4.587-2.824 9.737-4.272 15.115-4.073.207.007.37.18.362.386a.374.374 0 0 1-.389.358c-5.22-.193-10.223 1.211-14.691 3.962a.38.38 0 0 1-.517-.12.37.37 0 0 1 .12-.513M37.243 70.05c4.591-2.83 9.747-4.282 15.134-4.082.207.007.37.18.362.386a.374.374 0 0 1-.39.358c-5.227-.194-10.236 1.213-14.709 3.97a.38.38 0 0 1-.517-.12.37.37 0 0 1 .12-.513M36.712 67.216c4.591-2.829 9.747-4.281 15.134-4.08.207.007.369.18.361.385a.374.374 0 0 1-.389.358c-5.227-.194-10.236 1.214-14.71 3.97a.38.38 0 0 1-.516-.12.37.37 0 0 1 .12-.513M36.195 64.376c4.588-2.824 9.74-4.273 15.12-4.074.207.008.37.181.362.386a.374.374 0 0 1-.39.359c-5.22-.194-10.226 1.21-14.695 3.961a.38.38 0 0 1-.517-.12.37.37 0 0 1 .12-.513M35.65 61.552c4.59-2.83 9.747-4.281 15.133-4.081.207.008.37.18.362.386a.374.374 0 0 1-.39.358c-5.227-.194-10.236 1.213-14.708 3.97a.38.38 0 0 1-.518-.12.37.37 0 0 1 .12-.513",clipRule:"evenodd"})),Zt||(Zt=a.createElement("path",{fill:"#CBD0D3",d:"M35.851 61.868c4.532-2.793 9.618-4.222 14.922-4.025l1.592 8.497c-5.307-.198-10.39 1.232-14.922 4.025z"})),Qt||(Qt=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"m36.268 62.051 1.446 7.715c4.338-2.565 9.162-3.91 14.197-3.812l-1.452-7.749c-5.032-.127-9.86 1.23-14.191 3.846m-.615-.5c4.591-2.83 9.75-4.28 15.134-4.08a.375.375 0 0 1 .355.304l1.593 8.497a.37.37 0 0 1-.085.31.38.38 0 0 1-.298.13c-5.228-.195-10.237 1.212-14.71 3.97a.378.378 0 0 1-.568-.25l-1.592-8.496a.37.37 0 0 1 .171-.384",clipRule:"evenodd"})),qt||(qt=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M58.565 63.879c.876 5.566-4.736 9.076-8.612 7.78M8.738 76.438c1.616 4.56 7.623 6.458 13.652 0"})),Kt||(Kt=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:1.472,d:"M160.68 68.356c.934 6.676 1.531 14.409 0 20.996M171.536 72.568l-3.781 31.849h-4.47"})),Xt||(Xt=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.472,d:"M187.455 104.418h-4.471c.637-10.18 1.817-24.67 1.817-24.67"})),$t||($t=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M199.766 66.904c2.35 3.645 6.395 13.017 4.381 17.69M161.004 59.99c-3.656 2.734-9.85 8.336-9.904 15.127"})),Jt||(Jt=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M161.004 59.99c-3.656 2.734-9.85 8.336-9.904 15.127-.045 5.634 4.35 10.804 12.101 6.915"})),ei||(ei=a.createElement("path",{fill:"#77AD8C",d:"M188.416 36.69c5.324 1.935 9.926 5.533 12.45 10.684 5.586 11.402.195 27.178-11.38 32.714-10.499 5.032-24.499 1.152-30.83-8.532s-4.157-23.882 4.792-31.286c6.7-5.538 16.706-6.574 24.968-3.58"})),ti||(ti=a.createElement("path",{fill:"#5C9271",d:"M200.868 47.374a19.8 19.8 0 0 0-4.03-5.505c.638.885 1.2 1.822 1.68 2.8 5.587 11.402.196 27.177-11.38 32.714-9.081 4.35-20.778 2.028-27.868-4.939 6.584 9.03 20.044 12.517 30.218 7.648 11.568-5.54 16.966-21.316 11.38-32.718"})),ii||(ii=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:1.105,d:"M182.034 67.78c-2.79 3.71-7.987 4.925-11.944.505"})),si||(si=a.createElement("path",{fill:"#CBD0D3",d:"M175.979 96.185c-.089.946 2.303-20.818 2.977-27.89-6.413-3.959-13.71-5.464-21.09-3.967l-2.976 27.888c7.38-1.496 14.677.009 21.089 3.969"})),ni||(ni=a.createElement("path",{fill:"#EBEEF0",d:"M176.015 96.189c-.112.943 2.142-20.835 2.976-27.89 7.107-2.55 14.561-2.518 21.463.468l-2.976 27.888c-6.902-2.985-14.356-3.017-21.463-.466"})),oi||(oi=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M174.58 85.6c.437-4.028 1.037-9.587 1.66-15.427l.203.022a8025 8025 0 0 1-2.178 20.167l-.165 1.486-.006.048-.001.004-.002.008a.2.2 0 0 1-.107.073.2.2 0 0 1-.093-.094v-.012l.001-.003v-.001l.002-.02h.001l.003-.026.03-.268.135-1.217zm-.683 6.25a.2.2 0 0 1 .106-.07.2.2 0 0 1 .09.089zm.198.037v-.002zM172.305 84.486c.438-4.034 1.035-9.579 1.654-15.376l.203.022a10438 10438 0 0 1-2.172 20.136l-.136 1.235-.031.28-.006.05-.001.005-.001.004-.007.02c-.063.057-.179.014-.194-.027l-.001-.015.001-.006.001-.018h.001l.004-.036.032-.28.135-1.234c.121-1.104.3-2.743.518-4.76m-.688 6.31.2.019-.001-.006c-.015-.04-.13-.083-.194-.028zM170.011 83.561c.437-4.044 1.033-9.574 1.643-15.297l.203.022a10698 10698 0 0 1-2.163 20.089l-.138 1.259-.033.292-.007.057-.001.008-.001.007a.2.2 0 0 1-.109.076.2.2 0 0 1-.092-.097v-.007l.001-.018h.001l.006-.049.032-.291.138-1.258zm-.696 6.391.201.019a.2.2 0 0 0-.091-.097.2.2 0 0 0-.109.077zM167.698 82.823c.438-4.06 1.03-9.573 1.631-15.204l.202.021a14092 14092 0 0 1-2.153 20.038l-.141 1.287-.033.306-.008.063-.001.007v.004l-.002.01c-.008.02-.124.072-.199-.008-.001-.008-.002-.019-.001-.021v-.008l.001-.007v-.001l.007-.061.034-.306.14-1.287c.124-1.136.304-2.803.523-4.833m-.704 6.488.202.018-.002-.018c-.074-.08-.19-.028-.198-.008zM165.365 82.269c.44-4.083 1.03-9.583 1.62-15.111l.202.021a15535 15535 0 0 1-2.146 19.997l-.143 1.319-.035.322-.008.07-.002.015-.004.015c-.092.07-.196-.01-.198-.03v-.01l.001-.006.202.019v-.005c-.002-.02-.106-.1-.198-.03l-.004.014v.002l.001-.008.007-.068.036-.322.143-1.319zM163.009 81.934c.44-4.093 1.027-9.57 1.606-14.994l.202.021a31559 31559 0 0 1-2.135 19.918l-.146 1.348-.037.336-.008.077-.002.016-.001.006a.2.2 0 0 1-.029.055.17.17 0 0 1-.173-.075v-.007l.001-.003.202.019.001-.004c0-.005-.066-.097-.173-.075a.2.2 0 0 0-.03.055v.003l.001-.012.009-.076.037-.337.145-1.347zM160.626 81.796c.441-4.111 1.025-9.57 1.593-14.891l.203.02c-.568 5.322-1.153 10.781-1.593 14.892l-.533 4.968-.148 1.378-.038.35-.009.084-.002.018-.001.006c0 .004-.113.086-.202-.016v-.009000000000000001l.203.02v-.007c-.089-.102-.202-.02-.202-.016l-.001.002.001-.002.001-.017.009-.084.038-.35.148-1.378zM159.809 67.077l.202.02-2.315 21.692h-.01l-.182-.02h-.01z",clipRule:"evenodd"})),ri||(ri=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"M173.801 92.217c-5.049-2.588-10.56-3.683-16.171-3.04a.406.406 0 0 1-.45-.354.405.405 0 0 1 .358-.447c5.78-.662 11.454.468 16.637 3.125a.4.4 0 0 1 .174.543.41.41 0 0 1-.548.173M174.149 89.126c-5.054-2.595-10.57-3.692-16.187-3.048a.406.406 0 0 1-.45-.354.405.405 0 0 1 .358-.447c5.787-.663 11.465.47 16.654 3.134a.4.4 0 0 1 .173.543.41.41 0 0 1-.548.172M174.49 86.028c-5.059-2.594-10.575-3.691-16.188-3.048a.405.405 0 0 1-.45-.354.405.405 0 0 1 .358-.447c5.783-.662 11.461.47 16.653 3.134a.4.4 0 0 1 .174.543.407.407 0 0 1-.547.172M174.822 82.93c-5.059-2.595-10.575-3.692-16.188-3.049a.405.405 0 0 1-.45-.354.405.405 0 0 1 .358-.446c5.783-.663 11.461.47 16.653 3.133a.4.4 0 0 1 .174.543.407.407 0 0 1-.547.173M175.157 79.838c-5.059-2.6-10.581-3.7-16.202-3.055a.404.404 0 1 1-.093-.8c5.792-.665 11.476.47 16.669 3.14a.4.4 0 0 1 .174.543.41.41 0 0 1-.548.172M175.485 76.739c-5.059-2.6-10.581-3.7-16.202-3.056a.404.404 0 1 1-.093-.8c5.792-.665 11.476.472 16.67 3.14a.4.4 0 0 1 .173.543.41.41 0 0 1-.548.173",clipRule:"evenodd"})),ai||(ai=a.createElement("path",{fill:"#B8BDB9",d:"M159.902 67.086c5.707-.655 11.31.463 16.436 3.098l-.346 3.09c-5.121-2.628-10.719-3.743-16.42-3.09z"})),li||(li=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"m160.27 67.451-.243 2.28c5.417-.524 10.73.523 15.624 2.922l.251-2.237c-4.894-2.461-10.214-3.522-15.632-2.965m-.416-.765c5.792-.665 11.476.47 16.67 3.14l.247.127-.442 3.949-.526-.27c-5.054-2.594-10.571-3.691-16.187-3.047l-.504.057.419-3.919z",clipRule:"evenodd"})),ci||(ci=a.createElement("path",{fill:"#EBEEF0",fillRule:"evenodd",d:"M179.36 86.1c.423-4.031 1.009-9.591 1.632-15.431l.203.021c-.623 5.84-1.21 11.4-1.632 15.43-.211 2.015-.382 3.648-.495 4.742l-.125 1.218-.027.269-.002.025h.001l-.003.02-.001.004v.004l-.002.008a.2.2 0 0 1-.11.074.2.2 0 0 1-.09-.094v-.012l.004-.049.027-.27.125-1.217zm-.449 6.274a.2.2 0 0 0-.088-.09.2.2 0 0 0-.107.067zm-.201-.007v.001zM181.821 85.478c.424-4.035 1.01-9.582 1.628-15.378l.203.02a9453 9453 0 0 0-2.255 21.376l-.029.28-.003.036h.001l-.003.018-.001.006-.004.015c-.023.037-.145.055-.195-.013-.002-.008-.002-.02-.002-.022v-.008l.005-.052.028-.28.128-1.236zm-.457 6.334-.002-.015c-.051-.068-.172-.05-.196-.013l-.001.005zM184.261 85.047c.426-4.046 1.011-9.577 1.622-15.3l.202.021c-.61 5.723-1.195 11.254-1.621 15.3-.213 2.022-.387 3.674-.503 4.793l-.131 1.26-.03.291-.005.05h.001l-.002.017-.002.006a.2.2 0 0 1-.11.077.2.2 0 0 1-.091-.097l.001-.007v-.008l.005-.057.03-.293.131-1.26zm-.466 6.414v-.002a.2.2 0 0 0-.09-.097.2.2 0 0 0-.11.076zM186.679 84.801c.429-4.06 1.013-9.574 1.614-15.205l.202.02a14313 14313 0 0 0-2.288 21.634l-.007.061v.001h.001l-.001.008v.002l-.001.002v.003l-.006.021c-.09.062-.193-.012-.196-.033V91.3l.001-.007.006-.063.031-.306.135-1.288zm-.479 6.511v-.008c-.003-.02-.106-.095-.195-.033l-.006.018zm-.202-.018",clipRule:"evenodd"})),di||(di=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M178.707 91.973c5.63-1.53 11.417-1.465 16.931.375.212.07.327.3.255.51a.41.41 0 0 1-.515.254c-5.351-1.786-10.973-1.852-16.457-.361a.407.407 0 0 1-.499-.282.403.403 0 0 1 .285-.496M179.019 88.88c5.636-1.536 11.429-1.473 16.948.368a.403.403 0 1 1-.259.764c-5.357-1.787-10.984-1.851-16.475-.356a.403.403 0 1 1-.214-.777M179.351 85.78c5.635-1.534 11.427-1.471 16.943.369a.403.403 0 1 1-.259.764c-5.354-1.786-10.98-1.85-16.47-.356a.403.403 0 1 1-.214-.777M179.683 82.682c5.635-1.535 11.427-1.472 16.943.368a.403.403 0 1 1-.259.764c-5.354-1.786-10.98-1.85-16.469-.355a.403.403 0 1 1-.215-.777M179.994 79.588c5.643-1.54 11.442-1.479 16.966.365.213.071.327.3.255.51a.407.407 0 0 1-.515.254c-5.361-1.79-10.994-1.853-16.49-.352a.403.403 0 1 1-.216-.777M180.323 76.489c5.642-1.54 11.441-1.479 16.965.365.213.072.327.3.255.51a.407.407 0 0 1-.515.254c-5.361-1.79-10.994-1.852-16.49-.352a.403.403 0 1 1-.215-.777M180.671 73.385c5.637-1.534 11.43-1.471 16.949.37.212.071.327.3.255.51a.407.407 0 0 1-.515.254c-5.356-1.787-10.984-1.852-16.474-.357a.402.402 0 1 1-.215-.777M180.987 70.291c5.642-1.54 11.441-1.478 16.965.366.213.071.327.3.255.51a.406.406 0 0 1-.514.254c-5.362-1.79-10.995-1.853-16.491-.353a.403.403 0 1 1-.215-.777",clipRule:"evenodd"})),ui||(ui=a.createElement("path",{fill:"#CBD0D3",d:"M181.096 70.68c5.569-1.52 11.288-1.457 16.728.358l-.992 9.297c-5.443-1.817-11.159-1.88-16.728-.36z"})),gi||(gi=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"m181.469 70.997-.901 8.44c5.297-1.342 10.719-1.271 15.911.36l.905-8.477c-5.179-1.662-10.609-1.722-15.915-.323m-.482-.706c5.642-1.54 11.444-1.477 16.965.366.18.06.294.236.274.424l-.992 9.296a.404.404 0 0 1-.534.34c-5.361-1.79-10.994-1.853-16.49-.352a.41.41 0 0 1-.371-.082.4.4 0 0 1-.141-.349l.992-9.296a.4.4 0 0 1 .297-.347",clipRule:"evenodd"})),pi||(pi=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M204.146 84.595c-1.671 3.879-7.751 2.74-10.354-.297M151.096 75.116c-.045 5.635 4.349 10.805 12.1 6.915"})),mi||(mi=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.472,d:"M91.429 81.618c-.729 8.2-.457 15.965 1.975 22.796h4.47M80.227 81.238c-.76 8.178-.245 15.966 2.153 23.178h-4.478"})),hi||(hi=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M118.418 79.006c7.32 3.89 10.2 8.445 9.473 12.335M60.719 71.227c-7.51 3.313-11.627 6.373-11.627 13.398"})),fi||(fi=a.createElement("path",{fill:"#77AD8C",d:"m57.84 49.763-3.38 33.985 68.342 6.303 1.443-32.81z"})),yi||(yi=a.createElement("path",{fill:"#5C9271",d:"m57.476 82.268 2.638-32.25-2.273-.255-3.38 33.985 68.341 6.303.127-2.876z"})),vi||(vi=a.createElement("path",{stroke:"#161B18",strokeLinecap:"round",strokeMiterlimit:10,strokeWidth:1.105,d:"M80.625 72.749c3.832 4.721 11.357 6.736 17.468 1.896"})),_i||(_i=a.createElement("path",{fill:"#CBD0D3",d:"M86.74 98.236c-.1.945 2.55-20.79 3.308-27.852-6.365-4.035-13.644-5.624-21.041-4.213L65.7 94.023c7.397-1.41 14.676.179 21.04 4.213"})),ki||(ki=a.createElement("path",{fill:"#EBEEF0",d:"M86.776 98.24c-.123.942 2.39-20.808 3.308-27.852 7.137-2.468 14.59-2.35 21.455.717l-3.307 27.851c-6.865-3.065-14.319-3.184-21.456-.716"})),xi||(xi=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M85.467 87.637c.485-4.024 1.151-9.575 1.844-15.407l.202.023a8547 8547 0 0 1-2.418 20.141l-.192 1.544a.2.2 0 0 1-.108.072.2.2 0 0 1-.091-.095v-.017l.002-.02h.001l.004-.025.033-.268.15-1.215zm-.757 6.242a.2.2 0 0 1 .106-.069c.05.022.08.071.089.09zm.197.038v-.001zM83.205 86.496c.485-4.028 1.149-9.566 1.836-15.355l.202.023a9661 9661 0 0 1-2.561 21.343l-.042.335-.001.004-.007.02c-.065.056-.18.012-.194-.03v-.02q0-.007.002-.019l.005-.036.035-.278.15-1.233zm-.763 6.302.199.02v-.005c-.015-.041-.13-.085-.194-.03zM80.927 85.544c.485-4.04 1.146-9.561 1.825-15.277l.202.023A11321 11321 0 0 1 80.4 91.61l-.043.35-.003.014a.2.2 0 0 1-.11.076.2.2 0 0 1-.09-.1l.001-.023.007-.05.036-.29.153-1.257zm-.772 6.383.201.02a.2.2 0 0 0-.09-.097.2.2 0 0 0-.11.075zM78.619 84.779c.486-4.055 1.144-9.56 1.811-15.184l.203.024a14138 14138 0 0 1-2.593 21.664l-.001.007-.003.014c-.008.02-.124.07-.198-.01l-.002-.025v-.003l.001-.008.001-.001.008-.06.037-.306.156-1.285zm-.781 6.48.202.02-.002-.019c-.074-.08-.19-.03-.198-.01zM76.295 84.198c.488-4.077 1.144-9.57 1.8-15.091l.201.023a17205 17205 0 0 1-2.59 21.68l-.002.015-.004.014c-.093.07-.196-.012-.198-.032v-.016l.203.022v-.005c-.001-.02-.104-.101-.198-.033l-.004.015v.001l.001-.007.009-.069q.011-.1.039-.32l.158-1.318c.14-1.157.341-2.84.585-4.88M73.94 83.836c.489-4.088 1.14-9.558 1.784-14.975l.202.024a21887 21887 0 0 1-2.584 21.65l-.002.017v.005a.2.2 0 0 1-.03.055.17.17 0 0 1-.172-.077v-.01l.203.021v-.003a.17.17 0 0 0-.172-.077.2.2 0 0 0-.03.054v.004l.001-.013.01-.076.04-.336.162-1.346zM71.563 83.67l1.77-14.872.201.024a33930 33930 0 0 1-2.568 21.56l-.01.083-.002.018v.006c-.001.004-.115.084-.203-.019v-.009000000000000001l.203.022v-.006c-.088-.103-.201-.023-.202-.019v.002-.001l.002-.018.01-.083.042-.35.165-1.376zM70.918 68.942l.202.023-2.572 21.664-.01-.001-.182-.022h-.01z",clipRule:"evenodd"})),Ii||(Ii=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"M84.613 94.243c-5.017-2.647-10.516-3.805-16.133-3.227a.405.405 0 0 1-.446-.36.404.404 0 0 1 .362-.442c5.789-.596 11.448.6 16.6 3.318a.4.4 0 0 1 .167.545.41.41 0 0 1-.55.166M84.997 91.157c-5.023-2.653-10.527-3.815-16.15-3.236a.405.405 0 0 1-.446-.36.404.404 0 0 1 .363-.442c5.794-.596 11.459.603 16.615 3.327a.4.4 0 0 1 .167.545.41.41 0 0 1-.55.166M85.372 88.063c-5.028-2.653-10.53-3.814-16.15-3.236a.405.405 0 0 1-.446-.36.404.404 0 0 1 .363-.442c5.791-.595 11.455.604 16.615 3.327a.4.4 0 0 1 .167.545.41.41 0 0 1-.55.166M85.739 84.969c-5.027-2.653-10.53-3.815-16.15-3.237a.405.405 0 0 1-.446-.359.404.404 0 0 1 .363-.442c5.791-.596 11.455.603 16.615 3.326a.4.4 0 0 1 .168.545.41.41 0 0 1-.55.167M86.113 81.88c-5.027-2.658-10.536-3.822-16.165-3.243a.405.405 0 0 1-.445-.359.404.404 0 0 1 .362-.442c5.8-.598 11.47.604 16.631 3.333a.4.4 0 0 1 .167.546.41.41 0 0 1-.55.165M86.477 78.786c-5.028-2.658-10.537-3.823-16.165-3.243a.405.405 0 0 1-.446-.36.404.404 0 0 1 .362-.442c5.8-.597 11.47.606 16.632 3.334a.4.4 0 0 1 .167.545.41.41 0 0 1-.55.166",clipRule:"evenodd"})),Ai||(Ai=a.createElement("path",{fill:"#B8BDB9",d:"M71.012 68.953c5.714-.588 11.304.594 16.398 3.288l-.383 3.087c-5.09-2.688-10.674-3.868-16.383-3.28z"})),ji||(ji=a.createElement("path",{fill:"#B8BDB9",fillRule:"evenodd",d:"m71.377 69.322-.27 2.277c5.424-.461 10.724.647 15.589 3.103l.277-2.234c-4.864-2.518-10.171-3.64-15.596-3.146m-.406-.77c5.8-.597 11.47.604 16.63 3.334l.247.13-.49 3.943-.522-.276c-5.023-2.652-10.526-3.814-16.15-3.235l-.504.052.465-3.915z",clipRule:"evenodd"})),Mi||(Mi=a.createElement("path",{fill:"#EBEEF0",fillRule:"evenodd",d:"M90.243 88.191c.47-4.025 1.123-9.578 1.816-15.41l.202.023a8576 8576 0 0 0-2.367 20.146l-.172 1.51h.001l-.003.02v.006l-.001.002-.002.008a.2.2 0 0 1-.111.073.2.2 0 0 1-.089-.096v-.012l.005-.047.03-.27.14-1.216zm-.523 6.269a.2.2 0 0 0-.088-.091.2.2 0 0 0-.107.066zM92.712 87.598c.472-4.03 1.124-9.57 1.811-15.359l.203.024a9910 9910 0 0 0-2.51 21.348l-.031.279-.004.036q0 .012-.002.018v.006l-.005.015c-.024.036-.146.053-.195-.016l-.002-.021v-.009000000000000001l.006-.051.031-.28.143-1.234zm-.532 6.328q0-.007-.002-.015c-.05-.069-.171-.052-.195-.016l-.002.006zM95.154 87.195c.474-4.041 1.124-9.564 1.803-15.28l.202.023a11129 11129 0 0 0-2.509 21.325l-.038.34-.002.018-.002.007a.2.2 0 0 1-.111.075.2.2 0 0 1-.09-.098v-.007l.001-.008.007-.057.033-.293a5635.92 5635.92 0 0 1 .706-6.046m-.543 6.409v-.002c0-.007-.03-.07-.09-.099a.2.2 0 0 0-.11.075zM97.577 86.978c.477-4.056 1.126-9.562 1.794-15.186l.202.023a13877 13877 0 0 0-2.546 21.606l-.007.06v.013l-.001.004-.007.02c-.09.062-.192-.014-.195-.035v-.014l.001-.008.007-.062.035-.307.15-1.285zm-.557 6.505v-.008c-.003-.021-.104-.097-.195-.036l-.006.018zm-.202-.02",clipRule:"evenodd"})),Si||(Si=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"M89.522 94.057c5.648-1.465 11.434-1.333 16.925.57a.4.4 0 0 1 .249.514.407.407 0 0 1-.517.247c-5.33-1.848-10.95-1.978-16.452-.552a.403.403 0 1 1-.205-.78M89.865 90.967c5.655-1.47 11.446-1.34 16.943.565a.4.4 0 0 1 .249.514.407.407 0 0 1-.517.247c-5.336-1.85-10.961-1.979-16.47-.547a.403.403 0 1 1-.206-.78M90.236 87.872c5.654-1.47 11.444-1.34 16.938.565a.4.4 0 0 1 .249.513.407.407 0 0 1-.517.248c-5.333-1.849-10.957-1.978-16.464-.547a.403.403 0 1 1-.205-.78M90.603 84.776c5.654-1.469 11.444-1.339 16.939.566a.402.402 0 1 1-.269.76c-5.332-1.848-10.957-1.977-16.464-.546a.403.403 0 1 1-.206-.78M90.954 81.687c5.66-1.474 11.458-1.346 16.96.563a.4.4 0 0 1 .249.513.41.41 0 0 1-.518.247c-5.339-1.852-10.971-1.98-16.485-.544a.403.403 0 1 1-.206-.78M91.317 78.592c5.66-1.473 11.458-1.346 16.961.563a.402.402 0 1 1-.269.76c-5.34-1.852-10.972-1.979-16.486-.544a.403.403 0 1 1-.206-.78M91.705 75.492c5.654-1.469 11.447-1.339 16.943.567a.4.4 0 0 1 .249.513.407.407 0 0 1-.518.247c-5.334-1.849-10.96-1.978-16.469-.548a.403.403 0 1 1-.205-.78M92.056 72.402c5.66-1.474 11.458-1.345 16.96.563a.4.4 0 0 1 .249.513.407.407 0 0 1-.518.248c-5.34-1.852-10.972-1.98-16.485-.544a.403.403 0 1 1-.206-.78",clipRule:"evenodd"})),bi||(bi=a.createElement("path",{fill:"#CBD0D3",d:"M92.158 72.792c5.587-1.455 11.305-1.326 16.723.553l-1.103 9.284c-5.421-1.88-11.136-2.008-16.723-.553z"})),Ni||(Ni=a.createElement("path",{fill:"#CBD0D3",fillRule:"evenodd",d:"m92.53 73.113-1.002 8.43c5.313-1.28 10.734-1.147 15.906.545l1.005-8.467c-5.159-1.721-10.587-1.844-15.91-.508m-.475-.71c5.66-1.475 11.461-1.345 16.961.562.179.062.291.24.269.427l-1.103 9.285a.4.4 0 0 1-.188.294.41.41 0 0 1-.35.039c-5.339-1.852-10.971-1.98-16.485-.544a.41.41 0 0 1-.37-.086.4.4 0 0 1-.136-.35l1.102-9.285c.02-.164.139-.3.3-.343",clipRule:"evenodd"})),Ei||(Ei=a.createElement("path",{stroke:"#000",strokeLinecap:"round",strokeWidth:1.468,d:"M127.892 91.34c-1.329 7.115-12.918 8.843-24.256 0M49.088 84.625c0 6.05 9.182 11.081 24.545 3.457"}))),Ti="audience-segmentation-add-group-notice",Di="googlesitekit-audience-selection-panel-opened",Ri="audience-selection-form",Oi="audience-selected",zi="audience-selection-changed",Li="audience-selection-dismissed-items-error",Bi="audience-segmentation-creation-notice",Pi="audience-segmentation-creation-success-notice",Gi=1,Ui=3,Vi="audience-creation-edit-scope-notice",Fi="audience-creation-form";function PlaceholderTile({Widget:e}){const t=(0,c.useSelect)(e=>{const t=e(q.oR).getConfiguredAudiences();return e(Q.K9).getConfigurableAudiences().some(e=>"DEFAULT_AUDIENCE"!==e.audienceType&&!t.includes(e.name))}),i=(0,c.useSelect)(e=>e(Ve.O4).getGoogleSupportURL({path:"/analytics/answer/12799087"})),{setValue:s}=(0,c.useDispatch)(u.n),n=(0,B.jsx)(L.A,{href:i,secondary:!0,external:!0});return(0,B.jsx)(e,{className:"googlesitekit-audience-segmentation-tile-placeholder",children:(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-tile-placeholder__container",children:[(0,B.jsx)(Ci,{className:"googlesitekit-audience-segmentation-tile-placeholder__image"}),(0,B.jsxs)("div",{className:Ie()("googlesitekit-audience-segmentation-tile-placeholder__body",{"googlesitekit-audience-segmentation-tile-placeholder__body--without-selectable-audiences":!t}),children:[(0,B.jsx)(T.A,{as:"h3",type:"title",size:"small",className:"googlesitekit-audience-segmentation-tile-placeholder__title",children:t?(0,g.__)("Compare your group to other groups","google-site-kit"):(0,g.__)("Create more visitor groups","google-site-kit")}),(0,B.jsx)("p",{className:"googlesitekit-audience-segmentation-tile-placeholder__description",children:t?(0,z.A)((0,g.__)("<SelectGroupLink>Select</SelectGroupLink> another group to compare with your current group or learn more about how to group site visitors in <AnalyticsLink>Analytics</AnalyticsLink>","google-site-kit"),{AnalyticsLink:n,SelectGroupLink:(0,B.jsx)(L.A,{onClick:()=>s(Di,!0),secondary:!0})}):(0,z.A)((0,g.__)("Learn more about how to group site visitors in <AnalyticsLink>Analytics</AnalyticsLink>","google-site-kit"),{AnalyticsLink:n})})]})]})})}function MaybePlaceholderTile({Widget:e,loading:t,allTilesError:i,visibleAudienceCount:s}){return!1!==i&&!t||1!==s?null:t?(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})}):(0,B.jsx)(PlaceholderTile,{Widget:e})}function Body({activeTileIndex:e,allTilesError:t,individualTileErrors:i,loading:s,topCitiesReportsLoaded:n,topContentReportsLoaded:o,topContentPageTitlesReportsLoaded:r,visibleAudiences:l,Widget:d}){const u=(0,E.dv)(),g=(0,pe.A)(),p=u===E.mp||u===E.Lg,m=(0,c.useInViewSelect)(e=>e(Q.K9).getOrSyncAvailableAudiences(),[]),h=(0,c.useInViewSelect)(e=>e(q.oR).getConfiguredAudiences(),[]),[f,y]=(0,c.useSelect)(e=>e(Q.K9).getConfiguredSiteKitAndOtherAudiences())||[[],[]],v=(0,c.useSelect)(e=>e(Q.K9).hasAudiencePartialData(f)),_=(0,c.useInViewSelect)(e=>h?.reduce((t,i)=>(t[i]=e(Q.K9).isAudiencePartialData(i),t),{}),[h]),{report:k,reportError:x,siteKitAudiencesReport:I,totalPageviews:A,totalPageviewsReportError:j,topCitiesReport:M,topContentReport:S,topContentReportErrors:b,topContentPageTitlesReport:N,topContentPageTitlesReportErrors:w}=ee({isSiteKitAudiencePartialData:v,siteKitAudiences:f,otherAudiences:y});function C(e,t){const i=m?.filter(({name:t})=>t===e)?.[0]?.displayName||"",s=m?.filter(({name:t})=>t===e)?.[0]?.audienceSlug||"",{current:n,previous:o}=function(e){const t=f.some(t=>t.name===e),i=f.find(t=>t.name===e)?.audienceSlug;function s(s){let n;if(t&&v){const e="new-visitors"===i?"new":"returning";n=I?.rows?.find(({dimensionValues:t})=>t?.[0]?.value===e&&t?.[1]?.value===s)}else n=k?.rows?.find(({dimensionValues:t})=>t?.[0]?.value===e&&t?.[1]?.value===s);return[Number(n?.metricValues?.[0]?.value||0),Number(n?.metricValues?.[1]?.value||0),Number(n?.metricValues?.[2]?.value||0),Number(n?.metricValues?.[3]?.value||0)]}return{current:s("date_range_0"),previous:s("date_range_1")}}(e),r=n[0],a=o[0],l=n[1],c=o[1],d=n[2],u=o[2],g=n[3],p=o[3],h=M?.[t],y=S?.[t],x=N?.[t]?.rows?.reduce((e,t)=>(e[t.dimensionValues[0].value]=t.dimensionValues[1].value,e),{})||{},A=f.some(t=>t.name===e);let j=k,b=e;A&&v&&(j=I,b="new-visitors"===s?"new":"returning");const E=function(e,t){const i=e?.rows?.find(e=>e.dimensionValues?.[0]?.value===t);return 0===(i?.metricValues?.[0]?.value||0)}(j,b);return{audienceName:i,audienceSlug:s,visitors:r,prevVisitors:a,visitsPerVisitors:l,prevVisitsPerVisitors:c,pagesPerVisit:d,prevPagesPerVisit:u,pageviews:g,prevPageviews:p,topCities:h,topContent:y,topContentTitles:x,isZeroData:E,isPartialData:!A&&_[e]}}const T=Object.values(b).some(K.B)||Object.values(w).some(K.B),{dismissItem:D}=(0,c.useDispatch)(q.oR),{fetchSyncAvailableCustomDimensions:R}=(0,c.useDispatch)(Q.K9),O=(0,a.useCallback)(e=>{D(`audience-tile-${e}`)},[D]);(0,a.useEffect)(()=>{!g&&T&&R()},[R,T,g]);let z=0;return(0,B.jsxs)("div",{className:"googlesitekit-widget-audience-tiles__body",children:[t&&!s&&(0,B.jsx)(Y,{Widget:d,errors:[...Object.values(i).flat(2),x,j]}),(!1===t||s)&&l.map((t,a)=>{if(p&&a!==e)return null;const{audienceName:c,audienceSlug:u,visitors:g,prevVisitors:m,visitsPerVisitors:h,prevVisitsPerVisitors:f,pagesPerVisit:y,prevPagesPerVisit:v,pageviews:_,prevPageviews:k,topCities:x,topContent:I,topContentTitles:j,isZeroData:M,isPartialData:S}=C(t,a),b=x?.rows?(0,X.S)(x.rows):[];return!s&&n?.[t]&&o?.[t]&&r?.[t]&&void 0!==M&&void 0!==S?i[t].length>0?(0,B.jsx)(AudienceTileError,{audienceSlug:u,errors:i[t]},t):(0,B.jsx)(AudienceTile,{audienceTileNumber:z++,audienceSlug:u,title:c,infoTooltip:(0,B.jsx)(AudienceTooltipMessage,{audienceName:c,audienceSlug:u}),visitors:{currentValue:g,previousValue:m},visitsPerVisitor:{currentValue:h,previousValue:f},pagesPerVisit:{currentValue:y,previousValue:v},pageviews:{currentValue:_,previousValue:k},percentageOfTotalPageViews:0!==A?_/A:0,topCities:{dimensionValues:[b?.[0]?.dimensionValues?.[0],b?.[1]?.dimensionValues?.[0],b?.[2]?.dimensionValues?.[0]],metricValues:[b?.[0]?.metricValues?.[0],b?.[1]?.metricValues?.[0],b?.[2]?.metricValues?.[0]],total:g},topContent:{dimensionValues:[I?.rows?.[0]?.dimensionValues?.[0],I?.rows?.[1]?.dimensionValues?.[0],I?.rows?.[2]?.dimensionValues?.[0]],metricValues:[I?.rows?.[0]?.metricValues?.[0],I?.rows?.[1]?.metricValues?.[0],I?.rows?.[2]?.metricValues?.[0]]},topContentTitles:j,hasInvalidCustomDimensionError:T,Widget:d,audienceResourceName:t,isZeroData:M,isPartialData:S,isTileHideable:l.length>1,onHideTile:()=>O(t)},t):(0,B.jsx)(d,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})},t)}),!p&&(0,B.jsx)(MaybePlaceholderTile,{Widget:d,loading:s,allTilesError:t,visibleAudienceCount:l.length})]})}function Header({activeTileIndex:e,setActiveTile:t,visibleAudiences:i}){const s=(0,F.A)(),n=(0,c.useInViewSelect)(e=>e(Q.K9).getOrSyncAvailableAudiences(),[]);return(0,B.jsx)(R.TabBar,{className:"googlesitekit-widget-audience-tiles__tabs googlesitekit-tab-bar--start-aligned-high-contrast",activeIndex:e,handleActiveIndexUpdate:e=>t(i[e]),children:i.map((e,t)=>{const i=n?.filter(({name:t})=>t===e)?.[0]?.displayName||"",o=n?.filter(({name:t})=>t===e)?.[0]?.audienceSlug||"",r=(0,B.jsx)(AudienceTooltipMessage,{audienceName:i,audienceSlug:o});return(0,B.jsxs)(R.Tab,{"aria-label":i,children:[i,(0,B.jsx)(Fe.A,{title:r,tooltipClassName:"googlesitekit-info-tooltip__content--audience",onOpen:()=>{(0,V.sx)(`${s}_audiences-tile`,"view_tile_tooltip",o)}})]},t)})},i.length)}function AudienceTiles_hasZeroDataForAudience(e,t){const i=e?.rows?.find(e=>e.dimensionValues?.[0]?.value===t);return 0===(i?.metricValues?.[0]?.value||0)}function AudienceTiles({Widget:e,widgetLoading:t}){const i=(0,E.dv)(),s=i===E.mp||i===E.Lg,n=(0,c.useInViewSelect)(e=>e(q.oR).getConfiguredAudiences(),[]),o=(0,c.useInViewSelect)(e=>e(Q.K9).getOrSyncAvailableAudiences(),[]),[r,l]=(0,c.useSelect)(e=>e(Q.K9).getConfiguredSiteKitAndOtherAudiences())||[[],[]],d=(0,c.useSelect)(e=>e(Q.K9).hasAudiencePartialData(r)),{report:u,reportLoaded:g,reportError:p,siteKitAudiencesReport:m,siteKitAudiencesReportLoaded:h,siteKitAudiencesReportError:f,totalPageviewsReportLoaded:y,totalPageviewsReportError:v,topCitiesReportsLoaded:_,topCitiesReportErrors:k,topContentReportsLoaded:x,topContentReportErrors:I,topContentPageTitlesReportsLoaded:A,topContentPageTitlesReportErrors:j}=ee({isSiteKitAudiencePartialData:d,siteKitAudiences:r,otherAudiences:l}),M=n?.reduce((e,t)=>(e[t]=[],[k,I,j].forEach(i=>{const s=i[t];s&&!(0,K.B)(s)&&e[t].push(s)}),e),{}),S=(0,c.useSelect)(e=>e(q.oR).getDismissedItems()),{isDismissingItem:b}=(0,c.useSelect)(e=>e(q.oR)),{dismissItem:N}=(0,c.useDispatch)(q.oR),w=(0,a.useRef)({}),[C,T]=(0,a.useMemo)(()=>{const e=[],t=[],i=n?.slice().filter(e=>o.some(t=>t.name===e));for(;i?.length>0;){const s=i.shift(),n=S?.includes(`audience-tile-${s}`),o=r.some(e=>e.name===s);let a=u,l=s;if(o&&d){a=m;const e=r.find(e=>e.name===s)?.audienceSlug;l="new-visitors"===e?"new":"returning"}const c=AudienceTiles_hasZeroDataForAudience(a,l),g=i.length+t.length>0;n&&c&&g||(n&&!c&&e.push(s),t.push(s))}return[e,t]},[o,n,S,d,u,r,m]);const D=function(){const e=[];return u&&e.push(p),m&&e.push(f),!(!e.every(Boolean)&&!v)||n?.every(e=>M[e].length>0)}();(0,a.useEffect)(()=>{C.forEach(e=>{const t=`audience-tile-${e}`;w.current[t]||(N(t,{expiresInSeconds:1}),w.current[t]=!0)})},[C,N,b]);const R=(0,c.useSelect)(e=>e(Q.K9).isFetchingSyncAvailableCustomDimensions()),[O,z]=(0,a.useState)(T[0]),L=(0,a.useCallback)(e=>{const t=T.indexOf(e);return-1===t?0:t},[T]);(0,a.useEffect)(()=>{T.includes(O)||z(T[0])},[O,T]);const P=L(O),G=t||!g||!h||!y||!_||!x||!A||R;return(0,B.jsxs)(e,{className:"googlesitekit-widget-audience-tiles",noPadding:!0,children:[!1===D&&!G&&s&&T.length>0&&(0,B.jsx)(Header,{activeTileIndex:P,setActiveTile:z,visibleAudiences:T}),(0,B.jsx)(Body,{activeTileIndex:P,allTilesError:D,individualTileErrors:M,loading:G,topCitiesReportsLoaded:_,topContentReportsLoaded:x,topContentPageTitlesReportsLoaded:A,visibleAudiences:T,Widget:e})]})}MaybePlaceholderTile.propTypes={Widget:r().elementType.isRequired,loading:r().bool.isRequired,allTilesError:r().bool,visibleAudienceCount:r().number.isRequired},Body.propTypes={activeTileIndex:r().number.isRequired,allTilesError:r().bool.isRequired,individualTileErrors:r().object,loading:r().bool.isRequired,topCitiesReportsLoaded:r().object.isRequired,topContentReportsLoaded:r().object.isRequired,topContentPageTitlesReportsLoaded:r().object.isRequired,visibleAudiences:r().array.isRequired,Widget:r().elementType.isRequired},AudienceTiles.propTypes={Widget:r().elementType.isRequired,widgetLoading:r().bool.isRequired};var Wi=i(37226);const Hi=(0,a.forwardRef)(({className:e,children:t,Icon:i,SVGGraphic:s},n)=>(0,B.jsxs)("div",{ref:n,className:Ie()("googlesitekit-lean-cta-banner",e),children:[(0,B.jsxs)("div",{className:"googlesitekit-lean-cta-banner__body",children:[i&&(0,B.jsx)("div",{className:"googlesitekit-lean-cta-banner__body-icon",children:(0,B.jsx)(i,{width:"32",height:"32"})}),(0,B.jsx)("div",{className:"googlesitekit-lean-cta-banner__body-content",children:t})]}),s&&(0,B.jsx)("div",{className:"googlesitekit-lean-cta-banner__graphic",children:(0,B.jsx)(s,{})})]}));Hi.propTypes={className:r().string,children:r().node.isRequired,Icon:r().elementType,SVGGraphic:r().elementType};const Yi=Hi;var Zi=i(45472);const Qi=(0,a.forwardRef)((e,t)=>{const i=(0,F.A)(),s=(0,pe.A)(),n=(0,c.useSelect)(e=>e(q.oR).didSetAudiences()),o=(0,c.useSelect)(e=>e(Wi.i).getModuleIcon(W.L1)),r=(0,c.useSelect)(e=>e(Ve.O4).getSiteKitAdminSettingsURL({scrollTo:"visitor-groups"})),{setValue:a}=(0,c.useDispatch)(u.n),{navigateTo:l}=(0,c.useDispatch)(Zi.M),d=n?"no-longer-available":"none-selected";function p(){(0,V.sx)(`${i}_audiences-no-audiences`,"select_groups",d).finally(()=>{a(Di,!0)})}return(0,B.jsxs)(Yi,{ref:t,className:"googlesitekit-no-audience-banner",Icon:o,SVGGraphic:Ci,children:[(0,B.jsxs)(D.A,{children:[n&&(0,z.A)((0,g.__)("It looks like your visitor groups aren’t available anymore. <a>Select other groups</a>.","google-site-kit"),{a:(0,B.jsx)(L.A,{onClick:p,secondary:!0})}),!n&&(0,z.A)((0,g.__)("You don’t have any visitor groups selected. <a>Select groups</a>.","google-site-kit"),{a:(0,B.jsx)(L.A,{onClick:p,secondary:!0})})]}),!s&&(0,B.jsx)(D.A,{children:(0,z.A)((0,g.__)("You can deactivate this widget in <a>Settings</a>.","google-site-kit"),{a:(0,B.jsx)(L.A,{onClick:()=>{(0,V.sx)(`${i}_audiences-no-audiences`,"change_settings",d).finally(()=>{l(r)})},secondary:!0})})})]})}),qi=(0,U.A)(Qi);function NoAudienceBannerWidget({Widget:e,WidgetNull:t}){const i=(0,F.A)(),s=(0,c.useSelect)(e=>{const t=e(Q.K9).getOrSyncAvailableAudiences();return t?.map(e=>e.name)}),n=(0,c.useSelect)(e=>e(q.oR).getConfiguredAudiences()),o=(0,c.useSelect)(e=>e(q.oR).didSetAudiences()),r=n?.every(e=>Array.isArray(s)&&!s.includes(e));return n&&(0===n?.length||r)?(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(qi,{onInView:()=>{(0,V.sx)(`${i}_audiences-no-audiences`,"view_banner",o?"no-longer-available":"none-selected")}})}):(0,B.jsx)(t,{})}NoAudienceBannerWidget.propTypes={Widget:r().elementType.isRequired,WidgetNull:r().elementType.isRequired};const Ki=(0,l.A)({moduleName:W.L1})(NoAudienceBannerWidget);var Xi=i(84093);function AudienceTilesWidget({Widget:e}){const t=(0,c.useSelect)(e=>{const t=e(Q.K9).getOrSyncAvailableAudiences();return t?.map(e=>e.name)}),i=(0,c.useSelect)(e=>e(q.oR).getConfiguredAudiences()),s=(0,c.useSelect)(e=>e(Q.K9).hasSyncedAudiences()),n=(0,c.useSelect)(e=>e(Q.K9).isSyncingAudiences()),{clearErrors:o,maybeSyncAvailableAudiences:r,syncAvailableAudiences:l}=(0,c.useDispatch)(Q.K9),u=(0,c.useSelect)(e=>e(Q.K9).isSettingUpAudiences()),g=(0,c.useSelect)(e=>e(Q.K9).getErrorForAction("syncAvailableAudiences"));if((0,a.useEffect)(()=>{s||n||u||r()},[s,n,u,r]),g){const t=(0,d.SG)(g);return(0,B.jsx)(Y,{errors:g,Widget:e,onRetry:t?void 0:async()=>{await o("syncAvailableAudiences"),await l()},showRetryButton:!t})}const p=i?.some(e=>t?.includes(e));return p?(0,B.jsx)(AudienceTiles,{Widget:e,widgetLoading:!s||!t||!i}):s?(0,B.jsx)(Ki,{Widget:e,WidgetNull:Xi.A}):(0,B.jsx)(e,{className:"googlesitekit-widget-audience-tiles",noPadding:!0,children:(0,B.jsxs)("div",{className:"googlesitekit-widget-audience-tiles__body",children:[(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})}),(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})})]})})}AudienceTilesWidget.propTypes={Widget:r().elementType.isRequired,WidgetNull:r().elementType.isRequired};const $i=(0,l.A)({moduleName:W.L1})(AudienceTilesWidget);var Ji,es=i(68869),ts=i(3183),is=i(98652),ss=i(718);function AudienceItem({slug:e,title:t,description:i,subtitle:s,userCount:n,audienceType:o}){const r=`${Q.bz}${e}`,l=(0,Qe.A)(Ri,Oi),d=(0,c.useSelect)(e=>e(q.oR).hasExpirableItem(r)),u=(0,c.useSelect)(e=>e(q.oR).isExpirableItemActive(r)),[p,m]=(0,c.useSelect)(e=>e(Q.K9).getAudienceUserCountReportErrors())||[],h=[];m&&h.push(m),p&&h.push(p);const{setValues:f}=(0,c.useDispatch)(Ue.s),y=(0,c.useSelect)(t=>t(q.oR).isItemDismissed(`audience-tile-${e}`)),v=(0,a.useCallback)(t=>{f(Ri,{[Oi]:t.target.checked?l.concat([e]):l.filter(t=>t!==e),[zi]:!0})},[l,f,e]),_="DEFAULT_AUDIENCE"!==o&&(!1===d||u),k=l?.includes(e),x=`audience-selection-checkbox-${e}`;function ItemBadge(){return y?(0,B.jsx)(BadgeWithTooltip,{label:(0,g.__)("Temporarily hidden","google-site-kit"),tooltipTitle:(0,g.__)("Site Kit is collecting data for this group. Once data is available the group will be added to your dashboard.","google-site-kit")}):_?(0,B.jsx)(is.A,{}):null}return(0,B.jsx)(ss.y3,{id:x,slug:e,title:t,subtitle:s,description:i,isItemSelected:k,onCheckboxChange:v,suffix:h.length?"-":(0,V.Eo)(n),badge:(y||_)&&(0,B.jsx)(ItemBadge,{})})}function AudienceItemPreviewBlock(){return(0,B.jsxs)("div",{className:"googlesitekit-selection-panel__loading",children:[(0,B.jsxs)("div",{className:"googlesitekit-selection-panel__loading-left",children:[(0,B.jsx)(me.A,{width:"90px",height:"20px",className:"googlesitekit-selection-panel__loading-item"}),(0,B.jsx)(me.A,{width:"293px",height:"15px",className:"googlesitekit-selection-panel__loading-item"})]}),(0,B.jsx)("div",{className:"googlesitekit-selection-panel__loading-right",children:(0,B.jsx)(me.A,{width:"43px",height:"20px",className:"googlesitekit-selection-panel__loading-item"})})]})}function ns(){return ns=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},ns.apply(null,arguments)}AudienceItem.propTypes={slug:r().string.isRequired,title:r().string.isRequired,description:r().string.isRequired,subtitle:r().string,userCount:r().number.isRequired,audienceType:r().string.isRequired};const os=e=>a.createElement("svg",ns({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 23 22"},e),Ji||(Ji=a.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M11.5 22q-2.283 0-4.29-.852a11.3 11.3 0 0 1-3.492-2.366 11.3 11.3 0 0 1-2.365-3.492A10.9 10.9 0 0 1 .5 11q0-2.283.853-4.29a11.3 11.3 0 0 1 2.364-3.492A10.9 10.9 0 0 1 7.21.88 10.6 10.6 0 0 1 11.5 0q2.283 0 4.29.88a10.9 10.9 0 0 1 3.492 2.337q1.486 1.486 2.338 3.493.88 2.007.88 4.29t-.88 4.29a10.9 10.9 0 0 1-2.338 3.492q-1.485 1.485-3.492 2.366A10.9 10.9 0 0 1 11.5 22m0-14.3q.468 0 .77-.303.33-.33.33-.797a1 1 0 0 0-.33-.77 1 1 0 0 0-.77-.33q-.467 0-.797.33a1.04 1.04 0 0 0-.303.77q0 .468.303.798.33.302.797.302m-1.1 8.8V9.9h2.2v6.6z",clipRule:"evenodd"})));var rs;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 ls=e=>a.createElement("svg",as({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),rs||(rs=a.createElement("path",{fill:"currentColor",d:"M10 18.333q-.687 0-1.188-.479a1.66 1.66 0 0 1-.479-1.188h3.334q0 .689-.5 1.188-.48.48-1.167.48Zm-3.333-2.5v-1.667h6.666v1.667zm.208-2.5a6.5 6.5 0 0 1-2.292-2.292Q3.75 9.604 3.75 7.916q0-2.604 1.813-4.416Q7.393 1.667 10 1.667q2.604 0 4.417 1.833 1.833 1.812 1.833 4.417a6 6 0 0 1-.854 3.124 6.3 6.3 0 0 1-2.271 2.292zm.5-1.667h5.25a4.5 4.5 0 0 0 1.438-1.645q.52-.98.52-2.105 0-1.915-1.333-3.25Q11.917 3.334 10 3.333c-1.917-.001-2.361.445-3.25 1.333q-1.333 1.335-1.333 3.25 0 1.125.5 2.105a4.7 4.7 0 0 0 1.458 1.645"}))),cs=(0,a.forwardRef)(({className:e,content:t,dismissLabel:i,Icon:s=ls,onDismiss:n},o)=>(0,B.jsxs)("div",{ref:o,className:Ie()("googlesitekit-audience-segmentation-info-notice",e),children:[(0,B.jsx)(s,{width:"20",height:"20"}),(0,B.jsxs)("div",{className:"googlesitekit-audience-segmentation-info-notice__body",children:[(0,B.jsx)(D.A,{children:t}),i&&(0,B.jsx)(R.Button,{onClick:n,className:"googlesitekit-audience-segmentation-info-notice__dismiss",tertiary:!0,children:i})]})]}));cs.propTypes={className:r().string,content:r().string.isRequired,dismissLabel:r().string,Icon:r().elementType,onDismiss:r().func};const ds=cs;function AddGroupNotice(){const[e,t]=(0,a.useState)(!1),i=(0,c.useInViewSelect)(e=>e(q.oR).isItemDismissed(Ti)),s=(0,c.useSelect)(e=>e(u.n).getValue(Di)),n=(0,c.useSelect)(e=>e(Q.K9).isFetchingSyncAvailableAudiences()),o=(0,Qe.A)(Ri,Oi),{dismissItem:r}=(0,c.useDispatch)(q.oR),l=(0,a.useCallback)(async()=>{await r(Ti)},[r]);return(0,a.useEffect)(()=>{Array.isArray(o)&&(o.length>1&&t(!0),s||1!==o?.length||t(!1))},[o,s,t]),i||e||n||!o?.length?null:(0,B.jsx)(ds,{className:"googlesitekit-audience-selection-panel__add-group-notice",content:(0,g.__)("By adding another group to your dashboard, you will be able to compare them and understand which content brings back users from each group","google-site-kit"),dismissLabel:(0,g.__)("Got it","google-site-kit"),Icon:os,onDismiss:l})}AddGroupNotice.propTypes={savedItemSlugs:r().array};var us=i(72545),gs=i(2390),ps=i(80035);function AudienceCreationErrorNotice({apiErrors:e,hasOAuthError:t}){const i=(0,F.A)(),s=Array.isArray(e)?e:[e],n=(0,c.useSelect)(e=>e(Ve.O4).getErrorTroubleshootingLinkURL({code:"analytics-4_insufficient_permissions"})),o=(0,c.useSelect)(e=>e(Q.K9).getServiceEntityAccessURL()),r=(0,c.useSelect)(e=>e(Ve.O4).getErrorTroubleshootingLinkURL({code:"access_denied"})),l=(0,c.useSelect)(e=>e(u.n).getValue(Di)),p=s.length>0,m=s.some(e=>(0,d.SG)(e));if((0,a.useEffect)(()=>{if(!l||!p&&!t)return;let e="setup_error";t?e="auth_error":m&&(e="insufficient_permissions_error"),(0,V.sx)(`${i}_audiences-sidebar-create-audiences`,e)},[p,m,t,l,i]),!s.length&&!t)return null;let h,f;return t?f=(0,z.A)((0,g.__)("Setup was interrupted because you didn’t grant the necessary permissions. Click on Create again to retry. If that doesn’t work, <HelpLink />","google-site-kit"),{HelpLink:(0,B.jsx)(L.A,{href:r,external:!0,hideExternalIndicator:!0,children:(0,g.__)("get help","google-site-kit")})}):m?(h=(0,g.__)("Insufficient permissions","google-site-kit"),f=(0,z.A)((0,g.__)("Contact your administrator. Trouble getting access? <HelpLink />","google-site-kit"),{HelpLink:(0,B.jsx)(L.A,{href:n,external:!0,hideExternalIndicator:!0,children:(0,g.__)("Get help","google-site-kit")})})):(h=(0,g.__)("Analytics update failed","google-site-kit"),f=(0,g.__)("Click on Create to try again.","google-site-kit")),(0,B.jsx)(ps.A,{className:"googlesitekit-audience-creation-error-notice",type:ps.A.TYPES.ERROR,title:h,description:f,ctaButton:m?{label:(0,g.__)("Request access","google-site-kit"),href:o,onClick:()=>{(0,V.sx)(`${i}_audiences-sidebar-create-audiences`,"insufficient_permissions_error_request_access")}}:void 0,hideIcon:!0})}function AudienceCreationNotice(){const e=(0,F.A)(),[t,s]=(0,a.useState)(!1),n=(0,c.useInViewSelect)(e=>{const{getConfigurableAudiences:t}=e(Q.K9),i=t();if(void 0!==i)return i.length?i.filter(({audienceType:e})=>"SITE_KIT_AUDIENCE"===e):[]}),{dismissItem:o}=(0,c.useDispatch)(q.oR),{setValue:r}=(0,c.useDispatch)(u.n),l=(0,c.useInViewSelect)(e=>e(q.oR).isItemDismissed(Bi)),p=(0,c.useInViewSelect)(e=>e(q.oR).isItemDismissed(Vi)),m=(0,c.useInViewSelect)(e=>e(q.oR).hasScope(Q.S9)),h=(0,c.useSelect)(e=>e(u.n).getValue(Di));const f=(0,Ge.F)(i.g.location.href,{notification:"audience_segmentation"}),{setValues:y}=(0,c.useDispatch)(Ue.s),{setPermissionScopeError:v}=(0,c.useDispatch)(q.oR),{createAudience:_,syncAvailableAudiences:k}=(0,c.useDispatch)(Q.K9),x=(0,Qe.A)(Fi,"autoSubmit"),I=(0,Qe.A)(Fi,"audienceToCreate"),[A,j]=(0,a.useState)([]),M=(0,a.useCallback)(async e=>{if(s(e),!m)return y(Fi,{autoSubmit:!0,audienceToCreate:e}),void v({code:d.db,message:(0,g.__)("Additional permissions are required to create a new audience in Analytics.","google-site-kit"),data:{status:403,scopes:[Q.S9],skipModal:!0,redirectURL:f}});y(Fi,{autoSubmit:!1,audienceToCreate:void 0});const{error:t}=await _(Q.fB[e]);j(t?[t]:[]),await k(),s(!1),t||r(Pi,!0)},[m,_,k,y,v,f,r]);const S=(0,c.useSelect)(e=>e(Ve.O4).getSetupErrorCode()),b=x&&"access_denied"===S;(0,a.useEffect)(()=>{!async function(){m&&x&&(r(Di,!0),await M(I))}()},[I,M,m,x,r]);const N=!l&&n?.length<2;if((0,a.useEffect)(()=>{h&&N&&(0,V.sx)(`${e}_audiences-sidebar-create-audiences`,"view_notice")},[h,N,e]),(0,a.useEffect)(()=>{!h||m||p||(0,V.sx)(`${e}_audiences-sidebar-create-audiences`,"view_oauth_notice")},[m,p,h,e]),!N)return null;const E=Object.keys(Q.fB).filter(e=>!n.some(t=>t.audienceSlug===e));return(0,B.jsxs)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice",children:[(0,B.jsxs)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-header",children:[(0,B.jsx)("p",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-title",children:(0,g.__)("Create groups suggested by Site Kit","google-site-kit")}),(0,B.jsx)(L.A,{className:"googlesitekit-audience-selection-panel__audience-creation-notice-close",onClick:function(){o(Bi)},linkButton:!0,children:(0,B.jsx)(us.A,{width:"15",height:"15"})})]}),(0,B.jsx)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-body",children:E&&E.map(i=>(0,B.jsxs)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-audience",children:[(0,B.jsxs)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-audience-details",children:[(0,B.jsx)(T.A,{as:"h3",type:"title",size:"small",children:Q.fB[i].displayName}),(0,B.jsx)("p",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-audience-description",children:Q.fB[i].description})]}),(0,B.jsx)("div",{className:"googlesitekit-audience-selection-panel__audience-creation-notice-audience-button",children:(0,B.jsx)(gs.A,{spinnerPosition:gs.k.BEFORE,onClick:()=>{(0,V.sx)(`${e}_audiences-sidebar-create-audiences`,"create_audience",i).finally(()=>{M(i)})},isSaving:t===i,children:(0,g.__)("Create","google-site-kit")})})]},i))}),!m&&!p&&(0,B.jsx)(ps.A,{type:ps.A.TYPES.WARNING,description:(0,g.__)("Creating these groups require more data tracking. You will be directed to update your Analytics property.","google-site-kit"),dismissButton:{onClick:function(){(0,V.sx)(`${e}_audiences-sidebar-create-audiences`,"dismiss_oauth_notice").finally(()=>{o(Vi)})}},hideIcon:!0}),(A.length>0||b)&&(0,B.jsx)(AudienceCreationErrorNotice,{apiErrors:A,hasOAuthError:b})]})}function AudienceItems({savedItemSlugs:e=[]}){const[t,i]=(0,a.useState)(!0),{setExpirableItemTimers:s}=(0,c.useDispatch)(q.oR),{syncAvailableAudiences:n}=(0,c.useDispatch)(Q.K9),o=(0,pe.A)(),r=(0,c.useSelect)(e=>e(u.n).getValue(Di)),l=(0,c.useSelect)(e=>e(Q.K9).isFetchingSyncAvailableAudiences());(0,a.useEffect)(()=>{t&&r&&(i(!1),async function(){await n()}())},[t,r,n]);const d=(0,c.useInViewSelect)(e=>{const{getConfigurableAudiences:t,getReport:i,getAudiencesUserCountReportOptions:s,getConfigurableSiteKitAndOtherAudiences:n,hasAudiencePartialData:o}=e(Q.K9),r=t();if(void 0===r)return;if(!r.length)return[];const[a,l]=n(),c=o(a),d=e(q.oR).getDateRangeDates({offsetDays:Q.f2}),u=c&&i({...d,metrics:[{name:"totalUsers"}],dimensions:[{name:"newVsReturning"}],reportID:"audience-segmentation_audience-items_component_newVsReturningReport"}),g=!1===c||!0===c&&l?.length>0?i(s(c?l:r)):{},{rows:p=[]}=u||{},{rows:m=[]}=g||{};function h(e,t){return e.find(e=>e?.dimensionValues?.[0]?.value===t)}return r.map(e=>{let t;return t="SITE_KIT_AUDIENCE"===e.audienceType&&c?h(p,"new-visitors"===e.audienceSlug?"new":"returning"):h(m,e.name),{...e,userCount:Number(t?.metricValues?.[0]?.value)||0}})});function p(e,{audienceType:t,description:i,displayName:s,name:n,userCount:o}){let r="";switch(t){case"DEFAULT_AUDIENCE":r=(0,g.__)("Created by default by Google Analytics","google-site-kit"),i="";break;case"SITE_KIT_AUDIENCE":r=(0,g.__)("Created by Site Kit","google-site-kit");break;case"USER_AUDIENCE":r=(0,g.__)("Already exists in your Analytics property","google-site-kit")}return{...e,[n]:{title:s,subtitle:i,description:r,userCount:o,audienceType:t}}}const m=d?.filter(({name:t})=>e.includes(t)).reduce(p,{}),h=d?.filter(({name:t})=>!e.includes(t)).reduce(p,{}),f=(0,c.useSelect)(e=>{if(void 0===d)return;const{hasFinishedResolution:t,hasExpirableItem:i}=e(q.oR);return t("getExpirableItems")?d.filter(({audienceType:e,name:t})=>"DEFAULT_AUDIENCE"!==e&&!i(`${Q.bz}${t}`)).map(({name:e})=>`${Q.bz}${e}`):void 0});return(0,ts.A)(()=>{r&&void 0!==f&&f.length&&s(f.map(e=>({slug:e,expiresInSeconds:4*V.Du})))},[r,s,f]),(0,B.jsx)(ss.DW,{availableItemsTitle:(0,g.__)("Additional groups","google-site-kit"),availableSavedItems:m,availableUnsavedItems:h,ItemComponent:l?AudienceItemPreviewBlock:AudienceItem,savedItemSlugs:e,notice:(0,B.jsxs)(a.Fragment,{children:[(0,B.jsx)(AddGroupNotice,{}),!o&&(0,B.jsx)(AudienceCreationNotice,{})]})})}function RequestAccessButton({requestAccessURL:e}){const t=(0,F.A)();return(0,B.jsx)(R.Button,{className:"googlesitekit-audience-selection-panel__error-notice-action",href:e,target:"_blank",onClick:()=>{(0,V.sx)(`${t}_audiences-sidebar`,"insufficient_permissions_error_request_access")},tertiary:!0,children:(0,g.__)("Request access","google-site-kit")})}function RetryButton({handleRetry:e}){const t=(0,F.A)();return(0,B.jsx)(R.Button,{className:"googlesitekit-audience-selection-panel__error-notice-action",onClick:()=>{e(),(0,V.sx)(`${t}_audiences-sidebar`,"data_loading_error_retry")},tertiary:!0,children:(0,g.__)("Retry","google-site-kit")})}function SyncErrorNotice(){const e=(0,F.A)(),t=(0,c.useSelect)(e=>e(Q.K9).getErrorForAction("syncAvailableAudiences")),[i,s]=(0,c.useInViewSelect)(e=>e(Q.K9).getAudienceUserCountReportErrors())||[],n=(0,c.useSelect)(e=>e(Ve.O4).getErrorTroubleshootingLinkURL({code:"analytics-4_insufficient_permissions"})),o=(0,c.useSelect)(e=>e(u.n).getValue(Di)),{clearError:r,syncAvailableAudiences:l}=(0,c.useDispatch)(Q.K9),p=(0,a.useCallback)(async()=>{await r("syncAvailableAudiences"),l()},[r,l]),m=[];t&&m.push(t),s&&m.push(s),i&&m.push(i);const h=m.length>0,f=m.some(e=>(0,d.SG)(e));if((0,a.useEffect)(()=>{o&&h&&(0,V.sx)(`${e}_audiences-sidebar`,f?"insufficient_permissions_error":"data_loading_error")},[h,f,o,e]),!m.length)return null;const y=[s,i].some(e=>!!e);return(0,B.jsx)(ps.A,{className:"googlesitekit-audience-selection-panel__error-notice googlesitekit-notice--error googlesitekit-notice--small googlesitekit-notice--square",type:ps.A.TYPES.ERROR,description:f?(0,z.A)((0,g.__)("Insufficient permissions, contact your administrator. Trouble getting access? <HelpLink />","google-site-kit"),{HelpLink:(0,B.jsx)(L.A,{href:n,external:!0,hideExternalIndicator:!0,children:(0,g.__)("Get help","google-site-kit")})}):(0,g.__)("Data loading failed","google-site-kit"),hideIcon:!0,children:f||y?(0,B.jsx)(O.A,{moduleSlug:"analytics-4",error:m,buttonVariant:"danger",RequestAccessButton,RetryButton,hideGetHelpLink:!0}):(0,B.jsx)(RetryButton,{handleRetry:p})})}function Footer({isOpen:e,closePanel:t,savedItemSlugs:i}){const s=(0,F.A)(),n=(0,Qe.A)(Ri,Oi),{setValues:o}=(0,c.useDispatch)(Ue.s),r=(0,c.useSelect)(e=>e(q.oR).isSavingUserAudienceSettings()),l=(0,c.useInViewSelect)(e=>{const t=e(q.oR).getDismissedItems();return t?.filter(e=>e.startsWith("audience-tile-"))}),d=(0,c.useSelect)(e=>e(Q.K9).getOrSyncAvailableAudiences()),{saveUserAudienceSettings:u,removeDismissedItems:g}=(0,c.useDispatch)(q.oR),{getConfiguredAudiences:p}=(0,c.useSelect)(q.oR),m=(0,a.useCallback)(async e=>{o(Ri,{[Li]:null});let{error:t}=await u({configuredAudiences:e});if(!t){const i=l?.filter(t=>{const i=t.replace("audience-tile-","");return!e.includes(i)})||[];e.every(e=>l?.includes(`audience-tile-${e}`))&&i.push(`audience-tile-${e[0]}`),i?.length>0&&(({error:t}=await g(...i)),t&&o(Ri,{[Li]:t}))}return{error:t}},[l,g,u,o]),h=(0,a.useCallback)(()=>{const e={USER_AUDIENCE:"user",SITE_KIT_AUDIENCE:"site-kit",DEFAULT_AUDIENCE:"default"},t=p(),i=Object.keys(e).map(i=>{const s=t.filter(e=>{const t=d?.find(({name:t})=>e===t);return t?.audienceType===i});return`${e[i]}:${s.length}`}).join(",");(0,V.sx)(`${s}_audiences-sidebar`,"audiences_sidebar_save",i)},[d,p,s]),f=(0,a.useCallback)(()=>{(0,V.sx)(`${s}_audiences-sidebar`,"audiences_sidebar_cancel")},[s]);return(0,B.jsx)(ss.gy,{savedItemSlugs:i,selectedItemSlugs:n,saveSettings:m,minSelectedItemCount:Gi,maxSelectedItemCount:Ui,isBusy:r,isOpen:e,closePanel:t,onSaveSuccess:h,onCancel:f})}function Header_Header({closePanel:e}){const t=(0,pe.A)(),i=(0,c.useSelect)(e=>e(Ve.O4).getSiteKitAdminSettingsURL({scrollTo:"visitor-groups"})),s=(0,c.useSelect)(e=>e(q.oR).isSavingUserAudienceSettings()),{navigateTo:n}=(0,c.useDispatch)(Zi.M),o=(0,a.useCallback)(()=>n(i),[i,n]);return(0,B.jsx)(ss.W4,{title:(0,g.__)("Select visitor groups","google-site-kit"),onCloseClick:e,children:!t&&(0,B.jsx)(D.A,{children:(0,z.A)((0,g.__)("You can deactivate this widget in <link><strong>Settings</strong></link>","google-site-kit"),{link:(0,B.jsx)(L.A,{onClick:o,disabled:s,secondary:!0}),strong:(0,B.jsx)("strong",{})})})})}function LearnMoreLink(){const e=(0,c.useSelect)(e=>e(Ve.O4).getGoogleSupportURL({path:"/analytics/answer/12799087"}));return(0,B.jsx)("div",{className:"googlesitekit-audience-selection-panel__learn-more",children:(0,z.A)((0,g.__)("Learn more about grouping site visitors and audiences in <link><strong>Analytics</strong></link>","google-site-kit"),{link:(0,B.jsx)(L.A,{href:e,secondary:!0,external:!0}),strong:(0,B.jsx)("strong",{})})})}AudienceCreationErrorNotice.propTypes={apiErrors:r().oneOfType([r().arrayOf(r().object),r().object,r().array]),hasOAuthError:r().bool},AudienceItems.propTypes={savedItemSlugs:r().array},RequestAccessButton.propTypes={requestAccessURL:r().string.isRequired},RetryButton.propTypes={handleRetry:r().func.isRequired},Footer.propTypes={isOpen:r().bool,closePanel:r().func.isRequired,savedItemSlugs:r().array},Header_Header.propTypes={closePanel:r().func.isRequired};var ms=i(19793);function AudienceCreationSuccessNotice(){const e=(0,F.A)(),{setValue:t}=(0,c.useDispatch)(u.n),i=(0,c.useSelect)(e=>e(u.n).getValue(Pi)),s=(0,c.useSelect)(e=>e(u.n).getValue(Di));return(0,a.useEffect)(()=>{s&&i&&(0,V.sx)(`${e}_audiences-sidebar-create-audiences-success`,"view_notification")},[s,i,e]),i?(0,B.jsxs)("div",{className:"googlesitekit-audience-selection-panel__success-notice",children:[(0,B.jsx)("div",{className:"googlesitekit-audience-selection-panel__success-notice-icon",children:(0,B.jsx)(ms.A,{width:24,height:24})}),(0,B.jsx)("p",{className:"googlesitekit-audience-selection-panel__success-notice-message",children:(0,g.__)("Visitor group created successfully!","google-site-kit")}),(0,B.jsx)("div",{className:"googlesitekit-audience-selection-panel__success-notice-actions",children:(0,B.jsx)(R.Button,{onClick:()=>{(0,V.sx)(`${e}_audiences-sidebar-create-audiences-success`,"dismiss_notification").finally(()=>{t(Pi,!1)})},tertiary:!0,children:(0,g.__)("Got it","google-site-kit")})})]}):null}var hs=i(74595),fs=i(67768);function SaveErrorNotice({savedItemSlugs:e}){const t=(0,Qe.A)(Ri,Oi),i=(0,Qe.A)(Ri,Li),s=(0,hs.ws)(e=>e(q.oR).getUserAudienceSettings()),o=(0,hs.WM)(e=>e(q.oR).getErrorForAction("saveUserAudienceSettings",[{...s,configuredAudiences:t}])),r=t?.length||0;let l;r<Gi?l=(0,g.sprintf)(/* translators: 1: Minimum number of groups that can be selected. 2: Number of selected groups. */ /* translators: 1: Minimum number of groups that can be selected. 2: Number of selected groups. */
|
||
(0,g._n)("Select at least %1$d group (%2$d selected)","Select at least %1$d groups (%2$d selected)",Gi,"google-site-kit"),Gi,r):r>Ui&&(l=(0,g.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,g.__)("Select up to %1$d groups (%2$d selected)","google-site-kit"),Ui,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 d=o||i;return c&&l&&(d={message:l}),(0,B.jsx)(fs.A,{error:d})}function Panel(){const e=(0,F.A)(),t=(0,c.useSelect)(e=>e(u.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)(Fi,"autoSubmit"),{setValues:o}=(0,c.useDispatch)(Ue.s),{setValue:r}=(0,c.useDispatch)(u.n),l=(0,a.useCallback)(()=>{o(Ri,{[Oi]:s,[zi]:!1}),(0,V.sx)(`${e}_audiences-sidebar`,"audiences_sidebar_view")},[s,o,e]),d=(0,a.useCallback)(()=>{t&&(r(Di,!1),r(Pi,!1))},[r,t]);return(0,B.jsxs)(ss.Ay,{className:"googlesitekit-audience-selection-panel",closePanel:d,isOpen:t||n,isLoading:i,onOpen:l,children:[(0,B.jsx)(Header_Header,{closePanel:d}),(0,B.jsx)(AudienceItems,{savedItemSlugs:s}),(0,B.jsx)(LearnMoreLink,{}),(0,B.jsx)(SaveErrorNotice,{savedItemSlugs:s}),(0,B.jsx)(SyncErrorNotice,{}),(0,B.jsx)(AudienceCreationSuccessNotice,{}),(0,B.jsx)(Footer,{closePanel:d,isOpen:t,savedItemSlugs:s})]})}function AudienceSelectionPanel(){const e=(0,c.useSelect)(e=>e(u.n).getValue(Di));return(0,B.jsx)(es.Ay,{value:{key:"AudienceSelectionPanel",value:!!e},children:(0,B.jsx)(Panel,{})})}var ys=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(Wi.i).isModuleConnected(W.L1))?(0,B.jsx)(ys.A,{className:"googlesitekit-audience-widget__source",name:(0,g._x)("Analytics","Service name","google-site-kit"),href:i,external:!0}):null}var vs,_s,ks,xs,Is=i(674);function ChangeGroupsLink(){const e=(0,F.A)(),t=(0,c.useInViewSelect)(e=>e(Q.K9).getConfigurableAudiences(),[]),{setValue:i}=(0,c.useDispatch)(u.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,B.jsx)(L.A,{className:"googlesitekit-widget-area__cta-link",onClick:s,leadingIcon:(0,B.jsx)(Is.A,{width:22,height:22}),secondary:!0,linkButton:!0,children:(0,g.__)("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),vs||(vs=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("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("clipPath",{id:"audience-connect-analytics-cta-graphic_svg__a"},a.createElement("path",{fill:"#fff",d:"M0 0h480v150H0z"})))),a.createElement("g",{clipPath:"url(#audience-connect-analytics-cta-graphic_svg__a)",transform:"translate(-73)"},_s||(_s=a.createElement("path",{fill:"#B8E6CA",d:"M91.722 36.579a72 72 0 0 1 7.307-6.582c24.521-19.234 44.779-19.203 72.826-15.693 18.961 2.373 30.038 11.4 55.889 9.98s32.474-7.992 64.117-5.887c25.048 1.667 36.285 6.612 58.554 18.182 20.61 10.707 39.324 29.519 48.728 54.397 16.12 42.644-12.622 119.393-51.166 123.012-27.93 2.623-50.979-28.308-79.169-21.145-17.366 4.414-27.666 22.927-41.064 35.144-15.631 14.255-49.304 13.359-67.607 5.751-17.442-7.248-34.409-21.615-40.106-42.775-4.337-16.114-5.519-35.322-17.661-50.04-14.694-17.811-23.672-25.756-28.716-49.947-4.382-21.009 5.045-40.938 18.068-54.397"})),a.createElement("mask",{id:"audience-connect-analytics-cta-graphic_svg__b",width:332,height:228,x:72,y:12,maskUnits:"userSpaceOnUse",style:{maskType:"alpha"}},ks||(ks=a.createElement("path",{fill:"#B8E6CA",d:"M91.722 36.579a72 72 0 0 1 7.307-6.582c24.521-19.234 44.779-19.203 72.826-15.693 18.961 2.373 30.038 11.4 55.889 9.98s32.474-7.992 64.117-5.887c25.048 1.667 36.285 6.612 58.554 18.182 20.61 10.707 39.324 29.519 48.728 54.397 16.12 42.644-12.622 119.393-51.166 123.012-27.93 2.623-50.979-28.308-79.169-21.145-17.366 4.414-27.666 22.927-41.064 35.144-15.631 14.255-49.304 13.359-67.607 5.751-17.442-7.248-34.409-21.615-40.106-42.775-4.337-16.114-5.519-35.322-17.661-50.04-14.694-17.811-23.672-25.756-28.716-49.947-4.382-21.009 5.045-40.938 18.068-54.397"}))),xs||(xs=a.createElement("g",{mask:"url(#audience-connect-analytics-cta-graphic_svg__b)"},a.createElement("g",{filter:"url(#audience-connect-analytics-cta-graphic_svg__c)"},a.createElement("rect",{width:112.591,height:153.065,x:125.551,y:30.171,fill:"#fff",rx:8.095})),a.createElement("rect",{width:39.014,height:7.002,x:139.555,y:93.193,fill:"#EBEEF0",rx:3.501}),a.createElement("rect",{width:14.005,height:7.002,x:139.555,y:82.189,fill:"#EBEEF0",rx:3.501}),a.createElement("rect",{width:14.005,height:7.002,x:139.555,y:118.259,fill:"#EBEEF0",rx:3.501}),a.createElement("path",{fill:"#B8E6CA",d:"M202.578 91.693a6.5 6.5 0 0 1 6.502-6.503h10.004a6.502 6.502 0 0 1 0 13.005H209.08a6.5 6.5 0 0 1-6.502-6.502"}),a.createElement("rect",{width:26.492,height:6.623,x:139.535,y:45.625,fill:"#EBEEF0",rx:3.311}),a.createElement("path",{fill:"#FFDED3",d:"M202.578 127.763a6.5 6.5 0 0 1 6.502-6.502h10.004a6.502 6.502 0 1 1 0 13.004H209.08a6.5 6.5 0 0 1-6.502-6.502"}),a.createElement("rect",{width:41.014,height:7.002,x:138.555,y:129.263,fill:"#EBEEF0",rx:3.501}),a.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.472,d:"M238.141 65.862H126.286"}),a.createElement("g",{filter:"url(#audience-connect-analytics-cta-graphic_svg__d)"},a.createElement("rect",{width:112.591,height:153.065,x:252.859,y:30.171,fill:"#fff",rx:8.095})),a.createElement("rect",{width:38.859,height:7.002,x:266.809,y:93.193,fill:"#EBEEF0",rx:3.501}),a.createElement("rect",{width:13.949,height:7.002,x:266.809,y:82.189,fill:"#EBEEF0",rx:3.501}),a.createElement("rect",{width:13.949,height:7.002,x:266.805,y:118.259,fill:"#EBEEF0",rx:3.501}),a.createElement("path",{fill:"#B8E6CA",d:"M329.582 91.693a6.5 6.5 0 0 1 6.502-6.503h9.912a6.502 6.502 0 1 1 0 13.005h-9.912a6.5 6.5 0 0 1-6.502-6.502"}),a.createElement("rect",{width:26.492,height:6.623,x:266.844,y:45.625,fill:"#EBEEF0",rx:3.311}),a.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.472,d:"M358.094 65.862H252.862"}),a.createElement("path",{fill:"#FFDED3",d:"M329.582 127.763a6.5 6.5 0 0 1 6.502-6.502h9.912a6.502 6.502 0 1 1 0 13.004h-9.912a6.5 6.5 0 0 1-6.502-6.502"}),a.createElement("rect",{width:40.852,height:7.002,x:265.812,y:129.263,fill:"#EBEEF0",rx:3.501})))));var Ms,Ss,bs,Ns;function Es(){return Es=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},Es.apply(null,arguments)}const ws=e=>a.createElement("svg",Es({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 553 146"},e),a.createElement("g",{clipPath:"url(#audience-connect-analytics-cta-graphic-tablet_svg__a)"},Ms||(Ms=a.createElement("path",{fill:"#B8E6CA",d:"M67.728 34.59a72 72 0 0 1 7.31-6.584c24.527-19.24 44.792-19.21 72.848-15.698 18.966 2.374 30.047 11.404 55.905 9.984C229.65 20.872 234.5 10.117 271 14.308S322.5-1.5 360.5 1.5s52 32 72 42 37 8.5 50 35 4 83.5-36 106-99.355 25.386-122.439 27.553c-27.938 2.624-50.995-28.317-79.194-21.151-17.371 4.415-27.674 22.934-41.076 35.155-15.636 14.258-49.319 13.362-67.627 5.752-17.448-7.25-34.42-21.622-40.118-42.788-4.338-16.119-5.521-35.333-17.667-50.056-14.698-17.816-23.679-25.763-28.725-49.961-4.382-21.016 5.047-40.95 18.074-54.414"})),a.createElement("mask",{id:"audience-connect-analytics-cta-graphic-tablet_svg__b",width:441,height:237,x:48,y:1,maskUnits:"userSpaceOnUse",style:{maskType:"alpha"}},Ss||(Ss=a.createElement("path",{fill:"#B8E6CA",d:"M67.728 34.59a72 72 0 0 1 7.31-6.584c24.527-19.24 44.792-19.21 72.848-15.698 18.966 2.374 30.047 11.404 55.905 9.984C229.65 20.872 234.5 10.117 271 14.308S322.5-1.5 360.5 1.5s52 32 72 42 37 8.5 50 35 4 83.5-36 106-99.355 25.386-122.439 27.553c-27.938 2.624-50.995-28.317-79.194-21.151-17.371 4.415-27.674 22.934-41.076 35.155-15.636 14.258-49.319 13.362-67.627 5.752-17.448-7.25-34.42-21.622-40.118-42.788-4.338-16.119-5.521-35.333-17.667-50.056-14.698-17.816-23.679-25.763-28.725-49.961-4.382-21.016 5.047-40.95 18.074-54.414"}))),bs||(bs=a.createElement("g",{filter:"url(#audience-connect-analytics-cta-graphic-tablet_svg__c)",mask:"url(#audience-connect-analytics-cta-graphic-tablet_svg__b)"},a.createElement("rect",{width:112.625,height:153.111,x:93,y:29.181,fill:"#fff",rx:8.097}),a.createElement("rect",{width:39.025,height:7.005,x:107.008,y:92.222,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:14.009,height:7.005,x:107.008,y:81.214,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:14.009,height:7.005,x:107.008,y:117.295,fill:"#EBEEF0",rx:3.502}),a.createElement("path",{fill:"#B8E6CA",d:"M170.051 90.72a6.504 6.504 0 0 1 6.504-6.504h10.007a6.504 6.504 0 0 1 0 13.009h-10.007a6.504 6.504 0 0 1-6.504-6.504"}),a.createElement("rect",{width:26.5,height:6.625,x:106.984,y:44.639,fill:"#EBEEF0",rx:3.313}),a.createElement("path",{fill:"#FFDED3",d:"M170.051 126.802a6.504 6.504 0 0 1 6.504-6.505h10.007a6.504 6.504 0 0 1 0 13.009h-10.007a6.504 6.504 0 0 1-6.504-6.504"}),a.createElement("rect",{width:41.027,height:7.005,x:106.008,y:128.303,fill:"#EBEEF0",rx:3.502}),a.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.472,d:"M205.625 64.882H93.736"}),a.createElement("rect",{width:112.625,height:153.111,x:220.348,y:29.181,fill:"#fff",rx:8.097}),a.createElement("rect",{width:38.871,height:7.005,x:234.301,y:92.222,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:13.954,height:7.005,x:234.301,y:81.214,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:13.954,height:7.005,x:234.301,y:117.295,fill:"#EBEEF0",rx:3.502}),a.createElement("path",{fill:"#B8E6CA",d:"M297.094 90.72a6.504 6.504 0 0 1 6.504-6.504h9.915a6.504 6.504 0 0 1 0 13.009h-9.915a6.504 6.504 0 0 1-6.504-6.504"}),a.createElement("rect",{width:26.5,height:6.625,x:234.332,y:44.639,fill:"#EBEEF0",rx:3.313}),a.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.472,d:"M325.613 64.882H220.349"}),a.createElement("path",{fill:"#FFDED3",d:"M297.094 126.802a6.504 6.504 0 0 1 6.504-6.505h9.915a6.504 6.504 0 0 1 0 13.009h-9.915a6.504 6.504 0 0 1-6.504-6.504"}),a.createElement("rect",{width:40.864,height:7.005,x:233.305,y:128.303,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:112.625,height:153.111,x:347.695,y:29.181,fill:"#fff",rx:8.097}),a.createElement("rect",{width:38.871,height:7.005,x:361.648,y:92.222,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:13.954,height:7.005,x:361.648,y:81.214,fill:"#EBEEF0",rx:3.502}),a.createElement("rect",{width:13.954,height:7.005,x:361.648,y:117.295,fill:"#EBEEF0",rx:3.502}),a.createElement("path",{fill:"#FFDED3",d:"M424.441 90.72a6.504 6.504 0 0 1 6.505-6.504h9.915a6.504 6.504 0 0 1 0 13.009h-9.915a6.504 6.504 0 0 1-6.505-6.504"}),a.createElement("rect",{width:26.5,height:6.625,x:361.68,y:44.639,fill:"#EBEEF0",rx:3.313}),a.createElement("path",{stroke:"#EBEEF0",strokeWidth:1.472,d:"M452.961 64.882H347.697"}),a.createElement("path",{fill:"#B8E6CA",d:"M424.441 126.802a6.505 6.505 0 0 1 6.505-6.505h9.915a6.504 6.504 0 0 1 0 13.009h-9.915a6.504 6.504 0 0 1-6.505-6.504"}),a.createElement("rect",{width:40.864,height:7.005,x:360.652,y:128.303,fill:"#EBEEF0",rx:3.502})))),Ns||(Ns=a.createElement("defs",null,a.createElement("clipPath",{id:"audience-connect-analytics-cta-graphic-tablet_svg__a"},a.createElement("path",{fill:"#fff",d:"M0 0h553v158H0z"})),a.createElement("filter",{id:"audience-connect-analytics-cta-graphic-tablet_svg__c",width:399.32,height:185.111,x:77,y:17.181,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_2898_16714"}),a.createElement("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_2898_16714",result:"shape"})))));var Cs=i(92698);function ConnectAnalyticsCTAWidget({Widget:e}){const t=(0,E.dv)()===E.Lg,i=(0,Cs.A)(W.L1),s=(0,c.useSelect)(e=>e(Wi.i).getModuleIcon(W.L1)),n=t?(0,B.jsx)(D.A,{children:(0,z.A)((0,g.__)("Google Analytics is disconnected, your audience metrics can’t be displayed. <a>Connect Google Analytics</a>","google-site-kit"),{a:(0,B.jsx)(L.A,{onClick:i,secondary:!0})})}):(0,B.jsxs)(a.Fragment,{children:[(0,B.jsx)(D.A,{children:(0,g.__)("Google Analytics is disconnected, your audience metrics can’t be displayed","google-site-kit")}),(0,B.jsx)(L.A,{onClick:i,secondary:!0,children:(0,g.__)("Connect Google Analytics","google-site-kit")})]});return(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(Yi,{Icon:s,SVGGraphic:t?ws:js,children:n})})}ConnectAnalyticsCTAWidget.propTypes={Widget:r().elementType.isRequired};const Ts=(0,U.A)(ds);function InfoNoticeWidget({Widget:e,WidgetNull:t}){const i=(0,F.A)(),s=(0,c.useInViewSelect)(e=>{const t=e(Q.K9).getOrSyncAvailableAudiences();return t?.map(e=>e.name)},[]),n=(0,c.useInViewSelect)(e=>e(q.oR).getConfiguredAudiences(),[]),o=n?.some(e=>s?.includes(e)),r=h.length,l=(0,c.useInViewSelect)(e=>e(q.oR).isPromptDismissed(m),[]),d=(0,c.useSelect)(e=>e(u.n).getValue(p)),f=(0,c.useInViewSelect)(e=>e(q.oR).getPromptDismissCount(m),[]),{dismissPrompt:y}=(0,c.useDispatch)(q.oR),v=(0,a.useCallback)(()=>{void 0!==f&&(0,V.sx)(`${i}_audiences-info-notice`,"dismiss_notice",h[f].slug).finally(()=>{const e=2*V.Du;y(m,{expiresInSeconds:f+1<r?e:0})})},[f,y,r,i]);if(!0!==o||l||void 0===f||f>=r||!0===d)return(0,B.jsx)(t,{});const{slug:_,content:k}=h[f];return(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(Ts,{content:k,dismissLabel:(0,g.__)("Got it","google-site-kit"),onDismiss:v,onInView:()=>{(0,V.sx)(`${i}_audiences-info-notice`,"view_notice",_)}})})}InfoNoticeWidget.propTypes={Widget:r().elementType.isRequired,WidgetNull:r().elementType.isRequired};const Ds=(0,l.A)({moduleName:W.L1})(InfoNoticeWidget);var Rs=i(15844);function SecondaryUserSetupWidget({Widget:e}){const[t,i]=(0,a.useState)(null),s=(0,c.useSelect)(e=>e(Q.K9).isSettingUpAudiences()),{enableSecondaryUserAudienceGroup:n}=(0,c.useDispatch)(Q.K9);return(0,Rs.A)(()=>{s||(async()=>{const{error:e}=await n();e&&i(e)})()}),t?(0,B.jsx)(Y,{Widget:e,errors:t,onRetry:async function(){i(null);const{error:e}=await n();e&&i(e)},showRetryButton:!(0,d.SG)(t)}):(0,B.jsx)(e,{className:"googlesitekit-widget-audience-tiles",noPadding:!0,children:(0,B.jsxs)("div",{className:"googlesitekit-widget-audience-tiles__body",children:[(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})}),(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})})]})})}SecondaryUserSetupWidget.propTypes={Widget:r().elementType.isRequired};var Os=i(33566);function PrimaryUserSetupWidget({Widget:e}){const{apiErrors:t,isSaving:i,failedAudiences:s,onEnableGroups:n}=(0,Os.A)(),o=(0,c.useSelect)(e=>e(Q.K9).isSettingUpAudiences());return(0,Rs.A)(()=>{o||n()}),!t.length&&!s.length||i?(0,B.jsx)(e,{className:"googlesitekit-widget-audience-tiles",noPadding:!0,children:(0,B.jsxs)("div",{className:"googlesitekit-widget-audience-tiles__body",children:[(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})}),(0,B.jsx)(e,{noPadding:!0,children:(0,B.jsx)(AudienceTileLoading,{})})]})}):(0,B.jsx)(Y,{Widget:e,errors:t,onRetry:n,failedAudiences:s,showRetryButton:!(0,d.SG)(t[0])})}PrimaryUserSetupWidget.propTypes={Widget:r().elementType.isRequired}},76422:(e,t,i)=>{i.d(t,{A:()=>OverlayNotification});var s=i(62688),n=i.n(s),o=i(50539),r=i(71423),a=i(7070),l=i(5230),c=i(4452),d=i.n(c),u=i(32947),g=i(63696),p=i(15167),m=i(62540);function Title({children:e}){return(0,m.jsx)(p.A,{as:"h3",size:"medium",type:"title",className:"googlesitekit-overlay-card__title",children:e})}function Description({children:e}){return(0,m.jsx)("p",{className:"googlesitekit-overlay-card__description",children:e})}Title.propTypes={children:n().node.isRequired},Description.propTypes={children:n().node.isRequired};var h=i(82871),f=i(49383);function DismissButton({label:e=(0,h.__)("Maybe later","google-site-kit"),onClick:t,disabled:i}){return(0,m.jsx)(f.Button,{onClick:t,disabled:i,tertiary:!0,children:e})}const y={label:n().string,onClick:n().func,disabled:n().bool};function CTAButton(e){const{label:t,...i}=e;return(0,m.jsx)(f.Button,{...i,children:t})}DismissButton.propTypes=y,CTAButton.propTypes={...y,href:n().string,target:n().string,trailingIcon:n().object};var v=i(98652);function Body({title:e,description:t,ctaButton:i,dismissButton:s,GraphicDesktop:n,GraphicMobile:o,newBadge:r}){const a=(0,u.dv)();return(0,m.jsxs)(g.Fragment,{children:[a!==u.mp&&n&&(0,m.jsx)("div",{className:"googlesitekit-overlay-card__graphic",children:(0,m.jsx)(n,{})}),(0,m.jsxs)("div",{className:"googlesitekit-overlay-card__body",children:[r&&(0,m.jsx)("div",{className:"googlesitekit-overlay-card__badge",children:(0,m.jsx)(v.A,{hasNoSpacing:!0})}),e&&(0,m.jsx)(Title,{children:e}),t&&(0,m.jsx)(Description,{children:t})]}),(i||s)&&(0,m.jsxs)("div",{className:"googlesitekit-overlay-card__actions",children:[s&&(0,m.jsx)(DismissButton,{...s}),i&&(0,m.jsx)(CTAButton,{...i})]}),a===u.mp&&o&&(0,m.jsx)(o,{})]})}function OverlayCard(e){const{visible:t,className:i,...s}=e,n=(0,u.dv)();if(!t)return null;const o=(0,m.jsx)("div",{className:d()("googlesitekit-overlay-card",i),children:(0,m.jsx)(Body,{...s})});return n===u.mp?o:(0,m.jsx)(l.A,{direction:"up",in:t,children:o})}function OverlayNotification({notificationID:e,ctaButton:t,dismissButton:i,gaTrackingEventArgs:s,...n}){const l=(0,a.A)(e,s?.category,{confirmAction:s?.confirmAction,dismissAction:s?.dismissAction}),{dismissNotification:c}=(0,o.useDispatch)(r.D);const{dismissOnClick:d,dismissOptions:u,...g}=t||{};const p=t?{...g,onClick:async function(i){l.confirm(s?.label,s?.value),await(t?.onClick?.(i)),d&&c(e,{...u})}}:void 0;return(0,m.jsx)(OverlayCard,{ctaButton:p,dismissButton:{...i,onClick:async function(t){await(i?.onClick?.(t)),l.dismiss(s?.label,s?.value),c(e,{...i.dismissOptions})}},...n,visible:!0})}Body.propTypes={title:n().node,description:n().node,ctaButton:n().shape({...y,href:n().string,target:n().string,trailingIcon:n().element}),dismissButton:n().shape({...y}),GraphicDesktop:n().elementType,GraphicMobile:n().elementType,newBadge:n().bool},OverlayCard.propTypes={className:n().string,title:n().string,description:n().oneOfType([n().string,n().object]),ctaButton:n().shape({...y,href:n().string,target:n().string,trailingIcon:n().object}),dismissButton:n().shape(y),GraphicDesktop:n().elementType,GraphicMobile:n().elementType,newBadge:n().bool,visible:n().bool},OverlayCard.defaultProps={visible:!1},OverlayNotification.propTypes={notificationID:n().string,ctaButton:n().object,dismissButton:n().oneOfType([n().object,n().bool])}},77513:(e,t,i)=>{i.d(t,{A:()=>l});var s=i(62688),n=i.n(s),o=i(90007),r=i(12850),a=i(62540);function NotificationFromServer({id:e,titleIcon:t,title:i,content:s,ctaLabel:n,ctaTarget:l,ctaURL:c,dismissible:d,dismissLabel:u,learnMoreLabel:g,learnMoreURL:p,onCTAClick:m,onDismissClick:h,gaTrackingEventArgs:f}){const y={expiresInSeconds:r.Jg};return(0,a.jsx)(o.A,{notificationID:e,type:o.Q.WARNING,titleIcon:t||void 0,title:i,description:s,learnMoreLink:p?{label:g,href:p}:void 0,ctaButton:{label:n,href:c,target:l,onClick:m,dismissOptions:y},dismissButton:d?{label:u,onClick:h,dismissOptions:y}:void 0,gaTrackingEventArgs:f})}NotificationFromServer.propTypes={id:n().string.isRequired,title:n().string.isRequired,content:n().node,ctaLabel:n().string,ctaTarget:n().string,ctaURL:n().string,dismissible:n().bool,dismissLabel:n().string,learnMoreLabel:n().string,learnMoreURL:n().string,onCTAClick:n().func,onDismissClick:n().func,gaTrackingEventArgs:n().object};const l=NotificationFromServer},77766:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s=i(63696),n=i(61991);const __WEBPACK_DEFAULT_EXPORT__=function(){return(0,s.useContext)(n.Ay)}},77967:(e,t,i)=>{i.d(t,{A:()=>ErrorNotice});var s=i(62688),n=i.n(s),o=i(63696),r=i(82871),a=i(84024),l=i(50539),c=i(67150),d=i(80035),u=i(12850),g=i(62540);function ErrorNotice({className:e,error:t,hasButton:i=!1,storeName:s,message:n=t.message,noPrefix:p=!1,skipRetryMessage:m,hideIcon:h=!1}){const f=(0,l.useDispatch)(),y=(0,l.useSelect)(e=>s?e(s).getSelectorDataForError(t):null),v=(0,o.useCallback)(()=>{f(y.storeName).invalidateResolution(y.name,y.args)},[f,y]);if(!n||(0,c.G)(t))return null;const _=i&&(0,c.vl)(t,y);let k=n;i||m||(k=(0,r.sprintf)(/* translators: %s: Error message from Google API. */ /* translators: %s: Error message from Google API. */
|
||
(0,r.__)("%s (Please try again.)","google-site-kit"),k)),p||(k=(0,r.sprintf)(/* translators: $%s: Error message */ /* translators: $%s: Error message */
|
||
(0,r.__)("Error: %s","google-site-kit"),k));const x=t?.data?.reconnectURL;x&&(0,a.m)(x)&&(k=(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"),k,x));return(0,g.jsx)(d.A,{className:e,type:d.A.TYPES.ERROR,description:(0,g.jsx)("span",{dangerouslySetInnerHTML:(0,u.p9)(k,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})}),ctaButton:_?{label:(0,r.__)("Retry","google-site-kit"),onClick:v}: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),d=i(58116),u=i(93896),g=i(71423),p=i(53137),m=i(72455),h=i(77766),f=i(68485),y=i(12850),v=i(33566),_=i(80869),k=i(34375);var x=i(99897),I=i(16196),A=i(93934),j=i(54349),M=i(49655),S=i(12108),b=i(32947),N=i(62540);const E="setup-success-notification-audiences";function AudienceSegmentationSetupSuccessSubtleNotification({id:e,Notification:t}){const s=(0,b.dv)(),{dismissNotification:n}=(0,l.useDispatch)(g.D),r=(0,l.useSelect)(e=>e(d.oR).isAudienceSegmentationWidgetHidden());return(0,a.useEffect)(()=>{r&&n(E)},[n,r]),void 0===r?null:(0,N.jsx)(t,{children:(0,N.jsx)(j.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,S.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)(g.D),{setValues:I}=(0,l.useDispatch)(c.s),A={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")},j=(0,f.i)(A),M=(0,l.useSelect)(t=>t(g.D).isNotificationDismissalFinal(e)),S=(0,w.A)(m.PW,"autoSubmit"),[b,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:O,failedAudiences:z,isSaving:L,onEnableGroups:B}=(0,v.A)({onSuccess:T,onError:D,onOAuthNavigation:R}),{clearPermissionScopeError:P}=(0,l.useDispatch)(d.oR),{setSetupErrorCode:G}=(0,l.useDispatch)(u.O4),U=(0,a.useCallback)(()=>{I(m.PW,{autoSubmit:!1}),P(),G(null),C(!1)},[P,G,I]),V=(0,l.useSelect)(e=>e(u.O4).getSetupErrorCode()),F=(0,l.useSelect)(e=>e(u.O4).getDocumentationLinkURL("visitor-groups")),W=S&&"access_denied"===V,H={gaTrackingEventArgs:{category:s}};return(0,N.jsxs)(a.Fragment,{children:[(0,N.jsx)(t,{...H,children:(0,N.jsx)(k.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:F},ctaButton:{label:L?(0,o.__)("Enabling groups","google-site-kit"):(0,o.__)("Enable groups","google-site-kit"),onClick:B,disabled:L,inProgress:L},dismissButton:{label:M?(0,o.__)("Don’t show again","google-site-kit"):(0,o.__)("Maybe later","google-site-kit"),onClick:j,disabled:L,dismissOptions:{expiresInSeconds:M?0:2*y.Du}},svg:{desktop:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDk2IiBoZWlnaHQ9IjI1MyIgdmlld0JveD0iMCAwIDQ5NiAyNTMiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMF8xNDYxXzExMzIzKSI+CjxwYXRoIGQ9Ik0zOS4wMzAzIDYwLjcwNjRDNDIuMTc1IDU3LjQ2NCA0NS40OTIxIDU0LjQ3NjMgNDguOTYwMSA1MS43NjNDODIuMjgxMiAyNS42MjUgMTA5LjgxMSAyNS42NjcgMTQ3LjkyNCAzMC40Mzc1QzE3My42OSAzMy42NjE1IDE4OC43NDMgNDUuOTI5NCAyMjMuODcxIDQ0QzI1OSA0Mi4wNzA2IDI2OCAzMy4xMzkxIDMxMSAzNS45OTk5QzM0NS4wMzggMzguMjY0NiAzNjAuMzA4IDQ0Ljk4NDYgMzkwLjU3IDYwLjcwNjRDNDE4LjU3NyA3NS4yNTY4IDQ0NC4wMDcgMTAwLjgyIDQ1Ni43ODYgMTM0LjYyOEM0NzguNjkyIDE5Mi41NzYgNDM5LjYzNCAyOTYuODcxIDM4Ny4yNTYgMzAxLjc4OEMzNDkuMzAzIDMwNS4zNTMgMzE3Ljk4MSAyNjMuMzIgMjc5LjY3MyAyNzMuMDU1QzI1Ni4wNzQgMjc5LjA1MyAyNDIuMDc4IDMwNC4yMSAyMjMuODcxIDMyMC44MTJDMjAyLjYzIDM0MC4xODMgMTU2Ljg3MiAzMzguOTY1IDEzMiAzMjguNjI4QzEwOC4yOTggMzE4Ljc3NyA4NS4yNDEgMjk5LjI1NCA3Ny41IDI3MC41QzcxLjYwNjggMjQ4LjYwMyA3MCAyMjIuNSA1My41IDIwMi41QzMzLjUzMjQgMTc4LjI5NiAyMS4zMzI4IDE2Ny41IDE0LjQ3NzYgMTM0LjYyOEM4LjUyMzg3IDEwNi4wNzggMjEuMzMzNSA3OC45OTY3IDM5LjAzMDMgNjAuNzA2NFoiIGZpbGw9IiNCOEU2Q0EiLz4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAxXzE0NjFfMTEzMjMpIj4KPG1hc2sgaWQ9Im1hc2swXzE0NjFfMTEzMjMiIHN0eWxlPSJtYXNrLXR5cGU6YWxwaGEiIG1hc2tVbml0cz0idXNlclNwYWNlT25Vc2UiIHg9IjEzIiB5PSIyNyIgd2lkdGg9IjQ1MCIgaGVpZ2h0PSIzMDkiPgo8cGF0aCBkPSJNMzkuMDMwMyA2MC43MDY0QzQyLjE3NSA1Ny40NjQgNDUuNDkyMSA1NC40NzYzIDQ4Ljk2MDEgNTEuNzYzQzgyLjI4MTIgMjUuNjI1IDEwOS44MTEgMjUuNjY3IDE0Ny45MjQgMzAuNDM3NUMxNzMuNjkgMzMuNjYxNSAxODguNzQzIDQ1LjkyOTQgMjIzLjg3MSA0NEMyNTkgNDIuMDcwNiAyNjggMzMuMTM5MSAzMTEgMzUuOTk5OUMzNDUuMDM4IDM4LjI2NDYgMzYwLjMwOCA0NC45ODQ2IDM5MC41NyA2MC43MDY0QzQxOC41NzcgNzUuMjU2OCA0NDQuMDA3IDEwMC44MiA0NTYuNzg2IDEzNC42MjhDNDc4LjY5MiAxOTIuNTc2IDQzOS42MzQgMjk2Ljg3MSAzODcuMjU2IDMwMS43ODhDMzQ5LjMwMyAzMDUuMzUzIDMxNy45ODEgMjYzLjMyIDI3OS42NzMgMjczLjA1NUMyNTYuMDc0IDI3OS4wNTMgMjQyLjA3OCAzMDQuMjEgMjIzLjg3MSAzMjAuODEyQzIwMi42MyAzNDAuMTgzIDE1Ni44NzIgMzM4Ljk2NSAxMzIgMzI4LjYyOEMxMDguMjk4IDMxOC43NzcgODUuMjQxIDI5OS4yNTQgNzcuNSAyNzAuNUM3MS42MDY4IDI0OC42MDMgNzAgMjIyLjUgNTMuNSAyMDIuNUMzMy41MzI0IDE3OC4yOTYgMjEuMzMyOCAxNjcuNSAxNC40Nzc2IDEzNC42MjhDOC41MjM4NyAxMDYuMDc4IDIxLjMzMzUgNzguOTk2NyAzOS4wMzAzIDYwLjcwNjRaIiBmaWxsPSIjQjhFNkNBIi8+CjwvbWFzaz4KPGcgbWFzaz0idXJsKCNtYXNrMF8xNDYxXzExMzIzKSI+CjxnIGZpbHRlcj0idXJsKCNmaWx0ZXIwX2RfMTQ2MV8xMTMyMykiPgo8cmVjdCB4PSI4NSIgeT0iNTIiIHdpZHRoPSIxNTMiIGhlaWdodD0iMjA4IiByeD0iMTEiIGZpbGw9IndoaXRlIi8+CjwvZz4KPHJlY3QgeD0iMTA0LjAzMSIgeT0iMTM3LjY0MSIgd2lkdGg9IjUzLjAxNTYiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTA0LjAzMSIgeT0iMTIyLjY4OCIgd2lkdGg9IjE5LjAzMTIiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTA0LjAzMSIgeT0iMTcxLjcwMyIgd2lkdGg9IjE5LjAzMTIiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTA0LjAzMSIgeT0iMjE4LjcwMyIgd2lkdGg9IjE5LjAzMTIiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHBhdGggZD0iTTE4OS42NzIgMTM1LjYwMkMxODkuNjcyIDEzMC43MjIgMTkzLjYyOCAxMjYuNzY2IDE5OC41MDggMTI2Ljc2NkgyMTIuMTAyQzIxNi45ODIgMTI2Ljc2NiAyMjAuOTM4IDEzMC43MjIgMjIwLjkzOCAxMzUuNjAyQzIyMC45MzggMTQwLjQ4MiAyMTYuOTgyIDE0NC40MzggMjEyLjEwMiAxNDQuNDM4SDE5OC41MDhDMTkzLjYyOCAxNDQuNDM4IDE4OS42NzIgMTQwLjQ4MiAxODkuNjcyIDEzNS42MDJaIiBmaWxsPSIjQjhFNkNBIi8+CjxyZWN0IHg9IjEwNCIgeT0iNzMiIHdpZHRoPSIzNiIgaGVpZ2h0PSI5IiByeD0iNC41IiBmaWxsPSIjRUJFRUYwIi8+CjxwYXRoIGQ9Ik0xODkuNjcyIDE4NC42MTdDMTg5LjY3MiAxNzkuNzM3IDE5My42MjggMTc1Ljc4MSAxOTguNTA4IDE3NS43ODFIMjEyLjEwMkMyMTYuOTgyIDE3NS43ODEgMjIwLjkzOCAxNzkuNzM3IDIyMC45MzggMTg0LjYxN0MyMjAuOTM4IDE4OS40OTcgMjE2Ljk4MiAxOTMuNDUzIDIxMi4xMDIgMTkzLjQ1M0gxOTguNTA4QzE5My42MjggMTkzLjQ1MyAxODkuNjcyIDE4OS40OTcgMTg5LjY3MiAxODQuNjE3WiIgZmlsbD0iI0ZGREVEMyIvPgo8cGF0aCBkPSJNMTg5LjY3MiAyMzEuNjE3QzE4OS42NzIgMjI2LjczNyAxOTMuNjI4IDIyMi43ODEgMTk4LjUwOCAyMjIuNzgxSDIxMi4xMDJDMjE2Ljk4MiAyMjIuNzgxIDIyMC45MzggMjI2LjczNyAyMjAuOTM4IDIzMS42MTdDMjIwLjkzOCAyMzYuNDk3IDIxNi45ODIgMjQwLjQ1MyAyMTIuMTAyIDI0MC40NTNIMTk4LjUwOEMxOTMuNjI4IDI0MC40NTMgMTg5LjY3MiAyMzYuNDk3IDE4OS42NzIgMjMxLjYxN1oiIGZpbGw9IiNCOEU2Q0EiLz4KPHJlY3QgeD0iMTAyLjY3MiIgeT0iMTg2LjY1NiIgd2lkdGg9IjU1LjczNDQiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTAyLjY3MiIgeT0iMjQzLjY1NiIgd2lkdGg9IjU1LjczNDQiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHBhdGggZD0iTTIzOCAxMDAuNUw4NiAxMDAuNSIgc3Ryb2tlPSIjRUJFRUYwIiBzdHJva2Utd2lkdGg9IjIiLz4KPGcgZmlsdGVyPSJ1cmwoI2ZpbHRlcjFfZF8xNDYxXzExMzIzKSI+CjxyZWN0IHg9IjI1OCIgeT0iNTIiIHdpZHRoPSIxNTMiIGhlaWdodD0iMjA4IiByeD0iMTEiIGZpbGw9IndoaXRlIi8+CjwvZz4KPHJlY3QgeD0iMjc2Ljk1NiIgeT0iMTM3LjY0MSIgd2lkdGg9IjUyLjgwNTMiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjc2Ljk1NiIgeT0iMTIyLjY4OCIgd2lkdGg9IjE4Ljk1NTciIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjc2Ljk1NSIgeT0iMTcxLjcwMyIgd2lkdGg9IjE4Ljk1NTciIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjc2Ljk1NSIgeT0iMjE4LjcwMyIgd2lkdGg9IjE4Ljk1NTciIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHBhdGggZD0iTTM2Mi4yNTcgMTM1LjYwMkMzNjIuMjU3IDEzMC43MjIgMzY2LjIxMyAxMjYuNzY2IDM3MS4wOTMgMTI2Ljc2NkgzODQuNTYyQzM4OS40NDIgMTI2Ljc2NiAzOTMuMzk4IDEzMC43MjIgMzkzLjM5OCAxMzUuNjAyQzM5My4zOTggMTQwLjQ4MiAzODkuNDQyIDE0NC40MzggMzg0LjU2MiAxNDQuNDM4SDM3MS4wOTNDMzY2LjIxMyAxNDQuNDM4IDM2Mi4yNTcgMTQwLjQ4MiAzNjIuMjU3IDEzNS42MDJaIiBmaWxsPSIjQjhFNkNBIi8+CjxyZWN0IHg9IjI3NyIgeT0iNzMiIHdpZHRoPSIzNiIgaGVpZ2h0PSI5IiByeD0iNC41IiBmaWxsPSIjRUJFRUYwIi8+CjxwYXRoIGQ9Ik00MDEuMDAxIDEwMC41TDI1OC4wMDEgMTAwLjUiIHN0cm9rZT0iI0VCRUVGMCIgc3Ryb2tlLXdpZHRoPSIyIi8+CjxwYXRoIGQ9Ik0zNjIuMjU2IDE4NC42MTdDMzYyLjI1NiAxNzkuNzM3IDM2Ni4yMTIgMTc1Ljc4MSAzNzEuMDkyIDE3NS43ODFIMzg0LjU2MkMzODkuNDQxIDE3NS43ODEgMzkzLjM5NyAxNzkuNzM3IDM5My4zOTcgMTg0LjYxN0MzOTMuMzk3IDE4OS40OTcgMzg5LjQ0MSAxOTMuNDUzIDM4NC41NjIgMTkzLjQ1M0gzNzEuMDkyQzM2Ni4yMTIgMTkzLjQ1MyAzNjIuMjU2IDE4OS40OTcgMzYyLjI1NiAxODQuNjE3WiIgZmlsbD0iI0ZGREVEMyIvPgo8cGF0aCBkPSJNMzYyLjI1NiAyMzEuNjE3QzM2Mi4yNTYgMjI2LjczNyAzNjYuMjEyIDIyMi43ODEgMzcxLjA5MiAyMjIuNzgxSDM4NC41NjJDMzg5LjQ0MSAyMjIuNzgxIDM5My4zOTcgMjI2LjczNyAzOTMuMzk3IDIzMS42MTdDMzkzLjM5NyAyMzYuNDk3IDM4OS40NDEgMjQwLjQ1MyAzODQuNTYyIDI0MC40NTNIMzcxLjA5MkMzNjYuMjEyIDI0MC40NTMgMzYyLjI1NiAyMzYuNDk3IDM2Mi4yNTYgMjMxLjYxN1oiIGZpbGw9IiNGRkRFRDMiLz4KPHJlY3QgeD0iMjc1LjYwMiIgeT0iMTg2LjY1NiIgd2lkdGg9IjU1LjUxMzMiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjc1LjYwMiIgeT0iMjQzLjY1NiIgd2lkdGg9IjU1LjUxMzMiIGhlaWdodD0iOS41MTU2MiIgcng9IjQuNzU3ODEiIGZpbGw9IiNFQkVFRjAiLz4KPC9nPgo8L2c+CjwvZz4KPGRlZnM+CjxmaWx0ZXIgaWQ9ImZpbHRlcjBfZF8xNDYxXzExMzIzIiB4PSI2OSIgeT0iNDAiIHdpZHRoPSIxODUiIGhlaWdodD0iMjQwIiBmaWx0ZXJVbml0cz0idXNlclNwYWNlT25Vc2UiIGNvbG9yLWludGVycG9sYXRpb24tZmlsdGVycz0ic1JHQiI+CjxmZUZsb29kIGZsb29kLW9wYWNpdHk9IjAiIHJlc3VsdD0iQmFja2dyb3VuZEltYWdlRml4Ii8+CjxmZUNvbG9yTWF0cml4IGluPSJTb3VyY2VBbHBoYSIgdHlwZT0ibWF0cml4IiB2YWx1ZXM9IjAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDEyNyAwIiByZXN1bHQ9ImhhcmRBbHBoYSIvPgo8ZmVPZmZzZXQgZHk9IjQiLz4KPGZlR2F1c3NpYW5CbHVyIHN0ZERldmlhdGlvbj0iOCIvPgo8ZmVDb21wb3NpdGUgaW4yPSJoYXJkQWxwaGEiIG9wZXJhdG9yPSJvdXQiLz4KPGZlQ29sb3JNYXRyaXggdHlwZT0ibWF0cml4IiB2YWx1ZXM9IjAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAuMTUgMCIvPgo8ZmVCbGVuZCBtb2RlPSJub3JtYWwiIGluMj0iQmFja2dyb3VuZEltYWdlRml4IiByZXN1bHQ9ImVmZmVjdDFfZHJvcFNoYWRvd18xNDYxXzExMzIzIi8+CjxmZUJsZW5kIG1vZGU9Im5vcm1hbCIgaW49IlNvdXJjZUdyYXBoaWMiIGluMj0iZWZmZWN0MV9kcm9wU2hhZG93XzE0NjFfMTEzMjMiIHJlc3VsdD0ic2hhcGUiLz4KPC9maWx0ZXI+CjxmaWx0ZXIgaWQ9ImZpbHRlcjFfZF8xNDYxXzExMzIzIiB4PSIyNDIiIHk9IjQwIiB3aWR0aD0iMTg1IiBoZWlnaHQ9IjI0MCIgZmlsdGVyVW5pdHM9InVzZXJTcGFjZU9uVXNlIiBjb2xvci1pbnRlcnBvbGF0aW9uLWZpbHRlcnM9InNSR0IiPgo8ZmVGbG9vZCBmbG9vZC1vcGFjaXR5PSIwIiByZXN1bHQ9IkJhY2tncm91bmRJbWFnZUZpeCIvPgo8ZmVDb2xvck1hdHJpeCBpbj0iU291cmNlQWxwaGEiIHR5cGU9Im1hdHJpeCIgdmFsdWVzPSIwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAxMjcgMCIgcmVzdWx0PSJoYXJkQWxwaGEiLz4KPGZlT2Zmc2V0IGR5PSI0Ii8+CjxmZUdhdXNzaWFuQmx1ciBzdGREZXZpYXRpb249IjgiLz4KPGZlQ29tcG9zaXRlIGluMj0iaGFyZEFscGhhIiBvcGVyYXRvcj0ib3V0Ii8+CjxmZUNvbG9yTWF0cml4IHR5cGU9Im1hdHJpeCIgdmFsdWVzPSIwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwLjE1IDAiLz4KPGZlQmxlbmQgbW9kZT0ibm9ybWFsIiBpbjI9IkJhY2tncm91bmRJbWFnZUZpeCIgcmVzdWx0PSJlZmZlY3QxX2Ryb3BTaGFkb3dfMTQ2MV8xMTMyMyIvPgo8ZmVCbGVuZCBtb2RlPSJub3JtYWwiIGluPSJTb3VyY2VHcmFwaGljIiBpbjI9ImVmZmVjdDFfZHJvcFNoYWRvd18xNDYxXzExMzIzIiByZXN1bHQ9InNoYXBlIi8+CjwvZmlsdGVyPgo8Y2xpcFBhdGggaWQ9ImNsaXAwXzE0NjFfMTEzMjMiPgo8cmVjdCB3aWR0aD0iNDk2IiBoZWlnaHQ9IjI1MyIgZmlsbD0id2hpdGUiLz4KPC9jbGlwUGF0aD4KPGNsaXBQYXRoIGlkPSJjbGlwMV8xNDYxXzExMzIzIj4KPHJlY3Qgd2lkdGg9IjQ1MCIgaGVpZ2h0PSIyMjUiIGZpbGw9IndoaXRlIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgxMyAyOCkiLz4KPC9jbGlwUGF0aD4KPC9kZWZzPgo8L3N2Zz4K",mobile:"data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDMzIiBoZWlnaHQ9IjE0NyIgdmlld0JveD0iMCAwIDQzMyAxNDciIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxnIGNsaXAtcGF0aD0idXJsKCNjbGlwMF8xNTA1XzQ2OTUpIj4KPGcgY2xpcC1wYXRoPSJ1cmwoI2NsaXAxXzE1MDVfNDY5NSkiPgo8cGF0aCBkPSJNNTIuMjUzOSAzNS43MDY1QzU1LjA2MzIgMzIuNDY0MSA1OC4wMjY1IDI5LjQ3NjQgNjEuMTI0NSAyNi43NjMxQzkwLjg5MTQgMC42MjUwOTIgMTE1LjQ4NCAwLjY2NzA1MyAxNDkuNTMyIDUuNDM3NTNDMTcyLjU1IDguNjYxNTMgMTg1Ljk5NyAyMC45Mjk0IDIxNy4zNzkgMTlDMjc0LjIwMSAxNS41MDY1IDMxNi41MTYgMS40Nzc4NyAzNjkgMzJDMzk0LjAyIDQ2LjU1MDQgNDE0LjAzMyA3NS44MjA0IDQyNS40NDkgMTA5LjYyOEM0NDUuMDE4IDE2Ny41NzYgNDEwLjEyNyAyNzEuODcxIDM2My4zMzYgMjc2Ljc4OEMzMjkuNDMxIDI4MC4zNTMgMzAxLjQ0OSAyMzguMzIgMjY3LjIyOCAyNDguMDU1QzI0Ni4xNDcgMjU0LjA1MyAyMzMuNjQzIDI3OS4yMSAyMTcuMzc5IDI5NS44MTJDMTk4LjQwMyAzMTUuMTgzIDE1Ny41MjYgMzEzLjk2NSAxMzUuMzA3IDMwMy42MjhDMTE0LjEzMyAyOTMuNzc3IDkzLjUzNTQgMjc0LjI1NCA4Ni42MjAyIDI0NS41QzgxLjM1NTYgMjIzLjYwMyA3OS45MjAyIDE5Ny41IDY1LjE4MDIgMTc3LjVDNDcuMzQyNCAxNTMuMjk2IDM2LjQ0NDIgMTQyLjUgMzAuMzIwMiAxMDkuNjI4QzI1LjAwMTUgODEuMDc4NCAzNi40NDQ4IDUzLjk5NjggNTIuMjUzOSAzNS43MDY1WiIgZmlsbD0iI0I4RTZDQSIvPgo8ZyBjbGlwLXBhdGg9InVybCgjY2xpcDJfMTUwNV80Njk1KSI+CjxnIGZpbHRlcj0idXJsKCNmaWx0ZXIwX2RfMTUwNV80Njk1KSI+CjxyZWN0IHg9Ijk2LjQzOTkiIHk9IjIyLjgxMzUiIHdpZHRoPSIxMTMuNTYiIGhlaWdodD0iMTU0LjM4MiIgcng9IjguMTY0NDQiIGZpbGw9IndoaXRlIi8+CjwvZz4KPHJlY3QgeD0iMTEwLjU2NSIgeT0iODYuMzc3OSIgd2lkdGg9IjM5LjM0OTQiIGhlaWdodD0iNy4wNjI3MSIgcng9IjMuNTMxMzUiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTEwLjU2NSIgeT0iNzUuMjc5MyIgd2lkdGg9IjE0LjEyNTQiIGhlaWdodD0iNy4wNjI3MSIgcng9IjMuNTMxMzUiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMTEwLjU2NSIgeT0iMTExLjY2IiB3aWR0aD0iMTQuMTI1NCIgaGVpZ2h0PSI3LjA2MjcxIiByeD0iMy41MzEzNSIgZmlsbD0iI0VCRUVGMCIvPgo8cmVjdCB4PSIxMTAuNTY1IiB5PSIxNDYuNTQ0IiB3aWR0aD0iMTQuMTI1NCIgaGVpZ2h0PSI3LjA2MjcxIiByeD0iMy41MzEzNSIgZmlsbD0iI0VCRUVGMCIvPgo8cGF0aCBkPSJNMTc0LjEzIDg0Ljg2NDRDMTc0LjEzIDgxLjI0MjQgMTc3LjA2NiA3OC4zMDYyIDE4MC42ODggNzguMzA2MkgxOTAuNzc4QzE5NC40IDc4LjMwNjIgMTk3LjMzNiA4MS4yNDI0IDE5Ny4zMzYgODQuODY0NEMxOTcuMzM2IDg4LjQ4NjQgMTk0LjQgOTEuNDIyNiAxOTAuNzc4IDkxLjQyMjZIMTgwLjY4OEMxNzcuMDY2IDkxLjQyMjYgMTc0LjEzIDg4LjQ4NjQgMTc0LjEzIDg0Ljg2NDRaIiBmaWxsPSIjQjhFNkNBIi8+CjxyZWN0IHg9IjExMC41NDIiIHk9IjM4LjQwMDEiIHdpZHRoPSIyNi43MiIgaGVpZ2h0PSI2LjY4IiByeD0iMy4zNCIgZmlsbD0iI0VCRUVGMCIvPgo8cGF0aCBkPSJNMTc0LjEzIDEyMS4yNDVDMTc0LjEzIDExNy42MjMgMTc3LjA2NiAxMTQuNjg3IDE4MC42ODggMTE0LjY4N0gxOTAuNzc4QzE5NC40IDExNC42ODcgMTk3LjMzNiAxMTcuNjIzIDE5Ny4zMzYgMTIxLjI0NUMxOTcuMzM2IDEyNC44NjcgMTk0LjQgMTI3LjgwMyAxOTAuNzc4IDEyNy44MDNIMTgwLjY4OEMxNzcuMDY2IDEyNy44MDMgMTc0LjEzIDEyNC44NjcgMTc0LjEzIDEyMS4yNDVaIiBmaWxsPSIjRkZERUQzIi8+CjxyZWN0IHg9IjEwOS41NTciIHk9IjEyMi43NTgiIHdpZHRoPSI0MS4zNjczIiBoZWlnaHQ9IjcuMDYyNzEiIHJ4PSIzLjUzMTM1IiBmaWxsPSIjRUJFRUYwIi8+CjxwYXRoIGQ9Ik0yMTAgNTguODExM0w5Ny4xODIyIDU4LjgxMTMiIHN0cm9rZT0iI0VCRUVGMCIgc3Ryb2tlLXdpZHRoPSIxLjQ4NDQ0Ii8+CjxnIGZpbHRlcj0idXJsKCNmaWx0ZXIxX2RfMTUwNV80Njk1KSI+CjxyZWN0IHg9IjIyNC44NDQiIHk9IjIyLjgxMzUiIHdpZHRoPSIxMTMuNTYiIGhlaWdodD0iMTU0LjM4MiIgcng9IjguMTY0NDQiIGZpbGw9IndoaXRlIi8+CjwvZz4KPHJlY3QgeD0iMjM4LjkxNCIgeT0iODYuMzc3OSIgd2lkdGg9IjM5LjE5MzMiIGhlaWdodD0iNy4wNjI3MSIgcng9IjMuNTMxMzUiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjM4LjkxNCIgeT0iNzUuMjc5MyIgd2lkdGg9IjE0LjA2OTQiIGhlaWdodD0iNy4wNjI3MSIgcng9IjMuNTMxMzUiIGZpbGw9IiNFQkVFRjAiLz4KPHJlY3QgeD0iMjM4LjkxMyIgeT0iMTExLjY2IiB3aWR0aD0iMTQuMDY5NCIgaGVpZ2h0PSI3LjA2MjcxIiByeD0iMy41MzEzNSIgZmlsbD0iI0VCRUVGMCIvPgo8cmVjdCB4PSIyMzguOTEzIiB5PSIxNDYuNTQ0IiB3aWR0aD0iMTQuMDY5NCIgaGVpZ2h0PSI3LjA2MjcxIiByeD0iMy41MzEzNSIgZmlsbD0iI0VCRUVGMCIvPgo8cGF0aCBkPSJNMzAyLjIyNiA4NC44NjQ0QzMwMi4yMjYgODEuMjQyNCAzMDUuMTYyIDc4LjMwNjIgMzA4Ljc4NCA3OC4zMDYySDMxOC43ODJDMzIyLjQwNCA3OC4zMDYyIDMyNS4zNCA4MS4yNDI0IDMyNS4zNCA4NC44NjQ0QzMyNS4zNCA4OC40ODY0IDMyMi40MDQgOTEuNDIyNiAzMTguNzgyIDkxLjQyMjZIMzA4Ljc4NEMzMDUuMTYyIDkxLjQyMjYgMzAyLjIyNiA4OC40ODY0IDMwMi4yMjYgODQuODY0NFoiIGZpbGw9IiNCOEU2Q0EiLz4KPHJlY3QgeD0iMjM4Ljk0NyIgeT0iMzguNDAwMSIgd2lkdGg9IjI2LjcyIiBoZWlnaHQ9IjYuNjgiIHJ4PSIzLjM0IiBmaWxsPSIjRUJFRUYwIi8+CjxwYXRoIGQ9Ik0zMzAuOTgzIDU4LjgxMTNMMjI0Ljg0NSA1OC44MTEzIiBzdHJva2U9IiNFQkVFRjAiIHN0cm9rZS13aWR0aD0iMS40ODQ0NCIvPgo8cGF0aCBkPSJNMzAyLjIyNiAxMjEuMjQ1QzMwMi4yMjYgMTE3LjYyMyAzMDUuMTYyIDExNC42ODcgMzA4Ljc4NCAxMTQuNjg3SDMxOC43ODFDMzIyLjQwMyAxMTQuNjg3IDMyNS4zNCAxMTcuNjIzIDMyNS4zNCAxMjEuMjQ1QzMyNS4zNCAxMjQuODY3IDMyMi40MDMgMTI3LjgwMyAzMTguNzgxIDEyNy44MDNIMzA4Ljc4NEMzMDUuMTYyIDEyNy44MDMgMzAyLjIyNiAxMjQuODY3IDMwMi4yMjYgMTIxLjI0NVoiIGZpbGw9IiNGRkRFRDMiLz4KPHJlY3QgeD0iMjM3LjkwOSIgeT0iMTIyLjc1OCIgd2lkdGg9IjQxLjIwMzIiIGhlaWdodD0iNy4wNjI3MSIgcng9IjMuNTMxMzUiIGZpbGw9IiNFQkVFRjAiLz4KPC9nPgo8L2c+CjwvZz4KPGRlZnM+CjxmaWx0ZXIgaWQ9ImZpbHRlcjBfZF8xNTA1XzQ2OTUiIHg9Ijg0LjU2NDQiIHk9IjEzLjkwNjgiIHdpZHRoPSIxMzcuMzExIiBoZWlnaHQ9IjE3OC4xMzMiIGZpbHRlclVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgY29sb3ItaW50ZXJwb2xhdGlvbi1maWx0ZXJzPSJzUkdCIj4KPGZlRmxvb2QgZmxvb2Qtb3BhY2l0eT0iMCIgcmVzdWx0PSJCYWNrZ3JvdW5kSW1hZ2VGaXgiLz4KPGZlQ29sb3JNYXRyaXggaW49IlNvdXJjZUFscGhhIiB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMTI3IDAiIHJlc3VsdD0iaGFyZEFscGhhIi8+CjxmZU9mZnNldCBkeT0iMi45Njg4OSIvPgo8ZmVHYXVzc2lhbkJsdXIgc3RkRGV2aWF0aW9uPSI1LjkzNzc4Ii8+CjxmZUNvbXBvc2l0ZSBpbjI9ImhhcmRBbHBoYSIgb3BlcmF0b3I9Im91dCIvPgo8ZmVDb2xvck1hdHJpeCB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMC4xNSAwIi8+CjxmZUJsZW5kIG1vZGU9Im5vcm1hbCIgaW4yPSJCYWNrZ3JvdW5kSW1hZ2VGaXgiIHJlc3VsdD0iZWZmZWN0MV9kcm9wU2hhZG93XzE1MDVfNDY5NSIvPgo8ZmVCbGVuZCBtb2RlPSJub3JtYWwiIGluPSJTb3VyY2VHcmFwaGljIiBpbjI9ImVmZmVjdDFfZHJvcFNoYWRvd18xNTA1XzQ2OTUiIHJlc3VsdD0ic2hhcGUiLz4KPC9maWx0ZXI+CjxmaWx0ZXIgaWQ9ImZpbHRlcjFfZF8xNTA1XzQ2OTUiIHg9IjIxMi45NjkiIHk9IjEzLjkwNjgiIHdpZHRoPSIxMzcuMzExIiBoZWlnaHQ9IjE3OC4xMzMiIGZpbHRlclVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgY29sb3ItaW50ZXJwb2xhdGlvbi1maWx0ZXJzPSJzUkdCIj4KPGZlRmxvb2QgZmxvb2Qtb3BhY2l0eT0iMCIgcmVzdWx0PSJCYWNrZ3JvdW5kSW1hZ2VGaXgiLz4KPGZlQ29sb3JNYXRyaXggaW49IlNvdXJjZUFscGhhIiB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMTI3IDAiIHJlc3VsdD0iaGFyZEFscGhhIi8+CjxmZU9mZnNldCBkeT0iMi45Njg4OSIvPgo8ZmVHYXVzc2lhbkJsdXIgc3RkRGV2aWF0aW9uPSI1LjkzNzc4Ii8+CjxmZUNvbXBvc2l0ZSBpbjI9ImhhcmRBbHBoYSIgb3BlcmF0b3I9Im91dCIvPgo8ZmVDb2xvck1hdHJpeCB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMC4xNSAwIi8+CjxmZUJsZW5kIG1vZGU9Im5vcm1hbCIgaW4yPSJCYWNrZ3JvdW5kSW1hZ2VGaXgiIHJlc3VsdD0iZWZmZWN0MV9kcm9wU2hhZG93XzE1MDVfNDY5NSIvPgo8ZmVCbGVuZCBtb2RlPSJub3JtYWwiIGluPSJTb3VyY2VHcmFwaGljIiBpbjI9ImVmZmVjdDFfZHJvcFNoYWRvd18xNTA1XzQ2OTUiIHJlc3VsdD0ic2hhcGUiLz4KPC9maWx0ZXI+CjxjbGlwUGF0aCBpZD0iY2xpcDBfMTUwNV80Njk1Ij4KPHJlY3Qgd2lkdGg9IjQzMyIgaGVpZ2h0PSIxNDciIGZpbGw9IndoaXRlIi8+CjwvY2xpcFBhdGg+CjxjbGlwUGF0aCBpZD0iY2xpcDFfMTUwNV80Njk1Ij4KPHJlY3Qgd2lkdGg9IjU1MyIgaGVpZ2h0PSIyNTMiIGZpbGw9IndoaXRlIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgtNjApIi8+CjwvY2xpcFBhdGg+CjxjbGlwUGF0aCBpZD0iY2xpcDJfMTUwNV80Njk1Ij4KPHJlY3Qgd2lkdGg9IjMzNCIgaGVpZ2h0PSIxNjciIGZpbGw9IndoaXRlIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSg1MCA1KSIvPgo8L2NsaXBQYXRoPgo8L2RlZnM+Cjwvc3ZnPgo=",verticalPosition:"bottom"},gaTrackingEventArgs:{category:s}})}),(b||W)&&(0,N.jsx)(_.A,{hasOAuthError:W,apiErrors:O.length?O:z,onRetry:B,inProgress:L,onCancel:W?U:()=>C(!1),trackEventCategory:`${i}_audiences-setup`})]})}AudienceSegmentationSetupCTABanner.propTypes={id:n().string,Notification:n().elementType};const T=(0,r.A)((0,I.A)({moduleName:x.L1}),(0,A.WP)("audienceSegmentationSetupCTA"))(AudienceSegmentationSetupCTABanner)},79829:(e,t,i)=>{i.d(t,{Eo:()=>u,JK:()=>h,K5:()=>m,jq:()=>p,mK:()=>d});var s=i(17243),n=i(50532),o=i.n(n),r=i(82871);function a(e,t={}){const{formatUnit:i,formatDecimal:s}=function(e,t={}){const{hours:i,minutes:s,seconds:n}=l(e);return{hours:i,minutes:s,seconds:n,formatUnit(){const{unitDisplay:o="short",...a}=t,l={unitDisplay:o,...a,style:"unit"};return 0===e?p(n,{...l,unit:"second"}):(0,r.sprintf)(/* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */ /* translators: 1: formatted seconds, 2: formatted minutes, 3: formatted hours */
|
||
(0,r._x)("%3$s %2$s %1$s","duration of time: hh mm ss","google-site-kit"),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 d(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 u(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=d(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 g=o()(console.warn);function p(e,t={}){const{locale:i=h(),...s}=t;try{return new Intl.NumberFormat(i,s).format(e)}catch(t){g(`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:()=>_});var s,n=i(62688),o=i.n(n),r=i(4452),a=i.n(r),l=i(63696),c=i(19793);function d(){return d=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},d.apply(null,arguments)}const warning_notice=e=>l.createElement("svg",d({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 u=i(42343),g=i(49655),p=i(62540);const m={[g.Q.NEW]:u.A,[g.Q.SUCCESS]:c.A,[g.Q.INFO]:warning_notice,[g.Q.WARNING]:warning_notice,[g.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(g.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,hideExternalIndicator:r}){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":"_self",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 y=i(82871);function DismissButton({label:e=(0,y.__)("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 v=(0,l.forwardRef)(({className:e,title:t,description:i,dismissButton:s,ctaButton:n,type:o=g.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})]})]}));v.TYPES=g.Q,v.propTypes={className:o().string,title:o().oneOfType([o().string,o().object]),description:o().node,type:o().oneOf(Object.values(g.Q)),dismissButton:o().shape(DismissButton.propTypes),ctaButton:o().shape({...CTAButton.propTypes,label:o().string}),children:o().node,hideIcon:o().bool};const _=v},80452:(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",fill:"none",viewBox:"0 0 12 9"},e),s||(s=n.createElement("path",{stroke:"currentColor",strokeLinecap:"square",strokeWidth:1.6,d:"m2 5.309 1.474 2.14c.69 1.001 1.946 1.001 2.636 0L10 1.8"})))},80869:(e,t,i)=>{i.d(t,{A:()=>AudienceErrorModal});var s=i(62688),n=i.n(s),o=i(13606),r=i(82871),a=i(50539),l=i(20898),c=i(4445),d=i(14007),u=i(93896),g=i(72455),p=i(67150),m=i(12850),h=i(62540);function AudienceErrorModal({apiErrors:e,hasOAuthError:t,inProgress:i,title:s,description:n,trackEventCategory:f,onCancel:y=()=>{},onRetry:v=()=>{}}){const _=Array.isArray(e)?e:[e],k=(0,a.useSelect)(e=>e(u.O4).getErrorTroubleshootingLinkURL({code:"analytics-4_insufficient_permissions"})),x=(0,a.useSelect)(e=>e(g.K9).getServiceEntityAccessURL()),I=(0,a.useSelect)(e=>e(u.O4).getErrorTroubleshootingLinkURL({code:"access_denied"}));if(!_.length&&!t)return null;const A=_.some(e=>(0,p.SG)(e));let j,M,S,b;return t?(j=(0,r.__)("Analytics update failed","google-site-kit"),M=(0,o.A)((0,r.__)("Setup was interrupted because you did not grant the necessary permissions. <HelpLink />","google-site-kit"),{HelpLink:(0,h.jsx)(l.A,{href:I,external:!0,hideExternalIndicator:!0,children:(0,r.__)("Get help","google-site-kit")})}),S=(0,r.__)("Retry","google-site-kit")):A?(j=(0,r.__)("Insufficient permissions","google-site-kit"),M=(0,o.A)((0,r.__)("You’ll need to contact your administrator. Trouble getting access? <HelpLink />","google-site-kit"),{HelpLink:(0,h.jsx)(l.A,{href:k,external:!0,hideExternalIndicator:!0,children:(0,r.__)("Get help","google-site-kit")})}),S=(0,r.__)("Request access","google-site-kit"),b=x):(j=s||(0,r.__)("Failed to set up visitor groups","google-site-kit"),M=n||(0,r.__)("Oops! Something went wrong. Retry enabling groups.","google-site-kit"),S=(0,r.__)("Retry","google-site-kit")),(0,h.jsx)(d.A,{children:(0,h.jsx)(c.A,{buttonLink:b,title:j,subtitle:M,handleConfirm:function(){let e;e=t?"auth_error_retry":A?"insufficient_permissions_error_request_access":"setup_error_retry",(0,m.sx)(f,e).finally(()=>{A||v()})},confirmButton:S,handleCancel:function(){let e;e=t?"auth_error_cancel":A?"insufficient_permissions_error_cancel":"setup_error_cancel",(0,m.sx)(f,e).finally(y)},onOpen:()=>{let e;e=t?"auth_error":A?"insufficient_permissions_error":"setup_error",(0,m.sx)(f,e)},onClose:y,inProgress:i,refocusQuerySelector:"#audience_segmentation_setup_cta-notification .googlesitekit-banner__cta",danger:!0,dialogActive:!0})})}AudienceErrorModal.propTypes={apiErrors:n().oneOfType([n().arrayOf(n().object),n().object,n().array]),hasOAuthError:n().bool,inProgress:n().bool,title:n().string,description:n().string,trackEventCategory:n().string,onCancel:n().func,onRetry:n().func}},81520:(e,t,i)=>{function Null(){return null}i.d(t,{A:()=>Null})},82046:(e,t,i)=>{i.d(t,{C:()=>o,p:()=>n});var s=i(15210);function n(e,t={}){return{__html:s.O.sanitize(e,t)}}function o(e){const t="object"==typeof e?e.toString():e;return t?.replace?.(/\/+$/,"")}},82167:(e,t,i)=>{i.d(t,{A:()=>OptIn});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(63696),l=i(13606),c=i(82871),d=i(50539),u=i(49383),g=i(58116),p=i(89318),m=i(20898),h=i(77766),f=i(50787),y=i(62540);function OptIn({id:e="googlesitekit-opt-in",name:t="optIn",className:i,trackEventCategory:s,alignLeftCheckbox:n=!1}){const[o,v]=(0,a.useState)(),_=(0,d.useSelect)(e=>e(g.oR).isTrackingEnabled()),k=(0,d.useSelect)(e=>e(g.oR).getErrorForAction("setTrackingEnabled",[!_])),{setTrackingEnabled:x}=(0,d.useDispatch)(g.oR),I=(0,h.A)(),A=(0,a.useCallback)(async e=>{const{response:t,error:i}=await x(e);i?v(_):((0,p.M9)(t.enabled),t.enabled&&(0,p.sx)(s||I,"tracking_optin"))},[_,x,s,I]);(0,a.useEffect)(()=>{void 0!==_&&void 0===o&&v(_)},[_,o]);const j=(0,f.d)(A,300),M=(0,a.useCallback)(e=>{const t=e.target.checked;v(t),j(t)},[j]);return(0,y.jsxs)("div",{className:r()("googlesitekit-opt-in",i),children:[(0,y.jsx)(u.Checkbox,{id:e,name:t,value:"1",checked:o,onChange:M,loading:void 0===_,alignLeft:n,children:(0,l.A)((0,c.__)("<span>Help us improve Site Kit by sharing anonymous usage data.</span> <span>All collected data is treated in accordance with the <a>Google Privacy Policy.</a></span>","google-site-kit"),{a:(0,y.jsx)(m.A,{href:"https://policies.google.com/privacy",external:!0},"link"),span:(0,y.jsx)("span",{})})}),k?.message&&(0,y.jsx)("div",{className:"googlesitekit-error-text",children:k?.message})]})}OptIn.propTypes={id:n().string,name:n().string,className:n().string,trackEventCategory:n().string,alignLeftCheckbox:n().bool}},82871:e=>{e.exports=googlesitekit.i18n},83366:(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",fill:"currentColor",viewBox:"0 0 24 24"},e),s||(s=n.createElement("path",{d:"M5 21a2 2 0 0 1-1.425-.575A2 2 0 0 1 3 19V5q0-.825.575-1.4Q4.175 3 5 3h7v2H5v14h14v-7h2v7q0 .825-.6 1.425Q19.825 21 19 21zm4.7-5.3-1.4-1.4L17.6 5H14V3h7v7h-2V6.4z"})))},84093:(e,t,i)=>{i.d(t,{A:()=>WidgetNull});var s=i(62688),n=i.n(s),o=i(47345),r=i(81520),a=i(62540);const l={};function WidgetNull({widgetSlug:e}){return(0,o.A)(e,r.A,l),(0,a.jsx)(r.A,{})}WidgetNull.propTypes={widgetSlug:n().string.isRequired,...r.A.propTypes}},84385:(e,t,i)=>{i.d(t,{A:()=>IconWrapper});var s=i(62688),n=i.n(s),o=i(62540);function IconWrapper({children:e,marginLeft:t,marginRight:i}){return(0,o.jsx)("span",{className:"googlesitekit-icon-wrapper",style:{marginLeft:t,marginRight:i},children:e})}IconWrapper.propTypes={children:n().node.isRequired,marginLeft:n().number,marginRight:n().number}},84707:(e,t,i)=>{var s=i(131),n=i(78325),o=i(21134),r=i(12701),a=i(24558),l=i(62688),c=i.n(l),d=i(15844),u=i(18117),g=i(63696),p=i(82871),m=i(50539),h=i(93896),f=i(37226),y=i(45472),v=i(99897),_=i(12850),k=i(6464),x=i(20068),I=i(84826),A=i(55527),j=i(12755),M=i(4452),S=i.n(M),b=i(20898),N=i(49383),E=i(62540);function ModuleSetupFooter({module:e,onCancel:t,onComplete:i}){const[s,n]=(0,g.useState)(!1),o=(0,m.useSelect)(e=>e(h.O4).getAdminURL("googlesitekit-settings")),r=(0,m.useSelect)(t=>t(e?.storeName)?.isSetupBlocked?.()),a=(0,m.useSelect)(t=>t(f.i).canSubmitChanges(e?.slug)),l=(0,g.useCallback)(async()=>{n(!0),await i(),n(!1)},[n,i]);return e?(0,E.jsx)("div",{className:S()("googlesitekit-setup__footer",`googlesitekit-setup__footer--${e?.slug}`),children:(0,E.jsx)(A.xA,{children:(0,E.jsxs)(A.fI,{children:[(0,E.jsx)(A.fh,{smSize:2,mdSize:4,lgSize:6,alignMiddle:!0,children:(0,E.jsx)(b.A,{id:`setup-${e.slug}-cancel`,href:o,onClick:t,children:r?(0,p.__)("Back","google-site-kit"):(0,p.__)("Cancel","google-site-kit")})}),i&&(0,E.jsx)(A.fh,{smSize:2,mdSize:4,lgSize:6,alignRight:!0,children:(0,E.jsx)(N.SpinnerButton,{id:`setup-${e.slug}-complete`,onClick:l,disabled:!a||s,isSaving:s,children:(0,p.__)("Complete Setup","google-site-kit")})})]})})}):null}ModuleSetupFooter.propTypes={module:c().shape({slug:c().string.isRequired,storeName:c().string.isRequired}).isRequired,onCancel:c().func.isRequired,onComplete:c().func};var w=i(40409);function ModuleSetup({moduleSlug:e}){const{navigateTo:t}=(0,m.useDispatch)(y.M),i=(0,k.i)("setupFlowRefresh"),[s]=(0,x.A)("showProgress"),n=(0,m.useSelect)(t=>t(f.i).getModule(e)),r=(0,m.useRegistry)(),a=(0,u.l6)(async i=>{if(await(0,o.LD)("module_setup"),await(0,_.sx)("moduleSetup","complete_module_setup",e),i)return void t(i);const{select:s,resolveSelect:n}=r;await n(h.O4).getSiteInfo();const a=s(h.O4).getAdminURL("googlesitekit-dashboard",{notification:"authentication_success",slug:e});t(a)},[r,t,e]),l=n?.onCompleteSetup,c=(0,g.useCallback)(()=>l(r,a),[l,r,a]),M=(0,g.useCallback)(async()=>{await(0,_.sx)("moduleSetup","cancel_module_setup",e)},[e]);if((0,d.A)(()=>{(0,_.sx)("moduleSetup","view_module_setup",e)}),!n?.SetupComponent)return null;const{SetupComponent:S}=n,b=i&&e===v.L1&&"true"===s;return(0,E.jsxs)(g.Fragment,{children:[(0,E.jsx)(j.A,{subHeader:b?(0,E.jsx)(w.A,{currentSegment:4,totalSegments:6}):null,children:(0,E.jsx)(I.A,{})}),(0,E.jsx)("div",{className:"googlesitekit-setup",children:(0,E.jsx)(A.xA,{children:(0,E.jsx)(A.fI,{children:(0,E.jsx)(A.fh,{size:12,children:(0,E.jsxs)("section",{className:"googlesitekit-setup__wrapper",children:[(0,E.jsx)(A.xA,{children:(0,E.jsx)(A.fI,{children:(0,E.jsxs)(A.fh,{size:12,children:[(0,E.jsx)("p",{className:"googlesitekit-setup__intro-title",children:(0,p.__)("Connect Service","google-site-kit")}),(0,E.jsx)(S,{module:n,finishSetup:a})]})})}),(0,E.jsx)(ModuleSetupFooter,{module:n,onCancel:M,onComplete:"function"==typeof l?c:void 0})]})})})})})]})}ModuleSetup.propTypes={moduleSlug:c().string.isRequired};var C=i(44949),T=i(60072),D=i(24452),R=i(76283),O=i(75949),z=i(29507),L=i(98748),B=i(58116),P=i(5230),G=i(78340),U=i(12417),V=i(56009),F=i(88933),W=i(15167);function SurveyHeader({title:e,dismissSurvey:t}){return(0,E.jsxs)("div",{className:"googlesitekit-survey__header",children:[(0,E.jsx)("div",{className:"googlesitekit-survey__header-logo",children:(0,E.jsx)(F.A,{width:24,height:24})}),(0,E.jsxs)("div",{className:"googlesitekit-survey__header-details",children:[(0,E.jsx)(W.A,{as:"h3",type:"headline",size:"small",children:e}),(0,E.jsx)(N.Button,{"aria-label":(0,p.__)("Dismiss","google-site-kit"),icon:(0,E.jsx)(U.A,{icon:V.A,size:40}),onClick:t,className:"googlesitekit-survey__header-close"})]})]})}SurveyHeader.propTypes={title:c().string.isRequired,dismissSurvey:c().func.isRequired};const H=SurveyHeader;function SurveyCompletion({title:e,children:t,ctaText:i,ctaURL:s,ctaOnClick:n,dismissSurvey:o}){return(0,E.jsxs)("div",{className:"googlesitekit-survey__completion",children:[(0,E.jsx)(H,{title:e,dismissSurvey:o}),(0,E.jsx)("div",{className:"googlesitekit-survey__body",children:t}),s&&i&&(0,E.jsx)("div",{className:"googlesitekit-survey__footer",children:(0,E.jsx)(N.Button,{href:s,onClick:n,target:"_blank",children:i})})]})}SurveyCompletion.propTypes={title:c().string.isRequired,children:c().node,ctaText:c().string,ctaURL:c().string,ctaOnClick:c().func,dismissSurvey:c().func.isRequired},SurveyCompletion.defaultProps={title:"",children:null,ctaText:"",ctaURL:"",ctaOnClick:null};const Y=SurveyCompletion;var Z=i(13606);function SurveyTerms(){const e=(0,m.useSelect)(e=>e(h.O4).getGooglePrivacyPolicyURL()),t=(0,m.useSelect)(e=>e(h.O4).getGoogleTermsURL());return(0,E.jsx)("p",{className:"googlesitekit-survey__terms",children:(0,Z.A)((0,p.__)("By continuing, you agree to allow Google to use your answers and account info to improve services, per our <privacy>Privacy</privacy> & <terms>Terms</terms>.","google-site-kit"),{privacy:(0,E.jsx)(b.A,{href:e,external:!0,hideExternalIndicator:!0,noFlex:!0}),terms:(0,E.jsx)(b.A,{href:t,external:!0,hideExternalIndicator:!0,noFlex:!0})})})}var Q,q=i(59323);function K(){return K=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},K.apply(null,arguments)}var X;function $(){return $=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},$.apply(null,arguments)}var J;function survey_neutral_extends(){return survey_neutral_extends=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},survey_neutral_extends.apply(null,arguments)}var ee;function te(){return te=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},te.apply(null,arguments)}var ie;function se(){return se=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},se.apply(null,arguments)}const ne={1:e=>g.createElement("svg",K({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),Q||(Q=g.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M14.985 0C6.705 0 0 6.72 0 15s6.705 15 14.985 15C23.28 30 30 23.28 30 15S23.28 0 14.985 0M15 27C8.37 27 3 21.63 3 15S8.37 3 15 3s12 5.37 12 12-5.37 12-12 12m7.5-15.75a2.247 2.247 0 0 1-2.25 2.25A2.247 2.247 0 0 1 18 11.25 2.247 2.247 0 0 1 20.25 9a2.247 2.247 0 0 1 2.25 2.25M9.75 13.5A2.247 2.247 0 0 0 12 11.25 2.247 2.247 0 0 0 9.75 9a2.247 2.247 0 0 0-2.25 2.25 2.247 2.247 0 0 0 2.25 2.25m-2.415 9c1.2-3.06 4.17-5.25 7.665-5.25s6.465 2.19 7.665 5.25z",clipRule:"evenodd"}))),2:e=>g.createElement("svg",$({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),X||(X=g.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M30 15c0 8.28-6.72 15-15.015 15C6.705 30 0 23.28 0 15S6.705 0 14.985 0C23.28 0 30 6.72 30 15m-9.75-1.5a2.247 2.247 0 0 0 2.25-2.25A2.247 2.247 0 0 0 20.25 9 2.247 2.247 0 0 0 18 11.25a2.247 2.247 0 0 0 2.25 2.25m-13.725 9c1.245-3.495 4.56-6 8.49-6 3.915 0 7.23 2.505 8.475 6h-3.315c-1.035-1.785-2.955-3-5.16-3-2.22 0-4.125 1.215-5.175 3zM12 11.25a2.247 2.247 0 0 1-2.25 2.25 2.247 2.247 0 0 1-2.25-2.25A2.247 2.247 0 0 1 9.75 9 2.247 2.247 0 0 1 12 11.25M15 3c6.63 0 12 5.37 12 12s-5.37 12-12 12S3 21.63 3 15 8.37 3 15 3",clipRule:"evenodd"}))),3:e=>g.createElement("svg",survey_neutral_extends({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),J||(J=g.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M30 15c0 8.28-6.72 15-15.015 15C6.705 30 0 23.28 0 15S6.705 0 14.985 0C23.28 0 30 6.72 30 15M9.75 9A2.247 2.247 0 0 1 12 11.25a2.247 2.247 0 0 1-2.25 2.25 2.247 2.247 0 0 1-2.25-2.25A2.247 2.247 0 0 1 9.75 9m10.5 0A2.247 2.247 0 0 0 18 11.25a2.247 2.247 0 0 0 2.25 2.25 2.247 2.247 0 0 0 2.25-2.25A2.247 2.247 0 0 0 20.25 9M10.5 22.5v-3h9v3zM15 3c6.63 0 12 5.37 12 12s-5.37 12-12 12S3 21.63 3 15 8.37 3 15 3",clipRule:"evenodd"}))),4:e=>g.createElement("svg",te({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),ee||(ee=g.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M30 15c0 8.28-6.72 15-15.015 15C6.705 30 0 23.28 0 15S6.705 0 14.985 0C23.28 0 30 6.72 30 15m-9.75-1.5a2.247 2.247 0 0 0 2.25-2.25A2.247 2.247 0 0 0 20.25 9 2.247 2.247 0 0 0 18 11.25a2.247 2.247 0 0 0 2.25 2.25m3.225 4.5c-1.245 3.495-4.56 6-8.49 6-3.915 0-7.23-2.505-8.475-6h3.315c1.035 1.785 2.955 3 5.16 3 2.22 0 4.125-1.215 5.175-3zM12 11.25a2.247 2.247 0 0 1-2.25 2.25 2.247 2.247 0 0 1-2.25-2.25A2.247 2.247 0 0 1 9.75 9 2.247 2.247 0 0 1 12 11.25M15 3c6.63 0 12 5.37 12 12s-5.37 12-12 12S3 21.63 3 15 8.37 3 15 3",clipRule:"evenodd"}))),5:e=>g.createElement("svg",se({xmlns:"http://www.w3.org/2000/svg",fill:"none"},e),ie||(ie=g.createElement("path",{fill:"currentColor",fillRule:"evenodd",d:"M14.985 0C6.705 0 0 6.72 0 15s6.705 15 14.985 15C23.28 30 30 23.28 30 15S23.28 0 14.985 0M15 27C8.37 27 3 21.63 3 15S8.37 3 15 3s12 5.37 12 12-5.37 12-12 12m7.5-15.75a2.247 2.247 0 0 1-2.25 2.25A2.247 2.247 0 0 1 18 11.25 2.247 2.247 0 0 1 20.25 9a2.247 2.247 0 0 1 2.25 2.25M9.75 13.5A2.247 2.247 0 0 0 12 11.25 2.247 2.247 0 0 0 9.75 9a2.247 2.247 0 0 0-2.25 2.25 2.247 2.247 0 0 0 2.25 2.25M22.665 18c-1.2 3.06-4.17 5.25-7.665 5.25S8.535 21.06 7.335 18z",clipRule:"evenodd"})))};function SurveyQuestionRatingChoice({choice:e,answerQuestion:t}){const i=(0,g.useCallback)(()=>{"function"==typeof t&&t({answer:{answer_ordinal:e.answer_ordinal}})},[t,e]),s=ne[e.answer_ordinal];return s?(0,E.jsxs)("div",{className:"googlesitekit-survey__choice",children:[(0,E.jsx)(N.Button,{icon:(0,E.jsx)(s,{width:30,height:30}),"aria-label":e.text,onClick:i}),(0,E.jsx)(q.A,{children:e.text})]}):null}SurveyQuestionRatingChoice.propTypes={choice:c().shape({answer_ordinal:c().oneOfType([c().string,c().number]),text:c().string}).isRequired};const oe=SurveyQuestionRatingChoice;function SurveyQuestionRating({question:e,choices:t,answerQuestion:i,dismissSurvey:s}){return(0,E.jsxs)("div",{className:"googlesitekit-survey__question-rating",children:[(0,E.jsx)(H,{title:e,dismissSurvey:s}),(0,E.jsx)("div",{className:"googlesitekit-survey__body",children:(0,E.jsx)("div",{className:"googlesitekit-survey__choices",children:t.map((e,t)=>(0,E.jsx)(oe,{choice:e,answerQuestion:i},t))})})]})}SurveyQuestionRating.propTypes={question:c().string.isRequired,choices:c().arrayOf(c().shape({answer_ordinal:c().oneOfType([c().string,c().number]),text:c().string})).isRequired,answerQuestion:c().func.isRequired,dismissSurvey:c().func.isRequired};const re=SurveyQuestionRating;var ae=i(52684),le=i(16834);function SurveyQuestionOpenText({question:e,answerQuestion:t,placeholder:i,subtitle:s,dismissSurvey:n,submitButtonText:o}){const[r,a]=(0,g.useState)("");const l=(0,g.useCallback)(e=>{a(e.target.value.slice(0,200))},[a]),c=(0,ae.A)(SurveyQuestionOpenText,"SurveyQuestionOpenText");return(0,E.jsxs)("div",{className:"googlesitekit-survey__open-text",children:[(0,E.jsx)(H,{title:e,dismissSurvey:n}),(0,E.jsxs)("div",{className:"googlesitekit-survey__body",children:[(0,E.jsx)(le.A,{children:(0,E.jsx)("label",{htmlFor:c,children:i})}),(0,E.jsx)(N.TextField,{name:`survey-opentext-${c}`,helperText:s,onChange:l,label:i,inputType:"textarea",id:c,value:r,textarea:!0})]}),(0,E.jsx)("div",{className:"googlesitekit-survey__footer",children:(0,E.jsx)(N.Button,{disabled:0===r.length,onClick:function(){t({answer:r})},children:o})})]})}SurveyQuestionOpenText.propTypes={question:c().string.isRequired,subtitle:c().string.isRequired,placeholder:c().string.isRequired,answerQuestion:c().func.isRequired,dismissSurvey:c().func.isRequired,submitButtonText:c().string.isRequired};const ce=SurveyQuestionOpenText;var de=i(17243);function SurveyQuestionMultiSelect({question:e,choices:t,answerQuestion:i,dismissSurvey:s,minChoices:n=1,maxChoices:o,submitButtonText:r}){const a=(0,ae.A)(SurveyQuestionMultiSelect,"SurveyQuestionMultiSelect"),l=t.map(({answer_ordinal:e,write_in:t})=>({answer_ordinal:e,selected:!1,...t?{answer_text:""}:{}})),c=(0,de.keyBy)(l,"answer_ordinal"),[d,u]=(0,g.useState)(c);const m=t.filter(({write_in:e,answer_ordinal:t})=>{if(e){const{selected:e,answer_text:i}=d[t];if(e&&0===i.length)return!0}return!1}).length>0,h=Object.values(d).filter(({selected:e})=>e).length,f=o&&h===o,y=m||h<n;return(0,E.jsxs)("div",{className:"googlesitekit-survey__multi-select",children:[(0,E.jsx)(H,{title:e,dismissSurvey:s}),(0,E.jsx)("div",{className:"googlesitekit-survey__body",children:t.map(({answer_ordinal:e,text:t,write_in:i})=>{const s=d[e],n=`${a}-answer-${e}`;return(0,E.jsxs)("div",{className:S()("googlesitekit-survey__multi-select__choice",{"googlesitekit-survey__multi-select__choice--disabled":f&&!s.selected}),children:[(0,E.jsx)(N.Checkbox,{checked:s.selected,disabled:f&&!s.selected,onChange:()=>function(e){const t={...d,[e]:{...d[e],selected:!d[e].selected}};u(t)}(e),value:`${e}`,id:n,name:n,children:t}),i&&(0,E.jsxs)(g.Fragment,{children:[(0,E.jsx)(le.A,{children:(0,E.jsx)("label",{htmlFor:`${n}-write-in`,children:(0,p.sprintf)(/* translators: %s: Option name */ /* translators: %s: Option name */
|
||
(0,p.__)("Text input for option %s","google-site-kit"),t)})}),(0,E.jsx)(N.TextField,{id:`${n}-write-in`,onChange:t=>function(e,t){const i={...d,[t]:{...d[t],answer_text:e.target.value?.slice(0,200)}};u(i)}(t,e),value:s.answer_text,disabled:!s.selected})]})]},n)})}),(0,E.jsxs)("div",{className:"googlesitekit-survey__footer",children:[n>1&&(0,E.jsx)(N.HelperText,{persistent:!0,children:(0,p.sprintf)(/* translators: %s: the number of answers. */ /* translators: %s: the number of answers. */
|
||
(0,p.__)("Choose at least %s answers","google-site-kit"),n)}),(0,E.jsx)(N.Button,{onClick:function(){const e=Object.values(d).filter(({selected:e})=>e).map(({answer_ordinal:e,answer_text:t})=>t?{answer_ordinal:e,answer_text:t}:{answer_ordinal:e});i({answer:e})},disabled:y,children:r})]})]})}SurveyQuestionMultiSelect.propTypes={question:c().string.isRequired,choices:c().arrayOf(c().shape({answer_ordinal:c().oneOfType([c().string,c().number]),text:c().string,write_in:c().bool})).isRequired,answerQuestion:c().func.isRequired,dismissSurvey:c().func.isRequired,minChoices:c().number,maxChoices:c().number,submitButtonText:c().string.isRequired};const ue=SurveyQuestionMultiSelect;function SurveyQuestionSingleSelectChoice({value:e,setValue:t,writeIn:i,setWriteIn:s,choice:n}){const{answer_ordinal:o,text:r,write_in:a}=n,l=e===o,c=`googlesitekit-survey__multi-select-${o}-${r}`;return(0,E.jsxs)("div",{className:"googlesitekit-single-select__choice",children:[(0,E.jsx)(N.Radio,{id:r.replace(/ /g,"-"),value:o,checked:l,name:r,onClick:()=>t(o),children:r}),a&&(0,E.jsxs)(g.Fragment,{children:[(0,E.jsx)(le.A,{children:(0,E.jsx)("label",{htmlFor:c,children:(0,p.sprintf)(/* translators: %s: Option name */ /* translators: %s: Option name */
|
||
(0,p.__)("Text input for option %s","google-site-kit"),r)})}),(0,E.jsx)(N.TextField,{id:c,onChange:e=>s(e.target.value.slice(0,200)),value:i,disabled:!l})]})]})}SurveyQuestionSingleSelectChoice.propTypes={choice:c().shape({answer_ordinal:c().oneOfType([c().string,c().number]),text:c().string,write_in:c().bool}),value:c().string.isRequired,setValue:c().func.isRequired,writeIn:c().string.isRequired,setWriteIn:c().func.isRequired};const ge=SurveyQuestionSingleSelectChoice;function SurveyQuestionSingleSelect({question:e,choices:t,answerQuestion:i,dismissSurvey:s,submitButtonText:n}){const[o,r]=(0,g.useState)(""),[a,l]=(0,g.useState)(""),c=t.map(e=>({...e,answer_ordinal:`${e.answer_ordinal}`})),d=!!o&&c.filter(({answer_ordinal:e,write_in:t})=>e===o&&t).length>0;const u=""===o||d&&""===a;return(0,E.jsxs)("div",{className:"googlesitekit-single-select",children:[(0,E.jsx)(H,{title:e,dismissSurvey:s}),(0,E.jsx)("div",{className:"googlesitekit-survey__body",children:c.map((e,t)=>(0,E.jsx)(ge,{value:o,setValue:r,writeIn:a,setWriteIn:l,choice:e},t))}),(0,E.jsx)("div",{className:"googlesitekit-survey__footer",children:(0,E.jsx)(N.Button,{onClick:function(){const e=d?{answer_text:a}:{};i({answer:{answer_ordinal:Number(o),...e}})},disabled:u,children:n})})]})}SurveyQuestionSingleSelect.propTypes={question:c().string.isRequired,choices:c().arrayOf(c().shape({answer_ordinal:c().oneOfType([c().string,c().number]),text:c().string,write_in:c().bool})).isRequired,answerQuestion:c().func.isRequired,dismissSurvey:c().func.isRequired};const pe=SurveyQuestionSingleSelect,me={MULTI_SELECT:"multi_select",OPEN_TEXT:"open_text",RATING:"rating",SINGLE_SELECT:"single_select"};function SurveyQuestion({currentQuestion:e,answerQuestion:t,dismissSurvey:i,isLastQuestion:s}){const n={key:e.question_text,answerQuestion:t,dismissSurvey:i,question:e.question_text,submitButtonText:s?(0,p.__)("Submit","google-site-kit"):(0,p.__)("Next","google-site-kit")};return(0,E.jsxs)(g.Fragment,{children:[e.question_type===me.MULTI_SELECT&&(0,E.jsx)(ue,{...n,choices:e.question.answer_choice,minChoices:e.question.min_choices,maxChoices:e.question.max_choices}),e.question_type===me.OPEN_TEXT&&(0,E.jsx)(ce,{...n,subtitle:e.question.subtitle,placeholder:e.question.placeholder}),e.question_type===me.RATING&&(0,E.jsx)(re,{...n,choices:e.question.answer_choice}),e.question_type===me.SINGLE_SELECT&&(0,E.jsx)(pe,{...n,choices:e.question.answer_choice})]})}function he(e,t){return!1===e.some(({trigger_condition:e})=>!(!Array.isArray(e)||0===e.length)&&e.some(e=>e.question_ordinal===t.question_ordinal))}function fe(e){return e.reduce((e,{question_ordinal:t,answer:i})=>({...e,[t]:i.answer.answer_ordinal||i.answer}),{})}SurveyQuestion.propTypes={currentQuestion:c().object.isRequired,answerQuestion:c().func.isRequired,dismissSurvey:c().func.isRequired,isLastQuestion:c().bool.isRequired};var ye=i(27333);const ve=Object.freeze([]);function CurrentSurvey(){const[e,t]=(0,g.useState)(!1),[i,s]=(0,g.useState)(!1),[n,o]=(0,g.useState)(!1),[r,a]=(0,g.useState)(!1),l=(0,m.useSelect)(e=>e(B.oR).getCurrentSurveyCompletions()),c=(0,m.useSelect)(e=>e(B.oR).getCurrentSurveyQuestions()),u=(0,m.useSelect)(e=>e(B.oR).getCurrentSurveySession()),p=(0,m.useSelect)(e=>e(B.oR).isTrackingEnabled()),h=u?`survey-${u.session_id}`:null,f=(0,ye.A)(h,"hideSurvey"),y=(0,ye.A)(h,"answers")||ve,{setValues:v}=(0,m.useDispatch)(G.s),{sendSurveyEvent:_}=(0,m.useDispatch)(B.oR);(0,g.useEffect)(()=>{c?.length&&!e&&(t(!0),_("survey_shown"))},[c,e,_]);const{currentQuestion:k,currentQuestionOrdinal:x}=function(e,t){const i=fe(t);let s=Math.max(0,...t.map(e=>e.question_ordinal))+1;const n=e?.find(e=>{const{question_ordinal:t,trigger_condition:n}=e;if(t<s)return!1;if(Array.isArray(n)&&n.length>0)for(const e of n){const t=i[e.question_ordinal];if(!t)return s++,!1;const n=e.answer_ordinal||[];if(!Array.isArray(t)&&!n.includes(t))return s++,!1;if(Array.isArray(t)&&!t.some(({answer_ordinal:e})=>n.includes(e))){s++;break}}return t===s});return{currentQuestion:n,currentQuestionOrdinal:s}}(c,y),I=(0,g.useCallback)(e=>{r||(a(!0),_("question_answered",{question_ordinal:k?.question_ordinal,answer:e}),setTimeout(()=>{v(h,{answers:[...y,{question_ordinal:k?.question_ordinal,answer:e}]}),a(!1)},300))},[y,k,h,_,v,r]),A=function(e,t,i,s){const n=fe(t);let o;return e?.length&&s>e.length&&(o=(i||[]).find(e=>{const t=e.trigger_condition||[];for(const i of t)if(i.answer_ordinal.includes(n[i.question_ordinal]))return o=e,!0;return!1}),o||(o=i[0])),o}(c,y,l,x),j=(0,g.useCallback)(()=>{_("follow_up_link_clicked",{completion_ordinal:A?.completion_ordinal}),_("survey_closed"),v(h,{hideSurvey:!0})},[h,_,v,A]),M=(0,g.useCallback)(()=>{_("survey_closed"),o(!1)},[_]),S=(0,g.useCallback)(()=>{v(h,{hideSurvey:!0})},[h,v]);return(0,g.useEffect)(()=>{A&&!i&&(s(!0),_("completion_shown",{completion_ordinal:A?.completion_ordinal}))},[i,_,A]),(0,d.A)(()=>{o(!0)}),!f&&c&&l&&void 0!==p?A?(0,E.jsx)(P.A,{direction:"up",in:n,onExited:S,children:(0,E.jsx)("div",{className:"googlesitekit-survey",children:(0,E.jsx)(Y,{dismissSurvey:M,ctaOnClick:j,ctaText:A.follow_up_text,ctaURL:A.follow_up_url,title:A.completion_title,children:A.completion_text})})}):Object.values(me).includes(k?.question_type)?(0,E.jsx)(P.A,{direction:"up",in:n,onExited:S,children:(0,E.jsxs)("div",{className:"googlesitekit-survey",children:[(0,E.jsx)(SurveyQuestion,{currentQuestion:k,answerQuestion:I,dismissSurvey:M,isLastQuestion:he(c,k)}),!1===p&&1===k?.question_ordinal&&(0,E.jsx)("div",{className:"googlesitekit-survey__footer",children:(0,E.jsx)(SurveyTerms,{})})]})}):null:null}var _e=i(14007);function CurrentSurveyPortal(){return(0,m.useSelect)(e=>e(h.O4).isUsingProxy()&&!1===e(B.oR).areSurveysOnCooldown()?e(B.oR).getCurrentSurvey():null)?(0,E.jsx)(_e.A,{slug:"survey",children:(0,E.jsx)(CurrentSurvey,{})}):null}var ke=i(66847),xe=i(7081),Ie=i(50111),Ae=i(68869),je=i(27134),Me=i(718),Se=i(77766);function Panel(){const e=(0,Se.A)(),t=(0,m.useSelect)(e=>e(xe.n).getValue(Ie.EA)),i=(0,m.useInViewSelect)(e=>{const t=e(B.oR).getKeyMetrics();if(!Array.isArray(t))return[];const{isKeyMetricAvailable:i}=e(B.oR);return t.filter(i)}),{setValues:s}=(0,m.useDispatch)(G.s),{setValue:n}=(0,m.useDispatch)(xe.n),o=(0,g.useCallback)(()=>{s(Ie.Is,{[Ie.Y0]:i,[Ie.Nl]:i}),(0,_.sx)(`${e}_kmw-sidebar`,"metrics_sidebar_view")},[i,s,e]),r=(0,g.useCallback)(()=>{t&&n(Ie.EA,!1)},[n,t]),[a,l]=(0,g.useState)(!1);return(0,E.jsx)(Me.Ay,{isOpen:t||a,onOpen:o,closePanel:r,className:"googlesitekit-km-selection-panel googlesitekit-acr-km-selection-panel",children:(0,E.jsx)(je.A,{isOpen:t,closePanel:r,savedViewableMetrics:i,setIsNavigatingToOAuthURL:l})})}function MetricsSelectionPanel(){const e=(0,m.useSelect)(e=>e(xe.n).getValue(Ie.EA));return(0,E.jsx)(Ae.Ay,{value:{key:"MetricsSelectionPanel",value:!!e},children:(0,E.jsx)(Panel,{})})}var be=i(89506),Ne=i(86134),Ee=i(35323),we=i(84754),Ce=i(13719),Te=i(32947),De=i(66201),Re=i(12108),Oe=i(50234),ze=i(74995),Le=i(53137),Be=i(68485);function DashboardMainApp(){const[e,t]=(0,g.useState)(!1),s=(0,Ee.A)(),n=(0,Te.dv)(),[o,r]=(0,x.A)("widgetArea"),{setValues:l}=(0,m.useDispatch)(G.s),c=(0,m.useSelect)(e=>e(B.oR).getGrantedScopes()),u=(0,ye.A)(B.$8,"permissionsError"),p=void 0!==c&&u?.data?.scopes?.some(e=>c.includes(e)),f=(0,m.useSelect)(e=>e(B.oR).getConfiguredAudiences());(0,d.A)(()=>{if(s||setTimeout(()=>t(!0),5e3),o){const e=`.googlesitekit-widget-area--${o}`;setTimeout(()=>{function t(){i.g.scrollTo({top:(0,Re.YJ)(e,n),behavior:"smooth"})}i.g.addEventListener("scrollend",function e(){t(),i.g.removeEventListener("scrollend",e)}),t(),r(void 0)},100)}}),(0,g.useEffect)(()=>{void 0!==u&&p&&l(B.$8,{permissionsError:{}})},[p,l,u]);const y=(0,m.useSelect)(e=>s?e(B.oR).getViewableModules():null),v={modules:y||void 0},A=(0,m.useSelect)(e=>e(Ne.aO).isWidgetContextActive(C.CONTEXT_MAIN_DASHBOARD_KEY_METRICS,v)),M=(0,m.useSelect)(e=>e(Ne.aO).isWidgetContextActive(C.CONTEXT_MAIN_DASHBOARD_TRAFFIC,v)),b=(0,m.useSelect)(e=>e(Ne.aO).isWidgetContextActive(C.CONTEXT_MAIN_DASHBOARD_CONTENT,v)),N=(0,m.useSelect)(e=>e(Ne.aO).isWidgetContextActive(C.CONTEXT_MAIN_DASHBOARD_SPEED,v)),w=(0,m.useSelect)(e=>e(Ne.aO).isWidgetContextActive(C.CONTEXT_MAIN_DASHBOARD_MONETIZATION,v)),P=(0,m.useSelect)(e=>e(B.oR).isKeyMetricsWidgetHidden()),U=(0,Oe.A)(),V=(0,m.useSelect)(e=>!0===e(h.O4).isKeyMetricsSetupCompleted()&&!1===P||e(B.oR).isAuthenticated()&&!1===e(h.O4).isKeyMetricsSetupCompleted()&&U),F=(0,k.i)("proactiveUserEngagement");(0,De.Z)();let W=null;return w?W=a.Gw:N?W=a.Ej:b?W=a.en:M?W=a.OT:A&&(W=a.SH),(0,E.jsxs)(g.Fragment,{children:[(0,E.jsx)(ke.A,{}),(0,E.jsx)(Ce.A,{}),(0,E.jsx)(Be.r,{}),(0,E.jsxs)(j.A,{showNavigation:!0,children:[(0,E.jsx)(O.A,{}),(0,E.jsx)(z.A,{}),!s&&(0,E.jsx)(T.A,{}),(0,E.jsx)(I.A,{})]}),(0,E.jsxs)("div",{className:"googlesitekit-page-content",children:[(0,E.jsx)(ze.A,{areaSlug:Le.bI.DASHBOARD_TOP}),(0,E.jsx)(ze.A,{areaSlug:Le.bI.DASHBOARD_TOP,groupID:Le.He.SETUP_CTAS}),(0,E.jsx)(ze.A,{areaSlug:Le.bI.OVERLAYS,groupID:Le.He.SETUP_CTAS}),!0!==P&&(0,E.jsx)(D.A,{id:a.SH,slug:C.CONTEXT_MAIN_DASHBOARD_KEY_METRICS,className:S()({"googlesitekit-widget-context--last":W===a.SH})}),(0,E.jsx)(D.A,{id:a.OT,slug:C.CONTEXT_MAIN_DASHBOARD_TRAFFIC,className:S()({"googlesitekit-widget-context--last":W===a.OT})}),(0,E.jsx)(D.A,{id:a.en,slug:C.CONTEXT_MAIN_DASHBOARD_CONTENT,className:S()({"googlesitekit-widget-context--last":W===a.en})}),(0,E.jsx)(D.A,{id:a.Ej,slug:C.CONTEXT_MAIN_DASHBOARD_SPEED,className:S()({"googlesitekit-widget-context--last":W===a.Ej})}),(0,E.jsx)(D.A,{id:a.Gw,slug:C.CONTEXT_MAIN_DASHBOARD_MONETIZATION,className:S()({"googlesitekit-widget-context--last":W===a.Gw})}),(0,E.jsx)(we.A,{})]}),(0,E.jsx)(L.A,{triggerID:"view_dashboard",ttl:_.tt}),e&&(0,E.jsx)(CurrentSurveyPortal,{}),V&&(0,E.jsx)(MetricsSelectionPanel,{}),F&&(0,E.jsx)(be.A,{}),f&&(0,E.jsx)(R.Rl,{}),(0,E.jsx)(we.A,{})]})}function DashboardEntryPoint({setupModuleSlug:e}){return e?(0,E.jsx)(ModuleSetup,{moduleSlug:e}):(0,E.jsx)(DashboardMainApp,{})}DashboardEntryPoint.propTypes={setupModuleSlug:c().string},(0,s.A)(async()=>{i.g._googlesitekitLegacyData.admin.resetSession&&await(0,o.IL)();const e=document.getElementById("js-googlesitekit-main-dashboard");if(e){const{setupModuleSlug:t,viewOnly:i}=e.dataset;let s=a.bg;t||(s=i?a.Ax:a.jU),(0,n.render)((0,E.jsx)(r.A,{viewContext:s,children:(0,E.jsx)(DashboardEntryPoint,{setupModuleSlug:t})}),e)}})},84754:(e,t,i)=>{i.d(t,{A:()=>c});var s=i(63696),n=i(82871),o=i(50539),r=i(7081),a=i(80035),l=i(62540);const c=function OfflineNotification(){const[e,t]=(0,s.useState)(!1),i=(0,o.useSelect)(e=>e(r.n).getIsOnline());return(0,s.useEffect)(()=>{i&&e&&t(!1)},[i,e]),(0,l.jsx)("div",{"aria-live":"polite",children:!i&&!e&&(0,l.jsx)(a.A,{className:"googlesitekit-notice-snackbar--bottom-right",type:a.A.TYPES.WARNING,description:(0,n.__)("You are currently offline. Some features may not be available.","google-site-kit"),ctaButton:{label:(0,n.__)("OK, Got it!","google-site-kit"),onClick:()=>t(!0)}})})}},84826:(e,t,i)=>{i.d(t,{A:()=>HelpMenu});var s,n=i(62688),o=i.n(n),r=i(21795),a=i(63696),l=i(19266),c=i(82871),d=i(50539),u=i(49383);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 p=e=>a.createElement("svg",g({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 20 20"},e),s||(s=a.createElement("path",{fill:"currentColor",d:"M9 16h2v-2H9zm1-16C4.48 0 0 4.48 0 10s4.48 10 10 10 10-4.48 10-10S15.52 0 10 0m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m0-14C7.79 4 6 5.79 6 8h2c0-1.1.9-2 2-2s2 .9 2 2c0 2-3 1.75-3 5h2c0-2.25 3-2.5 3-5 0-2.21-1.79-4-4-4"})));var m=i(99235),h=i(12850),f=i(20898),y=i(77766),v=i(62540);function HelpMenuLink({children:e,href:t,gaEventLabel:i}){const s=(0,y.A)(),n=(0,a.useCallback)(async()=>{i&&await(0,h.sx)(`${s}_headerbar_helpmenu`,"click_outgoing_link",i)},[i,s]);return(0,v.jsx)("li",{className:"googlesitekit-help-menu-link mdc-list-item",role:"none",children:(0,v.jsx)(f.A,{className:"mdc-list-item__text",href:t,role:"menuitem",onClick:n,external:!0,hideExternalIndicator:!0,children:e})})}HelpMenuLink.propTypes={children:o().node.isRequired,href:o().string.isRequired,gaEventLabel:o().string};const _=HelpMenuLink;var k=i(37226),x=i(93896),I=i(73589);function HelpMenu({children:e}){const[t,i]=(0,a.useState)(!1),s=(0,a.useRef)(),n=(0,y.A)();(0,r.A)(s,()=>i(!1)),(0,m.l)([l._f,l.wn],s,()=>i(!1));const o=(0,d.useSelect)(e=>e(k.i).isModuleActive(I.Py)),g=(0,a.useCallback)(()=>{t||(0,h.sx)(`${n}_headerbar`,"open_helpmenu"),i(!t)},[t,n]),f=(0,a.useCallback)(()=>{i(!1)},[]),A=(0,d.useSelect)(e=>e(x.O4).getDocumentationLinkURL("fix-common-issues"));return(0,v.jsxs)("div",{ref:s,className:"googlesitekit-dropdown-menu googlesitekit-dropdown-menu__icon-menu mdc-menu-surface--anchor",children:[(0,v.jsx)(u.Button,{"aria-controls":"googlesitekit-help-menu","aria-expanded":t,"aria-label":(0,c.__)("Help","google-site-kit"),"aria-haspopup":"menu",className:"googlesitekit-header__dropdown googlesitekit-border-radius-round googlesitekit-button-icon googlesitekit-help-menu__button mdc-button--dropdown",icon:(0,v.jsx)(p,{width:"20",height:"20"}),onClick:g,tooltipEnterDelayInMS:500,text:!0}),(0,v.jsxs)(u.Menu,{className:"googlesitekit-width-auto",menuOpen:t,id:"googlesitekit-help-menu",onSelected:f,children:[e,(0,v.jsx)(_,{gaEventLabel:"fix_common_issues",href:A,children:(0,c.__)("Fix common issues","google-site-kit")}),(0,v.jsx)(_,{gaEventLabel:"documentation",href:"https://sitekit.withgoogle.com/documentation/",children:(0,c.__)("Read help docs","google-site-kit")}),(0,v.jsx)(_,{gaEventLabel:"support_forum",href:"https://wordpress.org/support/plugin/google-site-kit/",children:(0,c.__)("Get support","google-site-kit")}),o&&(0,v.jsx)(_,{gaEventLabel:"adsense_help",href:"https://support.google.com/adsense/",children:(0,c.__)("Get help with AdSense","google-site-kit")})]})]})}HelpMenu.propTypes={children:o().node}},85149:(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","aria-labelledby":"warning-title warning-desc",viewBox:"0 0 24 24"},e),s||(s=o.createElement("path",{fill:"none",d:"M0 0h24v24H0z"})),n||(n=o.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2m1 15h-2v-2h2zm0-4h-2V7h2z"})))},86134:(e,t,i)=>{i.d(t,{N$:()=>n,aO:()=>o,qB:()=>s});const s={BOXES:"boxes",COMPOSITE:"composite"},n={QUARTER:"quarter",HALF:"half",FULL:"full"},o="core/widgets"},87251:(e,t,i)=>{i.d(t,{A:()=>DashboardSharingSettings});var s=i(4452),n=i.n(s),o=i(82871),r=i(50539),a=i(62688),l=i.n(a),c=i(63696),d=i(10072),u=i(77766),g=i(37226),p=i(93896),m=i(7081),h=i(24288),f=i(12850),y=i(58116),v=i(13606),_=i(19266),k=i(49383),x=i(20898),I=i(69195),A=i(11253),j=i(99235),M=i(62540);const S=(0,o.__)("All","google-site-kit"),b=(0,c.forwardRef)(({moduleSlug:e,isLocked:t=!1},i)=>{const s=(0,u.A)(),a=(0,c.useRef)(),{setSharedRoles:l}=(0,r.useDispatch)(g.i),{setValue:d}=(0,r.useDispatch)(m.n),p=(0,r.useSelect)(e=>e(g.i).getShareableRoles()),y=(0,r.useSelect)(t=>t(g.i).getSharedRoles(e)),v=(0,r.useSelect)(e=>e(m.n).getValue(h.zP))===e;(0,j.l)([_._f],i,()=>{v&&d(h.zP,void 0)});const b=(0,r.useSelect)(t=>t(g.i).haveModuleSharingSettingsChanged(e,"sharedRoles")),N=(0,c.useCallback)(()=>{v?(d(h.zP,void 0),b&&(0,f.sx)(`${s}_sharing`,"change_shared_roles",e)):d(h.zP,e)},[v,b,e,d,s]);(0,c.useEffect)(()=>{a.current&&(v?a.current.firstChild.focus():a.current.focus())},[v]);const E=(0,c.useCallback)(({type:t,target:i,keyCode:s})=>{if("keydown"===t&&s!==_.Fm)return;const n=i.closest(".mdc-chip"),o=n?.dataset?.chipId;if(!o)return;let r;r="all"===o?y?.length===p?.length?[]:p.map(({id:e})=>e):null===y?[o]:y.includes(o)?y.filter(e=>e!==o):[...y,o],l(e,r)},[e,l,y,p]);return p?(0,M.jsxs)("div",{className:n()("googlesitekit-user-role-select",{"googlesitekit-user-role-select--open":v}),children:[!v&&(0,M.jsx)(k.Button,{"aria-label":(0,o.__)("Edit roles","google-site-kit"),className:"googlesitekit-user-role-select__button",onClick:N,icon:(0,M.jsx)(I.A,{width:23,height:23}),tabIndex:t?-1:void 0,ref:a}),!v&&y?.length>0&&(0,M.jsx)("span",{className:"googlesitekit-user-role-select__current-roles",children:function(){const e=p?.reduce((e,t)=>(y.includes(t.id)&&e.push(t.displayName),e),[]);return e.join(", ")}()}),!v&&(!y||0===y?.length)&&(0,M.jsx)("span",{className:"googlesitekit-user-role-select__add-roles",children:(0,M.jsx)(x.A,{onClick:N,tabIndex:t?-1:void 0,children:(0,o.__)("Add roles","google-site-kit")})}),v&&(0,M.jsxs)(c.Fragment,{children:[(0,M.jsxs)("div",{className:"googlesitekit-user-role-select__chipset",ref:a,children:[(0,M.jsx)(k.Chip,{id:"all",label:S,onClick:E,onKeyDown:E,selected:y?.length===p?.length,className:"googlesitekit-user-role-select__chip--all"}),p.map(({id:e,displayName:t},i)=>(0,M.jsx)(k.Chip,{id:e,label:t,onClick:E,onKeyDown:E,selected:y?.includes(e)},i))]}),(0,M.jsx)(k.Button,{"aria-label":(0,o.__)("Done editing roles","google-site-kit"),title:(0,o.__)("Done","google-site-kit"),className:"googlesitekit-user-role-select__button",onClick:N,icon:(0,M.jsx)(A.A,{width:18,height:18}),tabIndex:t?-1:void 0})]})]}):null});b.propTypes={moduleSlug:l().string.isRequired,isLocked:l().bool};const N=b;var E=i(80035);const w=(0,c.forwardRef)(({moduleSlug:e,isLocked:t,hasSharingCapability:i,recoverable:s,recoverableModuleSupportLink:n},r)=>i?(0,M.jsx)(N,{moduleSlug:e,isLocked:t,ref:r}):s?(0,M.jsx)(E.A,{className:"googlesitekit-notice--small",type:E.A.TYPES.WARNING,description:(0,v.A)((0,o.__)("Managing user required to manage view access. <a>Learn more</a>","google-site-kit"),{a:(0,M.jsx)(x.A,{href:n,external:!0,hideExternalIndicator:!0})}),hideIcon:!0}):(0,M.jsx)("p",{className:"googlesitekit-dashboard-sharing-settings__note",children:(0,o.__)("Contact managing user to manage view access","google-site-kit")}));w.propTypes={moduleSlug:l().string.isRequired,isLocked:l().bool.isRequired,hasSharingCapability:l().bool,recoverable:l().bool,recoverableModuleSupportLink:l().string},w.displayName="ModuleViewAccess";const C=w;var T=i(12417),D=i(51135);const R=[{value:"owner",label:(0,o.__)("Only me","google-site-kit")},{value:"all_admins",label:(0,o.__)("Any admin signed in with Google","google-site-kit")}];function ModuleManageAccess({sharedOwnershipModule:e,hasOwnedModule:t,ownerUsername:i,hasSharingCapability:s,manageViewAccess:n,onChange:r}){return e?(0,M.jsxs)("p",{className:"googlesitekit-dashboard-sharing-settings__note",children:[(0,M.jsx)("span",{children:(0,o.__)("Any admin signed in with Google","google-site-kit")}),(0,M.jsx)(k.Tooltip,{title:(0,o.__)("This service requires general access to Google APIs rather than access to a specific user-owned property/entity, so view access is manageable by any admin signed in with Google.","google-site-kit"),children:(0,M.jsx)("span",{className:"googlesitekit-dashboard-sharing-settings__tooltip-icon",children:(0,M.jsx)(T.A,{icon:D.A,size:18})})})]}):t?(0,M.jsx)(k.Select,{className:"googlesitekit-dashboard-sharing-settings__select",value:n,options:R,onChange:r,onClick:r,outlined:!0}):i?(0,M.jsxs)("p",{className:"googlesitekit-dashboard-sharing-settings__note",children:[(0,v.A)((0,o.sprintf)(/* translators: %s: user who manages the module. */ /* translators: %s: user who manages the module. */
|
||
(0,o.__)("<span>Managed by</span> <strong>%s</strong>","google-site-kit"),i),{span:(0,M.jsx)("span",{}),strong:(0,M.jsx)("strong",{})}),(0,M.jsx)(k.Tooltip,{title:s?(0,o.sprintf)(/* translators: %s: name of the user who manages the module. */ /* translators: %s: name of the user who manages the module. */
|
||
(0,o.__)("%s has connected this and given managing permissions to all admins. You can change who can view this on the dashboard.","google-site-kit"),i):(0,o.sprintf)(/* translators: %s: name of the user who manages the module. */ /* translators: %s: name of the user who manages the module. */
|
||
(0,o.__)("Contact %s to change who can manage view access for this module","google-site-kit"),i),children:(0,M.jsx)("span",{className:"googlesitekit-dashboard-sharing-settings__tooltip-icon",children:(0,M.jsx)(T.A,{icon:D.A,size:18})})})]}):null}function Module({moduleSlug:e,moduleName:t,ownerUsername:i,recoverable:s}){const o=(0,u.A)(),a=(0,c.useRef)(),[l,v]=(0,c.useState)(void 0),_=(0,r.useSelect)(e=>e(g.i).hasRecoverableModules()),k=(0,r.useSelect)(e=>e(p.O4).hasMultipleAdmins()),x=_||k,I=(0,r.useSelect)(t=>{var i;return null!==(i=t(g.i).getSharingManagement(e))&&void 0!==i?i:"owner"}),A=(0,r.useSelect)(t=>t(y.oR).hasCapability(y.Ml,e)),j=(0,r.useSelect)(t=>t(y.oR).hasCapability(y.hz,e)),S=(0,r.useSelect)(e=>e(g.i).getSharedOwnershipModules()),b=(0,r.useSelect)(e=>e(m.n).getValue(h.zP)),N=(0,r.useSelect)(e=>e(g.i).isDoingSubmitSharingChanges()),E=(0,r.useSelect)(e=>e(p.O4).getDocumentationLinkURL("dashboard-sharing-module-recovery")),{setSharingManagement:w}=(0,r.useDispatch)(g.i),T=S&&Object.keys(S).includes(e);(0,c.useEffect)(()=>{v(T?"all_admins":I)},[I,T]);const D=(0,r.useSelect)(t=>t(g.i).haveModuleSharingSettingsChanged(e,"management"));(0,c.useEffect)(()=>{D&&(0,f.sx)(`${o}_sharing`,`change_management_${I}`,e)},[D,I,e,o]);const R=(0,c.useCallback)(t=>{const i=t.target.value;v(i),w(e,i)},[w,v,e]),O=e===b,z=!O&&void 0!==b||N;return(0,M.jsxs)("div",{className:n()("googlesitekit-dashboard-sharing-settings__module","googlesitekit-dashboard-sharing-settings__row",{"googlesitekit-dashboard-sharing-settings__row--editing":O,"googlesitekit-dashboard-sharing-settings__row--disabled":z}),ref:a,children:[(0,M.jsxs)("div",{className:"googlesitekit-dashboard-sharing-settings__column--product",children:[(0,M.jsx)(d.A,{slug:e,size:48}),(0,M.jsx)("span",{className:"googlesitekit-dashboard-sharing-settings__module-name",children:t})]}),(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__column--view",children:(0,M.jsx)(C,{moduleSlug:e,isLocked:z,hasSharingCapability:j,recoverable:s,recoverableModuleSupportLink:E,ref:a})}),x&&(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__column--manage",children:(0,M.jsx)(ModuleManageAccess,{sharedOwnershipModule:T,hasOwnedModule:A,ownerUsername:i,hasSharingCapability:j,manageViewAccess:l,onChange:R})})]})}function DashboardSharingSettings(){const t=(0,r.useSelect)(e=>e(g.i).hasRecoverableModules()),i=(0,r.useSelect)(e=>e(p.O4).hasMultipleAdmins()),s=t||i,a=(0,r.useSelect)(t=>{const i=t(y.oR).getID(),s=t(g.i).getShareableModules(),n=[],o=[],r=[];for(e of Object.values(s))e.owner?.id===i?n.push(e):t(y.oR).hasCapability(y.hz,e.slug)?o.push(e):r.push(e);return[...n,...o,...r]});return void 0===a?null:(0,M.jsxs)("div",{className:n()("googlesitekit-dashboard-sharing-settings",{"googlesitekit-dashboard-sharing-settings--has-multiple-admins":s}),children:[(0,M.jsxs)("header",{className:"googlesitekit-dashboard-sharing-settings__header googlesitekit-dashboard-sharing-settings__row",children:[(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__column--product",children:(0,o.__)("Product","google-site-kit")}),(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__column--view",children:(0,o.__)("Who can view","google-site-kit")}),s&&(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__column--manage",children:(0,o.__)("Who can manage view access","google-site-kit")})]}),(0,M.jsx)("div",{className:"googlesitekit-dashboard-sharing-settings__main",children:a.map(({slug:e,name:t,owner:i,recoverable:s})=>(0,M.jsx)(Module,{moduleSlug:e,moduleName:t,ownerUsername:i?.login,recoverable:s},e))})]})}ModuleManageAccess.propTypes={sharedOwnershipModule:l().bool,hasOwnedModule:l().bool,ownerUsername:l().string,hasSharingCapability:l().bool,manageViewAccess:l().string,onChange:l().func.isRequired},Module.propTypes={moduleSlug:l().string.isRequired,moduleName:l().string.isRequired,ownerUsername:l().string,recoverable:l().bool},e=i.hmd(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,arguments)}const __WEBPACK_DEFAULT_EXPORT__=e=>n.createElement("svg",o({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 43 44"},e),s||(s=n.createElement("g",{fill:"none",fillRule:"evenodd"},n.createElement("path",{fill:"#FBBC05",d:"m2.253 12.252 7.399 5.658A13 13 0 0 0 9 22c0 1.43.229 2.805.652 4.09l-7.4 5.658A22 22 0 0 1 0 22c0-3.506.81-6.814 2.253-9.748"}),n.createElement("path",{fill:"#EA4335",d:"m9.652 17.91-7.4-5.658A21.94 21.94 0 0 1 22 0c5.6 0 10.6 2.1 14.5 5.5l-6.4 6.4C27.9 10.1 25.1 9 22 9c-5.77 0-10.64 3.725-12.348 8.91"}),n.createElement("path",{fill:"#34A853",d:"m2.25 31.742 7.396-5.67A12.975 12.975 0 0 0 22 35c6.1 0 10.7-3.1 11.8-8.5H22V18h20.5c.3 1.3.5 2.7.5 4 0 14-10 22-21 22A21.94 21.94 0 0 1 2.25 31.742"}),n.createElement("path",{fill:"#4285F4",d:"m36.34 38.52-7.025-5.437c2.297-1.45 3.895-3.685 4.485-6.583H22V18h20.5c.3 1.3.5 2.7.5 4 0 7.17-2.623 12.767-6.66 16.52"}))))},89318:(e,t,i)=>{i.d(t,{M9:()=>M,sx:()=>A,BI:()=>j});var s=i(17243);const n="_googlesitekitDataLayer",o="data-googlesitekit-gtag";function r(e){return function(){e[n]=e[n]||[],e[n].push(arguments)}}var a=i(65214);const l={activeModules:[],isAuthenticated:!1,referenceSiteURL:"",trackingEnabled:!1,trackingID:"",userIDHash:"",userRoles:[]};const{activeModules:c=[],isSiteKitScreen:d,trackingEnabled:u,trackingID:g,referenceSiteURL:p,userIDHash:m,isAuthenticated:h,userRoles:f}=i.g._googlesitekitTrackingData||{},{GOOGLESITEKIT_VERSION:y}=i.g,v={activeModules:c,trackingEnabled:u,trackingID:g,referenceSiteURL:p,userIDHash:m,isSiteKitScreen:d,userRoles:f,isAuthenticated:h,pluginVersion:y},{enableTracking:_,disableTracking:k,isTrackingEnabled:x,initializeSnippet:I,trackEvent:A,trackEventOnce:j}=function(e,t=i.g,c=i.g){const d={...l,...e};d.referenceSiteURL&&(d.referenceSiteURL=d.referenceSiteURL.toString().replace(/\/+$/,""));const u=function(e,t){const s=r(t);let l;const{activeModules:c,referenceSiteURL:d,userIDHash:u,userRoles:g=[],isAuthenticated:p,pluginVersion:m}=e;return function(){const{document:t}=i.g;if(void 0===l&&(l=!!t.querySelector(`script[${o}]`)),l)return!1;l=!0;const r=g?.length?g.join(","):"";s("js",new Date),s("config",e.trackingID,{groups:"site_kit",send_page_view:e.isSiteKitScreen,domain:d,plugin_version:m||"",enabled_features:Array.from(a.t).join(","),active_modules:c.join(","),authenticated:p?"1":"0",user_properties:{user_roles:r,user_identifier:u}});const h=t.createElement("script");return h.setAttribute(o,""),h.async=!0,h.src=`https://www.googletagmanager.com/gtag/js?id=${e.trackingID}&l=${n}`,t.head.appendChild(h),{scriptTagSrc:`https://www.googletagmanager.com/gtag/js?id=${e.trackingID}&l=${n}`}}}(d,t),g=function(e,t,i,s){const n=r(t);return async function(t,o,r,a){const{trackingEnabled:l}=e;if(!l)return null;i();const c={send_to:"site_kit",event_category:t,event_label:r,value:a};return new Promise(e=>{const i=setTimeout(function(){s.console.warn(`Tracking event "${o}" (category "${t}") took too long to fire.`),e()},1e3);function r(){clearTimeout(i),e()}n("event",o,{...c,event_callback:r}),s._gaUserPrefs?.ioo?.()&&r()})}}(d,t,u,c),p={};return{enableTracking:function(){d.trackingEnabled=!0},disableTracking:function(){d.trackingEnabled=!1},initializeSnippet:u,isTrackingEnabled:function(){return!!d.trackingEnabled},trackEvent:g,trackEventOnce:function(...e){const t=JSON.stringify(e);p[t]||(p[t]=(0,s.once)(g)),p[t](...e)}}}(v);function M(e){e?_():k()}d&&u&&I()},89362:(e,t,i)=>{i.d(t,{A:()=>__WEBPACK_DEFAULT_EXPORT__});var s=i(63696);const __WEBPACK_DEFAULT_EXPORT__=function(e,t){const[n,o]=(0,s.useState)(null);return(0,s.useEffect)(()=>{if(e.current&&"function"==typeof i.g.IntersectionObserver){function s(e){o(e[e.length-1])}const n=new i.g.IntersectionObserver(s,t);return n.observe(e.current),()=>{o(null),n.disconnect()}}return()=>{}},[e.current,t.threshold,t.root,t.rootMargin]),n}},89506:(e,t,i)=>{i.d(t,{A:()=>UserSettingsSelectionPanel});var s=i(82871),n=i(63696),o=i(50539),r=i(7081),a=i(58116),l=i(3288),c=i(718),d=i(62688),u=i.n(d),g=i(13606),p=i(45472),m=i(93896),h=i(35323),f=i(20898),y=i(59323),v=i(77766),_=i(24558),k=i(62540);function Header({closePanel:e}){const t=(0,v.A)(),i=(0,h.A)(),r=(0,o.useSelect)(e=>e(m.O4).getSiteKitAdminSettingsURL()),{navigateTo:a}=(0,o.useDispatch)(p.M),l=(0,n.useCallback)(()=>{_.KK===t&&e(),a(r)},[r,a,e,t]);return(0,k.jsx)(c.W4,{title:(0,s.__)("Email reports subscription","google-site-kit"),onCloseClick:e,children:!i&&(0,k.jsx)(y.A,{type:"body",size:"small",children:(0,g.A)((0,s.__)("You can always deactivate this feature in <link>Settings</link>","google-site-kit"),{link:(0,k.jsx)(f.A,{onClick:l,secondary:!0})})})})}var x=i(80035);function SelectionPanelFooter({notice:e,onNoticeDismiss:t}){return(0,k.jsx)("footer",{className:"googlesitekit-selection-panel-footer",children:(0,k.jsx)("div",{className:"googlesitekit-selection-panel-footer__content",children:e?(0,k.jsx)(x.A,{type:e.type,description:e.text,dismissButton:{label:(0,s.__)("Got it","google-site-kit"),onClick:t},hideIcon:!0}):(0,k.jsx)(y.A,{type:"body",size:"small",children:(0,s.__)("This email is generated by Site Kit using data from your dashboard and sent to your WordPress email, so all your data stays with you.","google-site-kit")})})})}SelectionPanelFooter.propTypes={notice:u().shape({text:u().string,type:u().oneOf(["info","success","error"])}),onNoticeDismiss:u().func};var I=i(15167),A=i(4452),j=i.n(A),M=i(63972);function FrequencySelector({isUserSubscribed:e}){const t=(0,n.useMemo)(()=>[(0,s._x)("Sunday","day name","google-site-kit"),(0,s._x)("Monday","day name","google-site-kit"),(0,s._x)("Tuesday","day name","google-site-kit"),(0,s._x)("Wednesday","day name","google-site-kit"),(0,s._x)("Thursday","day name","google-site-kit"),(0,s._x)("Friday","day name","google-site-kit"),(0,s._x)("Saturday","day name","google-site-kit")],[]);const i=(0,o.useSelect)(e=>e(m.O4).getStartOfWeek()),r=(0,o.useSelect)(e=>e(a.oR).getEmailReportingFrequency()),l=(0,o.useSelect)(e=>e(a.oR).getEmailReportingSavedFrequency()),{setEmailReportingFrequency:c}=(0,o.useDispatch)(a.oR),d=(0,s.sprintf)(/* translators: %s: localized day-of-week name (e.g. Monday). */ /* translators: %s: localized day-of-week name (e.g. Monday). */
|
||
(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)),u={weekly:{label:(0,s.__)("Weekly","google-site-kit"),period:(0,s.__)("Last 7 days","google-site-kit"),description:d},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,k.jsxs)(n.Fragment,{children:[(0,k.jsx)(I.A,{className:"googlesitekit-frequency-selector-title",type:"label",size:"small",as:"h3",children:(0,s.__)("Frequency","google-site-kit")}),(0,k.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}=u[t]||{};return(0,k.jsxs)("div",{className:j()("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,k.jsxs)("div",{className:"googlesitekit-frequency-selector__label-row",children:[(0,k.jsx)(I.A,{className:"googlesitekit-frequency-selector__label",type:"label",size:"large",as:"div",children:s}),l===t&&e&&(0,k.jsx)("div",{className:"googlesitekit-frequency-selector__saved-indicator",children:(0,k.jsx)(M.A,{className:"googlesitekit-frequency-selector__label-tick","aria-hidden":"true"})})]}),(0,k.jsx)(I.A,{className:"googlesitekit-frequency-selector__period",type:"body",size:"small",as:"div",children:n}),(0,k.jsx)(I.A,{className:"googlesitekit-frequency-selector__description",type:"body",size:"small",as:"div",children:o})]},t)})})]})}FrequencySelector.propTypes={isUserSubscribed:u().bool};var S=i(2390);const b={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 b.UPDATE_SETTINGS:o();break;case b.SUBSCRIBE:t();break;case b.UNSUBSCRIBE:i()}}return(0,k.jsxs)("div",{className:"googlesitekit-selection-panel-subscribe-actions",children:[e&&(0,k.jsx)(S.A,{onClick:()=>c(b.UNSUBSCRIBE),isSaving:r&&a===b.UNSUBSCRIBE,disabled:r,tertiary:!0,children:(0,s.__)("Unsubscribe","google-site-kit")}),(0,k.jsx)(S.A,{onClick:()=>c(e?b.UPDATE_SETTINGS:b.SUBSCRIBE),isSaving:r&&a!==b.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:d,closePanel:u}){const g=(0,o.useSelect)(e=>e(a.oR).getUser()),p=g?.wpEmail;return(0,k.jsxs)(n.Fragment,{children:[(0,k.jsxs)("div",{className:"googlesitekit-user-settings-selection__panel-content",children:[(0,k.jsx)(Header,{closePanel:u}),(0,k.jsx)("div",{className:"googlesitekit-user-settings-selection__panel-description",children:(0,k.jsxs)(y.A,{type:"body",size:"small",children:[(0,s.__)("You’ll receive the report to your WordPress user email","google-site-kit"),p&&(0,k.jsx)(I.A,{type:"body",size:"medium",children:p})]})}),(0,k.jsx)(FrequencySelector,{isUserSubscribed:t}),(0,k.jsx)(SubscribeActions,{onSubscribe:l,onUnsubscribe:c,updateSettings:r,isSubscribed:t,isLoading:i})]}),(0,k.jsx)(SelectionPanelFooter,{notice:e,onNoticeDismiss:d})]})}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()),[d,u]=(0,n.useState)(null),{setValue:g}=(0,o.useDispatch)(r.n),{saveEmailReportingSettings:p,resetEmailReportingSettings:m}=(0,o.useDispatch)(a.oR),h=(0,n.useCallback)(()=>{e&&(setTimeout(()=>{m(),u(null)},310),g(l.Q,!1))},[e,m,g]),f=(0,n.useCallback)(async()=>{const{error:e}=await p();u(e?{type:"error",text:e?.message||(0,s.__)("An error occurred.","google-site-kit")}:{type:"success",text:(0,s.__)("You’ve successfully updated frequency settings!","google-site-kit")})},[p]),y=(0,n.useCallback)(async()=>{const{error:e}=await p({subscribed:!0});u(e?{type:"error",text:e?.message||(0,s.__)("An error occurred.","google-site-kit")}:{type:"success",text:(0,s.__)("You’ve successfully subscribed to email reports!","google-site-kit")})},[p]),v=(0,n.useCallback)(async()=>{const{error:e}=await p({subscribed:!1});u(e?{type:"error",text:e?.message||(0,s.__)("An error occurred.","google-site-kit")}:{type:"info",text:(0,s.__)("You’ve unsubscribed from email reports","google-site-kit")})},[p]),_=(0,n.useCallback)(()=>u(null),[]);return(0,k.jsx)(c.Ay,{className:"googlesitekit-user-settings-selection-panel",isOpen:!!e,closePanel:h,children:(0,k.jsx)(PanelContent,{notice:d,isUserSubscribed:t?.subscribed,isSavingSettings:i,onSaveCallback:f,onSubscribe:y,onUnsubscribe:v,onNoticeDismiss:_,closePanel:h})})}SubscribeActions.propTypes={isSubscribed:u().bool,onSubscribe:u().func.isRequired,onUnsubscribe:u().func.isRequired,updateSettings:u().func.isRequired,isLoading:u().bool},PanelContent.propTypes={savedFrequency:u().string,notice:u().shape({text:u().string,type:u().oneOf(["info","success","error"])}),onSaveCallback:u().func,onUnsubscribe:u().func,onNoticeDismiss:u().func,closePanel:u().func}},90007:(e,t,i)=>{i.d(t,{Q:()=>v,A:()=>BannerNotification});var s=i(4452),n=i.n(s),o=i(62688),r=i.n(o),a=i(50539),l=i(71423),c=i(7070),d=i(7184),u=i(30823),g=i(3782),p=i(29584),m=i(55527);const h="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMzYwIiBoZWlnaHQ9IjIzNCIgdmlld0JveD0iMCAwIDM2MCAyMzQiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik03My4xMzAyIDE3MC42NjhDODkuMzcxOSAxODkuOTkgMTE1LjQ3NiAxOTUuMTEgMTMxLjg2NSAxODkuOTkxQzE1My4yNDYgMTgzLjMxMiAxNjYuNjcyIDE2Mi45NjcgMTg1LjUwMiAxNjAuNTQ0QzIwNC4zMzMgMTU4LjEyMSAyMTUuNDA2IDE2OC43MDYgMjM1Ljg5NyAxNzAuMjMzQzI1Ni4zODkgMTcxLjc2IDI4MS4yMzIgMTY3LjYzIDI5Mi43OTEgMTM3LjkzNUMzMDQuMzQ5IDEwOC4yMzkgMjkzLjk0OCA3OC4yMzIxIDI3MC4yMTQgNjQuMzYxNUMyNDYuNDgxIDUwLjQ5MDggMjMzLjI3MSA2Ni43Njk0IDIxMC41NjQgNjguMTIzN0MxODcuODU4IDY5LjQ3NzkgMTc4LjAyMyA0NS44NTI4IDE2MS4wMjMgNDQuMzUyOEMxNDQuMDIzIDQyLjg1MjggMTM0LjUyMyA0NS44NTMgMTI0LjUyMyA1OC44NTI5QzExNC41MjMgNzEuODUyOCAxMjAuMzcxIDg1Ljc2NDEgODkuNTIzNSA5OS44NTNDNTguNjc1OCAxMTMuOTQyIDU2Ljg4ODUgMTUxLjM0NSA3My4xMzAyIDE3MC42NjhaIiBmaWxsPSIjRkZFNEIxIi8+CjxnIGZpbHRlcj0idXJsKCNmaWx0ZXIwX2RfMjcwNV8xNzY4NikiPgo8cmVjdCB4PSIxMTYuNTIzIiB5PSI1Ny45MTk5IiB3aWR0aD0iMTI4IiBoZWlnaHQ9IjEyOC41MzMiIHJ4PSI2Ljk4MjUyIiBmaWxsPSIjRUJFRUYwIi8+CjxtYXNrIGlkPSJtYXNrMF8yNzA1XzE3Njg2IiBzdHlsZT0ibWFzay10eXBlOmFscGhhIiBtYXNrVW5pdHM9InVzZXJTcGFjZU9uVXNlIiB4PSIxMTYiIHk9IjU3IiB3aWR0aD0iMTI5IiBoZWlnaHQ9IjEzMiI+CjxyZWN0IHg9IjExNi41MjMiIHk9IjU3LjkxOTkiIHdpZHRoPSIxMjgiIGhlaWdodD0iMTMwLjEzMyIgcng9IjYuOTgyNTIiIGZpbGw9IiNERUUzRTYiLz4KPC9tYXNrPgo8ZyBtYXNrPSJ1cmwoI21hc2swXzI3MDVfMTc2ODYpIj4KPHJlY3QgeD0iMTI1LjA1NyIgeT0iMTE3LjY1MyIgd2lkdGg9IjExMC40IiBoZWlnaHQ9IjMwLjkzMzMiIHJ4PSIzLjc1MTI4IiBmaWxsPSIjRjNGNUY3Ii8+CjxyZWN0IHg9IjEyNS4wNTciIHk9IjEwMy4yNTMiIHdpZHRoPSIxMTAuNCIgaGVpZ2h0PSIzMC45MzMzIiByeD0iMy43NTEyOCIgZmlsbD0iI0YzRjVGNyIvPgo8cmVjdCB4PSIxMjUuMDU3IiB5PSIxNTYuMDUzIiB3aWR0aD0iMTEwLjQiIGhlaWdodD0iMzAuOTMzMyIgcng9IjMuNzUxMjgiIGZpbGw9IiNGM0Y1RjciLz4KPHJlY3Qgd2lkdGg9IjMyIiBoZWlnaHQ9IjE4Ljk0NjUiIHJ4PSIyLjMxNTY5IiB0cmFuc2Zvcm09Im1hdHJpeCgxIDAgMCAtMSAyMDMuNDU3IDk1LjYyNDkpIiBmaWxsPSIjRjNGNUY3Ii8+CjxyZWN0IHdpZHRoPSIzMiIgaGVpZ2h0PSIxOC45NDY1IiByeD0iMi4zMTU2OSIgdHJhbnNmb3JtPSJtYXRyaXgoMSAwIDAgLTEgMTYzLjk5IDk1LjYyNTcpIiBmaWxsPSIjRjNGNUY3Ii8+CjxyZWN0IHdpZHRoPSIzMiIgaGVpZ2h0PSIxOC45NDY1IiByeD0iMi4zMTU2OSIgdHJhbnNmb3JtPSJtYXRyaXgoMSAwIDAgLTEgMTI0LjUyMyA5NS42MjU3KSIgZmlsbD0iI0YzRjVGNyIvPgo8L2c+CjxwYXRoIGQ9Ik0xMTYuNTIzIDY0LjkzNTVDMTE2LjUyMyA2MS4wNzkyIDExOS42NSA1Ny45NTMgMTIzLjUwNiA1Ny45NTNIMjM3LjM4M0MyNDEuMjM5IDU3Ljk1MyAyNDQuMzY1IDYxLjA3OTIgMjQ0LjM2NSA2NC45MzU1VjY4LjUzM0gxMTYuNTIzVjY0LjkzNTVaIiBmaWxsPSJ3aGl0ZSIvPgo8cmVjdCB4PSIxMjEuODEzIiB5PSI2MS40Nzk2IiB3aWR0aD0iMy41MjY2NyIgaGVpZ2h0PSIzLjUyNjY3IiByeD0iMS43NjMzMyIgZmlsbD0iI0YzRjVGNyIvPgo8cmVjdCB4PSIxMjcuMTA0IiB5PSI2MS40Nzk2IiB3aWR0aD0iMy41MjY2NyIgaGVpZ2h0PSIzLjUyNjY3IiByeD0iMS43NjMzMyIgZmlsbD0iI0YzRjVGNyIvPgo8cmVjdCB4PSIxMzIuNDM3IiB5PSI2MS40Nzk2IiB3aWR0aD0iMy41MjY2NyIgaGVpZ2h0PSIzLjUyNjY3IiByeD0iMS43NjMzMyIgZmlsbD0iI0YzRjVGNyIvPgo8L2c+CjxjaXJjbGUgY3g9IjE4MC41MjMiIGN5PSIxMjAuODUzIiByPSIxNy4zNzkzIiBmaWxsPSIjNEUzMzAwIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIuNzU4NjIiLz4KPGNpcmNsZSBjeD0iMS42NTUxNyIgY3k9IjEuNjU1MTciIHI9IjEuNjU1MTciIHRyYW5zZm9ybT0ibWF0cml4KDEgMCAwIC0xIDE3OC44NjggMTE2Ljk5MSkiIGZpbGw9IiNGRkU0QjEiLz4KPHJlY3Qgd2lkdGg9IjMuMzEwMzQiIGhlaWdodD0iOS4zNzkzMSIgcng9IjEuNjU1MTciIHRyYW5zZm9ybT0ibWF0cml4KDEgMCAwIC0xIDE3OC44NjggMTI4LjU3NykiIGZpbGw9IiNGRkU0QjEiLz4KPGRlZnM+CjxmaWx0ZXIgaWQ9ImZpbHRlcjBfZF8yNzA1XzE3Njg2IiB4PSIxMDcuOTkiIHk9IjUxLjUxOTkiIHdpZHRoPSIxNDUuMDY3IiBoZWlnaHQ9IjE0Ni4xMzMiIGZpbHRlclVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgY29sb3ItaW50ZXJwb2xhdGlvbi1maWx0ZXJzPSJzUkdCIj4KPGZlRmxvb2QgZmxvb2Qtb3BhY2l0eT0iMCIgcmVzdWx0PSJCYWNrZ3JvdW5kSW1hZ2VGaXgiLz4KPGZlQ29sb3JNYXRyaXggaW49IlNvdXJjZUFscGhhIiB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMTI3IDAiIHJlc3VsdD0iaGFyZEFscGhhIi8+CjxmZU9mZnNldCBkeT0iMi4xMzMzMyIvPgo8ZmVHYXVzc2lhbkJsdXIgc3RkRGV2aWF0aW9uPSI0LjI2NjY3Ii8+CjxmZUNvbXBvc2l0ZSBpbjI9ImhhcmRBbHBoYSIgb3BlcmF0b3I9Im91dCIvPgo8ZmVDb2xvck1hdHJpeCB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMC4xNSAwIi8+CjxmZUJsZW5kIG1vZGU9Im5vcm1hbCIgaW4yPSJCYWNrZ3JvdW5kSW1hZ2VGaXgiIHJlc3VsdD0iZWZmZWN0MV9kcm9wU2hhZG93XzI3MDVfMTc2ODYiLz4KPGZlQmxlbmQgbW9kZT0ibm9ybWFsIiBpbj0iU291cmNlR3JhcGhpYyIgaW4yPSJlZmZlY3QxX2Ryb3BTaGFkb3dfMjcwNV8xNzY4NiIgcmVzdWx0PSJzaGFwZSIvPgo8L2ZpbHRlcj4KPC9kZWZzPgo8L3N2Zz4K",f="data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNDAwIiBoZWlnaHQ9IjIwMiIgdmlld0JveD0iMCAwIDQwMCAyMDIiIGZpbGw9Im5vbmUiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+CjxwYXRoIGQ9Ik04NC44NTc1IDk3LjYxNjZDMTA1Ljg1NyAxMzQuMDIgMTUzLjIwMSAxMDYuMTIzIDE4MS4zNTcgMTE0LjU3MkMyMDkuNTEzIDEyMy4wMiAyMTMuNDY4IDE2MS41NDUgMjM1Ljg1NyAxNjkuOTI1QzI1OC4yNDUgMTc4LjMwNiAzMDMuMDY4IDE3MS41MTUgMzE2LjAwMiAxMzguMTM1QzMyOC45MzYgMTA0Ljc1NCAzMTIuMTY3IDgzLjY1MjkgMjg3LjY1MiA3Mi4xNjk0QzI2My4xMzYgNjAuNjg1OSAyNjguOTc2IDM2Ljc4MzYgMjM0LjE2NiAyNy44MDA5QzE5OS4zNTcgMTguODE4MiAxNzguNjY1IDQxLjI2NTEgMTQwLjE2NSAzMC43OTI3QzEwMS42NjUgMjAuMzIwNCA2My44NTc4IDYxLjIxMzEgODQuODU3NSA5Ny42MTY2WiIgZmlsbD0iI0ZGREVEMyIvPgo8ZyBmaWx0ZXI9InVybCgjZmlsdGVyMF9kXzI3MDVfMTc2MzMpIj4KPHJlY3QgeD0iMTI3LjY2NiIgeT0iMzcuODQxMSIgd2lkdGg9IjEyOCIgaGVpZ2h0PSIxMjguMTk0IiByeD0iNi45ODI1MiIgZmlsbD0iI0VCRUVGMCIvPgo8bWFzayBpZD0ibWFzazBfMjcwNV8xNzYzMyIgc3R5bGU9Im1hc2stdHlwZTphbHBoYSIgbWFza1VuaXRzPSJ1c2VyU3BhY2VPblVzZSIgeD0iMTI3IiB5PSIzNyIgd2lkdGg9IjEyOSIgaGVpZ2h0PSIxMzEiPgo8cmVjdCB4PSIxMjcuNjY2IiB5PSIzNy44NDExIiB3aWR0aD0iMTI4IiBoZWlnaHQ9IjEyOS43OSIgcng9IjYuOTgyNTIiIGZpbGw9IiNERUUzRTYiLz4KPC9tYXNrPgo8ZyBtYXNrPSJ1cmwoI21hc2swXzI3MDVfMTc2MzMpIj4KPHJlY3QgeD0iMTM2LjIiIHk9Ijk3LjQxNjkiIHdpZHRoPSIxMTAuNCIgaGVpZ2h0PSIzMC44NTE4IiByeD0iMy43NTEyOCIgZmlsbD0iI0YzRjVGNyIvPgo8cmVjdCB4PSIxMzYuMiIgeT0iODMuMDU0NiIgd2lkdGg9IjExMC40IiBoZWlnaHQ9IjMwLjg1MTgiIHJ4PSIzLjc1MTI4IiBmaWxsPSIjRjNGNUY3Ii8+CjxwYXRoIGQ9Ik0xMzYuMiAxMzkuNDY3QzEzNi4yIDEzNy4zOTUgMTM3Ljg3OSAxMzUuNzE2IDEzOS45NTEgMTM1LjcxNkgyNDIuODQ5QzI0NC45MiAxMzUuNzE2IDI0Ni42IDEzNy4zOTUgMjQ2LjYgMTM5LjQ2N1YxNjUuOTM1SDEzNi4yVjEzOS40NjdaIiBmaWxsPSIjRjNGNUY3Ii8+CjxyZWN0IHdpZHRoPSIzMiIgaGVpZ2h0PSIxOC44OTY2IiByeD0iMi4zMTU2OSIgdHJhbnNmb3JtPSJtYXRyaXgoMSAwIDAgLTEgMjE0LjU5OSA3NS40NDY3KSIgZmlsbD0iI0YzRjVGNyIvPgo8cmVjdCB3aWR0aD0iMzIiIGhlaWdodD0iMTguODk2NiIgcng9IjIuMzE1NjkiIHRyYW5zZm9ybT0ibWF0cml4KDEgMCAwIC0xIDE3NS4xMzMgNzUuNDQ3NikiIGZpbGw9IiNGM0Y1RjciLz4KPHJlY3Qgd2lkdGg9IjMyIiBoZWlnaHQ9IjE4Ljg5NjYiIHJ4PSIyLjMxNTY5IiB0cmFuc2Zvcm09Im1hdHJpeCgxIDAgMCAtMSAxMzUuNjY2IDc1LjQ0NzYpIiBmaWxsPSIjRjNGNUY3Ii8+CjwvZz4KPHBhdGggZD0iTTEyNy42NjYgNDQuODU2N0MxMjcuNjY2IDQxLjAwMDQgMTMwLjc5MyAzNy44NzQyIDEzNC42NDkgMzcuODc0MkgyNDguNTI2QzI1Mi4zODIgMzcuODc0MiAyNTUuNTA4IDQxLjAwMDQgMjU1LjUwOCA0NC44NTY3VjQ4LjQyNjNIMTI3LjY2NlY0NC44NTY3WiIgZmlsbD0id2hpdGUiLz4KPHJlY3QgeD0iMTMyLjk1NiIgeT0iNDEuMzkxNSIgd2lkdGg9IjMuNTI2NjciIGhlaWdodD0iMy41MTczNyIgcng9IjEuNzU4NjgiIGZpbGw9IiNGM0Y1RjciLz4KPHJlY3QgeD0iMTM4LjI0NyIgeT0iNDEuMzkxNSIgd2lkdGg9IjMuNTI2NjciIGhlaWdodD0iMy41MTczNyIgcng9IjEuNzU4NjgiIGZpbGw9IiNGM0Y1RjciLz4KPHJlY3QgeD0iMTQzLjU4IiB5PSI0MS4zOTE1IiB3aWR0aD0iMy41MjY2NyIgaGVpZ2h0PSIzLjUxNzM3IiByeD0iMS43NTg2OCIgZmlsbD0iI0YzRjVGNyIvPgo8L2c+CjxjaXJjbGUgY3g9IjE5MS42NjYiIGN5PSIxMDAuOTE1IiByPSIxNi44IiBmaWxsPSIjQUM0MjIwIiBzdHJva2U9IndoaXRlIiBzdHJva2Utd2lkdGg9IjIuNjY2NjciLz4KPHBhdGggZD0iTTE5Mi45MTQgOTMuOTgxOEgxOTAuNDE4QzE5MC4wOTIgOTMuOTgxOCAxODkuODQzIDk0LjI3MTQgMTg5Ljg5MSA5NC41OTM2TDE5MS4xMzkgMTAyLjk3M0MxOTEuMjI5IDEwMy41OCAxOTIuMTA0IDEwMy41OCAxOTIuMTk0IDEwMi45NzNMMTkzLjQ0MiA5NC41OTM2QzE5My40OSA5NC4yNzE0IDE5My4yNCA5My45ODE4IDE5Mi45MTQgOTMuOTgxOFoiIGZpbGw9IiNGRkRFRDMiLz4KPGNpcmNsZSBjeD0iMTkxLjY2NiIgY3k9IjEwNi43ODIiIHI9IjEuNiIgZmlsbD0iI0ZGREVEMyIvPgo8ZGVmcz4KPGZpbHRlciBpZD0iZmlsdGVyMF9kXzI3MDVfMTc2MzMiIHg9IjExOS4xMzMiIHk9IjMxLjQ0MTEiIHdpZHRoPSIxNDUuMDY3IiBoZWlnaHQ9IjE0NS4yNjEiIGZpbHRlclVuaXRzPSJ1c2VyU3BhY2VPblVzZSIgY29sb3ItaW50ZXJwb2xhdGlvbi1maWx0ZXJzPSJzUkdCIj4KPGZlRmxvb2QgZmxvb2Qtb3BhY2l0eT0iMCIgcmVzdWx0PSJCYWNrZ3JvdW5kSW1hZ2VGaXgiLz4KPGZlQ29sb3JNYXRyaXggaW49IlNvdXJjZUFscGhhIiB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMTI3IDAiIHJlc3VsdD0iaGFyZEFscGhhIi8+CjxmZU9mZnNldCBkeT0iMi4xMzMzMyIvPgo8ZmVHYXVzc2lhbkJsdXIgc3RkRGV2aWF0aW9uPSI0LjI2NjY3Ii8+CjxmZUNvbXBvc2l0ZSBpbjI9ImhhcmRBbHBoYSIgb3BlcmF0b3I9Im91dCIvPgo8ZmVDb2xvck1hdHJpeCB0eXBlPSJtYXRyaXgiIHZhbHVlcz0iMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMCAwIDAgMC4xNSAwIi8+CjxmZUJsZW5kIG1vZGU9Im5vcm1hbCIgaW4yPSJCYWNrZ3JvdW5kSW1hZ2VGaXgiIHJlc3VsdD0iZWZmZWN0MV9kcm9wU2hhZG93XzI3MDVfMTc2MzMiLz4KPGZlQmxlbmQgbW9kZT0ibm9ybWFsIiBpbj0iU291cmNlR3JhcGhpYyIgaW4yPSJlZmZlY3QxX2Ryb3BTaGFkb3dfMjcwNV8xNzYzMyIgcmVzdWx0PSJzaGFwZSIvPgo8L2ZpbHRlcj4KPC9kZWZzPgo8L3N2Zz4K";var y=i(62540);const v={INFO:"info",ERROR:"error",WARNING:"warning"};function BannerNotification({notificationID:e,type:t=v.INFO,learnMoreLink:i,dismissButton:s,ctaButton:o,gaTrackingEventArgs:r,...u}){const g=(0,c.A)(e,r?.category),{dismissNotification:p}=(0,a.useDispatch)(l.D);let _=u?.svg;return _||t===v.INFO||(_={desktop:void 0,mobile:void 0,verticalPosition:"center"},t===v.WARNING&&(_.desktop=h),t===v.ERROR&&(_.desktop=f)),(0,y.jsx)("div",{className:n()("googlesitekit-banner-notification",`googlesitekit-banner-notification--${t}`),children:(0,y.jsx)(m.xA,{className:"googlesitekit-page-content",children:(0,y.jsx)(m.fI,{children:(0,y.jsx)(m.fh,{size:12,children:(0,y.jsx)(d.A,{learnMoreLink:i&&{...i,onClick:async function(e){g.clickLearnMore(r?.label,r?.value),await(i?.onClick?.(e))}},dismissButton:s&&{...s,onClick:async function(t){await(s?.onClick?.(t)),g.dismiss(r?.label,r?.value),p(e,{...s?.dismissOptions})}},ctaButton:o&&{...o,onClick:async function(t){g.confirm(r?.label,r?.value),await(o?.onClick?.(t)),o?.dismissOnClick&&p(e,{...o?.dismissOptions})}},svg:_,...u})})})})})}BannerNotification.propTypes={notificationID:r().string.isRequired,type:r().oneOf(Object.values(v)),titleIcon:r().node,title:r().string,description:r().oneOfType([r().string,r().node]),learnMoreLink:r().shape(u.A.propTypes),dismissButton:r().shape(p.A.propTypes),ctaButton:r().shape(g.A.propTypes),gaTrackingEventArgs:r().shape({category:r().string,label:r().string,value:r().number})}},91560:(e,t,i)=>{i.d(t,{A:()=>g});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(13606),l=i(82871),c=i(20898),d=i(35323),u=i(62540);function SourceLink({name:e,href:t,className:i,external:s}){return(0,d.A)()?null:(0,u.jsx)("div",{className:r()("googlesitekit-source-link",i),children:(0,a.A)((0,l.sprintf)(/* translators: %s: source link */ /* translators: %s: source link */
|
||
(0,l.__)("Source: %s","google-site-kit"),`<a>${e}</a>`),{a:(0,u.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 g=SourceLink},92698:(e,t,i)=>{i.d(t,{A:()=>g});var s=i(63696),n=i(50539),o=i(93896),r=i(58116),a=i(37226),l=i(45472),c=i(21134),d=i(89318),u=i(77766);function g(e){const t=(0,u.A)(),i=(0,n.useSelect)(t=>t(a.i).getModule(e)),g=(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,d.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&&g?f:null}},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:()=>d,c1:()=>u.c1,X9:()=>l,JS:()=>o,T5:()=>g,WP:()=>u.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 d({counter:e},{counter:t}){return e-t}function u({counter:e},{counter:t}){return t-e}function g({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(d)[0].counter,f).filter(g).length){h.some(g)&&(h=h.sort(u),h=h.filter(g))}const y=h[0].width;n.push(c),l+=s.Gr[y],l>12?(l-=s.Gr[y],n[m]++,9===l&&([i,l]=r(i,l)),l=s.Gr[y],c++):12===l&&(l=0,c++),i.push(s.Gr[y])}),9===l&&([i,l]=r(i,l)),{columnWidths:i,rowIndexes:n}}var c=i(17243);function d(e,t,{columnWidths:i,rowIndexes:n}){const o=[],r=[...i];if(!e?.length)return{gridColumnWidths:r,overrideComponents:o};let a=null,l=-1,d=[];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,u)=>{if(o.push(null),a=t[s.slug],l=n[u],a)if(g=a,p=t[e[u+1]?.slug],m=l,h=n[u+1],m===h&&(0,c.isEqual)(g,p))d.push(i[u]),r[u]=0;else if(d.length>0){d.push(i[u]);const e=d.reduce((e,t)=>e+t,0);o[u]=a,r[u]=e,d=[]}var g,p,m,h}),{gridColumnWidths:r,overrideComponents:o}}var u=i(35001);function g(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",{d:"M5.625 10L5.625 2.375L9.125 5.875L10 5L5 -1.76555e-07L-2.7055e-07 5L0.875 5.875L4.375 2.375L4.375 10L5.625 10Z",fill:"currentColor"})})}ChangeArrow.propTypes={direction:n().string,invertColor:n().bool,width:n().number,height:n().number},ChangeArrow.defaultProps={direction:"up",invertColor:!1,width:9,height:9};const l=ChangeArrow},97398:(e,t,i)=>{i.d(t,{Y:()=>s});const s="search-console"},98652:(e,t,i)=>{i.d(t,{A:()=>p});var s=i(62688),n=i.n(s),o=i(4452),r=i.n(o),a=i(63696),l=i(82871),c=i(49383),d=i(2362),u=i(20898),g=i(62540);function NewBadge({tooltipTitle:e,learnMoreLink:t,forceOpen:i,hasLeftSpacing:s,hasNoSpacing:n,onLearnMoreClick:o=()=>{}}){const p=(0,g.jsx)(d.A,{className:r()("googlesitekit-new-badge",{"googlesitekit-new-badge--has-no-spacing":n}),label:(0,l.__)("New","google-site-kit"),hasLeftSpacing:s});return e?(0,g.jsx)(c.Tooltip,{tooltipClassName:"googlesitekit-new-badge__tooltip",title:(0,g.jsxs)(a.Fragment,{children:[e,(0,g.jsx)("br",{}),(0,g.jsx)(u.A,{href:t,onClick:o,external:!0,hideExternalIndicator:!0,children:(0,l.__)("Learn more","google-site-kit")})]}),placement:"top",enterTouchDelay:0,leaveTouchDelay:5e3,open:i,interactive:!0,children:p}):p}NewBadge.propTypes={tooltipTitle:n().string,learnMoreLink:n().string,forceOpen:n().bool,onLearnMoreClick:n().func,hasLeftSpacing:n().bool,hasNoSpacing:n().bool};const p=NewBadge},98748:(e,t,i)=>{i.d(t,{A:()=>SurveyViewTrigger});var s=i(63696),n=i(62688),o=i.n(n),r=i(50539),a=i(58116);function SurveyViewTrigger({triggerID:e,ttl:t=0}){const{triggerSurvey:i}=(0,r.useDispatch)(a.oR);return(0,s.useEffect)(()=>{i(e,{ttl:t})},[e,t,i]),null}SurveyViewTrigger.propTypes={triggerID:o().string.isRequired,ttl:o().number}},99235:(e,t,i)=>{i.d(t,{l:()=>n});var s=i(78174);function n(e,t,i){(0,s.A)(i=>e.includes(i.keyCode)&&t.current.contains(i.target),i)}},99455:(e,t,i)=>{i.d(t,{A:()=>u});var s,n=i(82871),o=i(88933),r=i(63696);function a(){return a=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var i=arguments[t];for(var s in i)({}).hasOwnProperty.call(i,s)&&(e[s]=i[s])}return e},a.apply(null,arguments)}const l=e=>r.createElement("svg",a({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 80 21"},e),s||(s=r.createElement("path",{fill:"#5F6368",d:"M62.09 1.664h3.038v.1L58.34 9.593l7.241 10.224v.1H62.7L56.755 11.4 53.95 14.64v5.278h-2.351V1.664h2.35v9.415h.1zM69.985 3.117c0 .454-.167.853-.488 1.175-.322.322-.71.488-1.176.488-.455 0-.854-.166-1.175-.488a1.6 1.6 0 0 1-.488-1.175c0-.466.166-.854.488-1.176s.71-.488 1.175-.488c.455 0 .854.166 1.176.488.332.333.487.72.487 1.176m-.477 4.313v12.498h-2.351V7.43zM77.016 20.128c-1.02 0-1.864-.31-2.54-.943q-1.014-.948-1.031-2.628V9.57h-2.196V7.43h2.196V3.603h2.35V7.43h3.061v2.14h-3.06v6.222c0 .831.166 1.397.488 1.696.321.3.687.444 1.097.444.189 0 .366-.022.555-.067.188-.044.344-.1.499-.166l.743 2.096c-.632.222-1.342.333-2.162.333M2.673 18.952C1.375 18.009.488 16.678 0 14.97l2.883-1.176c.289 1.076.799 1.94 1.542 2.628.732.677 1.619 1.02 2.65 1.02.965 0 1.774-.244 2.45-.742.677-.5 1.01-1.187 1.01-2.052 0-.798-.3-1.453-.887-1.974q-.883-.781-3.094-1.564l-1.22-.432Q3.371 9.997 2.04 8.716C1.153 7.862.71 6.742.71 5.346c0-.966.266-1.853.787-2.673S2.75 1.209 3.693.72C4.624.244 5.678 0 6.864 0c1.708 0 3.072.41 4.081 1.242 1.02.832 1.697 1.752 2.04 2.795L10.236 5.2c-.2-.621-.576-1.164-1.142-1.63-.565-.477-1.286-.71-2.173-.71s-1.641.222-2.251.676-.91 1.032-.91 1.742c0 .676.278 1.22.82 1.663.544.432 1.398.854 2.563 1.253l1.22.41c1.674.577 2.96 1.342 3.88 2.274.921.931 1.376 2.184 1.376 3.748 0 1.275-.322 2.34-.976 3.193a6 6 0 0 1-2.495 1.919 8 8 0 0 1-3.116.621c-1.62 0-3.072-.466-4.358-1.408M15.969 3.449a1.95 1.95 0 0 1-.588-1.43c0-.566.2-1.043.588-1.431A1.95 1.95 0 0 1 17.399 0c.566 0 1.043.2 1.43.588.389.388.588.865.588 1.43 0 .566-.2 1.043-.587 1.43a1.95 1.95 0 0 1-1.43.589c-.566-.012-1.043-.2-1.431-.588m-.067 2.595h2.994v13.883h-2.994zM25.406 19.85c-.544-.2-.987-.466-1.331-.788-.776-.776-1.176-1.84-1.176-3.182V8.683h-2.428v-2.64h2.428V2.13h2.994v3.926h3.372v2.639h-3.372v6.531c0 .743.145 1.276.433 1.575.277.366.743.543 1.42.543.31 0 .576-.044.82-.122q.35-.116.765-.399v2.917c-.599.277-1.32.41-2.173.41a5 5 0 0 1-1.753-.3M33.623 19.407a6.63 6.63 0 0 1-2.529-2.628c-.61-1.12-.909-2.373-.909-3.77 0-1.332.3-2.551.887-3.693.588-1.132 1.409-2.04 2.462-2.706s2.251-1.01 3.593-1.01c1.397 0 2.606.311 3.637.921a6.1 6.1 0 0 1 2.34 2.528c.532 1.076.799 2.274.799 3.627 0 .255-.023.576-.078.953H33.179c.111 1.287.566 2.285 1.375 2.983a4.16 4.16 0 0 0 2.817 1.043c.854 0 1.597-.189 2.218-.588a4.27 4.27 0 0 0 1.508-1.597l2.528 1.198q-.981 1.713-2.561 2.694c-1.054.655-2.318.976-3.782.976q-2.046.033-3.66-.931m7.23-8.051a3.3 3.3 0 0 0-.466-1.453c-.277-.477-.687-.887-1.242-1.208-.554-.322-1.23-.488-2.03-.488-.964 0-1.773.288-2.439.853-.665.566-1.12 1.342-1.375 2.296z"})));var c=i(16834),d=i(62540);const u=function Logo(){return(0,d.jsxs)("div",{className:"googlesitekit-logo","aria-hidden":"true",children:[(0,d.jsx)(o.A,{className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),(0,d.jsx)(l,{className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),(0,d.jsx)(c.A,{children:(0,n.__)("Site Kit by Google Logo","google-site-kit")})]})}},99897:(e,t,i)=>{i.d(t,{A_:()=>d,DF:()=>g,L1:()=>p,M0:()=>r,Mc:()=>a,Ok:()=>c,U9:()=>l,iW:()=>o,ue:()=>n,wq:()=>s,xR:()=>u});const s=1,n=2,o=3,r="enhanced-measurement-activation-banner-tooltip-state",a="enhanced-measurement-activation-banner-dismissed-item",l="_r.explorerCard..selmet",c="_r.explorerCard..seldim",d="_r..dataFilters",u="_r..nav",g="key-metrics-connect-ga4-cta-widget",p="analytics-4"}},e=>{e.O(0,[660],()=>{return t=84707,e(e.s=t);var t});e.O()}]); |