Site Kit by Google - Version 1.14.0

Version Description

Download this release

Release Info

Developer flixos90
Plugin Icon 128x128 Site Kit by Google
Version 1.14.0
Comparing to
See all releases

Code changes from version 1.13.1 to 1.14.0

dist/assets/js/chunk-googlesitekit-adminbar-7bc82ce2559c24c046ce.js ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[1],{1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return o})),n.d(t,"a",(function(){return c})),n.d(t,"e",(function(){return l})),n.d(t,"f",(function(){return u})),n.d(t,"g",(function(){return g})),n.d(t,"h",(function(){return f})),n.d(t,"b",(function(){return h})),n.d(t,"i",(function(){return v})),n.d(t,"j",(function(){return b})),n.d(t,"k",(function(){return E})),n.d(t,"c",(function(){return j})),n.d(t,"l",(function(){return A})),n.d(t,"m",(function(){return C})),n.d(t,"n",(function(){return P})),n.d(t,"o",(function(){return T})),n.d(t,"p",(function(){return L})),n.d(t,"q",(function(){return I})),n.d(t,"r",(function(){return M})),n.d(t,"s",(function(){return W}));var a=n(98);void 0===e.googlesitekit&&(e.googlesitekit={});var r=e.googlesitekit._element||a,i=r.Children,o=r.cloneElement,c=r.Component,s=r.concatChildren,l=r.createContext,u=r.createElement,d=r.createInterpolateElement,g=r.createPortal,f=r.createRef,p=r.findDOMNode,m=r.forwardRef,h=r.Fragment,y=r.isEmptyElement,v=r.isValidElement,b=r.lazy,_=r.memo,k=r.Platform,O=r.RawHTML,E=r.render,S=r.renderToString,D=r.StrictMode,j=r.Suspense,w=r.switchChildrenNodeName,R=r.unmountComponentAtNode,A=r.useCallback,C=r.useContext,N=r.useDebugValue,P=r.useEffect,x=r.useImperativeHandle,T=r.useLayoutEffect,L=r.useMemo,I=r.useReducer,M=r.useRef,W=r.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:i,cloneElement:o,Component:c,concatChildren:s,createContext:l,createElement:u,createInterpolateElement:d,createPortal:g,createRef:f,findDOMNode:p,forwardRef:m,Fragment:h,isEmptyElement:y,isValidElement:v,lazy:b,memo:_,Platform:k,RawHTML:O,render:E,renderToString:S,StrictMode:D,Suspense:j,switchChildrenNodeName:w,unmountComponentAtNode:R,useCallback:A,useContext:C,useDebugValue:N,useEffect:P,useImperativeHandle:x,useLayoutEffect:T,useMemo:L,useReducer:I,useRef:M,useState:W})}).call(this,n(13))},104:function(e,t,n){"use strict";(function(e,a){var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(9),f=n.n(g),p=n(10),m=n.n(p),h=n(4),y=n.n(h),v=n(1),b=n(2),_=n.n(b),k=n(0),O=n(5),E=n(117),S=n(17),D=n(46),j=n(110);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=y()(e);if(t){var r=y()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return m()(this,n)}}var R=function(t){f()(AnalyticsInactiveCTA,t);var n,r=w(AnalyticsInactiveCTA);function AnalyticsInactiveCTA(){return l()(this,AnalyticsInactiveCTA),r.apply(this,arguments)}return d()(AnalyticsInactiveCTA,[{key:"render",value:function(){var t=this.props,n=t.title,r=void 0===n?Object(k.__)("Learn more about what visitors do on your site.","google-site-kit"):n,i=t.description,o=void 0===i?Object(k.__)("Connecting with Google Analytics to see unique vistors, goal completions, top pages and more.","google-site-kit"):i,c=t.ctaLabel,s=void 0===c?Object(k.__)("Set up Analytics","google-site-kit"):c;return e._googlesitekitLegacyData.permissions.canManageOptions?a.createElement(D.a,{title:r,description:o,onClick:AnalyticsInactiveCTA.setupAnalyticsClick,ctaLabel:s}):null}}],[{key:"setupAnalyticsClick",value:(n=c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,Object(O.b)(S.c,"analytics",!0);case 3:return t.next=5,Object(E.a)();case 5:e.location=Object(O.l)("analytics",!0),t.next=11;break;case 8:t.prev=8,t.t0=t.catch(0),Object(O.u)(j.a,{id:"analytics-setup-error",title:Object(k.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 11:case"end":return t.stop()}}),t,null,[[0,8]])}))),function(){return n.apply(this,arguments)})}]),AnalyticsInactiveCTA}(v.a);R.propTypes={title:_.a.string,description:_.a.string,ctaLabel:_.a.string},R.defaultProps={},t.a=R}).call(this,n(13),n(12))},108:function(e,t,n){"use strict";function a(e){return"string"==typeof e&&/^pub-\d+$/.test(e)}function r(e){return"string"==typeof e&&/^ca-pub-\d+$/.test(e)}n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return r}))},109:function(e,t,n){"use strict";var a=n(100);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(a.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,r){if(n)return r(e);setTimeout((function(){n=!0}),1e3);var i=e.parse,o=void 0===i||i,c=e.path;if("string"==typeof e.path){var s,l=(null===(s=e.method)||void 0===s?void 0:s.toUpperCase())||"GET",u=Object(a.getStablePath)(c);if(o&&"GET"===l&&t[u]){var d=Promise.resolve(t[u].body);return delete t[u],d}if("OPTIONS"===l&&t[l]&&t[l][u]){var g=Promise.resolve(t[l][u]);return delete t[l][u],g}}return r(e)}}},110:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(38);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(t){s()(GenericError,t);var n=m(GenericError);function GenericError(){return r()(this,GenericError),n.apply(this,arguments)}return o()(GenericError,[{key:"render",value:function(){return e.createElement(p.a,this.props)}}]),GenericError}(f.a);t.a=h}).call(this,n(12))},111:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(213),y=n.n(h),v=n(18),b=n.n(v),_=n(168),k=n(0),O=n(47),E=n(28),S=n(44);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var j=function(t){s()(Dialog,t);var n=D(Dialog);function Dialog(){var e;return r()(this,Dialog),(e=n.call(this)).state={attributes:[Object(k.__)("Audience overview","google-site-kit"),Object(k.__)("Top pages","google-site-kit"),Object(k.__)("Top acquisition channels","google-site-kit"),Object(k.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(f.h)(),e}return o()(Dialog,[{key:"componentDidMount",value:function(){new S.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,a=t.handleDialog,r=t.title,i=t.provides,o=t.handleConfirm,c=t.subtitle,s=t.confirmButton,l=t.dependentModules,u=t.instanceId,d=t.danger,g="googlesitekit-dialog-label-".concat(u),f="googlesitekit-dialog-description-".concat(u),p=!(!i||!i.length);return e.createElement("div",{ref:this.dialogRef,className:b()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":r?g:void 0,"aria-describedby":p?f:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(y.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},r&&e.createElement("h2",{id:g,className:"mdc-dialog__title"},r),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),p&&e.createElement("section",{id:f,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},i.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),l&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(k.__)("Note: ","google-site-kit")),l),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(O.a,{onClick:o,danger:d},s||Object(k.__)("Disconnect","google-site-kit")),e.createElement(E.a,{className:"mdc-dialog__cancel-button",onClick:function(){return a()},inherit:!0},Object(k.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(f.a);j.propTypes={dialogActive:m.a.bool,handleDialog:m.a.func,handleConfirm:m.a.func.isRequired,title:m.a.string,description:m.a.string,confirmButton:m.a.string,danger:m.a.bool},j.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null,danger:!1},t.a=Object(_.a)(j)}).call(this,n(12))},112:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return h}));var a=n(3),r=n.n(a),i=n(11),o=n.n(i),c=n(19),s=n.n(c),l=n(41),u=n.n(l),d=n(8),g=n.n(d),f=n(43);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=function(t,n,a){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},c=i.client,l=void 0===c||c,d=i.server,p=void 0===d||d,h=i.storeName,y=void 0===h?void 0:h;s()(t,"type is required."),s()(n,"identifier is required."),s()(a,"datapoint is required.");var v=y||"".concat(t,"/").concat(n),b={serverNotifications:p?void 0:{},clientNotifications:l?void 0:{}},_=Object(f.a)({baseName:"getNotifications",controlCallback:function(){return u.a.get(t,n,a)},reducerCallback:function(e,t){return m(m({},e),{},{serverNotifications:t.reduce((function(e,t){return m(m({},e),{},o()({},t.id,t))}),{})})}}),k={addNotification:function(e){return s()(e,"notification is required."),{payload:{notification:e},type:"ADD_NOTIFICATION"}},removeNotification:function(e){return s()(e,"id is required."),{payload:{id:e},type:"REMOVE_NOTIFICATION"}}},O={},E=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:b,n=arguments.length>1?arguments[1]:void 0,a=n.type,r=n.payload;switch(a){case"ADD_NOTIFICATION":var i=r.notification;return m(m({},t),{},{clientNotifications:m(m({},t.clientNotifications||{}),{},o()({},i.id,i))});case"REMOVE_NOTIFICATION":var c=r.id;if(void 0===t.clientNotifications||void 0===t.clientNotifications[c])return void 0!==t.serverNotifications&&void 0!==t.serverNotifications[c]&&e.console.warn('Cannot remove server-side notification with ID "'.concat(c,'"; this may be changed in a future release.')),m({},t);var s=m({},t.clientNotifications);return delete s[c],m(m({},t),{},{clientNotifications:s});default:return m({},t)}},S={getNotifications:r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,_.actions.fetchGetNotifications();case 2:case"end":return e.stop()}}),e)}))};p||delete S.getNotifications;var D={getNotifications:function(e){var t=e.serverNotifications,n=e.clientNotifications;return void 0===t&&void 0===n?t:Object.values(m(m({},t||{}),n||{}))}},j=g.a.combineStores(_,{INITIAL_STATE:b,actions:k,controls:O,reducer:E,resolvers:S,selectors:D});return m(m({},j),{},{STORE_NAME:v})}}).call(this,n(13))},113:function(e,t,n){"use strict";(function(e){var a=n(3),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(9),g=n.n(d),f=n(10),p=n.n(f),m=n(4),h=n.n(m),y=n(1),v=n(2),b=n.n(v),_=n(0),k=n(17),O=n(38);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return p()(this,n)}}var S=function(t){g()(Alert,t);var n,a=E(Alert);function Alert(e){var t;return s()(this,Alert),(t=a.call(this,e)).state={isLoading:!0,alerts:[],error:!1,message:""},t}return u()(Alert,[{key:"componentDidMount",value:function(){this.getAlert()}},{key:"getAlert",value:(n=o()(r.a.mark((function e(){var t,n;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=this.props.module,e.next=4,k.c.get(k.b,t,"notifications",{},!1);case 4:n=e.sent,this.setState({isLoading:!1,error:!1,alerts:n}),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),this.setState({isLoading:!1,error:e.t0.code});case 11:case"end":return e.stop()}}),e,this,[[0,8]])}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.alerts,a=t.error,r=t.isLoading;if(a||r||!n||!n.length)return null;var i=n.map((function(t){return e.createElement(O.a,{id:t.id,key:t.id,title:t.title,description:t.message||t.description,dismiss:Object(_.__)("Dismiss","google-site-kit"),isDismissable:t.isDismissible,format:"small",ctaLink:t.ctaURL,ctaLabel:t.ctaLabel,ctaTarget:t.ctaTarget,type:t.severity})}));return e.createElement(y.b,null,i)}}]),Alert}(y.a);S.propTypes={module:b.a.string.isRequired},t.a=S}).call(this,n(12))},114:function(e,t,n){"use strict";(function(e,a){var r=n(11),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(2),v=n.n(y),b=n(0),_=n(5),k=n(77),O=n(25),E=n(17),S=n(28),D=n(30),j=n(21);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var C=function(t){d()(DashboardAcquisitionPieChart,t);var n=A(DashboardAcquisitionPieChart);function DashboardAcquisitionPieChart(){return c()(this,DashboardAcquisitionPieChart),n.apply(this,arguments)}return l()(DashboardAcquisitionPieChart,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.source;if(!n||n.error||!n.length)return null;var r=Object(j.e)(n);return e.createElement("div",{className:"googlesitekit-chart googlesitekit-chart--pie"},e.createElement(k.a,{data:r,options:{chartArea:{width:"100%",height:"100%"},backgroundColor:"transparent",height:250,legend:{alignment:"center",textStyle:{color:"#5b5b61",fontSize:12}},slices:{0:{color:"#178EC5"},1:{color:"#54B23B"},2:{color:"#EB5729"},3:{color:"#ECED33"},4:{color:"#34CBE3"},5:{color:"#82E88E"}},title:null,width:"100%"},chartType:"pie",id:"overview-piechart",loadHeight:205}),a&&e.createElement("div",{className:"googlesitekit-chart__source"},[Object(b.__)("Source:","google-site-kit")," ",e.createElement(S.a,{key:"link",href:Object(_.m)("googlesitekit-module-analytics"),inherit:!0},Object(b._x)("Analytics","Service name","google-site-kit"))]))}}]),DashboardAcquisitionPieChart}(h.a);C.defaultProps={source:!1},C.propTypes={source:v.a.bool},t.a=Object(O.a)(C,[{type:E.b,identifier:"analytics",datapoint:"report",data:R(R({},j.t),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(_.n)("day"),context:["Dashboard","Single"]}],e.createElement(D.a,{width:"282px",height:"282px",shape:"circular"}),{},j.h,j.f)}).call(this,n(12),n(13))},116:function(e,t,n){"use strict";n.d(t,"a",(function(){return m}));var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(Modal,e);var t=p(Modal);function Modal(e){var n;return r()(this,Modal),(n=t.call(this,e)).el=document.createElement("div"),n.root=document.querySelector(".googlesitekit-plugin")||document.body,n}return o()(Modal,[{key:"componentDidMount",value:function(){this.root.appendChild(this.el)}},{key:"componentWillUnmount",value:function(){this.root.removeChild(this.el)}},{key:"render",value:function(){return Object(f.g)(this.props.children,this.el)}}]),Modal}(f.a)},117:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return g}));var a=n(3),r=n.n(a),i=n(11),o=n.n(i),c=n(14),s=n.n(c),l=n(17);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var g=function(){var t=s()(r.a.mark((function t(){var n,a,i,o,c,s;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,l.c.get(l.a,"user","authentication",{timestamp:Date.now()});case 3:n=t.sent,a=n.authenticated,i=n.requiredScopes,o=n.grantedScopes,c=n.unsatisfiedScopes,s=void 0===c?[]:c,e._googlesitekitLegacyData.setup=d(d({},e._googlesitekitLegacyData.setup||{}),{},{isAuthenticated:a,requiredScopes:i,grantedScopes:o,unsatisfiedScopes:s,needReauthenticate:0<s.length}),t.next=14;break;case 12:t.prev=12,t.t0=t.catch(0);case 14:case"end":return t.stop()}}),t,null,[[0,12]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(13))},12:function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"Children",(function(){return u})),n.d(t,"createRef",(function(){return d})),n.d(t,"Component",(function(){return g})),n.d(t,"PureComponent",(function(){return f})),n.d(t,"createContext",(function(){return p})),n.d(t,"forwardRef",(function(){return m})),n.d(t,"lazy",(function(){return h})),n.d(t,"memo",(function(){return y})),n.d(t,"useCallback",(function(){return v})),n.d(t,"useContext",(function(){return b})),n.d(t,"useEffect",(function(){return _})),n.d(t,"useImperativeHandle",(function(){return k})),n.d(t,"useDebugValue",(function(){return O})),n.d(t,"useLayoutEffect",(function(){return E})),n.d(t,"useMemo",(function(){return S})),n.d(t,"useReducer",(function(){return D})),n.d(t,"useRef",(function(){return j})),n.d(t,"useState",(function(){return w})),n.d(t,"Fragment",(function(){return R})),n.d(t,"Profiler",(function(){return A})),n.d(t,"StrictMode",(function(){return C})),n.d(t,"Suspense",(function(){return N})),n.d(t,"createElement",(function(){return P})),n.d(t,"cloneElement",(function(){return x})),n.d(t,"createFactory",(function(){return T})),n.d(t,"isValidElement",(function(){return L})),n.d(t,"version",(function(){return I})),n.d(t,"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",(function(){return M}));var a=n(11),r=n.n(a),i=n(59),o=n.n(i);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}void 0===e.googlesitekit&&(e.googlesitekit={});var s=e.googlesitekit._react||function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){r()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({default:o.a},i),l=s.default,u=s.Children,d=s.createRef,g=s.Component,f=s.PureComponent,p=s.createContext,m=s.forwardRef,h=s.lazy,y=s.memo,v=s.useCallback,b=s.useContext,_=s.useEffect,k=s.useImperativeHandle,O=s.useDebugValue,E=s.useLayoutEffect,S=s.useMemo,D=s.useReducer,j=s.useRef,w=s.useState,R=s.Fragment,A=s.Profiler,C=s.StrictMode,N=s.Suspense,P=s.createElement,x=s.cloneElement,T=s.createFactory,L=s.isValidElement,I=s.version,M=s.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;void 0===e.googlesitekit._react&&(e.googlesitekit._react={default:o.a,Children:u,createRef:d,Component:g,PureComponent:f,createContext:p,forwardRef:m,lazy:h,memo:y,useCallback:v,useContext:b,useEffect:_,useImperativeHandle:k,useDebugValue:O,useLayoutEffect:E,useMemo:S,useReducer:D,useRef:j,useState:w,Fragment:R,Profiler:A,StrictMode:C,Suspense:N,createElement:P,cloneElement:x,createFactory:T,isValidElement:L,version:I,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:M}),t.default=l}.call(this,n(13))},120:function(e,t,n){"use strict";(function(e){n(1);t.a=function Warning(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#F9BB2D",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"warning-title warning-desc"},e.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),e.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"}))}}).call(this,n(12))},121:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return AdSenseLinkCTA}));n(1);var a=n(0),r=n(46);function AdSenseLinkCTA(){return e.createElement(r.a,{title:Object(a.__)("Link Analytics and AdSense","google-site-kit"),description:Object(a.__)("Get reports for your top earning pages by linking your Analytics and AdSense accounts.","google-site-kit"),ctaLink:"https://support.google.com/adsense/answer/6084409",ctaLabel:Object(a.__)("Learn more","google-site-kit")})}}).call(this,n(12))},122:function(e,t,n){"use strict";(function(e){var a=n(3),r=n.n(a),i=n(11),o=n.n(i),c=n(19),s=n.n(c),l=n(8),u=n.n(l),d=n(20);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var p=u.a.createRegistrySelector,m={permissionError:null,capabilities:void 0},h={clearPermissionScopeError:function(){return{payload:{},type:"CLEAR_PERMISSION_SCOPE_ERROR"}},setPermissionScopeError:function(e){return s()(e,"permissionError is required."),{payload:{permissionError:e},type:"SET_PERMISSION_SCOPE_ERROR"}},receiveCapabilities:function(e){return{type:"RECEIVE_CAPABILITIES",payload:{capabilities:e}}}},y={getCapabilities:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.a.commonActions.getRegistry();case 2:if(!t.sent.select(d.c).getCapabilities()){t.next=5;break}return t.abrupt("return");case 5:return(null===(n=e._googlesitekitUserData)||void 0===n?void 0:n.permissions)||e.console.error("Could not load core/user permissions."),t.next=8,h.receiveCapabilities(null===(a=e._googlesitekitUserData)||void 0===a?void 0:a.permissions);case 8:case"end":return t.stop()}}),t)}))},v={getPermissionScopeError:function(e){return e.permissionError},getCapabilities:function(e){return e.capabilities},hasCapability:p((function(e){return function(t,n){var a=e(d.c).getCapabilities();if(a)return!!a[n]}}))};t.a={INITIAL_STATE:m,actions:h,controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"CLEAR_PERMISSION_SCOPE_ERROR":return f(f({},e),{},{permissionError:null});case"SET_PERMISSION_SCOPE_ERROR":var r=a.permissionError;return f(f({},e),{},{permissionError:r});case"RECEIVE_CAPABILITIES":var i=a.capabilities;return f(f({},e),{},{capabilities:i});default:return f({},e)}},resolvers:y,selectors:v}}).call(this,n(13))},123:function(e,t,n){"use strict";(function(e){var a=n(3),r=n.n(a),i=n(11),o=n.n(i),c=n(19),s=n.n(c),l=n(48),u=n(8),d=n.n(u),g=n(20);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=d.a.createRegistrySelector,h={connectURL:void 0,user:void 0,verified:void 0},y={receiveConnectURL:function(e){return s()(e,"connectURL is required."),{payload:{connectURL:e},type:"RECEIVE_CONNECT_URL"}},receiveUserInfo:function(e){return s()(e,"userInfo is required."),{payload:{user:e},type:"RECEIVE_USER_INFO"}},receiveUserIsVerified:function(e){return s()(void 0!==e,"userIsVerified is required."),{payload:{verified:e},type:"RECEIVE_USER_IS_VERIFIED"}}},v={getConnectURL:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,!(0,n.select)(g.c).getConnectURL()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.connectURL,t.next=12,y.receiveConnectURL(a);case 12:case"end":return t.stop()}}),t)})),getUser:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(g.c).getUser()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.user,t.next=12,y.receiveUserInfo(a);case 12:case"end":return t.stop()}}),t)})),isVerified:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(g.c).isVerified()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.verified,t.next=12,y.receiveUserIsVerified(a);case 12:case"end":return t.stop()}}),t)}))},b={getUser:function(e){return e.user},getConnectURL:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.additionalScopes,a=void 0===n?[]:n,r=t.redirectURL,i=void 0===r?void 0:r,o=e.connectURL,c={redirect:i};if(void 0!==o)return(null==a?void 0:a.length)?Object(l.a)(o,p(p({},c),{},{additional_scopes:a})):Object(l.a)(o,c)},getID:m((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.id:t}})),getName:m((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.name:t}})),getEmail:m((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.email:t}})),getPicture:m((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.picture:t}})),isVerified:function(e){return e.verified}};t.a={INITIAL_STATE:h,actions:y,controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"RECEIVE_CONNECT_URL":var r=a.connectURL;return p(p({},e),{},{connectURL:r});case"RECEIVE_USER_INFO":var i=a.user;return p(p({},e),{},{user:i});case"RECEIVE_USER_IS_VERIFIED":var o=a.verified;return p(p({},e),{},{verified:o});default:return p({},e)}},resolvers:v,selectors:b}}).call(this,n(13))},124:function(e,t,n){"use strict";(function(e){n(1);var a=n(2),r=n.n(a),i=n(18),o=n.n(i);function ChangeArrow(t){var n=t.direction,a=t.invertColor;return e.createElement("svg",{className:o()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(n),{"googlesitekit-change-arrow--inverted-color":a}),width:"9",height:"9",viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("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:r.a.string,invertColor:r.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,n(12))},125:function(e,t,n){"use strict";(function(e){n(1);t.a=function Error(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#EA4336",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"error-title error-desc"},e.createElement("path",{d:"M4.47 21h15.06c1.54 0 2.5-1.67 1.73-3L13.73 4.99c-.77-1.33-2.69-1.33-3.46 0L2.74 18c-.77 1.33.19 3 1.73 3zM12 14c-.55 0-1-.45-1-1v-2c0-.55.45-1 1-1s1 .45 1 1v2c0 .55-.45 1-1 1zm1 4h-2v-2h2v2z"}))}}).call(this,n(12))},126:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(38);t.a=function DashboardPermissionAlert(){return e.createElement(r.a,{id:"permission error",title:Object(a.__)("Permissions issue accessing data","google-site-kit"),description:Object(a.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,n(12))},128:function(e,t,n){"use strict";(function(e,a){n(1);var r=n(0),i=n(5),o=n(46),c=n(89);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],s=arguments.length>2&&void 0!==arguments[2]&&arguments[2],l=arguments.length>3&&void 0!==arguments[3]&&arguments[3],u=Object(i.j)()[t].name,d=e.createElement(o.a
2
+ /* translators: %s: Module name */,{title:Object(r.sprintf)(Object(r.__)("%s activation","google-site-kit"),u)
3
+ /* translators: %s: Module name */,description:Object(r.sprintf)(Object(r.__)("%s module needs to be configured","google-site-kit"),u),ctaLabel:Object(r.__)("Complete activation","google-site-kit"),onClick:function(){a.location=Object(i.l)(t,!0)}});return Object(c.a)(d,n,s,l)}}).call(this,n(12),n(13))},129:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(33),y=n(47);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(AdSenseDashboardOutro,t);var n=v(AdSenseDashboardOutro);function AdSenseDashboardOutro(){return r()(this,AdSenseDashboardOutro),n.apply(this,arguments)}return o()(AdSenseDashboardOutro,[{key:"render",value:function(){var t=Object(m.j)().adsense.accountURL;return e.createElement("section",{className:"googlesitekit-module-outro"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("div",{className:"googlesitekit-module-outro__logo"},e.createElement(h.a,{id:"adsense",height:"36",width:"42"}),e.createElement(h.a,{id:"plus",height:"13",width:"13"}),e.createElement(h.a,{id:"analytics",height:"36",width:"34"})),e.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-module-outro__title "},Object(p.__)("Connect Analytics with AdSense to create a powerful team that shows robust metrics for your site.","google-site-kit")),e.createElement("div",{className:"googlesitekit-module-outro__button"},e.createElement(y.a,{href:t,target:"_blank"},Object(p.__)("Connect Accounts","google-site-kit")))))))}}]),AdSenseDashboardOutro}(f.a);t.a=b}).call(this,n(12))},130:function(e,t,n){"use strict";(function(e,a){var r=n(11),i=n.n(r),o=n(1),c=n(0),s=n(8),l=n.n(s),u=n(5),d=n(62),g=n(25),f=n(17),p=n(39),m=n(51),h=n(131),y=n(21),v=n(20);function b(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function _(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?b(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):b(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var k=l.a.useSelect;t.a=Object(g.a)((function AnalyticsDashboardWidgetTopAcquisitionSources(t){var n=t.data,a=k((function(e){return e(v.c).getDateRange()}));if(!n||!n.length)return null;if(!Array.isArray(n[0].data.totals)||!n[0].data.totals.length)return null;if(!Array.isArray(n[0].data.rows)||!n[0].data.rows.length)return null;var r=Object(d.b)(a),i=[{title:Object(c.__)("Channel","google-site-kit"),tooltip:Object(c.__)("Channel refers to where your traffic originated from","google-site-kit")},{title:Object(c.__)("Users","google-site-kit"),tooltip:Object(c.__)("Number of users that originated from that traffic","google-site-kit")},{title:Object(c.__)("New Users","google-site-kit"),
4
+ /* translators: %s: date range */
5
+ tooltip:Object(c.sprintf)(Object(c.__)("Number of new users to visit your page over last %s","google-site-kit"),r)},{title:Object(c.__)("Sessions","google-site-kit"),
6
+ /* translators: %s: date range */
7
+ tooltip:Object(c.sprintf)(Object(c.__)("Number of sessions users had on your website over last %s","google-site-kit"),r)},{title:Object(c.__)("Percentage","google-site-kit"),tooltip:Object(c.__)("Percentage of sessions","google-site-kit")}],s=n[0].data.totals[0].values[1],l=n[0].data.rows.map((function(t,n){var a=t.metrics[0].values[1]/s*100;return[t.dimensions[0],Object(u.q)(t.metrics[0].values[0]),Object(u.q)(t.metrics[0].values[1]),Object(u.q)(t.metrics[0].values[2]),e.createElement(o.b,{key:"minichart-analytics-top-as-"+n},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(a.toFixed(2),"%")," ",e.createElement(h.a,{percent:a.toFixed(1),index:n})))]})),g=Object(p.b)(l,i,{hideHeader:!1,chartsEnabled:!1});return e.createElement("div",{className:"googlesitekit-details-widget"},e.createElement(p.a,null,g))}),[{type:f.b,identifier:"analytics",datapoint:"report",data:_(_({},y.t),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(u.n)("day"),context:["Single","Dashboard"]}],e.createElement(m.a,{rows:4,rowHeight:50}),{},y.h)}).call(this,n(12),n(13))},131:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(77),m=n(184);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var y=function(t){s()(MiniChart,t);var n=h(MiniChart);function MiniChart(){return r()(this,MiniChart),n.apply(this,arguments)}return o()(MiniChart,[{key:"render",value:function(){var t=this.props,n=t.index,a=t.percent,r={backgroundColor:"transparent",chartArea:{width:"100%",height:"100%"},enableInteractivity:!1,height:28,legend:{position:"none"},slices:{0:{color:m.a[n]},1:{color:"#e6e6e6"}},title:null,tooltip:{trigger:"none"},width:28},i=[["source","percent"],["",+a],["",100-a]];return e.createElement("div",{className:"googlesitekit-mini-chart"},e.createElement(p.a,{data:i,options:r,chartType:"pie",loadSmall:!0,loadCompressed:!0,loadHeight:24,loadText:!1,id:"minichart"+n}))}}]),MiniChart}(f.a);t.a=y}).call(this,n(12))},132:function(e,t,n){"use strict";(function(e,a){n(1);var r=n(0),i=n(48),o=n(8),c=n.n(o),s=n(5),l=n(25),u=n(17),d=n(39),g=n(51),f=n(58),p=c.a.useSelect;t.a=Object(l.a)((function SearchConsoleDashboardWidgetKeywordTable(t){var n=t.data,a=p((function(e){return e(f.a).getPropertyID()})),o=p((function(e){return e(f.a).getServiceURL({path:"/performance/search-analytics",query:{resource_id:a,num_of_days:28}})}));if(!n||!n.length)return null;var c=[{title:Object(r.__)("Keyword","google-site-kit"),tooltip:Object(r.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(r.__)("Clicks","google-site-kit"),tooltip:Object(r.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(r.__)("Impressions","google-site-kit"),tooltip:Object(r.__)("Counted each time your content appears in search results","google-site-kit")}],l=[],u=n.map((function(e,t){var n=e.keys[0];return l[t]=Object(i.a)(o,{query:n}),[n,Object(s.q)(e.clicks),Object(s.q)(e.impressions)]})),g={hideHeader:!1,chartsEnabled:!1,links:l},m=Object(d.b)(u,c,g);return e.createElement(d.a,null,m)}),[{type:u.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"query",limit:10},priority:1,maxAge:Object(s.n)("day"),context:["Single","Dashboard"]}],e.createElement(g.a,{padding:!0}),{createGrid:!0},(function(e){return!e.length}))}).call(this,n(12),n(13))},133:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(DashboardSearchFunnelInner,e);var t=p(DashboardSearchFunnelInner);function DashboardSearchFunnelInner(){return r()(this,DashboardSearchFunnelInner),t.apply(this,arguments)}return o()(DashboardSearchFunnelInner,[{key:"render",value:function(){return null}}]),DashboardSearchFunnelInner}(n(1).a);t.a=Object(f.a)("googlesitekit.DashboardSearchFunnel")(m)},134:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(8),i=n.n(r),o=n(42),c=n(27),s=i.a.useSelect;t.a=function AnalyticsAdSenseDashboardWidgetLayout(t){var n=t.children,r=s((function(e){return e(o.a).getServiceAccountSiteURL()}));return e.createElement(c.a,{header:!0,title:Object(a.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(a.__)("Advanced Settings","google-site-kit"),headerCtaLink:r},n)}}).call(this,n(12))},135:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var a=n(108);function r(e){if(Object(a.b)(e))return e.match(/pub-\d+$/)[0]}},136:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var a=n(225),r=function(e){var t=new URL(e);return Object(a.parse)(t.hostname).domain}},138:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(33);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(r.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(r.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(a.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,n(12))},139:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return Root}));n(1);var a=n(2),r=n.n(a),i=n(8),o=n.n(i),c=n(140),s=n(141),l=n(142),u=n(143);function Root(t){var n=t.children,a=t.registry,r=t.dataAPIContext,i=t.dataAPIModuleArgs;return e.createElement(o.a.RegistryProvider,{value:a},e.createElement(c.a,null,e.createElement(l.a,null,n,r&&e.createElement(u.a,{context:r,args:i})),e.createElement(s.a,null)))}Root.propTypes={children:r.a.node.isRequired,registry:r.a.object,dataAPIContext:r.a.string,dataAPIModuleArgs:r.a.object},Root.defaultProps={registry:o.a}}).call(this,n(12))},140:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(9),l=n.n(s),u=n(10),d=n.n(u),g=n(4),f=n.n(g),p=n(1),m=n(2),h=n.n(m),y=n(0),v=n(38);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var _=function(t){l()(ErrorHandler,t);var n=b(ErrorHandler);function ErrorHandler(e){var t;return i()(this,ErrorHandler),(t=n.call(this,e)).state={error:null,info:null},t}return c()(ErrorHandler,[{key:"componentDidCatch",value:function(t,n){e.console.error("Caught an error:",t,n),this.setState({error:t,info:n})}},{key:"render",value:function(){var e=this.props.children,t=this.state,n=t.error,r=t.info;return n?a.createElement(v.a,{id:"googlesitekit-error",title:Object(y.__)("Site Kit encountered an error","google-site-kit"),description:a.createElement("code",null,n.message),isDismissable:!1,format:"small",type:"win-error"},a.createElement("pre",null,r.componentStack)):e}}]),ErrorHandler}(p.a);_.defaultProps={},_.propTypes={children:h.a.node.isRequired},t.a=_}).call(this,n(13),n(12))},141:function(e,t,n){"use strict";(function(e,a){var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(1),l=n(0),u=n(8),d=n.n(u),g=n(96),f=n(111),p=n(116),m=n(87),h=d.a.useSelect,y=d.a.useDispatch,v=d.a.useRegistry;t.a=function PermissionsModal(){var t,n,r,o=v(),u=h((function(e){return e(g.a).getPermissionScopeError()})),d=h((function(t){var n;return t(g.a).getConnectURL({additionalScopes:null==u||null===(n=u.data)||void 0===n?void 0:n.scopes,redirectURL:e.location.href})})),b=y(g.a).clearPermissionScopeError,_=Object(s.l)((function(){b()}),[b]),k=Object(s.l)(c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(m.c)(o);case 2:e.location.assign(d);case 3:case"end":return t.stop()}}),t)}))),[o,d]);return Object(s.n)((function(){(function(){var e=c()(i.a.mark((function e(){var t,n,a;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(null==u||null===(t=u.data)||void 0===t?void 0:t.skipModal)||!(null==u||null===(n=u.data)||void 0===n||null===(a=n.scopes)||void 0===a?void 0:a.length)){e.next=3;break}return e.next=3,k();case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[k,u]),u?(null==u||null===(t=u.data)||void 0===t||null===(n=t.scopes)||void 0===n?void 0:n.length)?(null==u||null===(r=u.data)||void 0===r?void 0:r.skipModal)?null:a.createElement(p.a,null,a.createElement(f.a,{title:Object(l.__)("Additional Permissions Required","google-site-kit"),subtitle:u.message,confirmButton:Object(l.__)("Proceed","google-site-kit"),dialogActive:!0,handleConfirm:k,handleDialog:_})):(e.console.warn("permissionsError lacks scopes array to use for redirect, so not showing the PermissionsModal. permissionsError was:",u),null):null}}).call(this,n(13),n(12))},142:function(e,t,n){"use strict";var a=n(3),r=n.n(a),i=n(14),o=n.n(i),c=n(35),s=n.n(c),l=n(1),u=n(8),d=n.n(u),g=n(87),f=d.a.useRegistry;t.a=function RestoreSnapshots(e){var t=e.children,n=f(),a=Object(l.s)(!1),i=s()(a,2),c=i[0],u=i[1];return Object(l.n)((function(){c||o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(g.b)(n);case 2:u(!0);case 3:case"end":return e.stop()}}),e)})))()}),[n,c]),c?t:null}},143:function(e,t,n){"use strict";n.d(t,"a",(function(){return CollectModuleData}));var a=n(1),r=n(16),i=(n(17),n(8)),o=n.n(i),c=n(20),s=o.a.useSelect;function CollectModuleData(e){var t=e.context,n=e.args,i=s((function(e){return e(c.c).getDateRange()}));return Object(a.n)((function(){return function(){return Object(r.d)("googlesitekit.moduleDataReset")}}),[i]),Object(a.n)((function(){Object(r.d)("googlesitekit.moduleLoaded",t,n)}),[t,n,i]),null}},149:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(8),i=n.n(r),o=n(44),c=n(62),s=n(20),l=i.a.useSelect,u=i.a.useDispatch;t.a=function DateRangeSelector(){var t=Object.values(Object(c.a)()),n=l((function(e){return e(s.c).getDateRange()})),r=u(s.c).setDateRange,i=Object(a.l)((function(e,t){r(t.dataset.value)}),[t]);return e.createElement(o.j,{enhanced:!0,className:"mdc-select--minimal",name:"time_period",label:"",onEnhancedChange:i,value:n},t.map((function(t){var n=t.slug,a=t.label;return e.createElement(o.i,{key:n,value:n},a)})))}}).call(this,n(12))},154:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(28);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(LayoutHeader,t);var n=b(LayoutHeader);function LayoutHeader(){return r()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.ctaLabel,r=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":r,"mdc-layout-grid__cell--span-12-desktop":!r,"mdc-layout-grid__cell--span-8-tablet":!r})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),r&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(v.a,{href:r,external:!0,inherit:!0},a)))))}}]),LayoutHeader}(f.a);_.propTypes={title:m.a.string,ctaLabel:m.a.string,ctaLink:m.a.string},_.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=_}).call(this,n(12))},155:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(82);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return r()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,a=t.ctaLink,r=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a&&n&&e.createElement(h.a,{className:"googlesitekit-data-block__source",name:n,href:a,external:!0}),r))))}}]),LayoutFooter}(f.a);v.propTypes={ctaLabel:m.a.string,ctaLink:m.a.string},t.a=v}).call(this,n(12))},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return o})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return s})),n.d(t,"e",(function(){return l})),n.d(t,"d",(function(){return f})),n.d(t,"c",(function(){return p}));var a=n(94);void 0===e.googlesitekit&&(e.googlesitekit={});var r=e.googlesitekit._hooks||a,i=r.addAction,o=r.addFilter,c=r.removeAction,s=r.removeFilter,l=r.hasAction,u=r.hasFilter,d=r.removeAllActions,g=r.removeAllFilters,f=r.doAction,p=r.applyFilters,m=r.currentAction,h=r.currentFilter,y=r.doingAction,v=r.doingFilter,b=r.didAction,_=r.didFilter,k=r.actions,O=r.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:i,addFilter:o,removeAction:c,removeFilter:s,hasAction:l,hasFilter:u,removeAllActions:d,removeAllFilters:g,doAction:f,applyFilters:p,currentAction:m,currentFilter:h,doingAction:y,doingFilter:v,didAction:b,didFilter:_,actions:k,filters:O})}).call(this,n(13))},169:function(e,t,n){"use strict";(function(e,a){var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(23),f=n.n(g),p=n(9),m=n.n(p),h=n(10),y=n.n(h),v=n(4),b=n.n(v),_=n(1),k=n(0),O=n(8),E=n.n(O),S=n(5),D=n(111),j=n(47),w=n(170),R=n(116),A=n(34),C=n(20);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var P=E.a.withSelect,x=function(t){m()(UserMenu,t);var n,r=N(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=r.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(f()(t)),t.handleMenuClose=t.handleMenuClose.bind(f()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(f()(t)),t.handleDialog=t.handleDialog.bind(f()(t)),t.handleDialogClose=t.handleDialogClose.bind(f()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(f()(t)),t.menuButtonRef=Object(_.h)(),t.menuRef=Object(_.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var a=this.props.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:if(!a)return;e.location.assign(a);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(S.d)(),document.location=Object(S.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this.props,t=e.proxyPermissionsURL,n=e.userEmail,r=e.userPicture,i=this.state,o=i.dialogActive,c=i.menuOpen;return n?a.createElement(_.b,null,a.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},a.createElement(j.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:r?a.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},a.createElement("img",{className:"mdc-button__icon--image",src:r,alt:Object(k.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:c,ariaControls:"user-menu"},n),a.createElement(w.a,{ref:this.menuRef,menuOpen:c,menuItems:[Object(k.__)("Disconnect","google-site-kit")].concat(t?[Object(k.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),a.createElement(R.a,null,a.createElement(D.a,{dialogActive:o,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(k.__)("Disconnect","google-site-kit"),subtitle:Object(k.__)("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:Object(k.__)("Disconnect","google-site-kit"),provides:[],danger:!0}))):null}}]),UserMenu}(_.a);t.a=P((function(e){return{proxyPermissionsURL:e(A.c).getProxyPermissionsURL(),userEmail:e(C.c).getEmail(),userPicture:e(C.c).getPicture()}}))(x)}).call(this,n(13),n(12))},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return v.a})),n.d(t,"b",(function(){return v.b}));var a=n(11),r=n.n(a),i=n(15),o=n(65),c=n(48),s=n(16),l=n(62),u=n(24),d=n(55),g=n(71),f=n.n(g);function p(e){return f()(e)&&e.hasOwnProperty("code")&&("string"==typeof e.code||"number"==typeof e.code)&&e.hasOwnProperty("message")&&"string"==typeof e.message&&e.hasOwnProperty("data")}var m=n(97),h=n(126),y=n(29),v=n(72),b=n(99);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){r()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var O=function(e,t){var n=k({data:{}},e);return n.data=k({dateRange:t},n.data),n},E={maxRequests:10,combinedGetFromCache:function(e){var t=this;return new Promise((function(n,a){try{var r=[],o=Object(l.c)();Object(i.each)(e,(function(e){var n=O(e,o);n.key=Object(y.c)(n.type,n.identifier,n.datapoint,n.data);var a=Object(y.b)(n.key,n.maxAge);void 0!==a&&(r[n.key]=a,t.resolve(n,a))})),n(r)}catch(e){a()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=[],r=25,u=Object(l.c)();Object(i.each)(e,(function(e){var n=O(e,u);n.key=Object(y.c)(n.type,n.identifier,n.datapoint,n.data);var i=Object(y.b)(n.key,n.maxAge);void 0!==i?(setTimeout((function(){t.resolve(n,i)}),r),r+=25):a.push(n)})),a=Object(i.sortBy)(a,"priority");var g=[],f=[],m={},h=!!a.find((function(e){return e.priority<10}));Object(i.each)(a,(function(e,t){!n&&10<=e.priority&&h?f.push(e):m[e.key]?m[e.key].push(t):(m[e.key]=[t],g.push(e))}));var v=10,b=g.slice(0,v),_=g.slice(v);if(_=_.concat(f),0!==b.length||0!==_.length){0<_.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(_,!0)}),50):this.maxRequests=10;var k=null!==Object(d.c)("datacache");return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/data/",{datacache:k||void 0}),data:{request:b},method:"POST"}).then((function(e){Object(i.each)(e,(function(e,n){if(m[n]){var r=p(e);r&&t.handleWPError(e),Object(i.each)(m[n],(function(n){var i=a[n];r||Object(y.e)(i.key,e),t.resolve(i,e)})),0===_.length&&Object(s.d)("googlesitekit.dataLoaded","api")}else console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(s.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){console.warn("WP Error in data response",e);var t=e.data;if(t&&t.reason){var n=0;["authError","insufficientPermissions"].includes(t.reason)&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.b)(m.a),1),n++),"forbidden"===t.reason&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.b)(h.a),1),n++),n&&Object(s.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(s.g)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+n}))}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},invalidateCacheGroup:b.a,collectModuleData:function(e,t){var n=Object(s.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var a=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=Object(y.c)(e,t,n,r);if(!i){var l=Object(y.b)(s,3600);if(void 0!==l)return new Promise((function(e){e(l)}))}return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),r)}).then((function(e){return i||Object(y.e)(s,e),Promise.resolve(e)})).catch((function(e){return a.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,a){var r={};return r.data=a,Object(o.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:r,method:"POST"}).then((function(a){return E.invalidateCacheGroup(e,t,n),new Promise((function(e){e(a)}))}))},setModuleActive:function(e,t){return this.set(v.a,"modules","activation",{slug:e,active:t})}};Object(s.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData")||Object(s.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData",E.collectModuleData.bind(E));t.c=E},170:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(Menu,t);var n=y(Menu);function Menu(e){var t;return r()(this,Menu),(t=n.call(this,e)).menuRef=Object(f.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new h.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,a=t.menuItems,r=t.onSelected,i=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:i,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},a.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:r.bind(null,n),onKeyDown:r.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(f.a);v.propTypes={menuOpen:m.a.bool.isRequired,menuItems:m.a.array.isRequired,id:m.a.string.isRequired},t.a=v}).call(this,n(12))},171:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(ErrorNotification,e);var t=p(ErrorNotification);function ErrorNotification(){return r()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(f.a)("googlesitekit.ErrorNotification")(m)},172:function(e,t,n){"use strict";(function(e){var a=n(3),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(23),g=n.n(d),f=n(9),p=n.n(f),m=n(10),h=n.n(m),y=n(4),v=n.n(y),b=n(1),_=n(18),k=n.n(_),O=n(85),E=n(0),S=n(173),D=n(175),j=n(113),w=n(176),R=n(75),A=n(76),C=n(49),N=n(129),P=n(64),x=n(93),T=n(5),L=n(91),I=n(92),M=n(88),W=n(27);function U(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return h()(this,n)}}var q=Object(O.a)("googlesitekit.AdSenseDashboardZeroData")((function(){return null})),F=function(t){p()(AdSenseDashboardWidget,t);var n,a=U(AdSenseDashboardWidget);function AdSenseDashboardWidget(e){var t;return s()(this,AdSenseDashboardWidget),(t=a.call(this,e)).state={receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0,zeroData:!1},t.handleDataError=t.handleDataError.bind(g()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(g()(t)),t.handleZeroData=t.handleZeroData.bind(g()(t)),t}return u()(AdSenseDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:(n=o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(P.a)();case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,error:e,errorObj:t,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleZeroData",value:function(){this.setState({zeroData:!0,loading:!1})}},{key:"render",value:function(){var t=this,n=Object(T.j)(),a=this.state,r=a.receivingData,i=a.error,o=a.errorObj,c=a.loading,s=a.isAdSenseConnected,l=a.zeroData,u=n.adsense.homepage,d=c||!r||l?"googlesitekit-nodata":"";return e.createElement(b.b,null,e.createElement(I.a,null),e.createElement("div",{className:d},e.createElement(j.a,{module:"adsense"})),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--adsense"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},!i&&n.adsense.setupComplete?e.createElement(M.a,{title:Object(E._x)("AdSense","Service name","google-site-kit"),icon:!0,iconWidth:"30",iconHeight:"26",iconID:"adsense",status:"connected",statusText:Object(E.__)("AdSense is connected","google-site-kit")}):e.createElement(M.a,{title:Object(E._x)("AdSense","Service name","google-site-kit"),icon:!0,iconWidth:"30",iconHeight:"26",iconID:"adsense",status:"not-connected",statusText:Object(E.__)("AdSense is not connected","google-site-kit")}),c&&e.createElement(C.a,null)),l&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(W.a,{fill:!0},e.createElement(q,null))),!r&&(i?Object(A.a)(Object(E._x)("AdSense","Service name","google-site-kit"),i,!0,!0,!0,o):Object(R.a)(Object(E._x)("AdSense","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(x.a,{slug:"adsense",context:"module-dashboard"}),e.createElement(W.a,{header:!0,title:Object(E.__)("Estimated earnings","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:u},e.createElement(S.a,{handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(W.a,{header:!0,title:Object(E.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:u},e.createElement(D.a,{handleDataError:function(e){e||t.handleZeroData()}}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(w.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(L.a,null))))),!s&&e.createElement(N.a,null))}}]),AdSenseDashboardWidget}(b.a);t.a=F}).call(this,n(12))},173:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(31),y=n(30),v=n(25),b=n(17),_=n(64);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var O=function(t){s()(AdSenseEstimateEarningsWidget,t);var n=k(AdSenseEstimateEarningsWidget);function AdSenseEstimateEarningsWidget(e){var t;return r()(this,AdSenseEstimateEarningsWidget),(t=n.call(this,e)).state={refetch:!1,today:!1,yesterday:!1,sevenDays:!1,month:!1,twentyEightDays:!1,sameDayLastWeek:!1,prev7Days:!1,monthLastYear:!1,prev28Days:!1,error:!1,message:""},t}return o()(AdSenseEstimateEarningsWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var e=this.state,t=e.today,n=e.yesterday,a=e.sevenDays,r=e.month,i=e.twentyEightDays,o=e.sameDayLastWeek,c=e.prev7Days,s=e.monthLastYear,l=e.prev28Days;if(!(t&&n&&a&&r&&i&&o&&c&&s&&l))return null;var u=t.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),d=!!u&&u.currency,g=t.totals?[{className:"googlesitekit-data-block--today",title:Object(p.__)("Today so far","google-site-kit"),datapoint:Object(m.s)(t.totals[0],d)},{className:"googlesitekit-data-block--yesterday",title:Object(p.__)("Yesterday","google-site-kit"),datapoint:Object(m.s)(n.totals[0],d),change:o.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--7days",title:Object(p.__)("Last 7 days","google-site-kit"),datapoint:Object(m.s)(a.totals[0],d),change:c.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--month",title:Object(p.__)("This month","google-site-kit"),datapoint:Object(m.s)(r.totals[0],d),change:s.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--28days",title:Object(p.__)("Last 28 days","google-site-kit"),datapoint:Object(m.s)(i.totals[0],d),change:l.totals[0],changeDataUnit:"%"}]:[];return AdSenseEstimateEarningsWidget.renderLayout(g)}}],[{key:"renderLayout",value:function(t){return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(h.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))}))))}},{key:"renderPreviews",value:function(){for(var t=[],n=0;5>n;n++)t.push(e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(y.a,{width:"100%",height:"104px"})));return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t))}}]),AdSenseEstimateEarningsWidget}(f.a);t.a=Object(v.a)(O,[{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.today)return{today:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"yesterday"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.yesterday)return{yesterday:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"same-day-last-week"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.sameDayLastWeek)return{sameDayLastWeek:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-7-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.sevenDays)return{sevenDays:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-7-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev7Days)return{prev7Days:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.month)return{month:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month-last-year"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.monthLastYear)return{monthLastYear:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.twentyEightDays)return{twentyEightDays:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev28Days)return{prev28Days:n}}}],O.renderPreviews(),{createGrid:!0},_.b)}).call(this,n(12))},174:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(9),l=n.n(s),u=n(10),d=n.n(u),g=n(4),f=n.n(g),p=n(1),m=n(0),h=n(38);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var v=function(t){l()(InvalidCredentialsWarning,t);var n=y(InvalidCredentialsWarning);function InvalidCredentialsWarning(){return i()(this,InvalidCredentialsWarning),n.apply(this,arguments)}return c()(InvalidCredentialsWarning,[{key:"render",value:function(){return e.createElement(h.a,{id:"notification-id",title:Object(m.__)("Security Token Error","google-site-kit"),description:Object(m.__)("We’re unable to retrieve your data because your security token is expired or revoked. Please ","google-site-kit"),learnMoreURL:a._googlesitekitLegacyData.admin.connectURL,learnMoreLabel:Object(m.__)("reauthenticate your account","google-site-kit"),format:"small",type:"win-error"})}}]),InvalidCredentialsWarning}(p.a);t.a=v}).call(this,n(12),n(13))},175:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(15),h=n(5),y=n(17),v=n(31),b=n(30),_=n(64),k=n(25);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(AdSensePerformanceWidget,t);var n=O(AdSensePerformanceWidget);function AdSensePerformanceWidget(e){var t;return r()(this,AdSensePerformanceWidget),(t=n.call(this,e)).state={twentyEightDays:!1,prev28Days:!1},t}return o()(AdSensePerformanceWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.twentyEightDays,a=t.prev28Days,r=n.totals?[{className:"googlesitekit-data-block--page-rpm",title:Object(p.__)("Page RPM","google-site-kit"),datapoint:Object(h.s)(n.totals[1]),change:Object(m.isUndefined)(a.totals)?0:a.totals[1],changeDataUnit:"%"},{className:"googlesitekit-data-block--impression",title:Object(p.__)("Impressions","google-site-kit"),datapoint:Object(h.s)(n.totals[2]),change:Object(m.isUndefined)(a.totals)?0:a.totals[2],changeDataUnit:"%"}]:[];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},r.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(v.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))}))))}}]),AdSensePerformanceWidget}(f.a);t.a=Object(k.a)(E,[{type:y.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.twentyEightDays)return{twentyEightDays:n}}},{type:y.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev28Days)return{prev28Days:n}}}],e.createElement(b.a,{width:"100%",height:"250px"}),{createGrid:!0},_.b)}).call(this,n(12))},176:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(DashboardAdSenseTopPages,e);var t=p(DashboardAdSenseTopPages);function DashboardAdSenseTopPages(){return r()(this,DashboardAdSenseTopPages),t.apply(this,arguments)}return o()(DashboardAdSenseTopPages,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopPages}(n(1).a);t.a=Object(f.a)("googlesitekit.AnalyticsAdSenseTopPagesTable")(m)},177:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(57),h=n(178),y=n(179),v=n(93);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(DashboardEarnings,t);var n=b(DashboardEarnings);function DashboardEarnings(){return r()(this,DashboardEarnings),n.apply(this,arguments)}return o()(DashboardEarnings,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(p.__)("Earnings","google-site-kit"),description:Object(p.__)("How much you’re earning from your content through AdSense.","google-site-kit")}),e.createElement(v.a,{slug:"adsense",context:"module-sitekit-dashboard"})),e.createElement(y.a,null),e.createElement(h.a,null))}}]),DashboardEarnings}(f.a);t.a=_}).call(this,n(12))},178:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(DashboardAdSenseTopEarningPagesSmall,e);var t=p(DashboardAdSenseTopEarningPagesSmall);function DashboardAdSenseTopEarningPagesSmall(){return r()(this,DashboardAdSenseTopEarningPagesSmall),t.apply(this,arguments)}return o()(DashboardAdSenseTopEarningPagesSmall,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopEarningPagesSmall}(n(1).a);t.a=Object(f.a)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall")(m)},179:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(64),h=n(27),y=n(25),v=n(17),b=n(30),_=n(5),k=n(31),O=n(66);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(AdSenseDashboardMainSummary,t);var n=E(AdSenseDashboardMainSummary);function AdSenseDashboardMainSummary(e){var t;return r()(this,AdSenseDashboardMainSummary),(t=n.call(this,e)).state={today:!1,period:!1,daily:!1},t}return o()(AdSenseDashboardMainSummary,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.today,a=t.period,r=t.daily;if(!(n&&a&&r&&a.totals))return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(h.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(b.a,{width:"100%",height:"276px",padding:!0})));var i=Object(m.e)(r.rows),o=Object(_.m)("googlesitekit-module-adsense",{}),c=a.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),s=!!c&&c.currency;return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(h.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-rpm",title:Object(p.__)("RPM","google-site-kit"),datapoint:Object(_.s)(a.totals[1],s),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,2),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-earnings",title:Object(p.__)("Total Earnings","google-site-kit"),datapoint:Object(_.s)(a.totals[0],s),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},change:n.totals[0],changeDataUnit:"$",sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,1),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-impressions",title:Object(p.__)("Ad Impressions","google-site-kit"),datapoint:Object(_.s)(a.totals[2]),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,3),change:1,loadSmall:!1}),context:"compact"})))))))}}]),AdSenseDashboardMainSummary}(f.a);t.a=Object(y.a)(S,[{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.today)return{today:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.period)return{period:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month",dimensions:["DATE"]},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.daily)return{daily:n}}}],e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(h.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(b.a,{width:"100%",height:"276px",padding:!0}))),{inGrid:!0,createGrid:!0},m.b)}).call(this,n(12))},180:function(e,t,n){"use strict";(function(e){var a=n(3),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(23),g=n.n(d),f=n(9),p=n.n(f),m=n(10),h=n.n(m),y=n(4),v=n.n(y),b=n(1),_=n(18),k=n.n(_),O=n(0),E=n(8),S=n.n(E),D=n(92),j=n(181),w=n(182),R=n(183),A=n(130),C=n(27),N=n(88),P=n(114),x=n(113),T=n(49),L=n(75),I=n(76),M=n(129),W=n(64),U=n(62),q=n(91),F=n(20);function H(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return h()(this,n)}}var G=S.a.withSelect,B=function(t){p()(AnalyticsDashboardWidget,t);var n,a=H(AnalyticsDashboardWidget);function AnalyticsDashboardWidget(e){var t;return s()(this,AnalyticsDashboardWidget),(t=a.call(this,e)).state={selectedStats:[0],receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0},t.handleStatSelection=t.handleStatSelection.bind(g()(t)),t.buildSeries=t.buildSeries.bind(g()(t)),t.handleDataError=t.handleDataError.bind(g()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(g()(t)),t}return u()(AnalyticsDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:(n=o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(W.a)();case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleStatSelection",value:function(e){this.setState({selectedStats:[e]})}},{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,loading:!1,error:e,errorObj:t})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"buildSeries",value:function(){var e=this.state.selectedStats,t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"};return{0:{color:t[e],targetAxisIndex:0},1:{color:t[e],targetAxisIndex:0,lineDashStyle:[3,3],lineWidth:1}}}},{key:"render",value:function(){var t=this.state,n=t.selectedStats,a=t.error,r=t.errorObj,i=t.receivingData,o=t.loading,c=t.isAdSenseConnected,s=this.props.dateRange,l=this.buildSeries(),u=!o&&i?"":"googlesitekit-nodata",d=Object(U.b)(s);return e.createElement(b.b,null,e.createElement(D.a,null),e.createElement(x.a,{module:"analytics"}),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--analytics"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(N.a,{title:Object(O._x)("Analytics","Service name","google-site-kit"),icon:!0,iconWidth:"24",iconHeight:"26",iconID:"analytics",status:"connected",statusText:Object(O.__)("Analytics is connected","google-site-kit")}),o&&e.createElement(T.a,null)),!i&&(a?Object(I.a)(Object(O._x)("Analytics","Service name","google-site-kit"),a,!0,!0,!0,r):Object(L.a)(Object(O._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0
8
+ /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Audience overview for the last %s","google-site-kit"),d),headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),headerCtaLink:"http://analytics.google.com"},e.createElement(R.a,{selectedStats:n,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),e.createElement(j.a,{selectedStats:n,series:l,vAxes:null,dateRangeSlug:s}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0,footer:!0
9
+ /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Top content over the last %s","google-site-kit"),d),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement(w.a,null))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0,footer:!0
10
+ /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Top acquisition channels over the last %s","google-site-kit"),d),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(P.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(A.a,null)))))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(q.a,null))))),!o&&!c&&e.createElement(M.a,null))}}]),AnalyticsDashboardWidget}(b.a);t.a=G((function(e){return{dateRange:e(F.c).getDateRange()}}))(B)}).call(this,n(12))},181:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(23),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(0),v=n(5),b=n(77),_=n(25),k=n(17),O=n(21),E=n(30);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var D=function(t){d()(AnalyticsDashboardWidgetSiteStats,t);var n=S(AnalyticsDashboardWidgetSiteStats);function AnalyticsDashboardWidgetSiteStats(e){var t;return i()(this,AnalyticsDashboardWidgetSiteStats),(t=n.call(this,e)).setOptions=t.setOptions.bind(l()(t)),t}return c()(AnalyticsDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,n=t.series,a=t.vAxes,r={chart:{title:""===e._googlesitekitLegacyData.pageTitle?"":Object(y.__)("Users Traffic Summary","google-site-kit")},curveType:"line",height:270,width:"100%",chartArea:{height:"80%",width:"87%"},legend:{position:"top",textStyle:{color:"#616161",fontSize:12}},hAxis:{format:"M/d/yy",gridlines:{color:"#fff"},textStyle:{color:"#616161",fontSize:12}},vAxis:{gridlines:{color:"#eee"},minorGridlines:{color:"#eee"},textStyle:{color:"#616161",fontSize:12},titleTextStyle:{color:"#616161",fontSize:12,italic:!1}}};return r.series=n,r.vAxes=a,r}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.selectedStats,r=e.dateRangeSlug;if(!t||!t.length)return null;var i=r?r.match(/\d+/).map(Number)[0]:28,o=Object(O.c)(t,n,i);if(!o)return null;var c=this.setOptions();return a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement(b.a,{selectedStats:n,data:o,options:c}))))}}]),AnalyticsDashboardWidgetSiteStats}(h.a);t.a=Object(_.a)(D,[{type:k.b,identifier:"analytics",datapoint:"report",data:O.s,priority:1,maxAge:Object(v.n)("day"),context:"Single"}],a.createElement(E.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,n(13),n(12))},182:function(e,t,n){"use strict";(function(e){var a=n(35),r=n.n(a),i=(n(1),n(18)),o=n.n(i),c=n(2),s=n.n(c),l=n(0),u=n(8),d=n.n(u),g=n(5),f=n(25),p=n(17),m=n(39),h=n(51),y=n(21),v=n(22),b=d.a.useSelect,_=function AnalyticsDashboardWidgetTopPagesTable(t){var n=b((function(e){return e(v.h).getAccountID()})),a=b((function(e){return e(v.h).getProfileID()})),i=b((function(e){return e(v.h).getInternalWebPropertyID()})),c=b((function(e){return e(v.h).getServiceURL({path:"/report/content-drilldown/a".concat(n,"w").concat(i,"p").concat(a,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath")})})),s=t.data,u=t.colspan;if(!s||!s.length)return null;if(!Array.isArray(s[0].data.rows))return null;var d=[{title:Object(l.__)("Title","google-site-kit"),tooltip:Object(l.__)("Page Title","google-site-kit"),primary:!0},{title:Object(l.__)("Pageviews","google-site-kit"),tooltip:Object(l.__)("Pageviews","google-site-kit")},{title:Object(l.__)("Unique Pageviews","google-site-kit"),tooltip:Object(l.__)("Unique Pageviews","google-site-kit")},{title:Object(l.__)("Bounce Rate","google-site-kit"),tooltip:Object(l.__)("Bounce Rate","google-site-kit")}],f=[],p=s[0].data.rows.map((function(t,n){var a=Number(t.metrics[0].values[2]),i=r()(t.dimensions,2),o=i[0],s=i[1];return f[n]="".concat(c,":").concat(encodeURIComponent(s.replace(/\//g,"~2F"))),[o,Object(g.q)(t.metrics[0].values[0]),Object(g.q)(t.metrics[0].values[1]),e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap",key:"minichart-"+n},"".concat(a.toFixed(2),"%"))]})),h={hideHeader:!1,chartsEnabled:!1,links:f,hideColumns:{mobile:[2,3]}},y=Object(m.b)(p,d,h);return e.createElement("div",{className:o()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(u))},e.createElement(m.a,null,y))};_.propTypes={data:s.a.array,colspan:s.a.number},_.defaultProps={data:null,colspan:12},t.a=Object(f.a)(_,[{type:p.b,identifier:"analytics",datapoint:"report",data:Object(y.g)(),priority:1,maxAge:Object(g.n)("day"),context:["Single","Dashboard"]}],e.createElement(h.a,{padding:!0}),{createGrid:!0})}).call(this,n(12))},183:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(0),y=n(5),v=n(31),b=n(25),_=n(17),k=n(21),O=n(30);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(AnalyticsDashboardWidgetOverview,t);var n=E(AnalyticsDashboardWidgetOverview);function AnalyticsDashboardWidgetOverview(e){var t;return r()(this,AnalyticsDashboardWidgetOverview),(t=n.call(this,e)).state={report:!1,totalUsers:!1,previousTotalUsers:!1},t}return o()(AnalyticsDashboardWidgetOverview,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props.requestDataToState;this.setState(e)}},{key:"render",value:function(){var t=this.props,n=t.selectedStats,a=t.handleStatSelection,r=this.state,i=r.report,o=r.totalUsers,c=r.previousTotalUsers;if(!i||!i.length||!o)return null;var s=Object(k.b)(i);if(!s)return null;var l=s.totalSessions,u=s.averageBounceRate,d=s.averageSessionDuration,g=s.totalSessionsChange,f=s.averageBounceRateChange,p=s.averageSessionDurationChange,m=Object(y.c)(c,o),b=[{className:"googlesitekit-data-block--users googlesitekit-data-block--button-1",title:Object(h.__)("Users","google-site-kit"),datapoint:Object(y.s)(o),change:m,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:a},{className:"googlesitekit-data-block--sessions googlesitekit-data-block--button-2",title:Object(h.__)("Sessions","google-site-kit"),datapoint:Object(y.s)(l),change:g,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:a},{className:"googlesitekit-data-block--bounce googlesitekit-data-block--button-3",title:Object(h.__)("Bounce Rate","google-site-kit"),datapoint:Number(u).toFixed(2),change:f,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:a,datapointUnit:"%",invertChangeColor:!0},{className:"googlesitekit-data-block--duration googlesitekit-data-block--button-4",title:Object(h.__)("Session Duration","google-site-kit"),datapoint:Object(y.r)(d),change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:a}];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner",role:"toolbar","aria-label":"Line Chart Options"},b.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(v.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection,datapointUnit:t.datapointUnit,invertChangeColor:t.invertChangeColor}))}))))}}]),AnalyticsDashboardWidgetOverview}(f.a);S.propTypes={handleDataError:m.a.func.isRequired},t.a=Object(b.a)(S,[{type:_.b,identifier:"analytics",datapoint:"report",data:k.p,priority:1,maxAge:Object(y.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.report)return{report:n}}},{type:_.b,identifier:"analytics",datapoint:"report",data:k.u,priority:1,maxAge:Object(y.n)("day"),context:["Single"],toState:function(e,t){var n=t.data;if(!1===e.totalUsers)return Object(k.r)(n)}}],e.createElement(O.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},k.h,k.f)}).call(this,n(12))},184:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var a=["#178EC5","#54B23B","#EB5729","#ECED33","#34CBE3","#82E88E"]},185:function(e,t,n){"use strict";(function(e,a){var r=n(32),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(186),v=n(104),b=n(5);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var k=function(t){d()(AnalyticsAdminbarWidget,t);var n=_(AnalyticsAdminbarWidget);function AnalyticsAdminbarWidget(){return c()(this,AnalyticsAdminbarWidget),n.apply(this,arguments)}return l()(AnalyticsAdminbarWidget,[{key:"render",value:function(){return"undefined"!==i()(e._googlesitekitLegacyData.permaLink)&&""===e._googlesitekitLegacyData.permaLink?null:Object(b.j)().analytics.active?a.createElement(y.a,null):a.createElement(h.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(v.a,null)))}}]),AnalyticsAdminbarWidget}(h.a);t.a=k}).call(this,n(13),n(12))},186:function(e,t,n){"use strict";(function(e,a){var r=n(11),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(0),v=n(5),b=n(31),_=n(25),k=n(17),O=n(21),E=n(30);function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var w=function(t){d()(AnalyticsAdminbarWidgetOverview,t);var n=j(AnalyticsAdminbarWidgetOverview);function AnalyticsAdminbarWidgetOverview(e){var t;return c()(this,AnalyticsAdminbarWidgetOverview),(t=n.call(this,e)).state={overview:!1,totalUsers:!1,previousTotalUsers:!1},t}return l()(AnalyticsAdminbarWidgetOverview,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.overview,a=t.totalUsers,r=t.previousTotalUsers;if(!n||!a)return null;var i=n.totalSessions,o=n.totalSessionsChange,c=Object(v.c)(r,a);return e.createElement(h.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(b.a,{className:"overview-total-users",title:Object(y.__)("Total Users","google-site-kit"),datapoint:Object(v.s)(a),change:c,changeDataUnit:"%"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(b.a,{className:"overview-total-sessions",title:Object(y.__)("Total Sessions","google-site-kit"),datapoint:Object(v.s)(i),change:o,changeDataUnit:"%"})))}}]),AnalyticsAdminbarWidgetOverview}(h.a);t.a=Object(_.a)(w,[{type:k.b,identifier:"analytics",datapoint:"report",data:D(D({},O.p),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(v.n)("day"),context:"Adminbar",toState:function(e,t){var n=t.data;if(!e.overview)return{overview:Object(O.b)(n)}}},{type:k.b,identifier:"analytics",datapoint:"report",data:D(D({},O.u),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(v.n)("day"),context:"Adminbar",toState:function(e,t){var n=t.data;if(!1===e.totalUsers)return Object(O.r)(n)}}],e.createElement(h.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(E.a,{width:"auto",height:"59px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(E.a,{width:"auto",height:"59px"}))),{inGrid:!0},O.h,O.f)}).call(this,n(12),n(13))},187:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(23),s=n.n(c),l=n(9),u=n.n(l),d=n(10),g=n.n(d),f=n(4),p=n.n(f),m=n(1),h=n(18),y=n.n(h),v=n(0),b=n(27),_=n(57),k=n(75),O=n(76),E=n(128),S=n(114),D=n(188),j=n(5);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var R=function(t){u()(AnalyticsAllTraffic,t);var n=w(AnalyticsAllTraffic);function AnalyticsAllTraffic(e){var t;return r()(this,AnalyticsAllTraffic),(t=n.call(this,e)).state={receivingData:!0,error:!1},t.handleDataError=t.handleDataError.bind(s()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(s()(t)),t}return o()(AnalyticsAllTraffic,[{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,error:e,errorObj:t})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0})}},{key:"getErrorDataComponent",value:function(){var e=Object(j.j)().analytics,t=e.active,n=e.setupComplete,a=this.state,r=a.error,i=a.errorObj,o=a.receivingData;return t&&!n?Object(E.a)("analytics",!0,!0,!0):o?null:r?Object(O.a)(Object(v._x)("Analytics","Service name","google-site-kit"),r,!0,!0,!0,i):Object(k.a)(Object(v._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)}},{key:"render",value:function(){var t=this.state,n=t.error,a=t.receivingData,r=n||!a?"googlesitekit-nodata":"";return e.createElement(m.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{description:Object(v.__)("How people found your site.","google-site-kit"),title:Object(v.__)("All Traffic","google-site-kit")})),this.getErrorDataComponent(),e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",r)},e.createElement(b.a,{className:"googlesitekit-dashboard-all-traffic"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(S.a,{source:!0,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(D.a,null)))))))}}]),AnalyticsAllTraffic}(m.a);t.a=R}).call(this,n(12))},188:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(25),y=n(17),v=n(39),b=n(131),_=n(51),k=n(21);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,t);var n=O(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources);function AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources(){return r()(this,AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources),n.apply(this,arguments)}return o()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;if(!Array.isArray(t[0].data.totals)||!t[0].data.totals.length)return null;if(!Array.isArray(t[0].data.rows)||!t[0].data.rows.length)return null;var n=[{title:Object(p.__)("Source","google-site-kit"),primary:!0},{title:Object(p.__)("Percent","google-site-kit")}],a=t[0].data.totals[0].values[1],r=t[0].data.rows.map((function(t,n){var r=t.metrics[0].values[1]/a*100;return[t.dimensions[0],e.createElement(f.b,{key:"minichart-"+n},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(r.toFixed(2),"%")," ",e.createElement(b.a,{percent:r.toFixed(1),index:n})))]})),i=Object(v.b)(r,n,{hideHeader:!0,chartsEnabled:!0});return e.createElement("div",{className:"googlesitekit-alltraffic-widget"},e.createElement(v.a,null,i))}}]),AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources}(f.a);t.a=Object(h.a)(E,[{type:y.b,identifier:"analytics",datapoint:"report",data:k.t,priority:1,maxAge:Object(m.n)("day"),context:"Dashboard"}],e.createElement(_.a,{rows:3,rowHeight:50}))}).call(this,n(12))},189:function(e,t,n){"use strict";(function(e,a){var r=n(11),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(15),v=n(0),b=n(5),_=n(21),k=n(31),O=n(25),E=n(17),S=n(66),D=n(46),j=n(30);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var C=function(t){d()(AnalyticsDashboardWidgetTopLevel,t);var n=A(AnalyticsDashboardWidgetTopLevel);function AnalyticsDashboardWidgetTopLevel(e){var t;return c()(this,AnalyticsDashboardWidgetTopLevel),(t=n.call(this,e)).state={accounts:!1,goals:!1,totalUsers:!1,previousTotalUsers:!1},t}return l()(AnalyticsDashboardWidgetTopLevel,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.overview,r=t.extractedAnalytics,i=t.goals,o=t.totalUsers,c=t.previousTotalUsers,s=e._googlesitekitLegacyData.permaLink,l=Object(b.m)("googlesitekit-module-analytics",{}),u="",d="",g="",f="";n&&(u=n.goalCompletions,d=n.goalCompletionsChange,g=n.averageBounceRate,f=n.averageBounceRateChange);var p=Object(b.c)(c,o);return a.createElement(h.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(k.a,{className:"overview-total-users",title:Object(v.__)("Unique Visitors from Search","google-site-kit"),datapoint:Object(b.s)(o),change:p,changeDataUnit:"%",source:{name:Object(v._x)("Analytics","Service name","google-site-kit"),link:l},sparkline:r&&a.createElement(S.a,{data:Object(b.f)(r,1),change:p})})),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},s&&a.createElement(k.a,{className:"overview-bounce-rate",title:Object(v.__)("Bounce Rate","google-site-kit"),datapoint:Number(g).toFixed(2),datapointUnit:Object(v.__)("%","google-site-kit"),change:f,changeDataUnit:"%",invertChangeColor:!0,source:{name:Object(v._x)("Analytics","Service name","google-site-kit"),link:l},sparkline:r&&a.createElement(S.a,{data:Object(b.f)(r,2),change:f})}),!s&&i&&Object(y.isEmpty)(i.items)&&a.createElement(D.a,{title:Object(v.__)("Use goals to measure success.","google-site-kit"),description:Object(v.__)("Goals measure how well your site or app fulfills your target objectives.","google-site-kit"),ctaLink:"https://support.google.com/analytics/answer/1032415?hl=en#create_or_edit_goals",ctaLabel:Object(v.__)("Create a new goal","google-site-kit")}),!s&&i&&!Object(y.isEmpty)(i.items)&&a.createElement(k.a,{className:"overview-goals-completed",title:Object(v.__)("Goals Completed","google-site-kit"),datapoint:Object(b.s)(u),change:d,changeDataUnit:"%",source:{name:Object(v._x)("Analytics","Service name","google-site-kit"),link:l},sparkline:r&&a.createElement(S.a,{data:Object(b.f)(r,3),change:d})}),!s&&!i&&a.createElement(j.a,{width:"100%",height:"202px"})))}}]),AnalyticsDashboardWidgetTopLevel}(h.a);t.a=Object(O.a)(C,[{type:E.b,identifier:"analytics",datapoint:"report",data:R(R({},_.p),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(b.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.overview)return{overview:Object(_.b)(n)}}},{type:E.b,identifier:"analytics",datapoint:"report",data:R(R({},_.u),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(b.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!1===e.totalUsers)return Object(_.r)(n)}},{type:E.b,identifier:"analytics",datapoint:"report",data:R(R({},_.s),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(b.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.extractedAnalytics)return{extractedAnalytics:Object(_.d)(n)}}},{type:E.b,identifier:"analytics",datapoint:"goals",data:{url:e._googlesitekitLegacyData.permaLink},priority:1,maxAge:Object(b.n)("hour"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.goals)return{goals:n}}}],a.createElement(h.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(j.a,{width:"100%",height:"202px"})),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(j.a,{width:"100%",height:"202px"}))),{inGrid:!0},(function(e,t){return"report"===t&&Object(_.h)(e)}),_.f)}).call(this,n(13),n(12))},190:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(21),y=n(191),v=n(31),b=n(46),_=n(25),k=n(17);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(WPAnalyticsDashboardWidgetOverview,t);var n=O(WPAnalyticsDashboardWidgetOverview);function WPAnalyticsDashboardWidgetOverview(e){var t;return r()(this,WPAnalyticsDashboardWidgetOverview),(t=n.call(this,e)).state={overview:!1,totalUsers:!1,previousTotalUsers:!1},t}return o()(WPAnalyticsDashboardWidgetOverview,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.overview,a=t.totalUsers,r=t.previousTotalUsers;if(!n||!a)return null;var i=n.averageSessionDuration,o=n.averageSessionDurationChange,c=Object(m.c)(r,a);return e.createElement(f.b,null,0===a?e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(b.a,{title:Object(p.__)("Analytics Gathering Data","google-site-kit"),description:Object(p.__)("Analytics data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})):e.createElement(f.b,null,e.createElement(v.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-users",title:Object(p.__)("Total Unique Visitors","google-site-kit"),datapoint:Object(m.s)(a),change:c,changeDataUnit:"%"}),e.createElement(v.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-average-session-duration",title:Object(p.__)("Avg. Time on Page","google-site-kit"),datapoint:Object(m.r)(i),change:o,changeDataUnit:"%"})))}}]),WPAnalyticsDashboardWidgetOverview}(f.a);t.a=Object(_.a)(E,[{type:k.b,identifier:"analytics",datapoint:"report",data:h.p,priority:1,maxAge:Object(m.n)("day"),context:"WPDashboard",toState:function(e,t){var n=t.data;if(!e.overview)return{overview:Object(h.b)(n)}}},{type:k.b,identifier:"analytics",datapoint:"report",data:h.u,priority:1,maxAge:Object(m.n)("day"),context:"WPDashboard",toState:function(e,t){var n=t.data;if(!1===e.totalUsers)return Object(h.r)(n)}}],e.createElement(y.a,{width:"23%",height:"94px",count:2}),{},h.h,h.f)}).call(this,n(12))},191:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(30);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(PreviewBlocks,t);var n=y(PreviewBlocks);function PreviewBlocks(){return r()(this,PreviewBlocks),n.apply(this,arguments)}return o()(PreviewBlocks,[{key:"render",value:function(){for(var t=this.props,n=t.width,a=t.height,r=t.shape,i=t.count,o=[],c=0;c++<i;)o.push(e.createElement(h.a,{width:n,height:a,shape:r,key:c}));return o}}]),PreviewBlocks}(f.a);v.propTypes={width:m.a.string,height:m.a.string,shape:m.a.string,count:m.a.number},v.defaultProps={width:"100px",height:"100px",shape:"square",count:1},t.a=v}).call(this,n(12))},192:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(57),h=n(27),y=n(130),v=n(114);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,t);var n=b(AnalyticsDashboardDetailsWidgetTopAcquisitionSources);function AnalyticsDashboardDetailsWidgetTopAcquisitionSources(){return r()(this,AnalyticsDashboardDetailsWidgetTopAcquisitionSources),n.apply(this,arguments)}return o()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(p.__)("All Traffic","google-site-kit"),description:Object(p.__)("How people found your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{className:"googlesitekit-analytics-acquisition-sources",footer:!0,headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(p.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(p._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(v.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(y.a,null)))))))}}]),AnalyticsDashboardDetailsWidgetTopAcquisitionSources}(f.a);t.a=_}).call(this,n(12))},193:function(e,t,n){"use strict";(function(e){var a=n(35),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(9),u=n.n(l),d=n(10),g=n.n(d),f=n(4),p=n.n(f),m=n(1),h=n(0),y=n(25),v=n(17),b=n(39),_=n(51),k=n(5),O=n(21);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var S=function(t){u()(WPAnalyticsDashboardWidgetTopPagesTable,t);var n=E(WPAnalyticsDashboardWidgetTopPagesTable);function WPAnalyticsDashboardWidgetTopPagesTable(){return o()(this,WPAnalyticsDashboardWidgetTopPagesTable),n.apply(this,arguments)}return s()(WPAnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data;if(Object(O.h)(t))return null;if(!t||!t.length)return null;if(!Array.isArray(t[0].data.rows))return null;var n=[],a=t[0].data.rows.map((function(e,t){var a=r()(e.dimensions,2),i=a[0],o=a[1];return n[t]=o.startsWith("/")?o:"/"+o,[i,Object(k.q)(e.metrics[0].values[0])]})),i=[{title:Object(h.__)("Title","google-site-kit"),tooltip:Object(h.__)("Page Title","google-site-kit"),primary:!0},{title:Object(h.__)("Pageviews","google-site-kit"),tooltip:Object(h.__)("Pageviews","google-site-kit")}],o={chartsEnabled:!0,links:n,cap:5,showURLs:!0},c=Object(b.b)(a,i,o);return e.createElement("div",{className:"googlesitekit-search-console-widget"},e.createElement("h2",{className:"googlesitekit-search-console-widget__title"},Object(h.__)("Top content over the last 28 days","google-site-kit")),e.createElement(b.a,null,c))}}]),WPAnalyticsDashboardWidgetTopPagesTable}(m.a);t.a=Object(y.a)(S,[{type:v.b,identifier:"analytics",datapoint:"report",data:Object(O.g)(),priority:1,maxAge:Object(k.n)("day"),context:"WPDashboard"}],e.createElement(_.a,{rows:6}))}).call(this,n(12))},194:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(8),i=n.n(r),o=n(5),c=n(25),s=n(17),l=n(39),u=n(51),d=n(89),g=n(121),f=n(21),p=n(22),m=n(134),h=i.a.useSelect;t.a=Object(c.a)((function AnalyticsAdSenseDashboardWidgetTopPagesTable(t){var n=t.data,r=h((function(e){return e(p.h).getAccountID()})),i=h((function(e){return e(p.h).getProfileID()})),c=h((function(e){return e(p.h).getInternalWebPropertyID()})),s=h((function(e){return e(p.h).getServiceURL({path:"/report/content-pages/a".concat(r,"w").concat(c,"p").concat(i,"/explorer-table.plotKeys=[]&_r.drilldown=analytics.pagePath:~2F")})}));if(Object(f.h)(n))return null;if(!n||!n.length)return null;if(!Array.isArray(n[0].data.rows))return null;var u=[{title:Object(a.__)("Page Title","google-site-kit"),tooltip:Object(a.__)("Page Title","google-site-kit"),primary:!0},{title:Object(a.__)("Earnings","google-site-kit"),tooltip:Object(a.__)("Earnings","google-site-kit")},{title:Object(a.__)("Page RPM","google-site-kit"),tooltip:Object(a.__)("Page RPM","google-site-kit")},{title:Object(a.__)("Impressions","google-site-kit"),tooltip:Object(a.__)("Impressions","google-site-kit")}],d=n[0].data.rows.map((function(e){return[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2),Number(e.metrics[0].values[1]).toFixed(2),Object(o.q)(e.metrics[0].values[2])]})),g={hideHeader:!1,chartsEnabled:!1,links:n[0].data.rows.map((function(e){var t=e.dimensions[1].replace(/\//g,"~2F");return encodeURI(s+t)}))},y=Object(l.b)(d,u,g);return e.createElement(m.a,null,e.createElement(l.a,null,y))}),[{type:s.b,identifier:"analytics",datapoint:"report",data:f.a,priority:1,maxAge:Object(o.n)("day"),context:"Single"}],e.createElement(m.a,null,e.createElement(u.a,{padding:!0})),{createGrid:!0},(function(){return!1}),(function(t){return t.code&&t.message&&t.data&&t.data.status?"badRequest"===t.data.reason?e.createElement(m.a,null,Object(d.a)(e.createElement(g.a,null),!1,!1,!0)):t.message:!!t.error&&(400===t.error.code&&"INVALID_ARGUMENT"===t.error.status&&Object(o.j)().analytics.active?null:t.error.message?t.error.message:t.error.errors&&t.error.errors[0]&&t.error.errors[0].message?t.error.errors[0].message:Object(a.__)("Unidentified error","google-site-kit"))}))}).call(this,n(12))},195:function(e,t,n){"use strict";(function(e){var a=n(35),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(9),u=n.n(l),d=n(10),g=n.n(d),f=n(4),p=n.n(f),m=n(1),h=n(0),y=n(5),v=n(21),b=n(25),_=n(17),k=n(39),O=n(51),E=n(27);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var D=function(t){u()(AnalyticsDashboardWidgetPopularPagesTable,t);var n=S(AnalyticsDashboardWidgetPopularPagesTable);function AnalyticsDashboardWidgetPopularPagesTable(){return o()(this,AnalyticsDashboardWidgetPopularPagesTable),n.apply(this,arguments)}return s()(AnalyticsDashboardWidgetPopularPagesTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;if(!Array.isArray(t[0].data.rows))return null;var n=[{title:Object(h.__)("Most popular content","google-site-kit"),primary:!0},{title:Object(h.__)("Views","google-site-kit")}],a=[],i=t[0].data.rows.map((function(e,t){var n=r()(e.dimensions,2),i=n[0],o=n[1];return a[t]=o.startsWith("/")?o:"/"+o,[i,Object(y.q)(e.metrics[0].values[0])]})),o={hideHeader:!1,chartsEnabled:!1,links:a,showURLs:!0},c=Object(k.b)(i,n,o);return AnalyticsDashboardWidgetPopularPagesTable.renderLayout(e.createElement(k.a,null,c))}}],[{key:"renderLayout",value:function(t){return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(E.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(h._x)("Analytics","Service name","google-site-kit"),footerCtaLink:Object(y.j)().analytics.homepage,fill:!0},t))}}]),AnalyticsDashboardWidgetPopularPagesTable}(m.a);t.a=Object(b.a)(D,[{type:_.b,identifier:"analytics",datapoint:"report",data:Object(v.g)(),priority:1,maxAge:Object(y.n)("day"),context:["Single","Dashboard"]}],D.renderLayout(e.createElement(O.a,{padding:!0})),{inGrid:!0,createGrid:!0},v.h)}).call(this,n(12))},196:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(25),h=n(17),y=n(39),v=n(51),b=n(27),_=n(121),k=n(5),O=n(21);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(AdSenseDashboardWidgetTopPagesTableSmall,t);var n=E(AdSenseDashboardWidgetTopPagesTableSmall);function AdSenseDashboardWidgetTopPagesTableSmall(){return r()(this,AdSenseDashboardWidgetTopPagesTableSmall),n.apply(this,arguments)}return o()(AdSenseDashboardWidgetTopPagesTableSmall,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;if(!Array.isArray(t[0].data.rows))return null;var n=[{title:Object(p.__)("Top Earning Pages","google-site-kit"),tooltip:Object(p.__)("Top Earning Pages","google-site-kit"),primary:!0},{title:Object(p.__)("Revenue","google-site-kit"),tooltip:Object(p.__)("Revenue","google-site-kit")}],a=[],r=t[0].data.rows.map((function(e,t){return a[t]=e.dimensions[1],[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2)]})),i={hideHeader:!1,chartsEnabled:!1,cap:5,links:a},o=Object(y.b)(r,n,i);return AdSenseDashboardWidgetTopPagesTableSmall.renderLayout(e.createElement(y.a,null,o))}}],[{key:"renderLayout",value:function(t){return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(b.a,{className:"googlesitekit-top-earnings-pages",footer:!0,footerCtaLabel:Object(p._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"http://analytics.google.com",fill:!0},t))}}]),AdSenseDashboardWidgetTopPagesTableSmall}(f.a);t.a=Object(m.a)(S,[{type:h.b,identifier:"analytics",datapoint:"report",data:O.a,priority:1,maxAge:Object(k.n)("day"),context:"Dashboard"}],S.renderLayout(e.createElement(v.a,{rows:5,padding:!0})),{inGrid:!0,createGrid:!0},O.h,(function(t){if(t.code&&t.message&&t.data&&t.data.status)return"badRequest"===t.data.reason?e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(b.a,{className:"googlesitekit-top-earnings-pages",fill:!0},e.createElement(_.a,null))):t.message;if(t&&t.errors){var n=Object.values(t.errors);if(n[0]&&n[0][0])return n[0][0]}return!1}))}).call(this,n(12))},197:function(e,t,n){"use strict";(function(e){var a=n(11),r=n.n(a),i=n(35),o=n.n(i),c=n(1),s=n(18),l=n.n(s),u=n(0),d=n(8),g=n.n(d),f=n(92),p=n(198),m=n(132),h=n(199),y=n(88),v=n(27),b=n(113),_=n(49),k=n(75),O=n(76),E=n(62),S=n(91),D=n(58),j=n(20);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}var R=g.a.useSelect;t.a=function GoogleSitekitSearchConsoleDashboardWidget(){var t,n,a=Object(c.s)([0,1]),i=o()(a,2),s=i[0],d=i[1],g=Object(c.s)(!0),A=o()(g,2),C=A[0],N=A[1],P=Object(c.s)(!1),x=o()(P,2),T=x[0],L=x[1],I=Object(c.s)(),M=o()(I,2),W=M[0],U=M[1],q=Object(c.s)(!0),F=o()(q,2),H=F[0],G=F[1],B=R((function(e){return e(j.c).getDateRange()})),z=R((function(e){return e(D.a).getPropertyID()})),V=R((function(e){return e(D.a).getServiceURL({query:{resource_id:z}})})),K=(t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"},s.map((function(e,n){return{color:t[e],targetAxisIndex:n}}))),Y=(n={0:Object(u.__)("Clicks","google-site-kit"),1:Object(u.__)("Impressions","google-site-kit"),2:Object(u.__)("Average CTR","google-site-kit"),3:Object(u.__)("Average Position","google-site-kit")},s.map((function(e){var t={};return 3===e&&(t.direction=-1),function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){r()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({title:n[e]},t)}))),J=!H&&C?"":"googlesitekit-nodata",$=Object(E.b)(B);return e.createElement(c.b,null,e.createElement(f.a,null),e.createElement(b.a,{module:"search-console"}),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--search-console"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(y.a,{title:Object(u._x)("Search Console","Service name","google-site-kit"),icon:!0,iconWidth:"23",iconHeight:"21",iconID:"search-console",status:"connected",statusText:Object(u.__)("Search Console is connected","google-site-kit")}),H&&e.createElement(_.a,null)),!C&&(T?Object(O.a)(Object(u._x)("Search Console","Service name","google-site-kit"),T,!0,!0,!0,W):Object(k.a)(Object(u._x)("Search Console","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:l()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",J)},e.createElement(v.a,{header:!0
11
+ /* translators: %s: date range */,title:Object(u.sprintf)(Object(u.__)("Overview for the last %s","google-site-kit"),$),headerCtaLabel:Object(u.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:V},e.createElement(h.a,{selectedStats:s,handleStatSelection:function(e){var t=s.slice();s.includes(e)?t=s.filter((function(t){return e!==t})):t.push(e),0!==t.length&&d(t)},handleDataError:function(e,t){N(!1),L(e),U(t),G(!1)},handleDataSuccess:function(){N(!0),G(!1)}}),e.createElement(p.a,{selectedStats:s,series:K,vAxes:Y}))),e.createElement("div",{className:l()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",J)},e.createElement(v.a
12
+ /* translators: %s: date range */,{title:Object(u.sprintf)(Object(u.__)("Top search queries over the last %s","google-site-kit"),$),header:!0,footer:!0,headerCtaLabel:Object(u.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:V,footerCtaLabel:Object(u._x)("Search Console","Service name","google-site-kit"),footerCtaLink:V},e.createElement(m.a,null))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(S.a,null))))))}}).call(this,n(12))},198:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(23),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(0),v=n(5),b=n(25),_=n(17),k=n(77),O=n(30),E=n(53);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var D=function(t){d()(SearchConsoleDashboardWidgetSiteStats,t);var n=S(SearchConsoleDashboardWidgetSiteStats);function SearchConsoleDashboardWidgetSiteStats(e){var t;return i()(this,SearchConsoleDashboardWidgetSiteStats),(t=n.call(this,e)).setOptions=t.setOptions.bind(l()(t)),t}return c()(SearchConsoleDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,n=t.selectedStats,a=t.series,r=t.vAxes,i=e._googlesitekitLegacyData.pageTitle,o=Object(y.__)("Search Traffic Summary","google-site-kit");i&&i.length&&(
13
+ /* translators: %s: page title */
14
+ o=Object(y.sprintf)(Object(y.__)("Search Traffic Summary for %s","google-site-kit"),Object(v.e)(i)));var c={chart:{title:o},curveType:"line",height:270,width:"100%",chartArea:{height:"80%",width:"87%"},legend:{position:"top",textStyle:{color:"#616161",fontSize:12}},hAxis:{format:"M/d/yy",gridlines:{color:"#fff"},textStyle:{color:"#616161",fontSize:12}},vAxis:{gridlines:{color:"#eee"},minorGridlines:{color:"#eee"},textStyle:{color:"#616161",fontSize:12},titleTextStyle:{color:"#616161",fontSize:12,italic:!1}}};return c.series=a,c.vAxes=r,3<=n.length&&(c.vAxis.textPosition="none",c.vAxis.gridlines.color="#fff",c.vAxis.minorGridlines.color="#fff",c.chartArea.width="98%"),c}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.selectedStats;if(!t||!t.length)return null;var r=this.setOptions(),i=Object(E.a)(t);return a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement(k.a,{selectedStats:n,data:i.dataMap,options:r,singleStat:!1}))))}}]),SearchConsoleDashboardWidgetSiteStats}(h.a);t.a=Object(b.a)(D,[{type:_.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(v.n)("day"),context:"Single"}],a.createElement(O.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,n(13),n(12))},199:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(31),y=n(25),v=n(17),b=n(30),_=n(53),k=n(2),O=n.n(k);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(SearchConsoleDashboardWidgetOverview,t);var n=E(SearchConsoleDashboardWidgetOverview);function SearchConsoleDashboardWidgetOverview(){return r()(this,SearchConsoleDashboardWidgetOverview),n.apply(this,arguments)}return o()(SearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.selectedStats,r=t.handleStatSelection;if(!n||!n.length)return null;var i=Object(_.a)(n),o=i.totalClicks,c=i.totalImpressions,s=i.averageCTR,l=i.averagePosition,u=i.totalClicksChange,d=i.totalImpressionsChange,g=i.averageCTRChange,m=i.averagePositionChange,y=[{className:"googlesitekit-data-block--clicks googlesitekit-data-block--button-1",title:Object(p.__)("Total Clicks","google-site-kit"),datapoint:o,change:u,changeDataUnit:"%",context:"button",selected:a.includes(0),handleStatSelection:r},{className:"googlesitekit-data-block--impressions googlesitekit-data-block--button-2",title:Object(p.__)("Total Impressions","google-site-kit"),datapoint:c,change:d,changeDataUnit:"%",context:"button",selected:a.includes(1),handleStatSelection:r},{className:"googlesitekit-data-block--ctr googlesitekit-data-block--button-3",title:Object(p.__)("Average CTR","google-site-kit"),datapoint:s+"%",change:g,changeDataUnit:"%",context:"button",selected:a.includes(2),handleStatSelection:r},{className:"googlesitekit-data-block--position googlesitekit-data-block--button-4",title:Object(p.__)("Average Position","google-site-kit"),datapoint:l,change:m,changeDataUnit:"%",context:"button",selected:a.includes(3),handleStatSelection:r}];return e.createElement(f.b,null,e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner",role:"toolbar","aria-label":"Line Chart Options"},y.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(h.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))})))))}}]),SearchConsoleDashboardWidgetOverview}(f.a);S.propTypes={handleDataError:O.a.func.isRequired},t.a=Object(y.a)(S,[{type:v.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"]}],e.createElement(b.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},_.b)}).call(this,n(12))},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return i}));var a="core/user",r="googlesitekit_manage_options",i="missing_required_scopes"},200:function(e,t,n){"use strict";(function(e,a){var r=n(32),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(1),y=n(201);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var b=function(t){d()(GoogleSitekitSearchConsoleAdminbarWidget,t);var n=v(GoogleSitekitSearchConsoleAdminbarWidget);function GoogleSitekitSearchConsoleAdminbarWidget(){return c()(this,GoogleSitekitSearchConsoleAdminbarWidget),n.apply(this,arguments)}return l()(GoogleSitekitSearchConsoleAdminbarWidget,[{key:"render",value:function(){return"undefined"!==i()(e._googlesitekitLegacyData.permaLink)&&""===e._googlesitekitLegacyData.permaLink?null:a.createElement(y.a,null)}}]),GoogleSitekitSearchConsoleAdminbarWidget}(h.a);t.a=b}).call(this,n(13),n(12))},201:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(9),l=n.n(s),u=n(10),d=n.n(u),g=n(4),f=n.n(g),p=n(1),m=n(0),h=n(5),y=n(31),v=n(25),b=n(17),_=n(53),k=n(30);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var E=function(t){l()(SearchConsoleAdminbarWidgetOverview,t);var n=O(SearchConsoleAdminbarWidgetOverview);function SearchConsoleAdminbarWidgetOverview(){return i()(this,SearchConsoleAdminbarWidgetOverview),n.apply(this,arguments)}return c()(SearchConsoleAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error)return null;var n=Object(_.a)(t),a=n.totalClicks,r=n.totalImpressions,i=n.totalClicksChange,o=n.totalImpressionsChange;return e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(y.a,{className:"overview-total-impressions",title:Object(m.__)("Total Impressions","google-site-kit"),datapoint:r,change:o,changeDataUnit:"%"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(y.a,{className:"overview-total-clicks",title:Object(m.__)("Total Clicks","google-site-kit"),datapoint:a,change:i,changeDataUnit:"%"})))}}]),SearchConsoleAdminbarWidgetOverview}(p.a);t.a=Object(v.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(h.n)("day"),context:"Adminbar"}],e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"auto",height:"59px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"auto",height:"59px"}))),{inGrid:!0},_.b)}).call(this,n(12),n(13))},202:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(203);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(t){s()(WPSearchConsoleDashboardWidget,t);var n=m(WPSearchConsoleDashboardWidget);function WPSearchConsoleDashboardWidget(){return r()(this,WPSearchConsoleDashboardWidget),n.apply(this,arguments)}return o()(WPSearchConsoleDashboardWidget,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement(p.a,null))}}]),WPSearchConsoleDashboardWidget}(f.a);t.a=h}).call(this,n(12))},203:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(5),h=n(30),y=n(31),v=n(25),b=n(17),_=n(53),k=n(46);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(WPSearchConsoleDashboardWidgetOverview,t);var n=O(WPSearchConsoleDashboardWidgetOverview);function WPSearchConsoleDashboardWidgetOverview(){return r()(this,WPSearchConsoleDashboardWidgetOverview),n.apply(this,arguments)}return o()(WPSearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=Object(_.a)(t),a=n.totalClicks,r=n.totalImpressions,i=n.totalClicksChange,o=n.totalImpressionsChange;return e.createElement(f.b,null,t.length?e.createElement(f.b,null,e.createElement(y.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-impressions",title:Object(p.__)("Total Impressions","google-site-kit"),datapoint:r,change:o,changeDataUnit:"%"}),e.createElement(y.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-clicks",title:Object(p.__)("Total Clicks","google-site-kit"),datapoint:a,change:i,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(k.a,{title:Object(p.__)("Search Console Data Empty","google-site-kit"),description:Object(p.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPSearchConsoleDashboardWidgetOverview}(f.a);t.a=Object(v.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(m.n)("day"),context:["WPDashboard"]}],e.createElement(h.a,{width:"23%",height:"94px",count:2}),{},_.b)}).call(this,n(12))},204:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(9),l=n.n(s),u=n(10),d=n.n(u),g=n(4),f=n.n(g),p=n(1),m=n(18),h=n.n(m),y=n(0),v=n(5),b=n(27),_=n(57),k=n(104),O=n(133);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var S=function(t){l()(DashboardSearchFunnel,t);var n=E(DashboardSearchFunnel);function DashboardSearchFunnel(){return i()(this,DashboardSearchFunnel),n.apply(this,arguments)}return c()(DashboardSearchFunnel,[{key:"render",value:function(){var t=Object(v.j)(),n=e._googlesitekitLegacyData.permissions.canManageOptions,r=t.analytics.active||n?12:6;return a.createElement(p.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},a.createElement(_.a,{title:Object(y.__)("Search Funnel","google-site-kit"),description:Object(y.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit")})),a.createElement("div",{className:h()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(r))},a.createElement(b.a,{className:"googlesitekit-analytics-search-funnel"},a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement(O.a,null),!t.analytics.active&&a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(k.a,null)))))))}}]),DashboardSearchFunnel}(p.a);t.a=S}).call(this,n(13),n(12))},205:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(9),l=n.n(s),u=n(10),d=n.n(u),g=n(4),f=n.n(g),p=n(1),m=n(0),h=n(31),y=n(25),v=n(17),b=n(53),_=n(66),k=n(30),O=n(5),E=n(46);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var D=function(t){l()(SearchConsoleDashboardWidgetTopLevel,t);var n=S(SearchConsoleDashboardWidgetTopLevel);function SearchConsoleDashboardWidgetTopLevel(){return i()(this,SearchConsoleDashboardWidgetTopLevel),n.apply(this,arguments)}return c()(SearchConsoleDashboardWidgetTopLevel,[{key:"render",value:function(){var t=this.props.data,n=t.error;if(n)return Object(O.w)("plugin_setup","search_console_error",n.message),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(E.a,{title:Object(m.__)("Something went wrong","google-site-kit"),description:n.message,error:!0}));if(!t)return null;if(!t.length)return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(E.a,{title:Object(m.__)("Search Console Data Empty","google-site-kit"),description:Object(m.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""}));var a=Object(O.m)("googlesitekit-module-search-console",{}),r=Object(b.a)(t),i=r.totalClicks,o=r.totalImpressions,c=r.totalClicksChange,s=r.totalImpressionsChange,l=r.dataMap;return e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(h.a,{className:"overview-total-impressions",title:Object(m.__)("Impressions","google-site-kit"),datapoint:o,change:s,changeDataUnit:"%",source:{name:Object(m._x)("Search Console","Service name","google-site-kit"),link:a},sparkline:e.createElement(_.a,{data:Object(O.f)(l,2),change:s})})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(h.a,{className:"overview-total-clicks",title:Object(m.__)("Clicks","google-site-kit"),datapoint:i,change:c,changeDataUnit:"%",source:{name:Object(m._x)("Search Console","Service name","google-site-kit"),link:a},sparkline:e.createElement(_.a,{data:Object(O.f)(l,1),change:c})})))}}]),SearchConsoleDashboardWidgetTopLevel}(p.a);t.a=Object(y.a)(D,[{type:v.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(O.n)("day"),context:["Single","Dashboard"]}],e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"100%",height:"202px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"100%",height:"202px"}))),{inGrid:!0},b.b)}).call(this,n(12),n(13))},206:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(27),h=n(133),y=n(5),v=n(104),b=n(57);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(DashboardDetailsSearchFunnel,t);var n=_(DashboardDetailsSearchFunnel);function DashboardDetailsSearchFunnel(){return r()(this,DashboardDetailsSearchFunnel),n.apply(this,arguments)}return o()(DashboardDetailsSearchFunnel,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(b.a,{description:Object(p.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit"),title:Object(p.__)("Search Funnel","google-site-kit")})),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},e.createElement(m.a,{className:"googlesitekit-analytics-search-funnel"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement(h.a,null),!Object(y.j)().analytics.active&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(v.a,null)))))))}}]),DashboardDetailsSearchFunnel}(f.a);t.a=k}).call(this,n(12))},207:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(0),i=n(8),o=n.n(i),c=n(132),s=n(57),l=n(27),u=n(58),d=o.a.useSelect;t.a=function DashboardDetailsWidgetKeywordsTable(){var t=d((function(e){return e(u.a).getPropertyID()})),n=d((function(e){return e(u.a).getServiceURL({query:{resource_id:t}})}));return e.createElement(a.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(s.a,{title:Object(r.__)("Top Queries","google-site-kit"),description:Object(r.__)("What people searched for to find your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(l.a,{footer:!0,footerCtaLabel:Object(r._x)("Search Console","Service name","google-site-kit"),footerCtaLink:n},e.createElement(c.a,null))))}}).call(this,n(12))},208:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(48),i=n(8),o=n.n(i),c=n(5),s=n(25),l=n(17),u=n(39),d=n(51),g=n(27),f=n(53),p=n(58),m=o.a.useSelect;t.a=Object(s.a)((function DashboardWidgetPopularKeywordsTable(t){var n=t.data,i=m((function(e){return e(p.a).getPropertyID()})),o=m((function(e){return e(p.a).getServiceURL({path:"/performance/search-analytics",query:{resource_id:i,num_of_days:28}})})),s=m((function(e){return e(p.a).getServiceURL({query:{resource_id:i}})}));if(!n||!n.length)return null;var l=[{title:Object(a.__)("Top search queries for your site","google-site-kit"),tooltip:Object(a.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(a.__)("Clicks","google-site-kit"),tooltip:Object(a.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(a.__)("Impressions","google-site-kit"),tooltip:Object(a.__)("Counted each time your content appears in search results","google-site-kit")}],d=[],f=n.map((function(e,t){var n=e.keys[0];return d[t]=Object(r.a)(o,{query:n}),[n,Object(c.q)(e.clicks),Object(c.q)(e.impressions)]})),h={hideHeader:!1,chartsEnabled:!1,links:d},y=Object(u.b)(f,l,h);return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(g.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(a._x)("Search Console","Service name","google-site-kit"),footerCtaLink:s,fill:!0},e.createElement(u.a,null,y)))}),[{type:l.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"query",limit:10},priority:1,maxAge:Object(c.n)("day"),context:["Dashboard"]}],e.createElement(d.a,{padding:!0}),{inGrid:!0,createGrid:!0},f.b)}).call(this,n(12))},209:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(0),m=n(210),h=n(57);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(DashboardPopularity,t);var n=y(DashboardPopularity);function DashboardPopularity(){return r()(this,DashboardPopularity),n.apply(this,arguments)}return o()(DashboardPopularity,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{title:Object(p.__)("Popularity","google-site-kit"),description:Object(p.__)("Your most popular pages and how people found them from Search.","google-site-kit")})),e.createElement(m.a,null))}}]),DashboardPopularity}(f.a);t.a=v}).call(this,n(12))},21:function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"q",(function(){return y})),n.d(t,"i",(function(){return d})),n.d(t,"j",(function(){return g})),n.d(t,"n",(function(){return f})),n.d(t,"o",(function(){return p})),n.d(t,"m",(function(){return m})),n.d(t,"l",(function(){return h})),n.d(t,"k",(function(){return d})),n.d(t,"e",(function(){return v})),n.d(t,"c",(function(){return _})),n.d(t,"d",(function(){return k})),n.d(t,"f",(function(){return O})),n.d(t,"h",(function(){return E})),n.d(t,"a",(function(){return S})),n.d(t,"s",(function(){return D})),n.d(t,"p",(function(){return j})),n.d(t,"u",(function(){return w})),n.d(t,"t",(function(){return R})),n.d(t,"g",(function(){return A})),n.d(t,"r",(function(){return C}));var a=n(15),r=n(0),i=n(5),o=function(e){if(!e||!e.length)return!1;var t=e[0].data.totals,n=t[0].values,a=t[1].values,r=n[1],o=n[2],c=n[3],s=n[4],l=n[5];return{totalSessions:r,averageBounceRate:o,averageSessionDuration:c,totalSessionsChange:Object(i.c)(a[1],n[1]),averageBounceRateChange:Object(i.c)(a[2],n[2]),averageSessionDurationChange:Object(i.c)(a[3],n[3]),goalCompletions:s,goalCompletionsChange:Object(i.c)(a[4],n[4]),totalPageViews:l,totalPageViewsChange:Object(i.c)(a[5],n[5])}},c=function(e){if("string"==typeof e&&e.match(/[0-9]{8}/)){var t=e.slice(0,4),n=Number(e.slice(4,6))-1,a=e.slice(6,8);return new Date(t,n.toString(),a)}return!1},s=n(35),l=n.n(s),u=n(22),d=function(e){return(parseInt(e,10)||0)>0};function g(e){return e===u.a||d(e)}function f(e){return"string"==typeof e&&/^UA-\d+-\d+$/.test(e)}function p(e){return e===u.f||f(e)}function m(e){return e===u.e||d(e)}function h(e){return"string"==typeof e&&e.trim().length>0}function y(e){if(!f(e))return!1;var t=e.match(/^UA-(\d+)-(\d+)/),n=l()(t,3);return{accountID:n[1],propertyID:e,number:n[2]}}var v=function(e){if(!e||!e.length)return null;var t=e[0].data,n=t.rows,r=t.totals[0].values[1],i=[["Source","Percent"]];return Object(a.each)(n,(function(e){var t=e.metrics[0].values[1]/r,n=e.dimensions[0];i.push([n,t])})),i};function b(e,t){var n=[];return Object(a.each)(e,(function(e){if(e.metrics){var a=e.metrics[0].values,r=e.dimensions[0],i=c(r);n.push([i,a[t]])}})),n}var _=function(e,t,n){if(!e||!e.length)return null;var i=e[0].data.rows;if(!i)return!1;var o=i.length;if(2*n>o){for(var c=new Date,s=0;n>s;s++){var l=(c.getMonth()+1).toString(),u=c.getDate().toString(),d=c.getFullYear().toString()+(2>l.length?"0":"")+l+(2>u.length?"0":"")+u;if(s>o){var g={dimensions:[d],metrics:[{values:[0,0,0,0,0]}]};i.unshift(g)}c.setDate(c.getDate()-1)}i.push([0,0])}var f=[Object(r.__)("Users","google-site-kit"),Object(r.__)("Sessions","google-site-kit"),Object(r.__)("Bounce Rate","google-site-kit"),Object(r.__)("Session Duration","google-site-kit")],p=[[{type:"date",label:Object(r.__)("Day","google-site-kit")},{type:"number",label:f[t]},{type:"number",label:Object(r.__)("Previous period","google-site-kit")}]],m=i.slice(i.length-n,i.length),h=i.slice(0,i.length-n),y=b(m,t),v=b(h,t);return Object(a.each)(y,(function(e,t){e[0]&&e[1]&&v[t]&&p.push([e[0],e[1],v[t][1]])})),p},k=function(e){if(!e||!e.length)return null;var t=e[0].data.rows,n=[[{type:"date",label:"Day"},{type:"number",label:"Users"},{type:"number",label:"Sessions"},{type:"number",label:"Goals Completed"}]];return Object(a.each)(t,(function(e){var t=e.metrics[0].values,a=e.dimensions[0],r=c(a);n.push([r,t[0],t[1],t[4]])})),n},O=function(e){var t;return e.error&&e.error.status?function(e,t){var n="";switch(e){case"INVALID_ARGUMENT":n=Object(r.__)("Analytics module needs to be configured.","google-site-kit");break;case"UNAUTHENTICATED":n=Object(r.__)("You need to be authenticated to get this data.","google-site-kit");break;case"PERMISSION_DENIED":n=Object(r.__)("Your account does not have sufficient permission to access this data, please consult to your web administrator.","google-site-kit");break;case"RESOURCE_EXHAUSTED":n=Object(r.__)("Your account exceeded the maximum quota. Please try again later.","google-site-kit");break;case"INTERNAL":n=Object(r.__)("Unexpected internal server error occurred.","google-site-kit");break;case"BACKEND_ERROR":n=Object(r.__)("Analytics server returned unknown error. Please try again later.","google-site-kit");break;case"UNAVAILABLE":n=Object(r.__)("The service was unable to process the request. Please try again later.","google-site-kit");break;default:n=t}return n}(e.error.status,e.error.message):!!(e.code&&e.message&&(null===(t=e.data)||void 0===t?void 0:t.status))&&e.message},E=function(e){if(!e||!e.length)return!0;if(e&&e[0]&&e[0].data&&e[0].data.totals&&e[0].data.totals[0]){var t=e[0].data.totals[0].values,n=!0;return Object(a.each)(t,(function(e){0!==parseInt(e,10)&&(n=!1)})),n}return!1},S={dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:[{expression:"ga:adsenseRevenue",alias:"Earnings"},{expression:"ga:adsenseECPM",alias:"Page RPM"},{expression:"ga:adsensePageImpressions",alias:"Impressions"}],orderby:[{fieldName:"ga:adsenseRevenue",sortOrder:"DESCENDING"}],limit:10},D={compareDateRanges:1,dimensions:"ga:date",metrics:[{expression:"ga:users",alias:"Users"},{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:bounceRate",alias:"Bounce Rate"},{expression:"ga:avgSessionDuration",alias:"Average Session Duration"},{expression:"ga:goalCompletionsAll",alias:"Goal Completions"}],limit:180},j={multiDateRange:1,dimensions:"ga:date",metrics:[{expression:"ga:users",alias:"Users"},{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:bounceRate",alias:"Bounce Rate"},{expression:"ga:avgSessionDuration",alias:"Average Session Duration"},{expression:"ga:goalCompletionsAll",alias:"Goal Completions"},{expression:"ga:pageviews",alias:"Pageviews"}],limit:10},w={multiDateRange:1,metrics:[{expression:"ga:users",alias:"Total Users"}]},R={dimensions:"ga:channelGrouping",metrics:[{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:users",alias:"Users"},{expression:"ga:newUsers",alias:"New Users"}],orderby:[{fieldName:"ga:users",sortOrder:"DESCENDING"}],limit:10},A=function(){return{dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:[{expression:"ga:pageviews",alias:"Pageviews"},{expression:"ga:uniquePageviews",alias:"Unique Pageviews"},{expression:"ga:bounceRate",alias:"Bounce rate"}],orderby:[{fieldName:"ga:pageviews",sortOrder:"DESCENDING"}],limit:10}},C=function(e){var t,n,a,r,i,o,c,s,l,u;return{totalUsers:null==e||null===(t=e[0])||void 0===t||null===(n=t.data)||void 0===n||null===(a=n.totals)||void 0===a||null===(r=a[0])||void 0===r||null===(i=r.values)||void 0===i?void 0:i[0],previousTotalUsers:null==e||null===(o=e[0])||void 0===o||null===(c=o.data)||void 0===c||null===(s=c.totals)||void 0===s||null===(l=s[1])||void 0===l||null===(u=l.values)||void 0===u?void 0:u[0]}}},210:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(DashboardPopularityInner,e);var t=p(DashboardPopularityInner);function DashboardPopularityInner(){return r()(this,DashboardPopularityInner),t.apply(this,arguments)}return o()(DashboardPopularityInner,[{key:"render",value:function(){return null}}]),DashboardPopularityInner}(n(1).a);t.a=Object(f.a)("googlesitekit.DashboardPopularity")(m)},211:function(e,t,n){"use strict";(function(e,a){var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(23),f=n.n(g),p=n(9),m=n.n(p),h=n(10),y=n.n(h),v=n(4),b=n.n(v),_=n(1),k=n(15),O=n(240),E=n.n(O),S=n(0),D=n(5),j=n(17),w=n(47),R=n(27);function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var C=function(t){m()(PostSearcher,t);var n,r=A(PostSearcher);function PostSearcher(e){var t;return l()(this,PostSearcher),(t=r.call(this,e)).noResultsMessage=Object(S.__)("No results found","google-site-kit"),t.state={isSearching:!1,results:[],error:!1,message:"",canSubmit:!1,match:{}},t.postSearch=t.postSearch.bind(f()(t)),t.onClick=t.onClick.bind(f()(t)),t.onConfirm=t.onConfirm.bind(f()(t)),t}return d()(PostSearcher,[{key:"postSearch",value:(n=c()(i.a.mark((function e(t,n){var a;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n([Object(S.__)("Loading…","google-site-kit")]),e.prev=1,e.next=4,j.c.get(j.a,"search","post-search",{query:encodeURIComponent(t)});case 4:0<(a=e.sent).length?n(Object(k.map)(a,(function(e){return e.post_title}))):n([this.noResultsMessage]),this.setState({isSearching:!0,results:a,error:!1,message:""}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(1),n([this.noResultsMessage]),this.setState({isSearching:!1,error:e.t0.code,message:e.t0.message});case 13:case"end":return e.stop()}}),e,this,[[1,9]])}))),function(e,t){return n.apply(this,arguments)})},{key:"getURLPathname",value:function(e){try{var t=new URL(e);return Object(k.trim)(t.pathname,"/")}catch(e){return!1}}},{key:"onConfirm",value:function(e){var t=this.state.results;if(Array.isArray(t)&&e!==this.noResultsMessage){var n=t.find((function(t){return t.post_title===e}));e&&n&&this.setState({selection:e,canSubmit:!0,match:n})}else this.setState({canSubmit:!1})}},{key:"onClick",value:function(){var t=this.state,n=t.selection,a=t.match;a&&a.ID&&e.location.assign(Object(D.m)("googlesitekit-dashboard",{id:a.ID,permaLink:a.permalink,pageTitle:n}))}},{key:"render",value:function(){var e=Object(D.j)(),t=e.analytics&&e.analytics.active?"mdc-layout-grid__cell mdc-layout-grid__cell--span-12":"mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop";return a.createElement("div",{className:t},a.createElement(R.a,{title:Object(S.__)("Search for individual page or post information","google-site-kit"),header:!0},a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement("div",{className:"googlesitekit-post-searcher"},a.createElement("label",{className:"googlesitekit-post-searcher__label",htmlFor:"autocomplete"},Object(S.__)("Title or URL","google-site-kit")),a.createElement(E.a,{id:"autocomplete",source:Object(k.debounce)(this.postSearch,200),minLength:2,onConfirm:this.onConfirm,showNoOptionsFound:!1}),a.createElement("div",{className:"googlesitekit-post-searcher__button-wrapper"},a.createElement(w.a,{onClick:this.onClick,className:"googlesitekit-post-searcher__button",disabled:!this.state.canSubmit},Object(S.__)("View Data","google-site-kit")))))))))}}]),PostSearcher}(_.a);t.a=C}).call(this,n(13),n(12))},22:function(e,t,n){"use strict";n.d(t,"h",(function(){return a})),n.d(t,"a",(function(){return r})),n.d(t,"f",(function(){return i})),n.d(t,"e",(function(){return o})),n.d(t,"c",(function(){return c})),n.d(t,"d",(function(){return s})),n.d(t,"g",(function(){return l})),n.d(t,"b",(function(){return u}));var a="modules/analytics",r="account_create",i="property_create",o="profile_create",c="analyticsAccountCreate",s="analyticsSetup",l="https://www.googleapis.com/auth/analytics.provision",u="https://www.googleapis.com/auth/analytics.edit"},24:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var a=n(83),r=n.n(a),i=n(1),o=function(e){return function(t){return function FilteredComponent(n){return Object(i.f)(i.b,{},"",Object(i.f)(t,n),e)}}},c=function(t,n){return function(a){return function InnerComponent(i){return e.createElement(t,r()({},i,n,{OriginalComponent:a}))}}}}).call(this,n(12))},244:function(e,t,n){"use strict";(function(e,t){n(1);var a=n(24),r=n(5),i=n(172),o=n(177),c=n(16),s="adsense";Object(c.b)("googlesitekit.SetupModuleShowLink","googlesitekit.adsenseSetupModuleShowLink",(function(t,n){return!("adsense"===n&&!e._googlesitekitLegacyData.canAdsRun)&&t}));var l=Object(r.j)();if(l.adsense.active){var u=Object(a.a)(t.createElement(i.a,null)),d=Object(a.a)(t.createElement(o.a,null));if(l[s].setupComplete)Object(c.b)("googlesitekit.ModuleApp-".concat(s),"googlesitekit.ModuleApp",u),Object(c.b)("googlesitekit.DashboardModule","googlesitekit.DashboardEarningModule",d,50);else{var g=e._googlesitekitLegacyData.admin,f=g.reAuth,p=g.currentScreen,m=p?p.id:null;f||"site-kit_page_googlesitekit-module-adsense"!==m||(e.location=Object(r.m)("googlesitekit-module-".concat(s),{reAuth:!0,slug:s})),Object(c.b)("googlesitekit.Connected-".concat(s),"googlesitekit.AdSenseModuleConnected",(function(e){var t=l[s].settings;return!(e||void 0===t||"graylisted"!==t.accountStatus&&"pending"!==t.accountStatus)||e}))}Object(c.b)("googlesitekit.ModulesNotificationsRequest","googlesitekit.adsenseNotifications",(function(e){return e.push({identifier:"adsense"}),e}))}}).call(this,n(13),n(12))},245:function(e,t,n){"use strict";(function(e,t){n(1);var a=n(16),r=n(5),i=n(24),o=n(180),c=n(185),s=n(187),l=n(189),u=n(190),d=n(192),g=n(193),f=n(194),p=n(195),m=n(196),h="analytics",y=Object(i.a)(e.createElement(c.a,null));Object(a.b)("googlesitekit.AdminbarModules","googlesitekit.Analytics",y,11);var v=Object(r.j)();if(!v[h].setupComplete){var b=t._googlesitekitLegacyData.admin,_=b.reAuth,k=b.currentScreen,O=k?k.id:null;_||"site-kit_page_googlesitekit-module-analytics"!==O||(t.location=Object(r.m)("googlesitekit-module-".concat(h),{reAuth:!0,slug:h}))}if(v.analytics.active){var E=Object(i.a)(e.createElement(o.a,null)),S=Object(i.a)(e.createElement(s.a,null)),D=Object(i.a)(e.createElement(u.a,null)),j=Object(i.a)(e.createElement(g.a,null)),w=Object(i.a)(e.createElement(l.a,null)),R=Object(i.a)(e.createElement(d.a,null)),A=Object(i.a)(e.createElement(f.a,null)),C=Object(i.a)(e.createElement(p.a,null)),N=Object(i.a)(e.createElement(m.a,null));Object(a.b)("googlesitekit.DashboardModule","googlesitekit.Analytics",S,9),Object(a.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.Analytics",w,11),Object(a.b)("googlesitekit.DashboardPopularity","googlesitekit.Analytics",C,20),Object(a.b)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall","googlesitekit.Analytics",N,20),Object(a.b)("googlesitekit.DashboardDetailsModule","googlesitekit.Analytics",R,20),Object(a.b)("googlesitekit.WPDashboardHeader","googlesitekit.Analytics",D),Object(a.b)("googlesitekit.WPDashboardModule","googlesitekit.Analytics",j),v[h].setupComplete&&Object(a.b)("googlesitekit.ModuleApp-"+h,"googlesitekit.Analytics",E),Object(a.b)("googlesitekit.AnalyticsAdSenseTopPagesTable","googlesitekit.Analytics",A,11),Object(a.b)("googlesitekit.showDateRangeSelector-".concat(h),"googlesitekit.analyticsShowDateRangeSelector",(function(){return!0}))}}).call(this,n(12),n(13))},246:function(e,t,n){"use strict";(function(e){n(1);var t=n(16),a=n(24),r=n(211),i=n(197),o=n(200),c=n(202),s=n(204),l=n(205),u=n(207),d=n(208),g=n(206),f=n(209),p="search-console",m=Object(a.a)(e.createElement(i.a,null)),h=Object(a.a)(e.createElement(o.a,null)),y=Object(a.a)(e.createElement(c.a,null)),v=Object(a.a)(e.createElement(s.a,null)),b=Object(a.a)(e.createElement(l.a,null)),_=Object(a.a)(e.createElement(g.a,null)),k=Object(a.a)(e.createElement(u.a,null)),O=Object(a.a)(e.createElement(d.a,null)),E=Object(a.a)(e.createElement(f.a,null)),S=Object(a.a)(e.createElement(r.a,null));Object(t.b)("googlesitekit.DashboardModule","googlesitekit.SearchConsole",v,11),Object(t.b)("googlesitekit.DashboardModule","googlesitekit.DashboardPopularityModule",E,40),Object(t.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.SearchConsoleSearchFunnel",b),Object(t.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",_),Object(t.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",k,40),Object(t.b)("googlesitekit.DashboardPopularity","googlesitekit.SearchConsoleDashboardPopularity",O),Object(t.b)("googlesitekit.DashboardPopularity","googlesitekit.DashboardPPostSearcherModule",S,30),Object(t.b)("googlesitekit.WPDashboardHeader","googlesitekit.SearchConsole",y,11),Object(t.b)("googlesitekit.ModuleApp-"+p,"googlesitekit.ModuleApp",m),Object(t.b)("googlesitekit.showDateRangeSelector-".concat(p),"googlesitekit.searchConsoleShowDateRangeSelector",(function(){return!0})),Object(t.b)("googlesitekit.AdminbarModules","googlesitekit.SearchConsole",h)}).call(this,n(12))},247:function(e,t,n){"use strict";n(244),n(245);var a=n(16),r=n(0),i=n(5);Object(i.j)().optimize.active&&Object(a.b)("googlesitekit.SetupWinNotification-optimize","googlesitekit.OptimizeSetupWinNotification",(function(e){return e.description=Object(r.__)("To set up experiments and see the results, go to ","google-site-kit"),e.learnMore.label="Optimize",e.learnMore.url="https://optimize.withgoogle.com/",e}));n(246)},25:function(e,t,n){"use strict";(function(e){var a=n(83),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(9),u=n.n(l),d=n(10),g=n.n(d),f=n(4),p=n.n(f),m=n(1),h=n(15),y=n(16),v=n(0),b=n(5),_=n(75),k=n(76),O=n(128);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}t.a=function(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{inGrid:!1,fullWidth:!1,createGrid:!1},c=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){return!1},l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:function(e){if(e&&e.error)return e.error.message?e.error.message:e.error.errors&&e.error.errors[0]&&e.error.errors[0].message?e.error.errors[0].message:Object(v.__)("Unidentified error","google-site-kit");if(e&&e.errors&&e.errors[0]&&e.errors[0].message)return e.errors[0].message;if(e&&e.error_data){var t=Object.values(e.error_data);if(t[0]&&"RateLimitExceeded"===t[0].reason)return Object(v.__)("Too many requests have been sent within a given time span. Please reload this page again in a few seconds","google-site-kit")}if(e&&e.errors){var n=Object.values(e.errors);if(n[0]&&n[0][0])return n[0][0]}return!!(e.code&&e.message&&e.data&&e.data.status)&&e.message};return function(d){u()(NewComponent,d);var g=E(NewComponent);function NewComponent(e){var t;o()(this,NewComponent),(t=g.call(this,e)).state={data:!1,zeroData:!1,error:!1},Object(y.a)("googlesitekit.moduleDataReset","googlesitekit.moduleDataResetHandler",(function(){t.setState({data:!1,error:!1,zeroData:!1})}));var a=function(e,n){var a=t.props,r=a.handleDataError,i=a.handleDataSuccess,o=n.datapoint,s=n.identifier,u=n.toState,d=l(e);d?(t.setState({error:d,module:s}),r&&r(d,e)):c(e,o,n)?(r&&r(d,e),t.setState({zeroData:!0})):i&&i(),t.setState({requestDataToState:u,data:e,datapoint:o,module:s})};return Object(h.each)(n,(function(e){Array.isArray(e.context)?Object(h.each)(e.context,(function(t){Object(y.b)("googlesitekit.module".concat(t,"DataRequest"),"googlesitekit.data".concat(t),(function(t){return e.callback=function(t){a(t,e)},t.push(e),t}))})):Object(y.b)("googlesitekit.module".concat(e.context,"DataRequest"),"googlesitekit.data".concat(e.context),(function(t){return e.callback=function(t){a(t,e)},t.push(e),t}))})),t}return s()(NewComponent,[{key:"render",value:function(){var n=this.state,o=n.data,c=n.datapoint,s=n.module,l=n.zeroData,u=n.error,d=n.requestDataToState;if(!o)return a;var g=Object(b.j)(),f=s?g[s].name:Object(v.__)("Site Kit","google-site-kit");return s&&g[s].active&&!g[s].setupComplete?Object(O.a)(s,i.inGrid,i.fullWidth,i.createGrid):u?"string"!=typeof u?u:Object(k.a)(f,u,i.inGrid,i.fullWidth,i.createGrid,o):l?Object(_.a)(f,i.inGrid,i.fullWidth,i.createGrid):e.createElement(t,r()({data:o,datapoint:c,requestDataToState:d},this.props))}}]),NewComponent}(m.a)}}).call(this,n(12))},27:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(154),b=n(155);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(Layout,t);var n=_(Layout);function Layout(){return r()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,a=t.footer,r=t.children,i=t.title,o=t.headerCtaLabel,c=t.headerCtaLink,s=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,g=t.fill,f=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":g,"googlesitekit-layout--relative":f})},n&&e.createElement(v.a,{title:i,ctaLabel:o,ctaLink:c}),r,a&&e.createElement(b.a,{ctaLabel:s,ctaLink:l,footerContent:u}))}}]),Layout}(f.a);k.propTypes={header:m.a.bool,footer:m.a.bool,children:m.a.node.isRequired,title:m.a.string,headerCtaLabel:m.a.string,headerCtaLink:m.a.string,footerCtaLabel:m.a.string,footerCtaLink:m.a.string,footerContent:m.a.node,className:m.a.string,fill:m.a.bool,relative:m.a.bool},k.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=k}).call(this,n(12))},28:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(Link,t);var n=v(Link);function Link(){return r()(this,Link),n.apply(this,arguments)}return o()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,a=t.onClick,r=t.href,i=t.children,o=t.className,c=t.arrow,s=t.external,l=t.inverse,u=t.back,d=t.small,g=t.inherit,f=t.caps,p=t.danger,m=t.disabled,h=t.id,v=r&&!m,b=v?"a":"button";return e.createElement(b,{className:y()("googlesitekit-cta-link",o,{"googlesitekit-cta-link--arrow":c,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":l,"googlesitekit-cta-link--back":u,"googlesitekit-cta-link--small":d,"googlesitekit-cta-link--inherit":g,"googlesitekit-cta-link--caps":f,"googlesitekit-cta-link--danger":p,"googlesitekit-cta-link--disabled":m}),onClick:a,id:h,href:v?r:void 0,target:v&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:m,dangerouslySetInnerHTML:n},i)}}]),Link}(f.a);b.propTypes={dangerouslySetInnerHTML:m.a.shape({__html:m.a.string}),onClick:m.a.func,href:m.a.string,children:m.a.oneOfType([m.a.string.isRequired,m.a.array.isRequired]),className:m.a.string,arrow:m.a.bool,external:m.a.bool,inverse:m.a.bool,back:m.a.bool,small:m.a.bool,inherit:m.a.bool,caps:m.a.bool,danger:m.a.bool,disabled:m.a.bool},b.defaultProps={dangerouslySetInnerHTML:void 0,onClick:null,href:"",className:"",arrow:!1,external:!1,inverse:!1,back:!1,small:!1,inherit:!1,caps:!1,danger:!1,disabled:!1},t.a=b}).call(this,n(12))},29:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return l})),n.d(t,"b",(function(){return u})),n.d(t,"a",(function(){return d})),n.d(t,"c",(function(){return g}));var a=n(32),r=n.n(a),i=n(15),o=n(40),c=n(56),s=function(){e._googlesitekitLegacyData.admin=e._googlesitekitLegacyData.admin||{},"string"==typeof e._googlesitekitLegacyData.admin.datacache&&(e._googlesitekitLegacyData.admin.datacache=JSON.parse(e._googlesitekitLegacyData.admin.datacache)),"object"!==r()(e._googlesitekitLegacyData.admin.datacache)&&(e._googlesitekitLegacyData.admin.datacache={})},l=function(t,n){if(void 0!==n&&(!n||"object"!==r()(n)||!n.error&&!n.errors)){s(),e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(n);var a={value:n,date:Date.now()/1e3};Object(o.a)().setItem("googlesitekit_"+t,JSON.stringify(a))}},u=function(t,n){if(!e._googlesitekitLegacyData.admin.nojscache){if(s(),void 0!==e._googlesitekitLegacyData.admin.datacache[t])return e._googlesitekitLegacyData.admin.datacache[t];var a=JSON.parse(Object(o.a)().getItem("googlesitekit_"+t));return a&&"object"===r()(a)&&a.date&&(!n||Date.now()/1e3-a.date<n)?(e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(a.value),Object(i.cloneDeep)(e._googlesitekitLegacyData.admin.datacache[t])):void 0}},d=function(t){s(),delete e._googlesitekitLegacyData.admin.datacache[t],Object(o.a)().removeItem("googlesitekit_"+t)},g=function(e,t,n){for(var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],s=0,l=o;s<l.length;s++){var u=l[s];if(!u||!u.length)break;i.push(u)}return 3===i.length&&a&&"object"===r()(a)&&Object.keys(a).length&&i.push(Object(c.a)(a)),i.join("::")}}).call(this,n(13))},30:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(PreviewBlock,t);var n=v(PreviewBlock);function PreviewBlock(){return r()(this,PreviewBlock),n.apply(this,arguments)}return o()(PreviewBlock,[{key:"render",value:function(){var t=this.props,n=t.width,a=t.height,r=t.shape,i=t.padding;return e.createElement("div",{className:y()("googlesitekit-preview-block",{"googlesitekit-preview-block--padding":i}),style:{width:n,height:a}},e.createElement("div",{className:y()("googlesitekit-preview-block__wrapper",{"googlesitekit-preview-block__wrapper--circle":"circular"===r})}))}}]),PreviewBlock}(f.a);b.propTypes={width:m.a.string,height:m.a.string,shape:m.a.string,padding:m.a.bool},b.defaultProps={width:"100px",height:"100px",shape:"square",padding:!1},t.a=b}).call(this,n(12))},31:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(23),s=n.n(c),l=n(9),u=n.n(l),d=n(10),g=n.n(d),f=n(4),p=n.n(f),m=n(1),h=n(2),y=n.n(h),v=n(18),b=n.n(v),_=n(124),k=n(63),O=n(82);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var S=function(t){u()(DataBlock,t);var n=E(DataBlock);function DataBlock(e){var t;return r()(this,DataBlock),(t=n.call(this,e)).handleClick=t.handleClick.bind(s()(t)),t.handleKeyPress=t.handleKeyPress.bind(s()(t)),t}return o()(DataBlock,[{key:"handleClick",value:function(){var e=this.props,t=e.stat;(0,e.handleStatSelection)(t)}},{key:"handleKeyPress",value:function(e){e.preventDefault();var t=this.props,n=t.stat,a=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||a(n)}},{key:"render",value:function(){var t=this.props,n=t.className,a=t.title,r=t.datapoint,i=t.datapointUnit,o=t.change,c=t.changeDataUnit,s=t.context,l=t.period,u=t.selected,d=t.handleStatSelection,g=t.source,f=t.sparkline,p=t.invertChangeColor,h="button"===s?"button":"",y=f;return y&&p&&(y=Object(m.d)(f,{invertChangeColor:p})),e.createElement("div",{className:b()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":u}),tabIndex:"button"===s?"0":"-1",role:d&&h,onClick:d&&this.handleClick,onKeyPress:d&&this.handleKeyPress,"aria-label":d&&a,"aria-pressed":d&&u},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},a),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(r).concat(i))),y&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},y),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===o&&e.createElement(m.b,null," "),o&&e.createElement(m.b,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(_.a,{direction:0<parseFloat(o)?"up":"down",invertColor:p})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(k.b)(Math.abs(o))).concat(c," ").concat(l)))),g&&e.createElement(O.a,{className:"googlesitekit-data-block__source",name:g.name,href:g.link})))}}]),DataBlock}(m.a);S.propTypes={stat:y.a.number,onClick:y.a.func,className:y.a.string,title:y.a.string,datapoint:y.a.oneOfType([y.a.string,y.a.number]),datapointUnit:y.a.string,change:y.a.oneOfType([y.a.string,y.a.number]),changeDataUnit:y.a.string,context:y.a.string,period:y.a.string,selected:y.a.bool,handleStatSelection:y.a.func,invertChangeColor:y.a.bool},S.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=S}).call(this,n(12))},33:function(e,t,n){"use strict";(function(e,a){n(1);var r=n(2),i=n.n(r),o=n(18),c=n.n(o),s=function SvgIcon(t){var n=t.id,r=t.className,i=t.height,o=t.width,s="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return a.createElement("svg",{className:c()("svg",r),height:i,width:o},a.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:i.a.string.isRequired,className:i.a.string,height:i.a.string,width:i.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(13),n(12))},34:function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i}));var a="core/site",r="primary",i="secondary"},38:function(e,t,n){"use strict";(function(e){var a=n(11),r=n.n(a),i=n(3),o=n.n(i),c=n(14),s=n.n(c),l=n(6),u=n.n(l),d=n(7),g=n.n(d),f=n(23),p=n.n(f),m=n(9),h=n.n(m),y=n(10),v=n.n(y),b=n(4),_=n.n(b),k=n(1),O=n(2),E=n.n(O),S=n(18),D=n.n(S),j=n(15),w=n(33),R=n(54),A=n(29),C=n(31),N=n(47),P=n(120),x=n(125),T=n(28);function L(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=_()(e);if(t){var r=_()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return v()(this,n)}}var I=function(t){h()(Notification,t);var n,a,i=L(Notification);function Notification(e){var t;return u()(this,Notification),(t=i.call(this,e)).state={isClosed:!1},t.cardRef=Object(k.h)(),t.handleDismiss=t.handleDismiss.bind(p()(t)),t.handleCTAClick=t.handleCTAClick.bind(p()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&Object(A.e)("notification::displayed::".concat(t.props.id),new Date),t}return g()(Notification,[{key:"handleDismiss",value:(a=s()(o.a.mark((function e(t){var n;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),t.preventDefault(),!(n=this.props.onDismiss)){e.next=6;break}return e.next=6,n(t);case 6:this.dismiss();case 7:case"end":return e.stop()}}),e,this)}))),function(e){return a.apply(this,arguments)})},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){Object(A.e)("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:(n=s()(o.a.mark((function e(t){var n,a,r;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),n=this.props,a=n.isDismissable,!(r=n.onCTAClick)){e.next=5;break}return e.next=5,r(t);case 5:a&&this.dismiss();case 6:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,a=Object(A.b)("notification::dismissed::".concat(t));if(a){var r=new Date(a);r.setSeconds(r.getSeconds()+parseInt(n,10)),r<new Date&&Object(A.a)("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,a=this.props,i=a.children,o=a.id,c=a.title,s=a.description,l=a.blockData,u=a.winImage,d=a.smallImage,g=a.format,f=a.learnMoreURL,p=a.learnMoreDescription,m=a.learnMoreLabel,h=a.ctaLink,y=a.ctaLabel,v=a.ctaTarget,b=a.type,_=a.dismiss,O=a.isDismissable,E=a.logo,S=a.module,L=a.moduleName,I=a.pageIndex,M=a.anchorLink,W=a.anchorLinkLabel;if(Object(A.b)("notification::dismissed::".concat(o)))return null;var U,q=n?"is-closed":"is-open",F="large"===g&&"win-stats-increase"===b,H="mdc-layout-grid__cell--span-12";"large"===g?(H="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-6-tablet mdc-layout-grid__cell--span-8-desktop ",F&&(H="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-8-desktop ")):"small"===g&&(H="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),U="win-warning"===b?e.createElement(P.a,null):"win-error"===b?e.createElement(x.a,null):"";var G=e.createElement(k.b,null,l&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(j.map)(l,(function(t,n){return e.createElement("div",{key:n,className:D()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":F,"mdc-layout-grid__cell--span-4-desktop":!F})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(C.a,t)))})))),B=e.createElement(k.b,null,c&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},c),M&&W&&e.createElement("p",{className:"googlesitekit-publisher-win__link"},e.createElement(T.a,{href:M},W)),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(k.i)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(R.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),m&&e.createElement(k.b,null," ",e.createElement(T.a,{href:f,external:!0,inherit:!0},m),p),I&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},I))),i),z=S?e.createElement(w.a,{id:S,height:"19",width:"19"}):e.createElement(w.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:D()("googlesitekit-publisher-win",(t={},r()(t,"googlesitekit-publisher-win--".concat(g),g),r()(t,"googlesitekit-publisher-win--".concat(b),b),r()(t,"googlesitekit-publisher-win--".concat(q),q),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},E&&e.createElement("div",{className:D()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":F,"mdc-layout-grid__cell--order-1-tablet":F})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},z),L&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},L)),d&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("img",{className:"googlesitekit-publisher-win__small-image",alt:"",src:d})),e.createElement("div",{className:D()("mdc-layout-grid__cell",H)},F?e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-5-desktop mdc-layout-grid__cell--span-8-tablet"},B),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--align-bottom"},G)):e.createElement(k.b,null,B,G),h&&e.createElement(N.a,{href:h,target:v,onClick:this.handleCTAClick},y),O&&_&&e.createElement(T.a,{onClick:this.handleDismiss},_)),u&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--order-1-phone mdc-layout-grid__cell--order-2-tablet mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement("div",{className:"googlesitekit-publisher-win__image-large"},e.createElement("img",{alt:"",src:u}))),("win-error"===b||"win-warning"===b)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},U)))))}}]),Notification}(k.a);I.propTypes={id:E.a.string.isRequired,title:E.a.string.isRequired,description:E.a.node,learnMoreURL:E.a.string,learnMoreDescription:E.a.string,learnMoreLabel:E.a.string,blockData:E.a.array,winImage:E.a.string,smallImage:E.a.string,format:E.a.string,ctaLink:E.a.string,ctaLabel:E.a.string,type:E.a.string,dismiss:E.a.string,isDismissable:E.a.bool,logo:E.a.bool,module:E.a.string,moduleName:E.a.string,pageIndex:E.a.string,dismissExpires:E.a.number,showOnce:E.a.bool,onCTAClick:E.a.func,onDismiss:E.a.func,anchorLink:E.a.string,anchorLinkLabel:E.a.string},I.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=I}).call(this,n(12))},39:function(e,t,n){"use strict";(function(e,a){n.d(t,"b",(function(){return w})),n.d(t,"a",(function(){return R}));var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(23),l=n.n(s),u=n(9),d=n.n(u),g=n(10),f=n.n(g),p=n(4),m=n.n(p),h=n(11),y=n.n(h),v=n(1),b=n(2),_=n.n(b),k=n(18),O=n.n(k),E=n(15),S=n(82),D=n(28);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var w=function(t,n,a){var r=[],i=a.links,o=a.source,c=a.showURLs;a.cap&&(t=t.slice(0,a.cap)),Object(E.each)(t,(function(t,n){var o=[],s=i&&i[n];Object(E.each)(t,(function(n,r){"string"==typeof n&&(n=n.replace(/\(none\)/gi,"direct"));var i=a&&a.hideColumns&&a.hideColumns.mobile.includes(r);o.push(e.createElement("td",{key:"cell-"+r,className:O()("googlesitekit-table__body-item",{"hidden-on-mobile":i})},t[0]===n&&s?e.createElement("div",{className:"googlesitekit-table__body-item-content"},e.createElement(D.a,{className:"googlesitekit-table__body-item-link",href:s,external:!0,inherit:!0},n),c&&e.createElement(D.a,{className:"googlesitekit-table__body-item-url",href:s,inherit:!0,external:!0},s)):e.createElement("div",{className:"googlesitekit-table__body-item-content"},n)))})),r.push(e.createElement("tr",{key:"tr-"+n,className:"googlesitekit-table__body-row"},o))}));var s=t&&t[0]&&t[0].length?t[0].length:1,l=a.hideColumns&&a.hideColumns.mobile&&a.hideColumns.mobile.length>0?s-a.hideColumns.mobile.length:s;return e.createElement("div",{className:O()("googlesitekit-table",{"googlesitekit-table--with-list":!a||!a.disableListMode})},e.createElement("table",{className:O()("googlesitekit-table__wrapper","googlesitekit-table__wrapper--".concat(s,"-col"),y()({},"googlesitekit-table__wrapper--mobile-".concat(l,"-col"),l!==s))},e.createElement("thead",{className:"googlesitekit-table__head"},e.createElement("tr",{key:"gksc_data_row_header-wrap",style:a&&a.hideHeader?{display:"none"}:{},className:"googlesitekit-table__head-row"},n.map((function(t,n){var r=a&&a.hideColumns&&a.hideColumns.mobile.includes(n);return e.createElement("th",{key:"gksc_data_row_header-".concat(n),className:O()("googlesitekit-table__head-item",{"googlesitekit-table__head-item--primary":t.primary},{"hidden-on-mobile":r}),"data-tooltip":t.tooltip},t.title)})))),e.createElement("tbody",{className:"googlesitekit-table__body"},r)),o&&e.createElement(S.a,{className:"googlesitekit-table__source",name:o.name,href:o.link}))},R=function(t){d()(TableOverflowContainer,t);var n=j(TableOverflowContainer);function TableOverflowContainer(){var e;return i()(this,TableOverflowContainer),(e=n.call(this)).state={isScrolling:!1},e.scrollRef=Object(v.h)(),e.updateFadeOnScroll=e.updateFadeOnScroll.bind(l()(e)),e}return c()(TableOverflowContainer,[{key:"componentDidMount",value:function(){var e=this;e.updateFadeOnScroll(),this.resize=Object(E.debounce)((function(){e.updateFadeOnScroll()}),100),a.addEventListener("resize",this.resize)}},{key:"componentWillUnmount",value:function(){a.removeEventListener("resize",this.resize)}},{key:"updateFadeOnScroll",value:function(){var e=this.scrollRef.current,t=e.scrollLeft,n=e.scrollWidth-e.offsetWidth,a=t<n-16&&0<n-16;this.setState({isScrolling:a})}},{key:"render",value:function(){var t=this.props.children,n=this.state.isScrolling;return e.createElement("div",{onScroll:Object(E.debounce)(this.updateFadeOnScroll,100),className:O()("googlesitekit-table-overflow",{"googlesitekit-table-overflow--gradient":n})},e.createElement("div",{ref:this.scrollRef,className:"googlesitekit-table-overflow__container"},t))}}]),TableOverflowContainer}(v.a);R.propTypes={children:_.a.element}}).call(this,n(12),n(13))},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return u}));var a,r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=function(t){var n=e[t];if(!n)return!1;try{var a="__storage_test__";return n.setItem(a,a),n.removeItem(a),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},l=function(){function NullStorage(){i()(this,NullStorage)}return c()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),u=function(){return a||(a=s("sessionStorage")?e.sessionStorage:s("localStorage")?e.localStorage:new l),a}}).call(this,n(13))},42:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var a="modules/adsense"},43:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return y}));var a=n(3),r=n.n(a),i=n(11),o=n.n(i),c=n(19),s=n.n(c),l=n(71),u=n.n(l),d=n(67),g=n(5);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=function(e){return p({},e)},h=function(){return{}},y=function(t){var n,a,i=t.baseName,c=t.controlCallback,l=t.reducerCallback,f=void 0===l?m:l,y=t.argsToParams,v=void 0===y?h:y;s()(i,"baseName is required."),s()("function"==typeof c,"controlCallback is required and must be a function."),s()("function"==typeof f,"reducerCallback must be a function."),s()("function"==typeof v,"argsToParams must be a function.");try{v(),a=!1}catch(e){a=!0}var b=Object(d.b)(i),_=Object(d.a)(i),k="FETCH_".concat(_),O="START_".concat(k),E="FINISH_".concat(k),S="CATCH_".concat(k),D="RECEIVE_".concat(_),j="fetch".concat(b),w="receive".concat(b),R="isFetching".concat(b),A=o()({},R,{}),C=(n={},o()(n,j,r.a.mark((function t(){var n,a,i,o=arguments;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:t.prev=0,i=v.apply(void 0,o),t.next=9;break;case 4:return t.prev=4,t.t0=t.catch(0),e.console.error(t.t0.message),a=t.t0,t.abrupt("return",{response:n,error:a});case 9:return t.next=11,{payload:{params:i},type:O};case 11:return t.prev=11,t.next=14,{payload:{params:i},type:k};case 14:return n=t.sent,t.next=17,C[w](n,i);case 17:return t.next=19,{payload:{params:i},type:E};case 19:t.next=26;break;case 21:return t.prev=21,t.t1=t.catch(11),a=t.t1,t.next=26,{payload:{error:a,params:i},type:S};case 26:return t.abrupt("return",{response:n,error:a});case 27:case"end":return t.stop()}}),t,null,[[0,4],[11,21]])}))),o()(n,w,(function(e,t){return s()(void 0!==e,"response is required."),a?s()(u()(t),"params is required."):t={},{payload:{response:e,params:t},type:D}})),n),N=o()({},k,(function(e){var t=e.payload;return c(t.params)})),P=o()({},R,(function(e){if(void 0===e[R])return!1;var t;try{for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];t=v.apply(void 0,a)}catch(e){return!1}return!!e[R][Object(g.v)(t)]}));return{INITIAL_STATE:A,actions:C,controls:N,reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case O:var r=a.params;return p(p({},e),{},o()({},R,p(p({},e[R]),{},o()({},Object(g.v)(r),!0))));case D:var i=a.response,c=a.params;return f(e,i,c);case E:var s=a.params;return p(p({},e),{},o()({},R,p(p({},e[R]),{},o()({},Object(g.v)(s),!1))));case S:var l=a.error,u=a.params;return p(p({},e),{},o()({error:l},R,p(p({},e[R]),{},o()({},Object(g.v)(u),!1))));default:return p({},e)}},resolvers:{},selectors:P}}}).call(this,n(13))},44:function(e,t,n){"use strict";var a=n(80),r=n.n(a);n.d(t,"k",(function(){return r.a})),n.d(t,"a",(function(){return a.HelperText})),n.d(t,"b",(function(){return a.Input}));var i=n(137);n.d(t,"g",(function(){return i.a}));var o=n(223);n.d(t,"e",(function(){return o.a}));var c=n(103),s=n.n(c);n.d(t,"j",(function(){return s.a})),n.d(t,"i",(function(){return c.Option}));var l=n(224);n.d(t,"h",(function(){return l.a}));var u=n(221);n.d(t,"d",(function(){return u.a}));var d=n(222);n.d(t,"c",(function(){return d.a}));var g=n(220);n.d(t,"f",(function(){return g.a}))},46:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(28);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(CTA,t);var n=b(CTA);function CTA(){return r()(this,CTA),n.apply(this,arguments)}return o()(CTA,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.description,r=t.ctaLink,i=t.ctaLabel,o=t.error,c=t.onClick;return e.createElement("div",{className:y()("googlesitekit-cta",{"googlesitekit-cta--error":o})},n&&e.createElement("h3",{className:"googlesitekit-cta__title"},n),a&&"string"==typeof a&&e.createElement("p",{className:"googlesitekit-cta__description"},a),a&&"string"!=typeof a&&e.createElement("div",{className:"googlesitekit-cta__description"},a),i&&e.createElement(v.a,{href:r,onClick:c,inverse:!o,caps:!0,arrow:!0},i))}}]),CTA}(f.a);_.propTypes={title:m.a.string.isRequired,description:m.a.oneOfType([m.a.string,m.a.node]),ctaLink:m.a.string,ctaLabel:m.a.string,error:m.a.bool,onClick:m.a.func},_.defaultProps={title:"",description:"",ctaLink:"",ctaLabel:"",error:!1,onClick:function(){}},t.a=_}).call(this,n(12))},47:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(44);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(Button,t);var n=b(Button);function Button(e){var t;return r()(this,Button),(t=n.call(this,e)).buttonRef=Object(f.h)(),t}return o()(Button,[{key:"componentDidMount",value:function(){new v.g(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,a=t.children,r=t.href,i=t.text,o=t.className,c=t.danger,s=t.disabled,l=t.target,u=t.id,d=t.icon,g=t.trailingIcon,f=t.ariaHaspopup,p=t.ariaExpanded,m=t.ariaControls,h=r&&!s?"a":"button";return e.createElement(h,{className:y()("mdc-button",o,{"mdc-button--raised":!i,"mdc-button--danger":c}),onClick:n,href:s?void 0:r,ref:this.buttonRef,disabled:!!s,target:l||"_self",id:u,"aria-haspopup":f,"aria-expanded":p,"aria-controls":m,role:"a"===h?"button":void 0},d&&d,e.createElement("span",{className:"mdc-button__label"},a),g&&g)}}]),Button}(f.a);_.propTypes={onClick:m.a.func,children:m.a.string.isRequired,href:m.a.string,text:m.a.bool,className:m.a.string,danger:m.a.bool,disabled:m.a.bool,icon:m.a.element,trailingIcon:m.a.element,ariaHaspopup:m.a.string,ariaExpanded:m.a.bool,ariaControls:m.a.string},_.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=_}).call(this,n(12))},49:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(ProgressBar,t);var n=v(ProgressBar);function ProgressBar(){return r()(this,ProgressBar),n.apply(this,arguments)}return o()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,a=t.small,r=t.compress,i=t.height,o=i?Math.round(i/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:o,marginBottom:o},className:y()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":a,"mdc-linear-progress--compress":r})},e.createElement("div",{className:"mdc-linear-progress__buffering-dots"}),e.createElement("div",{className:"mdc-linear-progress__buffer"}),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})))}}]),ProgressBar}(f.a);b.propTypes={className:m.a.string,small:m.a.bool,compress:m.a.bool},b.defaultProps={className:"",small:!1,compress:!1},t.a=b}).call(this,n(12))},5:function(e,t,n){"use strict";(function(e,a){n.d(t,"s",(function(){return A})),n.d(t,"q",(function(){return C})),n.d(t,"n",(function(){return P})),n.d(t,"r",(function(){return x})),n.d(t,"h",(function(){return T})),n.d(t,"c",(function(){return L})),n.d(t,"f",(function(){return I})),n.d(t,"j",(function(){return M})),n.d(t,"l",(function(){return W})),n.d(t,"m",(function(){return U})),n.d(t,"x",(function(){return q})),n.d(t,"b",(function(){return F})),n.d(t,"u",(function(){return H})),n.d(t,"e",(function(){return G})),n.d(t,"p",(function(){return B})),n.d(t,"i",(function(){return z}));var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(11),l=n.n(s),u=n(45),d=n.n(u),g=n(32),f=n.n(g),p=(n(1),n(15)),m=n(16),h=n(0),y=n(48),v=n(145),b=n(33);n.d(t,"a",(function(){return b.a}));var _=n(50);n.d(t,"w",(function(){return _.c}));var k=n(24),O=n(54);n.d(t,"t",(function(){return O.a}));var E=n(56);n.d(t,"v",(function(){return E.a}));var S=n(55);n.d(t,"d",(function(){return S.b})),n.d(t,"k",(function(){return S.c}));n(40);var D=n(63);function j(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?j(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):j(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return D.a})),n.d(t,"g",(function(){return k.b}));var R=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},A=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(p.isFinite)(e)?e:Number(e),Object(p.isFinite)(e)||(console.warn("Invalid number",e,f()(e)),e=0),t)return C(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in millions.
15
+ Object(h.__)("%sM","google-site-kit"),C(R(e),e%10==0?{}:n)):1e4<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in thousands.
16
+ Object(h.__)("%sK","google-site-kit"),C(R(e))):1e3<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in thousands.
17
+ Object(h.__)("%sK","google-site-kit"),C(R(e),e%10==0?{}:n)):e.toString()},C=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,a=void 0===n?N():n,r=d()(t,["locale"]);return new Intl.NumberFormat(a,r).format(e)},N=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(p.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var a=n.match(/^(\w{2})?(_)?(\w{2})/);if(a&&a[0])return a[0].replace(/_/g,"-")}return t.navigator.language},P=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},x=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},T=function(e,t){var n=1e3*P("day"),a=e.getTime(),r=t.getTime();return Math.round(Math.abs(a-r)/n)},L=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},I=function(e,t){return Object(p.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},M=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==f()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:w(w({},e),{},l()({},t,n[t]))}),{}):{}},W=function(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,r=a.admin,i=r.connectURL,o=r.adminRoot,c=a.setup.needReauthenticate,s=M(a)[t].screenID,l="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},u=Object(y.a)(o,w({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},l));if(!c)return u;var d=encodeURIComponent(Object(v.a)(u));return u=o+"?"+d,Object(y.a)(i,{redirect:u,status:n})},U=function(t,n){var a=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=w({page:t},n),Object(y.a)(a,n)},q=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},F=function(){var e=c()(i.a.mark((function e(t,n,a){var r,o,c,s,l=arguments;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=l.length>3&&void 0!==l[3]?l[3]:_.c,o=l.length>4&&void 0!==l[4]?l[4]:M,e.next=4,t.setModuleActive(n,a);case 4:return c=e.sent,(s=o())[n]&&(s[n].active=a),e.next=9,r("".concat(n,"_setup"),a?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",c);case 10:case"end":return e.stop()}}),e)})));return function(t,n,a){return e.apply(this,arguments)}}(),H=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(m.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(k.b)(e,t),1)},G=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(p.unescape)(t)};function B(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var c=a.createElement(b.a,{id:t,width:r,height:i,className:o});return n?c=a.createElement(b.a,{id:"".concat(t,"-disabled"),width:r,height:i,className:o}):"pagespeed-insights"===t&&(c=a.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:r,alt:"",className:o})),c}}function z(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,a=n.blogPrefix,r=n.isNetworkMode;return r?t:a+t}}).call(this,n(13),n(12))},51:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(30);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(PreviewTable,t);var n=b(PreviewTable);function PreviewTable(){return r()(this,PreviewTable),n.apply(this,arguments)}return o()(PreviewTable,[{key:"render",value:function(){for(var t=this.props,n=t.rows,a=t.rowHeight,r=t.padding,i=[],o=0;n>o;o++)i.push(e.createElement("div",{className:"googlesitekit-preview-table__row",key:"table-row-"+o},e.createElement(v.a,{width:"100%",height:a+"px"})));return e.createElement("div",{className:y()("googlesitekit-preview-table",{"googlesitekit-preview-table--padding":r})},i)}}]),PreviewTable}(f.a);_.propTypes={rows:m.a.number,rowHeight:m.a.number,padding:m.a.bool},_.defaultProps={rows:11,rowHeight:35,padding:!1},t.a=_}).call(this,n(12))},53:function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var a=n(15),r=n(5);function i(e){var t=[[{type:"string",label:"Day"},{type:"number",label:"Clicks"},{type:"number",label:"Impressions"},{type:"number",label:"CTR"},{type:"number",label:"Position"}]],n=0,i=0,o=0,c=0,s=e.length;Object(a.each)(e,(function(e){var a=new Date(e.keys[0]);t.push([a.getMonth()+1+"/"+a.getUTCDate(),e.clicks,e.impressions,e.ctr,e.position]),n+=e.clicks,i+=e.impressions,o+=e.ctr,c+=e.position}));var l=n,u=i;n=Object(r.s)(n),i=Object(r.s)(i);var d=s>0?(o/s*100).toFixed(1):"0.0",g=s>0?o/s:0,f=s>0?(c/s).toFixed(1):"0.0";return{dataMap:t,totalClicks:n,totalClicksRaw:l,totalImpressions:i,totalImpressionsRaw:u,averageCTR:d,averageCTRRaw:g,averagePosition:f}}var o=function(e){var t=Math.floor(e.length/2),n=i(e.slice(t)),a=i(e.slice(0,t));return{dataMap:n.dataMap,totalClicks:n.totalClicks,totalImpressions:n.totalImpressions,averageCTR:n.averageCTR,averagePosition:n.averagePosition,totalClicksChange:Object(r.c)(a.totalClicksRaw,n.totalClicksRaw),totalImpressionsChange:Object(r.c)(a.totalImpressionsRaw,n.totalImpressionsRaw),averageCTRChange:Object(r.c)(a.averageCTRRaw,n.averageCTRRaw),averagePositionChange:Object(r.c)(a.averagePosition,n.averagePosition)}},c=function(e){if(!e.length)return!0;var t=o(e),n=t.totalClicks,a=t.totalImpressions,r=t.averageCTR,i=t.averagePosition;return 0===parseInt(n,10)&&0===parseInt(a,10)&&0===parseInt(r,10)&&0===parseInt(i,10)}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var a=n(78),r=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:a.a.sanitize(e,t)}}},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var a=n(32),r=n.n(a),i=n(106),o=n.n(i),c=function(e){return o()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(a){var i=t[a];i&&"object"===r()(i)&&!Array.isArray(i)&&(i=e(i)),n[a]=i})),n}(e)))}},57:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var y=function(t){s()(DashboardModuleHeader,t);var n=h(DashboardModuleHeader);function DashboardModuleHeader(){return r()(this,DashboardModuleHeader),n.apply(this,arguments)}return o()(DashboardModuleHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.description;return e.createElement("header",{className:"googlesitekit-dashboard-module-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-dashboard-module-header__title "},n),a&&e.createElement("p",{className:"googlesitekit-dashboard-module-header__description"},a))))}}]),DashboardModuleHeader}(f.a);y.propTypes={title:m.a.string,description:m.a.string},y.defaultProps={title:"",description:""},t.a=y}).call(this,n(12))},58:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var a="modules/search-console"},62:function(e,t,n){"use strict";n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return l}));var a=n(0),r=n(8),i=n.n(r),o=n(20);function c(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s(),t=e.match(/last-(\d+)-days/);if(t&&t[1])return Object(a.sprintf)(
18
+ /* translators: %s: Number of days matched. */
19
+ Object(a._n)("%s day","%s days",parseInt(t[1],10),"google-site-kit"),t[1]);throw new Error("Unrecognized date range slug.")}function s(){return i.a.select(o.c).getDateRange()}function l(){
20
+ /* translators: %s: Number of days to request data. */
21
+ var e=Object(a.__)("Last %s days","google-site-kit");return{"last-7-days":{slug:"last-7-days",label:Object(a.sprintf)(e,7)},"last-14-days":{slug:"last-14-days",label:Object(a.sprintf)(e,14)},"last-28-days":{slug:"last-28-days",label:Object(a.sprintf)(e,28)},"last-90-days":{slug:"last-90-days",label:Object(a.sprintf)(e,90)}}}},63:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return s}));var a=n(45),r=n.n(a),i=n(15),o=n(0);function c(){Object(o.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,a=void 0===n?l():n,i=r()(t,["locale"]);return new Intl.NumberFormat(a,i).format(e)},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(i.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var a=n.match(/^(\w{2})?(_)?(\w{2})/);if(a&&a[0])return a[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(13))},64:function(e,t,n){"use strict";n.d(t,"e",(function(){return g})),n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return p}));var a=n(3),r=n.n(a),i=n(14),o=n.n(i),c=n(15),s=n(5),l=n(21),u=n(17),d=(n(135),n(84),n(108));n.d(t,"c",(function(){return d.a})),n.d(t,"d",(function(){return d.b}));n(136);function g(e){var t=[[{type:"date",label:"Day"},{type:"number",label:"RPM"},{type:"number",label:"Earnings"},{type:"number",label:"Impressions"}]];return Object(c.each)(e,(function(e){var n=new Date(e[0]);t.push([n,e[2],e[1],e[3]])})),{dataMap:t}}var f=function(){var e=o()(r.a.mark((function e(){var t,n,a,i;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=Object(s.j)(),n=t.adsense.active,a=t.analytics.active,i=!0,!n||!a){e.next=7;break}return e.next=7,u.c.get(u.b,"analytics","report",l.a).then((function(e){e&&(i=!0)})).catch((function(e){400===e.code&&"INVALID_ARGUMENT"===e.message&&(i=!1)}));case 7:return e.abrupt("return",new Promise((function(e){e(i)})));case 8:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),p=function(e,t,n){if(!n.data||!n.data.dateRange||"last-28-days"!==n.data.dateRange)return!1;var a=[];return e.totals&&(a=e.totals),0===(a=a.filter((function(e){return 0<e}))).length}},647:function(e,t,n){"use strict";n.r(t),function(e,a){n.d(t,"GoogleSitekitAdminbar",(function(){return w})),n.d(t,"init",(function(){return R}));var r=n(3),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(23),f=n.n(g),p=n(9),m=n.n(p),h=n(10),y=n.n(h),v=n(4),b=n.n(v),_=n(1),k=(n(247),n(0)),O=n(5),E=n(28),S=n(657),D=n(139);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var w=function(t){m()(GoogleSitekitAdminbar,t);var n,r=j(GoogleSitekitAdminbar);function GoogleSitekitAdminbar(e){var t;return l()(this,GoogleSitekitAdminbar),(t=r.call(this,e)).handleMoreDetailsLink=t.handleMoreDetailsLink.bind(f()(t)),t}return d()(GoogleSitekitAdminbar,[{key:"handleMoreDetailsLink",value:(n=c()(i.a.mark((function t(){var n,a,r,o,c,s;return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e._googlesitekitLegacyData,a=n.permaLink,r=n.postID,o=n.postType,c=n.pageTitle,s=Object(O.m)("googlesitekit-dashboard",{permaLink:a,id:r,postType:o,pageTitle:c}),t.next=4,Object(O.w)("admin_bar","post_details_click");case 4:document.location=s;case 5:case"end":return t.stop()}}),t)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData,n=t.pageTitle,r=t.permaLink;return a.createElement(_.b,null,a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-3 mdc-layout-grid__cell--align-middle "},a.createElement("div",{className:"googlesitekit-adminbar__subtitle"},Object(k.__)("Stats for","google-site-kit")),a.createElement("div",{className:"googlesitekit-adminbar__title"},n?Object(O.e)(n):r)),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--align-middle "},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement(S.a,null))),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2 mdc-layout-grid__cell--align-middle "},a.createElement(E.a,{className:"googlesitekit-adminbar__link",href:"#",onClick:this.handleMoreDetailsLink},Object(k.__)("More details","google-site-kit"))))),a.createElement(E.a,{className:"googlesitekit-adminbar__link googlesitekit-adminbar__link--mobile",href:"#",onClick:this.handleMoreDetailsLink},Object(k.__)("More details","google-site-kit")))}}]),GoogleSitekitAdminbar}(_.a);function R(){var e=document.getElementById("js-googlesitekit-adminbar-modules");e&&(Object(O.o)(),Object(_.k)(a.createElement(D.a,{dataAPIContext:"Adminbar"},a.createElement(w,null)),e))}}.call(this,n(13),n(12))},65:function(e,t,n){"use strict";(function(e){var a=n(26),r=n.n(a),i=n(109),o=e._googlesitekitAPIFetchData||{},c=o.nonce,s=o.nonceEndpoint,l=o.preloadedData,u=o.rootURL;r.a.nonceEndpoint=s,r.a.nonceMiddleware=r.a.createNonceMiddleware(c),r.a.rootURLMiddleware=r.a.createRootURLMiddleware(u),r.a.preloadingMiddleware=Object(i.a)(l),r.a.use(r.a.nonceMiddleware),r.a.use(r.a.mediaUploadMiddleware),r.a.use(r.a.rootURLMiddleware),r.a.use(r.a.preloadingMiddleware),t.default=r.a}).call(this,n(13))},657:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(85);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(t){s()(AdminbarModules,t);var n=m(AdminbarModules);function AdminbarModules(){return r()(this,AdminbarModules),n.apply(this,arguments)}return o()(AdminbarModules,[{key:"render",value:function(){return e.createElement(f.b,null)}}]),AdminbarModules}(f.a);t.a=Object(p.a)("googlesitekit.AdminbarModules")(h)}).call(this,n(12))},66:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(168),y=n(77);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(Sparkline,t);var n=v(Sparkline);function Sparkline(){return r()(this,Sparkline),n.apply(this,arguments)}return o()(Sparkline,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.change,r=t.instanceId,i=t.invertChangeColor,o=t.loadSmall,c=t.loadCompressed,s=t.loadHeight,l=t.loadText;if(!n)return"loading...";var u=i?"red":"green",d=i?"green":"red",g={title:"",backgroundColor:"transparent",curveType:"line",width:"100%",height:"50",enableInteractivity:!1,chartArea:{height:"100%",width:"100%"},legend:{position:"none"},axisFontSize:0,hAxis:{baselineColor:"none",ticks:[]},vAxis:{baselineColor:"none",ticks:[]},axes:[],colors:[0<=(parseFloat(a)||0)?u:d]};return e.createElement("div",{className:"googlesitekit-analytics-sparkline-chart-wrap"},e.createElement(y.a,{data:n,options:g,id:"googlesitekit-sparkline-".concat(r),loadSmall:o,loadCompressed:c,loadHeight:s,loadText:l}))}}]),Sparkline}(f.a);b.propTypes={instanceId:m.a.number.isRequired,invertChangeColor:m.a.bool,loadSmall:m.a.bool,loadCompressed:m.a.bool,loadHeight:m.a.number,loadText:m.a.bool},b.defaultProps={invertChangeColor:!1,loadSmall:!0,loadCompressed:!0,loadHeight:46,loadText:!1},t.a=Object(h.a)(b)}).call(this,n(12))},67:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return r}));var a=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},r=function(e){return e.replace(/([a-z0-9]{1})([A-Z]{1})/g,"$1_$2").toUpperCase()}},72:function(e,t,n){"use strict";n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return r}));var a="core",r="modules"},74:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return p})),n.d(t,"d",(function(){return m})),n.d(t,"a",(function(){return h})),n.d(t,"c",(function(){return y}));var a=n(3),r=n.n(a),i=n(14),o=n.n(i);n(73);function c(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var a=0,r=function(){};return{s:r,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var l,u=["sessionStorage","localStorage"],d=[].concat(u),g=function(){var t=o()(r.a.mark((function t(n){var a,i;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,i="__storage_test__",a.setItem(i,i),a.removeItem(i),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==a.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),f=function(){var t=o()(r.a.mark((function t(){var n,a,i;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==l){t.next=25;break}n=c(d),t.prev=4,n.s();case 6:if((a=n.n()).done){t.next=16;break}if(i=a.value,!l){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,g(i);case 12:if(!t.sent){t.next=14;break}l=e[i];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===l&&(l=null);case 25:return t.abrupt("return",l);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),p=function(){var e=o()(r.a.mark((function e(t){var n,a,i,o,c=arguments;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=c.length>1&&void 0!==c[1]?c[1]:null,e.next=3,f();case 3:if(!(a=e.sent)){e.next=10;break}if(!(i=a.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(o=JSON.parse(i)).timestamp||!(null===n||Math.round(Date.now()/1e3)-o.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:o.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),m=function(){var t=o()(r.a.mark((function t(n,a){var i,o,c=arguments;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=c.length>2&&void 0!==c[2]?c[2]:void 0,t.next=3,f();case 3:if(!(o=t.sent)){t.next=14;break}return t.prev=5,o.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:i||Math.round(Date.now()/1e3),value:a})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),h=function(){var t=o()(r.a.mark((function t(n){var a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f();case 2:if(!(a=t.sent)){t.next=13;break}return t.prev=4,a.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),y=function(){var t=o()(r.a.mark((function t(){var n,a,i,o;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,a=[],i=0;i<n.length;i++)0===(o=n.key(i)).indexOf("googlesitekit_")&&a.push(o.substring("googlesitekit_".length));return t.abrupt("return",a);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:case"end":return t.stop()}}),t,null,[[4,10]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(13))},75:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(46),i=n(89);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=e.createElement(r.a
22
+ /* translators: %s: Module name */,{title:Object(a.sprintf)(Object(a.__)("%s Gathering Data","google-site-kit"),t)
23
+ /* translators: %s: Module name */,description:Object(a.sprintf)(Object(a.__)("%s data is not yet available, please check back later.","google-site-kit"),t)});return Object(i.a)(s,n,o,c)}}).call(this,n(12))},76:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(5),i=n(95),o=n(46),c=n(89),s=n(174);t.a=function(t,n){var l,u=arguments.length>2&&void 0!==arguments[2]&&arguments[2],d=arguments.length>3&&void 0!==arguments[3]&&arguments[3],g=arguments.length>4&&void 0!==arguments[4]&&arguments[4],f=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},p=null==f||null===(l=f.data)||void 0===l?void 0:l.reconnectURL,m=p?e.createElement(i.a,{message:n,reconnectURL:p}):n,h=e.createElement(o.a
24
+ /* translators: %s: module name */,{title:Object(a.sprintf)(Object(a.__)("Data error in %s","google-site-kit"),t),description:m,error:!0});return"Invalid Credentials"===n&&Object(r.u)(s.a),Object(c.a)(h,u,d,g)}}).call(this,n(12))},77:function(e,t,n){"use strict";(function(e,a){var r,i=n(3),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(23),g=n.n(d),f=n(9),p=n.n(f),m=n(10),h=n.n(m),y=n(4),v=n.n(y),b=n(14),_=n.n(b),k=n(1),O=n(2),E=n.n(O),S=n(0),D=n(15),j=n(49);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return h()(this,n)}}function R(){return A.apply(this,arguments)}function A(){return(A=_()(o.a.mark((function t(){var n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!r){t.next=2;break}return t.abrupt("return",r);case 2:return e.google&&e.google.charts?r=Promise.resolve():((n=document.createElement("script")).type="text/javascript",r=new Promise((function(t){n.onload=t,e.document.head.appendChild(n),n.src="https://www.gstatic.com/charts/loader.js"}))),t.abrupt("return",r);case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var C=function(t){p()(GoogleChart,t);var n,r=w(GoogleChart);function GoogleChart(e){var t;return s()(this,GoogleChart),(t=r.call(this,e)).state={loading:!0,chart:null},t.onChartsLoad=t.onChartsLoad.bind(g()(t)),t.waitForChart=t.waitForChart.bind(g()(t)),t.getData=t.getData.bind(g()(t)),t.prepareChart=t.prepareChart.bind(g()(t)),t.drawChart=t.drawChart.bind(g()(t)),t.updateChart=t.updateChart.bind(g()(t)),t.chartRef=Object(k.h)(),t.resize=Object(D.debounce)(t.drawChart,100),t}return u()(GoogleChart,[{key:"onChartsLoad",value:function(){this.getData(),this.prepareChart(),this.drawChart(),this.setState({loading:!1})}},{key:"componentDidMount",value:(n=_()(o.a.mark((function t(){return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,R();case 2:e.google.charts.load("current",{packages:["corechart"]}),e.google.charts.setOnLoadCallback(this.onChartsLoad),e.addEventListener("resize",this.resize);case 5:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})},{key:"componentDidUpdate",value:function(e){var t=this.props.selectedStats;0!==t.length&&JSON.stringify(t)!==JSON.stringify(e.selectedStats)&&this.updateChart()}},{key:"componentWillUnmount",value:function(){e.removeEventListener("resize",this.resize)}},{key:"waitForChart",value:function(e){setTimeout((function(){e()}),500)}},{key:"getData",value:function(){return e.google&&e.google.visualization&&e.google.visualization.arrayToDataTable(this.props.data)}},{key:"prepareChart",value:function(){var t=this.chartRef.current;if(e.google&&t){var n="pie"===this.props.chartType?new e.google.visualization.PieChart(t):new e.google.visualization.LineChart(t);this.setState({chart:n})}else this.waitForChart(this.prepareChart)}},{key:"drawChart",value:function(){var e=this.state.chart,t=this.props,n=t.selectedStats,a=t.options,r=this.getData();null!==r&&null!==e?(e.draw(r,a),0!==n.length&&this.updateChart()):this.waitForChart(this.drawChart)}},{key:"updateChart",value:function(){var t=this.state.chart,n=this.props,a=n.selectedStats,r=n.options,i=n.singleStat,o=this.getData();if(null!==o&&null!==t){var c=new e.google.visualization.DataView(o);if(!i){var s=[0];s=s.concat(a.map((function(e){return e+1}))),c.setColumns(s)}t.draw(c,r)}else this.waitForChart(this.drawChart)}},{key:"render",value:function(){var e=this.state.loading,t=this.props,n=t.className,r=t.loadSmall,i=t.loadCompressed,o=t.loadHeight,c=t.loadText;return a.createElement("div",{className:"googlesitekit-graph-wrapper"},a.createElement("div",{ref:this.chartRef,className:"googlesitekit-line-chart"},a.createElement("div",{className:"googlesitekit-chart-loading"},e&&a.createElement("div",{className:"googlesitekit-chart-loading__wrapper"},c&&a.createElement("p",null,Object(S.__)("Loading chart…","google-site-kit")),a.createElement(j.a,{className:n,small:r,compress:i,height:o})))))}}]),GoogleChart}(k.a);C.propTypes={selectedStats:E.a.array,options:E.a.object.isRequired,id:E.a.string,singleStat:E.a.bool,className:E.a.string,loadSmall:E.a.bool,loadCompressed:E.a.bool,loadHeight:E.a.number,loadText:E.a.bool},C.defaultProps={selectedStats:[],id:"",singleStat:!0,className:"",loadSmall:!1,loadCompressed:!1,loadHeight:null,loadText:!0},t.a=C}).call(this,n(13),n(12))},78:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return r}));var a=n(105),r=n.n(a)()(e)}).call(this,n(13))},82:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(2),m=n.n(p),h=n(18),y=n.n(h),v=n(0),b=n(28);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(SourceLink,t);var n=_(SourceLink);function SourceLink(){return r()(this,SourceLink),n.apply(this,arguments)}return o()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,a=t.href,r=t.className,i=t.external;return e.createElement("div",{className:y()("googlesitekit-source-link",r)},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(b.a,{key:"link",href:a,external:i,inherit:!0},n)])}}]),SourceLink}(f.a);k.propTypes={name:m.a.string,href:m.a.string,className:m.a.string,external:m.a.bool},k.defaultProps={name:"",href:"",className:"",external:!1},t.a=k}).call(this,n(12))},84:function(e,t,n){"use strict";n.d(t,"e",(function(){return a})),n.d(t,"d",(function(){return r})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"g",(function(){return c})),n.d(t,"f",(function(){return s})),n.d(t,"a",(function(){return l})),n.d(t,"i",(function(){return u})),n.d(t,"h",(function(){return d})),n.d(t,"k",(function(){return g})),n.d(t,"m",(function(){return f})),n.d(t,"j",(function(){return p})),n.d(t,"l",(function(){return m})),n.d(t,"o",(function(){return h})),n.d(t,"n",(function(){return y}));var a="none",r="multiple",i="disapproved",o="graylisted",c="pending",s="no-client",l="approved",u="none",d="added",g=function(e){var t=e.accounts,n=e.clients,i=e.alerts,c=e.error,u=e.previousAccountID,d=e.previousClientID;return void 0===t||void 0===u?v(c):p({accounts:t,previousAccountID:u})?void 0!==n&&void 0!==d?void 0===i?b(c):i.some((function(e){return"GRAYLISTED_PUBLISHER"===e.type}))?o:m({clients:n,previousClientID:d})?l:s:void 0:t.length?r:a},f=function(e){var t=e.urlChannels,n=e.siteURL;if(void 0!==t&&void 0!==n)return t.some((function(e){return 0<=n.indexOf(e.urlPattern)}))?d:u},p=function(e){var t=e.accounts,n=e.previousAccountID;if(void 0!==t&&t.length){if(t.length>1){if(!n)return;return t.reduce((function(e,t){return t.id===n?n:e}),void 0)}return t[0].id}},m=function(e){var t=e.clients,n=e.previousClientID;if(void 0!==t){var a=t.filter((function(e){return"AFC"===e.productCode}));if(a.length){if(a.length>1&&n){var r=a.reduce((function(e,t){return t.id===n?n:e}),"");if(r)return r}return a[0].id}}},h=function(e){return e===o||e===c},y=function(e){return v(e)||b(e)},v=function(e){return _(e,"noAdSenseAccount")?a:_(e,"disapprovedAccount")?i:void 0},b=function(e){if(_(e,"accountPendingReview"))return c},_=function(e,t){return!(!e||!e.data)&&t===e.data.reason}},87:function(e,t,n){"use strict";n.d(t,"a",(function(){return y})),n.d(t,"c",(function(){return b})),n.d(t,"b",(function(){return _}));var a=n(45),r=n.n(a),i=n(11),o=n.n(i),c=n(3),s=n.n(c),l=n(19),u=n.n(l),d=n(8),g=n.n(d),f=n(74);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function m(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=g.a.createRegistryControl,y=function(e){var t;u()(e,"storeName is required to create a snapshot store.");var n={},a={deleteSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"DELETE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})),restoreSnapshot:s.a.mark((function e(){var t,n,a,r,i,o,c=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=c.length>0&&void 0!==c[0]?c[0]:{},n=t.clearAfterRestore,a=void 0===n||n,e.next=4,{payload:{},type:"RESTORE_SNAPSHOT"};case 4:if(r=e.sent,i=r.cacheHit,o=r.value,!i){e.next=13;break}return e.next=10,{payload:{snapshot:o},type:"SET_STATE_FROM_SNAPSHOT"};case 10:if(!a){e.next=13;break}return e.next=13,{payload:{},type:"DELETE_SNAPSHOT"};case 13:return e.abrupt("return",i);case 14:case"end":return e.stop()}}),e)})),createSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"CREATE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)}))},i=(t={},o()(t,"DELETE_SNAPSHOT",(function(){return Object(f.a)("datastore::cache::".concat(e))})),o()(t,"CREATE_SNAPSHOT",h((function(t){return function(){return Object(f.d)("datastore::cache::".concat(e),t.stores[e].store.getState())}}))),o()(t,"RESTORE_SNAPSHOT",(function(){return Object(f.b)("datastore::cache::".concat(e),3600)})),t);return{INITIAL_STATE:n,actions:a,controls:i,reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n,t=arguments.length>1?arguments[1]:void 0,a=t.type,i=t.payload;switch(a){case"SET_STATE_FROM_SNAPSHOT":var o=i.snapshot,c=(o.error,r()(o,["error"]));return m({},c);default:return m({},e)}}}},v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Object.values(e.stores).filter((function(e){return Object.keys(e.getActions()).includes("restoreSnapshot")}))},b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Promise.all(v(e).map((function(e){return e.getActions().createSnapshot()})))},_=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Promise.all(v(e).map((function(e){return e.getActions().restoreSnapshot()})))}},88:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(1),p=n(18),m=n.n(p),h=n(2),y=n.n(h),v=n(16),b=n(33),_=n(149);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var O=function(t){s()(PageHeader,t);var n=k(PageHeader);function PageHeader(){return r()(this,PageHeader),n.apply(this,arguments)}return o()(PageHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.icon,r=t.iconWidth,i=t.iconHeight,o=t.iconID,c=t.className,s=t.status,l=t.statusText,u=t.fullWidth?"\n\t\t\tmdc-layout-grid__cell\n\t\t\tmdc-layout-grid__cell--span-12\n\t\t\t":"\n\t\t\tmdc-layout-grid__cell\n\t\t\tmdc-layout-grid__cell--span-4-phone\n\t\t\tmdc-layout-grid__cell--span-4-tablet\n\t\t\tmdc-layout-grid__cell--span-6-desktop\n\t\t\t",d=Object(v.c)("googlesitekit.showDateRangeSelector-".concat(o),!1),g=!(""===s&&!d);return e.createElement("header",{className:"googlesitekit-page-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:u},a&&e.createElement(b.a,{id:o,height:i,width:r,className:"googlesitekit-page-header__icon"}),e.createElement("h1",{className:m()("googlesitekit-page-header__title",c)},n)),g&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--align-right-tablet mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement("div",{className:"googlesitekit-page-header__details"},s&&e.createElement("span",{className:m()("googlesitekit-page-header__status","googlesitekit-page-header__status--".concat(s))},l),d&&e.createElement("span",{className:"googlesitekit-page-header__range"},e.createElement(_.a,null))))))}}]),PageHeader}(f.a);O.propTypes={title:y.a.string,icon:y.a.bool,iconID:y.a.string,iconWidth:y.a.string,iconHeight:y.a.string,className:y.a.string,status:y.a.string,statusText:y.a.string,fullWidth:y.a.bool},O.defaultProps={title:"",icon:!1,iconID:"",iconWidth:"",iconHeight:"",className:"googlesitekit-heading-3",status:"",statusText:"",fullWidth:!1},t.a=O}).call(this,n(12))},89:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(27);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return e.createElement(a.b,null,n&&i&&o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(r.a,{fill:!0},e.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))))),n&&!i&&o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(r.a,{fill:!0},e.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))))),n&&i&&!o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},t),n&&!i&&!o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},t),!n&&!i&&o&&e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))),!n&&!i&&!o&&t)}}).call(this,n(12))},91:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(28);t.a=function HelpLink(){var t=Object(a.__)("Need help?","google-site-kit");return e.createElement(r.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},92:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(8),i=n.n(r),o=n(138),c=n(169),s=n(171),l=n(20),u=i.a.useSelect;t.a=function Header(){var t=u((function(e){return e(l.c).isAuthenticated()}));return e.createElement(a.b,null,e.createElement("header",{className:"googlesitekit-header"},e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(o.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&e.createElement(c.a,null))))),e.createElement(s.a,null))}}).call(this,n(12))},93:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),g=n.n(d),f=n(85);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(ModuleSettingsWarning,e);var t=p(ModuleSettingsWarning);function ModuleSettingsWarning(){return r()(this,ModuleSettingsWarning),t.apply(this,arguments)}return o()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(n(1).a);t.a=Object(f.a)("googlesitekit.ModuleSettingsWarning")(m)},95:function(e,t,n){"use strict";(function(e){n(1);var a=n(2),r=n.n(a),i=n(167),o=n(0),c=n(5);function ErrorText(t){var n=t.message,a=t.reconnectURL;if(!n)return null;var r=Object(o.sprintf)(
25
+ /* translators: %s: Error message */
26
+ Object(o.__)("Error: %s","google-site-kit"),n);a&&Object(i.a)(a)&&(r=r+" "+Object(o.sprintf)(
27
+ /* translators: %s: Reconnect URL */
28
+ Object(o.__)('To fix this, <a href="%s">redo the plugin setup</a>.',"google-site-kit"),a));return e.createElement("div",{className:"googlesitekit-error-text"},e.createElement("p",{dangerouslySetInnerHTML:Object(c.t)(r,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})}))}ErrorText.propTypes={message:r.a.string.isRequired,reconnectURL:r.a.string},ErrorText.defaultProps={reconnectURL:""},t.a=ErrorText}).call(this,n(12))},96:function(e,t,n){"use strict";n.d(t,"a",(function(){return d.c}));var a=n(8),r=n.n(a),i=n(3),o=n.n(i),c=n(11),s=n.n(c),l=n(41),u=n.n(l),d=n(20),g=n(43);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=r.a.createRegistrySelector,h=Object(g.a)({baseName:"getAuthentication",controlCallback:function(){return u.a.get("core","user","authentication",void 0,{useCache:!1})},reducerCallback:function(e,t){return p(p({},e),{},{authentication:t})}}),y={authentication:void 0},v={getAuthentication:o.a.mark((function e(){var t;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,r.a.commonActions.getRegistry();case 2:if(t=e.sent,(0,t.select)(d.c).getAuthentication()){e.next=7;break}return e.next=7,h.actions.fetchGetAuthentication();case 7:case"end":return e.stop()}}),e)}))},b={getAuthentication:function(e){return e.authentication},hasScope:m((function(e){return function(t,n){var a=e(d.c).getGrantedScopes(t);if(void 0!==a)return a.includes(n)}})),isAuthenticated:m((function(e){return function(){return(e(d.c).getAuthentication()||{}).authenticated}})),getGrantedScopes:m((function(e){return function(){return(e(d.c).getAuthentication()||{}).grantedScopes}})),getRequiredScopes:m((function(e){return function(){return(e(d.c).getAuthentication()||{}).requiredScopes}})),getUnsatisfiedScopes:m((function(e){return function(){return(e(d.c).getAuthentication()||{}).unsatisfiedScopes}})),needsReauthentication:m((function(e){return function(){return(e(d.c).getAuthentication()||{}).needsReauthentication}}))},_=r.a.combineStores(h,{INITIAL_STATE:y,resolvers:v,selectors:b}),k=(_.INITIAL_STATE,_.actions,_.controls,_.reducer,_.resolvers,_.selectors,_),O=n(19),E=n.n(O);function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function D(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var j={INITIAL_STATE:{dateRange:"last-28-days"},actions:{setDateRange:function(e){return E()(e,"Date range slug is required."),{type:"SET_DATE_RANGE",payload:{slug:e}}}},controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"SET_DATE_RANGE":return D(D({},e),{},{dateRange:a.slug});default:return D({},e)}},resolvers:{},selectors:{getDateRange:function(e){return e.dateRange}}};function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var A=r.a.createRegistrySelector,C=Object(g.a)({baseName:"disconnect",controlCallback:function(){return u.a.set("core","user","disconnect")},reducerCallback:function(e,t){return R(R({},e),{},{disconnected:t})}}),N={disconnected:void 0},P={disconnect:o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,C.actions.fetchDisconnect();case 2:case"end":return e.stop()}}),e)}))},x={isDoingDisconnect:A((function(e){return function(){return e(d.c).isFetchingDisconnect()}}))},T=r.a.combineStores(C,{INITIAL_STATE:N,actions:P,selectors:x}),L=(T.INITIAL_STATE,T.actions,T.controls,T.reducer,T.resolvers,T.selectors,T);function I(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}var M={INITIAL_STATE:{error:void 0},actions:{},controls:{},reducer:function(e){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?I(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e)},resolvers:{},selectors:{getError:function(e){return e.error}}},W=n(112),U=Object(W.a)("core","user","notifications",{server:!1}),q=n(122),F=n(123),H=r.a.combineStores(r.a.commonStore,k,j,L,M,U,q.a,F.a);H.INITIAL_STATE,H.actions,H.controls,H.reducer,H.resolvers,H.selectors;r.a.registerStore(d.c,H)},97:function(e,t,n){"use strict";(function(e,a){var r=n(35),i=n.n(r),o=(n(1),n(150)),c=n.n(o),s=n(0),l=n(8),u=n.n(l),d=n(38),g=n(5),f=n(20),p=u.a.useSelect,m={siteverification:"site-verification",webmasters:"search-console"};t.a=function DashboardAuthAlert(){var t,n,r,o,l,u=p((function(e){return e(f.c).getUnsatisfiedScopes()})),h=p((function(t){return t(f.c).getConnectURL({redirectURL:e.location.href})}));if(void 0===u||void 0===h)return null;switch(u.some((function(e){return!e.match(/^https:\/\/www.googleapis.com\/auth\//)}))?t="generic":(r=u,o=Object(g.j)(),t=(n=r.map((function(e){return e.match(/^https:\/\/www.googleapis.com\/auth\/([a-z]+)/)})).map((function(e){var t=i()(e,2)[1];return m[t]||t})).map((function(e){var t;return(null===(t=o[e])||void 0===t?void 0:t.name)||!1}))).some((function(e){return!1===e}))?"generic":1<(n=c()(n)).length?"multiple":"single"),t){case"multiple":
29
+ /* translators: used between list items, there is a space after the comma. */
30
+ var y=Object(s.__)(", ","google-site-kit");l=Object(s.sprintf)(
31
+ /* translators: %s: List of product names */
32
+ Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for: %s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n.join(y));break;case"single":l=Object(s.sprintf)(
33
+ /* translators: %1$s: Product name */
34
+ Object(s.__)("Site Kit can’t access the relevant data from %1$s because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for %1$s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n[0]);break;case"generic":l=Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup – make sure to approve all permissions at the authentication stage.","google-site-kit")}return a.createElement(d.a,{id:"authentication error",title:Object(s.__)("Site Kit can’t access necessary data","google-site-kit"),description:l,format:"small",type:"win-error",isDismissable:!1,ctaLink:h,ctaLabel:Object(s.__)("Redo setup","google-site-kit")})}}).call(this,n(13),n(12))},99:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var a=n(40),r=n(29),i=function(t,n,i){var o=Object(r.c)(t,n,i);Object(r.d)(),Object.keys(e._googlesitekitLegacyData.admin.datacache).forEach((function(t){0!==t.indexOf(o+"::")&&t!==o||delete e._googlesitekitLegacyData.admin.datacache[t]})),Object.keys(Object(a.a)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(o,"::"))&&e!=="googlesitekit_".concat(o)||Object(a.a)().removeItem(e)}))}}).call(this,n(13))}}]);
dist/assets/js/chunk-googlesitekit-adminbar-e1a01c9625180ff3775e.js DELETED
@@ -1,34 +0,0 @@
1
- (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[1],{1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return o})),n.d(t,"a",(function(){return c})),n.d(t,"e",(function(){return l})),n.d(t,"f",(function(){return u})),n.d(t,"g",(function(){return g})),n.d(t,"h",(function(){return f})),n.d(t,"b",(function(){return m})),n.d(t,"i",(function(){return b})),n.d(t,"j",(function(){return v})),n.d(t,"k",(function(){return D})),n.d(t,"c",(function(){return j})),n.d(t,"l",(function(){return A})),n.d(t,"m",(function(){return C})),n.d(t,"n",(function(){return P})),n.d(t,"o",(function(){return T})),n.d(t,"p",(function(){return L})),n.d(t,"q",(function(){return I})),n.d(t,"r",(function(){return W})),n.d(t,"s",(function(){return M}));var a=n(96);void 0===e.googlesitekit&&(e.googlesitekit={});var r=e.googlesitekit._element||a,i=r.Children,o=r.cloneElement,c=r.Component,s=r.concatChildren,l=r.createContext,u=r.createElement,d=r.createInterpolateElement,g=r.createPortal,f=r.createRef,p=r.findDOMNode,h=r.forwardRef,m=r.Fragment,y=r.isEmptyElement,b=r.isValidElement,v=r.lazy,_=r.memo,k=r.Platform,O=r.RawHTML,D=r.render,E=r.renderToString,S=r.StrictMode,j=r.Suspense,w=r.switchChildrenNodeName,R=r.unmountComponentAtNode,A=r.useCallback,C=r.useContext,N=r.useDebugValue,P=r.useEffect,x=r.useImperativeHandle,T=r.useLayoutEffect,L=r.useMemo,I=r.useReducer,W=r.useRef,M=r.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:i,cloneElement:o,Component:c,concatChildren:s,createContext:l,createElement:u,createInterpolateElement:d,createPortal:g,createRef:f,findDOMNode:p,forwardRef:h,Fragment:m,isEmptyElement:y,isValidElement:b,lazy:v,memo:_,Platform:k,RawHTML:O,render:D,renderToString:E,StrictMode:S,Suspense:j,switchChildrenNodeName:w,unmountComponentAtNode:R,useCallback:A,useContext:C,useDebugValue:N,useEffect:P,useImperativeHandle:x,useLayoutEffect:T,useMemo:L,useReducer:I,useRef:W,useState:M})}).call(this,n(15))},100:function(e,t,n){"use strict";(function(e,a){var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(8),f=n.n(g),p=n(9),h=n.n(p),m=n(3),y=n.n(m),b=n(1),v=n(2),_=n.n(v),k=n(0),O=n(5),D=n(115),E=n(17),S=n(46),j=n(107);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=y()(e);if(t){var r=y()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return h()(this,n)}}var R=function(t){f()(AnalyticsInactiveCTA,t);var n,r=w(AnalyticsInactiveCTA);function AnalyticsInactiveCTA(){return l()(this,AnalyticsInactiveCTA),r.apply(this,arguments)}return d()(AnalyticsInactiveCTA,[{key:"render",value:function(){var t=this.props,n=t.title,r=void 0===n?Object(k.__)("Learn more about what visitors do on your site.","google-site-kit"):n,i=t.description,o=void 0===i?Object(k.__)("Connecting with Google Analytics to see unique vistors, goal completions, top pages and more.","google-site-kit"):i,c=t.ctaLabel,s=void 0===c?Object(k.__)("Set up Analytics","google-site-kit"):c;return e._googlesitekitLegacyData.permissions.canManageOptions?a.createElement(S.a,{title:r,description:o,onClick:AnalyticsInactiveCTA.setupAnalyticsClick,ctaLabel:s}):null}}],[{key:"setupAnalyticsClick",value:(n=c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,Object(O.b)(E.c,"analytics",!0);case 3:return t.next=5,Object(D.a)();case 5:e.location=Object(O.l)("analytics",!0),t.next=11;break;case 8:t.prev=8,t.t0=t.catch(0),Object(O.u)(j.a,{id:"analytics-setup-error",title:Object(k.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 11:case"end":return t.stop()}}),t,null,[[0,8]])}))),function(){return n.apply(this,arguments)})}]),AnalyticsInactiveCTA}(b.a);R.propTypes={title:_.a.string,description:_.a.string,ctaLabel:_.a.string},R.defaultProps={},t.a=R}).call(this,n(15),n(12))},105:function(e,t,n){"use strict";function a(e){return"string"==typeof e&&/^pub-\d+$/.test(e)}function r(e){return"string"==typeof e&&/^ca-pub-\d+$/.test(e)}n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return r}))},106:function(e,t,n){"use strict";var a=n(98);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(a.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,r){if(n)return r(e);setTimeout((function(){n=!0}),1e3);var i=e.parse,o=void 0===i||i,c=e.path;if("string"==typeof e.path){var s,l=(null===(s=e.method)||void 0===s?void 0:s.toUpperCase())||"GET",u=Object(a.getStablePath)(c);if(o&&"GET"===l&&t[u]){var d=Promise.resolve(t[u].body);return delete t[u],d}if("OPTIONS"===l&&t[l]&&t[l][u]){var g=Promise.resolve(t[l][u]);return delete t[l][u],g}}return r(e)}}},107:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(37);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(t){s()(GenericError,t);var n=h(GenericError);function GenericError(){return r()(this,GenericError),n.apply(this,arguments)}return o()(GenericError,[{key:"render",value:function(){return e.createElement(p.a,this.props)}}]),GenericError}(f.a);t.a=m}).call(this,n(12))},109:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(209),y=n.n(m),b=n(18),v=n.n(b),_=n(164),k=n(0),O=n(47),D=n(28),E=n(43);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var j=function(t){s()(Dialog,t);var n=S(Dialog);function Dialog(){var e;return r()(this,Dialog),(e=n.call(this)).state={attributes:[Object(k.__)("Audience overview","google-site-kit"),Object(k.__)("Top pages","google-site-kit"),Object(k.__)("Top acquisition channels","google-site-kit"),Object(k.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(f.h)(),e}return o()(Dialog,[{key:"componentDidMount",value:function(){new E.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,a=t.handleDialog,r=t.title,i=t.provides,o=t.handleConfirm,c=t.subtitle,s=t.confirmButton,l=t.dependentModules,u=t.instanceId,d=t.danger,g="googlesitekit-dialog-label-".concat(u),f="googlesitekit-dialog-description-".concat(u),p=!(!i||!i.length);return e.createElement("div",{ref:this.dialogRef,className:v()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":r?g:void 0,"aria-describedby":p?f:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(y.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},r&&e.createElement("h2",{id:g,className:"mdc-dialog__title"},r),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),p&&e.createElement("section",{id:f,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},i.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),l&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(k.__)("Note: ","google-site-kit")),l),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(O.a,{onClick:o,danger:d},s||Object(k.__)("Disconnect","google-site-kit")),e.createElement(D.a,{className:"mdc-dialog__cancel-button",onClick:function(){return a()},inherit:!0},Object(k.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(f.a);j.propTypes={dialogActive:h.a.bool,handleDialog:h.a.func,handleConfirm:h.a.func.isRequired,title:h.a.string,description:h.a.string,confirmButton:h.a.string,danger:h.a.bool},j.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null,danger:!1},t.a=Object(_.a)(j)}).call(this,n(12))},110:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return m}));var a=n(4),r=n.n(a),i=n(10),o=n.n(i),c=n(19),s=n.n(c),l=n(41),u=n.n(l),d=n(11),g=n.n(d),f=n(42);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=function(t,n,a){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},c=i.client,l=void 0===c||c,d=i.server,p=void 0===d||d,m=i.storeName,y=void 0===m?void 0:m;s()(t,"type is required."),s()(n,"identifier is required."),s()(a,"datapoint is required.");var b=y||"".concat(t,"/").concat(n),v={serverNotifications:p?void 0:{},clientNotifications:l?void 0:{}},_=Object(f.a)({baseName:"getNotifications",controlCallback:function(){return u.a.get(t,n,a)},reducerCallback:function(e,t){return h(h({},e),{},{serverNotifications:t.reduce((function(e,t){return h(h({},e),{},o()({},t.id,t))}),{})})}}),k={addNotification:function(e){return s()(e,"notification is required."),{payload:{notification:e},type:"ADD_NOTIFICATION"}},removeNotification:function(e){return s()(e,"id is required."),{payload:{id:e},type:"REMOVE_NOTIFICATION"}}},O={},D=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:v,n=arguments.length>1?arguments[1]:void 0,a=n.type,r=n.payload;switch(a){case"ADD_NOTIFICATION":var i=r.notification;return h(h({},t),{},{clientNotifications:h(h({},t.clientNotifications||{}),{},o()({},i.id,i))});case"REMOVE_NOTIFICATION":var c=r.id;if(void 0===t.clientNotifications||void 0===t.clientNotifications[c])return void 0!==t.serverNotifications&&void 0!==t.serverNotifications[c]&&e.console.warn('Cannot remove server-side notification with ID "'.concat(c,'"; this may be changed in a future release.')),h({},t);var s=h({},t.clientNotifications);return delete s[c],h(h({},t),{},{clientNotifications:s});default:return h({},t)}},E={getNotifications:r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,_.actions.fetchGetNotifications();case 2:case"end":return e.stop()}}),e)}))};p||delete E.getNotifications;var S={getNotifications:function(e){var t=e.serverNotifications,n=e.clientNotifications;return void 0===t&&void 0===n?t:Object.values(h(h({},t||{}),n||{}))}},j=g.a.combineStores(_,{INITIAL_STATE:v,actions:k,controls:O,reducer:D,resolvers:E,selectors:S});return h(h({},j),{},{STORE_NAME:b})}}).call(this,n(15))},111:function(e,t,n){"use strict";(function(e){var a=n(4),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(8),g=n.n(d),f=n(9),p=n.n(f),h=n(3),m=n.n(h),y=n(1),b=n(2),v=n.n(b),_=n(0),k=n(17),O=n(37);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return p()(this,n)}}var E=function(t){g()(Alert,t);var n,a=D(Alert);function Alert(e){var t;return s()(this,Alert),(t=a.call(this,e)).state={isLoading:!0,alerts:[],error:!1,message:""},t}return u()(Alert,[{key:"componentDidMount",value:function(){this.getAlert()}},{key:"getAlert",value:(n=o()(r.a.mark((function e(){var t,n;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,t=this.props.module,e.next=4,k.c.get(k.b,t,"notifications",{},!1);case 4:n=e.sent,this.setState({isLoading:!1,error:!1,alerts:n}),e.next=11;break;case 8:e.prev=8,e.t0=e.catch(0),this.setState({isLoading:!1,error:e.t0.code});case 11:case"end":return e.stop()}}),e,this,[[0,8]])}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.alerts,a=t.error,r=t.isLoading;if(a||r||!n||!n.length)return null;var i=n.map((function(t){return e.createElement(O.a,{id:t.id,key:t.id,title:t.title,description:t.message||t.description,dismiss:Object(_.__)("Dismiss","google-site-kit"),isDismissable:t.isDismissible,format:"small",ctaLink:t.ctaURL,ctaLabel:t.ctaLabel,ctaTarget:t.ctaTarget,type:t.severity})}));return e.createElement(y.b,null,i)}}]),Alert}(y.a);E.propTypes={module:v.a.string.isRequired},t.a=E}).call(this,n(12))},112:function(e,t,n){"use strict";(function(e,a){var r=n(10),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(2),b=n.n(y),v=n(0),_=n(5),k=n(75),O=n(25),D=n(17),E=n(28),S=n(30),j=n(21);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var C=function(t){d()(DashboardAcquisitionPieChart,t);var n=A(DashboardAcquisitionPieChart);function DashboardAcquisitionPieChart(){return c()(this,DashboardAcquisitionPieChart),n.apply(this,arguments)}return l()(DashboardAcquisitionPieChart,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.source;if(!n||n.error||!n.length)return null;var r=Object(j.e)(n);return e.createElement("div",{className:"googlesitekit-chart googlesitekit-chart--pie"},e.createElement(k.a,{data:r,options:{chartArea:{width:"100%",height:"100%"},backgroundColor:"transparent",height:250,legend:{alignment:"center",textStyle:{color:"#5b5b61",fontSize:12}},slices:{0:{color:"#178EC5"},1:{color:"#54B23B"},2:{color:"#EB5729"},3:{color:"#ECED33"},4:{color:"#34CBE3"},5:{color:"#82E88E"}},title:null,width:"100%"},chartType:"pie",id:"overview-piechart",loadHeight:205}),a&&e.createElement("div",{className:"googlesitekit-chart__source"},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(E.a,{key:"link",href:Object(_.m)("googlesitekit-module-analytics"),inherit:!0},Object(v._x)("Analytics","Service name","google-site-kit"))]))}}]),DashboardAcquisitionPieChart}(m.a);C.defaultProps={source:!1},C.propTypes={source:b.a.bool},t.a=Object(O.a)(C,[{type:D.b,identifier:"analytics",datapoint:"report",data:R(R({},j.s),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(_.n)("day"),context:["Dashboard","Single"]}],e.createElement(S.a,{width:"282px",height:"282px",shape:"circular"}),{},j.h,j.f)}).call(this,n(12),n(15))},114:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(Modal,e);var t=p(Modal);function Modal(e){var n;return r()(this,Modal),(n=t.call(this,e)).el=document.createElement("div"),n.root=document.querySelector(".googlesitekit-plugin")||document.body,n}return o()(Modal,[{key:"componentDidMount",value:function(){this.root.appendChild(this.el)}},{key:"componentWillUnmount",value:function(){this.root.removeChild(this.el)}},{key:"render",value:function(){return Object(f.g)(this.props.children,this.el)}}]),Modal}(f.a)},115:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return g}));var a=n(4),r=n.n(a),i=n(10),o=n.n(i),c=n(14),s=n.n(c),l=n(17);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function d(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var g=function(){var t=s()(r.a.mark((function t(){var n,a,i,o,c,s;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,l.c.get(l.a,"user","authentication",{timestamp:Date.now()});case 3:n=t.sent,a=n.authenticated,i=n.requiredScopes,o=n.grantedScopes,c=n.unsatisfiedScopes,s=void 0===c?[]:c,e._googlesitekitLegacyData.setup=d(d({},e._googlesitekitLegacyData.setup||{}),{},{isAuthenticated:a,requiredScopes:i,grantedScopes:o,unsatisfiedScopes:s,needReauthenticate:0<s.length}),t.next=14;break;case 12:t.prev=12,t.t0=t.catch(0);case 14:case"end":return t.stop()}}),t,null,[[0,12]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(15))},116:function(e,t,n){"use strict";n.d(t,"d",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"b",(function(){return c})),n.d(t,"a",(function(){return s}));var a=n(222),r=n(45),i=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.siteURL,n="https://www.google.com/adsense/signup/new",a={source:"site-kit",utm_source:"site-kit",utm_medium:"wordpress_signup"};return t&&(a.url=t),Object(r.a)(n,a)},o=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.accountID,n=e.userEmail,a=l({accountID:t,userEmail:n,path:"/home"});return Object(r.a)(a,{source:"site-kit"})},c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.accountID,n=e.siteURL,a=e.userEmail,i=l({accountID:t,userEmail:a,path:"/sites/my-sites"}),o={source:"site-kit"};return n&&(o.url=u(n)||n),Object(r.a)(i,o)},s=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.accountID,n=e.siteURL,a=e.userEmail,i=l({accountID:t,userEmail:a,path:"/myads/sites/preview"}),o={source:"site-kit"};return n&&(o.url=u(n)||n),Object(r.a)(i,o)},l=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},t=e.accountID,n=e.userEmail,a=e.path,r=void 0===a?"/home":a,i="https://www.google.com/adsense/new";return n&&(i+="/u/".concat(n)),t&&(i+="/".concat(t),r&&(i+=r)),i},u=function(e){var t=new URL(e);return Object(a.parse)(t.hostname).domain}},119:function(e,t,n){"use strict";(function(e){n(1);t.a=function Warning(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#F9BB2D",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"warning-title warning-desc"},e.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),e.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"}))}}).call(this,n(12))},120:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return AdSenseLinkCTA}));n(1);var a=n(0),r=n(46);function AdSenseLinkCTA(){return e.createElement(r.a,{title:Object(a.__)("Link Analytics and AdSense","google-site-kit"),description:Object(a.__)("Get reports for your top earning pages by linking your Analytics and AdSense accounts.","google-site-kit"),ctaLink:"https://support.google.com/adsense/answer/6084409",ctaLabel:Object(a.__)("Learn more","google-site-kit")})}}).call(this,n(12))},121:function(e,t,n){"use strict";(function(e){var a=n(4),r=n.n(a),i=n(10),o=n.n(i),c=n(19),s=n.n(c),l=n(11),u=n.n(l),d=n(20);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var p=u.a.createRegistrySelector,h={permissionError:null,capabilities:void 0},m={clearPermissionScopeError:function(){return{payload:{},type:"CLEAR_PERMISSION_SCOPE_ERROR"}},setPermissionScopeError:function(e){return s()(e,"permissionError is required."),{payload:{permissionError:e},type:"SET_PERMISSION_SCOPE_ERROR"}},receiveCapabilities:function(e){return{type:"RECEIVE_CAPABILITIES",payload:{capabilities:e}}}},y={getCapabilities:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,u.a.commonActions.getRegistry();case 2:if(!t.sent.select(d.c).getCapabilities()){t.next=5;break}return t.abrupt("return");case 5:return(null===(n=e._googlesitekitUserData)||void 0===n?void 0:n.permissions)||e.console.error("Could not load core/user permissions."),t.next=8,m.receiveCapabilities(null===(a=e._googlesitekitUserData)||void 0===a?void 0:a.permissions);case 8:case"end":return t.stop()}}),t)}))},b={getPermissionScopeError:function(e){return e.permissionError},getCapabilities:function(e){return e.capabilities},hasCapability:p((function(e){return function(t,n){var a=e(d.c).getCapabilities();if(a)return!!a[n]}}))};t.a={INITIAL_STATE:h,actions:m,controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"CLEAR_PERMISSION_SCOPE_ERROR":return f(f({},e),{},{permissionError:null});case"SET_PERMISSION_SCOPE_ERROR":var r=a.permissionError;return f(f({},e),{},{permissionError:r});case"RECEIVE_CAPABILITIES":var i=a.capabilities;return f(f({},e),{},{capabilities:i});default:return f({},e)}},resolvers:y,selectors:b}}).call(this,n(15))},122:function(e,t,n){"use strict";(function(e){var a=n(4),r=n.n(a),i=n(10),o=n.n(i),c=n(19),s=n.n(c),l=n(45),u=n(11),d=n.n(u),g=n(20);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=d.a.createRegistrySelector,m={connectURL:void 0,user:void 0,verified:void 0},y={receiveConnectURL:function(e){return s()(e,"connectURL is required."),{payload:{connectURL:e},type:"RECEIVE_CONNECT_URL"}},receiveUserInfo:function(e){return s()(e,"userInfo is required."),{payload:{user:e},type:"RECEIVE_USER_INFO"}},receiveUserIsVerified:function(e){return s()(void 0!==e,"userIsVerified is required."),{payload:{verified:e},type:"RECEIVE_USER_IS_VERIFIED"}}},b={getConnectURL:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,!(0,n.select)(g.c).getConnectURL()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.connectURL,t.next=12,y.receiveConnectURL(a);case 12:case"end":return t.stop()}}),t)})),getUser:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(g.c).getUser()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.user,t.next=12,y.receiveUserInfo(a);case 12:case"end":return t.stop()}}),t)})),isVerified:r.a.mark((function t(){var n,a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,d.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(g.c).isVerified()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return a=e._googlesitekitUserData.verified,t.next=12,y.receiveUserIsVerified(a);case 12:case"end":return t.stop()}}),t)}))},v={getUser:function(e){return e.user},getConnectURL:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.additionalScopes,a=void 0===n?[]:n,r=t.redirectURL,i=void 0===r?void 0:r,o=e.connectURL,c={redirect:i};if(void 0!==o)return(null==a?void 0:a.length)?Object(l.a)(o,p(p({},c),{},{additional_scopes:a})):Object(l.a)(o,c)},getID:h((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.id:t}})),getName:h((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.name:t}})),getEmail:h((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.email:t}})),getPicture:h((function(e){return function(){var t=e(g.c).getUser();return void 0!==t?t.picture:t}})),isVerified:function(e){return e.verified}};t.a={INITIAL_STATE:m,actions:y,controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"RECEIVE_CONNECT_URL":var r=a.connectURL;return p(p({},e),{},{connectURL:r});case"RECEIVE_USER_INFO":var i=a.user;return p(p({},e),{},{user:i});case"RECEIVE_USER_IS_VERIFIED":var o=a.verified;return p(p({},e),{},{verified:o});default:return p({},e)}},resolvers:b,selectors:v}}).call(this,n(15))},123:function(e,t,n){"use strict";(function(e){n(1);var a=n(2),r=n.n(a),i=n(18),o=n.n(i);function ChangeArrow(t){var n=t.direction,a=t.invertColor;return e.createElement("svg",{className:o()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(n),{"googlesitekit-change-arrow--inverted-color":a}),width:"9",height:"9",viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("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:r.a.string,invertColor:r.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,n(12))},124:function(e,t,n){"use strict";(function(e){n(1);t.a=function Error(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#EA4336",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"error-title error-desc"},e.createElement("path",{d:"M4.47 21h15.06c1.54 0 2.5-1.67 1.73-3L13.73 4.99c-.77-1.33-2.69-1.33-3.46 0L2.74 18c-.77 1.33.19 3 1.73 3zM12 14c-.55 0-1-.45-1-1v-2c0-.55.45-1 1-1s1 .45 1 1v2c0 .55-.45 1-1 1zm1 4h-2v-2h2v2z"}))}}).call(this,n(12))},125:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(37);t.a=function DashboardPermissionAlert(){return e.createElement(r.a,{id:"permission error",title:Object(a.__)("Permissions issue accessing data","google-site-kit"),description:Object(a.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,n(12))},126:function(e,t,n){"use strict";(function(e,a){n(1);var r=n(0),i=n(5),o=n(46),c=n(87);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],s=arguments.length>2&&void 0!==arguments[2]&&arguments[2],l=arguments.length>3&&void 0!==arguments[3]&&arguments[3],u=Object(i.j)()[t].name,d=e.createElement(o.a
2
- /* translators: %s: Module name */,{title:Object(r.sprintf)(Object(r.__)("%s activation","google-site-kit"),u)
3
- /* translators: %s: Module name */,description:Object(r.sprintf)(Object(r.__)("%s module needs to be configured","google-site-kit"),u),ctaLabel:Object(r.__)("Complete activation","google-site-kit"),onClick:function(){a.location=Object(i.l)(t,!0)}});return Object(c.a)(d,n,s,l)}}).call(this,n(12),n(15))},127:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(5),m=n(34),y=n(47);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(AdSenseDashboardOutro,t);var n=b(AdSenseDashboardOutro);function AdSenseDashboardOutro(){return r()(this,AdSenseDashboardOutro),n.apply(this,arguments)}return o()(AdSenseDashboardOutro,[{key:"render",value:function(){var t=Object(h.j)().adsense.accountURL;return e.createElement("section",{className:"googlesitekit-module-outro"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("div",{className:"googlesitekit-module-outro__logo"},e.createElement(m.a,{id:"adsense",height:"36",width:"42"}),e.createElement(m.a,{id:"plus",height:"13",width:"13"}),e.createElement(m.a,{id:"analytics",height:"36",width:"34"})),e.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-module-outro__title "},Object(p.__)("Connect Analytics with AdSense to create a powerful team that shows robust metrics for your site.","google-site-kit")),e.createElement("div",{className:"googlesitekit-module-outro__button"},e.createElement(y.a,{href:t,target:"_blank"},Object(p.__)("Connect Accounts","google-site-kit")))))))}}]),AdSenseDashboardOutro}(f.a);t.a=v}).call(this,n(12))},128:function(e,t,n){"use strict";(function(e,a){var r=n(10),i=n.n(r),o=n(1),c=n(13),s=n(0),l=n(11),u=n.n(l),d=n(5),g=n(59),f=n(25),p=n(17),h=n(39),m=n(51),y=n(129),b=n(21),v=n(20);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var O=u.a.useSelect;t.a=Object(f.a)((function AnalyticsDashboardWidgetTopAcquisitionSources(t){var n=t.data,a=O((function(e){return e(v.c).getDateRange()}));if(!n||!n.length)return null;var r=Object(g.b)(a),i=[{title:Object(s.__)("Channel","google-site-kit"),tooltip:Object(s.__)("Channel refers to where your traffic originated from","google-site-kit")},{title:Object(s.__)("Users","google-site-kit"),tooltip:Object(s.__)("Number of users that originated from that traffic","google-site-kit")},{title:Object(s.__)("New Users","google-site-kit"),
4
- /* translators: %s: date range */
5
- tooltip:Object(s.sprintf)(Object(s.__)("Number of new users to visit your page over last %s","google-site-kit"),r)},{title:Object(s.__)("Sessions","google-site-kit"),
6
- /* translators: %s: date range */
7
- tooltip:Object(s.sprintf)(Object(s.__)("Number of sessions users had on your website over last %s","google-site-kit"),r)},{title:Object(s.__)("Percentage","google-site-kit"),tooltip:Object(s.__)("Percentage of sessions","google-site-kit")}],l=n[0].data.totals[0].values[1],u=Object(c.map)(n[0].data.rows,(function(t,n){var a=t.metrics[0].values[1]/l*100;return[t.dimensions[0],Object(d.q)(t.metrics[0].values[0]),Object(d.q)(t.metrics[0].values[1]),Object(d.q)(t.metrics[0].values[2]),e.createElement(o.b,{key:"minichart-analytics-top-as-"+n},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(a.toFixed(2),"%")," ",e.createElement(y.a,{percent:a.toFixed(1),index:n})))]})),f=Object(h.b)(u,i,{hideHeader:!1,chartsEnabled:!1});return e.createElement("div",{className:"googlesitekit-details-widget"},e.createElement(h.a,null,f))}),[{type:p.b,identifier:"analytics",datapoint:"report",data:k(k({},b.s),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(d.n)("day"),context:["Single","Dashboard"]}],e.createElement(m.a,{rows:4,rowHeight:50}),{},b.h)}).call(this,n(12),n(15))},129:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(75),h=n(180);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var y=function(t){s()(MiniChart,t);var n=m(MiniChart);function MiniChart(){return r()(this,MiniChart),n.apply(this,arguments)}return o()(MiniChart,[{key:"render",value:function(){var t=this.props,n=t.index,a=t.percent,r={backgroundColor:"transparent",chartArea:{width:"100%",height:"100%"},enableInteractivity:!1,height:28,legend:{position:"none"},slices:{0:{color:h.a[n]},1:{color:"#e6e6e6"}},title:null,tooltip:{trigger:"none"},width:28},i=[["source","percent"],["",+a],["",100-a]];return e.createElement("div",{className:"googlesitekit-mini-chart"},e.createElement(p.a,{data:i,options:r,chartType:"pie",loadSmall:!0,loadCompressed:!0,loadHeight:24,loadText:!1,id:"minichart"+n}))}}]),MiniChart}(f.a);t.a=y}).call(this,n(12))},130:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(13),m=n(0),y=n(5),b=n(25),v=n(17),_=n(39),k=n(51);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var D=function(t){l()(SearchConsoleDashboardWidgetKeywordTable,t);var n=O(SearchConsoleDashboardWidgetKeywordTable);function SearchConsoleDashboardWidgetKeywordTable(){return i()(this,SearchConsoleDashboardWidgetKeywordTable),n.apply(this,arguments)}return c()(SearchConsoleDashboardWidgetKeywordTable,[{key:"render",value:function(){var t=this.props.data,n=[{title:Object(m.__)("Keyword","google-site-kit"),tooltip:Object(m.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(m.__)("Clicks","google-site-kit"),tooltip:Object(m.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(m.__)("Impressions","google-site-kit"),tooltip:Object(m.__)("Counted each time your content appears in search results","google-site-kit")}],a=Object(y.j)()["search-console"].settings.propertyID,r=[],i=Object(h.map)(t,(function(e,t){var n=e.keys[0];return r[t]=Object(m.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%1$s&query=!%2$s&num_of_days=28",a,n),[n,Object(y.q)(e.clicks),Object(y.q)(e.impressions)]})),o={hideHeader:!1,chartsEnabled:!1,links:r},c=Object(_.b)(i,n,o);return e.createElement(_.a,null,c)}}]),SearchConsoleDashboardWidgetKeywordTable}(p.a);t.a=Object(b.a)(D,[{type:v.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"query",limit:10},priority:1,maxAge:Object(y.n)("day"),context:["Single","Dashboard"]}],e.createElement(k.a,{padding:!0}),{createGrid:!0},(function(e){return!e.length}))}).call(this,n(12),n(15))},131:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(DashboardSearchFunnelInner,e);var t=p(DashboardSearchFunnelInner);function DashboardSearchFunnelInner(){return r()(this,DashboardSearchFunnelInner),t.apply(this,arguments)}return o()(DashboardSearchFunnelInner,[{key:"render",value:function(){return null}}]),DashboardSearchFunnelInner}(n(1).a);t.a=Object(f.a)("googlesitekit.DashboardSearchFunnel")(h)},132:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var a=n(105);function r(e){if(Object(a.b)(e))return e.match(/pub-\d+$/)[0]}},135:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(34);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(r.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(r.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(a.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,n(12))},136:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return Root}));n(1);var a=n(2),r=n.n(a),i=n(11),o=n.n(i),c=n(137),s=n(138),l=n(139),u=n(140);function Root(t){var n=t.children,a=t.registry,r=t.dataAPIContext,i=t.dataAPIModuleArgs;return e.createElement(o.a.RegistryProvider,{value:a},e.createElement(c.a,null,e.createElement(l.a,null,n,r&&e.createElement(u.a,{context:r,args:i})),e.createElement(s.a,null)))}Root.propTypes={children:r.a.node.isRequired,registry:r.a.object,dataAPIContext:r.a.string,dataAPIModuleArgs:r.a.object},Root.defaultProps={registry:o.a}}).call(this,n(12))},137:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(2),m=n.n(h),y=n(0),b=n(37);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var _=function(t){l()(ErrorHandler,t);var n=v(ErrorHandler);function ErrorHandler(e){var t;return i()(this,ErrorHandler),(t=n.call(this,e)).state={error:null,info:null},t}return c()(ErrorHandler,[{key:"componentDidCatch",value:function(t,n){e.console.error("Caught an error:",t,n),this.setState({error:t,info:n})}},{key:"render",value:function(){var e=this.props.children,t=this.state,n=t.error,r=t.info;return n?a.createElement(b.a,{id:"googlesitekit-error",title:Object(y.__)("Site Kit encountered an error","google-site-kit"),description:a.createElement("code",null,n.message),isDismissable:!1,format:"small",type:"win-error"},a.createElement("pre",null,r.componentStack)):e}}]),ErrorHandler}(p.a);_.defaultProps={},_.propTypes={children:m.a.node.isRequired},t.a=_}).call(this,n(15),n(12))},138:function(e,t,n){"use strict";(function(e,a){var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(1),l=n(0),u=n(11),d=n.n(u),g=n(94),f=n(109),p=n(114),h=n(85),m=d.a.useSelect,y=d.a.useDispatch,b=d.a.useRegistry;t.a=function PermissionsModal(){var t,n,r,o=b(),u=m((function(e){return e(g.a).getPermissionScopeError()})),d=m((function(t){var n;return t(g.a).getConnectURL({additionalScopes:null==u||null===(n=u.data)||void 0===n?void 0:n.scopes,redirectURL:e.location.href})})),v=y(g.a).clearPermissionScopeError,_=Object(s.l)((function(){v()}),[v]),k=Object(s.l)(c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(h.c)(o);case 2:e.location.assign(d);case 3:case"end":return t.stop()}}),t)}))),[o,d]);return Object(s.n)((function(){(function(){var e=c()(i.a.mark((function e(){var t,n,a;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(null==u||null===(t=u.data)||void 0===t?void 0:t.skipModal)||!(null==u||null===(n=u.data)||void 0===n||null===(a=n.scopes)||void 0===a?void 0:a.length)){e.next=3;break}return e.next=3,k();case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[k,u]),u?(null==u||null===(t=u.data)||void 0===t||null===(n=t.scopes)||void 0===n?void 0:n.length)?(null==u||null===(r=u.data)||void 0===r?void 0:r.skipModal)?null:a.createElement(p.a,null,a.createElement(f.a,{title:Object(l.__)("Additional Permissions Required","google-site-kit"),subtitle:u.message,confirmButton:Object(l.__)("Proceed","google-site-kit"),dialogActive:!0,handleConfirm:k,handleDialog:_})):(e.console.warn("permissionsError lacks scopes array to use for redirect, so not showing the PermissionsModal. permissionsError was:",u),null):null}}).call(this,n(15),n(12))},139:function(e,t,n){"use strict";var a=n(4),r=n.n(a),i=n(14),o=n.n(i),c=n(38),s=n.n(c),l=n(1),u=n(11),d=n.n(u),g=n(85),f=d.a.useRegistry;t.a=function RestoreSnapshots(e){var t=e.children,n=f(),a=Object(l.s)(!1),i=s()(a,2),c=i[0],u=i[1];return Object(l.n)((function(){c||o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(g.b)(n);case 2:u(!0);case 3:case"end":return e.stop()}}),e)})))()}),[n,c]),c?t:null}},140:function(e,t,n){"use strict";n.d(t,"a",(function(){return CollectModuleData}));var a=n(1),r=n(16),i=(n(17),n(11)),o=n.n(i),c=n(20),s=o.a.useSelect;function CollectModuleData(e){var t=e.context,n=e.args,i=s((function(e){return e(c.c).getDateRange()}));return Object(a.n)((function(){return function(){return Object(r.d)("googlesitekit.moduleDataReset")}}),[i]),Object(a.n)((function(){Object(r.d)("googlesitekit.moduleLoaded",t,n)}),[t,n,i]),null}},145:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(11),i=n.n(r),o=n(43),c=n(59),s=n(20),l=i.a.useSelect,u=i.a.useDispatch;t.a=function DateRangeSelector(){var t=Object.values(Object(c.a)()),n=l((function(e){return e(s.c).getDateRange()})),r=u(s.c).setDateRange,i=Object(a.l)((function(e,t){r(t.dataset.value)}),[t]);return e.createElement(o.j,{enhanced:!0,className:"mdc-select--minimal",name:"time_period",label:"",onEnhancedChange:i,value:n},t.map((function(t){var n=t.slug,a=t.label;return e.createElement(o.i,{key:n,value:n},a)})))}}).call(this,n(12))},150:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(28);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(LayoutHeader,t);var n=v(LayoutHeader);function LayoutHeader(){return r()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.ctaLabel,r=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":r,"mdc-layout-grid__cell--span-12-desktop":!r,"mdc-layout-grid__cell--span-8-tablet":!r})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),r&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(b.a,{href:r,external:!0,inherit:!0},a)))))}}]),LayoutHeader}(f.a);_.propTypes={title:h.a.string,ctaLabel:h.a.string,ctaLink:h.a.string},_.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=_}).call(this,n(12))},151:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(80);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return r()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,a=t.ctaLink,r=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a&&n&&e.createElement(m.a,{className:"googlesitekit-data-block__source",name:n,href:a,external:!0}),r))))}}]),LayoutFooter}(f.a);b.propTypes={ctaLabel:h.a.string,ctaLink:h.a.string},t.a=b}).call(this,n(12))},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return o})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return s})),n.d(t,"e",(function(){return l})),n.d(t,"d",(function(){return f})),n.d(t,"c",(function(){return p}));var a=n(92);void 0===e.googlesitekit&&(e.googlesitekit={});var r=e.googlesitekit._hooks||a,i=r.addAction,o=r.addFilter,c=r.removeAction,s=r.removeFilter,l=r.hasAction,u=r.hasFilter,d=r.removeAllActions,g=r.removeAllFilters,f=r.doAction,p=r.applyFilters,h=r.currentAction,m=r.currentFilter,y=r.doingAction,b=r.doingFilter,v=r.didAction,_=r.didFilter,k=r.actions,O=r.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:i,addFilter:o,removeAction:c,removeFilter:s,hasAction:l,hasFilter:u,removeAllActions:d,removeAllFilters:g,doAction:f,applyFilters:p,currentAction:h,currentFilter:m,doingAction:y,doingFilter:b,didAction:v,didFilter:_,actions:k,filters:O})}).call(this,n(15))},165:function(e,t,n){"use strict";(function(e,a){var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(22),f=n.n(g),p=n(8),h=n.n(p),m=n(9),y=n.n(m),b=n(3),v=n.n(b),_=n(1),k=n(0),O=n(5),D=n(109),E=n(47),S=n(166),j=n(114);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var R=function(t){h()(UserMenu,t);var n,r=w(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=r.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(f()(t)),t.handleMenuClose=t.handleMenuClose.bind(f()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(f()(t)),t.handleDialog=t.handleDialog.bind(f()(t)),t.handleDialogClose=t.handleDialogClose.bind(f()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(f()(t)),t.menuButtonRef=Object(_.h)(),t.menuRef=Object(_.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var a=e._googlesitekitLegacyData.admin.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:e.location.assign(a);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(O.d)(),document.location=Object(O.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData.admin,n=t.userData,r=n.email,i=void 0===r?"":r,o=n.picture,c=void 0===o?"":o,s=t.proxyPermissionsURL,l=this.state,u=l.dialogActive,d=l.menuOpen;return a.createElement(_.b,null,a.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},a.createElement(E.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:c?a.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},a.createElement("img",{className:"mdc-button__icon--image",src:c,alt:Object(k.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},i),a.createElement(S.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(k.__)("Disconnect","google-site-kit")].concat(s?[Object(k.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),a.createElement(j.a,null,a.createElement(D.a,{dialogActive:u,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(k.__)("Disconnect","google-site-kit"),subtitle:Object(k.__)("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:Object(k.__)("Disconnect","google-site-kit"),provides:[],danger:!0})))}}]),UserMenu}(_.a);t.a=R}).call(this,n(15),n(12))},166:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(Menu,t);var n=y(Menu);function Menu(e){var t;return r()(this,Menu),(t=n.call(this,e)).menuRef=Object(f.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new m.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,a=t.menuItems,r=t.onSelected,i=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:i,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},a.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:r.bind(null,n),onKeyDown:r.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(f.a);b.propTypes={menuOpen:h.a.bool.isRequired,menuItems:h.a.array.isRequired,id:h.a.string.isRequired},t.a=b}).call(this,n(12))},167:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(ErrorNotification,e);var t=p(ErrorNotification);function ErrorNotification(){return r()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(f.a)("googlesitekit.ErrorNotification")(h)},168:function(e,t,n){"use strict";(function(e){var a=n(4),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(22),g=n.n(d),f=n(8),p=n.n(f),h=n(9),m=n.n(h),y=n(3),b=n.n(y),v=n(1),_=n(18),k=n.n(_),O=n(83),D=n(0),E=n(169),S=n(171),j=n(111),w=n(172),R=n(73),A=n(74),C=n(49),N=n(127),P=n(61),x=n(91),T=n(5),L=n(89),I=n(90),W=n(86),M=n(27);function U(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return m()(this,n)}}var q=Object(O.a)("googlesitekit.AdSenseDashboardZeroData")((function(){return null})),F=function(t){p()(AdSenseDashboardWidget,t);var n,a=U(AdSenseDashboardWidget);function AdSenseDashboardWidget(e){var t;return s()(this,AdSenseDashboardWidget),(t=a.call(this,e)).state={receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0,zeroData:!1},t.handleDataError=t.handleDataError.bind(g()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(g()(t)),t.handleZeroData=t.handleZeroData.bind(g()(t)),t}return u()(AdSenseDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:(n=o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(P.a)();case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,error:e,errorObj:t,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleZeroData",value:function(){this.setState({zeroData:!0,loading:!1})}},{key:"render",value:function(){var t=this,n=Object(T.j)(),a=this.state,r=a.receivingData,i=a.error,o=a.errorObj,c=a.loading,s=a.isAdSenseConnected,l=a.zeroData,u=n.adsense.homepage,d=c||!r||l?"googlesitekit-nodata":"";return e.createElement(v.b,null,e.createElement(I.a,null),e.createElement("div",{className:d},e.createElement(j.a,{module:"adsense"})),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--adsense"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},!i&&n.adsense.setupComplete?e.createElement(W.a,{title:Object(D._x)("AdSense","Service name","google-site-kit"),icon:!0,iconWidth:"30",iconHeight:"26",iconID:"adsense",status:"connected",statusText:Object(D.__)("AdSense is connected","google-site-kit")}):e.createElement(W.a,{title:Object(D._x)("AdSense","Service name","google-site-kit"),icon:!0,iconWidth:"30",iconHeight:"26",iconID:"adsense",status:"not-connected",statusText:Object(D.__)("AdSense is not connected","google-site-kit")}),c&&e.createElement(C.a,null)),l&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(M.a,{fill:!0},e.createElement(q,null))),!r&&(i?Object(A.a)(Object(D._x)("AdSense","Service name","google-site-kit"),i,!0,!0,!0,o):Object(R.a)(Object(D._x)("AdSense","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(x.a,{slug:"adsense",context:"module-dashboard"}),e.createElement(M.a,{header:!0,title:Object(D.__)("Estimated earnings","google-site-kit"),headerCtaLabel:Object(D.__)("Advanced Settings","google-site-kit"),headerCtaLink:u},e.createElement(E.a,{handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(M.a,{header:!0,title:Object(D.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(D.__)("Advanced Settings","google-site-kit"),headerCtaLink:u},e.createElement(S.a,{handleDataError:function(e){e||t.handleZeroData()}}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",d)},e.createElement(w.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(L.a,null))))),!s&&e.createElement(N.a,null))}}]),AdSenseDashboardWidget}(v.a);t.a=F}).call(this,n(12))},169:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(5),m=n(31),y=n(30),b=n(25),v=n(17),_=n(61);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var O=function(t){s()(AdSenseEstimateEarningsWidget,t);var n=k(AdSenseEstimateEarningsWidget);function AdSenseEstimateEarningsWidget(e){var t;return r()(this,AdSenseEstimateEarningsWidget),(t=n.call(this,e)).state={refetch:!1,today:!1,yesterday:!1,sevenDays:!1,month:!1,twentyEightDays:!1,sameDayLastWeek:!1,prev7Days:!1,monthLastYear:!1,prev28Days:!1,error:!1,message:""},t}return o()(AdSenseEstimateEarningsWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var e=this.state,t=e.today,n=e.yesterday,a=e.sevenDays,r=e.month,i=e.twentyEightDays,o=e.sameDayLastWeek,c=e.prev7Days,s=e.monthLastYear,l=e.prev28Days;if(!(t&&n&&a&&r&&i&&o&&c&&s&&l))return null;var u=t.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),d=!!u&&u.currency,g=t.totals?[{className:"googlesitekit-data-block--today",title:Object(p.__)("Today so far","google-site-kit"),datapoint:Object(h.s)(t.totals[0],d)},{className:"googlesitekit-data-block--yesterday",title:Object(p.__)("Yesterday","google-site-kit"),datapoint:Object(h.s)(n.totals[0],d),change:o.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--7days",title:Object(p.__)("Last 7 days","google-site-kit"),datapoint:Object(h.s)(a.totals[0],d),change:c.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--month",title:Object(p.__)("This month","google-site-kit"),datapoint:Object(h.s)(r.totals[0],d),change:s.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--28days",title:Object(p.__)("Last 28 days","google-site-kit"),datapoint:Object(h.s)(i.totals[0],d),change:l.totals[0],changeDataUnit:"%"}]:[];return AdSenseEstimateEarningsWidget.renderLayout(g)}}],[{key:"renderLayout",value:function(t){return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(m.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))}))))}},{key:"renderPreviews",value:function(){for(var t=[],n=0;5>n;n++)t.push(e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(y.a,{width:"100%",height:"104px"})));return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t))}}]),AdSenseEstimateEarningsWidget}(f.a);t.a=Object(b.a)(O,[{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.today)return{today:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"yesterday"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.yesterday)return{yesterday:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"same-day-last-week"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.sameDayLastWeek)return{sameDayLastWeek:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-7-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.sevenDays)return{sevenDays:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-7-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev7Days)return{prev7Days:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.month)return{month:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month-last-year"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.monthLastYear)return{monthLastYear:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.twentyEightDays)return{twentyEightDays:n}}},{type:v.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev28Days)return{prev28Days:n}}}],O.renderPreviews(),{createGrid:!0},_.b)}).call(this,n(12))},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return b.a})),n.d(t,"b",(function(){return b.b}));var a=n(10),r=n.n(a),i=n(13),o=n(63),c=n(45),s=n(16),l=n(59),u=n(23),d=n(55),g=n(69),f=n.n(g);function p(e){return f()(e)&&e.hasOwnProperty("code")&&("string"==typeof e.code||"number"==typeof e.code)&&e.hasOwnProperty("message")&&"string"==typeof e.message&&e.hasOwnProperty("data")}var h=n(95),m=n(125),y=n(29),b=n(70),v=n(97);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){r()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var O=function(e,t){var n=k({data:{}},e);return n.data=k({dateRange:t},n.data),n},D={maxRequests:10,combinedGetFromCache:function(e){var t=this;return new Promise((function(n,a){try{var r=[],o=Object(l.c)();Object(i.each)(e,(function(e){var n=O(e,o);n.key=Object(y.c)(n.type,n.identifier,n.datapoint,n.data);var a=Object(y.b)(n.key,n.maxAge);void 0!==a&&(r[n.key]=a,t.resolve(n,a))})),n(r)}catch(e){a()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],a=[],r=25,u=Object(l.c)();Object(i.each)(e,(function(e){var n=O(e,u);n.key=Object(y.c)(n.type,n.identifier,n.datapoint,n.data);var i=Object(y.b)(n.key,n.maxAge);void 0!==i?(setTimeout((function(){t.resolve(n,i)}),r),r+=25):a.push(n)})),a=Object(i.sortBy)(a,"priority");var g=[],f=[],h={},m=!!a.find((function(e){return e.priority<10}));Object(i.each)(a,(function(e,t){!n&&10<=e.priority&&m?f.push(e):h[e.key]?h[e.key].push(t):(h[e.key]=[t],g.push(e))}));var b=10,v=g.slice(0,b),_=g.slice(b);if(_=_.concat(f),0!==v.length||0!==_.length){0<_.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(_,!0)}),50):this.maxRequests=10;var k=null!==Object(d.c)("datacache");return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/data/",{datacache:k||void 0}),data:{request:v},method:"POST"}).then((function(e){Object(i.each)(e,(function(e,n){if(h[n]){var r=p(e);r&&t.handleWPError(e),Object(i.each)(h[n],(function(n){var i=a[n];r||Object(y.e)(i.key,e),t.resolve(i,e)})),0===_.length&&Object(s.d)("googlesitekit.dataLoaded","api")}else console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(s.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){console.warn("WP Error in data response",e);var t=e.data;if(t&&t.reason){var n=0;["authError","insufficientPermissions"].includes(t.reason)&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.b)(h.a),1),n++),"forbidden"===t.reason&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.b)(m.a),1),n++),n&&Object(s.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(s.g)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+n}))}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},invalidateCacheGroup:v.a,collectModuleData:function(e,t){var n=Object(s.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var a=this,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=Object(y.c)(e,t,n,r);if(!i){var l=Object(y.b)(s,3600);if(void 0!==l)return new Promise((function(e){e(l)}))}return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),r)}).then((function(e){return i||Object(y.e)(s,e),Promise.resolve(e)})).catch((function(e){return a.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,a){var r={};return r.data=a,Object(o.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:r,method:"POST"}).then((function(a){return D.invalidateCacheGroup(e,t,n),new Promise((function(e){e(a)}))}))},setModuleActive:function(e,t){return this.set(b.a,"modules","activation",{slug:e,active:t})}};Object(s.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData")||Object(s.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData",D.collectModuleData.bind(D));t.c=D},170:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(0),m=n(37);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var b=function(t){l()(InvalidCredentialsWarning,t);var n=y(InvalidCredentialsWarning);function InvalidCredentialsWarning(){return i()(this,InvalidCredentialsWarning),n.apply(this,arguments)}return c()(InvalidCredentialsWarning,[{key:"render",value:function(){return e.createElement(m.a,{id:"notification-id",title:Object(h.__)("Security Token Error","google-site-kit"),description:Object(h.__)("We’re unable to retrieve your data because your security token is expired or revoked. Please ","google-site-kit"),learnMoreURL:a._googlesitekitLegacyData.admin.connectURL,learnMoreLabel:Object(h.__)("reauthenticate your account","google-site-kit"),format:"small",type:"win-error"})}}]),InvalidCredentialsWarning}(p.a);t.a=b}).call(this,n(12),n(15))},171:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(13),m=n(5),y=n(17),b=n(31),v=n(30),_=n(61),k=n(25);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var D=function(t){s()(AdSensePerformanceWidget,t);var n=O(AdSensePerformanceWidget);function AdSensePerformanceWidget(e){var t;return r()(this,AdSensePerformanceWidget),(t=n.call(this,e)).state={twentyEightDays:!1,prev28Days:!1},t}return o()(AdSensePerformanceWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.twentyEightDays,a=t.prev28Days,r=n.totals?[{className:"googlesitekit-data-block--page-rpm",title:Object(p.__)("Page RPM","google-site-kit"),datapoint:Object(m.s)(n.totals[1]),change:Object(h.isUndefined)(a.totals)?0:a.totals[1],changeDataUnit:"%"},{className:"googlesitekit-data-block--impression",title:Object(p.__)("Impressions","google-site-kit"),datapoint:Object(m.s)(n.totals[2]),change:Object(h.isUndefined)(a.totals)?0:a.totals[2],changeDataUnit:"%"}]:[];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},r.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-top mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement(b.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))}))))}}]),AdSensePerformanceWidget}(f.a);t.a=Object(k.a)(D,[{type:y.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.twentyEightDays)return{twentyEightDays:n}}},{type:y.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(m.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.prev28Days)return{prev28Days:n}}}],e.createElement(v.a,{width:"100%",height:"250px"}),{createGrid:!0},_.b)}).call(this,n(12))},172:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(DashboardAdSenseTopPages,e);var t=p(DashboardAdSenseTopPages);function DashboardAdSenseTopPages(){return r()(this,DashboardAdSenseTopPages),t.apply(this,arguments)}return o()(DashboardAdSenseTopPages,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopPages}(n(1).a);t.a=Object(f.a)("googlesitekit.AnalyticsAdSenseTopPagesTable")(h)},173:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(57),m=n(174),y=n(175),b=n(91);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(DashboardEarnings,t);var n=v(DashboardEarnings);function DashboardEarnings(){return r()(this,DashboardEarnings),n.apply(this,arguments)}return o()(DashboardEarnings,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{title:Object(p.__)("Earnings","google-site-kit"),description:Object(p.__)("How much you’re earning from your content through AdSense.","google-site-kit")}),e.createElement(b.a,{slug:"adsense",context:"module-sitekit-dashboard"})),e.createElement(y.a,null),e.createElement(m.a,null))}}]),DashboardEarnings}(f.a);t.a=_}).call(this,n(12))},174:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(DashboardAdSenseTopEarningPagesSmall,e);var t=p(DashboardAdSenseTopEarningPagesSmall);function DashboardAdSenseTopEarningPagesSmall(){return r()(this,DashboardAdSenseTopEarningPagesSmall),t.apply(this,arguments)}return o()(DashboardAdSenseTopEarningPagesSmall,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopEarningPagesSmall}(n(1).a);t.a=Object(f.a)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall")(h)},175:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(61),m=n(27),y=n(25),b=n(17),v=n(30),_=n(5),k=n(31),O=n(64);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(AdSenseDashboardMainSummary,t);var n=D(AdSenseDashboardMainSummary);function AdSenseDashboardMainSummary(e){var t;return r()(this,AdSenseDashboardMainSummary),(t=n.call(this,e)).state={today:!1,period:!1,daily:!1},t}return o()(AdSenseDashboardMainSummary,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.today,a=t.period,r=t.daily;if(!(n&&a&&r&&a.totals))return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(m.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(v.a,{width:"100%",height:"276px",padding:!0})));var i=Object(h.e)(r.rows),o=Object(_.m)("googlesitekit-module-adsense",{}),c=a.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),s=!!c&&c.currency;return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(m.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-rpm",title:Object(p.__)("RPM","google-site-kit"),datapoint:Object(_.s)(a.totals[1],s),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,2),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-earnings",title:Object(p.__)("Total Earnings","google-site-kit"),datapoint:Object(_.s)(a.totals[0],s),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},change:n.totals[0],changeDataUnit:"$",sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,1),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(k.a,{className:"overview-adsense-impressions",title:Object(p.__)("Ad Impressions","google-site-kit"),datapoint:Object(_.s)(a.totals[2]),source:{name:Object(p._x)("AdSense","Service name","google-site-kit"),link:o},sparkline:r&&e.createElement(O.a,{data:Object(_.f)(i.dataMap,3),change:1,loadSmall:!1}),context:"compact"})))))))}}]),AdSenseDashboardMainSummary}(f.a);t.a=Object(y.a)(E,[{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.today)return{today:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.period)return{period:n}}},{type:b.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month",dimensions:["DATE"]},priority:1,maxAge:Object(_.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.daily)return{daily:n}}}],e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(m.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(v.a,{width:"100%",height:"276px",padding:!0}))),{inGrid:!0,createGrid:!0},h.b)}).call(this,n(12))},176:function(e,t,n){"use strict";(function(e){var a=n(4),r=n.n(a),i=n(14),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(22),g=n.n(d),f=n(8),p=n.n(f),h=n(9),m=n.n(h),y=n(3),b=n.n(y),v=n(1),_=n(18),k=n.n(_),O=n(0),D=n(11),E=n.n(D),S=n(90),j=n(177),w=n(178),R=n(179),A=n(128),C=n(27),N=n(86),P=n(112),x=n(111),T=n(49),L=n(73),I=n(74),W=n(127),M=n(61),U=n(59),q=n(89),F=n(20);function H(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return m()(this,n)}}var G=E.a.withSelect,B=function(t){p()(AnalyticsDashboardWidget,t);var n,a=H(AnalyticsDashboardWidget);function AnalyticsDashboardWidget(e){var t;return s()(this,AnalyticsDashboardWidget),(t=a.call(this,e)).state={selectedStats:[0],receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0},t.handleStatSelection=t.handleStatSelection.bind(g()(t)),t.buildSeries=t.buildSeries.bind(g()(t)),t.handleDataError=t.handleDataError.bind(g()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(g()(t)),t}return u()(AnalyticsDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:(n=o()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(M.a)();case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleStatSelection",value:function(e){this.setState({selectedStats:[e]})}},{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,loading:!1,error:e,errorObj:t})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"buildSeries",value:function(){var e=this.state.selectedStats,t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"};return{0:{color:t[e],targetAxisIndex:0},1:{color:t[e],targetAxisIndex:0,lineDashStyle:[3,3],lineWidth:1}}}},{key:"render",value:function(){var t=this.state,n=t.selectedStats,a=t.error,r=t.errorObj,i=t.receivingData,o=t.loading,c=t.isAdSenseConnected,s=this.props.dateRange,l=this.buildSeries(),u=!o&&i?"":"googlesitekit-nodata",d=Object(U.b)(s);return e.createElement(v.b,null,e.createElement(S.a,null),e.createElement(x.a,{module:"analytics"}),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--analytics"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(N.a,{title:Object(O._x)("Analytics","Service name","google-site-kit"),icon:!0,iconWidth:"24",iconHeight:"26",iconID:"analytics",status:"connected",statusText:Object(O.__)("Analytics is connected","google-site-kit")}),o&&e.createElement(T.a,null)),!i&&(a?Object(I.a)(Object(O._x)("Analytics","Service name","google-site-kit"),a,!0,!0,!0,r):Object(L.a)(Object(O._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0
8
- /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Audience overview for the last %s","google-site-kit"),d),headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),headerCtaLink:"http://analytics.google.com"},e.createElement(R.a,{selectedStats:n,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),e.createElement(j.a,{selectedStats:n,series:l,vAxes:null,dateRangeSlug:s}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0,footer:!0
9
- /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Top content over the last %s","google-site-kit"),d),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement(w.a,null))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(C.a,{header:!0,footer:!0
10
- /* translators: %s: date range */,title:Object(O.sprintf)(Object(O.__)("Top acquisition channels over the last %s","google-site-kit"),d),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(O.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(P.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(A.a,null)))))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(q.a,null))))),!o&&!c&&e.createElement(W.a,null))}}]),AnalyticsDashboardWidget}(v.a);t.a=G((function(e){return{dateRange:e(F.c).getDateRange()}}))(B)}).call(this,n(12))},177:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(22),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(0),b=n(5),v=n(75),_=n(25),k=n(17),O=n(21),D=n(30);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var S=function(t){d()(AnalyticsDashboardWidgetSiteStats,t);var n=E(AnalyticsDashboardWidgetSiteStats);function AnalyticsDashboardWidgetSiteStats(e){var t;return i()(this,AnalyticsDashboardWidgetSiteStats),(t=n.call(this,e)).setOptions=t.setOptions.bind(l()(t)),t}return c()(AnalyticsDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,n=t.series,a=t.vAxes,r={chart:{title:""===e._googlesitekitLegacyData.pageTitle?"":Object(y.__)("Users Traffic Summary","google-site-kit")},curveType:"line",height:270,width:"100%",chartArea:{height:"80%",width:"87%"},legend:{position:"top",textStyle:{color:"#616161",fontSize:12}},hAxis:{format:"M/d/yy",gridlines:{color:"#fff"},textStyle:{color:"#616161",fontSize:12}},vAxis:{gridlines:{color:"#eee"},minorGridlines:{color:"#eee"},textStyle:{color:"#616161",fontSize:12},titleTextStyle:{color:"#616161",fontSize:12,italic:!1}}};return r.series=n,r.vAxes=a,r}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.selectedStats,r=e.dateRangeSlug;if(!t||!t.length)return null;var i=r?r.match(/\d+/).map(Number)[0]:28,o=Object(O.c)(t,n,i);if(!o)return null;var c=this.setOptions();return a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement(v.a,{selectedStats:n,data:o,options:c}))))}}]),AnalyticsDashboardWidgetSiteStats}(m.a);t.a=Object(_.a)(S,[{type:k.b,identifier:"analytics",datapoint:"report",data:O.r,priority:1,maxAge:Object(b.n)("day"),context:"Single"}],a.createElement(D.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,n(15),n(12))},178:function(e,t,n){"use strict";(function(e){var a=n(38),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(18),y=n.n(m),b=n(13),v=n(2),_=n.n(v),k=n(0),O=n(5),D=n(25),E=n(17),S=n(39),j=n(51),w=n(21);function R(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var A=function(t){u()(AnalyticsDashboardWidgetTopPagesTable,t);var n=R(AnalyticsDashboardWidgetTopPagesTable);function AnalyticsDashboardWidgetTopPagesTable(){return o()(this,AnalyticsDashboardWidgetTopPagesTable),n.apply(this,arguments)}return s()(AnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.colspan;if(!n||!n.length)return null;var i=[{title:Object(k.__)("Title","google-site-kit"),tooltip:Object(k.__)("Page Title","google-site-kit"),primary:!0},{title:Object(k.__)("Pageviews","google-site-kit"),tooltip:Object(k.__)("Pageviews","google-site-kit")},{title:Object(k.__)("Unique Pageviews","google-site-kit"),tooltip:Object(k.__)("Unique Pageviews","google-site-kit")},{title:Object(k.__)("Bounce Rate","google-site-kit"),tooltip:Object(k.__)("Bounce Rate","google-site-kit")}],o=[],c=Object(b.map)(n[0].data.rows,(function(t,n){var a=Number(t.metrics[0].values[2]),i=r()(t.dimensions,2),c=i[0],s=i[1];return o[n]=AnalyticsDashboardWidgetTopPagesTable.addDeepLink(s),[c,Object(O.q)(t.metrics[0].values[0]),Object(O.q)(t.metrics[0].values[1]),e.createElement(h.b,{key:"minichart-"+n},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(a.toFixed(2),"%")))]})),s={hideHeader:!1,chartsEnabled:!1,links:o,hideColumns:{mobile:[2,3]}},l=Object(S.b)(c,i,s);return e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(a))},e.createElement(S.a,null,l))}}],[{key:"addDeepLink",value:function(e){var t=Object(O.j)().analytics.settings,n=t.accountID,a=t.internalWebPropertyID,r=t.profileID;return n?"https://analytics.google.com/analytics/web/#/report/content-drilldown/a".concat(n,"w").concat(a,"p").concat(r,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:").concat(encodeURIComponent(e.replace(/\//g,"~2F"))):"https://analytics.google.com/analytics/web/"}}]),AnalyticsDashboardWidgetTopPagesTable}(h.a);A.propTypes={data:_.a.array,colspan:_.a.number},A.defaultProps={data:null,colspan:12},t.a=Object(D.a)(A,[{type:E.b,identifier:"analytics",datapoint:"report",data:Object(w.g)(),priority:1,maxAge:Object(O.n)("day"),context:["Single","Dashboard"]}],e.createElement(j.a,{padding:!0}),{createGrid:!0})}).call(this,n(12))},179:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(13),y=n(0),b=n(5),v=n(31),_=n(25),k=n(17),O=n(21),D=n(30);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(AnalyticsDashboardWidgetOverview,t);var n=E(AnalyticsDashboardWidgetOverview);function AnalyticsDashboardWidgetOverview(e){var t;return r()(this,AnalyticsDashboardWidgetOverview),(t=n.call(this,e)).state={report:!1,directTotalUsers:!1},t}return o()(AnalyticsDashboardWidgetOverview,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props.requestDataToState;this.setState(e)}},{key:"render",value:function(){var t=this.props,n=t.selectedStats,a=t.handleStatSelection,r=this.state,i=r.report,o=r.directTotalUsers;if(!i||!i.length||!o)return null;var c=Object(O.b)(i);if(!c)return null;var s=c.totalSessions,l=c.averageBounceRate,u=c.averageSessionDuration,d=c.totalUsersChange,g=c.totalSessionsChange,f=c.averageBounceRateChange,p=c.averageSessionDurationChange,h=[{className:"googlesitekit-data-block--users googlesitekit-data-block--button-1",title:Object(y.__)("Users","google-site-kit"),datapoint:Object(b.s)(o),change:d,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:a},{className:"googlesitekit-data-block--sessions googlesitekit-data-block--button-2",title:Object(y.__)("Sessions","google-site-kit"),datapoint:Object(b.s)(s),change:g,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:a},{className:"googlesitekit-data-block--bounce googlesitekit-data-block--button-3",title:Object(y.__)("Bounce Rate","google-site-kit"),datapoint:Number(l).toFixed(2),change:f,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:a,datapointUnit:"%",invertChangeColor:!0},{className:"googlesitekit-data-block--duration googlesitekit-data-block--button-4",title:Object(y.__)("Session Duration","google-site-kit"),datapoint:Object(b.r)(u),change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:a}];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner",role:"toolbar","aria-label":"Line Chart Options"},h.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(v.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection,datapointUnit:t.datapointUnit,invertChangeColor:t.invertChangeColor}))}))))}}]),AnalyticsDashboardWidgetOverview}(f.a);S.propTypes={handleDataError:h.a.func.isRequired},t.a=Object(_.a)(S,[{type:k.b,identifier:"analytics",datapoint:"report",data:O.p,priority:1,maxAge:Object(b.n)("day"),context:["Single","Dashboard"],toState:function(e,t){var n=t.data;if(!e.report)return{report:n}}},{type:k.b,identifier:"analytics",datapoint:"report",data:O.t,priority:1,maxAge:Object(b.n)("day"),context:["Single"],toState:function(e,t){var n=t.data;if(!e.directTotalUsers)return{directTotalUsers:Object(m.get)(n,"[0].data.totals[0].values[0]")}}}],e.createElement(D.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},O.h,O.f)}).call(this,n(12))},180:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var a=["#178EC5","#54B23B","#EB5729","#ECED33","#34CBE3","#82E88E"]},181:function(e,t,n){"use strict";(function(e,a){var r=n(33),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(182),b=n(100),v=n(5);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var k=function(t){d()(AnalyticsAdminbarWidget,t);var n=_(AnalyticsAdminbarWidget);function AnalyticsAdminbarWidget(){return c()(this,AnalyticsAdminbarWidget),n.apply(this,arguments)}return l()(AnalyticsAdminbarWidget,[{key:"render",value:function(){return"undefined"!==i()(e._googlesitekitLegacyData.permaLink)&&""===e._googlesitekitLegacyData.permaLink?null:Object(v.j)().analytics.active?a.createElement(y.a,null):a.createElement(m.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(b.a,null)))}}]),AnalyticsAdminbarWidget}(m.a);t.a=k}).call(this,n(15),n(12))},182:function(e,t,n){"use strict";(function(e,a){var r=n(10),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(0),b=n(5),v=n(31),_=n(25),k=n(17),O=n(21),D=n(30);function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var w=function(t){d()(AnalyticsAdminbarWidgetOverview,t);var n=j(AnalyticsAdminbarWidgetOverview);function AnalyticsAdminbarWidgetOverview(){return c()(this,AnalyticsAdminbarWidgetOverview),n.apply(this,arguments)}return l()(AnalyticsAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error||!t.length)return null;var n=Object(O.b)(t);if(!n)return null;var a=n.totalUsers,r=n.totalSessions,i=n.totalUsersChange,o=n.totalSessionsChange;return e.createElement(m.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(v.a,{className:"overview-total-users",title:Object(y.__)("Total Users","google-site-kit"),datapoint:Object(b.s)(a),change:i,changeDataUnit:"%"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(v.a,{className:"overview-total-sessions",title:Object(y.__)("Total Sessions","google-site-kit"),datapoint:Object(b.s)(r),change:o,changeDataUnit:"%"})))}}]),AnalyticsAdminbarWidgetOverview}(m.a);t.a=Object(_.a)(w,[{type:k.b,identifier:"analytics",datapoint:"report",data:S(S({},O.p),{},{url:a._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(b.n)("day"),context:"Adminbar"}],e.createElement(m.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(D.a,{width:"auto",height:"59px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(D.a,{width:"auto",height:"59px"}))),{inGrid:!0},O.h,O.f)}).call(this,n(12),n(15))},183:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(22),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(18),y=n.n(m),b=n(0),v=n(27),_=n(57),k=n(73),O=n(74),D=n(126),E=n(112),S=n(184),j=n(5);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var R=function(t){u()(AnalyticsAllTraffic,t);var n=w(AnalyticsAllTraffic);function AnalyticsAllTraffic(e){var t;return r()(this,AnalyticsAllTraffic),(t=n.call(this,e)).state={receivingData:!0,error:!1},t.handleDataError=t.handleDataError.bind(s()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(s()(t)),t}return o()(AnalyticsAllTraffic,[{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,error:e,errorObj:t})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0})}},{key:"getErrorDataComponent",value:function(){var e=Object(j.j)().analytics,t=e.active,n=e.setupComplete,a=this.state,r=a.error,i=a.errorObj,o=a.receivingData;return t&&!n?Object(D.a)("analytics",!0,!0,!0):o?null:r?Object(O.a)(Object(b._x)("Analytics","Service name","google-site-kit"),r,!0,!0,!0,i):Object(k.a)(Object(b._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)}},{key:"render",value:function(){var t=this.state,n=t.error,a=t.receivingData,r=n||!a?"googlesitekit-nodata":"";return e.createElement(h.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{description:Object(b.__)("How people found your site.","google-site-kit"),title:Object(b.__)("All Traffic","google-site-kit")})),this.getErrorDataComponent(),e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",r)},e.createElement(v.a,{className:"googlesitekit-dashboard-all-traffic"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(E.a,{source:!0,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(S.a,null)))))))}}]),AnalyticsAllTraffic}(h.a);t.a=R}).call(this,n(12))},184:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(13),h=n(0),m=n(5),y=n(25),b=n(17),v=n(39),_=n(129),k=n(51),O=n(21);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,t);var n=D(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources);function AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources(){return r()(this,AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources),n.apply(this,arguments)}return o()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=[{title:Object(h.__)("Source","google-site-kit"),primary:!0},{title:Object(h.__)("Percent","google-site-kit")}],a=t[0].data.totals[0].values[1],r=Object(p.map)(t[0].data.rows,(function(t,n){var r=t.metrics[0].values[1]/a*100;return[t.dimensions[0],e.createElement(f.b,{key:"minichart-"+n},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(r.toFixed(2),"%")," ",e.createElement(_.a,{percent:r.toFixed(1),index:n})))]})),i=Object(v.b)(r,n,{hideHeader:!0,chartsEnabled:!0});return e.createElement("div",{className:"googlesitekit-alltraffic-widget"},e.createElement(v.a,null,i))}}]),AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources}(f.a);t.a=Object(y.a)(E,[{type:b.b,identifier:"analytics",datapoint:"report",data:O.s,priority:1,maxAge:Object(m.n)("day"),context:"Dashboard"}],e.createElement(k.a,{rows:3,rowHeight:50}))}).call(this,n(12))},185:function(e,t,n){"use strict";(function(e,a){var r=n(10),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(13),b=n(0),v=n(5),_=n(21),k=n(31),O=n(25),D=n(17),E=n(64),S=n(46),j=n(30);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var C=function(t){d()(AnalyticsDashboardWidgetTopLevel,t);var n=A(AnalyticsDashboardWidgetTopLevel);function AnalyticsDashboardWidgetTopLevel(e){var t;return c()(this,AnalyticsDashboardWidgetTopLevel),(t=n.call(this,e)).state={accounts:!1,goals:!1,directTotalUsers:!1},t}return l()(AnalyticsDashboardWidgetTopLevel,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,n=e.requestDataToState;t&&!t.error&&"function"==typeof n&&this.setState(n)}},{key:"render",value:function(){var t=this.state,n=t.overview,r=t.extractedAnalytics,i=t.goals,o=t.directTotalUsers,c=e._googlesitekitLegacyData.permaLink,s=Object(v.m)("googlesitekit-module-analytics",{}),l="",u="",d="",g="",f="";return n&&(l=n.totalUsersChange,u=n.goalCompletions,d=n.goalCompletionsChange,g=n.averageBounceRate,f=n.averageBounceRateChange),a.createElement(m.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(k.a,{className:"overview-total-users",title:Object(b.__)("Unique Visitors from Search","google-site-kit"),datapoint:Object(v.s)(o),change:l,changeDataUnit:"%",source:{name:Object(b._x)("Analytics","Service name","google-site-kit"),link:s},sparkline:r&&a.createElement(E.a,{data:Object(v.f)(r,1),change:l})})),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},c&&a.createElement(k.a,{className:"overview-bounce-rate",title:Object(b.__)("Bounce Rate","google-site-kit"),datapoint:Number(g).toFixed(2),datapointUnit:Object(b.__)("%","google-site-kit"),change:f,changeDataUnit:"%",invertChangeColor:!0,source:{name:Object(b._x)("Analytics","Service name","google-site-kit"),link:s},sparkline:r&&a.createElement(E.a,{data:Object(v.f)(r,2),change:f})}),!c&&i&&Object(y.isEmpty)(i.items)&&a.createElement(S.a,{title:Object(b.__)("Use goals to measure success.","google-site-kit"),description:Object(b.__)("Goals measure how well your site or app fulfills your target objectives.","google-site-kit"),ctaLink:"https://support.google.com/analytics/answer/1032415?hl=en#create_or_edit_goals",ctaLabel:Object(b.__)("Create a new goal","google-site-kit")}),!c&&i&&!Object(y.isEmpty)(i.items)&&a.createElement(k.a,{className:"overview-goals-completed",title:Object(b.__)("Goals Completed","google-site-kit"),datapoint:Object(v.s)(u),change:d,changeDataUnit:"%",source:{name:Object(b._x)("Analytics","Service name","google-site-kit"),link:s},sparkline:r&&a.createElement(E.a,{data:Object(v.f)(r,3),change:d})}),!c&&!i&&a.createElement(j.a,{width:"100%",height:"202px"})))}}]),AnalyticsDashboardWidgetTopLevel}(m.a);t.a=Object(O.a)(C,[{type:D.b,identifier:"analytics",datapoint:"report",data:R(R({},_.p),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(v.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.overview)return{overview:Object(_.b)(n)}}},{type:D.b,identifier:"analytics",datapoint:"report",data:R(R({},_.t),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(v.n)("day"),context:["Dashboard"],toState:function(e,t){var n=t.data;if(!e.directTotalUsers)return{directTotalUsers:Object(y.get)(n,"[0].data.totals[0].values[0]")}}},{type:D.b,identifier:"analytics",datapoint:"report",data:R(R({},_.r),{},{url:e._googlesitekitLegacyData.permaLink}),priority:1,maxAge:Object(v.n)("day"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.extractedAnalytics)return{extractedAnalytics:Object(_.d)(n)}}},{type:D.b,identifier:"analytics",datapoint:"goals",data:{url:e._googlesitekitLegacyData.permaLink},priority:1,maxAge:Object(v.n)("hour"),context:"Dashboard",toState:function(e,t){var n=t.data;if(!e.goals)return{goals:n}}}],a.createElement(m.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(j.a,{width:"100%",height:"202px"})),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},a.createElement(j.a,{width:"100%",height:"202px"}))),{inGrid:!0},(function(e,t){return"report"===t&&Object(_.h)(e)}),_.f)}).call(this,n(15),n(12))},186:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(5),m=n(21),y=n(187),b=n(31),v=n(46),_=n(25),k=n(17);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var D=function(t){s()(WPAnalyticsDashboardWidgetOverview,t);var n=O(WPAnalyticsDashboardWidgetOverview);function WPAnalyticsDashboardWidgetOverview(){return r()(this,WPAnalyticsDashboardWidgetOverview),n.apply(this,arguments)}return o()(WPAnalyticsDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=Object(m.b)(t);if(!n)return null;var a=n.totalUsers,r=n.averageSessionDuration,i=n.totalUsersChange,o=n.averageSessionDurationChange;return e.createElement(f.b,null,t.length?e.createElement(f.b,null,e.createElement(b.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-users",title:Object(p.__)("Total Unique Visitors","google-site-kit"),datapoint:Object(h.s)(a),change:i,changeDataUnit:"%"}),e.createElement(b.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-average-session-duration",title:Object(p.__)("Avg. Time on Page","google-site-kit"),datapoint:Object(h.r)(r),change:o,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(v.a,{title:Object(p.__)("Analytics Gathering Data","google-site-kit"),description:Object(p.__)("Analytics data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPAnalyticsDashboardWidgetOverview}(f.a);t.a=Object(_.a)(D,[{type:k.b,identifier:"analytics",datapoint:"report",data:m.p,priority:1,maxAge:Object(h.n)("day"),context:["WPDashboard"]}],e.createElement(y.a,{width:"23%",height:"94px",count:2}),{},m.h,m.f)}).call(this,n(12))},187:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(30);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(PreviewBlocks,t);var n=y(PreviewBlocks);function PreviewBlocks(){return r()(this,PreviewBlocks),n.apply(this,arguments)}return o()(PreviewBlocks,[{key:"render",value:function(){for(var t=this.props,n=t.width,a=t.height,r=t.shape,i=t.count,o=[],c=0;c++<i;)o.push(e.createElement(m.a,{width:n,height:a,shape:r,key:c}));return o}}]),PreviewBlocks}(f.a);b.propTypes={width:h.a.string,height:h.a.string,shape:h.a.string,count:h.a.number},b.defaultProps={width:"100px",height:"100px",shape:"square",count:1},t.a=b}).call(this,n(12))},188:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(57),m=n(27),y=n(128),b=n(112);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,t);var n=v(AnalyticsDashboardDetailsWidgetTopAcquisitionSources);function AnalyticsDashboardDetailsWidgetTopAcquisitionSources(){return r()(this,AnalyticsDashboardDetailsWidgetTopAcquisitionSources),n.apply(this,arguments)}return o()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{title:Object(p.__)("All Traffic","google-site-kit"),description:Object(p.__)("How people found your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{className:"googlesitekit-analytics-acquisition-sources",footer:!0,headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(p.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(p._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(b.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement(y.a,null)))))))}}]),AnalyticsDashboardDetailsWidgetTopAcquisitionSources}(f.a);t.a=_}).call(this,n(12))},189:function(e,t,n){"use strict";(function(e){var a=n(38),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(13),y=n(0),b=n(25),v=n(17),_=n(39),k=n(51),O=n(5),D=n(21);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var S=function(t){u()(WPAnalyticsDashboardWidgetTopPagesTable,t);var n=E(WPAnalyticsDashboardWidgetTopPagesTable);function WPAnalyticsDashboardWidgetTopPagesTable(){return o()(this,WPAnalyticsDashboardWidgetTopPagesTable),n.apply(this,arguments)}return s()(WPAnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data;if(Object(D.h)(t))return null;var n=[],a=Object(m.map)(t[0].data.rows,(function(e,t){var a=r()(e.dimensions,2),i=a[0],o=a[1];return n[t]=o.startsWith("/")?o:"/"+o,[i,Object(O.q)(e.metrics[0].values[0])]})),i=[{title:Object(y.__)("Title","google-site-kit"),tooltip:Object(y.__)("Page Title","google-site-kit"),primary:!0},{title:Object(y.__)("Pageviews","google-site-kit"),tooltip:Object(y.__)("Pageviews","google-site-kit")}],o={chartsEnabled:!0,links:n,cap:5,showURLs:!0},c=Object(_.b)(a,i,o);return e.createElement("div",{className:"googlesitekit-search-console-widget"},e.createElement("h2",{className:"googlesitekit-search-console-widget__title"},Object(y.__)("Top content over the last 28 days","google-site-kit")),e.createElement(_.a,null,c))}}]),WPAnalyticsDashboardWidgetTopPagesTable}(h.a);t.a=Object(b.a)(S,[{type:v.b,identifier:"analytics",datapoint:"report",data:Object(D.g)(),priority:1,maxAge:Object(O.n)("day"),context:"WPDashboard"}],e.createElement(k.a,{rows:6}))}).call(this,n(12))},190:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(13),h=n(0),m=n(5),y=n(25),b=n(17),v=n(39),_=n(27),k=n(51),O=n(87),D=n(120),E=n(21);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var j=function(t){s()(AnalyticsAdSenseDashboardWidgetTopPagesTable,t);var n=S(AnalyticsAdSenseDashboardWidgetTopPagesTable);function AnalyticsAdSenseDashboardWidgetTopPagesTable(){return r()(this,AnalyticsAdSenseDashboardWidgetTopPagesTable),n.apply(this,arguments)}return o()(AnalyticsAdSenseDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data;if(Object(E.h)(t))return null;var n=[{title:Object(h.__)("Page Title","google-site-kit"),tooltip:Object(h.__)("Page Title","google-site-kit"),primary:!0},{title:Object(h.__)("Earnings","google-site-kit"),tooltip:Object(h.__)("Earnings","google-site-kit")},{title:Object(h.__)("Page RPM","google-site-kit"),tooltip:Object(h.__)("Page RPM","google-site-kit")},{title:Object(h.__)("Impressions","google-site-kit"),tooltip:Object(h.__)("Impressions","google-site-kit")}],a=Object(p.map)(t[0].data.rows,(function(e){return[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2),Number(e.metrics[0].values[1]).toFixed(2),Object(m.q)(e.metrics[0].values[2])]})),r=Object(m.j)().analytics.settings,i=r.accountID,o=r.internalWebPropertyID,c=r.profileID,s="https://analytics.google.com/analytics/web/?pli=1#/report/content-pages/a".concat(i,"w").concat(o,"p").concat(c,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:~2F"),l={hideHeader:!1,chartsEnabled:!1,links:Object(p.map)(t[0].data.rows,(function(e){var t=e.dimensions[1].replace(/\//g,"~2F");return s+t}))},u=Object(v.b)(a,n,l);return AnalyticsAdSenseDashboardWidgetTopPagesTable.renderLayout(e.createElement(v.a,null,u))}}],[{key:"renderLayout",value:function(t){var n=Object(m.j)().adsense.accountURL;return e.createElement(_.a,{header:!0,title:Object(h.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(h.__)("Advanced Settings","google-site-kit"),headerCtaLink:n},t)}}]),AnalyticsAdSenseDashboardWidgetTopPagesTable}(f.a);t.a=Object(y.a)(j,[{type:b.b,identifier:"analytics",datapoint:"report",data:E.a,priority:1,maxAge:Object(m.n)("day"),context:"Single"}],j.renderLayout(e.createElement(k.a,{padding:!0})),{createGrid:!0},(function(){return!1}),(function(t){return t.code&&t.message&&t.data&&t.data.status?"badRequest"===t.data.reason?j.renderLayout(Object(O.a)(e.createElement(D.a,null),!1,!1,!0)):t.message:!!t.error&&(400===t.error.code&&"INVALID_ARGUMENT"===t.error.status&&Object(m.j)().analytics.active?null:t.error.message?t.error.message:t.error.errors&&t.error.errors[0]&&t.error.errors[0].message?t.error.errors[0].message:Object(h.__)("Unidentified error","google-site-kit"))}))}).call(this,n(12))},191:function(e,t,n){"use strict";(function(e){var a=n(38),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(13),y=n(0),b=n(5),v=n(21),_=n(25),k=n(17),O=n(39),D=n(51),E=n(27);function S(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var j=function(t){u()(AnalyticsDashboardWidgetPopularPagesTable,t);var n=S(AnalyticsDashboardWidgetPopularPagesTable);function AnalyticsDashboardWidgetPopularPagesTable(){return o()(this,AnalyticsDashboardWidgetPopularPagesTable),n.apply(this,arguments)}return s()(AnalyticsDashboardWidgetPopularPagesTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=[{title:Object(y.__)("Most popular content","google-site-kit"),primary:!0},{title:Object(y.__)("Views","google-site-kit")}],a=[],i=Object(m.map)(t[0].data.rows,(function(e,t){var n=r()(e.dimensions,2),i=n[0],o=n[1];return a[t]=o.startsWith("/")?o:"/"+o,[i,Object(b.q)(e.metrics[0].values[0])]})),o={hideHeader:!1,chartsEnabled:!1,links:a,showURLs:!0},c=Object(O.b)(i,n,o);return AnalyticsDashboardWidgetPopularPagesTable.renderLayout(e.createElement(O.a,null,c))}}],[{key:"renderLayout",value:function(t){return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(E.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(y._x)("Analytics","Service name","google-site-kit"),footerCtaLink:Object(b.j)().analytics.homepage,fill:!0},t))}}]),AnalyticsDashboardWidgetPopularPagesTable}(h.a);t.a=Object(_.a)(j,[{type:k.b,identifier:"analytics",datapoint:"report",data:Object(v.g)(),priority:1,maxAge:Object(b.n)("day"),context:["Single","Dashboard"]}],j.renderLayout(e.createElement(D.a,{padding:!0})),{inGrid:!0,createGrid:!0},v.h)}).call(this,n(12))},192:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(13),h=n(0),m=n(25),y=n(17),b=n(39),v=n(51),_=n(27),k=n(120),O=n(5),D=n(21);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var S=function(t){s()(AdSenseDashboardWidgetTopPagesTableSmall,t);var n=E(AdSenseDashboardWidgetTopPagesTableSmall);function AdSenseDashboardWidgetTopPagesTableSmall(){return r()(this,AdSenseDashboardWidgetTopPagesTableSmall),n.apply(this,arguments)}return o()(AdSenseDashboardWidgetTopPagesTableSmall,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=[{title:Object(h.__)("Top Earning Pages","google-site-kit"),tooltip:Object(h.__)("Top Earning Pages","google-site-kit"),primary:!0},{title:Object(h.__)("Revenue","google-site-kit"),tooltip:Object(h.__)("Revenue","google-site-kit")}],a=[],r=Object(p.map)(t[0].data.rows,(function(e,t){return a[t]=e.dimensions[1],[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2)]})),i={hideHeader:!1,chartsEnabled:!1,cap:5,links:a},o=Object(b.b)(r,n,i);return AdSenseDashboardWidgetTopPagesTableSmall.renderLayout(e.createElement(b.a,null,o))}}],[{key:"renderLayout",value:function(t){return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(_.a,{className:"googlesitekit-top-earnings-pages",footer:!0,footerCtaLabel:Object(h._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"http://analytics.google.com",fill:!0},t))}}]),AdSenseDashboardWidgetTopPagesTableSmall}(f.a);t.a=Object(m.a)(S,[{type:y.b,identifier:"analytics",datapoint:"report",data:D.a,priority:1,maxAge:Object(O.n)("day"),context:"Dashboard"}],S.renderLayout(e.createElement(v.a,{rows:5,padding:!0})),{inGrid:!0,createGrid:!0},D.h,(function(t){if(t.code&&t.message&&t.data&&t.data.status)return"badRequest"===t.data.reason?e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(_.a,{className:"googlesitekit-top-earnings-pages",fill:!0},e.createElement(k.a,null))):t.message;if(t&&t.errors){var n=Object.values(t.errors);if(n[0]&&n[0][0])return n[0][0]}return!1}))}).call(this,n(12))},193:function(e,t,n){"use strict";(function(e){var a=n(10),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(22),u=n.n(l),d=n(8),g=n.n(d),f=n(9),p=n.n(f),h=n(3),m=n.n(h),y=n(1),b=n(18),v=n.n(b),_=n(0),k=n(11),O=n.n(k),D=n(90),E=n(194),S=n(130),j=n(195),w=n(86),R=n(27),A=n(111),C=n(49),N=n(73),P=n(74),x=n(59),T=n(89),L=n(5),I=n(20);function W(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function M(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var r=m()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return p()(this,n)}}var U=O.a.withSelect,q=function(t){g()(GoogleSitekitSearchConsoleDashboardWidget,t);var n=M(GoogleSitekitSearchConsoleDashboardWidget);function GoogleSitekitSearchConsoleDashboardWidget(e){var t;return o()(this,GoogleSitekitSearchConsoleDashboardWidget),(t=n.call(this,e)).state={selectedStats:[0,1],receivingData:!0,error:!1,loading:!0},t.handleStatSelection=t.handleStatSelection.bind(u()(t)),t.buildSeries=t.buildSeries.bind(u()(t)),t.buildVAxes=t.buildVAxes.bind(u()(t)),t.handleDataError=t.handleDataError.bind(u()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(u()(t)),t}return s()(GoogleSitekitSearchConsoleDashboardWidget,[{key:"handleDataError",value:function(e,t){this.setState({receivingData:!1,error:e,errorObj:t,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleStatSelection",value:function(e){var t=this.state.selectedStats,n=t.slice();t.includes(e)?n=t.filter((function(t){return e!==t})):n.push(e),0!==n.length&&this.setState({selectedStats:n})}},{key:"buildSeries",value:function(){var e=this.state.selectedStats,t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"};return e.map((function(e,n){return{color:t[e],targetAxisIndex:n}}))}},{key:"buildVAxes",value:function(){var e=this.state.selectedStats,t={0:Object(_.__)("Clicks","google-site-kit"),1:Object(_.__)("Impressions","google-site-kit"),2:Object(_.__)("Average CTR","google-site-kit"),3:Object(_.__)("Average Position","google-site-kit")};return e.map((function(e){var n={};return 3===e&&(n.direction=-1),function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?W(Object(n),!0).forEach((function(t){r()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):W(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({title:t[e]},n)}))}},{key:"render",value:function(){var t=this.state,n=t.selectedStats,a=t.receivingData,r=t.error,i=t.errorObj,o=t.loading,c=this.props.dateRange,s=this.buildSeries(),l=this.buildVAxes(),u=!o&&a?"":"googlesitekit-nodata",d=Object(x.b)(c),g=Object(_.sprintf)("https://search.google.com/search-console?resource_id=%s",Object(L.j)()["search-console"].settings.propertyID);return e.createElement(y.b,null,e.createElement(D.a,null),e.createElement(A.a,{module:"search-console"}),e.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--search-console"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(w.a,{title:Object(_._x)("Search Console","Service name","google-site-kit"),icon:!0,iconWidth:"23",iconHeight:"21",iconID:"search-console",status:"connected",statusText:Object(_.__)("Search Console is connected","google-site-kit")}),o&&e.createElement(C.a,null)),!a&&(r?Object(P.a)(Object(_._x)("Search Console","Service name","google-site-kit"),r,!0,!0,!0,i):Object(N.a)(Object(_._x)("Search Console","Service name","google-site-kit"),!0,!0,!0)),e.createElement("div",{className:v()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(R.a,{header:!0
11
- /* translators: %s: date range */,title:Object(_.sprintf)(Object(_.__)("Overview for the last %s","google-site-kit"),d),headerCtaLabel:Object(_.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:g},e.createElement(j.a,{selectedStats:n,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),e.createElement(E.a,{selectedStats:n,series:s,vAxes:l}))),e.createElement("div",{className:v()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},e.createElement(R.a
12
- /* translators: %s: date range */,{title:Object(_.sprintf)(Object(_.__)("Top search queries over the last %s","google-site-kit"),d),header:!0,footer:!0,headerCtaLabel:Object(_.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:g,footerCtaLabel:Object(_._x)("Search Console","Service name","google-site-kit"),footerCtaLink:g},e.createElement(S.a,null))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(T.a,null))))))}}]),GoogleSitekitSearchConsoleDashboardWidget}(y.a);t.a=U((function(e){return{dateRange:e(I.c).getDateRange()}}))(q)}).call(this,n(12))},194:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(22),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(0),b=n(5),v=n(25),_=n(17),k=n(75),O=n(30),D=n(53);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var S=function(t){d()(SearchConsoleDashboardWidgetSiteStats,t);var n=E(SearchConsoleDashboardWidgetSiteStats);function SearchConsoleDashboardWidgetSiteStats(e){var t;return i()(this,SearchConsoleDashboardWidgetSiteStats),(t=n.call(this,e)).setOptions=t.setOptions.bind(l()(t)),t}return c()(SearchConsoleDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,n=t.selectedStats,a=t.series,r=t.vAxes,i=e._googlesitekitLegacyData.pageTitle,o=Object(y.__)("Search Traffic Summary","google-site-kit");i&&i.length&&(
13
- /* translators: %s: page title */
14
- o=Object(y.sprintf)(Object(y.__)("Search Traffic Summary for %s","google-site-kit"),Object(b.e)(i)));var c={chart:{title:o},curveType:"line",height:270,width:"100%",chartArea:{height:"80%",width:"87%"},legend:{position:"top",textStyle:{color:"#616161",fontSize:12}},hAxis:{format:"M/d/yy",gridlines:{color:"#fff"},textStyle:{color:"#616161",fontSize:12}},vAxis:{gridlines:{color:"#eee"},minorGridlines:{color:"#eee"},textStyle:{color:"#616161",fontSize:12},titleTextStyle:{color:"#616161",fontSize:12,italic:!1}}};return c.series=a,c.vAxes=r,3<=n.length&&(c.vAxis.textPosition="none",c.vAxis.gridlines.color="#fff",c.vAxis.minorGridlines.color="#fff",c.chartArea.width="98%"),c}},{key:"render",value:function(){var e=this.props,t=e.data,n=e.selectedStats;if(!t||!t.length)return null;var r=this.setOptions(),i=Object(D.a)(t);return a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement(k.a,{selectedStats:n,data:i.dataMap,options:r,singleStat:!1}))))}}]),SearchConsoleDashboardWidgetSiteStats}(m.a);t.a=Object(v.a)(S,[{type:_.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(b.n)("day"),context:"Single"}],a.createElement(O.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,n(15),n(12))},195:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(5),m=n(31),y=n(25),b=n(17),v=n(30),_=n(53),k=n(2),O=n.n(k);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(SearchConsoleDashboardWidgetOverview,t);var n=D(SearchConsoleDashboardWidgetOverview);function SearchConsoleDashboardWidgetOverview(){return r()(this,SearchConsoleDashboardWidgetOverview),n.apply(this,arguments)}return o()(SearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.selectedStats,r=t.handleStatSelection;if(!n||!n.length)return null;var i=Object(_.a)(n),o=i.totalClicks,c=i.totalImpressions,s=i.averageCTR,l=i.averagePosition,u=i.totalClicksChange,d=i.totalImpressionsChange,g=i.averageCTRChange,h=i.averagePositionChange,y=[{className:"googlesitekit-data-block--clicks googlesitekit-data-block--button-1",title:Object(p.__)("Total Clicks","google-site-kit"),datapoint:o,change:u,changeDataUnit:"%",context:"button",selected:a.includes(0),handleStatSelection:r},{className:"googlesitekit-data-block--impressions googlesitekit-data-block--button-2",title:Object(p.__)("Total Impressions","google-site-kit"),datapoint:c,change:d,changeDataUnit:"%",context:"button",selected:a.includes(1),handleStatSelection:r},{className:"googlesitekit-data-block--ctr googlesitekit-data-block--button-3",title:Object(p.__)("Average CTR","google-site-kit"),datapoint:s+"%",change:g,changeDataUnit:"%",context:"button",selected:a.includes(2),handleStatSelection:r},{className:"googlesitekit-data-block--position googlesitekit-data-block--button-4",title:Object(p.__)("Average Position","google-site-kit"),datapoint:l,change:h,changeDataUnit:"%",context:"button",selected:a.includes(3),handleStatSelection:r}];return e.createElement(f.b,null,e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner",role:"toolbar","aria-label":"Line Chart Options"},y.map((function(t,n){return e.createElement("div",{key:n,className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(m.a,{stat:n,className:t.className,title:t.title,datapoint:t.datapoint,change:t.change,changeDataUnit:t.changeDataUnit,context:t.context,selected:t.selected,handleStatSelection:t.handleStatSelection}))})))))}}]),SearchConsoleDashboardWidgetOverview}(f.a);E.propTypes={handleDataError:O.a.func.isRequired},t.a=Object(y.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(h.n)("day"),context:["Single","Dashboard"]}],e.createElement(v.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},_.b)}).call(this,n(12))},196:function(e,t,n){"use strict";(function(e,a){var r=n(33),i=n.n(r),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(1),y=n(197);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var v=function(t){d()(GoogleSitekitSearchConsoleAdminbarWidget,t);var n=b(GoogleSitekitSearchConsoleAdminbarWidget);function GoogleSitekitSearchConsoleAdminbarWidget(){return c()(this,GoogleSitekitSearchConsoleAdminbarWidget),n.apply(this,arguments)}return l()(GoogleSitekitSearchConsoleAdminbarWidget,[{key:"render",value:function(){return"undefined"!==i()(e._googlesitekitLegacyData.permaLink)&&""===e._googlesitekitLegacyData.permaLink?null:a.createElement(y.a,null)}}]),GoogleSitekitSearchConsoleAdminbarWidget}(m.a);t.a=v}).call(this,n(15),n(12))},197:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(0),m=n(5),y=n(31),b=n(25),v=n(17),_=n(53),k=n(30);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var D=function(t){l()(SearchConsoleAdminbarWidgetOverview,t);var n=O(SearchConsoleAdminbarWidgetOverview);function SearchConsoleAdminbarWidgetOverview(){return i()(this,SearchConsoleAdminbarWidgetOverview),n.apply(this,arguments)}return c()(SearchConsoleAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error)return null;var n=Object(_.a)(t),a=n.totalClicks,r=n.totalImpressions,i=n.totalClicksChange,o=n.totalImpressionsChange;return e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(y.a,{className:"overview-total-impressions",title:Object(h.__)("Total Impressions","google-site-kit"),datapoint:r,change:o,changeDataUnit:"%"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(y.a,{className:"overview-total-clicks",title:Object(h.__)("Total Clicks","google-site-kit"),datapoint:a,change:i,changeDataUnit:"%"})))}}]),SearchConsoleAdminbarWidgetOverview}(p.a);t.a=Object(b.a)(D,[{type:v.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(m.n)("day"),context:"Adminbar"}],e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"auto",height:"59px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"auto",height:"59px"}))),{inGrid:!0},_.b)}).call(this,n(12),n(15))},198:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(199);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(t){s()(WPSearchConsoleDashboardWidget,t);var n=h(WPSearchConsoleDashboardWidget);function WPSearchConsoleDashboardWidget(){return r()(this,WPSearchConsoleDashboardWidget),n.apply(this,arguments)}return o()(WPSearchConsoleDashboardWidget,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement(p.a,null))}}]),WPSearchConsoleDashboardWidget}(f.a);t.a=m}).call(this,n(12))},199:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(5),m=n(30),y=n(31),b=n(25),v=n(17),_=n(53),k=n(46);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var D=function(t){s()(WPSearchConsoleDashboardWidgetOverview,t);var n=O(WPSearchConsoleDashboardWidgetOverview);function WPSearchConsoleDashboardWidgetOverview(){return r()(this,WPSearchConsoleDashboardWidgetOverview),n.apply(this,arguments)}return o()(WPSearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=Object(_.a)(t),a=n.totalClicks,r=n.totalImpressions,i=n.totalClicksChange,o=n.totalImpressionsChange;return e.createElement(f.b,null,t.length?e.createElement(f.b,null,e.createElement(y.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-impressions",title:Object(p.__)("Total Impressions","google-site-kit"),datapoint:r,change:o,changeDataUnit:"%"}),e.createElement(y.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-clicks",title:Object(p.__)("Total Clicks","google-site-kit"),datapoint:a,change:i,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(k.a,{title:Object(p.__)("Search Console Data Empty","google-site-kit"),description:Object(p.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPSearchConsoleDashboardWidgetOverview}(f.a);t.a=Object(b.a)(D,[{type:v.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(h.n)("day"),context:["WPDashboard"]}],e.createElement(m.a,{width:"23%",height:"94px",count:2}),{},_.b)}).call(this,n(12))},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return a})),n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return i}));var a="core/user",r="googlesitekit_manage_options",i="missing_required_scopes"},200:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(18),m=n.n(h),y=n(0),b=n(5),v=n(27),_=n(57),k=n(100),O=n(131);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var E=function(t){l()(DashboardSearchFunnel,t);var n=D(DashboardSearchFunnel);function DashboardSearchFunnel(){return i()(this,DashboardSearchFunnel),n.apply(this,arguments)}return c()(DashboardSearchFunnel,[{key:"render",value:function(){var t=Object(b.j)(),n=e._googlesitekitLegacyData.permissions.canManageOptions,r=t.analytics.active||n?12:6;return a.createElement(p.b,null,a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},a.createElement(_.a,{title:Object(y.__)("Search Funnel","google-site-kit"),description:Object(y.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit")})),a.createElement("div",{className:m()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(r))},a.createElement(v.a,{className:"googlesitekit-analytics-search-funnel"},a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement(O.a,null),!t.analytics.active&&a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(k.a,null)))))))}}]),DashboardSearchFunnel}(p.a);t.a=E}).call(this,n(15),n(12))},201:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(0),m=n(31),y=n(25),b=n(17),v=n(53),_=n(64),k=n(30),O=n(5),D=n(46);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var S=function(t){l()(SearchConsoleDashboardWidgetTopLevel,t);var n=E(SearchConsoleDashboardWidgetTopLevel);function SearchConsoleDashboardWidgetTopLevel(){return i()(this,SearchConsoleDashboardWidgetTopLevel),n.apply(this,arguments)}return c()(SearchConsoleDashboardWidgetTopLevel,[{key:"render",value:function(){var t=this.props.data,n=t.error;if(n)return Object(O.w)("plugin_setup","search_console_error",n.message),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(D.a,{title:Object(h.__)("Something went wrong","google-site-kit"),description:n.message,error:!0}));if(!t)return null;if(!t.length)return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(D.a,{title:Object(h.__)("Search Console Data Empty","google-site-kit"),description:Object(h.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""}));var a=Object(O.m)("googlesitekit-module-search-console",{}),r=Object(v.a)(t),i=r.totalClicks,o=r.totalImpressions,c=r.totalClicksChange,s=r.totalImpressionsChange,l=r.dataMap;return e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(m.a,{className:"overview-total-impressions",title:Object(h.__)("Impressions","google-site-kit"),datapoint:o,change:s,changeDataUnit:"%",source:{name:Object(h._x)("Search Console","Service name","google-site-kit"),link:a},sparkline:e.createElement(_.a,{data:Object(O.f)(l,2),change:s})})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(m.a,{className:"overview-total-clicks",title:Object(h.__)("Clicks","google-site-kit"),datapoint:i,change:c,changeDataUnit:"%",source:{name:Object(h._x)("Search Console","Service name","google-site-kit"),link:a},sparkline:e.createElement(_.a,{data:Object(O.f)(l,1),change:c})})))}}]),SearchConsoleDashboardWidgetTopLevel}(p.a);t.a=Object(y.a)(S,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:a._googlesitekitLegacyData.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(O.n)("day"),context:["Single","Dashboard"]}],e.createElement(p.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"100%",height:"202px"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-3-desktop "},e.createElement(k.a,{width:"100%",height:"202px"}))),{inGrid:!0},v.b)}).call(this,n(12),n(15))},202:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(27),m=n(131),y=n(5),b=n(100),v=n(57);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(DashboardDetailsSearchFunnel,t);var n=_(DashboardDetailsSearchFunnel);function DashboardDetailsSearchFunnel(){return r()(this,DashboardDetailsSearchFunnel),n.apply(this,arguments)}return o()(DashboardDetailsSearchFunnel,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(v.a,{description:Object(p.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit"),title:Object(p.__)("Search Funnel","google-site-kit")})),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},e.createElement(h.a,{className:"googlesitekit-analytics-search-funnel"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement(m.a,null),!Object(y.j)().analytics.active&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(b.a,null)))))))}}]),DashboardDetailsSearchFunnel}(f.a);t.a=k}).call(this,n(12))},203:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(130),m=n(57),y=n(27),b=n(5);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(DashboardDetailsWidgetKeywordsTable,t);var n=v(DashboardDetailsWidgetKeywordsTable);function DashboardDetailsWidgetKeywordsTable(){return r()(this,DashboardDetailsWidgetKeywordsTable),n.apply(this,arguments)}return o()(DashboardDetailsWidgetKeywordsTable,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(p.__)("Top Queries","google-site-kit"),description:Object(p.__)("What people searched for to find your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(y.a,{footer:!0,footerCtaLabel:Object(p._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(p.sprintf)("https://search.google.com/search-console?resource_id=%s",Object(b.j)()["search-console"].settings.propertyID)},e.createElement(h.a,null))))}}]),DashboardDetailsWidgetKeywordsTable}(f.a);t.a=_}).call(this,n(12))},204:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(13),h=n(0),m=n(5),y=n(25),b=n(17),v=n(39),_=n(51),k=n(27),O=n(53);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var E=function(t){s()(DashboardWidgetPopularKeywordsTable,t);var n=D(DashboardWidgetPopularKeywordsTable);function DashboardWidgetPopularKeywordsTable(){return r()(this,DashboardWidgetPopularKeywordsTable),n.apply(this,arguments)}return o()(DashboardWidgetPopularKeywordsTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var n=[{title:Object(h.__)("Top search queries for your site","google-site-kit"),tooltip:Object(h.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(h.__)("Clicks","google-site-kit"),tooltip:Object(h.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(h.__)("Impressions","google-site-kit"),tooltip:Object(h.__)("Counted each time your content appears in search results","google-site-kit")}],a=Object(m.j)()["search-console"].settings.propertyID,r=[],i=Object(p.map)(t,(function(e,t){var n=e.keys[0];return r[t]=Object(h.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%1$s&query=!%2$s&num_of_days=28",a,n),[n,Object(m.q)(e.clicks),Object(m.q)(e.impressions)]})),o={hideHeader:!1,chartsEnabled:!1,links:r},c=Object(v.b)(i,n,o);return DashboardWidgetPopularKeywordsTable.renderLayout(e.createElement(v.a,null,c))}}],[{key:"renderLayout",value:function(t){return e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(k.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(h._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(h.sprintf)("https://search.google.com/search-console?resource_id=%s",Object(m.j)()["search-console"].settings.propertyID),fill:!0},t))}}]),DashboardWidgetPopularKeywordsTable}(f.a);t.a=Object(y.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"query",limit:10},priority:1,maxAge:Object(m.n)("day"),context:["Dashboard"]}],E.renderLayout(e.createElement(_.a,{padding:!0})),{inGrid:!0,createGrid:!0},O.b)}).call(this,n(12))},205:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(0),h=n(206),m=n(57);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(DashboardPopularity,t);var n=y(DashboardPopularity);function DashboardPopularity(){return r()(this,DashboardPopularity),n.apply(this,arguments)}return o()(DashboardPopularity,[{key:"render",value:function(){return e.createElement(f.b,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(p.__)("Popularity","google-site-kit"),description:Object(p.__)("Your most popular pages and how people found them from Search.","google-site-kit")})),e.createElement(h.a,null))}}]),DashboardPopularity}(f.a);t.a=b}).call(this,n(12))},206:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(DashboardPopularityInner,e);var t=p(DashboardPopularityInner);function DashboardPopularityInner(){return r()(this,DashboardPopularityInner),t.apply(this,arguments)}return o()(DashboardPopularityInner,[{key:"render",value:function(){return null}}]),DashboardPopularityInner}(n(1).a);t.a=Object(f.a)("googlesitekit.DashboardPopularity")(h)},207:function(e,t,n){"use strict";(function(e,a){var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(22),f=n.n(g),p=n(8),h=n.n(p),m=n(9),y=n.n(m),b=n(3),v=n.n(b),_=n(1),k=n(13),O=n(237),D=n.n(O),E=n(0),S=n(5),j=n(17),w=n(47),R=n(27);function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var C=function(t){h()(PostSearcher,t);var n,r=A(PostSearcher);function PostSearcher(e){var t;return l()(this,PostSearcher),(t=r.call(this,e)).noResultsMessage=Object(E.__)("No results found","google-site-kit"),t.state={isSearching:!1,results:[],error:!1,message:"",canSubmit:!1,match:{}},t.postSearch=t.postSearch.bind(f()(t)),t.onClick=t.onClick.bind(f()(t)),t.onConfirm=t.onConfirm.bind(f()(t)),t}return d()(PostSearcher,[{key:"postSearch",value:(n=c()(i.a.mark((function e(t,n){var a;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n([Object(E.__)("Loading…","google-site-kit")]),e.prev=1,e.next=4,j.c.get(j.a,"search","post-search",{query:encodeURIComponent(t)});case 4:0<(a=e.sent).length?n(Object(k.map)(a,(function(e){return e.post_title}))):n([this.noResultsMessage]),this.setState({isSearching:!0,results:a,error:!1,message:""}),e.next=13;break;case 9:e.prev=9,e.t0=e.catch(1),n([this.noResultsMessage]),this.setState({isSearching:!1,error:e.t0.code,message:e.t0.message});case 13:case"end":return e.stop()}}),e,this,[[1,9]])}))),function(e,t){return n.apply(this,arguments)})},{key:"getURLPathname",value:function(e){try{var t=new URL(e);return Object(k.trim)(t.pathname,"/")}catch(e){return!1}}},{key:"onConfirm",value:function(e){var t=this.state.results;if(Array.isArray(t)&&e!==this.noResultsMessage){var n=t.find((function(t){return t.post_title===e}));e&&n&&this.setState({selection:e,canSubmit:!0,match:n})}else this.setState({canSubmit:!1})}},{key:"onClick",value:function(){var t=this.state,n=t.selection,a=t.match;a&&a.ID&&e.location.assign(Object(S.m)("googlesitekit-dashboard",{id:a.ID,permaLink:a.permalink,pageTitle:n}))}},{key:"render",value:function(){var e=Object(S.j)(),t=e.analytics&&e.analytics.active?"mdc-layout-grid__cell mdc-layout-grid__cell--span-12":"mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop";return a.createElement("div",{className:t},a.createElement(R.a,{title:Object(E.__)("Search for individual page or post information","google-site-kit"),header:!0},a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},a.createElement("div",{className:"googlesitekit-post-searcher"},a.createElement("label",{className:"googlesitekit-post-searcher__label",htmlFor:"autocomplete"},Object(E.__)("Title or URL","google-site-kit")),a.createElement(D.a,{id:"autocomplete",source:Object(k.debounce)(this.postSearch,200),minLength:2,onConfirm:this.onConfirm,showNoOptionsFound:!1}),a.createElement("div",{className:"googlesitekit-post-searcher__button-wrapper"},a.createElement(w.a,{onClick:this.onClick,className:"googlesitekit-post-searcher__button",disabled:!this.state.canSubmit},Object(E.__)("View Data","google-site-kit")))))))))}}]),PostSearcher}(_.a);t.a=C}).call(this,n(15),n(12))},21:function(e,t,n){"use strict";n.d(t,"b",(function(){return o})),n.d(t,"q",(function(){return y})),n.d(t,"i",(function(){return d})),n.d(t,"j",(function(){return g})),n.d(t,"n",(function(){return f})),n.d(t,"o",(function(){return p})),n.d(t,"m",(function(){return h})),n.d(t,"l",(function(){return m})),n.d(t,"k",(function(){return d})),n.d(t,"e",(function(){return b})),n.d(t,"c",(function(){return _})),n.d(t,"d",(function(){return k})),n.d(t,"f",(function(){return O})),n.d(t,"h",(function(){return D})),n.d(t,"a",(function(){return E})),n.d(t,"r",(function(){return S})),n.d(t,"p",(function(){return j})),n.d(t,"t",(function(){return w})),n.d(t,"s",(function(){return R})),n.d(t,"g",(function(){return A}));var a=n(13),r=n(0),i=n(5),o=function(e){if(!e||!e.length)return!1;var t=e[0].data.totals,n=t[0].values,a=t[1].values,r=n[0],o=n[1],c=n[2],s=n[3],l=n[4],u=n[5];return{totalUsers:r,totalSessions:o,averageBounceRate:c,averageSessionDuration:s,totalUsersChange:Object(i.c)(a[0],n[0]),totalSessionsChange:Object(i.c)(a[1],n[1]),averageBounceRateChange:Object(i.c)(a[2],n[2]),averageSessionDurationChange:Object(i.c)(a[3],n[3]),goalCompletions:l,goalCompletionsChange:Object(i.c)(a[4],n[4]),totalPageViews:u,totalPageViewsChange:Object(i.c)(a[5],n[5])}},c=function(e){if("string"==typeof e&&e.match(/[0-9]{8}/)){var t=e.slice(0,4),n=Number(e.slice(4,6))-1,a=e.slice(6,8);return new Date(t,n.toString(),a)}return!1},s=n(38),l=n.n(s),u=n(24),d=function(e){return(parseInt(e,10)||0)>0};function g(e){return e===u.a||d(e)}function f(e){return"string"==typeof e&&/^UA-\d+-\d+$/.test(e)}function p(e){return e===u.f||f(e)}function h(e){return e===u.e||d(e)}function m(e){return"string"==typeof e&&e.trim().length>0}function y(e){if(!f(e))return!1;var t=e.match(/^UA-(\d+)-(\d+)/),n=l()(t,3);return{accountID:n[1],propertyID:e,number:n[2]}}var b=function(e){if(!e||!e.length)return null;var t=e[0].data,n=t.rows,r=t.totals[0].values[1],i=[["Source","Percent"]];return Object(a.each)(n,(function(e){var t=e.metrics[0].values[1]/r,n=e.dimensions[0];i.push([n,t])})),i};function v(e,t){var n=[];return Object(a.each)(e,(function(e){if(e.metrics){var a=e.metrics[0].values,r=e.dimensions[0],i=c(r);n.push([i,a[t]])}})),n}var _=function(e,t,n){if(!e||!e.length)return null;var i=e[0].data.rows;if(!i)return!1;var o=i.length;if(2*n>o){for(var c=new Date,s=0;n>s;s++){var l=(c.getMonth()+1).toString(),u=c.getDate().toString(),d=c.getFullYear().toString()+(2>l.length?"0":"")+l+(2>u.length?"0":"")+u;if(s>o){var g={dimensions:[d],metrics:[{values:[0,0,0,0,0]}]};i.unshift(g)}c.setDate(c.getDate()-1)}i.push([0,0])}var f=[Object(r.__)("Users","google-site-kit"),Object(r.__)("Sessions","google-site-kit"),Object(r.__)("Bounce Rate","google-site-kit"),Object(r.__)("Session Duration","google-site-kit")],p=[[{type:"date",label:Object(r.__)("Day","google-site-kit")},{type:"number",label:f[t]},{type:"number",label:Object(r.__)("Previous period","google-site-kit")}]],h=i.slice(i.length-n,i.length),m=i.slice(0,i.length-n),y=v(h,t),b=v(m,t);return Object(a.each)(y,(function(e,t){e[0]&&e[1]&&b[t]&&p.push([e[0],e[1],b[t][1]])})),p},k=function(e){if(!e||!e.length)return null;var t=e[0].data.rows,n=[[{type:"date",label:"Day"},{type:"number",label:"Users"},{type:"number",label:"Sessions"},{type:"number",label:"Goals Completed"}]];return Object(a.each)(t,(function(e){var t=e.metrics[0].values,a=e.dimensions[0],r=c(a);n.push([r,t[0],t[1],t[4]])})),n},O=function(e){var t;return e.error&&e.error.status?function(e,t){var n="";switch(e){case"INVALID_ARGUMENT":n=Object(r.__)("Analytics module needs to be configured.","google-site-kit");break;case"UNAUTHENTICATED":n=Object(r.__)("You need to be authenticated to get this data.","google-site-kit");break;case"PERMISSION_DENIED":n=Object(r.__)("Your account does not have sufficient permission to access this data, please consult to your web administrator.","google-site-kit");break;case"RESOURCE_EXHAUSTED":n=Object(r.__)("Your account exceeded the maximum quota. Please try again later.","google-site-kit");break;case"INTERNAL":n=Object(r.__)("Unexpected internal server error occurred.","google-site-kit");break;case"BACKEND_ERROR":n=Object(r.__)("Analytics server returned unknown error. Please try again later.","google-site-kit");break;case"UNAVAILABLE":n=Object(r.__)("The service was unable to process the request. Please try again later.","google-site-kit");break;default:n=t}return n}(e.error.status,e.error.message):!!(e.code&&e.message&&(null===(t=e.data)||void 0===t?void 0:t.status))&&e.message},D=function(e){if(!e||!e.length)return!0;if(e&&e[0]&&e[0].data&&e[0].data.totals&&e[0].data.totals[0]){var t=e[0].data.totals[0].values,n=!0;return Object(a.each)(t,(function(e){0!==parseInt(e,10)&&(n=!1)})),n}return!1},E={dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:[{expression:"ga:adsenseRevenue",alias:"Earnings"},{expression:"ga:adsenseECPM",alias:"Page RPM"},{expression:"ga:adsensePageImpressions",alias:"Impressions"}],orderby:[{fieldName:"ga:adsenseRevenue",sortOrder:"DESCENDING"}],limit:10},S={compareDateRanges:1,dimensions:"ga:date",metrics:[{expression:"ga:users",alias:"Users"},{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:bounceRate",alias:"Bounce Rate"},{expression:"ga:avgSessionDuration",alias:"Average Session Duration"},{expression:"ga:goalCompletionsAll",alias:"Goal Completions"}],limit:180},j={multiDateRange:1,dimensions:"ga:date",metrics:[{expression:"ga:users",alias:"Users"},{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:bounceRate",alias:"Bounce Rate"},{expression:"ga:avgSessionDuration",alias:"Average Session Duration"},{expression:"ga:goalCompletionsAll",alias:"Goal Completions"},{expression:"ga:pageviews",alias:"Pageviews"}],limit:10},w={metrics:[{expression:"ga:users",alias:"Total Users"}]},R={dimensions:"ga:channelGrouping",metrics:[{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:users",alias:"Users"},{expression:"ga:newUsers",alias:"New Users"}],orderby:[{fieldName:"ga:users",sortOrder:"DESCENDING"}],limit:10},A=function(){return{dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:[{expression:"ga:pageviews",alias:"Pageviews"},{expression:"ga:uniquePageviews",alias:"Unique Pageviews"},{expression:"ga:bounceRate",alias:"Bounce rate"}],orderby:[{fieldName:"ga:pageviews",sortOrder:"DESCENDING"}],limit:10}}},23:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var a=n(81),r=n.n(a),i=n(1),o=function(e){return function(t){return function FilteredComponent(n){return Object(i.f)(i.b,{},"",Object(i.f)(t,n),e)}}},c=function(t,n){return function(a){return function InnerComponent(i){return e.createElement(t,r()({},i,n,{OriginalComponent:a}))}}}}).call(this,n(12))},24:function(e,t,n){"use strict";n.d(t,"h",(function(){return a})),n.d(t,"a",(function(){return r})),n.d(t,"f",(function(){return i})),n.d(t,"e",(function(){return o})),n.d(t,"c",(function(){return c})),n.d(t,"d",(function(){return s})),n.d(t,"g",(function(){return l})),n.d(t,"b",(function(){return u}));var a="modules/analytics",r="account_create",i="property_create",o="profile_create",c="analyticsAccountCreate",s="analyticsSetup",l="https://www.googleapis.com/auth/analytics.provision",u="https://www.googleapis.com/auth/analytics.edit"},240:function(e,t,n){"use strict";(function(e,t){n(1);var a=n(23),r=n(5),i=n(168),o=n(173),c=n(16),s="adsense";Object(c.b)("googlesitekit.SetupModuleShowLink","googlesitekit.adsenseSetupModuleShowLink",(function(t,n){return!("adsense"===n&&!e._googlesitekitLegacyData.canAdsRun)&&t}));var l=Object(r.j)();if(l.adsense.active){var u=Object(a.a)(t.createElement(i.a,null)),d=Object(a.a)(t.createElement(o.a,null));if(l[s].setupComplete)Object(c.b)("googlesitekit.ModuleApp-".concat(s),"googlesitekit.ModuleApp",u),Object(c.b)("googlesitekit.DashboardModule","googlesitekit.DashboardEarningModule",d,50);else{var g=e._googlesitekitLegacyData.admin,f=g.reAuth,p=g.currentScreen,h=p?p.id:null;f||"site-kit_page_googlesitekit-module-adsense"!==h||(e.location=Object(r.m)("googlesitekit-module-".concat(s),{reAuth:!0,slug:s})),Object(c.b)("googlesitekit.Connected-".concat(s),"googlesitekit.AdSenseModuleConnected",(function(e){var t=l[s].settings;return!(e||void 0===t||"graylisted"!==t.accountStatus&&"pending"!==t.accountStatus)||e}))}Object(c.b)("googlesitekit.ModulesNotificationsRequest","googlesitekit.adsenseNotifications",(function(e){return e.push({identifier:"adsense"}),e}))}}).call(this,n(15),n(12))},241:function(e,t,n){"use strict";(function(e,t){n(1);var a=n(16),r=n(5),i=n(23),o=n(176),c=n(181),s=n(183),l=n(185),u=n(186),d=n(188),g=n(189),f=n(190),p=n(191),h=n(192),m="analytics",y=Object(i.a)(e.createElement(c.a,null));Object(a.b)("googlesitekit.AdminbarModules","googlesitekit.Analytics",y,11);var b=Object(r.j)();if(!b[m].setupComplete){var v=t._googlesitekitLegacyData.admin,_=v.reAuth,k=v.currentScreen,O=k?k.id:null;_||"site-kit_page_googlesitekit-module-analytics"!==O||(t.location=Object(r.m)("googlesitekit-module-".concat(m),{reAuth:!0,slug:m}))}if(b.analytics.active){var D=Object(i.a)(e.createElement(o.a,null)),E=Object(i.a)(e.createElement(s.a,null)),S=Object(i.a)(e.createElement(u.a,null)),j=Object(i.a)(e.createElement(g.a,null)),w=Object(i.a)(e.createElement(l.a,null)),R=Object(i.a)(e.createElement(d.a,null)),A=Object(i.a)(e.createElement(f.a,null)),C=Object(i.a)(e.createElement(p.a,null)),N=Object(i.a)(e.createElement(h.a,null));Object(a.b)("googlesitekit.DashboardModule","googlesitekit.Analytics",E,9),Object(a.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.Analytics",w,11),Object(a.b)("googlesitekit.DashboardPopularity","googlesitekit.Analytics",C,20),Object(a.b)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall","googlesitekit.Analytics",N,20),Object(a.b)("googlesitekit.DashboardDetailsModule","googlesitekit.Analytics",R,20),Object(a.b)("googlesitekit.WPDashboardHeader","googlesitekit.Analytics",S),Object(a.b)("googlesitekit.WPDashboardModule","googlesitekit.Analytics",j),b[m].setupComplete&&Object(a.b)("googlesitekit.ModuleApp-"+m,"googlesitekit.Analytics",D),Object(a.b)("googlesitekit.AnalyticsAdSenseTopPagesTable","googlesitekit.Analytics",A,11),Object(a.b)("googlesitekit.showDateRangeSelector-".concat(m),"googlesitekit.analyticsShowDateRangeSelector",(function(){return!0}))}}).call(this,n(12),n(15))},242:function(e,t,n){"use strict";(function(e){n(1);var t=n(16),a=n(23),r=n(207),i=n(193),o=n(196),c=n(198),s=n(200),l=n(201),u=n(203),d=n(204),g=n(202),f=n(205),p="search-console",h=Object(a.a)(e.createElement(i.a,null)),m=Object(a.a)(e.createElement(o.a,null)),y=Object(a.a)(e.createElement(c.a,null)),b=Object(a.a)(e.createElement(s.a,null)),v=Object(a.a)(e.createElement(l.a,null)),_=Object(a.a)(e.createElement(g.a,null)),k=Object(a.a)(e.createElement(u.a,null)),O=Object(a.a)(e.createElement(d.a,null)),D=Object(a.a)(e.createElement(f.a,null)),E=Object(a.a)(e.createElement(r.a,null));Object(t.b)("googlesitekit.DashboardModule","googlesitekit.SearchConsole",b,11),Object(t.b)("googlesitekit.DashboardModule","googlesitekit.DashboardPopularityModule",D,40),Object(t.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.SearchConsoleSearchFunnel",v),Object(t.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",_),Object(t.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",k,40),Object(t.b)("googlesitekit.DashboardPopularity","googlesitekit.SearchConsoleDashboardPopularity",O),Object(t.b)("googlesitekit.DashboardPopularity","googlesitekit.DashboardPPostSearcherModule",E,30),Object(t.b)("googlesitekit.WPDashboardHeader","googlesitekit.SearchConsole",y,11),Object(t.b)("googlesitekit.ModuleApp-"+p,"googlesitekit.ModuleApp",h),Object(t.b)("googlesitekit.showDateRangeSelector-".concat(p),"googlesitekit.searchConsoleShowDateRangeSelector",(function(){return!0})),Object(t.b)("googlesitekit.AdminbarModules","googlesitekit.SearchConsole",m)}).call(this,n(12))},243:function(e,t,n){"use strict";n(240),n(241);var a=n(16),r=n(0),i=n(5);Object(i.j)().optimize.active&&Object(a.b)("googlesitekit.SetupWinNotification-optimize","googlesitekit.OptimizeSetupWinNotification",(function(e){return e.description=Object(r.__)("To set up experiments and see the results, go to ","google-site-kit"),e.learnMore.label="Optimize",e.learnMore.url="https://optimize.withgoogle.com/",e}));n(242)},25:function(e,t,n){"use strict";(function(e){var a=n(81),r=n.n(a),i=n(6),o=n.n(i),c=n(7),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(13),y=n(16),b=n(0),v=n(5),_=n(73),k=n(74),O=n(126);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}t.a=function(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{inGrid:!1,fullWidth:!1,createGrid:!1},c=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){return!1},l=arguments.length>5&&void 0!==arguments[5]?arguments[5]:function(e){if(e&&e.error)return e.error.message?e.error.message:e.error.errors&&e.error.errors[0]&&e.error.errors[0].message?e.error.errors[0].message:Object(b.__)("Unidentified error","google-site-kit");if(e&&e.errors&&e.errors[0]&&e.errors[0].message)return e.errors[0].message;if(e&&e.error_data){var t=Object.values(e.error_data);if(t[0]&&"RateLimitExceeded"===t[0].reason)return Object(b.__)("Too many requests have been sent within a given time span. Please reload this page again in a few seconds","google-site-kit")}if(e&&e.errors){var n=Object.values(e.errors);if(n[0]&&n[0][0])return n[0][0]}return!!(e.code&&e.message&&e.data&&e.data.status)&&e.message};return function(d){u()(NewComponent,d);var g=D(NewComponent);function NewComponent(e){var t;o()(this,NewComponent),(t=g.call(this,e)).state={data:!1,zeroData:!1,error:!1},Object(y.a)("googlesitekit.moduleDataReset","googlesitekit.moduleDataResetHandler",(function(){t.setState({data:!1})}));var a=function(e,n){var a=t.props,r=a.handleDataError,i=a.handleDataSuccess,o=n.datapoint,s=n.identifier,u=n.toState,d=l(e);d?(t.setState({error:d,module:s}),r&&r(d,e)):c(e,o,n)?(r&&r(d,e),t.setState({zeroData:!0})):i&&i(),t.setState({requestDataToState:u,data:e,datapoint:o,module:s})};return Object(m.each)(n,(function(e){Array.isArray(e.context)?Object(m.each)(e.context,(function(t){Object(y.b)("googlesitekit.module".concat(t,"DataRequest"),"googlesitekit.data".concat(t),(function(t){return e.callback=function(t){a(t,e)},t.push(e),t}))})):Object(y.b)("googlesitekit.module".concat(e.context,"DataRequest"),"googlesitekit.data".concat(e.context),(function(t){return e.callback=function(t){a(t,e)},t.push(e),t}))})),t}return s()(NewComponent,[{key:"render",value:function(){var n=this.state,o=n.data,c=n.datapoint,s=n.module,l=n.zeroData,u=n.error,d=n.requestDataToState;if(!o)return a;var g=Object(v.j)(),f=s?g[s].name:Object(b.__)("Site Kit","google-site-kit");return s&&g[s].active&&!g[s].setupComplete?Object(O.a)(s,i.inGrid,i.fullWidth,i.createGrid):u?"string"!=typeof u?u:Object(k.a)(f,u,i.inGrid,i.fullWidth,i.createGrid,o):l?Object(_.a)(f,i.inGrid,i.fullWidth,i.createGrid):e.createElement(t,r()({data:o,datapoint:c,requestDataToState:d},this.props))}}]),NewComponent}(h.a)}}).call(this,n(12))},27:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(150),v=n(151);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(Layout,t);var n=_(Layout);function Layout(){return r()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,a=t.footer,r=t.children,i=t.title,o=t.headerCtaLabel,c=t.headerCtaLink,s=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,g=t.fill,f=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":g,"googlesitekit-layout--relative":f})},n&&e.createElement(b.a,{title:i,ctaLabel:o,ctaLink:c}),r,a&&e.createElement(v.a,{ctaLabel:s,ctaLink:l,footerContent:u}))}}]),Layout}(f.a);k.propTypes={header:h.a.bool,footer:h.a.bool,children:h.a.node.isRequired,title:h.a.string,headerCtaLabel:h.a.string,headerCtaLink:h.a.string,footerCtaLabel:h.a.string,footerCtaLink:h.a.string,footerContent:h.a.node,className:h.a.string,fill:h.a.bool,relative:h.a.bool},k.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=k}).call(this,n(12))},28:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(Link,t);var n=b(Link);function Link(){return r()(this,Link),n.apply(this,arguments)}return o()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,a=t.onClick,r=t.href,i=t.children,o=t.className,c=t.arrow,s=t.external,l=t.inverse,u=t.back,d=t.small,g=t.inherit,f=t.caps,p=t.danger,h=t.disabled,m=t.id,b=r&&!h,v=b?"a":"button";return e.createElement(v,{className:y()("googlesitekit-cta-link",o,{"googlesitekit-cta-link--arrow":c,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":l,"googlesitekit-cta-link--back":u,"googlesitekit-cta-link--small":d,"googlesitekit-cta-link--inherit":g,"googlesitekit-cta-link--caps":f,"googlesitekit-cta-link--danger":p,"googlesitekit-cta-link--disabled":h}),onClick:a,id:m,href:b?r:void 0,target:b&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:h,dangerouslySetInnerHTML:n},i)}}]),Link}(f.a);v.propTypes={dangerouslySetInnerHTML:h.a.shape({__html:h.a.string}),onClick:h.a.func,href:h.a.string,children:h.a.oneOfType([h.a.string.isRequired,h.a.array.isRequired]),className:h.a.string,arrow:h.a.bool,external:h.a.bool,inverse:h.a.bool,back:h.a.bool,small:h.a.bool,inherit:h.a.bool,caps:h.a.bool,danger:h.a.bool,disabled:h.a.bool},v.defaultProps={dangerouslySetInnerHTML:void 0,onClick:null,href:"",className:"",arrow:!1,external:!1,inverse:!1,back:!1,small:!1,inherit:!1,caps:!1,danger:!1,disabled:!1},t.a=v}).call(this,n(12))},29:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return l})),n.d(t,"b",(function(){return u})),n.d(t,"a",(function(){return d})),n.d(t,"c",(function(){return g}));var a=n(33),r=n.n(a),i=n(13),o=n(40),c=n(56),s=function(){e._googlesitekitLegacyData.admin=e._googlesitekitLegacyData.admin||{},"string"==typeof e._googlesitekitLegacyData.admin.datacache&&(e._googlesitekitLegacyData.admin.datacache=JSON.parse(e._googlesitekitLegacyData.admin.datacache)),"object"!==r()(e._googlesitekitLegacyData.admin.datacache)&&(e._googlesitekitLegacyData.admin.datacache={})},l=function(t,n){if(void 0!==n&&(!n||"object"!==r()(n)||!n.error&&!n.errors)){s(),e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(n);var a={value:n,date:Date.now()/1e3};Object(o.a)().setItem("googlesitekit_"+t,JSON.stringify(a))}},u=function(t,n){if(!e._googlesitekitLegacyData.admin.nojscache){if(s(),void 0!==e._googlesitekitLegacyData.admin.datacache[t])return e._googlesitekitLegacyData.admin.datacache[t];var a=JSON.parse(Object(o.a)().getItem("googlesitekit_"+t));return a&&"object"===r()(a)&&a.date&&(!n||Date.now()/1e3-a.date<n)?(e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(a.value),Object(i.cloneDeep)(e._googlesitekitLegacyData.admin.datacache[t])):void 0}},d=function(t){s(),delete e._googlesitekitLegacyData.admin.datacache[t],Object(o.a)().removeItem("googlesitekit_"+t)},g=function(e,t,n){for(var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],s=0,l=o;s<l.length;s++){var u=l[s];if(!u||!u.length)break;i.push(u)}return 3===i.length&&a&&"object"===r()(a)&&Object.keys(a).length&&i.push(Object(c.a)(a)),i.join("::")}}).call(this,n(15))},30:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(PreviewBlock,t);var n=b(PreviewBlock);function PreviewBlock(){return r()(this,PreviewBlock),n.apply(this,arguments)}return o()(PreviewBlock,[{key:"render",value:function(){var t=this.props,n=t.width,a=t.height,r=t.shape,i=t.padding;return e.createElement("div",{className:y()("googlesitekit-preview-block",{"googlesitekit-preview-block--padding":i}),style:{width:n,height:a}},e.createElement("div",{className:y()("googlesitekit-preview-block__wrapper",{"googlesitekit-preview-block__wrapper--circle":"circular"===r})}))}}]),PreviewBlock}(f.a);v.propTypes={width:h.a.string,height:h.a.string,shape:h.a.string,padding:h.a.bool},v.defaultProps={width:"100px",height:"100px",shape:"square",padding:!1},t.a=v}).call(this,n(12))},31:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(22),s=n.n(c),l=n(8),u=n.n(l),d=n(9),g=n.n(d),f=n(3),p=n.n(f),h=n(1),m=n(2),y=n.n(m),b=n(18),v=n.n(b),_=n(123),k=n(60),O=n(80);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var r=p()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return g()(this,n)}}var E=function(t){u()(DataBlock,t);var n=D(DataBlock);function DataBlock(e){var t;return r()(this,DataBlock),(t=n.call(this,e)).handleClick=t.handleClick.bind(s()(t)),t.handleKeyPress=t.handleKeyPress.bind(s()(t)),t}return o()(DataBlock,[{key:"handleClick",value:function(){var e=this.props,t=e.stat;(0,e.handleStatSelection)(t)}},{key:"handleKeyPress",value:function(e){e.preventDefault();var t=this.props,n=t.stat,a=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||a(n)}},{key:"render",value:function(){var t=this.props,n=t.className,a=t.title,r=t.datapoint,i=t.datapointUnit,o=t.change,c=t.changeDataUnit,s=t.context,l=t.period,u=t.selected,d=t.handleStatSelection,g=t.source,f=t.sparkline,p=t.invertChangeColor,m="button"===s?"button":"",y=f;return y&&p&&(y=Object(h.d)(f,{invertChangeColor:p})),e.createElement("div",{className:v()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":u}),tabIndex:"button"===s?"0":"-1",role:d&&m,onClick:d&&this.handleClick,onKeyPress:d&&this.handleKeyPress,"aria-label":d&&a,"aria-pressed":d&&u},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},a),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(r).concat(i))),y&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},y),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===o&&e.createElement(h.b,null," "),o&&e.createElement(h.b,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(_.a,{direction:0<parseFloat(o)?"up":"down",invertColor:p})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(k.b)(Math.abs(o))).concat(c," ").concat(l)))),g&&e.createElement(O.a,{className:"googlesitekit-data-block__source",name:g.name,href:g.link})))}}]),DataBlock}(h.a);E.propTypes={stat:y.a.number,onClick:y.a.func,className:y.a.string,title:y.a.string,datapoint:y.a.oneOfType([y.a.string,y.a.number]),datapointUnit:y.a.string,change:y.a.oneOfType([y.a.string,y.a.number]),changeDataUnit:y.a.string,context:y.a.string,period:y.a.string,selected:y.a.bool,handleStatSelection:y.a.func,invertChangeColor:y.a.bool},E.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=E}).call(this,n(12))},34:function(e,t,n){"use strict";(function(e,a){n(1);var r=n(2),i=n.n(r),o=n(18),c=n.n(o),s=function SvgIcon(t){var n=t.id,r=t.className,i=t.height,o=t.width,s="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return a.createElement("svg",{className:c()("svg",r),height:i,width:o},a.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:i.a.string.isRequired,className:i.a.string,height:i.a.string,width:i.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(15),n(12))},37:function(e,t,n){"use strict";(function(e){var a=n(10),r=n.n(a),i=n(4),o=n.n(i),c=n(14),s=n.n(c),l=n(6),u=n.n(l),d=n(7),g=n.n(d),f=n(22),p=n.n(f),h=n(8),m=n.n(h),y=n(9),b=n.n(y),v=n(3),_=n.n(v),k=n(1),O=n(2),D=n.n(O),E=n(18),S=n.n(E),j=n(13),w=n(34),R=n(54),A=n(29),C=n(31),N=n(47),P=n(119),x=n(124),T=n(28);function L(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=_()(e);if(t){var r=_()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return b()(this,n)}}var I=function(t){m()(Notification,t);var n,a,i=L(Notification);function Notification(e){var t;return u()(this,Notification),(t=i.call(this,e)).state={isClosed:!1},t.cardRef=Object(k.h)(),t.handleDismiss=t.handleDismiss.bind(p()(t)),t.handleCTAClick=t.handleCTAClick.bind(p()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&Object(A.e)("notification::displayed::".concat(t.props.id),new Date),t}return g()(Notification,[{key:"handleDismiss",value:(a=s()(o.a.mark((function e(t){var n;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),t.preventDefault(),!(n=this.props.onDismiss)){e.next=6;break}return e.next=6,n(t);case 6:this.dismiss();case 7:case"end":return e.stop()}}),e,this)}))),function(e){return a.apply(this,arguments)})},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){Object(A.e)("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:(n=s()(o.a.mark((function e(t){var n,a,r;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),n=this.props,a=n.isDismissable,!(r=n.onCTAClick)){e.next=5;break}return e.next=5,r(t);case 5:a&&this.dismiss();case 6:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,a=Object(A.b)("notification::dismissed::".concat(t));if(a){var r=new Date(a);r.setSeconds(r.getSeconds()+parseInt(n,10)),r<new Date&&Object(A.a)("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,a=this.props,i=a.children,o=a.id,c=a.title,s=a.description,l=a.blockData,u=a.winImage,d=a.smallImage,g=a.format,f=a.learnMoreURL,p=a.learnMoreDescription,h=a.learnMoreLabel,m=a.ctaLink,y=a.ctaLabel,b=a.ctaTarget,v=a.type,_=a.dismiss,O=a.isDismissable,D=a.logo,E=a.module,L=a.moduleName,I=a.pageIndex,W=a.anchorLink,M=a.anchorLinkLabel;if(Object(A.b)("notification::dismissed::".concat(o)))return null;var U,q=n?"is-closed":"is-open",F="large"===g&&"win-stats-increase"===v,H="mdc-layout-grid__cell--span-12";"large"===g?(H="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-6-tablet mdc-layout-grid__cell--span-8-desktop ",F&&(H="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-8-desktop ")):"small"===g&&(H="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),U="win-warning"===v?e.createElement(P.a,null):"win-error"===v?e.createElement(x.a,null):"";var G=e.createElement(k.b,null,l&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(j.map)(l,(function(t,n){return e.createElement("div",{key:n,className:S()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":F,"mdc-layout-grid__cell--span-4-desktop":!F})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(C.a,t)))})))),B=e.createElement(k.b,null,c&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},c),W&&M&&e.createElement("p",{className:"googlesitekit-publisher-win__link"},e.createElement(T.a,{href:W},M)),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(k.i)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(R.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),h&&e.createElement(k.b,null," ",e.createElement(T.a,{href:f,external:!0,inherit:!0},h),p),I&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},I))),i),z=E?e.createElement(w.a,{id:E,height:"19",width:"19"}):e.createElement(w.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:S()("googlesitekit-publisher-win",(t={},r()(t,"googlesitekit-publisher-win--".concat(g),g),r()(t,"googlesitekit-publisher-win--".concat(v),v),r()(t,"googlesitekit-publisher-win--".concat(q),q),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},D&&e.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":F,"mdc-layout-grid__cell--order-1-tablet":F})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},z),L&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},L)),d&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("img",{className:"googlesitekit-publisher-win__small-image",alt:"",src:d})),e.createElement("div",{className:S()("mdc-layout-grid__cell",H)},F?e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-5-desktop mdc-layout-grid__cell--span-8-tablet"},B),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--align-bottom"},G)):e.createElement(k.b,null,B,G),m&&e.createElement(N.a,{href:m,target:b,onClick:this.handleCTAClick},y),O&&_&&e.createElement(T.a,{onClick:this.handleDismiss},_)),u&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--order-1-phone mdc-layout-grid__cell--order-2-tablet mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement("div",{className:"googlesitekit-publisher-win__image-large"},e.createElement("img",{alt:"",src:u}))),("win-error"===v||"win-warning"===v)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},U)))))}}]),Notification}(k.a);I.propTypes={id:D.a.string.isRequired,title:D.a.string.isRequired,description:D.a.node,learnMoreURL:D.a.string,learnMoreDescription:D.a.string,learnMoreLabel:D.a.string,blockData:D.a.array,winImage:D.a.string,smallImage:D.a.string,format:D.a.string,ctaLink:D.a.string,ctaLabel:D.a.string,type:D.a.string,dismiss:D.a.string,isDismissable:D.a.bool,logo:D.a.bool,module:D.a.string,moduleName:D.a.string,pageIndex:D.a.string,dismissExpires:D.a.number,showOnce:D.a.bool,onCTAClick:D.a.func,onDismiss:D.a.func,anchorLink:D.a.string,anchorLinkLabel:D.a.string},I.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=I}).call(this,n(12))},39:function(e,t,n){"use strict";(function(e,a){n.d(t,"b",(function(){return w})),n.d(t,"a",(function(){return R}));var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(22),l=n.n(s),u=n(8),d=n.n(u),g=n(9),f=n.n(g),p=n(3),h=n.n(p),m=n(10),y=n.n(m),b=n(1),v=n(2),_=n.n(v),k=n(18),O=n.n(k),D=n(13),E=n(80),S=n(28);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=h()(e);if(t){var r=h()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return f()(this,n)}}var w=function(t,n,a){var r=[],i=a.links,o=a.source,c=a.showURLs;a.cap&&(t=t.slice(0,a.cap)),Object(D.each)(t,(function(t,n){var o=[],s=i&&i[n];Object(D.each)(t,(function(n,r){"string"==typeof n&&(n=n.replace(/\(none\)/gi,"direct"));var i=a&&a.hideColumns&&a.hideColumns.mobile.includes(r);o.push(e.createElement("td",{key:"cell-"+r,className:O()("googlesitekit-table__body-item",{"hidden-on-mobile":i})},t[0]===n&&s?e.createElement("div",{className:"googlesitekit-table__body-item-content"},e.createElement(S.a,{className:"googlesitekit-table__body-item-link",href:s,external:!0,inherit:!0},n),c&&e.createElement(S.a,{className:"googlesitekit-table__body-item-url",href:s,inherit:!0,external:!0},s)):e.createElement("div",{className:"googlesitekit-table__body-item-content"},n)))})),r.push(e.createElement("tr",{key:"tr-"+n,className:"googlesitekit-table__body-row"},o))}));var s=t&&t[0]&&t[0].length?t[0].length:1,l=a.hideColumns&&a.hideColumns.mobile&&a.hideColumns.mobile.length>0?s-a.hideColumns.mobile.length:s;return e.createElement("div",{className:O()("googlesitekit-table",{"googlesitekit-table--with-list":!a||!a.disableListMode})},e.createElement("table",{className:O()("googlesitekit-table__wrapper","googlesitekit-table__wrapper--".concat(s,"-col"),y()({},"googlesitekit-table__wrapper--mobile-".concat(l,"-col"),l!==s))},e.createElement("thead",{className:"googlesitekit-table__head"},e.createElement("tr",{key:"gksc_data_row_header-wrap",style:a&&a.hideHeader?{display:"none"}:{},className:"googlesitekit-table__head-row"},n.map((function(t,n){var r=a&&a.hideColumns&&a.hideColumns.mobile.includes(n);return e.createElement("th",{key:"gksc_data_row_header-".concat(n),className:O()("googlesitekit-table__head-item",{"googlesitekit-table__head-item--primary":t.primary},{"hidden-on-mobile":r}),"data-tooltip":t.tooltip},t.title)})))),e.createElement("tbody",{className:"googlesitekit-table__body"},r)),o&&e.createElement(E.a,{className:"googlesitekit-table__source",name:o.name,href:o.link}))},R=function(t){d()(TableOverflowContainer,t);var n=j(TableOverflowContainer);function TableOverflowContainer(){var e;return i()(this,TableOverflowContainer),(e=n.call(this)).state={isScrolling:!1},e.scrollRef=Object(b.h)(),e.updateFadeOnScroll=e.updateFadeOnScroll.bind(l()(e)),e}return c()(TableOverflowContainer,[{key:"componentDidMount",value:function(){var e=this;e.updateFadeOnScroll(),this.resize=Object(D.debounce)((function(){e.updateFadeOnScroll()}),100),a.addEventListener("resize",this.resize)}},{key:"componentWillUnmount",value:function(){a.removeEventListener("resize",this.resize)}},{key:"updateFadeOnScroll",value:function(){var e=this.scrollRef.current,t=e.scrollLeft,n=e.scrollWidth-e.offsetWidth,a=t<n-16&&0<n-16;this.setState({isScrolling:a})}},{key:"render",value:function(){var t=this.props.children,n=this.state.isScrolling;return e.createElement("div",{onScroll:Object(D.debounce)(this.updateFadeOnScroll,100),className:O()("googlesitekit-table-overflow",{"googlesitekit-table-overflow--gradient":n})},e.createElement("div",{ref:this.scrollRef,className:"googlesitekit-table-overflow__container"},t))}}]),TableOverflowContainer}(b.a);R.propTypes={children:_.a.element}}).call(this,n(12),n(15))},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return u}));var a,r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=function(t){var n=e[t];if(!n)return!1;try{var a="__storage_test__";return n.setItem(a,a),n.removeItem(a),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},l=function(){function NullStorage(){i()(this,NullStorage)}return c()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),u=function(){return a||(a=s("sessionStorage")?e.sessionStorage:s("localStorage")?e.localStorage:new l),a}}).call(this,n(15))},42:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return y}));var a=n(4),r=n.n(a),i=n(10),o=n.n(i),c=n(19),s=n.n(c),l=n(69),u=n.n(l),d=n(65),g=n(5);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=function(e){return p({},e)},m=function(){return{}},y=function(t){var n,a,i=t.baseName,c=t.controlCallback,l=t.reducerCallback,f=void 0===l?h:l,y=t.argsToParams,b=void 0===y?m:y;s()(i,"baseName is required."),s()("function"==typeof c,"controlCallback is required and must be a function."),s()("function"==typeof f,"reducerCallback must be a function."),s()("function"==typeof b,"argsToParams must be a function.");try{b(),a=!1}catch(e){a=!0}var v=Object(d.b)(i),_=Object(d.a)(i),k="FETCH_".concat(_),O="START_".concat(k),D="FINISH_".concat(k),E="CATCH_".concat(k),S="RECEIVE_".concat(_),j="fetch".concat(v),w="receive".concat(v),R="isFetching".concat(v),A=o()({},R,{}),C=(n={},o()(n,j,r.a.mark((function t(){var n,a,i,o=arguments;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:t.prev=0,i=b.apply(void 0,o),t.next=9;break;case 4:return t.prev=4,t.t0=t.catch(0),e.console.error(t.t0.message),a=t.t0,t.abrupt("return",{response:n,error:a});case 9:return t.next=11,{payload:{params:i},type:O};case 11:return t.prev=11,t.next=14,{payload:{params:i},type:k};case 14:return n=t.sent,t.next=17,C[w](n,i);case 17:return t.next=19,{payload:{params:i},type:D};case 19:t.next=26;break;case 21:return t.prev=21,t.t1=t.catch(11),a=t.t1,t.next=26,{payload:{error:a,params:i},type:E};case 26:return t.abrupt("return",{response:n,error:a});case 27:case"end":return t.stop()}}),t,null,[[0,4],[11,21]])}))),o()(n,w,(function(e,t){return s()(void 0!==e,"response is required."),a?s()(u()(t),"params is required."):t={},{payload:{response:e,params:t},type:S}})),n),N=o()({},k,(function(e){var t=e.payload;return c(t.params)})),P=o()({},R,(function(e){if(void 0===e[R])return!1;var t;try{for(var n=arguments.length,a=new Array(n>1?n-1:0),r=1;r<n;r++)a[r-1]=arguments[r];t=b.apply(void 0,a)}catch(e){return!1}return!!e[R][Object(g.v)(t)]}));return{INITIAL_STATE:A,actions:C,controls:N,reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case O:var r=a.params;return p(p({},e),{},o()({},R,p(p({},e[R]),{},o()({},Object(g.v)(r),!0))));case S:var i=a.response,c=a.params;return f(e,i,c);case D:var s=a.params;return p(p({},e),{},o()({},R,p(p({},e[R]),{},o()({},Object(g.v)(s),!1))));case E:var l=a.error,u=a.params;return p(p({},e),{},o()({error:l},R,p(p({},e[R]),{},o()({},Object(g.v)(u),!1))));default:return p({},e)}},resolvers:{},selectors:P}}}).call(this,n(15))},43:function(e,t,n){"use strict";var a=n(78),r=n.n(a);n.d(t,"k",(function(){return r.a})),n.d(t,"a",(function(){return a.HelperText})),n.d(t,"b",(function(){return a.Input}));var i=n(134);n.d(t,"g",(function(){return i.a}));var o=n(221);n.d(t,"e",(function(){return o.a}));var c=n(99),s=n.n(c);n.d(t,"j",(function(){return s.a})),n.d(t,"i",(function(){return c.Option}));var l=n(220);n.d(t,"h",(function(){return l.a}));var u=n(219);n.d(t,"d",(function(){return u.a}));var d=n(218);n.d(t,"c",(function(){return d.a}));var g=n(217);n.d(t,"f",(function(){return g.a}))},46:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(28);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(CTA,t);var n=v(CTA);function CTA(){return r()(this,CTA),n.apply(this,arguments)}return o()(CTA,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.description,r=t.ctaLink,i=t.ctaLabel,o=t.error,c=t.onClick;return e.createElement("div",{className:y()("googlesitekit-cta",{"googlesitekit-cta--error":o})},n&&e.createElement("h3",{className:"googlesitekit-cta__title"},n),a&&"string"==typeof a&&e.createElement("p",{className:"googlesitekit-cta__description"},a),a&&"string"!=typeof a&&e.createElement("div",{className:"googlesitekit-cta__description"},a),i&&e.createElement(b.a,{href:r,onClick:c,inverse:!o,caps:!0,arrow:!0},i))}}]),CTA}(f.a);_.propTypes={title:h.a.string.isRequired,description:h.a.oneOfType([h.a.string,h.a.node]),ctaLink:h.a.string,ctaLabel:h.a.string,error:h.a.bool,onClick:h.a.func},_.defaultProps={title:"",description:"",ctaLink:"",ctaLabel:"",error:!1,onClick:function(){}},t.a=_}).call(this,n(12))},47:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(43);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(Button,t);var n=v(Button);function Button(e){var t;return r()(this,Button),(t=n.call(this,e)).buttonRef=Object(f.h)(),t}return o()(Button,[{key:"componentDidMount",value:function(){new b.g(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,a=t.children,r=t.href,i=t.text,o=t.className,c=t.danger,s=t.disabled,l=t.target,u=t.id,d=t.icon,g=t.trailingIcon,f=t.ariaHaspopup,p=t.ariaExpanded,h=t.ariaControls,m=r&&!s?"a":"button";return e.createElement(m,{className:y()("mdc-button",o,{"mdc-button--raised":!i,"mdc-button--danger":c}),onClick:n,href:s?void 0:r,ref:this.buttonRef,disabled:!!s,target:l||"_self",id:u,"aria-haspopup":f,"aria-expanded":p,"aria-controls":h,role:"a"===m?"button":void 0},d&&d,e.createElement("span",{className:"mdc-button__label"},a),g&&g)}}]),Button}(f.a);_.propTypes={onClick:h.a.func,children:h.a.string.isRequired,href:h.a.string,text:h.a.bool,className:h.a.string,danger:h.a.bool,disabled:h.a.bool,icon:h.a.element,trailingIcon:h.a.element,ariaHaspopup:h.a.string,ariaExpanded:h.a.bool,ariaControls:h.a.string},_.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=_}).call(this,n(12))},49:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(ProgressBar,t);var n=b(ProgressBar);function ProgressBar(){return r()(this,ProgressBar),n.apply(this,arguments)}return o()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,a=t.small,r=t.compress,i=t.height,o=i?Math.round(i/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:o,marginBottom:o},className:y()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":a,"mdc-linear-progress--compress":r})},e.createElement("div",{className:"mdc-linear-progress__buffering-dots"}),e.createElement("div",{className:"mdc-linear-progress__buffer"}),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})))}}]),ProgressBar}(f.a);v.propTypes={className:h.a.string,small:h.a.bool,compress:h.a.bool},v.defaultProps={className:"",small:!1,compress:!1},t.a=v}).call(this,n(12))},5:function(e,t,n){"use strict";(function(e,a){n.d(t,"s",(function(){return A})),n.d(t,"q",(function(){return C})),n.d(t,"n",(function(){return P})),n.d(t,"r",(function(){return x})),n.d(t,"h",(function(){return T})),n.d(t,"c",(function(){return L})),n.d(t,"f",(function(){return I})),n.d(t,"j",(function(){return W})),n.d(t,"l",(function(){return M})),n.d(t,"m",(function(){return U})),n.d(t,"x",(function(){return q})),n.d(t,"b",(function(){return F})),n.d(t,"u",(function(){return H})),n.d(t,"e",(function(){return G})),n.d(t,"p",(function(){return B})),n.d(t,"i",(function(){return z}));var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(10),l=n.n(s),u=n(44),d=n.n(u),g=n(33),f=n.n(g),p=(n(1),n(13)),h=n(16),m=n(0),y=n(45),b=n(142),v=n(34);n.d(t,"a",(function(){return v.a}));var _=n(50);n.d(t,"w",(function(){return _.c}));var k=n(23),O=n(54);n.d(t,"t",(function(){return O.a}));var D=n(56);n.d(t,"v",(function(){return D.a}));var E=n(55);n.d(t,"d",(function(){return E.b})),n.d(t,"k",(function(){return E.c}));n(40);var S=n(60);function j(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function w(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?j(Object(n),!0).forEach((function(t){l()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):j(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return S.a})),n.d(t,"g",(function(){return k.b}));var R=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},A=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(p.isFinite)(e)?e:Number(e),Object(p.isFinite)(e)||(console.warn("Invalid number",e,f()(e)),e=0),t)return C(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in millions.
15
- Object(m.__)("%sM","google-site-kit"),C(R(e),e%10==0?{}:n)):1e4<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
16
- Object(m.__)("%sK","google-site-kit"),C(R(e))):1e3<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
17
- Object(m.__)("%sK","google-site-kit"),C(R(e),e%10==0?{}:n)):e.toString()},C=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,a=void 0===n?N():n,r=d()(t,["locale"]);return new Intl.NumberFormat(a,r).format(e)},N=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(p.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var a=n.match(/^(\w{2})?(_)?(\w{2})/);if(a&&a[0])return a[0].replace(/_/g,"-")}return t.navigator.language},P=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},x=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},T=function(e,t){var n=1e3*P("day"),a=e.getTime(),r=t.getTime();return Math.round(Math.abs(a-r)/n)},L=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},I=function(e,t){return Object(p.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},W=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==f()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:w(w({},e),{},l()({},t,n[t]))}),{}):{}},M=function(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,r=a.admin,i=r.connectURL,o=r.adminRoot,c=a.setup.needReauthenticate,s=W(a)[t].screenID,l="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},u=Object(y.a)(o,w({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},l));if(!c)return u;var d=encodeURIComponent(Object(b.a)(u));return u=o+"?"+d,Object(y.a)(i,{redirect:u,status:n})},U=function(t,n){var a=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=w({page:t},n),Object(y.a)(a,n)},q=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},F=function(){var e=c()(i.a.mark((function e(t,n,a){var r,o,c,s,l=arguments;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=l.length>3&&void 0!==l[3]?l[3]:_.c,o=l.length>4&&void 0!==l[4]?l[4]:W,e.next=4,t.setModuleActive(n,a);case 4:return c=e.sent,(s=o())[n]&&(s[n].active=a),e.next=9,r("".concat(n,"_setup"),a?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",c);case 10:case"end":return e.stop()}}),e)})));return function(t,n,a){return e.apply(this,arguments)}}(),H=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(k.b)(e,t),1)},G=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(p.unescape)(t)};function B(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var c=a.createElement(v.a,{id:t,width:r,height:i,className:o});return n?c=a.createElement(v.a,{id:"".concat(t,"-disabled"),width:r,height:i,className:o}):"pagespeed-insights"===t&&(c=a.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:r,alt:"",className:o})),c}}function z(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,a=n.blogPrefix,r=n.isNetworkMode;return r?t:a+t}}).call(this,n(15),n(12))},51:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(30);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(PreviewTable,t);var n=v(PreviewTable);function PreviewTable(){return r()(this,PreviewTable),n.apply(this,arguments)}return o()(PreviewTable,[{key:"render",value:function(){for(var t=this.props,n=t.rows,a=t.rowHeight,r=t.padding,i=[],o=0;n>o;o++)i.push(e.createElement("div",{className:"googlesitekit-preview-table__row",key:"table-row-"+o},e.createElement(b.a,{width:"100%",height:a+"px"})));return e.createElement("div",{className:y()("googlesitekit-preview-table",{"googlesitekit-preview-table--padding":r})},i)}}]),PreviewTable}(f.a);_.propTypes={rows:h.a.number,rowHeight:h.a.number,padding:h.a.bool},_.defaultProps={rows:11,rowHeight:35,padding:!1},t.a=_}).call(this,n(12))},53:function(e,t,n){"use strict";n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var a=n(13),r=n(5);function i(e){var t=[[{type:"string",label:"Day"},{type:"number",label:"Clicks"},{type:"number",label:"Impressions"},{type:"number",label:"CTR"},{type:"number",label:"Position"}]],n=0,i=0,o=0,c=0,s=e.length;Object(a.each)(e,(function(e){var a=new Date(e.keys[0]);t.push([a.getMonth()+1+"/"+a.getUTCDate(),e.clicks,e.impressions,e.ctr,e.position]),n+=e.clicks,i+=e.impressions,o+=e.ctr,c+=e.position}));var l=n,u=i;n=Object(r.s)(n),i=Object(r.s)(i);var d=s>0?(o/s*100).toFixed(1):"0.0",g=s>0?o/s:0,f=s>0?(c/s).toFixed(1):"0.0";return{dataMap:t,totalClicks:n,totalClicksRaw:l,totalImpressions:i,totalImpressionsRaw:u,averageCTR:d,averageCTRRaw:g,averagePosition:f}}var o=function(e){var t=Math.floor(e.length/2),n=i(e.slice(t)),a=i(e.slice(0,t));return{dataMap:n.dataMap,totalClicks:n.totalClicks,totalImpressions:n.totalImpressions,averageCTR:n.averageCTR,averagePosition:n.averagePosition,totalClicksChange:Object(r.c)(a.totalClicksRaw,n.totalClicksRaw),totalImpressionsChange:Object(r.c)(a.totalImpressionsRaw,n.totalImpressionsRaw),averageCTRChange:Object(r.c)(a.averageCTRRaw,n.averageCTRRaw),averagePositionChange:Object(r.c)(a.averagePosition,n.averagePosition)}},c=function(e){if(!e.length)return!0;var t=o(e),n=t.totalClicks,a=t.totalImpressions,r=t.averageCTR,i=t.averagePosition;return 0===parseInt(n,10)&&0===parseInt(a,10)&&0===parseInt(r,10)&&0===parseInt(i,10)}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var a=n(76),r=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:a.a.sanitize(e,t)}}},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var a=n(33),r=n.n(a),i=n(102),o=n.n(i),c=function(e){return o()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(a){var i=t[a];i&&"object"===r()(i)&&!Array.isArray(i)&&(i=e(i)),n[a]=i})),n}(e)))}},57:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p);function m(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var y=function(t){s()(DashboardModuleHeader,t);var n=m(DashboardModuleHeader);function DashboardModuleHeader(){return r()(this,DashboardModuleHeader),n.apply(this,arguments)}return o()(DashboardModuleHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.description;return e.createElement("header",{className:"googlesitekit-dashboard-module-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-4-phone "},e.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-dashboard-module-header__title "},n),a&&e.createElement("p",{className:"googlesitekit-dashboard-module-header__description"},a))))}}]),DashboardModuleHeader}(f.a);y.propTypes={title:h.a.string,description:h.a.string},y.defaultProps={title:"",description:""},t.a=y}).call(this,n(12))},59:function(e,t,n){"use strict";n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return l}));var a=n(0),r=n(11),i=n.n(r),o=n(20);function c(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s(),t=e.match(/last-(\d+)-days/);if(t&&t[1])return Object(a.sprintf)(
18
- /* translators: %s: Number of days matched. */
19
- Object(a._n)("%s day","%s days",parseInt(t[1],10),"google-site-kit"),t[1]);throw new Error("Unrecognized date range slug.")}function s(){return i.a.select(o.c).getDateRange()}function l(){
20
- /* translators: %s: Number of days to request data. */
21
- var e=Object(a.__)("Last %s days","google-site-kit");return{"last-7-days":{slug:"last-7-days",label:Object(a.sprintf)(e,7)},"last-14-days":{slug:"last-14-days",label:Object(a.sprintf)(e,14)},"last-28-days":{slug:"last-28-days",label:Object(a.sprintf)(e,28)},"last-90-days":{slug:"last-90-days",label:Object(a.sprintf)(e,90)}}}},60:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return s}));var a=n(44),r=n.n(a),i=n(13),o=n(0);function c(){Object(o.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,a=void 0===n?l():n,i=r()(t,["locale"]);return new Intl.NumberFormat(a,i).format(e)},l=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(i.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var a=n.match(/^(\w{2})?(_)?(\w{2})/);if(a&&a[0])return a[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(15))},61:function(e,t,n){"use strict";n.d(t,"e",(function(){return g})),n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return p}));var a=n(4),r=n.n(a),i=n(14),o=n.n(i),c=n(13),s=n(5),l=n(21),u=n(17),d=(n(132),n(82),n(105));n.d(t,"c",(function(){return d.a})),n.d(t,"d",(function(){return d.b}));n(116);function g(e){var t=[[{type:"date",label:"Day"},{type:"number",label:"RPM"},{type:"number",label:"Earnings"},{type:"number",label:"Impressions"}]];return Object(c.each)(e,(function(e){var n=new Date(e[0]);t.push([n,e[2],e[1],e[3]])})),{dataMap:t}}var f=function(){var e=o()(r.a.mark((function e(){var t,n,a,i;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=Object(s.j)(),n=t.adsense.active,a=t.analytics.active,i=!0,!n||!a){e.next=7;break}return e.next=7,u.c.get(u.b,"analytics","report",l.a).then((function(e){e&&(i=!0)})).catch((function(e){400===e.code&&"INVALID_ARGUMENT"===e.message&&(i=!1)}));case 7:return e.abrupt("return",new Promise((function(e){e(i)})));case 8:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}}(),p=function(e,t,n){if(!n.data||!n.data.dateRange||"last-28-days"!==n.data.dateRange)return!1;var a=[];return e.totals&&(a=e.totals),0===(a=a.filter((function(e){return 0<e}))).length}},63:function(e,t,n){"use strict";(function(e){var a=n(26),r=n.n(a),i=n(106),o=e._googlesitekitAPIFetchData||{},c=o.nonce,s=o.nonceEndpoint,l=o.preloadedData,u=o.rootURL;r.a.nonceEndpoint=s,r.a.nonceMiddleware=r.a.createNonceMiddleware(c),r.a.rootURLMiddleware=r.a.createRootURLMiddleware(u),r.a.preloadingMiddleware=Object(i.a)(l),r.a.use(r.a.nonceMiddleware),r.a.use(r.a.mediaUploadMiddleware),r.a.use(r.a.rootURLMiddleware),r.a.use(r.a.preloadingMiddleware),t.default=r.a}).call(this,n(15))},64:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(164),y=n(75);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(Sparkline,t);var n=b(Sparkline);function Sparkline(){return r()(this,Sparkline),n.apply(this,arguments)}return o()(Sparkline,[{key:"render",value:function(){var t=this.props,n=t.data,a=t.change,r=t.instanceId,i=t.invertChangeColor,o=t.loadSmall,c=t.loadCompressed,s=t.loadHeight,l=t.loadText;if(!n)return"loading...";var u=i?"red":"green",d=i?"green":"red",g={title:"",backgroundColor:"transparent",curveType:"line",width:"100%",height:"50",enableInteractivity:!1,chartArea:{height:"100%",width:"100%"},legend:{position:"none"},axisFontSize:0,hAxis:{baselineColor:"none",ticks:[]},vAxis:{baselineColor:"none",ticks:[]},axes:[],colors:[0<=(parseFloat(a)||0)?u:d]};return e.createElement("div",{className:"googlesitekit-analytics-sparkline-chart-wrap"},e.createElement(y.a,{data:n,options:g,id:"googlesitekit-sparkline-".concat(r),loadSmall:o,loadCompressed:c,loadHeight:s,loadText:l}))}}]),Sparkline}(f.a);v.propTypes={instanceId:h.a.number.isRequired,invertChangeColor:h.a.bool,loadSmall:h.a.bool,loadCompressed:h.a.bool,loadHeight:h.a.number,loadText:h.a.bool},v.defaultProps={invertChangeColor:!1,loadSmall:!0,loadCompressed:!0,loadHeight:46,loadText:!1},t.a=Object(m.a)(v)}).call(this,n(12))},649:function(e,t,n){"use strict";n.r(t),function(e,a){n.d(t,"GoogleSitekitAdminbar",(function(){return w})),n.d(t,"init",(function(){return R}));var r=n(4),i=n.n(r),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),g=n(22),f=n.n(g),p=n(8),h=n.n(p),m=n(9),y=n.n(m),b=n(3),v=n.n(b),_=n(1),k=(n(243),n(0)),O=n(5),D=n(28),E=n(659),S=n(136);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=v()(e);if(t){var r=v()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return y()(this,n)}}var w=function(t){h()(GoogleSitekitAdminbar,t);var n,r=j(GoogleSitekitAdminbar);function GoogleSitekitAdminbar(e){var t;return l()(this,GoogleSitekitAdminbar),(t=r.call(this,e)).handleMoreDetailsLink=t.handleMoreDetailsLink.bind(f()(t)),t}return d()(GoogleSitekitAdminbar,[{key:"handleMoreDetailsLink",value:(n=c()(i.a.mark((function t(){var n,a,r,o,c,s;return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=e._googlesitekitLegacyData,a=n.permaLink,r=n.postID,o=n.postType,c=n.pageTitle,s=Object(O.m)("googlesitekit-dashboard",{permaLink:a,id:r,postType:o,pageTitle:c}),t.next=4,Object(O.w)("admin_bar","post_details_click");case 4:document.location=s;case 5:case"end":return t.stop()}}),t)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData,n=t.pageTitle,r=t.permaLink;return a.createElement(_.b,null,a.createElement("div",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-3 mdc-layout-grid__cell--align-middle "},a.createElement("div",{className:"googlesitekit-adminbar__subtitle"},Object(k.__)("Stats for","google-site-kit")),a.createElement("div",{className:"googlesitekit-adminbar__title"},n?Object(O.e)(n):r)),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--align-middle "},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement(E.a,null))),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2 mdc-layout-grid__cell--align-middle "},a.createElement(D.a,{className:"googlesitekit-adminbar__link",href:"#",onClick:this.handleMoreDetailsLink},Object(k.__)("More details","google-site-kit"))))),a.createElement(D.a,{className:"googlesitekit-adminbar__link googlesitekit-adminbar__link--mobile",href:"#",onClick:this.handleMoreDetailsLink},Object(k.__)("More details","google-site-kit")))}}]),GoogleSitekitAdminbar}(_.a);function R(){var e=document.getElementById("js-googlesitekit-adminbar-modules");e&&(Object(O.o)(),Object(_.k)(a.createElement(S.a,{dataAPIContext:"Adminbar"},a.createElement(w,null)),e))}}.call(this,n(15),n(12))},65:function(e,t,n){"use strict";n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return r}));var a=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},r=function(e){return e.replace(/([a-z0-9]{1})([A-Z]{1})/g,"$1_$2").toUpperCase()}},659:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(83);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var m=function(t){s()(AdminbarModules,t);var n=h(AdminbarModules);function AdminbarModules(){return r()(this,AdminbarModules),n.apply(this,arguments)}return o()(AdminbarModules,[{key:"render",value:function(){return e.createElement(f.b,null)}}]),AdminbarModules}(f.a);t.a=Object(p.a)("googlesitekit.AdminbarModules")(m)}).call(this,n(12))},70:function(e,t,n){"use strict";n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return r}));var a="core",r="modules"},72:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return p})),n.d(t,"d",(function(){return h})),n.d(t,"a",(function(){return m})),n.d(t,"c",(function(){return y}));var a=n(4),r=n.n(a),i=n(14),o=n.n(i);n(71);function c(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var a=0,r=function(){};return{s:r,n:function(){return a>=e.length?{done:!0}:{done:!1,value:e[a++]}},e:function(e){throw e},f:r}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}var l,u=["sessionStorage","localStorage"],d=[].concat(u),g=function(){var t=o()(r.a.mark((function t(n){var a,i;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,i="__storage_test__",a.setItem(i,i),a.removeItem(i),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==a.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),f=function(){var t=o()(r.a.mark((function t(){var n,a,i;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==l){t.next=25;break}n=c(d),t.prev=4,n.s();case 6:if((a=n.n()).done){t.next=16;break}if(i=a.value,!l){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,g(i);case 12:if(!t.sent){t.next=14;break}l=e[i];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===l&&(l=null);case 25:return t.abrupt("return",l);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),p=function(){var e=o()(r.a.mark((function e(t){var n,a,i,o,c=arguments;return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=c.length>1&&void 0!==c[1]?c[1]:null,e.next=3,f();case 3:if(!(a=e.sent)){e.next=10;break}if(!(i=a.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(o=JSON.parse(i)).timestamp||!(null===n||Math.round(Date.now()/1e3)-o.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:o.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),h=function(){var t=o()(r.a.mark((function t(n,a){var i,o,c=arguments;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=c.length>2&&void 0!==c[2]?c[2]:void 0,t.next=3,f();case 3:if(!(o=t.sent)){t.next=14;break}return t.prev=5,o.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:i||Math.round(Date.now()/1e3),value:a})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),m=function(){var t=o()(r.a.mark((function t(n){var a;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f();case 2:if(!(a=t.sent)){t.next=13;break}return t.prev=4,a.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),y=function(){var t=o()(r.a.mark((function t(){var n,a,i,o;return r.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,a=[],i=0;i<n.length;i++)0===(o=n.key(i)).indexOf("googlesitekit_")&&a.push(o.substring("googlesitekit_".length));return t.abrupt("return",a);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:case"end":return t.stop()}}),t,null,[[4,10]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(15))},73:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(46),i=n(87);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],s=e.createElement(r.a
22
- /* translators: %s: Module name */,{title:Object(a.sprintf)(Object(a.__)("%s Gathering Data","google-site-kit"),t)
23
- /* translators: %s: Module name */,description:Object(a.sprintf)(Object(a.__)("%s data is not yet available, please check back later.","google-site-kit"),t)});return Object(i.a)(s,n,o,c)}}).call(this,n(12))},74:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(5),i=n(93),o=n(46),c=n(87),s=n(170);t.a=function(t,n){var l,u=arguments.length>2&&void 0!==arguments[2]&&arguments[2],d=arguments.length>3&&void 0!==arguments[3]&&arguments[3],g=arguments.length>4&&void 0!==arguments[4]&&arguments[4],f=arguments.length>5&&void 0!==arguments[5]?arguments[5]:{},p=null==f||null===(l=f.data)||void 0===l?void 0:l.reconnectURL,h=p?e.createElement(i.a,{message:n,reconnectURL:p}):n,m=e.createElement(o.a
24
- /* translators: %s: module name */,{title:Object(a.sprintf)(Object(a.__)("Data error in %s","google-site-kit"),t),description:h,error:!0});return"Invalid Credentials"===n&&Object(r.u)(s.a),Object(c.a)(m,u,d,g)}}).call(this,n(12))},75:function(e,t,n){"use strict";(function(e,a){var r,i=n(4),o=n.n(i),c=n(6),s=n.n(c),l=n(7),u=n.n(l),d=n(22),g=n.n(d),f=n(8),p=n.n(f),h=n(9),m=n.n(h),y=n(3),b=n.n(y),v=n(14),_=n.n(v),k=n(1),O=n(2),D=n.n(O),E=n(0),S=n(13),j=n(49);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=b()(e);if(t){var r=b()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return m()(this,n)}}function R(){return A.apply(this,arguments)}function A(){return(A=_()(o.a.mark((function t(){var n;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!r){t.next=2;break}return t.abrupt("return",r);case 2:return e.google&&e.google.charts?r=Promise.resolve():((n=document.createElement("script")).type="text/javascript",r=new Promise((function(t){n.onload=t,e.document.head.appendChild(n),n.src="https://www.gstatic.com/charts/loader.js"}))),t.abrupt("return",r);case 4:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var C=function(t){p()(GoogleChart,t);var n,r=w(GoogleChart);function GoogleChart(e){var t;return s()(this,GoogleChart),(t=r.call(this,e)).state={loading:!0,chart:null},t.onChartsLoad=t.onChartsLoad.bind(g()(t)),t.waitForChart=t.waitForChart.bind(g()(t)),t.getData=t.getData.bind(g()(t)),t.prepareChart=t.prepareChart.bind(g()(t)),t.drawChart=t.drawChart.bind(g()(t)),t.updateChart=t.updateChart.bind(g()(t)),t.chartRef=Object(k.h)(),t.resize=Object(S.debounce)(t.drawChart,100),t}return u()(GoogleChart,[{key:"onChartsLoad",value:function(){this.getData(),this.prepareChart(),this.drawChart(),this.setState({loading:!1})}},{key:"componentDidMount",value:(n=_()(o.a.mark((function t(){return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,R();case 2:e.google.charts.load("current",{packages:["corechart"]}),e.google.charts.setOnLoadCallback(this.onChartsLoad),e.addEventListener("resize",this.resize);case 5:case"end":return t.stop()}}),t,this)}))),function(){return n.apply(this,arguments)})},{key:"componentDidUpdate",value:function(e){var t=this.props.selectedStats;0!==t.length&&JSON.stringify(t)!==JSON.stringify(e.selectedStats)&&this.updateChart()}},{key:"componentWillUnmount",value:function(){e.removeEventListener("resize",this.resize)}},{key:"waitForChart",value:function(e){setTimeout((function(){e()}),500)}},{key:"getData",value:function(){return e.google&&e.google.visualization&&e.google.visualization.arrayToDataTable(this.props.data)}},{key:"prepareChart",value:function(){var t=this.chartRef.current;if(e.google&&t){var n="pie"===this.props.chartType?new e.google.visualization.PieChart(t):new e.google.visualization.LineChart(t);this.setState({chart:n})}else this.waitForChart(this.prepareChart)}},{key:"drawChart",value:function(){var e=this.state.chart,t=this.props,n=t.selectedStats,a=t.options,r=this.getData();null!==r&&null!==e?(e.draw(r,a),0!==n.length&&this.updateChart()):this.waitForChart(this.drawChart)}},{key:"updateChart",value:function(){var t=this.state.chart,n=this.props,a=n.selectedStats,r=n.options,i=n.singleStat,o=this.getData();if(null!==o&&null!==t){var c=new e.google.visualization.DataView(o);if(!i){var s=[0];s=s.concat(a.map((function(e){return e+1}))),c.setColumns(s)}t.draw(c,r)}else this.waitForChart(this.drawChart)}},{key:"render",value:function(){var e=this.state.loading,t=this.props,n=t.className,r=t.loadSmall,i=t.loadCompressed,o=t.loadHeight,c=t.loadText;return a.createElement("div",{className:"googlesitekit-graph-wrapper"},a.createElement("div",{ref:this.chartRef,className:"googlesitekit-line-chart"},a.createElement("div",{className:"googlesitekit-chart-loading"},e&&a.createElement("div",{className:"googlesitekit-chart-loading__wrapper"},c&&a.createElement("p",null,Object(E.__)("Loading chart…","google-site-kit")),a.createElement(j.a,{className:n,small:r,compress:i,height:o})))))}}]),GoogleChart}(k.a);C.propTypes={selectedStats:D.a.array,options:D.a.object.isRequired,id:D.a.string,singleStat:D.a.bool,className:D.a.string,loadSmall:D.a.bool,loadCompressed:D.a.bool,loadHeight:D.a.number,loadText:D.a.bool},C.defaultProps={selectedStats:[],id:"",singleStat:!0,className:"",loadSmall:!1,loadCompressed:!1,loadHeight:null,loadText:!0},t.a=C}).call(this,n(15),n(12))},76:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return r}));var a=n(101),r=n.n(a)()(e)}).call(this,n(15))},80:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(2),h=n.n(p),m=n(18),y=n.n(m),b=n(0),v=n(28);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var k=function(t){s()(SourceLink,t);var n=_(SourceLink);function SourceLink(){return r()(this,SourceLink),n.apply(this,arguments)}return o()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,a=t.href,r=t.className,i=t.external;return e.createElement("div",{className:y()("googlesitekit-source-link",r)},[Object(b.__)("Source:","google-site-kit")," ",e.createElement(v.a,{key:"link",href:a,external:i,inherit:!0},n)])}}]),SourceLink}(f.a);k.propTypes={name:h.a.string,href:h.a.string,className:h.a.string,external:h.a.bool},k.defaultProps={name:"",href:"",className:"",external:!1},t.a=k}).call(this,n(12))},82:function(e,t,n){"use strict";n.d(t,"e",(function(){return a})),n.d(t,"d",(function(){return r})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"g",(function(){return c})),n.d(t,"f",(function(){return s})),n.d(t,"a",(function(){return l})),n.d(t,"i",(function(){return u})),n.d(t,"h",(function(){return d})),n.d(t,"k",(function(){return g})),n.d(t,"m",(function(){return f})),n.d(t,"j",(function(){return p})),n.d(t,"l",(function(){return h})),n.d(t,"o",(function(){return m})),n.d(t,"n",(function(){return y}));var a="none",r="multiple",i="disapproved",o="graylisted",c="pending",s="no-client",l="approved",u="none",d="added",g=function(e){var t=e.accounts,n=e.clients,i=e.alerts,c=e.error,u=e.previousAccountID,d=e.previousClientID;return void 0===t||void 0===u?b(c):p({accounts:t,previousAccountID:u})?void 0!==n&&void 0!==d?void 0===i?v(c):i.some((function(e){return"GRAYLISTED_PUBLISHER"===e.type}))?o:h({clients:n,previousClientID:d})?l:s:void 0:t.length?r:a},f=function(e){var t=e.urlChannels,n=e.siteURL;if(void 0!==t&&void 0!==n)return t.some((function(e){return 0<=n.indexOf(e.urlPattern)}))?d:u},p=function(e){var t=e.accounts,n=e.previousAccountID;if(void 0!==t&&t.length){if(t.length>1){if(!n)return;return t.reduce((function(e,t){return t.id===n?n:e}),void 0)}return t[0].id}},h=function(e){var t=e.clients,n=e.previousClientID;if(void 0!==t){var a=t.filter((function(e){return"AFC"===e.productCode}));if(a.length){if(a.length>1&&n){var r=a.reduce((function(e,t){return t.id===n?n:e}),"");if(r)return r}return a[0].id}}},m=function(e){return e===o||e===c},y=function(e){return b(e)||v(e)},b=function(e){return _(e,"noAdSenseAccount")?a:_(e,"disapprovedAccount")?i:void 0},v=function(e){if(_(e,"accountPendingReview"))return c},_=function(e,t){return!(!e||!e.data)&&t===e.data.reason}},85:function(e,t,n){"use strict";n.d(t,"a",(function(){return y})),n.d(t,"c",(function(){return v})),n.d(t,"b",(function(){return _}));var a=n(44),r=n.n(a),i=n(10),o=n.n(i),c=n(4),s=n.n(c),l=n(19),u=n.n(l),d=n(11),g=n.n(d),f=n(72);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=g.a.createRegistryControl,y=function(e){var t;u()(e,"storeName is required to create a snapshot store.");var n={},a={deleteSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"DELETE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})),restoreSnapshot:s.a.mark((function e(){var t,n,a,r,i,o,c=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=c.length>0&&void 0!==c[0]?c[0]:{},n=t.clearAfterRestore,a=void 0===n||n,e.next=4,{payload:{},type:"RESTORE_SNAPSHOT"};case 4:if(r=e.sent,i=r.cacheHit,o=r.value,!i){e.next=13;break}return e.next=10,{payload:{snapshot:o},type:"SET_STATE_FROM_SNAPSHOT"};case 10:if(!a){e.next=13;break}return e.next=13,{payload:{},type:"DELETE_SNAPSHOT"};case 13:return e.abrupt("return",i);case 14:case"end":return e.stop()}}),e)})),createSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"CREATE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)}))},i=(t={},o()(t,"DELETE_SNAPSHOT",(function(){return Object(f.a)("datastore::cache::".concat(e))})),o()(t,"CREATE_SNAPSHOT",m((function(t){return function(){return Object(f.d)("datastore::cache::".concat(e),t.stores[e].store.getState())}}))),o()(t,"RESTORE_SNAPSHOT",(function(){return Object(f.b)("datastore::cache::".concat(e),3600)})),t);return{INITIAL_STATE:n,actions:a,controls:i,reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n,t=arguments.length>1?arguments[1]:void 0,a=t.type,i=t.payload;switch(a){case"SET_STATE_FROM_SNAPSHOT":var o=i.snapshot,c=(o.error,r()(o,["error"]));return h({},c);default:return h({},e)}}}},b=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Object.values(e.stores).filter((function(e){return Object.keys(e.getActions()).includes("restoreSnapshot")}))},v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Promise.all(b(e).map((function(e){return e.getActions().createSnapshot()})))},_=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:g.a;return Promise.all(b(e).map((function(e){return e.getActions().restoreSnapshot()})))}},86:function(e,t,n){"use strict";(function(e){var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(1),p=n(18),h=n.n(p),m=n(2),y=n.n(m),b=n(16),v=n(34),_=n(145);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var O=function(t){s()(PageHeader,t);var n=k(PageHeader);function PageHeader(){return r()(this,PageHeader),n.apply(this,arguments)}return o()(PageHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=t.icon,r=t.iconWidth,i=t.iconHeight,o=t.iconID,c=t.className,s=t.status,l=t.statusText,u=t.fullWidth?"\n\t\t\tmdc-layout-grid__cell\n\t\t\tmdc-layout-grid__cell--span-12\n\t\t\t":"\n\t\t\tmdc-layout-grid__cell\n\t\t\tmdc-layout-grid__cell--span-4-phone\n\t\t\tmdc-layout-grid__cell--span-4-tablet\n\t\t\tmdc-layout-grid__cell--span-6-desktop\n\t\t\t",d=Object(b.c)("googlesitekit.showDateRangeSelector-".concat(o),!1),g=!(""===s&&!d);return e.createElement("header",{className:"googlesitekit-page-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:u},a&&e.createElement(v.a,{id:o,height:i,width:r,className:"googlesitekit-page-header__icon"}),e.createElement("h1",{className:h()("googlesitekit-page-header__title",c)},n)),g&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-bottom mdc-layout-grid__cell--align-right-tablet mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement("div",{className:"googlesitekit-page-header__details"},s&&e.createElement("span",{className:h()("googlesitekit-page-header__status","googlesitekit-page-header__status--".concat(s))},l),d&&e.createElement("span",{className:"googlesitekit-page-header__range"},e.createElement(_.a,null))))))}}]),PageHeader}(f.a);O.propTypes={title:y.a.string,icon:y.a.bool,iconID:y.a.string,iconWidth:y.a.string,iconHeight:y.a.string,className:y.a.string,status:y.a.string,statusText:y.a.string,fullWidth:y.a.bool},O.defaultProps={title:"",icon:!1,iconID:"",iconWidth:"",iconHeight:"",className:"googlesitekit-heading-3",status:"",statusText:"",fullWidth:!1},t.a=O}).call(this,n(12))},87:function(e,t,n){"use strict";(function(e){var a=n(1),r=n(27);t.a=function(t){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],i=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return e.createElement(a.b,null,n&&i&&o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(r.a,{fill:!0},e.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))))),n&&!i&&o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(r.a,{fill:!0},e.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))))),n&&i&&!o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},t),n&&!i&&!o&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},t),!n&&!i&&o&&e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},t))),!n&&!i&&!o&&t)}}).call(this,n(12))},89:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),r=n(28);t.a=function HelpLink(){var t=Object(a.__)("Need help?","google-site-kit");return e.createElement(r.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},90:function(e,t,n){"use strict";(function(e,a){var r=n(6),i=n.n(r),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),g=n(3),f=n.n(g),p=n(1),h=n(135),m=n(165),y=n(167);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=f()(e);if(t){var r=f()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return d()(this,n)}}var v=function(t){l()(Header,t);var n=b(Header);function Header(){return i()(this,Header),n.apply(this,arguments)}return c()(Header,[{key:"render",value:function(){var t=e._googlesitekitLegacyData.setup.isAuthenticated;return a.createElement(p.b,null,a.createElement("header",{className:"googlesitekit-header"},a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(h.a,null)),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&a.createElement(m.a,null))))),a.createElement(y.a,null))}}]),Header}(p.a);t.a=v}).call(this,n(15),n(12))},91:function(e,t,n){"use strict";var a=n(6),r=n.n(a),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),g=n.n(d),f=n(83);function p(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=g()(e);if(t){var r=g()(this).constructor;n=Reflect.construct(a,arguments,r)}else n=a.apply(this,arguments);return u()(this,n)}}var h=function(e){s()(ModuleSettingsWarning,e);var t=p(ModuleSettingsWarning);function ModuleSettingsWarning(){return r()(this,ModuleSettingsWarning),t.apply(this,arguments)}return o()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(n(1).a);t.a=Object(f.a)("googlesitekit.ModuleSettingsWarning")(h)},93:function(e,t,n){"use strict";(function(e){n(1);var a=n(2),r=n.n(a),i=n(162),o=n(0),c=n(5);function ErrorText(t){var n=t.message,a=t.reconnectURL;if(!n)return null;var r=Object(o.sprintf)(
25
- /* translators: %s: Error message */
26
- Object(o.__)("Error: %s","google-site-kit"),n);a&&Object(i.a)(a)&&(r=r+" "+Object(o.sprintf)(
27
- /* translators: %s: Reconnect URL */
28
- Object(o.__)('To fix this, <a href="%s">redo the plugin setup</a>.',"google-site-kit"),a));return e.createElement("div",{className:"googlesitekit-error-text"},e.createElement("p",{dangerouslySetInnerHTML:Object(c.t)(r,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})}))}ErrorText.propTypes={message:r.a.string.isRequired,reconnectURL:r.a.string},ErrorText.defaultProps={reconnectURL:""},t.a=ErrorText}).call(this,n(12))},94:function(e,t,n){"use strict";n.d(t,"a",(function(){return d.c}));var a=n(11),r=n.n(a),i=n(4),o=n.n(i),c=n(10),s=n.n(c),l=n(41),u=n.n(l),d=n(20),g=n(42);function f(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?f(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):f(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=r.a.createRegistrySelector,m=Object(g.a)({baseName:"getAuthentication",controlCallback:function(){return u.a.get("core","user","authentication",void 0,{useCache:!1})},reducerCallback:function(e,t){return p(p({},e),{},{authentication:t})}}),y={authentication:void 0},b={getAuthentication:o.a.mark((function e(){var t;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,r.a.commonActions.getRegistry();case 2:if(t=e.sent,(0,t.select)(d.c).getAuthentication()){e.next=7;break}return e.next=7,m.actions.fetchGetAuthentication();case 7:case"end":return e.stop()}}),e)}))},v={getAuthentication:function(e){return e.authentication},hasScope:h((function(e){return function(t,n){var a=e(d.c).getGrantedScopes(t);if(void 0!==a)return a.includes(n)}})),isAuthenticated:h((function(e){return function(){return(e(d.c).getAuthentication()||{}).authenticated}})),getGrantedScopes:h((function(e){return function(){return(e(d.c).getAuthentication()||{}).grantedScopes}})),getRequiredScopes:h((function(e){return function(){return(e(d.c).getAuthentication()||{}).requiredScopes}})),getUnsatisfiedScopes:h((function(e){return function(){return(e(d.c).getAuthentication()||{}).unsatisfiedScopes}})),needsReauthentication:h((function(e){return function(){return(e(d.c).getAuthentication()||{}).needsReauthentication}}))},_=r.a.combineStores(m,{INITIAL_STATE:y,resolvers:b,selectors:v}),k=(_.INITIAL_STATE,_.actions,_.controls,_.reducer,_.resolvers,_.selectors,_),O=n(19),D=n.n(O);function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var j={INITIAL_STATE:{dateRange:"last-28-days"},actions:{setDateRange:function(e){return D()(e,"Date range slug is required."),{type:"SET_DATE_RANGE",payload:{slug:e}}}},controls:{},reducer:function(e,t){var n=t.type,a=t.payload;switch(n){case"SET_DATE_RANGE":return S(S({},e),{},{dateRange:a.slug});default:return S({},e)}},resolvers:{},selectors:{getDateRange:function(e){return e.dateRange}}};function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var A=r.a.createRegistrySelector,C=Object(g.a)({baseName:"disconnect",controlCallback:function(){return u.a.set("core","user","disconnect")},reducerCallback:function(e,t){return R(R({},e),{},{disconnected:t})}}),N={disconnected:void 0},P={disconnect:o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,C.actions.fetchDisconnect();case 2:case"end":return e.stop()}}),e)}))},x={isDoingDisconnect:A((function(e){return function(){return e(d.c).isFetchingDisconnect()}}))},T=r.a.combineStores(C,{INITIAL_STATE:N,actions:P,selectors:x}),L=(T.INITIAL_STATE,T.actions,T.controls,T.reducer,T.resolvers,T.selectors,T);function I(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}var W={INITIAL_STATE:{error:void 0},actions:{},controls:{},reducer:function(e){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?I(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):I(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e)},resolvers:{},selectors:{getError:function(e){return e.error}}},M=n(110),U=Object(M.a)("core","user","notifications",{server:!1}),q=n(121),F=n(122),H=r.a.combineStores(r.a.commonStore,k,j,L,W,U,q.a,F.a);H.INITIAL_STATE,H.actions,H.controls,H.reducer,H.resolvers,H.selectors;r.a.registerStore(d.c,H)},95:function(e,t,n){"use strict";(function(e,a){var r=n(38),i=n.n(r),o=(n(1),n(146)),c=n.n(o),s=n(0),l=n(11),u=n.n(l),d=n(37),g=n(5),f=n(20),p=u.a.useSelect,h={siteverification:"site-verification",webmasters:"search-console"};t.a=function DashboardAuthAlert(){var t,n,r,o,l,u=p((function(e){return e(f.c).getUnsatisfiedScopes()})),m=p((function(t){return t(f.c).getConnectURL({redirectURL:e.location.href})}));if(void 0===u||void 0===m)return null;switch(u.some((function(e){return!e.match(/^https:\/\/www.googleapis.com\/auth\//)}))?t="generic":(r=u,o=Object(g.j)(),t=(n=r.map((function(e){return e.match(/^https:\/\/www.googleapis.com\/auth\/([a-z]+)/)})).map((function(e){var t=i()(e,2)[1];return h[t]||t})).map((function(e){var t;return(null===(t=o[e])||void 0===t?void 0:t.name)||!1}))).some((function(e){return!1===e}))?"generic":1<(n=c()(n)).length?"multiple":"single"),t){case"multiple":
29
- /* translators: used between list items, there is a space after the comma. */
30
- var y=Object(s.__)(", ","google-site-kit");l=Object(s.sprintf)(
31
- /* translators: %s: List of product names */
32
- Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for: %s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n.join(y));break;case"single":l=Object(s.sprintf)(
33
- /* translators: %1$s: Product name */
34
- Object(s.__)("Site Kit can’t access the relevant data from %1$s because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for %1$s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n[0]);break;case"generic":l=Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup – make sure to approve all permissions at the authentication stage.","google-site-kit")}return a.createElement(d.a,{id:"authentication error",title:Object(s.__)("Site Kit can’t access necessary data","google-site-kit"),description:l,format:"small",type:"win-error",isDismissable:!1,ctaLink:m,ctaLabel:Object(s.__)("Redo setup","google-site-kit")})}}).call(this,n(15),n(12))},97:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var a=n(40),r=n(29),i=function(t,n,i){var o=Object(r.c)(t,n,i);Object(r.d)(),Object.keys(e._googlesitekitLegacyData.admin.datacache).forEach((function(t){0!==t.indexOf(o+"::")&&t!==o||delete e._googlesitekitLegacyData.admin.datacache[t]})),Object.keys(Object(a.a)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(o,"::"))&&e!=="googlesitekit_".concat(o)||Object(a.a)().removeItem(e)}))}}).call(this,n(15))}}]);
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
dist/assets/js/chunk-googlesitekit-setup-wizard-670698fb9708f334d59e.js DELETED
@@ -1,7 +0,0 @@
1
- (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[2],{150:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(28);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var k=function(t){c()(LayoutHeader,t);var n=_(LayoutHeader);function LayoutHeader(){return i()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,r=t.ctaLabel,i=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":i,"mdc-layout-grid__cell--span-12-desktop":!i,"mdc-layout-grid__cell--span-8-tablet":!i})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),i&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(v.a,{href:i,external:!0,inherit:!0},r)))))}}]),LayoutHeader}(f.a);k.propTypes={title:m.a.string,ctaLabel:m.a.string,ctaLink:m.a.string},k.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=k}).call(this,n(12))},151:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(80);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){c()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return i()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,r=t.ctaLink,i=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},r&&n&&e.createElement(h.a,{className:"googlesitekit-data-block__source",name:n,href:r,external:!0}),i))))}}]),LayoutFooter}(f.a);v.propTypes={ctaLabel:m.a.string,ctaLink:m.a.string},t.a=v}).call(this,n(12))},165:function(e,t,n){"use strict";(function(e,r){var i=n(4),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(22),f=n.n(p),g=n(8),m=n.n(g),h=n(9),y=n.n(h),v=n(3),_=n.n(v),k=n(1),b=n(0),S=n(5),E=n(109),R=n(47),C=n(166),w=n(114);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var L=function(t){m()(UserMenu,t);var n,i=N(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=i.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(f()(t)),t.handleMenuClose=t.handleMenuClose.bind(f()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(f()(t)),t.handleDialog=t.handleDialog.bind(f()(t)),t.handleDialogClose=t.handleDialogClose.bind(f()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(f()(t)),t.menuButtonRef=Object(k.h)(),t.menuRef=Object(k.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var r=e._googlesitekitLegacyData.admin.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:e.location.assign(r);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(S.d)(),document.location=Object(S.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData.admin,n=t.userData,i=n.email,a=void 0===i?"":i,o=n.picture,s=void 0===o?"":o,c=t.proxyPermissionsURL,l=this.state,u=l.dialogActive,d=l.menuOpen;return r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},r.createElement(R.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:s?r.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},r.createElement("img",{className:"mdc-button__icon--image",src:s,alt:Object(b.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},a),r.createElement(C.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(b.__)("Disconnect","google-site-kit")].concat(c?[Object(b.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),r.createElement(w.a,null,r.createElement(E.a,{dialogActive:u,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(b.__)("Disconnect","google-site-kit"),subtitle:Object(b.__)("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:Object(b.__)("Disconnect","google-site-kit"),provides:[],danger:!0})))}}]),UserMenu}(k.a);t.a=L}).call(this,n(15),n(12))},166:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){c()(Menu,t);var n=y(Menu);function Menu(e){var t;return i()(this,Menu),(t=n.call(this,e)).menuRef=Object(f.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new h.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,r=t.menuItems,i=t.onSelected,a=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:a,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},r.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:i.bind(null,n),onKeyDown:i.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(f.a);v.propTypes={menuOpen:m.a.bool.isRequired,menuItems:m.a.array.isRequired,id:m.a.string.isRequired},t.a=v}).call(this,n(12))},167:function(e,t,n){"use strict";var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(83);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var m=function(e){c()(ErrorNotification,e);var t=g(ErrorNotification);function ErrorNotification(){return i()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(f.a)("googlesitekit.ErrorNotification")(m)},268:function(e,t,n){"use strict";(function(e){var r=n(4),i=n.n(r),a=n(10),o=n.n(a),s=n(14),c=n.n(s),l=n(6),u=n.n(l),d=n(7),p=n.n(d),f=n(22),g=n.n(f),m=n(8),h=n.n(m),y=n(9),v=n.n(y),_=n(3),k=n.n(_),b=n(1),S=n(2),E=n.n(S),R=n(18),C=n.n(R),w=n(63),N=n(0),L=n(5),O=n(269),x=n(50);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var i=k()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return v()(this,n)}}var D=function(t){h()(OptIn,t);var n,r=j(OptIn);function OptIn(e){var t;return u()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(x.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(g()(t)),t}return p()(OptIn,[{key:"handleOptIn",value:(n=c()(i.a.mark((function e(t){var n,r;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(L.i)("googlesitekit_tracking_optin"),Object(x.b)(n),!n){e.next=6;break}return e.next=6,Object(x.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(w.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,i=this.props,a=i.id,o=i.name,s=i.className,c=Object(N.sprintf)(
2
- /* translators: %s: privacy policy URL */
3
- Object(N.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:C()("googlesitekit-opt-in",s)},e.createElement(O.a,{id:a,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(L.t)(c,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(b.a);D.propTypes={id:E.a.string,name:E.a.string,className:E.a.string,optinAction:E.a.string},D.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=D}).call(this,n(12))},269:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(43);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var k=function(t){c()(Checkbox,t);var n=_(Checkbox);function Checkbox(e){var t;return i()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(f.h)(),t.checkboxRef=Object(f.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,i=t.name,a=t.value,o=t.checked,s=t.disabled,c=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:y()("mdc-checkbox",{"mdc-checkbox--disabled":s}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:i,value:a,checked:o,disabled:s,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},c))}}]),Checkbox}(f.a);k.propTypes={onChange:m.a.func.isRequired,id:m.a.string.isRequired,name:m.a.string.isRequired,value:m.a.string.isRequired,checked:m.a.bool,disabled:m.a.bool,children:m.a.node.isRequired},k.defaultProps={checked:!1,disabled:!1},t.a=k}).call(this,n(12))},27:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(150),_=n(151);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){c()(Layout,t);var n=k(Layout);function Layout(){return i()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,r=t.footer,i=t.children,a=t.title,o=t.headerCtaLabel,s=t.headerCtaLink,c=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,p=t.fill,f=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":p,"googlesitekit-layout--relative":f})},n&&e.createElement(v.a,{title:a,ctaLabel:o,ctaLink:s}),i,r&&e.createElement(_.a,{ctaLabel:c,ctaLink:l,footerContent:u}))}}]),Layout}(f.a);b.propTypes={header:m.a.bool,footer:m.a.bool,children:m.a.node.isRequired,title:m.a.string,headerCtaLabel:m.a.string,headerCtaLink:m.a.string,footerCtaLabel:m.a.string,footerCtaLink:m.a.string,footerContent:m.a.node,className:m.a.string,fill:m.a.bool,relative:m.a.bool},b.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=b}).call(this,n(12))},648:function(e,t,n){"use strict";n.r(t),function(e,r){var i=n(4),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(22),f=n.n(p),g=n(8),m=n.n(g),h=n(9),y=n.n(h),v=n(3),_=n.n(v),k=n(1),b=n(13),S=n(0),E=n(90),R=n(47),C=n(27),w=n(17),N=n(5),L=n(651),O=n(658);function x(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(Setup,t);var n,i=x(Setup);function Setup(t){var n;l()(this,Setup),n=i.call(this,t);var r=e._googlesitekitLegacyData.admin.connectURL,a=e._googlesitekitLegacyData.setup,o=a.isAuthenticated,s=a.hasSearchConsoleProperty,c=a.isSiteKitConnected,u=a.isVerified,d=a.needReauthenticate,p=e._googlesitekitLegacyData.permissions.canSetup;return n.state={canSetup:p,isAuthenticated:o,isVerified:u,needReauthenticate:d,hasSearchConsoleProperty:s,hasSearchConsolePropertyFromTheStart:s,connectURL:r,errorMsg:"",isSiteKitConnected:c,completeSetup:!1},n.siteConnectedSetup=n.siteConnectedSetup.bind(f()(n)),n.siteVerificationSetup=n.siteVerificationSetup.bind(f()(n)),n.searchConsoleSetup=n.searchConsoleSetup.bind(f()(n)),n.resetAndRestart=n.resetAndRestart.bind(f()(n)),n.completeSetup=n.completeSetup.bind(f()(n)),n.setErrorMessage=n.setErrorMessage.bind(f()(n)),n}return d()(Setup,[{key:"resetAndRestart",value:(n=s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.c.set(w.a,"site","reset");case 2:Object(N.d)(),this.setState({isSiteKitConnected:!1,isAuthenticated:!1,isVerified:!1,hasSearchConsoleProperty:!1,completeSetup:!1,errorMsg:""});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"completeSetup",value:function(){this.setState({completeSetup:!0})}},{key:"siteConnectedSetup",value:function(e){this.setState({isSiteKitConnected:e})}},{key:"siteVerificationSetup",value:function(e){this.setState({isVerified:e})}},{key:"searchConsoleSetup",value:function(e){this.setState({hasSearchConsoleProperty:e})}},{key:"isSetupFinished",value:function(){var e=this.state,t=e.isSiteKitConnected,n=e.isAuthenticated,r=e.isVerified,i=e.hasSearchConsoleProperty,a=e.completeSetup;return t&&n&&r&&i&&a}},{key:"setErrorMessage",value:function(e){this.setState({errorMsg:e})}},{key:"getApplicableSteps",value:function(){var e,t=L.a,n=Object.keys(t);for(e=0;e<n.length;e++)t[n[e]].isApplicable(this.state)||delete t[n[e]];return t}},{key:"currentStep",value:function(e){var t,n=Object.keys(e);for(t=0;t<n.length-1;t++)if(!e[n[t]].isCompleted(this.state))return n[t];return n[t]}},{key:"stepStatus",value:function(e,t){return e[t].isCompleted(this.state)?"completed":t===this.currentStep(e)?"inprogress":""}},{key:"render",value:function(){var t=this,n=this.state,i=n.canSetup,o=n.isAuthenticated,c=n.isVerified,l=n.needReauthenticate,u=n.hasSearchConsoleProperty,d=n.connectURL,p=n.isSiteKitConnected;if(this.isSetupFinished()){var f=Object(N.m)("googlesitekit-dashboard",{notification:"authentication_success"});Object(b.delay)((function(){e.location.replace(f)}),500,"later")}var g=this.getApplicableSteps(),m=this.currentStep(g),h=g[m].Component,y=r.createElement(h,{siteConnectedSetup:this.siteConnectedSetup,connectURL:d,siteVerificationSetup:this.siteVerificationSetup,searchConsoleSetup:this.searchConsoleSetup,completeSetup:this.completeSetup,isSiteKitConnected:p,isAuthenticated:o,isVerified:c,needReauthenticate:l,hasSearchConsoleProperty:u,setErrorMessage:this.setErrorMessage,resetAndRestart:g.clientCredentials?this.resetAndRestart:void 0}),v=i,_=!v&&!o;return r.createElement(k.b,null,r.createElement(E.a,null),r.createElement("div",{className:"googlesitekit-wizard"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement(C.a,null,r.createElement("section",{className:"googlesitekit-wizard-progress"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},v&&r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("div",{className:"googlesitekit-wizard-progress__steps"},Object.keys(g).map((function(e,n){return r.createElement(O.a,{key:g[e].title,currentStep:m===e,title:g[e].title,step:n+1,status:t.stepStatus(g,e),warning:g[e].warning,error:g[e].error,stepKey:e})})))))),_&&r.createElement("div",{className:"googlesitekit-setup__footer"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("h1",{className:"googlesitekit-setup__title"},Object(S.__)("Authenticate Site Kit","google-site-kit")),r.createElement("p",{className:"googlesitekit-setup__description"},Object(S.__)("Please sign into your Google account to begin.","google-site-kit")),r.createElement(R.a,{href:"#",onClick:s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(N.w)("plugin_setup","signin_with_google");case 2:document.location=d;case 3:case"end":return e.stop()}}),e)})))},Object(S.__)("Sign in with Google","google-site-kit"))))))),v&&y))))))}}]),Setup}(k.a);t.default=j}.call(this,n(15),n(12))},651:function(e,t,n){"use strict";var r=n(0),i=n(652),a=n(653),o=n(655),s=n(657),c={authentication:{title:Object(r.__)("Authenticate","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&!e.needReauthenticate},Component:i.a},verification:{title:Object(r.__)("Verify URL","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified},Component:a.a},seachConsoleProperty:{title:Object(r.__)("Connect Search Console","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:o.a},completeSetup:{title:Object(r.__)("Finish","google-site-kit"),required:!1,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:s.a}};t.a=c},652:function(e,t,n){"use strict";(function(e){var r=n(4),i=n.n(r),a=n(14),o=n.n(a),s=n(6),c=n.n(s),l=n(7),u=n.n(l),d=n(8),p=n.n(d),f=n(9),g=n.n(f),m=n(3),h=n.n(m),y=n(1),v=n(2),_=n.n(v),k=n(0),b=n(5),S=n(47),E=n(28),R=n(268),C=n(89);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h()(e);if(t){var i=h()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return g()(this,n)}}var N=function(t){p()(WizardStepAuthentication,t);var n=w(WizardStepAuthentication);function WizardStepAuthentication(){return c()(this,WizardStepAuthentication),n.apply(this,arguments)}return u()(WizardStepAuthentication,[{key:"render",value:function(){var t=this.props,n=t.connectURL,r=t.needReauthenticate,a=t.resetAndRestart;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--two"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(k.__)("Authenticate with Google","google-site-kit")),e.createElement("p",null,Object(k.__)("Please sign into your Google account to begin.","google-site-kit")),r&&e.createElement("p",{className:"googlesitekit-error-text"},Object(k.__)("You did not grant access to one or more of the requested scopes. Please grant all scopes that you are prompted for.","google-site-kit")),e.createElement("p",null,e.createElement(S.a,{onClick:o()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(b.w)("plugin_setup","signin_with_google");case 2:document.location=n;case 3:case"end":return e.stop()}}),e)})))},Object(k.__)("Sign in with Google","google-site-kit")),a&&e.createElement(E.a,{className:"googlesitekit-wizard-step__back",onClick:a},Object(k.__)("Back","google-site-kit"))),e.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},e.createElement(R.a,{optinAction:"analytics_optin_setup_fallback"}),e.createElement(C.a,null))))))}}]),WizardStepAuthentication}(y.a);N.propTypes={connectURL:_.a.string.isRequired,resetAndRestart:_.a.func},t.a=N}).call(this,n(12))},653:function(e,t,n){"use strict";(function(e){var r=n(81),i=n.n(r),a=n(6),o=n.n(a),s=n(7),c=n.n(s),l=n(8),u=n.n(l),d=n(9),p=n.n(d),f=n(3),g=n.n(f),m=n(1),h=n(2),y=n.n(h),v=n(654);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var i=g()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return p()(this,n)}}var k=function(t){u()(WizardStepVerification,t);var n=_(WizardStepVerification);function WizardStepVerification(){return o()(this,WizardStepVerification),n.apply(this,arguments)}return c()(WizardStepVerification,[{key:"render",value:function(){var t=!this.props.isVerified;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--three"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(v.a,i()({shouldSetup:t},this.props))))))}}]),WizardStepVerification}(m.a);k.propTypes={siteVerificationSetup:y.a.func.isRequired},t.a=k}).call(this,n(12))},654:function(e,t,n){"use strict";(function(e,r){var i=n(4),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(22),f=n.n(p),g=n(8),m=n.n(g),h=n(9),y=n.n(h),v=n(3),_=n.n(v),k=n(1),b=n(2),S=n.n(b),E=n(0),R=n(5),C=n(43),w=n(17),N=n(47),L=n(49),O=n(89);function x(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(SiteVerification,t);var n,i,o=x(SiteVerification);function SiteVerification(e){var t;l()(this,SiteVerification);var n=(t=o.call(this,e)).props,r=n.isAuthenticated,i=n.shouldSetup;return t.state={loading:r&&i,loadingMsg:Object(E.__)("Getting your verified sites…","google-site-kit"),siteURL:" ",selectedURL:"",errorCode:!1,errorMsg:""},t.onProceed=t.onProceed.bind(f()(t)),t}return d()(SiteVerification,[{key:"componentDidMount",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup;t&&n&&this.requestSitePropertyList()}},{key:"requestSitePropertyList",value:function(){var t=this,n=this.props.setErrorMessage;s()(a.a.mark((function r(){var i,o,s,c,l;return a.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,w.c.get(w.b,"site-verification","verification");case 3:if(i=r.sent,o=i.verified,s=i.identifier,!o){r.next=17;break}return r.next=9,Object(R.w)("verification_setup","verification_check_true");case 9:return r.next=11,t.insertSiteVerification(s);case 11:if(!0!==r.sent.verified){r.next=15;break}return t.props.siteVerificationSetup(!0),r.abrupt("return",!0);case 15:r.next=19;break;case 17:return r.next=19,Object(R.w)("verification_setup","verification_check_false");case 19:t.setState({loading:!1,siteURL:s}),r.next=28;break;case 22:r.prev=22,r.t0=r.catch(0),c=r.t0.message,Object(R.x)(r.t0.message)&&(l=JSON.parse(r.t0.message),c=l.error.message||r.t0.message),n(c),t.setState({loading:!1,errorCode:r.t0.code,errorMsg:c,siteURL:e._googlesitekitLegacyData.admin.siteURL});case 28:case"end":return r.stop()}}),r,null,[[0,22]])})))()}},{key:"insertSiteVerification",value:(i=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.c.set(w.b,"site-verification","verification",{siteURL:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(e){return i.apply(this,arguments)})},{key:"onProceed",value:(n=s()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=this.props.setErrorMessage,r=this.state.siteURL?this.state.siteURL:e._googlesitekitLegacyData.admin.siteURL,n(""),this.setState({loading:!0,loadingMsg:Object(E.__)("Verifying…","google-site-kit"),errorCode:!1,errorMsg:""}),t.prev=4,t.next=7,this.insertSiteVerification(r);case 7:!0===t.sent.verified&&(Object(R.w)("verification_setup","verification_insert_tag"),this.props.siteVerificationSetup(!0)),t.next=17;break;case 11:t.prev=11,t.t0=t.catch(4),i=t.t0.message,Object(R.x)(t.t0.message)&&(o=JSON.parse(t.t0.message),i=o.error.message||t.t0.message),n(i),this.setState({loading:!1,errorCode:t.t0.code,errorMsg:i});case 17:case"end":return t.stop()}}),t,this,[[4,11]])}))),function(){return n.apply(this,arguments)})},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.loadingMsg,i=e.siteURL,a=r.createElement(k.b,null,n&&r.createElement("p",null,n),r.createElement(L.a,null));return t?a:r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-wizard-step__inputs"},r.createElement(C.k,{label:Object(E.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},r.createElement(C.b,{value:i}))),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(N.a,{onClick:this.onProceed},Object(E.__)("Continue","google-site-kit")),r.createElement(O.a,null)))}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,i=this.state.errorMsg;return n?r.createElement(k.b,null,r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(E.__)("Verify URL","google-site-kit")),r.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(E.__)("We will need to verify your URL for Site Kit.","google-site-kit")),i&&0<i.length&&r.createElement("p",{className:"googlesitekit-error-text"},i),t&&this.renderForm()):SiteVerification.renderSetupDone()}}],[{key:"renderSetupDone",value:function(){return r.createElement(k.b,null,r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(E.__)("Verify URL","google-site-kit")),r.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(E.__)("Congratulations, your site has been verified!","google-site-kit")))}}]),SiteVerification}(k.a);j.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,siteVerificationSetup:S.a.func.isRequired,completeSetup:S.a.func,setErrorMessage:S.a.func.isRequired},t.a=j}).call(this,n(15),n(12))},655:function(e,t,n){"use strict";(function(e){var r=n(81),i=n.n(r),a=n(6),o=n.n(a),s=n(7),c=n.n(s),l=n(8),u=n.n(l),d=n(9),p=n.n(d),f=n(3),g=n.n(f),m=n(1),h=n(2),y=n.n(h),v=n(656);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var i=g()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return p()(this,n)}}var k=function(t){u()(WizardStepSearchConsoleProperty,t);var n=_(WizardStepSearchConsoleProperty);function WizardStepSearchConsoleProperty(){return o()(this,WizardStepSearchConsoleProperty),n.apply(this,arguments)}return c()(WizardStepSearchConsoleProperty,[{key:"render",value:function(){var t=this.props,n=t.isVerified,r=t.hasSearchConsoleProperty,a=n&&!r;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--four"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},a?e.createElement(v.a,i()({shouldSetup:a},this.props)):v.a.connected()))))}}]),WizardStepSearchConsoleProperty}(m.a);k.propTypes={searchConsoleSetup:y.a.func.isRequired},t.a=k}).call(this,n(12))},656:function(e,t,n){"use strict";(function(e,r){var i=n(4),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(22),f=n.n(p),g=n(8),m=n.n(g),h=n(9),y=n.n(h),v=n(3),_=n.n(v),k=n(1),b=n(2),S=n.n(b),E=n(0),R=n(5),C=n(17),w=n(49),N=n(89),L=n(43),O=n(47);function x(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(SearchConsole,t);var n,i,o=x(SearchConsole);function SearchConsole(t){var n;l()(this,SearchConsole),n=o.call(this,t);var r=e._googlesitekitLegacyData.admin.siteURL;return n.state={loading:!0,sites:!1,selectedURL:r,siteURL:r,connected:!1,errorCode:!1,errorMsg:""},n.handleURLSelect=n.handleURLSelect.bind(f()(n)),n.insertPropertyToSearchConsole=n.insertPropertyToSearchConsole.bind(f()(n)),n.submitPropertyEventHandler=n.submitPropertyEventHandler.bind(f()(n)),n}return d()(SearchConsole,[{key:"componentDidMount",value:(i=s()(a.a.mark((function e(){var t,n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=this.props,n=t.isAuthenticated,r=t.shouldSetup,n&&r){e.next=3;break}return e.abrupt("return");case 3:this.requestSearchConsoleSiteList();case 4:case"end":return e.stop()}}),e,this)}))),function(){return i.apply(this,arguments)})},{key:"requestSearchConsoleSiteList",value:function(){var e=this,t=this.props.setErrorMessage;s()(a.a.mark((function n(){var r;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,C.c.get(C.b,"search-console","matched-sites");case 3:if(1!==(r=n.sent).length){n.next=9;break}return n.next=7,e.insertPropertyToSearchConsole(r[0].siteURL);case 7:return e.props.searchConsoleSetup(r[0].siteURL),n.abrupt("return");case 9:if(r.length){n.next=11;break}throw{code:"no_property_matched",message:Object(E.__)("Your site has not been added to Search Console yet. Would you like to add it now?","google-site-kit")};case 11:throw t(""),e.setState({loading:!1,selectedURL:r[0].siteURL,sites:r}),{code:"multiple_properties_matched",message:Object(E.sprintf)(
4
- /* translators: %d: the number of matching properties */
5
- Object(E.__)("We found %d existing accounts. Please choose which one to use below.","google-site-kit"),r.length)};case 16:n.prev=16,n.t0=n.catch(0),t(n.t0.message),e.setState({loading:!1,errorCode:n.t0.code,errorMsg:n.t0.message});case 20:case"end":return n.stop()}}),n,null,[[0,16]])})))()}},{key:"insertPropertyToSearchConsole",value:(n=s()(a.a.mark((function e(t){var n,r=arguments;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=r.length>1&&void 0!==r[1]&&r[1],e.next=3,C.c.set(C.b,"search-console","site",{siteURL:t});case 3:if(!n){e.next=6;break}return e.next=6,Object(R.w)("search_console_setup","add_new_sc_property");case 6:this.setState({loading:!1,connected:!0});case 7:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"submitPropertyEventHandler",value:function(){var e=this,t=this.state,n=t.selectedURL,r=t.errorCode,i=this.props.setErrorMessage;s()(a.a.mark((function t(){return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,e.insertPropertyToSearchConsole(n,"no_property_matched"===r);case 3:i(""),e.props.searchConsoleSetup(n),t.next=11;break;case 7:t.prev=7,t.t0=t.catch(0),i(t.t0.message[0].message),e.setState({loading:!1,errorCode:t.t0.code,errorMsg:t.t0.message[0].message});case 11:case"end":return t.stop()}}),t,null,[[0,7]])})))()}},{key:"handleURLSelect",value:function(e,t){this.setState({selectedURL:t.getAttribute("data-value")})}},{key:"matchedForm",value:function(){var e=this.state,t=e.sites,n=e.selectedURL;if(!t)return null;var i=t.map((function(e){var t=e.siteURL;return t.startsWith("sc-domain:")&&(
6
- /* translators: %s: Search Console property domain name */
7
- t=Object(E.sprintf)(Object(E.__)("%s (domain property)","google-site-kit"),t.replace(/^sc-domain:/,""))),{label:t,value:e.siteURL}}));return r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-module__inputs"},r.createElement(L.j,{enhanced:!0,name:"siteProperty",label:Object(E.__)("Choose URL","google-site-kit"),outlined:!0,onEnhancedChange:this.handleURLSelect,options:i,value:n})),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(O.a,{onClick:this.submitPropertyEventHandler},Object(E.__)("Continue","google-site-kit")),r.createElement(N.a,null)))}},{key:"noSiteForm",value:function(){var e=this.state.siteURL;return r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-module__inputs"},r.createElement(L.k,{label:Object(E.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},r.createElement(L.b,{value:e}))),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(O.a,{onClick:this.submitPropertyEventHandler},Object(E.__)("Continue","google-site-kit")),r.createElement(N.a,null)))}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.sites;return t?r.createElement(k.b,null,r.createElement("p",null,Object(E.__)("We’re locating your Search Console account.","google-site-kit")),r.createElement(w.a,null)):0===n.length?this.noSiteForm():this.matchedForm()}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,i=this.state,a=i.errorMsg,o=i.connected;return!n||o?SearchConsole.connected():r.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("Search Console","Service name","google-site-kit")),a&&0<a.length&&r.createElement("p",{className:"googlesitekit-error-text"},a),t&&n&&this.renderForm())}}],[{key:"connected",value:function(){return r.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("Search Console","Service name","google-site-kit")),r.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(E.__)("Your Search Console is set up with Site Kit.","google-site-kit")))}}]),SearchConsole}(k.a);j.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,searchConsoleSetup:S.a.func.isRequired,setErrorMessage:S.a.func.isRequired},t.a=j}).call(this,n(15),n(12))},657:function(e,t,n){"use strict";(function(e,r){var i=n(6),a=n.n(i),o=n(7),s=n.n(o),c=n(8),l=n.n(c),u=n(9),d=n.n(u),p=n(3),f=n.n(p),g=n(1),m=n(2),h=n.n(m),y=n(0),v=n(5),_=n(47);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var i=f()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return d()(this,n)}}var b=function(t){l()(WizardStepCompleteSetup,t);var n=k(WizardStepCompleteSetup);function WizardStepCompleteSetup(t){var r;return a()(this,WizardStepCompleteSetup),r=n.call(this,t),e._googlesitekitLegacyData.setup.hasSearchConsoleProperty?Object(v.w)("plugin_setup","user_verified"):Object(v.w)("plugin_setup","site_verified"),r}return s()(WizardStepCompleteSetup,[{key:"render",value:function(){return r.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--five"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-9-desktop "},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(y.__)("Congratulations!","google-site-kit")),r.createElement("p",null,Object(y.__)("You successfully completed the Site Kit setup and connected Search Console. Check the dashboard for more services to connect.","google-site-kit")),r.createElement("div",{className:"googlesitekit-wizard-step__action"},r.createElement(_.a,{id:"wizard-step-five-proceed",onClick:this.props.completeSetup},Object(y.__)("Go to Dashboard","google-site-kit")))),r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-3-tablet mdc-layout-grid__cell--span-3-desktop "},r.createElement("div",{className:"googlesitekit-rocket"},r.createElement("img",{className:"googlesitekit-rocket__body",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-body.png"}),r.createElement("img",{className:"googlesitekit-rocket__clouds",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-clouds.png"}),r.createElement("img",{className:"googlesitekit-rocket__dust",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-dust.png"}))))))}}]),WizardStepCompleteSetup}(g.a);b.propTypes={completeSetup:h.a.func.isRequired},t.a=b}).call(this,n(15),n(12))},658:function(e,t,n){"use strict";var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(8),c=n.n(s),l=n(9),u=n.n(l),d=n(3),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(12),y=n.n(h),v=n(18),_=n.n(v),k=n(34);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var S=function(e){c()(WizardProgressStep,e);var t=b(WizardProgressStep);function WizardProgressStep(){return i()(this,WizardProgressStep),t.apply(this,arguments)}return o()(WizardProgressStep,[{key:"render",value:function(){var e=this.props,t=e.currentStep,n=e.step,r=e.title,i=e.status,a=e.warning,o=e.error,s=e.stepKey,c=i;a?c="warning":o&&(c="error");var l=!1;switch(c){case"warning":case"error":l=y.a.createElement(k.a,{id:"exclamation",height:"12",width:"2"});break;case"completed":l=y.a.createElement(k.a,{id:"check",height:"12",width:"16"})}return y.a.createElement("div",{className:_()("googlesitekit-wizard-progress-step","googlesitekit-wizard-progress-step--".concat(n),"googlesitekit-wizard-progress-step--".concat(s),{"googlesitekit-wizard-progress-step--current":t})},y.a.createElement("div",{className:"googlesitekit-wizard-progress-step__number-wrapper"},y.a.createElement("div",{className:_()("googlesitekit-wizard-progress-step__number","googlesitekit-wizard-progress-step__number--".concat(c))},y.a.createElement("span",{className:_()("googlesitekit-wizard-progress-step__number-text","googlesitekit-wizard-progress-step__number-text--".concat(c))},n),l&&y.a.createElement("span",{className:_()("googlesitekit-wizard-progress-step__number-icon","googlesitekit-wizard-progress-step__number-icon--".concat(c))},l))),y.a.createElement("p",{className:"googlesitekit-wizard-progress-step__text"},r))}}]),WizardProgressStep}(f.a);S.propTypes={currentStep:m.a.bool.isRequired,step:m.a.number.isRequired,title:m.a.string,status:m.a.string,warning:m.a.bool,error:m.a.bool},S.defaultProps={title:"",status:"",warning:!1,error:!1,removeFirstStep:!1},t.a=S},89:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),i=n(28);t.a=function HelpLink(){var t=Object(r.__)("Need help?","google-site-kit");return e.createElement(i.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},90:function(e,t,n){"use strict";(function(e,r){var i=n(6),a=n.n(i),o=n(7),s=n.n(o),c=n(8),l=n.n(c),u=n(9),d=n.n(u),p=n(3),f=n.n(p),g=n(1),m=n(135),h=n(165),y=n(167);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var i=f()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return d()(this,n)}}var _=function(t){l()(Header,t);var n=v(Header);function Header(){return a()(this,Header),n.apply(this,arguments)}return s()(Header,[{key:"render",value:function(){var t=e._googlesitekitLegacyData.setup.isAuthenticated;return r.createElement(g.b,null,r.createElement("header",{className:"googlesitekit-header"},r.createElement("section",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},r.createElement(m.a,null)),r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&r.createElement(h.a,null))))),r.createElement(y.a,null))}}]),Header}(g.a);t.a=_}).call(this,n(15),n(12))}}]);
 
 
 
 
 
 
 
dist/assets/js/chunk-googlesitekit-setup-wizard-b9d2c95d51997246bd53.js ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
1
+ (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[2],{154:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(28);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var k=function(t){c()(LayoutHeader,t);var n=_(LayoutHeader);function LayoutHeader(){return i()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,r=t.ctaLabel,i=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":i,"mdc-layout-grid__cell--span-12-desktop":!i,"mdc-layout-grid__cell--span-8-tablet":!i})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),i&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(v.a,{href:i,external:!0,inherit:!0},r)))))}}]),LayoutHeader}(f.a);k.propTypes={title:m.a.string,ctaLabel:m.a.string,ctaLink:m.a.string},k.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=k}).call(this,n(12))},155:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(82);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){c()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return i()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,r=t.ctaLink,i=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},r&&n&&e.createElement(h.a,{className:"googlesitekit-data-block__source",name:n,href:r,external:!0}),i))))}}]),LayoutFooter}(f.a);v.propTypes={ctaLabel:m.a.string,ctaLink:m.a.string},t.a=v}).call(this,n(12))},169:function(e,t,n){"use strict";(function(e,r){var i=n(3),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(23),f=n.n(p),g=n(9),m=n.n(g),h=n(10),y=n.n(h),v=n(4),_=n.n(v),k=n(1),b=n(0),S=n(8),E=n.n(S),R=n(5),C=n(111),w=n(47),N=n(170),L=n(116),x=n(34),O=n(20);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var P=E.a.withSelect,z=function(t){m()(UserMenu,t);var n,i=j(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=i.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(f()(t)),t.handleMenuClose=t.handleMenuClose.bind(f()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(f()(t)),t.handleDialog=t.handleDialog.bind(f()(t)),t.handleDialogClose=t.handleDialogClose.bind(f()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(f()(t)),t.menuButtonRef=Object(k.h)(),t.menuRef=Object(k.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var r=this.props.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:if(!r)return;e.location.assign(r);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(R.d)(),document.location=Object(R.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this.props,t=e.proxyPermissionsURL,n=e.userEmail,i=e.userPicture,a=this.state,o=a.dialogActive,s=a.menuOpen;return n?r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},r.createElement(w.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:i?r.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},r.createElement("img",{className:"mdc-button__icon--image",src:i,alt:Object(b.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:s,ariaControls:"user-menu"},n),r.createElement(N.a,{ref:this.menuRef,menuOpen:s,menuItems:[Object(b.__)("Disconnect","google-site-kit")].concat(t?[Object(b.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),r.createElement(L.a,null,r.createElement(C.a,{dialogActive:o,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(b.__)("Disconnect","google-site-kit"),subtitle:Object(b.__)("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:Object(b.__)("Disconnect","google-site-kit"),provides:[],danger:!0}))):null}}]),UserMenu}(k.a);t.a=P((function(e){return{proxyPermissionsURL:e(x.c).getProxyPermissionsURL(),userEmail:e(O.c).getEmail(),userPicture:e(O.c).getPicture()}}))(z)}).call(this,n(13),n(12))},170:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){c()(Menu,t);var n=y(Menu);function Menu(e){var t;return i()(this,Menu),(t=n.call(this,e)).menuRef=Object(f.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new h.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,r=t.menuItems,i=t.onSelected,a=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:a,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},r.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:i.bind(null,n),onKeyDown:i.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(f.a);v.propTypes={menuOpen:m.a.bool.isRequired,menuItems:m.a.array.isRequired,id:m.a.string.isRequired},t.a=v}).call(this,n(12))},171:function(e,t,n){"use strict";var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(85);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var m=function(e){c()(ErrorNotification,e);var t=g(ErrorNotification);function ErrorNotification(){return i()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(f.a)("googlesitekit.ErrorNotification")(m)},27:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(154),_=n(155);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){c()(Layout,t);var n=k(Layout);function Layout(){return i()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,r=t.footer,i=t.children,a=t.title,o=t.headerCtaLabel,s=t.headerCtaLink,c=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,p=t.fill,f=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":p,"googlesitekit-layout--relative":f})},n&&e.createElement(v.a,{title:a,ctaLabel:o,ctaLink:s}),i,r&&e.createElement(_.a,{ctaLabel:c,ctaLink:l,footerContent:u}))}}]),Layout}(f.a);b.propTypes={header:m.a.bool,footer:m.a.bool,children:m.a.node.isRequired,title:m.a.string,headerCtaLabel:m.a.string,headerCtaLink:m.a.string,footerCtaLabel:m.a.string,footerCtaLink:m.a.string,footerContent:m.a.node,className:m.a.string,fill:m.a.bool,relative:m.a.bool},b.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=b}).call(this,n(12))},270:function(e,t,n){"use strict";(function(e){var r=n(3),i=n.n(r),a=n(11),o=n.n(a),s=n(14),c=n.n(s),l=n(6),u=n.n(l),d=n(7),p=n.n(d),f=n(23),g=n.n(f),m=n(9),h=n.n(m),y=n(10),v=n.n(y),_=n(4),k=n.n(_),b=n(1),S=n(2),E=n.n(S),R=n(18),C=n.n(R),w=n(65),N=n(0),L=n(5),x=n(271),O=n(50);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var i=k()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return v()(this,n)}}var P=function(t){h()(OptIn,t);var n,r=j(OptIn);function OptIn(e){var t;return u()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(O.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(g()(t)),t}return p()(OptIn,[{key:"handleOptIn",value:(n=c()(i.a.mark((function e(t){var n,r;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(L.i)("googlesitekit_tracking_optin"),Object(O.b)(n),!n){e.next=6;break}return e.next=6,Object(O.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(w.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,i=this.props,a=i.id,o=i.name,s=i.className,c=Object(N.sprintf)(
2
+ /* translators: %s: privacy policy URL */
3
+ Object(N.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:C()("googlesitekit-opt-in",s)},e.createElement(x.a,{id:a,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(L.t)(c,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(b.a);P.propTypes={id:E.a.string,name:E.a.string,className:E.a.string,optinAction:E.a.string},P.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=P}).call(this,n(12))},271:function(e,t,n){"use strict";(function(e){var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(18),y=n.n(h),v=n(44);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var k=function(t){c()(Checkbox,t);var n=_(Checkbox);function Checkbox(e){var t;return i()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(f.h)(),t.checkboxRef=Object(f.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,i=t.name,a=t.value,o=t.checked,s=t.disabled,c=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:y()("mdc-checkbox",{"mdc-checkbox--disabled":s}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:i,value:a,checked:o,disabled:s,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},c))}}]),Checkbox}(f.a);k.propTypes={onChange:m.a.func.isRequired,id:m.a.string.isRequired,name:m.a.string.isRequired,value:m.a.string.isRequired,checked:m.a.bool,disabled:m.a.bool,children:m.a.node.isRequired},k.defaultProps={checked:!1,disabled:!1},t.a=k}).call(this,n(12))},34:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a}));var r="core/site",i="primary",a="secondary"},646:function(e,t,n){"use strict";n.r(t),function(e,r){var i=n(3),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(23),f=n.n(p),g=n(9),m=n.n(g),h=n(10),y=n.n(h),v=n(4),_=n.n(v),k=n(1),b=n(15),S=n(0),E=n(92),R=n(47),C=n(27),w=n(17),N=n(5),L=n(649),x=n(656);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(Setup,t);var n,i=O(Setup);function Setup(t){var n;l()(this,Setup),n=i.call(this,t);var r=e._googlesitekitLegacyData.admin.connectURL,a=e._googlesitekitLegacyData.setup,o=a.isAuthenticated,s=a.hasSearchConsoleProperty,c=a.isSiteKitConnected,u=a.isVerified,d=a.needReauthenticate,p=e._googlesitekitLegacyData.permissions.canSetup;return n.state={canSetup:p,isAuthenticated:o,isVerified:u,needReauthenticate:d,hasSearchConsoleProperty:s,hasSearchConsolePropertyFromTheStart:s,connectURL:r,errorMsg:"",isSiteKitConnected:c,completeSetup:!1},n.siteConnectedSetup=n.siteConnectedSetup.bind(f()(n)),n.siteVerificationSetup=n.siteVerificationSetup.bind(f()(n)),n.searchConsoleSetup=n.searchConsoleSetup.bind(f()(n)),n.resetAndRestart=n.resetAndRestart.bind(f()(n)),n.completeSetup=n.completeSetup.bind(f()(n)),n.setErrorMessage=n.setErrorMessage.bind(f()(n)),n}return d()(Setup,[{key:"resetAndRestart",value:(n=s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.c.set(w.a,"site","reset");case 2:Object(N.d)(),this.setState({isSiteKitConnected:!1,isAuthenticated:!1,isVerified:!1,hasSearchConsoleProperty:!1,completeSetup:!1,errorMsg:""});case 4:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"completeSetup",value:function(){this.setState({completeSetup:!0})}},{key:"siteConnectedSetup",value:function(e){this.setState({isSiteKitConnected:e})}},{key:"siteVerificationSetup",value:function(e){this.setState({isVerified:e})}},{key:"searchConsoleSetup",value:function(e){this.setState({hasSearchConsoleProperty:e})}},{key:"isSetupFinished",value:function(){var e=this.state,t=e.isSiteKitConnected,n=e.isAuthenticated,r=e.isVerified,i=e.hasSearchConsoleProperty,a=e.completeSetup;return t&&n&&r&&i&&a}},{key:"setErrorMessage",value:function(e){this.setState({errorMsg:e})}},{key:"getApplicableSteps",value:function(){var e,t=L.a,n=Object.keys(t);for(e=0;e<n.length;e++)t[n[e]].isApplicable(this.state)||delete t[n[e]];return t}},{key:"currentStep",value:function(e){var t,n=Object.keys(e);for(t=0;t<n.length-1;t++)if(!e[n[t]].isCompleted(this.state))return n[t];return n[t]}},{key:"stepStatus",value:function(e,t){return e[t].isCompleted(this.state)?"completed":t===this.currentStep(e)?"inprogress":""}},{key:"render",value:function(){var t=this,n=this.state,i=n.canSetup,o=n.isAuthenticated,c=n.isVerified,l=n.needReauthenticate,u=n.hasSearchConsoleProperty,d=n.connectURL,p=n.isSiteKitConnected;if(this.isSetupFinished()){var f=Object(N.m)("googlesitekit-dashboard",{notification:"authentication_success"});Object(b.delay)((function(){e.location.replace(f)}),500,"later")}var g=this.getApplicableSteps(),m=this.currentStep(g),h=g[m].Component,y=r.createElement(h,{siteConnectedSetup:this.siteConnectedSetup,connectURL:d,siteVerificationSetup:this.siteVerificationSetup,searchConsoleSetup:this.searchConsoleSetup,completeSetup:this.completeSetup,isSiteKitConnected:p,isAuthenticated:o,isVerified:c,needReauthenticate:l,hasSearchConsoleProperty:u,setErrorMessage:this.setErrorMessage,resetAndRestart:g.clientCredentials?this.resetAndRestart:void 0}),v=i,_=!v&&!o;return r.createElement(k.b,null,r.createElement(E.a,null),r.createElement("div",{className:"googlesitekit-wizard"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement(C.a,null,r.createElement("section",{className:"googlesitekit-wizard-progress"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},v&&r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("div",{className:"googlesitekit-wizard-progress__steps"},Object.keys(g).map((function(e,n){return r.createElement(x.a,{key:g[e].title,currentStep:m===e,title:g[e].title,step:n+1,status:t.stepStatus(g,e),warning:g[e].warning,error:g[e].error,stepKey:e})})))))),_&&r.createElement("div",{className:"googlesitekit-setup__footer"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("h1",{className:"googlesitekit-setup__title"},Object(S.__)("Authenticate Site Kit","google-site-kit")),r.createElement("p",{className:"googlesitekit-setup__description"},Object(S.__)("Please sign into your Google account to begin.","google-site-kit")),r.createElement(R.a,{href:"#",onClick:s()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(N.w)("plugin_setup","signin_with_google");case 2:document.location=d;case 3:case"end":return e.stop()}}),e)})))},Object(S.__)("Sign in with Google","google-site-kit"))))))),v&&y))))))}}]),Setup}(k.a);t.default=j}.call(this,n(13),n(12))},649:function(e,t,n){"use strict";var r=n(0),i=n(650),a=n(651),o=n(653),s=n(655),c={authentication:{title:Object(r.__)("Authenticate","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&!e.needReauthenticate},Component:i.a},verification:{title:Object(r.__)("Verify URL","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified},Component:a.a},seachConsoleProperty:{title:Object(r.__)("Connect Search Console","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:o.a},completeSetup:{title:Object(r.__)("Finish","google-site-kit"),required:!1,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:s.a}};t.a=c},650:function(e,t,n){"use strict";(function(e){var r=n(3),i=n.n(r),a=n(14),o=n.n(a),s=n(6),c=n.n(s),l=n(7),u=n.n(l),d=n(9),p=n.n(d),f=n(10),g=n.n(f),m=n(4),h=n.n(m),y=n(1),v=n(2),_=n.n(v),k=n(0),b=n(5),S=n(47),E=n(28),R=n(270),C=n(91);function w(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h()(e);if(t){var i=h()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return g()(this,n)}}var N=function(t){p()(WizardStepAuthentication,t);var n=w(WizardStepAuthentication);function WizardStepAuthentication(){return c()(this,WizardStepAuthentication),n.apply(this,arguments)}return u()(WizardStepAuthentication,[{key:"render",value:function(){var t=this.props,n=t.connectURL,r=t.needReauthenticate,a=t.resetAndRestart;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--two"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(k.__)("Authenticate with Google","google-site-kit")),e.createElement("p",null,Object(k.__)("Please sign into your Google account to begin.","google-site-kit")),r&&e.createElement("p",{className:"googlesitekit-error-text"},Object(k.__)("You did not grant access to one or more of the requested scopes. Please grant all scopes that you are prompted for.","google-site-kit")),e.createElement("p",null,e.createElement(S.a,{onClick:o()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(b.w)("plugin_setup","signin_with_google");case 2:document.location=n;case 3:case"end":return e.stop()}}),e)})))},Object(k.__)("Sign in with Google","google-site-kit")),a&&e.createElement(E.a,{className:"googlesitekit-wizard-step__back",onClick:a},Object(k.__)("Back","google-site-kit"))),e.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},e.createElement(R.a,{optinAction:"analytics_optin_setup_fallback"}),e.createElement(C.a,null))))))}}]),WizardStepAuthentication}(y.a);N.propTypes={connectURL:_.a.string.isRequired,resetAndRestart:_.a.func},t.a=N}).call(this,n(12))},651:function(e,t,n){"use strict";(function(e){var r=n(83),i=n.n(r),a=n(6),o=n.n(a),s=n(7),c=n.n(s),l=n(9),u=n.n(l),d=n(10),p=n.n(d),f=n(4),g=n.n(f),m=n(1),h=n(2),y=n.n(h),v=n(652);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var i=g()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return p()(this,n)}}var k=function(t){u()(WizardStepVerification,t);var n=_(WizardStepVerification);function WizardStepVerification(){return o()(this,WizardStepVerification),n.apply(this,arguments)}return c()(WizardStepVerification,[{key:"render",value:function(){var t=!this.props.isVerified;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--three"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(v.a,i()({shouldSetup:t},this.props))))))}}]),WizardStepVerification}(m.a);k.propTypes={siteVerificationSetup:y.a.func.isRequired},t.a=k}).call(this,n(12))},652:function(e,t,n){"use strict";(function(e,r){var i=n(3),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(23),f=n.n(p),g=n(9),m=n.n(g),h=n(10),y=n.n(h),v=n(4),_=n.n(v),k=n(1),b=n(2),S=n.n(b),E=n(0),R=n(5),C=n(44),w=n(17),N=n(47),L=n(49),x=n(91);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(SiteVerification,t);var n,i,o=O(SiteVerification);function SiteVerification(e){var t;l()(this,SiteVerification);var n=(t=o.call(this,e)).props,r=n.isAuthenticated,i=n.shouldSetup;return t.state={loading:r&&i,loadingMsg:Object(E.__)("Getting your verified sites…","google-site-kit"),siteURL:" ",selectedURL:"",errorCode:!1,errorMsg:""},t.onProceed=t.onProceed.bind(f()(t)),t}return d()(SiteVerification,[{key:"componentDidMount",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup;t&&n&&this.requestSitePropertyList()}},{key:"requestSitePropertyList",value:function(){var t=this,n=this.props.setErrorMessage;s()(a.a.mark((function r(){var i,o,s,c,l;return a.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,w.c.get(w.b,"site-verification","verification");case 3:if(i=r.sent,o=i.verified,s=i.identifier,!o){r.next=17;break}return r.next=9,Object(R.w)("verification_setup","verification_check_true");case 9:return r.next=11,t.insertSiteVerification(s);case 11:if(!0!==r.sent.verified){r.next=15;break}return t.props.siteVerificationSetup(!0),r.abrupt("return",!0);case 15:r.next=19;break;case 17:return r.next=19,Object(R.w)("verification_setup","verification_check_false");case 19:t.setState({loading:!1,siteURL:s}),r.next=28;break;case 22:r.prev=22,r.t0=r.catch(0),c=r.t0.message,Object(R.x)(r.t0.message)&&(l=JSON.parse(r.t0.message),c=l.error.message||r.t0.message),n(c),t.setState({loading:!1,errorCode:r.t0.code,errorMsg:c,siteURL:e._googlesitekitLegacyData.admin.siteURL});case 28:case"end":return r.stop()}}),r,null,[[0,22]])})))()}},{key:"insertSiteVerification",value:(i=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.c.set(w.b,"site-verification","verification",{siteURL:t});case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)}))),function(e){return i.apply(this,arguments)})},{key:"onProceed",value:(n=s()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n=this.props.setErrorMessage,r=this.state.siteURL?this.state.siteURL:e._googlesitekitLegacyData.admin.siteURL,n(""),this.setState({loading:!0,loadingMsg:Object(E.__)("Verifying…","google-site-kit"),errorCode:!1,errorMsg:""}),t.prev=4,t.next=7,this.insertSiteVerification(r);case 7:!0===t.sent.verified&&(Object(R.w)("verification_setup","verification_insert_tag"),this.props.siteVerificationSetup(!0)),t.next=17;break;case 11:t.prev=11,t.t0=t.catch(4),i=t.t0.message,Object(R.x)(t.t0.message)&&(o=JSON.parse(t.t0.message),i=o.error.message||t.t0.message),n(i),this.setState({loading:!1,errorCode:t.t0.code,errorMsg:i});case 17:case"end":return t.stop()}}),t,this,[[4,11]])}))),function(){return n.apply(this,arguments)})},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.loadingMsg,i=e.siteURL,a=r.createElement(k.b,null,n&&r.createElement("p",null,n),r.createElement(L.a,null));return t?a:r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-wizard-step__inputs"},r.createElement(C.k,{label:Object(E.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},r.createElement(C.b,{value:i}))),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(N.a,{onClick:this.onProceed},Object(E.__)("Continue","google-site-kit")),r.createElement(x.a,null)))}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,i=this.state.errorMsg;return n?r.createElement(k.b,null,r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(E.__)("Verify URL","google-site-kit")),r.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(E.__)("We will need to verify your URL for Site Kit.","google-site-kit")),i&&0<i.length&&r.createElement("p",{className:"googlesitekit-error-text"},i),t&&this.renderForm()):SiteVerification.renderSetupDone()}}],[{key:"renderSetupDone",value:function(){return r.createElement(k.b,null,r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(E.__)("Verify URL","google-site-kit")),r.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(E.__)("Congratulations, your site has been verified!","google-site-kit")))}}]),SiteVerification}(k.a);j.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,siteVerificationSetup:S.a.func.isRequired,completeSetup:S.a.func,setErrorMessage:S.a.func.isRequired},t.a=j}).call(this,n(13),n(12))},653:function(e,t,n){"use strict";(function(e){var r=n(83),i=n.n(r),a=n(6),o=n.n(a),s=n(7),c=n.n(s),l=n(9),u=n.n(l),d=n(10),p=n.n(d),f=n(4),g=n.n(f),m=n(1),h=n(2),y=n.n(h),v=n(654);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var i=g()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return p()(this,n)}}var k=function(t){u()(WizardStepSearchConsoleProperty,t);var n=_(WizardStepSearchConsoleProperty);function WizardStepSearchConsoleProperty(){return o()(this,WizardStepSearchConsoleProperty),n.apply(this,arguments)}return c()(WizardStepSearchConsoleProperty,[{key:"render",value:function(){var t=this.props,n=t.isVerified,r=t.hasSearchConsoleProperty,a=n&&!r;return e.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--four"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},a?e.createElement(v.a,i()({shouldSetup:a},this.props)):v.a.connected()))))}}]),WizardStepSearchConsoleProperty}(m.a);k.propTypes={searchConsoleSetup:y.a.func.isRequired},t.a=k}).call(this,n(12))},654:function(e,t,n){"use strict";(function(e,r){var i=n(3),a=n.n(i),o=n(14),s=n.n(o),c=n(6),l=n.n(c),u=n(7),d=n.n(u),p=n(23),f=n.n(p),g=n(9),m=n.n(g),h=n(10),y=n.n(h),v=n(4),_=n.n(v),k=n(1),b=n(2),S=n.n(b),E=n(0),R=n(5),C=n(17),w=n(49),N=n(91),L=n(44),x=n(47);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return y()(this,n)}}var j=function(t){m()(SearchConsole,t);var n,i,o=O(SearchConsole);function SearchConsole(t){var n;l()(this,SearchConsole),n=o.call(this,t);var r=e._googlesitekitLegacyData.admin.siteURL;return n.state={loading:!0,sites:!1,selectedURL:r,siteURL:r,connected:!1,errorCode:!1,errorMsg:""},n.handleURLSelect=n.handleURLSelect.bind(f()(n)),n.insertPropertyToSearchConsole=n.insertPropertyToSearchConsole.bind(f()(n)),n.submitPropertyEventHandler=n.submitPropertyEventHandler.bind(f()(n)),n}return d()(SearchConsole,[{key:"componentDidMount",value:(i=s()(a.a.mark((function e(){var t,n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t=this.props,n=t.isAuthenticated,r=t.shouldSetup,n&&r){e.next=3;break}return e.abrupt("return");case 3:this.requestSearchConsoleSiteList();case 4:case"end":return e.stop()}}),e,this)}))),function(){return i.apply(this,arguments)})},{key:"requestSearchConsoleSiteList",value:function(){var e=this,t=this.props.setErrorMessage;s()(a.a.mark((function n(){var r;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,C.c.get(C.b,"search-console","matched-sites");case 3:if(1!==(r=n.sent).length){n.next=9;break}return n.next=7,e.insertPropertyToSearchConsole(r[0].siteURL);case 7:return e.props.searchConsoleSetup(r[0].siteURL),n.abrupt("return");case 9:if(r.length){n.next=11;break}throw{code:"no_property_matched",message:Object(E.__)("Your site has not been added to Search Console yet. Would you like to add it now?","google-site-kit")};case 11:throw t(""),e.setState({loading:!1,selectedURL:r[0].siteURL,sites:r}),{code:"multiple_properties_matched",message:Object(E.sprintf)(
4
+ /* translators: %d: the number of matching properties */
5
+ Object(E.__)("We found %d existing accounts. Please choose which one to use below.","google-site-kit"),r.length)};case 16:n.prev=16,n.t0=n.catch(0),t(n.t0.message),e.setState({loading:!1,errorCode:n.t0.code,errorMsg:n.t0.message});case 20:case"end":return n.stop()}}),n,null,[[0,16]])})))()}},{key:"insertPropertyToSearchConsole",value:(n=s()(a.a.mark((function e(t){var n,r=arguments;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=r.length>1&&void 0!==r[1]&&r[1],e.next=3,C.c.set(C.b,"search-console","site",{siteURL:t});case 3:if(!n){e.next=6;break}return e.next=6,Object(R.w)("search_console_setup","add_new_sc_property");case 6:this.setState({loading:!1,connected:!0});case 7:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"submitPropertyEventHandler",value:function(){var e=this,t=this.state,n=t.selectedURL,r=t.errorCode,i=this.props.setErrorMessage;s()(a.a.mark((function t(){return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,e.insertPropertyToSearchConsole(n,"no_property_matched"===r);case 3:i(""),e.props.searchConsoleSetup(n),t.next=11;break;case 7:t.prev=7,t.t0=t.catch(0),i(t.t0.message[0].message),e.setState({loading:!1,errorCode:t.t0.code,errorMsg:t.t0.message[0].message});case 11:case"end":return t.stop()}}),t,null,[[0,7]])})))()}},{key:"handleURLSelect",value:function(e,t){this.setState({selectedURL:t.getAttribute("data-value")})}},{key:"matchedForm",value:function(){var e=this.state,t=e.sites,n=e.selectedURL;if(!t)return null;var i=t.map((function(e){var t=e.siteURL;return t.startsWith("sc-domain:")&&(
6
+ /* translators: %s: Search Console property domain name */
7
+ t=Object(E.sprintf)(Object(E.__)("%s (domain property)","google-site-kit"),t.replace(/^sc-domain:/,""))),{label:t,value:e.siteURL}}));return r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-module__inputs"},r.createElement(L.j,{enhanced:!0,name:"siteProperty",label:Object(E.__)("Choose URL","google-site-kit"),outlined:!0,onEnhancedChange:this.handleURLSelect,options:i,value:n})),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(x.a,{onClick:this.submitPropertyEventHandler},Object(E.__)("Continue","google-site-kit")),r.createElement(N.a,null)))}},{key:"noSiteForm",value:function(){var e=this.state.siteURL;return r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-module__inputs"},r.createElement(L.k,{label:Object(E.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},r.createElement(L.b,{value:e}))),r.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},r.createElement(x.a,{onClick:this.submitPropertyEventHandler},Object(E.__)("Continue","google-site-kit")),r.createElement(N.a,null)))}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.sites;return t?r.createElement(k.b,null,r.createElement("p",null,Object(E.__)("We’re locating your Search Console account.","google-site-kit")),r.createElement(w.a,null)):0===n.length?this.noSiteForm():this.matchedForm()}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,i=this.state,a=i.errorMsg,o=i.connected;return!n||o?SearchConsole.connected():r.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("Search Console","Service name","google-site-kit")),a&&0<a.length&&r.createElement("p",{className:"googlesitekit-error-text"},a),t&&n&&this.renderForm())}}],[{key:"connected",value:function(){return r.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("Search Console","Service name","google-site-kit")),r.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(E.__)("Your Search Console is set up with Site Kit.","google-site-kit")))}}]),SearchConsole}(k.a);j.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,searchConsoleSetup:S.a.func.isRequired,setErrorMessage:S.a.func.isRequired},t.a=j}).call(this,n(13),n(12))},655:function(e,t,n){"use strict";(function(e,r){var i=n(6),a=n.n(i),o=n(7),s=n.n(o),c=n(9),l=n.n(c),u=n(10),d=n.n(u),p=n(4),f=n.n(p),g=n(1),m=n(2),h=n.n(m),y=n(0),v=n(5),_=n(47);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var i=f()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return d()(this,n)}}var b=function(t){l()(WizardStepCompleteSetup,t);var n=k(WizardStepCompleteSetup);function WizardStepCompleteSetup(t){var r;return a()(this,WizardStepCompleteSetup),r=n.call(this,t),e._googlesitekitLegacyData.setup.hasSearchConsoleProperty?Object(v.w)("plugin_setup","user_verified"):Object(v.w)("plugin_setup","site_verified"),r}return s()(WizardStepCompleteSetup,[{key:"render",value:function(){return r.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--five"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-9-desktop "},r.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(y.__)("Congratulations!","google-site-kit")),r.createElement("p",null,Object(y.__)("You successfully completed the Site Kit setup and connected Search Console. Check the dashboard for more services to connect.","google-site-kit")),r.createElement("div",{className:"googlesitekit-wizard-step__action"},r.createElement(_.a,{id:"wizard-step-five-proceed",onClick:this.props.completeSetup},Object(y.__)("Go to Dashboard","google-site-kit")))),r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--span-3-tablet mdc-layout-grid__cell--span-3-desktop "},r.createElement("div",{className:"googlesitekit-rocket"},r.createElement("img",{className:"googlesitekit-rocket__body",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-body.png"}),r.createElement("img",{className:"googlesitekit-rocket__clouds",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-clouds.png"}),r.createElement("img",{className:"googlesitekit-rocket__dust",alt:"",src:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket-dust.png"}))))))}}]),WizardStepCompleteSetup}(g.a);b.propTypes={completeSetup:h.a.func.isRequired},t.a=b}).call(this,n(13),n(12))},656:function(e,t,n){"use strict";var r=n(6),i=n.n(r),a=n(7),o=n.n(a),s=n(9),c=n.n(s),l=n(10),u=n.n(l),d=n(4),p=n.n(d),f=n(1),g=n(2),m=n.n(g),h=n(12),y=n(18),v=n.n(y),_=n(33);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(r,arguments,i)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(e){c()(WizardProgressStep,e);var t=k(WizardProgressStep);function WizardProgressStep(){return i()(this,WizardProgressStep),t.apply(this,arguments)}return o()(WizardProgressStep,[{key:"render",value:function(){var e=this.props,t=e.currentStep,n=e.step,r=e.title,i=e.status,a=e.warning,o=e.error,s=e.stepKey,c=i;a?c="warning":o&&(c="error");var l=!1;switch(c){case"warning":case"error":l=h.default.createElement(_.a,{id:"exclamation",height:"12",width:"2"});break;case"completed":l=h.default.createElement(_.a,{id:"check",height:"12",width:"16"})}return h.default.createElement("div",{className:v()("googlesitekit-wizard-progress-step","googlesitekit-wizard-progress-step--".concat(n),"googlesitekit-wizard-progress-step--".concat(s),{"googlesitekit-wizard-progress-step--current":t})},h.default.createElement("div",{className:"googlesitekit-wizard-progress-step__number-wrapper"},h.default.createElement("div",{className:v()("googlesitekit-wizard-progress-step__number","googlesitekit-wizard-progress-step__number--".concat(c))},h.default.createElement("span",{className:v()("googlesitekit-wizard-progress-step__number-text","googlesitekit-wizard-progress-step__number-text--".concat(c))},n),l&&h.default.createElement("span",{className:v()("googlesitekit-wizard-progress-step__number-icon","googlesitekit-wizard-progress-step__number-icon--".concat(c))},l))),h.default.createElement("p",{className:"googlesitekit-wizard-progress-step__text"},r))}}]),WizardProgressStep}(f.a);b.propTypes={currentStep:m.a.bool.isRequired,step:m.a.number.isRequired,title:m.a.string,status:m.a.string,warning:m.a.bool,error:m.a.bool},b.defaultProps={title:"",status:"",warning:!1,error:!1,removeFirstStep:!1},t.a=b},91:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),i=n(28);t.a=function HelpLink(){var t=Object(r.__)("Need help?","google-site-kit");return e.createElement(i.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},92:function(e,t,n){"use strict";(function(e){var r=n(1),i=n(8),a=n.n(i),o=n(138),s=n(169),c=n(171),l=n(20),u=a.a.useSelect;t.a=function Header(){var t=u((function(e){return e(l.c).isAuthenticated()}));return e.createElement(r.b,null,e.createElement("header",{className:"googlesitekit-header"},e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(o.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&e.createElement(s.a,null))))),e.createElement(c.a,null))}}).call(this,n(12))}}]);
dist/assets/js/chunk-googlesitekit-setup-wizard-proxy-17b9a681d793c344b8b7.js DELETED
@@ -1,5 +0,0 @@
1
- (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[3],{150:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(28);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(LayoutHeader,t);var n=k(LayoutHeader);function LayoutHeader(){return a()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,r=t.ctaLabel,a=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":a,"mdc-layout-grid__cell--span-12-desktop":!a,"mdc-layout-grid__cell--span-8-tablet":!a})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),a&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(v.a,{href:a,external:!0,inherit:!0},r)))))}}]),LayoutHeader}(p.a);b.propTypes={title:m.a.string,ctaLabel:m.a.string,ctaLink:m.a.string},b.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=b}).call(this,n(12))},151:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(80);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return a()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,r=t.ctaLink,a=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},r&&n&&e.createElement(g.a,{className:"googlesitekit-data-block__source",name:n,href:r,external:!0}),a))))}}]),LayoutFooter}(p.a);v.propTypes={ctaLabel:m.a.string,ctaLink:m.a.string},t.a=v}).call(this,n(12))},165:function(e,t,n){"use strict";(function(e,r){var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(22),p=n.n(f),h=n(8),m=n.n(h),g=n(9),y=n.n(g),v=n(3),k=n.n(v),b=n(1),_=n(0),R=n(5),E=n(109),O=n(47),x=n(166),w=n(114);function L(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return y()(this,n)}}var C=function(t){m()(UserMenu,t);var n,a=L(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=a.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(p()(t)),t.handleMenuClose=t.handleMenuClose.bind(p()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(p()(t)),t.handleDialog=t.handleDialog.bind(p()(t)),t.handleDialogClose=t.handleDialogClose.bind(p()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(p()(t)),t.menuButtonRef=Object(b.h)(),t.menuRef=Object(b.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var r=e._googlesitekitLegacyData.admin.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:e.location.assign(r);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(R.d)(),document.location=Object(R.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData.admin,n=t.userData,a=n.email,i=void 0===a?"":a,o=n.picture,c=void 0===o?"":o,s=t.proxyPermissionsURL,l=this.state,u=l.dialogActive,d=l.menuOpen;return r.createElement(b.b,null,r.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},r.createElement(O.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:c?r.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},r.createElement("img",{className:"mdc-button__icon--image",src:c,alt:Object(_.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},i),r.createElement(x.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(_.__)("Disconnect","google-site-kit")].concat(s?[Object(_.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),r.createElement(w.a,null,r.createElement(E.a,{dialogActive:u,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(_.__)("Disconnect","google-site-kit"),subtitle:Object(_.__)("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:Object(_.__)("Disconnect","google-site-kit"),provides:[],danger:!0})))}}]),UserMenu}(b.a);t.a=C}).call(this,n(15),n(12))},166:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(Menu,t);var n=y(Menu);function Menu(e){var t;return a()(this,Menu),(t=n.call(this,e)).menuRef=Object(p.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new g.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,r=t.menuItems,a=t.onSelected,i=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:i,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},r.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:a.bind(null,n),onKeyDown:a.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(p.a);v.propTypes={menuOpen:m.a.bool.isRequired,menuItems:m.a.array.isRequired,id:m.a.string.isRequired},t.a=v}).call(this,n(12))},167:function(e,t,n){"use strict";var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(83);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(ErrorNotification,e);var t=h(ErrorNotification);function ErrorNotification(){return a()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(p.a)("googlesitekit.ErrorNotification")(m)},208:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return E})),n.d(t,"a",(function(){return w})),n.d(t,"c",(function(){return L}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),l=n(19),u=n.n(l),d=n(246),f=n.n(d),p=n(63),h=n(45),m=n(162),g=n(234),y=n(214),v=n(215),k=n(216),b=n(32);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var E=function(){var t=s()(a.a.mark((function t(n){var r,i,o,c,l;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e._googlesitekitLegacyData.admin,i=r.homeURL,o=r.ampMode,c={tagverify:1,timestamp:Date.now()},t.next=4,O(Object(h.a)(i,c),n);case 4:if((l=t.sent)||b.b!==o){t.next=9;break}return t.next=8,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map(function(){var e=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O(Object(h.a)(t.link,R(R({},c),{},{amp:1})),n);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).pop()}));case 8:l=t.sent;case 9:return t.abrupt("return",Promise.resolve(l||null));case 10:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),O=function(){var e=s()(a.a.mark((function e(t,n){var r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,fetch(t,{credentials:"omit"}).then((function(e){return e.text()}));case 3:return r=e.sent,e.abrupt("return",x(r,n)||null);case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",null);case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t,n){return e.apply(this,arguments)}}(),x=function(e,t){var n=({adsense:y.a,analytics:v.a,tagmanager:k.b,setup:g.a}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},w=function(e,t){var n=t.find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},L=f()(function(){var e=s()(a.a.mark((function e(t){var n,r,i,o;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.homeURL,r=t.ampMode,u()(Object(m.a)(n),"homeURL must be valid URL"),i=[n],b.b!==r){e.next=14;break}return e.prev=4,e.next=7,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return Object(h.a)(e.link,{amp:1})})).pop()}));case 7:(o=e.sent)&&i.push(o),e.next=14;break;case 11:return e.prev=11,e.t0=e.catch(4),e.abrupt("return",i);case 14:return e.abrupt("return",i);case 15:case"end":return e.stop()}}),e,null,[[4,11]])})));return function(t){return e.apply(this,arguments)}}())}).call(this,n(15))},212:function(e,t,n){"use strict";t.a=[/<script[^>]*>[^>]+?www.googletagmanager.com\/gtm[^>]+?['|"](GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtm\.js\?id=(GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/ns.html\?id=(GTM-[0-9A-Z]+)['|"]/,/<amp-analytics [^>]*config=['|"]https:\/\/www.googletagmanager.com\/amp.json\?id=(GTM-[0-9A-Z]+)['|"]/]},214:function(e,t,n){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},215:function(e,t,n){"use strict";t.a=[/<script [^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtag\/js\?id=(UA-.*?)['|"][^>]*><\/script>/,/<script[^>]*>[^<]+google-analytics\.com\/analytics\.js[^<]+(UA-\d+-\d+)/,/__gaTracker\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/ga\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/_gaq.push\( ?\[ ?['|"]_setAccount['|"], ?['|"](UA-.*?)['|"] ?] ?\)/,/<amp-analytics [^>]*type="gtag"[^>]*>[^<]*<script type="application\/json">[^<]*"gtag_id":\s*"(UA-[^"]+)"/,/<amp-analytics [^>]*type="googleanalytics"[^>]*>[^<]*<script type="application\/json">[^<]*"account":\s*"(UA-[^"]+)"/]},216:function(e,t,n){"use strict";function r(e){return(parseInt(e,10)||0)>0}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a.a}));var a=n(212)},234:function(e,t,n){"use strict";t.a=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/]},268:function(e,t,n){"use strict";(function(e){var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),l=n(6),u=n.n(l),d=n(7),f=n.n(d),p=n(22),h=n.n(p),m=n(8),g=n.n(m),y=n(9),v=n.n(y),k=n(3),b=n.n(k),_=n(1),R=n(2),E=n.n(R),O=n(18),x=n.n(O),w=n(63),L=n(0),C=n(5),S=n(269),j=n(50);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=b()(e);if(t){var a=b()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var N=function(t){g()(OptIn,t);var n,r=D(OptIn);function OptIn(e){var t;return u()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(j.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(h()(t)),t}return f()(OptIn,[{key:"handleOptIn",value:(n=s()(a.a.mark((function e(t){var n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(C.i)("googlesitekit_tracking_optin"),Object(j.b)(n),!n){e.next=6;break}return e.next=6,Object(j.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(w.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,a=this.props,i=a.id,o=a.name,c=a.className,s=Object(L.sprintf)(
2
- /* translators: %s: privacy policy URL */
3
- Object(L.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:x()("googlesitekit-opt-in",c)},e.createElement(S.a,{id:i,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(C.t)(s,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(_.a);N.propTypes={id:E.a.string,name:E.a.string,className:E.a.string,optinAction:E.a.string},N.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=N}).call(this,n(12))},269:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(43);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(Checkbox,t);var n=k(Checkbox);function Checkbox(e){var t;return a()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(p.h)(),t.checkboxRef=Object(p.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,a=t.name,i=t.value,o=t.checked,c=t.disabled,s=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:y()("mdc-checkbox",{"mdc-checkbox--disabled":c}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:a,value:i,checked:o,disabled:c,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},s))}}]),Checkbox}(p.a);b.propTypes={onChange:m.a.func.isRequired,id:m.a.string.isRequired,name:m.a.string.isRequired,value:m.a.string.isRequired,checked:m.a.bool,disabled:m.a.bool,children:m.a.node.isRequired},b.defaultProps={checked:!1,disabled:!1},t.a=b}).call(this,n(12))},27:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),l=n(9),u=n.n(l),d=n(3),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(150),k=n(151);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(Layout,t);var n=b(Layout);function Layout(){return a()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,r=t.footer,a=t.children,i=t.title,o=t.headerCtaLabel,c=t.headerCtaLink,s=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,f=t.fill,p=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":f,"googlesitekit-layout--relative":p})},n&&e.createElement(v.a,{title:i,ctaLabel:o,ctaLink:c}),a,r&&e.createElement(k.a,{ctaLabel:s,ctaLink:l,footerContent:u}))}}]),Layout}(p.a);_.propTypes={header:m.a.bool,footer:m.a.bool,children:m.a.node.isRequired,title:m.a.string,headerCtaLabel:m.a.string,headerCtaLink:m.a.string,footerCtaLabel:m.a.string,footerCtaLink:m.a.string,footerContent:m.a.node,className:m.a.string,fill:m.a.bool,relative:m.a.bool},_.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=_}).call(this,n(12))},32:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return i}));var r="core/site",a="primary",i="secondary"},370:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return M}));var a=n(44),i=n.n(a),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(8),d=n.n(u),f=n(9),p=n.n(f),h=n(3),m=n.n(h),g=n(4),y=n.n(g),v=n(14),k=n.n(v),b=n(1),_=n(0),R=n(2),E=n.n(R),O=n(119),x=n(49),w=n(208),L=n(17),C=n(28);function S(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return j(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return j(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function j(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return p()(this,n)}}var N=[k()(y.a.mark((function t(){var n;return y.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.location.hostname,!["localhost","127.0.0.1"].includes(n)&&!n.match(/\.(example|invalid|localhost|test)$/)){t.next=3;break}throw"invalid_hostname";case 3:case"end":return t.stop()}}),t)}))),k()(y.a.mark((function e(){var t,n,r;return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,L.c.set(L.a,"site","setup-tag");case 2:return t=e.sent,n=t.token,e.next=6,Object(w.b)("setup").catch((function(){throw"tag_fetch_failed"}));case 6:if(r=e.sent,n===r){e.next=9;break}throw"setup_token_mismatch";case 9:case"end":return e.stop()}}),e)})))],M=function(t){d()(CompatibilityChecks,t);var n,a=D(CompatibilityChecks);function CompatibilityChecks(t){var n;c()(this,CompatibilityChecks);var r=e._googlesitekitLegacyData.setup.isSiteKitConnected;return(n=a.call(this,t)).state={complete:r,error:null,developerPlugin:{}},n}return l()(CompatibilityChecks,[{key:"componentDidMount",value:(n=k()(y.a.mark((function e(){var t,n,r,a;return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.state.complete){e.next=2;break}return e.abrupt("return");case 2:e.prev=2,t=S(N),e.prev=4,t.s();case 6:if((n=t.n()).done){e.next=12;break}return r=n.value,e.next=10,r();case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),t.e(e.t0);case 17:return e.prev=17,t.f(),e.finish(17);case 20:e.next=28;break;case 22:return e.prev=22,e.t1=e.catch(2),e.next=26,L.c.get(L.a,"site","developer-plugin");case 26:a=e.sent,this.setState({error:e.t1,developerPlugin:a});case 28:this.setState({complete:!0});case 29:case"end":return e.stop()}}),e,this,[[2,22],[4,14,17,20]])}))),function(){return n.apply(this,arguments)})},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,n=e.active,r=e.installURL,a=e.activateURL,i=e.configureURL;return!t&&r?{labelHTML:Object(_.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:r,external:!1}:t&&!n&&a?{labelHTML:Object(_.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:a,external:!1}:t&&n&&i?{labelHTML:Object(_.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:{labelHTML:Object(_.__)('Learn how<span class="screen-reader-text"> to install and use the helper plugin</span>',"google-site-kit"),href:"https://sitekit.withgoogle.com/documentation/using-site-kit-on-a-staging-environment/",external:!0}}},{key:"renderError",value:function(e){var t=this.state.developerPlugin.installed,n=this.helperCTA(),a=n.labelHTML,i=n.href,o=n.external;switch(e){case"invalid_hostname":case"tag_fetch_failed":return r.createElement(b.b,null,!t&&Object(_.__)("Looks like this may be a staging environment. If so, you’ll need to install a helper plugin and verify your production site in Search Console.","google-site-kit"),t&&Object(_.__)("Looks like this may be a staging environment and you already have the helper plugin. Before you can use Site Kit, please make sure you’ve provided the necessary credentials in the Authentication section and verified your production site in Search Console.","google-site-kit")," ",r.createElement(C.a,{href:i,dangerouslySetInnerHTML:{__html:a},external:o,inherit:!0}));case"setup_token_mismatch":return Object(_.__)("Looks like you may be using a caching plugin which could interfere with setup. Please deactivate any caching plugins before setting up Site Kit. You may reactivate them once setup has been completed.","google-site-kit")}}},{key:"render",value:function(){var e,t,n=this.state,a=n.complete,o=n.error,c=this.props,s=c.children,l=i()(c,["children"]);return o&&(e=r.createElement(b.b,null,r.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement(O.a,null),r.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(_.__)("Your site may not be ready for Site Kit","google-site-kit"))),r.createElement("p",null,this.renderError(o))))),a||(t=r.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},r.createElement("small",null,Object(_.__)("Checking Compatibility…","google-site-kit")),r.createElement(x.a,{small:!0,compress:!0}))),s({restProps:l,complete:a,error:o,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(b.a);M.propTypes={children:E.a.func.isRequired}}).call(this,n(15),n(12))},371:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return S}));var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(22),p=n.n(f),h=n(8),m=n.n(h),g=n(9),y=n.n(g),v=n(3),k=n.n(v),b=n(1),_=n(0),R=n(45),E=n(5),O=n(17),x=n(109),w=n(28),L=n(114);function C(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return y()(this,n)}}var S=function(t){m()(ResetButton,t);var n,a=C(ResetButton);function ResetButton(t){var n;l()(this,ResetButton),n=a.call(this,t);var r=e._googlesitekitBaseData.splashURL;return n.state={dialogActive:!1,postResetURL:Object(R.a)(r,{notification:"reset_success"})},n.handleDialog=n.handleDialog.bind(p()(n)),n.handleUnlinkConfirm=n.handleUnlinkConfirm.bind(p()(n)),n.handleCloseModal=n.handleCloseModal.bind(p()(n)),n}return d()(ResetButton,[{key:"componentDidMount",value:function(){e.addEventListener("keyup",this.handleCloseModal,!1)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("keyup",this.handleCloseModal)}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O.c.set(O.a,"site","reset");case 2:Object(E.d)(),this.handleDialog(),document.location=this.state.postResetURL;case 5:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleCloseModal",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1})}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive}}))}},{key:"render",value:function(){var e=this,t=this.props.children,n=this.state.dialogActive;return r.createElement(b.b,null,r.createElement(w.a,{className:"googlesitekit-reset-button",onClick:function(){return e.setState({dialogActive:!0})},inherit:!0},t||Object(_.__)("Reset Site Kit","google-site-kit")),r.createElement(L.a,null,r.createElement(x.a,{dialogActive:n,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(_.__)("Reset Site Kit","google-site-kit"),subtitle:Object(_.__)("Resetting this site will remove access to all services. After disconnecting, you will need to re-authorize your access to restore service.","google-site-kit"),confirmButton:Object(_.__)("Reset","google-site-kit"),provides:[],danger:!0})))}}]),ResetButton}(b.a)}).call(this,n(15),n(12))},647:function(e,t,n){"use strict";n.r(t),function(e,r){var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(8),p=n.n(f),h=n(9),m=n.n(h),g=n(3),y=n.n(g),v=n(1),k=n(478),b=n.n(k),_=n(13),R=n(0),E=n(289),O=n(5),x=n(90),w=n(47),L=n(371),C=n(27),S=n(37),j=n(268),D=n(370);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=y()(e);if(t){var a=y()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return m()(this,n)}}var M=function(t){p()(SetupUsingProxy,t);var n=N(SetupUsingProxy);function SetupUsingProxy(t){var r;l()(this,SetupUsingProxy),r=n.call(this,t);var a=e._googlesitekitLegacyData.admin,i=a.proxySetupURL,o=a.siteURL,c=e._googlesitekitLegacyData.setup,s=c.isSiteKitConnected,u=c.isResettable,d=c.errorMessage,f=e._googlesitekitLegacyData.permissions.canSetup;return r.state={canSetup:f,errorMessage:d,isSiteKitConnected:s,isResettable:u,completeSetup:!1,proxySetupURL:i,resetSuccess:"reset_success"===Object(E.a)(location.href,"notification"),context:Object(E.a)(location.href,"googlesitekit_context"),siteHostname:b.a.toUnicode(new URL(o).hostname)},r}return d()(SetupUsingProxy,[{key:"isSetupFinished",value:function(){var e=this.state,t=e.isSiteKitConnected,n=e.completeSetup;return t&&n}},{key:"render",value:function(){if(this.isSetupFinished()){var t=Object(O.m)("googlesitekit-dashboard",{notification:"authentication_success"});Object(_.delay)((function(){e.location.replace(t)}),500,"later")}var n,a,o,s=this.state,l=s.context,u=s.errorMessage,d=s.isResettable,f=s.proxySetupURL,p=s.resetSuccess,h=s.siteHostname,m=d;"revoked"===l?(n=Object(R.sprintf)(
4
- /* translators: %s is the site's hostname. (e.g. example.com) */
5
- Object(R.__)("You revoked access to Site Kit for %s","google-site-kit"),h),a=Object(R.__)('Site Kit will no longer have access to your account. If you’d like to reconnect Site Kit, click "Start Setup" below to generate new credentials.',"google-site-kit"),o=Object(R.__)("Sign in with Google","google-site-kit")):m?(n=Object(R.__)("Sign in with Google to configure Site Kit","google-site-kit"),a=Object(R.__)("To use Site Kit, sign in with your Google account. The Site Kit service will guide you through 3 simple steps to complete the connection and configure the plugin.","google-site-kit"),o=Object(R.__)("Sign in with Google","google-site-kit")):(n=Object(R.__)("Sign in with Google to set up Site Kit","google-site-kit"),a=Object(R.__)("The Site Kit service will guide you through 3 simple setup steps.","google-site-kit"),o=Object(R.__)("Start setup","google-site-kit"));var g=function(){var t=c()(i.a.mark((function t(n){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n.preventDefault(),t.next=3,Object(O.w)("plugin_setup","proxy_start_setup_landing_page");case 3:e.location.assign(f);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return r.createElement(v.b,null,r.createElement(x.a,null),u&&r.createElement(S.a,{id:"setup_error",type:"win-error",title:Object(R.__)("Oops! There was a problem during set up. Please try again.","google-site-kit"),description:u,isDismissable:!1}),p&&r.createElement(S.a,{id:"reset_success",title:Object(R.__)("Site Kit by Google was successfully reset.","google-site-kit"),isDismissable:!1}),r.createElement("div",{className:"googlesitekit-wizard"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement(C.a,null,r.createElement("section",{className:"googlesitekit-wizard-progress"},r.createElement("div",{className:"googlesitekit-setup__footer"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("h1",{className:"googlesitekit-setup__title"},n),r.createElement("p",{className:"googlesitekit-setup__description"},a),r.createElement(D.a,null,(function(e){var t=e.complete,n=e.inProgressFeedback,a=e.CTAFeedback;return r.createElement(v.b,null,a,r.createElement(j.a,{optinAction:"analytics_optin_setup_fallback"}),r.createElement("div",{className:"googlesitekit-start-setup-wrap"},r.createElement(w.a,{className:"googlesitekit-start-setup",href:f,onClick:g,disabled:!t},o),n,d&&r.createElement(L.a,null)))})))))))))))))}}]),SetupUsingProxy}(v.a);t.default=M}.call(this,n(15),n(12))},90:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(8),l=n.n(s),u=n(9),d=n.n(u),f=n(3),p=n.n(f),h=n(1),m=n(135),g=n(165),y=n(167);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return d()(this,n)}}var k=function(t){l()(Header,t);var n=v(Header);function Header(){return i()(this,Header),n.apply(this,arguments)}return c()(Header,[{key:"render",value:function(){var t=e._googlesitekitLegacyData.setup.isAuthenticated;return r.createElement(h.b,null,r.createElement("header",{className:"googlesitekit-header"},r.createElement("section",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},r.createElement(m.a,null)),r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&r.createElement(g.a,null))))),r.createElement(y.a,null))}}]),Header}(h.a);t.a=k}).call(this,n(15),n(12))}}]);
 
 
 
 
 
dist/assets/js/chunk-googlesitekit-setup-wizard-proxy-48adf52bf605d60b5c05.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
1
+ (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[3],{154:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(28);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(LayoutHeader,t);var n=k(LayoutHeader);function LayoutHeader(){return a()(this,LayoutHeader),n.apply(this,arguments)}return o()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,r=t.ctaLabel,a=t.ctaLink;return e.createElement("header",{className:"googlesitekit-layout__header"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},n&&e.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--align-middle","mdc-layout-grid__cell--span-4-phone",{"mdc-layout-grid__cell--span-6-desktop":a,"mdc-layout-grid__cell--span-12-desktop":!a,"mdc-layout-grid__cell--span-8-tablet":!a})},e.createElement("h3",{className:"googlesitekit-subheading-1 googlesitekit-layout__header-title"},n)),a&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-phone mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-tablet "},e.createElement(v.a,{href:a,external:!0,inherit:!0},r)))))}}]),LayoutHeader}(p.a);b.propTypes={title:m.a.string,ctaLabel:m.a.string,ctaLink:m.a.string},b.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=b}).call(this,n(12))},155:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(82);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(LayoutFooter,t);var n=y(LayoutFooter);function LayoutFooter(){return a()(this,LayoutFooter),n.apply(this,arguments)}return o()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,r=t.ctaLink,a=t.footerContent;return e.createElement("footer",{className:"googlesitekit-layout__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},r&&n&&e.createElement(g.a,{className:"googlesitekit-data-block__source",name:n,href:r,external:!0}),a))))}}]),LayoutFooter}(p.a);v.propTypes={ctaLabel:m.a.string,ctaLink:m.a.string},t.a=v}).call(this,n(12))},169:function(e,t,n){"use strict";(function(e,r){var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(23),p=n.n(f),h=n(9),m=n.n(h),g=n(10),y=n.n(g),v=n(4),k=n.n(v),b=n(1),_=n(0),R=n(8),E=n.n(R),O=n(5),w=n(111),x=n(47),L=n(170),C=n(116),S=n(34),j=n(20);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return y()(this,n)}}var A=E.a.withSelect,N=function(t){m()(UserMenu,t);var n,a=D(UserMenu);function UserMenu(e){var t;return l()(this,UserMenu),(t=a.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(p()(t)),t.handleMenuClose=t.handleMenuClose.bind(p()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(p()(t)),t.handleDialog=t.handleDialog.bind(p()(t)),t.handleDialogClose=t.handleDialogClose.bind(p()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(p()(t)),t.menuButtonRef=Object(b.h)(),t.menuRef=Object(b.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var r=this.props.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:if(!r)return;e.location.assign(r);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(O.d)(),document.location=Object(O.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this.props,t=e.proxyPermissionsURL,n=e.userEmail,a=e.userPicture,i=this.state,o=i.dialogActive,c=i.menuOpen;return n?r.createElement(b.b,null,r.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},r.createElement(x.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:a?r.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},r.createElement("img",{className:"mdc-button__icon--image",src:a,alt:Object(_.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:c,ariaControls:"user-menu"},n),r.createElement(L.a,{ref:this.menuRef,menuOpen:c,menuItems:[Object(_.__)("Disconnect","google-site-kit")].concat(t?[Object(_.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),r.createElement(C.a,null,r.createElement(w.a,{dialogActive:o,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(_.__)("Disconnect","google-site-kit"),subtitle:Object(_.__)("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:Object(_.__)("Disconnect","google-site-kit"),provides:[],danger:!0}))):null}}]),UserMenu}(b.a);t.a=A((function(e){return{proxyPermissionsURL:e(S.c).getProxyPermissionsURL(),userEmail:e(j.c).getEmail(),userPicture:e(j.c).getPicture()}}))(N)}).call(this,n(13),n(12))},170:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var v=function(t){s()(Menu,t);var n=y(Menu);function Menu(e){var t;return a()(this,Menu),(t=n.call(this,e)).menuRef=Object(p.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new g.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,r=t.menuItems,a=t.onSelected,i=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:i,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},r.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:a.bind(null,n),onKeyDown:a.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(p.a);v.propTypes={menuOpen:m.a.bool.isRequired,menuItems:m.a.array.isRequired,id:m.a.string.isRequired},t.a=v}).call(this,n(12))},171:function(e,t,n){"use strict";var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(85);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var m=function(e){s()(ErrorNotification,e);var t=h(ErrorNotification);function ErrorNotification(){return a()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(p.a)("googlesitekit.ErrorNotification")(m)},212:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return E})),n.d(t,"a",(function(){return x})),n.d(t,"c",(function(){return L}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),l=n(19),u=n.n(l),d=n(251),f=n.n(d),p=n(65),h=n(48),m=n(167),g=n(237),y=n(217),v=n(218),k=n(219),b=n(34);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var E=function(){var t=s()(a.a.mark((function t(n){var r,i,o,c,l;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e._googlesitekitLegacyData.admin,i=r.homeURL,o=r.ampMode,c={tagverify:1,timestamp:Date.now()},t.next=4,O(Object(h.a)(i,c),n);case 4:if((l=t.sent)||b.b!==o){t.next=9;break}return t.next=8,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map(function(){var e=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O(Object(h.a)(t.link,R(R({},c),{},{amp:1})),n);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).pop()}));case 8:l=t.sent;case 9:return t.abrupt("return",Promise.resolve(l||null));case 10:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),O=function(){var e=s()(a.a.mark((function e(t,n){var r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,fetch(t,{credentials:"omit"}).then((function(e){return e.text()}));case 3:return r=e.sent,e.abrupt("return",w(r,n)||null);case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",null);case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t,n){return e.apply(this,arguments)}}(),w=function(e,t){var n=({adsense:y.a,analytics:v.a,tagmanager:k.b,setup:g.a}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},x=function(e,t){var n=t.find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},L=f()(function(){var e=s()(a.a.mark((function e(t){var n,r,i,o;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.homeURL,r=t.ampMode,u()(Object(m.a)(n),"homeURL must be valid URL"),i=[n],b.b!==r){e.next=14;break}return e.prev=4,e.next=7,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return Object(h.a)(e.link,{amp:1})})).pop()}));case 7:(o=e.sent)&&i.push(o),e.next=14;break;case 11:return e.prev=11,e.t0=e.catch(4),e.abrupt("return",i);case 14:return e.abrupt("return",i);case 15:case"end":return e.stop()}}),e,null,[[4,11]])})));return function(t){return e.apply(this,arguments)}}())}).call(this,n(13))},215:function(e,t,n){"use strict";t.a=[/<script[^>]*>[^>]+?www.googletagmanager.com\/gtm[^>]+?['|"](GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtm\.js\?id=(GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/ns.html\?id=(GTM-[0-9A-Z]+)['|"]/,/<amp-analytics [^>]*config=['|"]https:\/\/www.googletagmanager.com\/amp.json\?id=(GTM-[0-9A-Z]+)['|"]/]},217:function(e,t,n){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},218:function(e,t,n){"use strict";t.a=[/<script [^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtag\/js\?id=(UA-.*?)['|"][^>]*><\/script>/,/<script[^>]*>[^<]+google-analytics\.com\/analytics\.js[^<]+(UA-\d+-\d+)/,/__gaTracker\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/ga\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/_gaq.push\( ?\[ ?['|"]_setAccount['|"], ?['|"](UA-.*?)['|"] ?] ?\)/,/<amp-analytics [^>]*type="gtag"[^>]*>[^<]*<script type="application\/json">[^<]*"gtag_id":\s*"(UA-[^"]+)"/,/<amp-analytics [^>]*type="googleanalytics"[^>]*>[^<]*<script type="application\/json">[^<]*"account":\s*"(UA-[^"]+)"/]},219:function(e,t,n){"use strict";function r(e){return(parseInt(e,10)||0)>0}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a.a}));var a=n(215)},237:function(e,t,n){"use strict";t.a=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/]},27:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(154),k=n(155);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var _=function(t){s()(Layout,t);var n=b(Layout);function Layout(){return a()(this,Layout),n.apply(this,arguments)}return o()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,r=t.footer,a=t.children,i=t.title,o=t.headerCtaLabel,c=t.headerCtaLink,s=t.footerCtaLabel,l=t.footerCtaLink,u=t.footerContent,d=t.className,f=t.fill,p=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":f,"googlesitekit-layout--relative":p})},n&&e.createElement(v.a,{title:i,ctaLabel:o,ctaLink:c}),a,r&&e.createElement(k.a,{ctaLabel:s,ctaLink:l,footerContent:u}))}}]),Layout}(p.a);_.propTypes={header:m.a.bool,footer:m.a.bool,children:m.a.node.isRequired,title:m.a.string,headerCtaLabel:m.a.string,headerCtaLink:m.a.string,footerCtaLabel:m.a.string,footerCtaLink:m.a.string,footerContent:m.a.node,className:m.a.string,fill:m.a.bool,relative:m.a.bool},_.defaultProps={header:!1,footer:!1,title:"",headerCtaLabel:"",headerCtaLink:"",footerCtaLabel:"",footerCtaLink:"",footerContent:null,className:"",fill:!1,relative:!1},t.a=_}).call(this,n(12))},270:function(e,t,n){"use strict";(function(e){var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),l=n(6),u=n.n(l),d=n(7),f=n.n(d),p=n(23),h=n.n(p),m=n(9),g=n.n(m),y=n(10),v=n.n(y),k=n(4),b=n.n(k),_=n(1),R=n(2),E=n.n(R),O=n(18),w=n.n(O),x=n(65),L=n(0),C=n(5),S=n(271),j=n(50);function D(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=b()(e);if(t){var a=b()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var A=function(t){g()(OptIn,t);var n,r=D(OptIn);function OptIn(e){var t;return u()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(j.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(h()(t)),t}return f()(OptIn,[{key:"handleOptIn",value:(n=s()(a.a.mark((function e(t){var n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(C.i)("googlesitekit_tracking_optin"),Object(j.b)(n),!n){e.next=6;break}return e.next=6,Object(j.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(x.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,a=this.props,i=a.id,o=a.name,c=a.className,s=Object(L.sprintf)(
2
+ /* translators: %s: privacy policy URL */
3
+ Object(L.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:w()("googlesitekit-opt-in",c)},e.createElement(S.a,{id:i,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(C.t)(s,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(_.a);A.propTypes={id:E.a.string,name:E.a.string,className:E.a.string,optinAction:E.a.string},A.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=A}).call(this,n(12))},271:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),l=n(10),u=n.n(l),d=n(4),f=n.n(d),p=n(1),h=n(2),m=n.n(h),g=n(18),y=n.n(g),v=n(44);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=f()(e);if(t){var a=f()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return u()(this,n)}}var b=function(t){s()(Checkbox,t);var n=k(Checkbox);function Checkbox(e){var t;return a()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(p.h)(),t.checkboxRef=Object(p.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,a=t.name,i=t.value,o=t.checked,c=t.disabled,s=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:y()("mdc-checkbox",{"mdc-checkbox--disabled":c}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:a,value:i,checked:o,disabled:c,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},s))}}]),Checkbox}(p.a);b.propTypes={onChange:m.a.func.isRequired,id:m.a.string.isRequired,name:m.a.string.isRequired,value:m.a.string.isRequired,checked:m.a.bool,disabled:m.a.bool,children:m.a.node.isRequired},b.defaultProps={checked:!1,disabled:!1},t.a=b}).call(this,n(12))},34:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return i}));var r="core/site",a="primary",i="secondary"},369:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return U}));var a=n(45),i=n.n(a),o=n(6),c=n.n(o),s=n(7),l=n.n(s),u=n(9),d=n.n(u),f=n(10),p=n.n(f),h=n(4),m=n.n(h),g=n(3),y=n.n(g),v=n(14),k=n.n(v),b=n(1),_=n(0),R=n(2),E=n.n(R),O=n(41),w=n.n(O),x=n(54),L=n(212),C=n(28),S=n(120),j=n(49);function D(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return A(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return A(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function A(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return p()(this,n)}}var M=[k()(y.a.mark((function t(){var n;return y.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.location.hostname,!["localhost","127.0.0.1"].includes(n)&&!n.match(/\.(example|invalid|localhost|test)$/)){t.next=3;break}throw"invalid_hostname";case 3:case"end":return t.stop()}}),t)}))),k()(y.a.mark((function e(){var t,n,r;return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.a.set("core","site","setup-tag");case 2:return t=e.sent,n=t.token,e.next=6,Object(L.b)("setup").catch((function(){throw"check_fetch_failed"}));case 6:if(r=e.sent,n===r){e.next=9;break}throw"setup_token_mismatch";case 9:case"end":return e.stop()}}),e)}))),k()(y.a.mark((function e(){var t,n,r;return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w.a.get("core","site","health-checks",void 0,{useCache:!1}).catch((function(){throw"check_fetch_failed"}));case 2:if(null==(r=e.sent)||null===(t=r.checks)||void 0===t||null===(n=t.googleAPI)||void 0===n?void 0:n.pass){e.next=5;break}throw"google_api_connection_fail";case 5:case"end":return e.stop()}}),e)}))),k()(y.a.mark((function e(){return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch("https://cdn.ampproject.org/v0.js").catch((function(){throw"amp_cdn_restricted"}));case 2:if(e.sent.ok){e.next=5;break}throw"amp_cdn_restricted";case 5:case"end":return e.stop()}}),e)})))],U=function(t){d()(CompatibilityChecks,t);var n,a=N(CompatibilityChecks);function CompatibilityChecks(t){var n;c()(this,CompatibilityChecks);var r=e._googlesitekitLegacyData.setup.isSiteKitConnected;return(n=a.call(this,t)).state={complete:r,error:null,developerPlugin:{}},n}return l()(CompatibilityChecks,[{key:"componentDidMount",value:(n=k()(y.a.mark((function e(){var t,n,r,a;return y.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.state.complete){e.next=2;break}return e.abrupt("return");case 2:e.prev=2,t=D(M),e.prev=4,t.s();case 6:if((n=t.n()).done){e.next=12;break}return r=n.value,e.next=10,r();case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),t.e(e.t0);case 17:return e.prev=17,t.f(),e.finish(17);case 20:e.next=28;break;case 22:return e.prev=22,e.t1=e.catch(2),e.next=26,w.a.get("core","site","developer-plugin");case 26:a=e.sent,this.setState({error:e.t1,developerPlugin:a});case 28:this.setState({complete:!0});case 29:case"end":return e.stop()}}),e,this,[[2,22],[4,14,17,20]])}))),function(){return n.apply(this,arguments)})},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,n=e.active,r=e.installURL,a=e.activateURL,i=e.configureURL;return!t&&r?{labelHTML:Object(_.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:r,external:!1}:t&&!n&&a?{labelHTML:Object(_.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:a,external:!1}:t&&n&&i?{labelHTML:Object(_.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:{labelHTML:Object(_.__)('Learn how<span class="screen-reader-text"> to install and use the helper plugin</span>',"google-site-kit"),href:"https://sitekit.withgoogle.com/documentation/using-site-kit-on-a-staging-environment/",external:!0}}},{key:"renderError",value:function(e){var t=this.state.developerPlugin.installed,n=this.helperCTA(),a=n.labelHTML,i=n.href,o=n.external;switch(e){case"invalid_hostname":case"check_fetch_failed":return r.createElement("p",null,!t&&Object(_.__)("Looks like this may be a staging environment. If so, you’ll need to install a helper plugin and verify your production site in Search Console.","google-site-kit"),t&&Object(_.__)("Looks like this may be a staging environment and you already have the helper plugin. Before you can use Site Kit, please make sure you’ve provided the necessary credentials in the Authentication section and verified your production site in Search Console.","google-site-kit")," ",r.createElement(C.a,{href:i,dangerouslySetInnerHTML:{__html:a},external:o,inherit:!0}));case"setup_token_mismatch":return r.createElement("p",null,Object(_.__)("Looks like you may be using a caching plugin which could interfere with setup. Please deactivate any caching plugins before setting up Site Kit. You may reactivate them once setup has been completed.","google-site-kit"));case"google_api_connection_fail":return r.createElement(b.b,null,r.createElement("p",{dangerouslySetInnerHTML:Object(x.a)(Object(_.sprintf)(
4
+ /* translators: %1$s: Support Forum URL, %2$s: Error message */
5
+ Object(_.__)('Looks like your site is having a technical issue with requesting data from Google services.<br/>To get more help, ask a question on our <a href="%1$s">support forum</a> and include the text of the original error message:<br/>%2$s',"google-site-kit"),"https://wordpress.org/support/plugin/google-site-kit/",e),{ALLOWED_TAGS:["a","br"],ALLOWED_ATTR:["href"]})}));case"amp_cdn_restricted":return r.createElement(b.b,null,r.createElement("p",{dangerouslySetInnerHTML:Object(x.a)(Object(_.sprintf)(
6
+ /* translators: %1$s: Support Forum URL, %2$s: Error message */
7
+ Object(_.__)('Looks like the AMP CDN is restricted in your region, which could interfere with setup on the Site Kit service.<br/>To get more help, ask a question on our <a href="%1$s">support forum</a> and include the text of the original error message:<br/>%2$s',"google-site-kit"),"https://wordpress.org/support/plugin/google-site-kit/",e),{ALLOWED_TAGS:["a","br"],ALLOWED_ATTR:["href"]})}))}}},{key:"render",value:function(){var e,t,n=this.state,a=n.complete,o=n.error,c=this.props,s=c.children,l=i()(c,["children"]);return o&&(e=r.createElement(b.b,null,r.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement(S.a,null),r.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(_.__)("Your site may not be ready for Site Kit","google-site-kit"))),this.renderError(o)))),a||(t=r.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},r.createElement("small",null,Object(_.__)("Checking Compatibility…","google-site-kit")),r.createElement(j.a,{small:!0,compress:!0}))),s({restProps:l,complete:a,error:o,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(b.a);U.propTypes={children:E.a.func.isRequired}}).call(this,n(13),n(12))},370:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return S}));var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(23),p=n.n(f),h=n(9),m=n.n(h),g=n(10),y=n.n(g),v=n(4),k=n.n(v),b=n(1),_=n(0),R=n(48),E=n(5),O=n(17),w=n(111),x=n(28),L=n(116);function C(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return y()(this,n)}}var S=function(t){m()(ResetButton,t);var n,a=C(ResetButton);function ResetButton(t){var n;l()(this,ResetButton),n=a.call(this,t);var r=e._googlesitekitBaseData.splashURL;return n.state={dialogActive:!1,postResetURL:Object(R.a)(r,{notification:"reset_success"})},n.handleDialog=n.handleDialog.bind(p()(n)),n.handleUnlinkConfirm=n.handleUnlinkConfirm.bind(p()(n)),n.handleCloseModal=n.handleCloseModal.bind(p()(n)),n}return d()(ResetButton,[{key:"componentDidMount",value:function(){e.addEventListener("keyup",this.handleCloseModal,!1)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("keyup",this.handleCloseModal)}},{key:"handleUnlinkConfirm",value:(n=c()(i.a.mark((function e(){return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,O.c.set(O.a,"site","reset");case 2:Object(E.d)(),this.handleDialog(),document.location=this.state.postResetURL;case 5:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"handleCloseModal",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1})}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive}}))}},{key:"render",value:function(){var e=this,t=this.props.children,n=this.state.dialogActive;return r.createElement(b.b,null,r.createElement(x.a,{className:"googlesitekit-reset-button",onClick:function(){return e.setState({dialogActive:!0})},inherit:!0},t||Object(_.__)("Reset Site Kit","google-site-kit")),r.createElement(L.a,null,r.createElement(w.a,{dialogActive:n,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(_.__)("Reset Site Kit","google-site-kit"),subtitle:Object(_.__)("Resetting this site will remove access to all services. After disconnecting, you will need to re-authorize your access to restore service.","google-site-kit"),confirmButton:Object(_.__)("Reset","google-site-kit"),provides:[],danger:!0})))}}]),ResetButton}(b.a)}).call(this,n(13),n(12))},645:function(e,t,n){"use strict";n.r(t),function(e,r){var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(6),l=n.n(s),u=n(7),d=n.n(u),f=n(9),p=n.n(f),h=n(10),m=n.n(h),g=n(4),y=n.n(g),v=n(1),k=n(476),b=n.n(k),_=n(15),R=n(0),E=n(290),O=n(8),w=n.n(O),x=n(5),L=n(92),C=n(47),S=n(370),j=n(27),D=n(38),A=n(270),N=n(369),M=n(34);function U(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=y()(e);if(t){var a=y()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return m()(this,n)}}var P=w.a.withSelect,T=function(t){p()(SetupUsingProxy,t);var n=U(SetupUsingProxy);function SetupUsingProxy(t){var r;l()(this,SetupUsingProxy),r=n.call(this,t);var a=e._googlesitekitLegacyData.setup.errorMessage,i=e._googlesitekitLegacyData.permissions.canSetup;return r.state={canSetup:i,errorMessage:a,completeSetup:!1,resetSuccess:"reset_success"===Object(E.a)(location.href,"notification"),context:Object(E.a)(location.href,"googlesitekit_context")},r}return d()(SetupUsingProxy,[{key:"isSetupFinished",value:function(){var e=this.state.completeSetup;return this.props.isConnected&&e}},{key:"render",value:function(){if(this.isSetupFinished()){var t=Object(x.m)("googlesitekit-dashboard",{notification:"authentication_success"});Object(_.delay)((function(){e.location.replace(t)}),500,"later")}var n,a,o,s=this.state,l=s.context,u=s.errorMessage,d=s.resetSuccess,f=this.props,p=f.proxySetupURL,h=f.isResettable,m=f.hasConnectedAdmins,g=f.siteURL,y=m;"revoked"===l?(n=Object(R.sprintf)(
8
+ /* translators: %s is the site's hostname. (e.g. example.com) */
9
+ Object(R.__)("You revoked access to Site Kit for %s","google-site-kit"),b.a.toUnicode(new URL(g).hostname)),a=Object(R.__)('Site Kit will no longer have access to your account. If you’d like to reconnect Site Kit, click "Start Setup" below to generate new credentials.',"google-site-kit"),o=Object(R.__)("Sign in with Google","google-site-kit")):y?(n=Object(R.__)("Connect your Google account to Site Kit","google-site-kit"),a=Object(R.__)("Site Kit has already been configured by another admin of this site. To use Site Kit as well, sign in with your Google account which has access to Google services for this site (e.g. Google Analytics). Once you complete the 3 setup steps, you’ll see stats from all activated Google products.","google-site-kit"),o=Object(R.__)("Sign in with Google","google-site-kit")):(n=Object(R.__)("Sign in with Google to set up Site Kit","google-site-kit"),a=Object(R.__)("The Site Kit service will guide you through 3 simple setup steps.","google-site-kit"),o=Object(R.__)("Start setup","google-site-kit"));var k=function(){var t=c()(i.a.mark((function t(n){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return n.preventDefault(),t.next=3,Object(x.w)("plugin_setup","proxy_start_setup_landing_page");case 3:e.location.assign(p);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}();return r.createElement(v.b,null,r.createElement(L.a,null),u&&r.createElement(D.a,{id:"setup_error",type:"win-error",title:Object(R.__)("Oops! There was a problem during set up. Please try again.","google-site-kit"),description:u,isDismissable:!1}),d&&r.createElement(D.a,{id:"reset_success",title:Object(R.__)("Site Kit by Google was successfully reset.","google-site-kit"),isDismissable:!1}),r.createElement("div",{className:"googlesitekit-wizard"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement(j.a,null,r.createElement("section",{className:"googlesitekit-wizard-progress"},r.createElement("div",{className:"googlesitekit-setup__footer"},r.createElement("div",{className:"mdc-layout-grid"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},r.createElement("h1",{className:"googlesitekit-setup__title"},n),r.createElement("p",{className:"googlesitekit-setup__description"},a),r.createElement(N.a,null,(function(e){var t=e.complete,n=e.inProgressFeedback,a=e.CTAFeedback;return r.createElement(v.b,null,a,r.createElement(A.a,{optinAction:"analytics_optin_setup_fallback"}),r.createElement("div",{className:"googlesitekit-start-setup-wrap"},r.createElement(C.a,{className:"googlesitekit-start-setup",href:p,onClick:k,disabled:!t},o),n,!y&&h&&r.createElement(S.a,null)))})))))))))))))}}]),SetupUsingProxy}(v.a);t.default=P((function(e){var t=e(M.c);return{hasConnectedAdmins:t.hasConnectedAdmins(),isConnected:t.isConnected(),isResettable:t.isResettable(),siteURL:t.getReferenceSiteURL(),proxySetupURL:t.getProxySetupURL()}}))(T)}.call(this,n(13),n(12))},92:function(e,t,n){"use strict";(function(e){var r=n(1),a=n(8),i=n.n(a),o=n(138),c=n(169),s=n(171),l=n(20),u=i.a.useSelect;t.a=function Header(){var t=u((function(e){return e(l.c).isAuthenticated()}));return e.createElement(r.b,null,e.createElement("header",{className:"googlesitekit-header"},e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(o.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&e.createElement(c.a,null))))),e.createElement(s.a,null))}}).call(this,n(12))}}]);
dist/assets/js/chunk-googlesitekit-setup-wrapper-6028d5eff3636859d961.js DELETED
@@ -1 +0,0 @@
1
- (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[4],{165:function(e,t,n){"use strict";(function(e,a){var i=n(4),r=n.n(i),o=n(14),c=n.n(o),l=n(6),u=n.n(l),s=n(7),d=n.n(s),m=n(22),p=n.n(m),f=n(8),g=n.n(f),h=n(9),y=n.n(h),v=n(3),_=n.n(v),k=n(1),E=n(0),b=n(5),R=n(109),D=n(47),S=n(166),M=n(114);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=_()(e);if(t){var i=_()(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return y()(this,n)}}var C=function(t){g()(UserMenu,t);var n,i=N(UserMenu);function UserMenu(e){var t;return u()(this,UserMenu),(t=i.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(p()(t)),t.handleMenuClose=t.handleMenuClose.bind(p()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(p()(t)),t.handleDialog=t.handleDialog.bind(p()(t)),t.handleDialogClose=t.handleDialogClose.bind(p()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(p()(t)),t.menuButtonRef=Object(k.h)(),t.menuRef=Object(k.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var a=e._googlesitekitLegacyData.admin.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:e.location.assign(a);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(b.d)(),document.location=Object(b.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=e._googlesitekitLegacyData.admin,n=t.userData,i=n.email,r=void 0===i?"":i,o=n.picture,c=void 0===o?"":o,l=t.proxyPermissionsURL,u=this.state,s=u.dialogActive,d=u.menuOpen;return a.createElement(k.b,null,a.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},a.createElement(D.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:c?a.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},a.createElement("img",{className:"mdc-button__icon--image",src:c,alt:Object(E.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},r),a.createElement(S.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(E.__)("Disconnect","google-site-kit")].concat(l?[Object(E.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),a.createElement(M.a,null,a.createElement(R.a,{dialogActive:s,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(E.__)("Disconnect","google-site-kit"),subtitle:Object(E.__)("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:Object(E.__)("Disconnect","google-site-kit"),provides:[],danger:!0})))}}]),UserMenu}(k.a);t.a=C}).call(this,n(15),n(12))},166:function(e,t,n){"use strict";(function(e){var a=n(6),i=n.n(a),r=n(7),o=n.n(r),c=n(8),l=n.n(c),u=n(9),s=n.n(u),d=n(3),m=n.n(d),p=n(1),f=n(2),g=n.n(f),h=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var i=m()(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return s()(this,n)}}var v=function(t){l()(Menu,t);var n=y(Menu);function Menu(e){var t;return i()(this,Menu),(t=n.call(this,e)).menuRef=Object(p.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new h.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,a=t.menuItems,i=t.onSelected,r=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:r,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},a.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:i.bind(null,n),onKeyDown:i.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(p.a);v.propTypes={menuOpen:g.a.bool.isRequired,menuItems:g.a.array.isRequired,id:g.a.string.isRequired},t.a=v}).call(this,n(12))},167:function(e,t,n){"use strict";var a=n(6),i=n.n(a),r=n(7),o=n.n(r),c=n(8),l=n.n(c),u=n(9),s=n.n(u),d=n(3),m=n.n(d),p=n(83);function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=m()(e);if(t){var i=m()(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return s()(this,n)}}var g=function(e){l()(ErrorNotification,e);var t=f(ErrorNotification);function ErrorNotification(){return i()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(p.a)("googlesitekit.ErrorNotification")(g)},293:function(e,t,n){"use strict";n.r(t),function(e,a){var i=n(6),r=n.n(i),o=n(7),c=n.n(o),l=n(8),u=n.n(l),s=n(9),d=n.n(s),m=n(3),p=n.n(m),f=n(1),g=n(13),h=n(83),y=n(0),v=n(90),_=n(28),k=n(89),E=n(5);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return d()(this,n)}}var R=function(t){u()(BaseComponent,t);var n=b(BaseComponent);function BaseComponent(){return r()(this,BaseComponent),n.apply(this,arguments)}return c()(BaseComponent,[{key:"render",value:function(){var t=this.props.children;return e.createElement(f.b,null,t)}}]),BaseComponent}(f.a),D=function(t){u()(SetupWrapper,t);var n=b(SetupWrapper);function SetupWrapper(e){var t;r()(this,SetupWrapper),t=n.call(this,e);var i=a._googlesitekitLegacyData.setup.moduleToSetup;return t.state={currentModule:i},t}return c()(SetupWrapper,[{key:"render",value:function(){var t=this.state.currentModule,n=SetupWrapper.loadSetupModule(t),a=Object(E.m)("googlesitekit-settings",{});return e.createElement(f.b,null,e.createElement(v.a,null),e.createElement("div",{className:"googlesitekit-setup"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("section",{className:"googlesitekit-setup__wrapper"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("p",{className:" googlesitekit-setup__intro-title googlesitekit-overline "},Object(y.__)("Connect Service","google-site-kit")),n))),e.createElement("div",{className:"googlesitekit-setup__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(_.a,{id:"setup-".concat(t,"-cancel"),href:a},Object(y.__)("Cancel","google-site-kit"))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--align-right "},e.createElement(k.a,null)))))))))))}}],[{key:"loadSetupModule",value:function(t){var n=Object(h.a)("googlesitekit.ModuleSetup-".concat(t))(R);return e.createElement(n,{finishSetup:SetupWrapper.finishSetup,onSettingsPage:!1,isEditing:!0})}},{key:"finishSetup",value:function(){var e={notification:"authentication_success"};a._googlesitekitLegacyData.setup&&a._googlesitekitLegacyData.setup.moduleToSetup&&(e.slug=a._googlesitekitLegacyData.setup.moduleToSetup);var t=Object(E.m)("googlesitekit-dashboard",e);Object(g.delay)((function(){a.location.replace(t)}),500,"later")}}]),SetupWrapper}(f.a);t.default=D}.call(this,n(12),n(15))},89:function(e,t,n){"use strict";(function(e){n(1);var a=n(0),i=n(28);t.a=function HelpLink(){var t=Object(a.__)("Need help?","google-site-kit");return e.createElement(i.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},90:function(e,t,n){"use strict";(function(e,a){var i=n(6),r=n.n(i),o=n(7),c=n.n(o),l=n(8),u=n.n(l),s=n(9),d=n.n(s),m=n(3),p=n.n(m),f=n(1),g=n(135),h=n(165),y=n(167);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,a=p()(e);if(t){var i=p()(this).constructor;n=Reflect.construct(a,arguments,i)}else n=a.apply(this,arguments);return d()(this,n)}}var _=function(t){u()(Header,t);var n=v(Header);function Header(){return r()(this,Header),n.apply(this,arguments)}return c()(Header,[{key:"render",value:function(){var t=e._googlesitekitLegacyData.setup.isAuthenticated;return a.createElement(f.b,null,a.createElement("header",{className:"googlesitekit-header"},a.createElement("section",{className:"mdc-layout-grid"},a.createElement("div",{className:"mdc-layout-grid__inner"},a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},a.createElement(g.a,null)),a.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&a.createElement(h.a,null))))),a.createElement(y.a,null))}}]),Header}(f.a);t.a=_}).call(this,n(15),n(12))}}]);
 
dist/assets/js/chunk-googlesitekit-setup-wrapper-e19cadd3c7b2f1498278.js ADDED
@@ -0,0 +1 @@
 
1
+ (window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[]).push([[4],{169:function(e,t,n){"use strict";(function(e,i){var a=n(3),r=n.n(a),o=n(14),c=n.n(o),l=n(6),u=n.n(l),s=n(7),d=n.n(s),m=n(23),p=n.n(m),f=n(9),g=n.n(f),h=n(10),y=n.n(h),v=n(4),_=n.n(v),k=n(1),E=n(0),b=n(8),R=n.n(b),S=n(5),M=n(111),N=n(47),C=n(170),D=n(116),O=n(34),w=n(20);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=_()(e);if(t){var a=_()(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return y()(this,n)}}var U=R.a.withSelect,x=function(t){g()(UserMenu,t);var n,a=j(UserMenu);function UserMenu(e){var t;return u()(this,UserMenu),(t=a.call(this,e)).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(p()(t)),t.handleMenuClose=t.handleMenuClose.bind(p()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(p()(t)),t.handleDialog=t.handleDialog.bind(p()(t)),t.handleDialogClose=t.handleDialogClose.bind(p()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(p()(t)),t.menuButtonRef=Object(k.h)(),t.menuRef=Object(k.h)(),t}return d()(UserMenu,[{key:"componentDidMount",value:function(){e.addEventListener("mouseup",this.handleMenuClose),e.addEventListener("keyup",this.handleMenuClose),e.addEventListener("keyup",this.handleDialogClose)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("mouseup",this.handleMenuClose),e.removeEventListener("keyup",this.handleMenuClose),e.removeEventListener("keyup",this.handleDialogClose)}},{key:"handleMenu",value:function(){var e=this.state.menuOpen;this.setState({menuOpen:!e})}},{key:"handleMenuClose",value:function(e){("keyup"!==e.type||27!==e.keyCode)&&"mouseup"!==e.type||this.menuButtonRef.current.buttonRef.current.contains(e.target)||this.menuRef.current.menuRef.current.contains(e.target)||this.setState({menuOpen:!1})}},{key:"handleMenuItemSelect",value:function(t,n){var i=this.props.proxyPermissionsURL;if("keydown"===n.type&&(13===n.keyCode||32===n.keyCode)||"click"===n.type)switch(t){case 0:this.handleDialog();break;case 1:if(!i)return;e.location.assign(i);break;default:this.handleMenu()}}},{key:"handleDialog",value:function(){this.setState((function(e){return{dialogActive:!e.dialogActive,menuOpen:!1}}))}},{key:"handleDialogClose",value:function(e){27===e.keyCode&&this.setState({dialogActive:!1,menuOpen:!1})}},{key:"handleUnlinkConfirm",value:(n=c()(r.a.mark((function e(){return r.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(S.d)(),document.location=Object(S.m)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),e,this)}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this.props,t=e.proxyPermissionsURL,n=e.userEmail,a=e.userPicture,r=this.state,o=r.dialogActive,c=r.menuOpen;return n?i.createElement(k.b,null,i.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},i.createElement(N.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:a?i.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},i.createElement("img",{className:"mdc-button__icon--image",src:a,alt:Object(E.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:c,ariaControls:"user-menu"},n),i.createElement(C.a,{ref:this.menuRef,menuOpen:c,menuItems:[Object(E.__)("Disconnect","google-site-kit")].concat(t?[Object(E.__)("Manage sites…","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),i.createElement(D.a,null,i.createElement(M.a,{dialogActive:o,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(E.__)("Disconnect","google-site-kit"),subtitle:Object(E.__)("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:Object(E.__)("Disconnect","google-site-kit"),provides:[],danger:!0}))):null}}]),UserMenu}(k.a);t.a=U((function(e){return{proxyPermissionsURL:e(O.c).getProxyPermissionsURL(),userEmail:e(w.c).getEmail(),userPicture:e(w.c).getPicture()}}))(x)}).call(this,n(13),n(12))},170:function(e,t,n){"use strict";(function(e){var i=n(6),a=n.n(i),r=n(7),o=n.n(r),c=n(9),l=n.n(c),u=n(10),s=n.n(u),d=n(4),m=n.n(d),p=n(1),f=n(2),g=n.n(f),h=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return s()(this,n)}}var v=function(t){l()(Menu,t);var n=y(Menu);function Menu(e){var t;return a()(this,Menu),(t=n.call(this,e)).menuRef=Object(p.h)(),t}return o()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new h.f(this.menuRef.current),this.menu.open=e,this.menu.setDefaultFocusState(1)}},{key:"componentDidUpdate",value:function(e){var t=this.props.menuOpen;t!==e.menuOpen&&(this.menu.open=t)}},{key:"render",value:function(){var t=this.props,n=t.menuOpen,i=t.menuItems,a=t.onSelected,r=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:r,className:"mdc-list",role:"menu","aria-hidden":!n,"aria-orientation":"vertical",tabIndex:"-1"},i.map((function(t,n){return e.createElement("li",{key:n,className:"mdc-list-item",role:"menuitem",onClick:a.bind(null,n),onKeyDown:a.bind(null,n)},e.createElement("span",{className:"mdc-list-item__text"},t))}))))}}]),Menu}(p.a);v.propTypes={menuOpen:g.a.bool.isRequired,menuItems:g.a.array.isRequired,id:g.a.string.isRequired},t.a=v}).call(this,n(12))},171:function(e,t,n){"use strict";var i=n(6),a=n.n(i),r=n(7),o=n.n(r),c=n(9),l=n.n(c),u=n(10),s=n.n(u),d=n(4),m=n.n(d),p=n(85);function f(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return s()(this,n)}}var g=function(e){l()(ErrorNotification,e);var t=f(ErrorNotification);function ErrorNotification(){return a()(this,ErrorNotification),t.apply(this,arguments)}return o()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(n(1).a);t.a=Object(p.a)("googlesitekit.ErrorNotification")(g)},294:function(e,t,n){"use strict";n.r(t),function(e,i){var a=n(6),r=n.n(a),o=n(7),c=n.n(o),l=n(9),u=n.n(l),s=n(10),d=n.n(s),m=n(4),p=n.n(m),f=n(1),g=n(15),h=n(85),y=n(0),v=n(92),_=n(28),k=n(91),E=n(5);function b(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,i=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(i,arguments,a)}else n=i.apply(this,arguments);return d()(this,n)}}var R=function(t){u()(BaseComponent,t);var n=b(BaseComponent);function BaseComponent(){return r()(this,BaseComponent),n.apply(this,arguments)}return c()(BaseComponent,[{key:"render",value:function(){var t=this.props.children;return e.createElement(f.b,null,t)}}]),BaseComponent}(f.a),S=function(t){u()(SetupWrapper,t);var n=b(SetupWrapper);function SetupWrapper(e){var t;r()(this,SetupWrapper),t=n.call(this,e);var a=i._googlesitekitLegacyData.setup.moduleToSetup;return t.state={currentModule:a},t}return c()(SetupWrapper,[{key:"render",value:function(){var t=this.state.currentModule,n=SetupWrapper.loadSetupModule(t),i=Object(E.m)("googlesitekit-settings",{});return e.createElement(f.b,null,e.createElement(v.a,null),e.createElement("div",{className:"googlesitekit-setup"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("section",{className:"googlesitekit-setup__wrapper"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement("p",{className:" googlesitekit-setup__intro-title googlesitekit-overline "},Object(y.__)("Connect Service","google-site-kit")),n))),e.createElement("div",{className:"googlesitekit-setup__footer"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(_.a,{id:"setup-".concat(t,"-cancel"),href:i},Object(y.__)("Cancel","google-site-kit"))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--align-right "},e.createElement(k.a,null)))))))))))}}],[{key:"loadSetupModule",value:function(t){var n=Object(h.a)("googlesitekit.ModuleSetup-".concat(t))(R);return e.createElement(n,{finishSetup:SetupWrapper.finishSetup,onSettingsPage:!1,isEditing:!0})}},{key:"finishSetup",value:function(){var e={notification:"authentication_success"};i._googlesitekitLegacyData.setup&&i._googlesitekitLegacyData.setup.moduleToSetup&&(e.slug=i._googlesitekitLegacyData.setup.moduleToSetup);var t=Object(E.m)("googlesitekit-dashboard",e);Object(g.delay)((function(){i.location.replace(t)}),500,"later")}}]),SetupWrapper}(f.a);t.default=S}.call(this,n(12),n(13))},34:function(e,t,n){"use strict";n.d(t,"c",(function(){return i})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return r}));var i="core/site",a="primary",r="secondary"},91:function(e,t,n){"use strict";(function(e){n(1);var i=n(0),a=n(28);t.a=function HelpLink(){var t=Object(i.__)("Need help?","google-site-kit");return e.createElement(a.a,{className:"googlesitekit-help-link",href:"https://sitekit.withgoogle.com/documentation/",external:!0},t)}}).call(this,n(12))},92:function(e,t,n){"use strict";(function(e){var i=n(1),a=n(8),r=n.n(a),o=n(138),c=n(169),l=n(171),u=n(20),s=r.a.useSelect;t.a=function Header(){var t=s((function(e){return e(u.c).isAuthenticated()}));return e.createElement(i.b,null,e.createElement("header",{className:"googlesitekit-header"},e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--span-3-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},e.createElement(o.a,null)),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--align-middle mdc-layout-grid__cell--align-right-phone mdc-layout-grid__cell--span-1-phone mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},t&&e.createElement(c.a,null))))),e.createElement(l.a,null))}}).call(this,n(12))}}]);
dist/assets/js/googlesitekit-activation.js CHANGED
@@ -1,23 +1,27 @@
1
- !function(e){function t(t){for(var r,o,c=t[0],s=t[1],l=t[2],f=0,d=[];f<c.length;f++)o=c[f],Object.prototype.hasOwnProperty.call(a,o)&&a[o]&&d.push(a[o][0]),a[o]=0;for(r in s)Object.prototype.hasOwnProperty.call(s,r)&&(e[r]=s[r]);for(u&&u(t);d.length;)d.shift()();return i.push.apply(i,l||[]),n()}function n(){for(var e,t=0;t<i.length;t++){for(var n=i[t],r=!0,o=1;o<n.length;o++){var c=n[o];0!==a[c]&&(r=!1)}r&&(i.splice(t--,1),e=__webpack_require__(__webpack_require__.s=n[0]))}return e}var r={},a={5:0},i=[];function __webpack_require__(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,__webpack_require__),n.l=!0,n.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)__webpack_require__.d(n,r,function(t){return e[t]}.bind(null,r));return n},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var o=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],c=o.push.bind(o);o.push=t,o=o.slice();for(var s=0;s<o.length;s++)t(o[s]);var u=c;i.push([633,0]),n()}({1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return o})),n.d(t,"a",(function(){return c})),n.d(t,"e",(function(){return u})),n.d(t,"f",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"h",(function(){return p})),n.d(t,"b",(function(){return m})),n.d(t,"i",(function(){return v})),n.d(t,"j",(function(){return y})),n.d(t,"k",(function(){return j})),n.d(t,"c",(function(){return D})),n.d(t,"l",(function(){return R})),n.d(t,"m",(function(){return N})),n.d(t,"n",(function(){return C})),n.d(t,"o",(function(){return L})),n.d(t,"p",(function(){return I})),n.d(t,"q",(function(){return T})),n.d(t,"r",(function(){return M})),n.d(t,"s",(function(){return U}));var r=n(96);void 0===e.googlesitekit&&(e.googlesitekit={});var a=e.googlesitekit._element||r,i=a.Children,o=a.cloneElement,c=a.Component,s=a.concatChildren,u=a.createContext,l=a.createElement,f=a.createInterpolateElement,d=a.createPortal,p=a.createRef,g=a.findDOMNode,h=a.forwardRef,m=a.Fragment,b=a.isEmptyElement,v=a.isValidElement,y=a.lazy,k=a.memo,O=a.Platform,_=a.RawHTML,j=a.render,w=a.renderToString,E=a.StrictMode,D=a.Suspense,S=a.switchChildrenNodeName,x=a.unmountComponentAtNode,R=a.useCallback,N=a.useContext,P=a.useDebugValue,C=a.useEffect,A=a.useImperativeHandle,L=a.useLayoutEffect,I=a.useMemo,T=a.useReducer,M=a.useRef,U=a.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:i,cloneElement:o,Component:c,concatChildren:s,createContext:u,createElement:l,createInterpolateElement:f,createPortal:d,createRef:p,findDOMNode:g,forwardRef:h,Fragment:m,isEmptyElement:b,isValidElement:v,lazy:y,memo:k,Platform:O,RawHTML:_,render:j,renderToString:w,StrictMode:E,Suspense:D,switchChildrenNodeName:S,unmountComponentAtNode:x,useCallback:R,useContext:N,useDebugValue:P,useEffect:C,useImperativeHandle:A,useLayoutEffect:L,useMemo:I,useReducer:T,useRef:M,useState:U})}).call(this,n(15))},106:function(e,t,n){"use strict";var r=n(98);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(r.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,a){if(n)return a(e);setTimeout((function(){n=!0}),1e3);var i=e.parse,o=void 0===i||i,c=e.path;if("string"==typeof e.path){var s,u=(null===(s=e.method)||void 0===s?void 0:s.toUpperCase())||"GET",l=Object(r.getStablePath)(c);if(o&&"GET"===u&&t[l]){var f=Promise.resolve(t[l].body);return delete t[l],f}if("OPTIONS"===u&&t[u]&&t[u][l]){var d=Promise.resolve(t[u][l]);return delete t[u][l],d}}return a(e)}}},107:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(37);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var m=function(t){s()(GenericError,t);var n=h(GenericError);function GenericError(){return a()(this,GenericError),n.apply(this,arguments)}return o()(GenericError,[{key:"render",value:function(){return e.createElement(g.a,this.props)}}]),GenericError}(p.a);t.a=m}).call(this,n(12))},109:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(209),b=n.n(m),v=n(18),y=n.n(v),k=n(164),O=n(0),_=n(47),j=n(28),w=n(43);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var D=function(t){s()(Dialog,t);var n=E(Dialog);function Dialog(){var e;return a()(this,Dialog),(e=n.call(this)).state={attributes:[Object(O.__)("Audience overview","google-site-kit"),Object(O.__)("Top pages","google-site-kit"),Object(O.__)("Top acquisition channels","google-site-kit"),Object(O.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(p.h)(),e}return o()(Dialog,[{key:"componentDidMount",value:function(){new w.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,r=t.handleDialog,a=t.title,i=t.provides,o=t.handleConfirm,c=t.subtitle,s=t.confirmButton,u=t.dependentModules,l=t.instanceId,f=t.danger,d="googlesitekit-dialog-label-".concat(l),p="googlesitekit-dialog-description-".concat(l),g=!(!i||!i.length);return e.createElement("div",{ref:this.dialogRef,className:y()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":a?d:void 0,"aria-describedby":g?p:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(b.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},a&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},a),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),g&&e.createElement("section",{id:p,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},i.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),u&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(O.__)("Note: ","google-site-kit")),u),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(_.a,{onClick:o,danger:f},s||Object(O.__)("Disconnect","google-site-kit")),e.createElement(j.a,{className:"mdc-dialog__cancel-button",onClick:function(){return r()},inherit:!0},Object(O.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(p.a);D.propTypes={dialogActive:h.a.bool,handleDialog:h.a.func,handleConfirm:h.a.func.isRequired,title:h.a.string,description:h.a.string,confirmButton:h.a.string,danger:h.a.bool},D.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null,danger:!1},t.a=Object(k.a)(D)}).call(this,n(12))},11:function(e,t){e.exports=googlesitekit.data},110:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return m}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(19),s=n.n(c),u=n(41),l=n.n(u),f=n(11),d=n.n(f),p=n(42);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=function(t,n,r){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},c=i.client,u=void 0===c||c,f=i.server,g=void 0===f||f,m=i.storeName,b=void 0===m?void 0:m;s()(t,"type is required."),s()(n,"identifier is required."),s()(r,"datapoint is required.");var v=b||"".concat(t,"/").concat(n),y={serverNotifications:g?void 0:{},clientNotifications:u?void 0:{}},k=Object(p.a)({baseName:"getNotifications",controlCallback:function(){return l.a.get(t,n,r)},reducerCallback:function(e,t){return h(h({},e),{},{serverNotifications:t.reduce((function(e,t){return h(h({},e),{},o()({},t.id,t))}),{})})}}),O={addNotification:function(e){return s()(e,"notification is required."),{payload:{notification:e},type:"ADD_NOTIFICATION"}},removeNotification:function(e){return s()(e,"id is required."),{payload:{id:e},type:"REMOVE_NOTIFICATION"}}},_={},j=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y,n=arguments.length>1?arguments[1]:void 0,r=n.type,a=n.payload;switch(r){case"ADD_NOTIFICATION":var i=a.notification;return h(h({},t),{},{clientNotifications:h(h({},t.clientNotifications||{}),{},o()({},i.id,i))});case"REMOVE_NOTIFICATION":var c=a.id;if(void 0===t.clientNotifications||void 0===t.clientNotifications[c])return void 0!==t.serverNotifications&&void 0!==t.serverNotifications[c]&&e.console.warn('Cannot remove server-side notification with ID "'.concat(c,'"; this may be changed in a future release.')),h({},t);var s=h({},t.clientNotifications);return delete s[c],h(h({},t),{},{clientNotifications:s});default:return h({},t)}},w={getNotifications:a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,k.actions.fetchGetNotifications();case 2:case"end":return e.stop()}}),e)}))};g||delete w.getNotifications;var E={getNotifications:function(e){var t=e.serverNotifications,n=e.clientNotifications;return void 0===t&&void 0===n?t:Object.values(h(h({},t||{}),n||{}))}},D=d.a.combineStores(k,{INITIAL_STATE:y,actions:O,controls:_,reducer:j,resolvers:w,selectors:E});return h(h({},D),{},{STORE_NAME:v})}}).call(this,n(15))},114:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var h=function(e){s()(Modal,e);var t=g(Modal);function Modal(e){var n;return a()(this,Modal),(n=t.call(this,e)).el=document.createElement("div"),n.root=document.querySelector(".googlesitekit-plugin")||document.body,n}return o()(Modal,[{key:"componentDidMount",value:function(){this.root.appendChild(this.el)}},{key:"componentWillUnmount",value:function(){this.root.removeChild(this.el)}},{key:"render",value:function(){return Object(p.g)(this.props.children,this.el)}}]),Modal}(p.a)},115:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),u=n(17);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var d=function(){var t=s()(a.a.mark((function t(){var n,r,i,o,c,s;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,u.c.get(u.a,"user","authentication",{timestamp:Date.now()});case 3:n=t.sent,r=n.authenticated,i=n.requiredScopes,o=n.grantedScopes,c=n.unsatisfiedScopes,s=void 0===c?[]:c,e._googlesitekitLegacyData.setup=f(f({},e._googlesitekitLegacyData.setup||{}),{},{isAuthenticated:r,requiredScopes:i,grantedScopes:o,unsatisfiedScopes:s,needReauthenticate:0<s.length}),t.next=14;break;case 12:t.prev=12,t.t0=t.catch(0);case 14:case"end":return t.stop()}}),t,null,[[0,12]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(15))},117:function(e,t,n){"use strict";n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return p})),n.d(t,"b",(function(){return h}));var r=n(4),a=n.n(r),i=n(14),o=n.n(i),c=n(17);function s(){return u.apply(this,arguments)}function u(){return(u=o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,c.c.get(c.a,"site","notifications",{},!1);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var l=n(50);function f(e,t){return d.apply(this,arguments)}function d(){return(d=o()(a.a.mark((function e(t,n){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return c.c.invalidateCacheGroup(c.a,"site","notifications"),e.next=3,Object(l.c)("site_notifications",n,t);case 3:return e.next=5,c.c.set(c.a,"site","mark-notification",{notificationID:t,notificationState:n});case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function p(e){return g.apply(this,arguments)}function g(){return(g=o()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,f(t,"accepted");case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function h(e){return m.apply(this,arguments)}function m(){return(m=o()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,f(t,"dismissed");case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}},119:function(e,t,n){"use strict";(function(e){n(1);t.a=function Warning(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#F9BB2D",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"warning-title warning-desc"},e.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),e.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"}))}}).call(this,n(12))},121:function(e,t,n){"use strict";(function(e){var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(19),s=n.n(c),u=n(11),l=n.n(u),f=n(20);function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var g=l.a.createRegistrySelector,h={permissionError:null,capabilities:void 0},m={clearPermissionScopeError:function(){return{payload:{},type:"CLEAR_PERMISSION_SCOPE_ERROR"}},setPermissionScopeError:function(e){return s()(e,"permissionError is required."),{payload:{permissionError:e},type:"SET_PERMISSION_SCOPE_ERROR"}},receiveCapabilities:function(e){return{type:"RECEIVE_CAPABILITIES",payload:{capabilities:e}}}},b={getCapabilities:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.a.commonActions.getRegistry();case 2:if(!t.sent.select(f.c).getCapabilities()){t.next=5;break}return t.abrupt("return");case 5:return(null===(n=e._googlesitekitUserData)||void 0===n?void 0:n.permissions)||e.console.error("Could not load core/user permissions."),t.next=8,m.receiveCapabilities(null===(r=e._googlesitekitUserData)||void 0===r?void 0:r.permissions);case 8:case"end":return t.stop()}}),t)}))},v={getPermissionScopeError:function(e){return e.permissionError},getCapabilities:function(e){return e.capabilities},hasCapability:g((function(e){return function(t,n){var r=e(f.c).getCapabilities();if(r)return!!r[n]}}))};t.a={INITIAL_STATE:h,actions:m,controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"CLEAR_PERMISSION_SCOPE_ERROR":return p(p({},e),{},{permissionError:null});case"SET_PERMISSION_SCOPE_ERROR":var a=r.permissionError;return p(p({},e),{},{permissionError:a});case"RECEIVE_CAPABILITIES":var i=r.capabilities;return p(p({},e),{},{capabilities:i});default:return p({},e)}},resolvers:b,selectors:v}}).call(this,n(15))},122:function(e,t,n){"use strict";(function(e){var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(19),s=n.n(c),u=n(45),l=n(11),f=n.n(l),d=n(20);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=f.a.createRegistrySelector,m={connectURL:void 0,user:void 0,verified:void 0},b={receiveConnectURL:function(e){return s()(e,"connectURL is required."),{payload:{connectURL:e},type:"RECEIVE_CONNECT_URL"}},receiveUserInfo:function(e){return s()(e,"userInfo is required."),{payload:{user:e},type:"RECEIVE_USER_INFO"}},receiveUserIsVerified:function(e){return s()(void 0!==e,"userIsVerified is required."),{payload:{verified:e},type:"RECEIVE_USER_IS_VERIFIED"}}},v={getConnectURL:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,!(0,n.select)(d.c).getConnectURL()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.connectURL,t.next=12,b.receiveConnectURL(r);case 12:case"end":return t.stop()}}),t)})),getUser:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(d.c).getUser()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.user,t.next=12,b.receiveUserInfo(r);case 12:case"end":return t.stop()}}),t)})),isVerified:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(d.c).isVerified()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.verified,t.next=12,b.receiveUserIsVerified(r);case 12:case"end":return t.stop()}}),t)}))},y={getUser:function(e){return e.user},getConnectURL:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.additionalScopes,r=void 0===n?[]:n,a=t.redirectURL,i=void 0===a?void 0:a,o=e.connectURL,c={redirect:i};if(void 0!==o)return(null==r?void 0:r.length)?Object(u.a)(o,g(g({},c),{},{additional_scopes:r})):Object(u.a)(o,c)},getID:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.id:t}})),getName:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.name:t}})),getEmail:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.email:t}})),getPicture:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.picture:t}})),isVerified:function(e){return e.verified}};t.a={INITIAL_STATE:m,actions:b,controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"RECEIVE_CONNECT_URL":var a=r.connectURL;return g(g({},e),{},{connectURL:a});case"RECEIVE_USER_INFO":var i=r.user;return g(g({},e),{},{user:i});case"RECEIVE_USER_IS_VERIFIED":var o=r.verified;return g(g({},e),{},{verified:o});default:return g({},e)}},resolvers:v,selectors:y}}).call(this,n(15))},123:function(e,t,n){"use strict";(function(e){n(1);var r=n(2),a=n.n(r),i=n(18),o=n.n(i);function ChangeArrow(t){var n=t.direction,r=t.invertColor;return e.createElement("svg",{className:o()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(n),{"googlesitekit-change-arrow--inverted-color":r}),width:"9",height:"9",viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("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:a.a.string,invertColor:a.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,n(12))},124:function(e,t,n){"use strict";(function(e){n(1);t.a=function Error(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#EA4336",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"error-title error-desc"},e.createElement("path",{d:"M4.47 21h15.06c1.54 0 2.5-1.67 1.73-3L13.73 4.99c-.77-1.33-2.69-1.33-3.46 0L2.74 18c-.77 1.33.19 3 1.73 3zM12 14c-.55 0-1-.45-1-1v-2c0-.55.45-1 1-1s1 .45 1 1v2c0 .55-.45 1-1 1zm1 4h-2v-2h2v2z"}))}}).call(this,n(12))},125:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),a=n(37);t.a=function DashboardPermissionAlert(){return e.createElement(a.a,{id:"permission error",title:Object(r.__)("Permissions issue accessing data","google-site-kit"),description:Object(r.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,n(12))},135:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),a=n(34);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(a.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(a.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(r.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,n(12))},136:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return Root}));n(1);var r=n(2),a=n.n(r),i=n(11),o=n.n(i),c=n(137),s=n(138),u=n(139),l=n(140);function Root(t){var n=t.children,r=t.registry,a=t.dataAPIContext,i=t.dataAPIModuleArgs;return e.createElement(o.a.RegistryProvider,{value:r},e.createElement(c.a,null,e.createElement(u.a,null,n,a&&e.createElement(l.a,{context:a,args:i})),e.createElement(s.a,null)))}Root.propTypes={children:a.a.node.isRequired,registry:a.a.object,dataAPIContext:a.a.string,dataAPIModuleArgs:a.a.object},Root.defaultProps={registry:o.a}}).call(this,n(12))},137:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(8),u=n.n(s),l=n(9),f=n.n(l),d=n(3),p=n.n(d),g=n(1),h=n(2),m=n.n(h),b=n(0),v=n(37);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var k=function(t){u()(ErrorHandler,t);var n=y(ErrorHandler);function ErrorHandler(e){var t;return i()(this,ErrorHandler),(t=n.call(this,e)).state={error:null,info:null},t}return c()(ErrorHandler,[{key:"componentDidCatch",value:function(t,n){e.console.error("Caught an error:",t,n),this.setState({error:t,info:n})}},{key:"render",value:function(){var e=this.props.children,t=this.state,n=t.error,a=t.info;return n?r.createElement(v.a,{id:"googlesitekit-error",title:Object(b.__)("Site Kit encountered an error","google-site-kit"),description:r.createElement("code",null,n.message),isDismissable:!1,format:"small",type:"win-error"},r.createElement("pre",null,a.componentStack)):e}}]),ErrorHandler}(g.a);k.defaultProps={},k.propTypes={children:m.a.node.isRequired},t.a=k}).call(this,n(15),n(12))},138:function(e,t,n){"use strict";(function(e,r){var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(1),u=n(0),l=n(11),f=n.n(l),d=n(94),p=n(109),g=n(114),h=n(85),m=f.a.useSelect,b=f.a.useDispatch,v=f.a.useRegistry;t.a=function PermissionsModal(){var t,n,a,o=v(),l=m((function(e){return e(d.a).getPermissionScopeError()})),f=m((function(t){var n;return t(d.a).getConnectURL({additionalScopes:null==l||null===(n=l.data)||void 0===n?void 0:n.scopes,redirectURL:e.location.href})})),y=b(d.a).clearPermissionScopeError,k=Object(s.l)((function(){y()}),[y]),O=Object(s.l)(c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(h.c)(o);case 2:e.location.assign(f);case 3:case"end":return t.stop()}}),t)}))),[o,f]);return Object(s.n)((function(){(function(){var e=c()(i.a.mark((function e(){var t,n,r;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(null==l||null===(t=l.data)||void 0===t?void 0:t.skipModal)||!(null==l||null===(n=l.data)||void 0===n||null===(r=n.scopes)||void 0===r?void 0:r.length)){e.next=3;break}return e.next=3,O();case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[O,l]),l?(null==l||null===(t=l.data)||void 0===t||null===(n=t.scopes)||void 0===n?void 0:n.length)?(null==l||null===(a=l.data)||void 0===a?void 0:a.skipModal)?null:r.createElement(g.a,null,r.createElement(p.a,{title:Object(u.__)("Additional Permissions Required","google-site-kit"),subtitle:l.message,confirmButton:Object(u.__)("Proceed","google-site-kit"),dialogActive:!0,handleConfirm:O,handleDialog:k})):(e.console.warn("permissionsError lacks scopes array to use for redirect, so not showing the PermissionsModal. permissionsError was:",l),null):null}}).call(this,n(15),n(12))},139:function(e,t,n){"use strict";var r=n(4),a=n.n(r),i=n(14),o=n.n(i),c=n(38),s=n.n(c),u=n(1),l=n(11),f=n.n(l),d=n(85),p=f.a.useRegistry;t.a=function RestoreSnapshots(e){var t=e.children,n=p(),r=Object(u.s)(!1),i=s()(r,2),c=i[0],l=i[1];return Object(u.n)((function(){c||o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(d.b)(n);case 2:l(!0);case 3:case"end":return e.stop()}}),e)})))()}),[n,c]),c?t:null}},140:function(e,t,n){"use strict";n.d(t,"a",(function(){return CollectModuleData}));var r=n(1),a=n(16),i=(n(17),n(11)),o=n.n(i),c=n(20),s=o.a.useSelect;function CollectModuleData(e){var t=e.context,n=e.args,i=s((function(e){return e(c.c).getDateRange()}));return Object(r.n)((function(){return function(){return Object(a.d)("googlesitekit.moduleDataReset")}}),[i]),Object(r.n)((function(){Object(a.d)("googlesitekit.moduleLoaded",t,n)}),[t,n,i]),null}},153:function(e,t,n){"use strict";(function(e){var r=n(4),a=n.n(r),i=n(14),o=n.n(i),c=n(6),s=n.n(c),u=n(7),l=n.n(u),f=n(8),d=n.n(f),p=n(9),g=n.n(p),h=n(3),m=n.n(h),b=n(1),v=n(0),y=n(117),k=n(37);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return g()(this,n)}}var _=function(t){d()(DashboardCoreSiteAlerts,t);var n,r=O(DashboardCoreSiteAlerts);function DashboardCoreSiteAlerts(e){var t;return s()(this,DashboardCoreSiteAlerts),(t=r.call(this,e)).state={notifications:!1},t}return l()(DashboardCoreSiteAlerts,[{key:"componentDidMount",value:(n=o()(a.a.mark((function e(){var t;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(y.c)();case 3:t=e.sent,this.setState({notifications:t}),e.next=10;break;case 7:e.prev=7,e.t0=e.catch(0),console.warn("Error caught while fetching notifications",e.t0);case 10:case"end":return e.stop()}}),e,this,[[0,7]])}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state.notifications;return Array.isArray(t)?t.map((function(t){return e.createElement(k.a,{key:t.id,id:t.id,title:t.title||"",description:t.content||"",learnMoreURL:t.learnMoreURL||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaURL||"",ctaLabel:t.ctaLabel||"",ctaTarget:t.ctaTarget||"",dismiss:t.dismissLabel||Object(v.__)("OK, Got it!","google-site-kit"),isDismissable:t.dismissible,onCTAClick:o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(y.a)(t.id);case 2:case"end":return e.stop()}}),e)}))),onDismiss:o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(y.b)(t.id);case 2:case"end":return e.stop()}}),e)})))})})):null}}]),DashboardCoreSiteAlerts}(b.a);t.a=_}).call(this,n(12))},154:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(8),u=n.n(s),l=n(9),f=n.n(l),d=n(3),p=n.n(d),g=n(1),h=n(0),m=n(16),b=n(5),v=n(37),y=n(155);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var O=function(t){u()(DashboardSetupAlerts,t);var n=k(DashboardSetupAlerts);function DashboardSetupAlerts(){return i()(this,DashboardSetupAlerts),n.apply(this,arguments)}return c()(DashboardSetupAlerts,[{key:"render",value:function(){var t=Object(b.k)("notification");if(!t||""===t)return null;var n={id:"connected-successfully",setupTitle:Object(h.__)("Site Kit","google-site-kit"),description:Object(h.__)("Now you’ll be able to see how your site is doing in search. To get even more detailed stats, activate more modules. Here are our recommendations for what to include in your Site Kit:","google-site-kit"),learnMore:{label:"",url:"",description:""}},a=e._googlesitekitLegacyData.permissions.canManageOptions;switch(t){case"authentication_success":if(!a)return null;var i=Object(b.j)(),o=Object(b.k)("slug");return o&&i[o]&&!i[o].active?null:(o&&i[o]&&(n.id="".concat(n.id,"-").concat(o),n.setupTitle=i[o].name,n.description=Object(h.__)("Here are some other services you can connect to see even more stats:","google-site-kit"),n=Object(m.c)("googlesitekit.SetupWinNotification-".concat(o),n)),r.createElement(g.b,null,r.createElement(v.a,{id:n.id
2
- /* translators: %s: the name of a module that setup was completed for */,title:Object(h.sprintf)(Object(h.__)("Congrats on completing the setup for %s!","google-site-kit"),n.setupTitle),description:n.description,handleDismiss:function(){},winImage:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket.png",dismiss:Object(h.__)("OK, Got it!","google-site-kit"),format:"large",type:"win-success",learnMoreLabel:n.learnMore.label,learnMoreDescription:n.learnMore.description,learnMoreURL:n.learnMore.url,anchorLink:"pagespeed-insights"===o?"#googlesitekit-pagespeed-header":"",anchorLinkLabel:"pagespeed-insights"===o?Object(h.__)("Jump to the bottom of the dashboard to see how fast your home page is.","google-site-kit"):""},r.createElement(y.a,null))));case"authentication_failure":return r.createElement(g.b,null,r.createElement(v.a,{id:"connection error",title:Object(h.__)("There was a problem connecting to Google!","google-site-kit"),description:"",handleDismiss:function(){},format:"small",type:"win-error"}))}}}]),DashboardSetupAlerts}(g.a);t.a=O}).call(this,n(15),n(12))},155:function(e,t,n){"use strict";(function(e,r){var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(6),u=n.n(s),l=n(7),f=n.n(l),d=n(22),p=n.n(d),g=n(8),h=n.n(g),m=n(9),b=n.n(m),v=n(3),y=n.n(v),k=n(1),O=n(13),_=n(18),j=n.n(_),w=n(0),E=n(5),D=n(115),S=n(28),x=n(17),R=n(107),N=n(91);function P(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=y()(e);if(t){var a=y()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return b()(this,n)}}var C=function(t){h()(ModulesList,t);var n,a=P(ModulesList);function ModulesList(e){var t;return u()(this,ModulesList),(t=a.call(this,e)).setupModuleClick=t.setupModuleClick.bind(p()(t)),t}return f()(ModulesList,[{key:"setupModuleClick",value:(n=c()(i.a.mark((function t(n){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,this.setState({isSaving:!0}),t.next=4,Object(E.b)(x.c,n,!0);case 4:return t.next=6,Object(D.a)();case 6:e.location=Object(E.l)(n,!0),t.next=13;break;case 9:t.prev=9,t.t0=t.catch(0),Object(E.u)(R.a,{id:"setup-module-error",title:Object(w.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"}),this.setState({isSaving:!1});case 13:case"end":return t.stop()}}),t,this,[[0,9]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this,t=Object(E.j)(),n=Object.values(t).filter((function(e){return!e.internal})),a=n.filter((function(e){return e.active&&e.setupComplete})).reduce((function(e,t){return e[t.slug]=t.name,e}),{}),i=n.filter((function(e){return 0===e.required.length})).sort((function(e,t){return e.sort-t.sort}));return r.createElement("div",{className:"googlesitekit-modules-list"},Object(O.map)(i,(function(t){var n=!1,i="",o=t.slug,c=t.name,s=t.setupComplete,u=t.required;return 0<u.length&&u.forEach((function(e){a[e]&&(n=!0,i=a[e])})),r.createElement("div",{key:o,className:j()("googlesitekit-modules-list__module","googlesitekit-modules-list__module--".concat(o),{"googlesitekit-modules-list__module--disabled":n})},r.createElement("div",{className:"googlesitekit-settings-connect-module__wrapper"},r.createElement("div",{className:"googlesitekit-settings-connect-module__logo"},Object(E.p)(o,n)),r.createElement("h3",{className:"googlesitekit-settings-connect-module__title"},c)),r.createElement(N.a,{slug:o,context:"modules-list"}),s&&r.createElement("span",{className:"googlesitekit-settings-module__status"},r.createElement("span",{className:"googlesitekit-settings-module__status-icon googlesitekit-settings-module__status-icon--connected"},r.createElement("span",{className:"screen-reader-text"},Object(w.__)("Connected","google-site-kit"))),Object(w.__)("Connected","google-site-kit")),!s&&!n&&r.createElement(S.a,{arrow:!0,small:!0,inherit:!0,onClick:function(){e.setupModuleClick(o)}}," ",Object(w.__)("Connect Service","google-site-kit")),!s&&n&&r.createElement(S.a,{disabled:!0,small:!0,inherit:!0},
3
  /* translators: %s: parent module name */
4
- Object(w.sprintf)(Object(w.__)("Enable %s to start setup","google-site-kit"),i)))})))}}]),ModulesList}(k.a);t.a=C}).call(this,n(15),n(12))},156:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(8),u=n.n(s),l=n(9),f=n.n(l),d=n(3),p=n.n(d),g=n(1),h=n(13),m=n(0),b=n(5),v=n(37),y=n(77);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var O=function(t){u()(DashboardModulesAlerts,t);var n=k(DashboardModulesAlerts);function DashboardModulesAlerts(e){var t;return i()(this,DashboardModulesAlerts),(t=n.call(this,e)).state={data:!1},t}return c()(DashboardModulesAlerts,[{key:"componentDidMount",value:function(){var e=this,t=Object(y.f)();t&&Object(y.b)(t).then((function(t){e.setState({data:t.results})}))}},{key:"render",value:function(){var t=this.state.data;if(0===Object.keys(t).length)return null;var n=Object(b.j)(),a=[];return Object.keys(t).forEach((function(i){Object(h.each)(t[i],(function(t){a.push(e.createElement(v.a,{key:t.id,id:t.id,title:t.title||"",description:t.description||"",blockData:t.blockData||[],winImage:t.winImage?"".concat(r._googlesitekitLegacyData.admin.assetsRoot,"images/").concat(t.winImage):"",format:t.format||"small",learnMoreURL:t.learnMoreURL||"",learnMoreDescription:t.learnMoreDescription||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaURL||"",ctaLabel:t.ctaLabel||"",ctaTarget:t.ctaTarget||"",type:t.severity||"",dismiss:t.dismiss||Object(m.__)("OK, Got it!","google-site-kit"),isDismissable:t.isDismissable||!0,logo:t.logo||!0,module:i,moduleName:n[i].name,pageIndex:t.pageIndex||"",dismissExpires:t.dismissExpires||0,showOnce:t.showOnce||!1}))}))})),e.createElement(g.b,null,a)}}]),DashboardModulesAlerts}(g.a);t.a=O}).call(this,n(12),n(15))},157:function(e,t,n){"use strict";var r=n(4),a=n.n(r),i=n(14),o=n.n(i),c=n(6),s=n.n(c),u=n(7),l=n.n(u),f=n(13),d=n(17),p=function(){function WinsWithData(e){s()(this,WinsWithData),this.wins=e,this.response=[]}var e;return l()(WinsWithData,[{key:"get",value:(e=o()(a.a.mark((function e(){var t,n=this;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=Object(f.filter)(this.wins.map((function(e){return!!e.withData&&(e.withData.callback=function(t){n.response[e.identifier]=t},e.withData)}))),e.next=3,d.c.combinedGetFromCache(t);case 3:return e.abrupt("return",this.response);case 4:case"end":return e.stop()}}),e,this)}))),function(){return e.apply(this,arguments)})}]),WinsWithData}();t.a=p},158:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(13),h=n(0),m=n(16),b=n(37),v=n(77);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(DashboardWinsAlerts,t);var n=y(DashboardWinsAlerts);function DashboardWinsAlerts(e){var t;return a()(this,DashboardWinsAlerts),(t=n.call(this,e)).state={data:!1},t}return o()(DashboardWinsAlerts,[{key:"componentDidMount",value:function(){var e=this;Object(m.a)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetWinsNotifications",(function(){Object(m.f)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetWinsNotifications");var t=Object(v.g)();t&&Object(v.d)(t).then((function(t){e.setState({data:t.results})}))}))}},{key:"render",value:function(){var t=this.state.data;if(0===Object.keys(t).length)return null;var n=[];return Object.keys(t).forEach((function(r){Object(g.each)(t[r],(function(t){n.push(e.createElement(b.a,{key:t.id,id:t.id,title:t.title||"",description:t.description||"",blockData:t.blockData||[],winImage:t.winImage||"",format:t.format||"small",learnMoreURL:t.learnMoreURL||"",learnMoreDescription:t.learnMoreDescription||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaLink||"",ctaLabel:t.ctaLabel||"",type:t.severity||"",dismiss:t.dismiss||Object(h.__)("OK, Got it!","google-site-kit"),isDismissable:t.isDismissable||!0,logo:t.logo||!1,pageIndex:t.pageIndex||"",dismissExpires:t.dismissExpires||0,showOnce:t.showOnce||!1}))}))})),e.createElement(p.b,null,n)}}]),DashboardWinsAlerts}(p.a);t.a=k}).call(this,n(12))},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return o})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"d",(function(){return p})),n.d(t,"c",(function(){return g}));var r=n(92);void 0===e.googlesitekit&&(e.googlesitekit={});var a=e.googlesitekit._hooks||r,i=a.addAction,o=a.addFilter,c=a.removeAction,s=a.removeFilter,u=a.hasAction,l=a.hasFilter,f=a.removeAllActions,d=a.removeAllFilters,p=a.doAction,g=a.applyFilters,h=a.currentAction,m=a.currentFilter,b=a.doingAction,v=a.doingFilter,y=a.didAction,k=a.didFilter,O=a.actions,_=a.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:i,addFilter:o,removeAction:c,removeFilter:s,hasAction:u,hasFilter:l,removeAllActions:f,removeAllFilters:d,doAction:p,applyFilters:g,currentAction:h,currentFilter:m,doingAction:b,doingFilter:v,didAction:y,didFilter:k,actions:O,filters:_})}).call(this,n(15))},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return v.a})),n.d(t,"b",(function(){return v.b}));var r=n(10),a=n.n(r),i=n(13),o=n(63),c=n(45),s=n(16),u=n(59),l=n(23),f=n(55),d=n(69),p=n.n(d);function g(e){return p()(e)&&e.hasOwnProperty("code")&&("string"==typeof e.code||"number"==typeof e.code)&&e.hasOwnProperty("message")&&"string"==typeof e.message&&e.hasOwnProperty("data")}var h=n(95),m=n(125),b=n(29),v=n(70),y=n(97);function k(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function O(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?k(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):k(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var _=function(e,t){var n=O({data:{}},e);return n.data=O({dateRange:t},n.data),n},j={maxRequests:10,combinedGetFromCache:function(e){var t=this;return new Promise((function(n,r){try{var a=[],o=Object(u.c)();Object(i.each)(e,(function(e){var n=_(e,o);n.key=Object(b.c)(n.type,n.identifier,n.datapoint,n.data);var r=Object(b.b)(n.key,n.maxAge);void 0!==r&&(a[n.key]=r,t.resolve(n,r))})),n(a)}catch(e){r()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=[],a=25,l=Object(u.c)();Object(i.each)(e,(function(e){var n=_(e,l);n.key=Object(b.c)(n.type,n.identifier,n.datapoint,n.data);var i=Object(b.b)(n.key,n.maxAge);void 0!==i?(setTimeout((function(){t.resolve(n,i)}),a),a+=25):r.push(n)})),r=Object(i.sortBy)(r,"priority");var d=[],p=[],h={},m=!!r.find((function(e){return e.priority<10}));Object(i.each)(r,(function(e,t){!n&&10<=e.priority&&m?p.push(e):h[e.key]?h[e.key].push(t):(h[e.key]=[t],d.push(e))}));var v=10,y=d.slice(0,v),k=d.slice(v);if(k=k.concat(p),0!==y.length||0!==k.length){0<k.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(k,!0)}),50):this.maxRequests=10;var O=null!==Object(f.c)("datacache");return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/data/",{datacache:O||void 0}),data:{request:y},method:"POST"}).then((function(e){Object(i.each)(e,(function(e,n){if(h[n]){var a=g(e);a&&t.handleWPError(e),Object(i.each)(h[n],(function(n){var i=r[n];a||Object(b.e)(i.key,e),t.resolve(i,e)})),0===k.length&&Object(s.d)("googlesitekit.dataLoaded","api")}else console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(s.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){console.warn("WP Error in data response",e);var t=e.data;if(t&&t.reason){var n=0;["authError","insufficientPermissions"].includes(t.reason)&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(l.b)(h.a),1),n++),"forbidden"===t.reason&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(l.b)(m.a),1),n++),n&&Object(s.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(s.g)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+n}))}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},invalidateCacheGroup:y.a,collectModuleData:function(e,t){var n=Object(s.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var r=this,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=Object(b.c)(e,t,n,a);if(!i){var u=Object(b.b)(s,3600);if(void 0!==u)return new Promise((function(e){e(u)}))}return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),a)}).then((function(e){return i||Object(b.e)(s,e),Promise.resolve(e)})).catch((function(e){return r.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,r){var a={};return a.data=r,Object(o.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:a,method:"POST"}).then((function(r){return j.invalidateCacheGroup(e,t,n),new Promise((function(e){e(r)}))}))},setModuleActive:function(e,t){return this.set(v.a,"modules","activation",{slug:e,active:t})}};Object(s.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData")||Object(s.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData",j.collectModuleData.bind(j));t.c=j},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return i}));var r="core/user",a="googlesitekit_manage_options",i="missing_required_scopes"},208:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return j})),n.d(t,"a",(function(){return D})),n.d(t,"c",(function(){return S}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),u=n(19),l=n.n(u),f=n(246),d=n.n(f),p=n(63),g=n(45),h=n(162),m=n(234),b=n(214),v=n(215),y=n(216),k=n(32);function O(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?O(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):O(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var j=function(){var t=s()(a.a.mark((function t(n){var r,i,o,c,u;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e._googlesitekitLegacyData.admin,i=r.homeURL,o=r.ampMode,c={tagverify:1,timestamp:Date.now()},t.next=4,w(Object(g.a)(i,c),n);case 4:if((u=t.sent)||k.b!==o){t.next=9;break}return t.next=8,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map(function(){var e=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w(Object(g.a)(t.link,_(_({},c),{},{amp:1})),n);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).pop()}));case 8:u=t.sent;case 9:return t.abrupt("return",Promise.resolve(u||null));case 10:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),w=function(){var e=s()(a.a.mark((function e(t,n){var r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,fetch(t,{credentials:"omit"}).then((function(e){return e.text()}));case 3:return r=e.sent,e.abrupt("return",E(r,n)||null);case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",null);case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t,n){return e.apply(this,arguments)}}(),E=function(e,t){var n=({adsense:b.a,analytics:v.a,tagmanager:y.b,setup:m.a}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},D=function(e,t){var n=t.find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},S=d()(function(){var e=s()(a.a.mark((function e(t){var n,r,i,o;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.homeURL,r=t.ampMode,l()(Object(h.a)(n),"homeURL must be valid URL"),i=[n],k.b!==r){e.next=14;break}return e.prev=4,e.next=7,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return Object(g.a)(e.link,{amp:1})})).pop()}));case 7:(o=e.sent)&&i.push(o),e.next=14;break;case 11:return e.prev=11,e.t0=e.catch(4),e.abrupt("return",i);case 14:return e.abrupt("return",i);case 15:case"end":return e.stop()}}),e,null,[[4,11]])})));return function(t){return e.apply(this,arguments)}}())}).call(this,n(15))},212:function(e,t,n){"use strict";t.a=[/<script[^>]*>[^>]+?www.googletagmanager.com\/gtm[^>]+?['|"](GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtm\.js\?id=(GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/ns.html\?id=(GTM-[0-9A-Z]+)['|"]/,/<amp-analytics [^>]*config=['|"]https:\/\/www.googletagmanager.com\/amp.json\?id=(GTM-[0-9A-Z]+)['|"]/]},214:function(e,t,n){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},215:function(e,t,n){"use strict";t.a=[/<script [^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtag\/js\?id=(UA-.*?)['|"][^>]*><\/script>/,/<script[^>]*>[^<]+google-analytics\.com\/analytics\.js[^<]+(UA-\d+-\d+)/,/__gaTracker\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/ga\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/_gaq.push\( ?\[ ?['|"]_setAccount['|"], ?['|"](UA-.*?)['|"] ?] ?\)/,/<amp-analytics [^>]*type="gtag"[^>]*>[^<]*<script type="application\/json">[^<]*"gtag_id":\s*"(UA-[^"]+)"/,/<amp-analytics [^>]*type="googleanalytics"[^>]*>[^<]*<script type="application\/json">[^<]*"account":\s*"(UA-[^"]+)"/]},216:function(e,t,n){"use strict";function r(e){return(parseInt(e,10)||0)>0}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a.a}));var a=n(212)},23:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var r=n(81),a=n.n(r),i=n(1),o=function(e){return function(t){return function FilteredComponent(n){return Object(i.f)(i.b,{},"",Object(i.f)(t,n),e)}}},c=function(t,n){return function(r){return function InnerComponent(i){return e.createElement(t,a()({},i,n,{OriginalComponent:r}))}}}}).call(this,n(12))},233:function(e,t,n){"use strict";(function(e,t){n(1);var r=n(16),a=n(23),i=n(5),o=n(153),c=n(154),s=n(156),u=n(158),l=n(95),f=e._googlesitekitLegacyData.setup,d=Object(i.k)("notification"),p=Object(a.a)(t.createElement(o.a,null)),g=Object(a.a)(t.createElement(c.a,null)),h=Object(a.a)(t.createElement(s.a,null)),m=Object(a.a)(t.createElement(u.a,null)),b=Object(a.a)(t.createElement(l.a,null));Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.SetupNotification",p,10),f.needReauthenticate&&Object(r.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",b,1),"authentication_success"===d||"authentication_failure"===d?Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.SetupNotification",g,1):f.isAuthenticated&&f.isVerified&&(Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.ModulesNotification",h,1),Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.WinsNotification",m,1))}).call(this,n(15),n(12))},234:function(e,t,n){"use strict";t.a=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/]},252:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(22),s=n.n(c),u=n(8),l=n.n(u),f=n(9),d=n.n(f),p=n(3),g=n.n(p),h=n(1),m=n(18),b=n.n(m),v=n(0),y=n(16),k=n(77);function O(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var a=g()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return d()(this,n)}}var _=function(t){l()(NotificationCounter,t);var n=O(NotificationCounter);function NotificationCounter(e){var t;return a()(this,NotificationCounter),(t=n.call(this,e)).state={count:0},t.handleIncrement=t.handleIncrement.bind(s()(t)),t.handleDecrement=t.handleDecrement.bind(s()(t)),t}return o()(NotificationCounter,[{key:"componentDidMount",value:function(){var e=this;Object(y.a)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetTotalNotifications",(function(){Object(y.f)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetTotalNotifications"),Object(k.c)().then((function(t){e.setState({count:t})}))})),document.addEventListener("notificationDismissed",this.handleDecrement,!1)}},{key:"componentWillUnmount",value:function(){document.removeEventListener("notificationDismissed",this.handleDecrement)}},{key:"handleIncrement",value:function(){this.setState(k.e)}},{key:"handleDecrement",value:function(){this.setState(k.a)}},{key:"render",value:function(){var t=Object(v.sprintf)(
5
  /* translators: %d: the number of notifications */
6
- Object(v._n)("%d notification","%d notifications",this.state.count,"google-site-kit"),this.state.count),n=e.createElement("span",{className:b()("googlesitekit-notifications-counter","update-plugins","count-".concat(this.state.count))},e.createElement("span",{className:"plugin-count","aria-hidden":"true"},this.state.count),e.createElement("span",{className:"screen-reader-text"},t));return Object(h.g)(n,document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"))}}]),NotificationCounter}(h.a);t.a=_}).call(this,n(12))},268:function(e,t,n){"use strict";(function(e){var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),u=n(6),l=n.n(u),f=n(7),d=n.n(f),p=n(22),g=n.n(p),h=n(8),m=n.n(h),b=n(9),v=n.n(b),y=n(3),k=n.n(y),O=n(1),_=n(2),j=n.n(_),w=n(18),E=n.n(w),D=n(63),S=n(0),x=n(5),R=n(269),N=n(50);function P(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var C=function(t){m()(OptIn,t);var n,r=P(OptIn);function OptIn(e){var t;return l()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(N.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(g()(t)),t}return d()(OptIn,[{key:"handleOptIn",value:(n=s()(a.a.mark((function e(t){var n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(x.i)("googlesitekit_tracking_optin"),Object(N.b)(n),!n){e.next=6;break}return e.next=6,Object(N.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(D.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,a=this.props,i=a.id,o=a.name,c=a.className,s=Object(S.sprintf)(
7
  /* translators: %s: privacy policy URL */
8
- Object(S.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:E()("googlesitekit-opt-in",c)},e.createElement(R.a,{id:i,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(x.t)(s,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(O.a);C.propTypes={id:j.a.string,name:j.a.string,className:j.a.string,optinAction:j.a.string},C.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=C}).call(this,n(12))},269:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(Checkbox,t);var n=y(Checkbox);function Checkbox(e){var t;return a()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(p.h)(),t.checkboxRef=Object(p.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,a=t.name,i=t.value,o=t.checked,c=t.disabled,s=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:b()("mdc-checkbox",{"mdc-checkbox--disabled":c}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:a,value:i,checked:o,disabled:c,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},s))}}]),Checkbox}(p.a);k.propTypes={onChange:h.a.func.isRequired,id:h.a.string.isRequired,name:h.a.string.isRequired,value:h.a.string.isRequired,checked:h.a.bool,disabled:h.a.bool,children:h.a.node.isRequired},k.defaultProps={checked:!1,disabled:!1},t.a=k}).call(this,n(12))},28:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var y=function(t){s()(Link,t);var n=v(Link);function Link(){return a()(this,Link),n.apply(this,arguments)}return o()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,r=t.onClick,a=t.href,i=t.children,o=t.className,c=t.arrow,s=t.external,u=t.inverse,l=t.back,f=t.small,d=t.inherit,p=t.caps,g=t.danger,h=t.disabled,m=t.id,v=a&&!h,y=v?"a":"button";return e.createElement(y,{className:b()("googlesitekit-cta-link",o,{"googlesitekit-cta-link--arrow":c,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":u,"googlesitekit-cta-link--back":l,"googlesitekit-cta-link--small":f,"googlesitekit-cta-link--inherit":d,"googlesitekit-cta-link--caps":p,"googlesitekit-cta-link--danger":g,"googlesitekit-cta-link--disabled":h}),onClick:r,id:m,href:v?a:void 0,target:v&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:h,dangerouslySetInnerHTML:n},i)}}]),Link}(p.a);y.propTypes={dangerouslySetInnerHTML:h.a.shape({__html:h.a.string}),onClick:h.a.func,href:h.a.string,children:h.a.oneOfType([h.a.string.isRequired,h.a.array.isRequired]),className:h.a.string,arrow:h.a.bool,external:h.a.bool,inverse:h.a.bool,back:h.a.bool,small:h.a.bool,inherit:h.a.bool,caps:h.a.bool,danger:h.a.bool,disabled:h.a.bool},y.defaultProps={dangerouslySetInnerHTML:void 0,onClick:null,href:"",className:"",arrow:!1,external:!1,inverse:!1,back:!1,small:!1,inherit:!1,caps:!1,danger:!1,disabled:!1},t.a=y}).call(this,n(12))},29:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"b",(function(){return l})),n.d(t,"a",(function(){return f})),n.d(t,"c",(function(){return d}));var r=n(33),a=n.n(r),i=n(13),o=n(40),c=n(56),s=function(){e._googlesitekitLegacyData.admin=e._googlesitekitLegacyData.admin||{},"string"==typeof e._googlesitekitLegacyData.admin.datacache&&(e._googlesitekitLegacyData.admin.datacache=JSON.parse(e._googlesitekitLegacyData.admin.datacache)),"object"!==a()(e._googlesitekitLegacyData.admin.datacache)&&(e._googlesitekitLegacyData.admin.datacache={})},u=function(t,n){if(void 0!==n&&(!n||"object"!==a()(n)||!n.error&&!n.errors)){s(),e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(n);var r={value:n,date:Date.now()/1e3};Object(o.a)().setItem("googlesitekit_"+t,JSON.stringify(r))}},l=function(t,n){if(!e._googlesitekitLegacyData.admin.nojscache){if(s(),void 0!==e._googlesitekitLegacyData.admin.datacache[t])return e._googlesitekitLegacyData.admin.datacache[t];var r=JSON.parse(Object(o.a)().getItem("googlesitekit_"+t));return r&&"object"===a()(r)&&r.date&&(!n||Date.now()/1e3-r.date<n)?(e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(r.value),Object(i.cloneDeep)(e._googlesitekitLegacyData.admin.datacache[t])):void 0}},f=function(t){s(),delete e._googlesitekitLegacyData.admin.datacache[t],Object(o.a)().removeItem("googlesitekit_"+t)},d=function(e,t,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],s=0,u=o;s<u.length;s++){var l=u[s];if(!l||!l.length)break;i.push(l)}return 3===i.length&&r&&"object"===a()(r)&&Object.keys(r).length&&i.push(Object(c.a)(r)),i.join("::")}}).call(this,n(15))},31:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(22),s=n.n(c),u=n(8),l=n.n(u),f=n(9),d=n.n(f),p=n(3),g=n.n(p),h=n(1),m=n(2),b=n.n(m),v=n(18),y=n.n(v),k=n(123),O=n(60),_=n(80);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var a=g()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return d()(this,n)}}var w=function(t){l()(DataBlock,t);var n=j(DataBlock);function DataBlock(e){var t;return a()(this,DataBlock),(t=n.call(this,e)).handleClick=t.handleClick.bind(s()(t)),t.handleKeyPress=t.handleKeyPress.bind(s()(t)),t}return o()(DataBlock,[{key:"handleClick",value:function(){var e=this.props,t=e.stat;(0,e.handleStatSelection)(t)}},{key:"handleKeyPress",value:function(e){e.preventDefault();var t=this.props,n=t.stat,r=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||r(n)}},{key:"render",value:function(){var t=this.props,n=t.className,r=t.title,a=t.datapoint,i=t.datapointUnit,o=t.change,c=t.changeDataUnit,s=t.context,u=t.period,l=t.selected,f=t.handleStatSelection,d=t.source,p=t.sparkline,g=t.invertChangeColor,m="button"===s?"button":"",b=p;return b&&g&&(b=Object(h.d)(p,{invertChangeColor:g})),e.createElement("div",{className:y()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":l}),tabIndex:"button"===s?"0":"-1",role:f&&m,onClick:f&&this.handleClick,onKeyPress:f&&this.handleKeyPress,"aria-label":f&&r,"aria-pressed":f&&l},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},r),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(a).concat(i))),b&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},b),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===o&&e.createElement(h.b,null," "),o&&e.createElement(h.b,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(k.a,{direction:0<parseFloat(o)?"up":"down",invertColor:g})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(O.b)(Math.abs(o))).concat(c," ").concat(u)))),d&&e.createElement(_.a,{className:"googlesitekit-data-block__source",name:d.name,href:d.link})))}}]),DataBlock}(h.a);w.propTypes={stat:b.a.number,onClick:b.a.func,className:b.a.string,title:b.a.string,datapoint:b.a.oneOfType([b.a.string,b.a.number]),datapointUnit:b.a.string,change:b.a.oneOfType([b.a.string,b.a.number]),changeDataUnit:b.a.string,context:b.a.string,period:b.a.string,selected:b.a.bool,handleStatSelection:b.a.func,invertChangeColor:b.a.bool},w.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=w}).call(this,n(12))},32:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return i}));var r="core/site",a="primary",i="secondary"},34:function(e,t,n){"use strict";(function(e,r){n(1);var a=n(2),i=n.n(a),o=n(18),c=n.n(o),s=function SvgIcon(t){var n=t.id,a=t.className,i=t.height,o=t.width,s="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:c()("svg",a),height:i,width:o},r.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:i.a.string.isRequired,className:i.a.string,height:i.a.string,width:i.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(15),n(12))},35:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r="_googlesitekitDataLayer",a="data-googlesitekit-gtag"},37:function(e,t,n){"use strict";(function(e){var r=n(10),a=n.n(r),i=n(4),o=n.n(i),c=n(14),s=n.n(c),u=n(6),l=n.n(u),f=n(7),d=n.n(f),p=n(22),g=n.n(p),h=n(8),m=n.n(h),b=n(9),v=n.n(b),y=n(3),k=n.n(y),O=n(1),_=n(2),j=n.n(_),w=n(18),E=n.n(w),D=n(13),S=n(34),x=n(54),R=n(29),N=n(31),P=n(47),C=n(119),A=n(124),L=n(28);function I(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var T=function(t){m()(Notification,t);var n,r,i=I(Notification);function Notification(e){var t;return l()(this,Notification),(t=i.call(this,e)).state={isClosed:!1},t.cardRef=Object(O.h)(),t.handleDismiss=t.handleDismiss.bind(g()(t)),t.handleCTAClick=t.handleCTAClick.bind(g()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&Object(R.e)("notification::displayed::".concat(t.props.id),new Date),t}return d()(Notification,[{key:"handleDismiss",value:(r=s()(o.a.mark((function e(t){var n;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),t.preventDefault(),!(n=this.props.onDismiss)){e.next=6;break}return e.next=6,n(t);case 6:this.dismiss();case 7:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){Object(R.e)("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:(n=s()(o.a.mark((function e(t){var n,r,a;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),n=this.props,r=n.isDismissable,!(a=n.onCTAClick)){e.next=5;break}return e.next=5,a(t);case 5:r&&this.dismiss();case 6:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,r=Object(R.b)("notification::dismissed::".concat(t));if(r){var a=new Date(r);a.setSeconds(a.getSeconds()+parseInt(n,10)),a<new Date&&Object(R.a)("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,r=this.props,i=r.children,o=r.id,c=r.title,s=r.description,u=r.blockData,l=r.winImage,f=r.smallImage,d=r.format,p=r.learnMoreURL,g=r.learnMoreDescription,h=r.learnMoreLabel,m=r.ctaLink,b=r.ctaLabel,v=r.ctaTarget,y=r.type,k=r.dismiss,_=r.isDismissable,j=r.logo,w=r.module,I=r.moduleName,T=r.pageIndex,M=r.anchorLink,U=r.anchorLinkLabel;if(Object(R.b)("notification::dismissed::".concat(o)))return null;var q,F=n?"is-closed":"is-open",H="large"===d&&"win-stats-increase"===y,G="mdc-layout-grid__cell--span-12";"large"===d?(G="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-6-tablet mdc-layout-grid__cell--span-8-desktop ",H&&(G="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-8-desktop ")):"small"===d&&(G="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),q="win-warning"===y?e.createElement(C.a,null):"win-error"===y?e.createElement(A.a,null):"";var B=e.createElement(O.b,null,u&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(D.map)(u,(function(t,n){return e.createElement("div",{key:n,className:E()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":H,"mdc-layout-grid__cell--span-4-desktop":!H})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(N.a,t)))})))),W=e.createElement(O.b,null,c&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},c),M&&U&&e.createElement("p",{className:"googlesitekit-publisher-win__link"},e.createElement(L.a,{href:M},U)),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(O.i)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(x.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),h&&e.createElement(O.b,null," ",e.createElement(L.a,{href:p,external:!0,inherit:!0},h),g),T&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},T))),i),K=w?e.createElement(S.a,{id:w,height:"19",width:"19"}):e.createElement(S.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:E()("googlesitekit-publisher-win",(t={},a()(t,"googlesitekit-publisher-win--".concat(d),d),a()(t,"googlesitekit-publisher-win--".concat(y),y),a()(t,"googlesitekit-publisher-win--".concat(F),F),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},j&&e.createElement("div",{className:E()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":H,"mdc-layout-grid__cell--order-1-tablet":H})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},K),I&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},I)),f&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("img",{className:"googlesitekit-publisher-win__small-image",alt:"",src:f})),e.createElement("div",{className:E()("mdc-layout-grid__cell",G)},H?e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-5-desktop mdc-layout-grid__cell--span-8-tablet"},W),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--align-bottom"},B)):e.createElement(O.b,null,W,B),m&&e.createElement(P.a,{href:m,target:v,onClick:this.handleCTAClick},b),_&&k&&e.createElement(L.a,{onClick:this.handleDismiss},k)),l&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--order-1-phone mdc-layout-grid__cell--order-2-tablet mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement("div",{className:"googlesitekit-publisher-win__image-large"},e.createElement("img",{alt:"",src:l}))),("win-error"===y||"win-warning"===y)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},q)))))}}]),Notification}(O.a);T.propTypes={id:j.a.string.isRequired,title:j.a.string.isRequired,description:j.a.node,learnMoreURL:j.a.string,learnMoreDescription:j.a.string,learnMoreLabel:j.a.string,blockData:j.a.array,winImage:j.a.string,smallImage:j.a.string,format:j.a.string,ctaLink:j.a.string,ctaLabel:j.a.string,type:j.a.string,dismiss:j.a.string,isDismissable:j.a.bool,logo:j.a.bool,module:j.a.string,moduleName:j.a.string,pageIndex:j.a.string,dismissExpires:j.a.number,showOnce:j.a.bool,onCTAClick:j.a.func,onDismiss:j.a.func,anchorLink:j.a.string,anchorLinkLabel:j.a.string},T.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=T}).call(this,n(12))},370:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return A}));var a=n(44),i=n.n(a),o=n(6),c=n.n(o),s=n(7),u=n.n(s),l=n(8),f=n.n(l),d=n(9),p=n.n(d),g=n(3),h=n.n(g),m=n(4),b=n.n(m),v=n(14),y=n.n(v),k=n(1),O=n(0),_=n(2),j=n.n(_),w=n(119),E=n(49),D=n(208),S=n(17),x=n(28);function R(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return N(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return N(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function N(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function P(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h()(e);if(t){var a=h()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return p()(this,n)}}var C=[y()(b.a.mark((function t(){var n;return b.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.location.hostname,!["localhost","127.0.0.1"].includes(n)&&!n.match(/\.(example|invalid|localhost|test)$/)){t.next=3;break}throw"invalid_hostname";case 3:case"end":return t.stop()}}),t)}))),y()(b.a.mark((function e(){var t,n,r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,S.c.set(S.a,"site","setup-tag");case 2:return t=e.sent,n=t.token,e.next=6,Object(D.b)("setup").catch((function(){throw"tag_fetch_failed"}));case 6:if(r=e.sent,n===r){e.next=9;break}throw"setup_token_mismatch";case 9:case"end":return e.stop()}}),e)})))],A=function(t){f()(CompatibilityChecks,t);var n,a=P(CompatibilityChecks);function CompatibilityChecks(t){var n;c()(this,CompatibilityChecks);var r=e._googlesitekitLegacyData.setup.isSiteKitConnected;return(n=a.call(this,t)).state={complete:r,error:null,developerPlugin:{}},n}return u()(CompatibilityChecks,[{key:"componentDidMount",value:(n=y()(b.a.mark((function e(){var t,n,r,a;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.state.complete){e.next=2;break}return e.abrupt("return");case 2:e.prev=2,t=R(C),e.prev=4,t.s();case 6:if((n=t.n()).done){e.next=12;break}return r=n.value,e.next=10,r();case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),t.e(e.t0);case 17:return e.prev=17,t.f(),e.finish(17);case 20:e.next=28;break;case 22:return e.prev=22,e.t1=e.catch(2),e.next=26,S.c.get(S.a,"site","developer-plugin");case 26:a=e.sent,this.setState({error:e.t1,developerPlugin:a});case 28:this.setState({complete:!0});case 29:case"end":return e.stop()}}),e,this,[[2,22],[4,14,17,20]])}))),function(){return n.apply(this,arguments)})},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,n=e.active,r=e.installURL,a=e.activateURL,i=e.configureURL;return!t&&r?{labelHTML:Object(O.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:r,external:!1}:t&&!n&&a?{labelHTML:Object(O.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:a,external:!1}:t&&n&&i?{labelHTML:Object(O.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:{labelHTML:Object(O.__)('Learn how<span class="screen-reader-text"> to install and use the helper plugin</span>',"google-site-kit"),href:"https://sitekit.withgoogle.com/documentation/using-site-kit-on-a-staging-environment/",external:!0}}},{key:"renderError",value:function(e){var t=this.state.developerPlugin.installed,n=this.helperCTA(),a=n.labelHTML,i=n.href,o=n.external;switch(e){case"invalid_hostname":case"tag_fetch_failed":return r.createElement(k.b,null,!t&&Object(O.__)("Looks like this may be a staging environment. If so, you’ll need to install a helper plugin and verify your production site in Search Console.","google-site-kit"),t&&Object(O.__)("Looks like this may be a staging environment and you already have the helper plugin. Before you can use Site Kit, please make sure you’ve provided the necessary credentials in the Authentication section and verified your production site in Search Console.","google-site-kit")," ",r.createElement(x.a,{href:i,dangerouslySetInnerHTML:{__html:a},external:o,inherit:!0}));case"setup_token_mismatch":return Object(O.__)("Looks like you may be using a caching plugin which could interfere with setup. Please deactivate any caching plugins before setting up Site Kit. You may reactivate them once setup has been completed.","google-site-kit")}}},{key:"render",value:function(){var e,t,n=this.state,a=n.complete,o=n.error,c=this.props,s=c.children,u=i()(c,["children"]);return o&&(e=r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement(w.a,null),r.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(O.__)("Your site may not be ready for Site Kit","google-site-kit"))),r.createElement("p",null,this.renderError(o))))),a||(t=r.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},r.createElement("small",null,Object(O.__)("Checking Compatibility…","google-site-kit")),r.createElement(E.a,{small:!0,compress:!0}))),s({restProps:u,complete:a,error:o,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(k.a);A.propTypes={children:j.a.func.isRequired}}).call(this,n(15),n(12))},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r,a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=function(t){var n=e[t];if(!n)return!1;try{var r="__storage_test__";return n.setItem(r,r),n.removeItem(r),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},u=function(){function NullStorage(){i()(this,NullStorage)}return c()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),l=function(){return r||(r=s("sessionStorage")?e.sessionStorage:s("localStorage")?e.localStorage:new u),r}}).call(this,n(15))},41:function(e,t){e.exports=googlesitekit.api},42:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return b}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(19),s=n.n(c),u=n(69),l=n.n(u),f=n(65),d=n(5);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=function(e){return g({},e)},m=function(){return{}},b=function(t){var n,r,i=t.baseName,c=t.controlCallback,u=t.reducerCallback,p=void 0===u?h:u,b=t.argsToParams,v=void 0===b?m:b;s()(i,"baseName is required."),s()("function"==typeof c,"controlCallback is required and must be a function."),s()("function"==typeof p,"reducerCallback must be a function."),s()("function"==typeof v,"argsToParams must be a function.");try{v(),r=!1}catch(e){r=!0}var y=Object(f.b)(i),k=Object(f.a)(i),O="FETCH_".concat(k),_="START_".concat(O),j="FINISH_".concat(O),w="CATCH_".concat(O),E="RECEIVE_".concat(k),D="fetch".concat(y),S="receive".concat(y),x="isFetching".concat(y),R=o()({},x,{}),N=(n={},o()(n,D,a.a.mark((function t(){var n,r,i,o=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:t.prev=0,i=v.apply(void 0,o),t.next=9;break;case 4:return t.prev=4,t.t0=t.catch(0),e.console.error(t.t0.message),r=t.t0,t.abrupt("return",{response:n,error:r});case 9:return t.next=11,{payload:{params:i},type:_};case 11:return t.prev=11,t.next=14,{payload:{params:i},type:O};case 14:return n=t.sent,t.next=17,N[S](n,i);case 17:return t.next=19,{payload:{params:i},type:j};case 19:t.next=26;break;case 21:return t.prev=21,t.t1=t.catch(11),r=t.t1,t.next=26,{payload:{error:r,params:i},type:w};case 26:return t.abrupt("return",{response:n,error:r});case 27:case"end":return t.stop()}}),t,null,[[0,4],[11,21]])}))),o()(n,S,(function(e,t){return s()(void 0!==e,"response is required."),r?s()(l()(t),"params is required."):t={},{payload:{response:e,params:t},type:E}})),n),P=o()({},O,(function(e){var t=e.payload;return c(t.params)})),C=o()({},x,(function(e){if(void 0===e[x])return!1;var t;try{for(var n=arguments.length,r=new Array(n>1?n-1:0),a=1;a<n;a++)r[a-1]=arguments[a];t=v.apply(void 0,r)}catch(e){return!1}return!!e[x][Object(d.v)(t)]}));return{INITIAL_STATE:R,actions:N,controls:P,reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case _:var a=r.params;return g(g({},e),{},o()({},x,g(g({},e[x]),{},o()({},Object(d.v)(a),!0))));case E:var i=r.response,c=r.params;return p(e,i,c);case j:var s=r.params;return g(g({},e),{},o()({},x,g(g({},e[x]),{},o()({},Object(d.v)(s),!1))));case w:var u=r.error,l=r.params;return g(g({},e),{},o()({error:u},x,g(g({},e[x]),{},o()({},Object(d.v)(l),!1))));default:return g({},e)}},resolvers:{},selectors:C}}}).call(this,n(15))},43:function(e,t,n){"use strict";var r=n(78),a=n.n(r);n.d(t,"k",(function(){return a.a})),n.d(t,"a",(function(){return r.HelperText})),n.d(t,"b",(function(){return r.Input}));var i=n(134);n.d(t,"g",(function(){return i.a}));var o=n(221);n.d(t,"e",(function(){return o.a}));var c=n(99),s=n.n(c);n.d(t,"j",(function(){return s.a})),n.d(t,"i",(function(){return c.Option}));var u=n(220);n.d(t,"h",(function(){return u.a}));var l=n(219);n.d(t,"d",(function(){return l.a}));var f=n(218);n.d(t,"c",(function(){return f.a}));var d=n(217);n.d(t,"f",(function(){return d.a}))},449:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return ActivationApp}));var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(1),u=n(0),l=n(5),f=n(450),d=n(252);function ActivationApp(){var t=e._googlesitekitBaseData,n=t.proxySetupURL,a=t.splashURL,o=e._googlesitekitLegacyData.permissions.canViewDashboard,p=e._googlesitekitLegacyData.dashboardPermalink,g=n||a,h=Object(u.__)("Start setup","google-site-kit");o&&(g=p,h=Object(u.__)("Go to Dashboard","google-site-kit"));var m=Object(s.l)(function(){var t=c()(i.a.mark((function t(r){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r.preventDefault(),t.next=3,Object(l.w)("plugin_setup",n?"proxy_start_setup_banner":"goto_sitekit");case 3:e.location.assign(g);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());return r.createElement(s.b,null,r.createElement(d.a,null),r.createElement(f.a,{buttonURL:g,buttonLabel:h,onButtonClick:m}))}}).call(this,n(15),n(12))},450:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return ActivationMain}));var r=n(1),a=n(0),i=n(2),o=n.n(i),c=n(47),s=n(135),u=n(268),l=n(370);function ActivationMain(t){var n=t.buttonURL,i=t.onButtonClick,o=t.buttonLabel;return e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(s.a,null),e.createElement("h3",{className:"googlesitekit-heading-3 googlesitekit-activation__title"},Object(a.__)("Congratulations, the Site Kit plugin is now activated.","google-site-kit")),e.createElement(l.a,null,(function(t){var a=t.complete,s=t.inProgressFeedback,l=t.CTAFeedback;return e.createElement(r.b,null,l,e.createElement(u.a,{optinAction:"analytics_optin_setup_banner"}),e.createElement("div",{className:"googlesitekit-start-setup-wrap"},e.createElement(c.a,{id:"start-setup-link",className:"googlesitekit-start-setup",href:n,onClick:i,disabled:!a},o),s))})))))}ActivationMain.propTypes={buttonURL:o.a.string.isRequired,onButtonClick:o.a.func,buttonLabel:o.a.string.isRequired}}).call(this,n(12))},47:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(43);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(Button,t);var n=y(Button);function Button(e){var t;return a()(this,Button),(t=n.call(this,e)).buttonRef=Object(p.h)(),t}return o()(Button,[{key:"componentDidMount",value:function(){new v.g(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,r=t.children,a=t.href,i=t.text,o=t.className,c=t.danger,s=t.disabled,u=t.target,l=t.id,f=t.icon,d=t.trailingIcon,p=t.ariaHaspopup,g=t.ariaExpanded,h=t.ariaControls,m=a&&!s?"a":"button";return e.createElement(m,{className:b()("mdc-button",o,{"mdc-button--raised":!i,"mdc-button--danger":c}),onClick:n,href:s?void 0:a,ref:this.buttonRef,disabled:!!s,target:u||"_self",id:l,"aria-haspopup":p,"aria-expanded":g,"aria-controls":h,role:"a"===m?"button":void 0},f&&f,e.createElement("span",{className:"mdc-button__label"},r),d&&d)}}]),Button}(p.a);k.propTypes={onClick:h.a.func,children:h.a.string.isRequired,href:h.a.string,text:h.a.bool,className:h.a.string,danger:h.a.bool,disabled:h.a.bool,icon:h.a.element,trailingIcon:h.a.element,ariaHaspopup:h.a.string,ariaExpanded:h.a.bool,ariaControls:h.a.string},k.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=k}).call(this,n(12))},49:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var y=function(t){s()(ProgressBar,t);var n=v(ProgressBar);function ProgressBar(){return a()(this,ProgressBar),n.apply(this,arguments)}return o()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,r=t.small,a=t.compress,i=t.height,o=i?Math.round(i/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:o,marginBottom:o},className:b()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":r,"mdc-linear-progress--compress":a})},e.createElement("div",{className:"mdc-linear-progress__buffering-dots"}),e.createElement("div",{className:"mdc-linear-progress__buffer"}),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})))}}]),ProgressBar}(p.a);y.propTypes={className:h.a.string,small:h.a.bool,compress:h.a.bool},y.defaultProps={className:"",small:!1,compress:!1},t.a=y}).call(this,n(12))},5:function(e,t,n){"use strict";(function(e,r){n.d(t,"s",(function(){return R})),n.d(t,"q",(function(){return N})),n.d(t,"n",(function(){return C})),n.d(t,"r",(function(){return A})),n.d(t,"h",(function(){return L})),n.d(t,"c",(function(){return I})),n.d(t,"f",(function(){return T})),n.d(t,"j",(function(){return M})),n.d(t,"l",(function(){return U})),n.d(t,"m",(function(){return q})),n.d(t,"x",(function(){return F})),n.d(t,"b",(function(){return H})),n.d(t,"u",(function(){return G})),n.d(t,"e",(function(){return B})),n.d(t,"p",(function(){return W})),n.d(t,"i",(function(){return K}));var a=n(4),i=n.n(a),o=n(14),c=n.n(o),s=n(10),u=n.n(s),l=n(44),f=n.n(l),d=n(33),p=n.n(d),g=(n(1),n(13)),h=n(16),m=n(0),b=n(45),v=n(142),y=n(34);n.d(t,"a",(function(){return y.a}));var k=n(50);n.d(t,"w",(function(){return k.c}));var O=n(23),_=n(54);n.d(t,"t",(function(){return _.a}));var j=n(56);n.d(t,"v",(function(){return j.a}));var w=n(55);n.d(t,"d",(function(){return w.b})),n.d(t,"k",(function(){return w.c}));n(40);var E=n(60);function D(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?D(Object(n),!0).forEach((function(t){u()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return E.a})),n.d(t,"g",(function(){return O.b}));var x=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},R=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(g.isFinite)(e)?e:Number(e),Object(g.isFinite)(e)||(console.warn("Invalid number",e,p()(e)),e=0),t)return N(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in millions.
9
- Object(m.__)("%sM","google-site-kit"),N(x(e),e%10==0?{}:n)):1e4<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
10
- Object(m.__)("%sK","google-site-kit"),N(x(e))):1e3<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
11
- Object(m.__)("%sK","google-site-kit"),N(x(e),e%10==0?{}:n)):e.toString()},N=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?P():n,a=f()(t,["locale"]);return new Intl.NumberFormat(r,a).format(e)},P=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(g.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language},C=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},A=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},L=function(e,t){var n=1e3*C("day"),r=e.getTime(),a=t.getTime();return Math.round(Math.abs(r-a)/n)},I=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},T=function(e,t){return Object(g.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},M=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==p()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:S(S({},e),{},u()({},t,n[t]))}),{}):{}},U=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,a=r.admin,i=a.connectURL,o=a.adminRoot,c=r.setup.needReauthenticate,s=M(r)[t].screenID,u="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(b.a)(o,S({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},u));if(!c)return l;var f=encodeURIComponent(Object(v.a)(l));return l=o+"?"+f,Object(b.a)(i,{redirect:l,status:n})},q=function(t,n){var r=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=S({page:t},n),Object(b.a)(r,n)},F=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},H=function(){var e=c()(i.a.mark((function e(t,n,r){var a,o,c,s,u=arguments;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=u.length>3&&void 0!==u[3]?u[3]:k.c,o=u.length>4&&void 0!==u[4]?u[4]:M,e.next=4,t.setModuleActive(n,r);case 4:return c=e.sent,(s=o())[n]&&(s[n].active=r),e.next=9,a("".concat(n,"_setup"),r?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",c);case 10:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),G=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(O.b)(e,t),1)},B=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(g.unescape)(t)};function W(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var c=r.createElement(y.a,{id:t,width:a,height:i,className:o});return n?c=r.createElement(y.a,{id:"".concat(t,"-disabled"),width:a,height:i,className:o}):"pagespeed-insights"===t&&(c=r.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:a,alt:"",className:o})),c}}function K(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix,a=n.isNetworkMode;return a?t:r+t}}).call(this,n(15),n(12))},50:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return p})),n.d(t,"c",(function(){return d}));var r=n(66),a=e._googlesitekitBaseData||{},i=a.isFirstAdmin,o=a.trackingAllowed,c={isFirstAdmin:i,trackingEnabled:a.trackingEnabled,trackingID:a.trackingID,referenceSiteURL:a.referenceSiteURL,userIDHash:a.userIDHash},s=Object(r.a)(c),u=s.enableTracking,l=s.disableTracking,f=s.isTrackingEnabled,d=s.trackEvent;function p(e){e?u():l()}!0===o&&p(f())}).call(this,n(15))},52:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(35);function a(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(76),a=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:r.a.sanitize(e,t)}}},55:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return u})),n.d(t,"c",(function(){return f}));var r=n(38),a=n.n(r),i=n(0);function o(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw i}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var s=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,n=null,r=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),a=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(r&&a)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),n=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===n)return!1;var o=document.createElement("span");o.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var c=document.createElement("span");c.setAttribute("class","plugin-count"),c.setAttribute("aria-hidden","true"),c.textContent=e;var s=document.createElement("span");return s.setAttribute("class","screen-reader-text"),s.textContent=Object(i.sprintf)(
 
 
 
 
12
  /* translators: %d is the number of notifications */
13
- Object(i._n)("%d notification","%d notifications",e,"google-site-kit"),e),o.appendChild(c),o.appendChild(s),t&&null===r&&t.appendChild(o),n&&null===a&&n.appendChild(o),o},u=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),n={},r=0;r<t.length;r++)n[t[r].split("=")[0]]=decodeURIComponent(t[r].split("=")[1]);return e?n.hasOwnProperty(e)?decodeURIComponent(n[e].replace(/\+/g," ")):"":n},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,n=new URL(t.href);if(e)return n.searchParams&&n.searchParams.get?n.searchParams.get(e):l(e);var r,i={},c=o(n.searchParams.entries());try{for(c.s();!(r=c.n()).done;){var s=a()(r.value,2),u=s[0],f=s[1];i[u]=f}}catch(e){c.e(e)}finally{c.f()}return i}}).call(this,n(15))},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(33),a=n.n(r),i=n(102),o=n.n(i),c=function(e){return o()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(r){var i=t[r];i&&"object"===a()(i)&&!Array.isArray(i)&&(i=e(i)),n[r]=i})),n}(e)))}},59:function(e,t,n){"use strict";n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return u}));var r=n(0),a=n(11),i=n.n(a),o=n(20);function c(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s(),t=e.match(/last-(\d+)-days/);if(t&&t[1])return Object(r.sprintf)(
14
  /* translators: %s: Number of days matched. */
15
  Object(r._n)("%s day","%s days",parseInt(t[1],10),"google-site-kit"),t[1]);throw new Error("Unrecognized date range slug.")}function s(){return i.a.select(o.c).getDateRange()}function u(){
16
  /* translators: %s: Number of days to request data. */
17
- var e=Object(r.__)("Last %s days","google-site-kit");return{"last-7-days":{slug:"last-7-days",label:Object(r.sprintf)(e,7)},"last-14-days":{slug:"last-14-days",label:Object(r.sprintf)(e,14)},"last-28-days":{slug:"last-28-days",label:Object(r.sprintf)(e,28)},"last-90-days":{slug:"last-90-days",label:Object(r.sprintf)(e,90)}}}},60:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return s}));var r=n(44),a=n.n(r),i=n(13),o=n(0);function c(){Object(o.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?u():n,i=a()(t,["locale"]);return new Intl.NumberFormat(r,i).format(e)},u=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(i.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(15))},63:function(e,t,n){"use strict";(function(e){var r=n(26),a=n.n(r),i=n(106),o=e._googlesitekitAPIFetchData||{},c=o.nonce,s=o.nonceEndpoint,u=o.preloadedData,l=o.rootURL;a.a.nonceEndpoint=s,a.a.nonceMiddleware=a.a.createNonceMiddleware(c),a.a.rootURLMiddleware=a.a.createRootURLMiddleware(l),a.a.preloadingMiddleware=Object(i.a)(u),a.a.use(a.a.nonceMiddleware),a.a.use(a.a.mediaUploadMiddleware),a.a.use(a.a.rootURLMiddleware),a.a.use(a.a.preloadingMiddleware),t.default=a.a}).call(this,n(15))},633:function(e,t,n){"use strict";n.r(t),function(e){var t=n(1),r=n(148),a=n(5),i=(n(233),n(449)),o=n(136);Object(r.a)((function(){var n=document.getElementById("js-googlesitekit-activation");n&&(Object(a.o)(),Object(a.w)("plugin_setup","plugin_activated"),Object(t.k)(e.createElement(o.a,{dataAPIContext:"Activation"},e.createElement(i.a,null)),n),n.classList.remove("googlesitekit-activation--loading"))}))}.call(this,n(12))},65:function(e,t,n){"use strict";n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return a}));var r=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},a=function(e){return e.replace(/([a-z0-9]{1})([A-Z]{1})/g,"$1_$2").toUpperCase()}},66:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n(10),a=n.n(r),i=n(67),o=n(68);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var u={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,r=s(s({},u),t);return r.referenceSiteURL&&(r.referenceSiteURL=r.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(i.a)(r,n),disableTracking:function(){r.trackingEnabled=!1},isTrackingEnabled:function(){return!!r.trackingEnabled},trackEvent:Object(o.a)(r,n)}}}).call(this,n(15))},67:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var r=n(52),a=n(35);function i(t,n){var i=Object(r.a)(n);return function(){t.trackingEnabled=!0;var n=e.document;if(!n.querySelector("script[".concat(a.b,"]"))){var r=n.createElement("script");r.setAttribute(a.b,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(a.a),n.head.appendChild(r),i("js",new Date),i("config",t.trackingID)}}}}).call(this,n(15))},68:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(4),a=n.n(r),i=n(10),o=n.n(i),c=n(14),s=n.n(c),u=n(52);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(t,n){var r=Object(u.a)(n);return function(){var n=s()(a.a.mark((function n(i,o){var c,s,u,l,d,p,g,h,m=arguments;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(c=m.length>2&&void 0!==m[2]?m[2]:"",s=m.length>3&&void 0!==m[3]?m[3]:"",u=t.isFirstAdmin,l=t.referenceSiteURL,d=t.trackingEnabled,p=t.trackingID,g=t.userIDHash,d){n.next=5;break}return n.abrupt("return");case 5:return h={send_to:p,event_category:i,event_label:c,event_value:s,dimension1:l,dimension2:u?"true":"false",dimension3:g},n.abrupt("return",new Promise((function(t){var n=setTimeout((function(){e.console.warn('Tracking event "'.concat(o,'" (category "').concat(i,'") took too long to fire.')),t()}),1e3);r("event",o,f(f({},h),{},{event_callback:function(){clearTimeout(n),t()}}))})));case 7:case"end":return n.stop()}}),n)})));return function(e,t){return n.apply(this,arguments)}}()}}).call(this,n(15))},70:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r="core",a="modules"},72:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return g})),n.d(t,"d",(function(){return h})),n.d(t,"a",(function(){return m})),n.d(t,"c",(function(){return b}));var r=n(4),a=n.n(r),i=n(14),o=n.n(i);n(71);function c(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var u,l=["sessionStorage","localStorage"],f=[].concat(l),d=function(){var t=o()(a.a.mark((function t(n){var r,i;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,i="__storage_test__",r.setItem(i,i),r.removeItem(i),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==r.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),p=function(){var t=o()(a.a.mark((function t(){var n,r,i;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==u){t.next=25;break}n=c(f),t.prev=4,n.s();case 6:if((r=n.n()).done){t.next=16;break}if(i=r.value,!u){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,d(i);case 12:if(!t.sent){t.next=14;break}u=e[i];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===u&&(u=null);case 25:return t.abrupt("return",u);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),g=function(){var e=o()(a.a.mark((function e(t){var n,r,i,o,c=arguments;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=c.length>1&&void 0!==c[1]?c[1]:null,e.next=3,p();case 3:if(!(r=e.sent)){e.next=10;break}if(!(i=r.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(o=JSON.parse(i)).timestamp||!(null===n||Math.round(Date.now()/1e3)-o.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:o.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),h=function(){var t=o()(a.a.mark((function t(n,r){var i,o,c=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=c.length>2&&void 0!==c[2]?c[2]:void 0,t.next=3,p();case 3:if(!(o=t.sent)){t.next=14;break}return t.prev=5,o.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:i||Math.round(Date.now()/1e3),value:r})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),m=function(){var t=o()(a.a.mark((function t(n){var r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,p();case 2:if(!(r=t.sent)){t.next=13;break}return t.prev=4,r.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),b=function(){var t=o()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,p();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,r=[],i=0;i<n.length;i++)0===(o=n.key(i)).indexOf("googlesitekit_")&&r.push(o.substring("googlesitekit_".length));return t.abrupt("return",r);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:case"end":return t.stop()}}),t,null,[[4,10]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(15))},76:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var r=n(101),a=n.n(r)()(e)}).call(this,n(15))},77:function(e,t,n){"use strict";(function(e){n.d(t,"g",(function(){return g})),n.d(t,"f",(function(){return h})),n.d(t,"c",(function(){return m})),n.d(t,"b",(function(){return k})),n.d(t,"d",(function(){return _})),n.d(t,"e",(function(){return w})),n.d(t,"a",(function(){return E}));var r=n(4),a=n.n(r),i=n(14),o=n.n(i),c=n(16),s=n(13),u=n(5),l=n(157),f=n(17),d=n(29),p=Object(c.c)("googlesitekit.winCallbacks",{}),g=function(){return Object(c.c)("googlesitekit.WinsNotificationsRequest",[])},h=function(){return Object(c.c)("googlesitekit.ModulesNotificationsRequest",[])};function m(){return b.apply(this,arguments)}function b(){return(b=o()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((n=e._googlesitekitLegacyData.setup).isSiteKitConnected&&(n.isAuthenticated||n.isVerified)){t.next=3;break}return t.abrupt("return",0);case 3:return r=0,t.next=6,k();case 6:return(i=t.sent)&&i.total&&(r+=i.total),t.next=10,_();case 10:return(o=t.sent)&&o.total&&(r+=o.total),r=Object(c.c)("googlesitekit.TotalNotifications",r),r=Math.max(0,Math.abs(r)),e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",r),t.abrupt("return",r);case 16:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var v=function(e){return e?e.length?e.filter((function(e){return!Object(d.b)("notification::dismissed::".concat(e.id))})):e:[]},y=function(e){var t=function(e){return Object.keys(e).slice(0,1).map((function(t){return e[t]}))};if(1>=Object.keys(e).length)return e;var n=Object.values(e).filter((function(e){var t=Object(d.b)("notification::displayed::".concat(e[0].id));if(t){var n=new Date(t),r=new Date,a=new Date(Date.UTC(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()));if(n.setHours(0,0,0),a.setHours(0,0,0),n.getTime()===a.getTime())return!0;7<=Object(u.h)(n,a)&&Object(d.a)("notification::displayed::".concat(e[0].id))}return null===t})),r=null,a=[];return 0<Object.keys(n).length?(r=t(n),a[Object.keys(n)[0]]=r):(r=t(e),a[Object.keys(e)[0]]=r)};function k(){return O.apply(this,arguments)}function O(){return(O=o()(a.a.mark((function e(){var t,n,r,i;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={},n=0,e.next=4,h();case 4:return r=e.sent,i=[],r.map(function(){var e=o()(a.a.mark((function e(t){var n;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=new Promise(function(){var e=o()(a.a.mark((function e(n){var r,i;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.identifier,e.t0=v,e.next=4,f.c.get(f.b,r,"notifications",{},!1);case 4:e.t1=e.sent,i=(0,e.t0)(e.t1),n({identifier:r,notifications:i});case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),i.push(n);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),e.next=9,Promise.all(i).then((function(e){e.forEach((function(e){e.notifications.length&&(n+=e.notifications.length,t[e.identifier]=e.notifications)}))}));case 9:return e.abrupt("return",{results:t,total:n});case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function _(){return j.apply(this,arguments)}function j(){return(j=o()(a.a.mark((function e(){var t,n,r,i,c;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={},n=0,e.next=4,g();case 4:return r=e.sent,e.next=7,new l.a(r).get();case 7:return i=e.sent,c=[],r.map(function(){var e=o()(a.a.mark((function e(t){var n;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=new Promise(function(){var e=o()(a.a.mark((function e(n){var r,o,c,u,l;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=t.identifier,o=t.callback||Object(s.camelCase)(r),c=null,u=[],t.withData?(l=i[r]||null,c=p[o](l,r)):c=p[o](r),u=v(u=c?[c]:[]),n({identifier:r,notifications:u});case 8:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),c.push(n);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),e.next=12,Promise.all(c).then((function(e){e.forEach((function(e){e.notifications.length&&(t[e.identifier]=e.notifications)}))}));case 12:return t=y(t),n=t.length||Object.keys(t).length||0,e.abrupt("return",{results:t,total:n});case 15:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var w=function(t){var n=Math.abs(t.count)+1;return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}},E=function(t){var n=Math.max(0,Math.abs(t.count)-1);return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}}}).call(this,n(15))},80:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(0),y=n(28);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var O=function(t){s()(SourceLink,t);var n=k(SourceLink);function SourceLink(){return a()(this,SourceLink),n.apply(this,arguments)}return o()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,r=t.href,a=t.className,i=t.external;return e.createElement("div",{className:b()("googlesitekit-source-link",a)},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(y.a,{key:"link",href:r,external:i,inherit:!0},n)])}}]),SourceLink}(p.a);O.propTypes={name:h.a.string,href:h.a.string,className:h.a.string,external:h.a.bool},O.defaultProps={name:"",href:"",className:"",external:!1},t.a=O}).call(this,n(12))},85:function(e,t,n){"use strict";n.d(t,"a",(function(){return b})),n.d(t,"c",(function(){return y})),n.d(t,"b",(function(){return k}));var r=n(44),a=n.n(r),i=n(10),o=n.n(i),c=n(4),s=n.n(c),u=n(19),l=n.n(u),f=n(11),d=n.n(f),p=n(72);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=d.a.createRegistryControl,b=function(e){var t;l()(e,"storeName is required to create a snapshot store.");var n={},r={deleteSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"DELETE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})),restoreSnapshot:s.a.mark((function e(){var t,n,r,a,i,o,c=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=c.length>0&&void 0!==c[0]?c[0]:{},n=t.clearAfterRestore,r=void 0===n||n,e.next=4,{payload:{},type:"RESTORE_SNAPSHOT"};case 4:if(a=e.sent,i=a.cacheHit,o=a.value,!i){e.next=13;break}return e.next=10,{payload:{snapshot:o},type:"SET_STATE_FROM_SNAPSHOT"};case 10:if(!r){e.next=13;break}return e.next=13,{payload:{},type:"DELETE_SNAPSHOT"};case 13:return e.abrupt("return",i);case 14:case"end":return e.stop()}}),e)})),createSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"CREATE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)}))},i=(t={},o()(t,"DELETE_SNAPSHOT",(function(){return Object(p.a)("datastore::cache::".concat(e))})),o()(t,"CREATE_SNAPSHOT",m((function(t){return function(){return Object(p.d)("datastore::cache::".concat(e),t.stores[e].store.getState())}}))),o()(t,"RESTORE_SNAPSHOT",(function(){return Object(p.b)("datastore::cache::".concat(e),3600)})),t);return{INITIAL_STATE:n,actions:r,controls:i,reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n,t=arguments.length>1?arguments[1]:void 0,r=t.type,i=t.payload;switch(r){case"SET_STATE_FROM_SNAPSHOT":var o=i.snapshot,c=(o.error,a()(o,["error"]));return h({},c);default:return h({},e)}}}},v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Object.values(e.stores).filter((function(e){return Object.keys(e.getActions()).includes("restoreSnapshot")}))},y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Promise.all(v(e).map((function(e){return e.getActions().createSnapshot()})))},k=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Promise.all(v(e).map((function(e){return e.getActions().restoreSnapshot()})))}},91:function(e,t,n){"use strict";var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(8),s=n.n(c),u=n(9),l=n.n(u),f=n(3),d=n.n(f),p=n(83);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var h=function(e){s()(ModuleSettingsWarning,e);var t=g(ModuleSettingsWarning);function ModuleSettingsWarning(){return a()(this,ModuleSettingsWarning),t.apply(this,arguments)}return o()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(n(1).a);t.a=Object(p.a)("googlesitekit.ModuleSettingsWarning")(h)},94:function(e,t,n){"use strict";n.d(t,"a",(function(){return f.c}));var r=n(11),a=n.n(r),i=n(4),o=n.n(i),c=n(10),s=n.n(c),u=n(41),l=n.n(u),f=n(20),d=n(42);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=a.a.createRegistrySelector,m=Object(d.a)({baseName:"getAuthentication",controlCallback:function(){return l.a.get("core","user","authentication",void 0,{useCache:!1})},reducerCallback:function(e,t){return g(g({},e),{},{authentication:t})}}),b={authentication:void 0},v={getAuthentication:o.a.mark((function e(){var t;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.a.commonActions.getRegistry();case 2:if(t=e.sent,(0,t.select)(f.c).getAuthentication()){e.next=7;break}return e.next=7,m.actions.fetchGetAuthentication();case 7:case"end":return e.stop()}}),e)}))},y={getAuthentication:function(e){return e.authentication},hasScope:h((function(e){return function(t,n){var r=e(f.c).getGrantedScopes(t);if(void 0!==r)return r.includes(n)}})),isAuthenticated:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).authenticated}})),getGrantedScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).grantedScopes}})),getRequiredScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).requiredScopes}})),getUnsatisfiedScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).unsatisfiedScopes}})),needsReauthentication:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).needsReauthentication}}))},k=a.a.combineStores(m,{INITIAL_STATE:b,resolvers:v,selectors:y}),O=(k.INITIAL_STATE,k.actions,k.controls,k.reducer,k.resolvers,k.selectors,k),_=n(19),j=n.n(_);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function E(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var D={INITIAL_STATE:{dateRange:"last-28-days"},actions:{setDateRange:function(e){return j()(e,"Date range slug is required."),{type:"SET_DATE_RANGE",payload:{slug:e}}}},controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"SET_DATE_RANGE":return E(E({},e),{},{dateRange:r.slug});default:return E({},e)}},resolvers:{},selectors:{getDateRange:function(e){return e.dateRange}}};function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var R=a.a.createRegistrySelector,N=Object(d.a)({baseName:"disconnect",controlCallback:function(){return l.a.set("core","user","disconnect")},reducerCallback:function(e,t){return x(x({},e),{},{disconnected:t})}}),P={disconnected:void 0},C={disconnect:o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,N.actions.fetchDisconnect();case 2:case"end":return e.stop()}}),e)}))},A={isDoingDisconnect:R((function(e){return function(){return e(f.c).isFetchingDisconnect()}}))},L=a.a.combineStores(N,{INITIAL_STATE:P,actions:C,selectors:A}),I=(L.INITIAL_STATE,L.actions,L.controls,L.reducer,L.resolvers,L.selectors,L);function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var M={INITIAL_STATE:{error:void 0},actions:{},controls:{},reducer:function(e){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e)},resolvers:{},selectors:{getError:function(e){return e.error}}},U=n(110),q=Object(U.a)("core","user","notifications",{server:!1}),F=n(121),H=n(122),G=a.a.combineStores(a.a.commonStore,O,D,I,M,q,F.a,H.a);G.INITIAL_STATE,G.actions,G.controls,G.reducer,G.resolvers,G.selectors;a.a.registerStore(f.c,G)},95:function(e,t,n){"use strict";(function(e,r){var a=n(38),i=n.n(a),o=(n(1),n(146)),c=n.n(o),s=n(0),u=n(11),l=n.n(u),f=n(37),d=n(5),p=n(20),g=l.a.useSelect,h={siteverification:"site-verification",webmasters:"search-console"};t.a=function DashboardAuthAlert(){var t,n,a,o,u,l=g((function(e){return e(p.c).getUnsatisfiedScopes()})),m=g((function(t){return t(p.c).getConnectURL({redirectURL:e.location.href})}));if(void 0===l||void 0===m)return null;switch(l.some((function(e){return!e.match(/^https:\/\/www.googleapis.com\/auth\//)}))?t="generic":(a=l,o=Object(d.j)(),t=(n=a.map((function(e){return e.match(/^https:\/\/www.googleapis.com\/auth\/([a-z]+)/)})).map((function(e){var t=i()(e,2)[1];return h[t]||t})).map((function(e){var t;return(null===(t=o[e])||void 0===t?void 0:t.name)||!1}))).some((function(e){return!1===e}))?"generic":1<(n=c()(n)).length?"multiple":"single"),t){case"multiple":
18
  /* translators: used between list items, there is a space after the comma. */
19
  var b=Object(s.__)(", ","google-site-kit");u=Object(s.sprintf)(
20
  /* translators: %s: List of product names */
21
  Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for: %s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n.join(b));break;case"single":u=Object(s.sprintf)(
22
  /* translators: %1$s: Product name */
23
- Object(s.__)("Site Kit can’t access the relevant data from %1$s because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for %1$s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n[0]);break;case"generic":u=Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup – make sure to approve all permissions at the authentication stage.","google-site-kit")}return r.createElement(f.a,{id:"authentication error",title:Object(s.__)("Site Kit can’t access necessary data","google-site-kit"),description:u,format:"small",type:"win-error",isDismissable:!1,ctaLink:m,ctaLabel:Object(s.__)("Redo setup","google-site-kit")})}}).call(this,n(15),n(12))},97:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var r=n(40),a=n(29),i=function(t,n,i){var o=Object(a.c)(t,n,i);Object(a.d)(),Object.keys(e._googlesitekitLegacyData.admin.datacache).forEach((function(t){0!==t.indexOf(o+"::")&&t!==o||delete e._googlesitekitLegacyData.admin.datacache[t]})),Object.keys(Object(r.a)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(o,"::"))&&e!=="googlesitekit_".concat(o)||Object(r.a)().removeItem(e)}))}}).call(this,n(15))}});
1
+ !function(e){function t(t){for(var r,o,c=t[0],s=t[1],l=t[2],f=0,d=[];f<c.length;f++)o=c[f],Object.prototype.hasOwnProperty.call(a,o)&&a[o]&&d.push(a[o][0]),a[o]=0;for(r in s)Object.prototype.hasOwnProperty.call(s,r)&&(e[r]=s[r]);for(u&&u(t);d.length;)d.shift()();return i.push.apply(i,l||[]),n()}function n(){for(var e,t=0;t<i.length;t++){for(var n=i[t],r=!0,o=1;o<n.length;o++){var c=n[o];0!==a[c]&&(r=!1)}r&&(i.splice(t--,1),e=__webpack_require__(__webpack_require__.s=n[0]))}return e}var r={},a={5:0},i=[];function __webpack_require__(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,__webpack_require__),n.l=!0,n.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)__webpack_require__.d(n,r,function(t){return e[t]}.bind(null,r));return n},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var o=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],c=o.push.bind(o);o.push=t,o=o.slice();for(var s=0;s<o.length;s++)t(o[s]);var u=c;i.push([630,0]),n()}({1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return o})),n.d(t,"a",(function(){return c})),n.d(t,"e",(function(){return u})),n.d(t,"f",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"h",(function(){return p})),n.d(t,"b",(function(){return m})),n.d(t,"i",(function(){return v})),n.d(t,"j",(function(){return y})),n.d(t,"k",(function(){return j})),n.d(t,"c",(function(){return D})),n.d(t,"l",(function(){return x})),n.d(t,"m",(function(){return P})),n.d(t,"n",(function(){return C})),n.d(t,"o",(function(){return L})),n.d(t,"p",(function(){return I})),n.d(t,"q",(function(){return T})),n.d(t,"r",(function(){return M})),n.d(t,"s",(function(){return U}));var r=n(98);void 0===e.googlesitekit&&(e.googlesitekit={});var a=e.googlesitekit._element||r,i=a.Children,o=a.cloneElement,c=a.Component,s=a.concatChildren,u=a.createContext,l=a.createElement,f=a.createInterpolateElement,d=a.createPortal,p=a.createRef,g=a.findDOMNode,h=a.forwardRef,m=a.Fragment,b=a.isEmptyElement,v=a.isValidElement,y=a.lazy,k=a.memo,_=a.Platform,O=a.RawHTML,j=a.render,w=a.renderToString,E=a.StrictMode,D=a.Suspense,S=a.switchChildrenNodeName,R=a.unmountComponentAtNode,x=a.useCallback,P=a.useContext,N=a.useDebugValue,C=a.useEffect,A=a.useImperativeHandle,L=a.useLayoutEffect,I=a.useMemo,T=a.useReducer,M=a.useRef,U=a.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:i,cloneElement:o,Component:c,concatChildren:s,createContext:u,createElement:l,createInterpolateElement:f,createPortal:d,createRef:p,findDOMNode:g,forwardRef:h,Fragment:m,isEmptyElement:b,isValidElement:v,lazy:y,memo:k,Platform:_,RawHTML:O,render:j,renderToString:w,StrictMode:E,Suspense:D,switchChildrenNodeName:S,unmountComponentAtNode:R,useCallback:x,useContext:P,useDebugValue:N,useEffect:C,useImperativeHandle:A,useLayoutEffect:L,useMemo:I,useReducer:T,useRef:M,useState:U})}).call(this,n(13))},109:function(e,t,n){"use strict";var r=n(100);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(r.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,a){if(n)return a(e);setTimeout((function(){n=!0}),1e3);var i=e.parse,o=void 0===i||i,c=e.path;if("string"==typeof e.path){var s,u=(null===(s=e.method)||void 0===s?void 0:s.toUpperCase())||"GET",l=Object(r.getStablePath)(c);if(o&&"GET"===u&&t[l]){var f=Promise.resolve(t[l].body);return delete t[l],f}if("OPTIONS"===u&&t[u]&&t[u][l]){var d=Promise.resolve(t[u][l]);return delete t[u][l],d}}return a(e)}}},110:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(38);function h(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var m=function(t){s()(GenericError,t);var n=h(GenericError);function GenericError(){return a()(this,GenericError),n.apply(this,arguments)}return o()(GenericError,[{key:"render",value:function(){return e.createElement(g.a,this.props)}}]),GenericError}(p.a);t.a=m}).call(this,n(12))},111:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(213),b=n.n(m),v=n(18),y=n.n(v),k=n(168),_=n(0),O=n(47),j=n(28),w=n(44);function E(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var D=function(t){s()(Dialog,t);var n=E(Dialog);function Dialog(){var e;return a()(this,Dialog),(e=n.call(this)).state={attributes:[Object(_.__)("Audience overview","google-site-kit"),Object(_.__)("Top pages","google-site-kit"),Object(_.__)("Top acquisition channels","google-site-kit"),Object(_.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(p.h)(),e}return o()(Dialog,[{key:"componentDidMount",value:function(){new w.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,r=t.handleDialog,a=t.title,i=t.provides,o=t.handleConfirm,c=t.subtitle,s=t.confirmButton,u=t.dependentModules,l=t.instanceId,f=t.danger,d="googlesitekit-dialog-label-".concat(l),p="googlesitekit-dialog-description-".concat(l),g=!(!i||!i.length);return e.createElement("div",{ref:this.dialogRef,className:y()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":a?d:void 0,"aria-describedby":g?p:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(b.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},a&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},a),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),g&&e.createElement("section",{id:p,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},i.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),u&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(_.__)("Note: ","google-site-kit")),u),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(O.a,{onClick:o,danger:f},s||Object(_.__)("Disconnect","google-site-kit")),e.createElement(j.a,{className:"mdc-dialog__cancel-button",onClick:function(){return r()},inherit:!0},Object(_.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(p.a);D.propTypes={dialogActive:h.a.bool,handleDialog:h.a.func,handleConfirm:h.a.func.isRequired,title:h.a.string,description:h.a.string,confirmButton:h.a.string,danger:h.a.bool},D.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null,danger:!1},t.a=Object(k.a)(D)}).call(this,n(12))},112:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return m}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(19),s=n.n(c),u=n(41),l=n.n(u),f=n(8),d=n.n(f),p=n(43);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=function(t,n,r){var i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},c=i.client,u=void 0===c||c,f=i.server,g=void 0===f||f,m=i.storeName,b=void 0===m?void 0:m;s()(t,"type is required."),s()(n,"identifier is required."),s()(r,"datapoint is required.");var v=b||"".concat(t,"/").concat(n),y={serverNotifications:g?void 0:{},clientNotifications:u?void 0:{}},k=Object(p.a)({baseName:"getNotifications",controlCallback:function(){return l.a.get(t,n,r)},reducerCallback:function(e,t){return h(h({},e),{},{serverNotifications:t.reduce((function(e,t){return h(h({},e),{},o()({},t.id,t))}),{})})}}),_={addNotification:function(e){return s()(e,"notification is required."),{payload:{notification:e},type:"ADD_NOTIFICATION"}},removeNotification:function(e){return s()(e,"id is required."),{payload:{id:e},type:"REMOVE_NOTIFICATION"}}},O={},j=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:y,n=arguments.length>1?arguments[1]:void 0,r=n.type,a=n.payload;switch(r){case"ADD_NOTIFICATION":var i=a.notification;return h(h({},t),{},{clientNotifications:h(h({},t.clientNotifications||{}),{},o()({},i.id,i))});case"REMOVE_NOTIFICATION":var c=a.id;if(void 0===t.clientNotifications||void 0===t.clientNotifications[c])return void 0!==t.serverNotifications&&void 0!==t.serverNotifications[c]&&e.console.warn('Cannot remove server-side notification with ID "'.concat(c,'"; this may be changed in a future release.')),h({},t);var s=h({},t.clientNotifications);return delete s[c],h(h({},t),{},{clientNotifications:s});default:return h({},t)}},w={getNotifications:a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,k.actions.fetchGetNotifications();case 2:case"end":return e.stop()}}),e)}))};g||delete w.getNotifications;var E={getNotifications:function(e){var t=e.serverNotifications,n=e.clientNotifications;return void 0===t&&void 0===n?t:Object.values(h(h({},t||{}),n||{}))}},D=d.a.combineStores(k,{INITIAL_STATE:y,actions:_,controls:O,reducer:j,resolvers:w,selectors:E});return h(h({},D),{},{STORE_NAME:v})}}).call(this,n(13))},116:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var h=function(e){s()(Modal,e);var t=g(Modal);function Modal(e){var n;return a()(this,Modal),(n=t.call(this,e)).el=document.createElement("div"),n.root=document.querySelector(".googlesitekit-plugin")||document.body,n}return o()(Modal,[{key:"componentDidMount",value:function(){this.root.appendChild(this.el)}},{key:"componentWillUnmount",value:function(){this.root.removeChild(this.el)}},{key:"render",value:function(){return Object(p.g)(this.props.children,this.el)}}]),Modal}(p.a)},117:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),u=n(17);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var d=function(){var t=s()(a.a.mark((function t(){var n,r,i,o,c,s;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,u.c.get(u.a,"user","authentication",{timestamp:Date.now()});case 3:n=t.sent,r=n.authenticated,i=n.requiredScopes,o=n.grantedScopes,c=n.unsatisfiedScopes,s=void 0===c?[]:c,e._googlesitekitLegacyData.setup=f(f({},e._googlesitekitLegacyData.setup||{}),{},{isAuthenticated:r,requiredScopes:i,grantedScopes:o,unsatisfiedScopes:s,needReauthenticate:0<s.length}),t.next=14;break;case 12:t.prev=12,t.t0=t.catch(0);case 14:case"end":return t.stop()}}),t,null,[[0,12]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(13))},119:function(e,t,n){"use strict";n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return p})),n.d(t,"b",(function(){return h}));var r=n(3),a=n.n(r),i=n(14),o=n.n(i),c=n(17);function s(){return u.apply(this,arguments)}function u(){return(u=o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,c.c.get(c.a,"site","notifications",{},!1);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var l=n(50);function f(e,t){return d.apply(this,arguments)}function d(){return(d=o()(a.a.mark((function e(t,n){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return c.c.invalidateCacheGroup(c.a,"site","notifications"),e.next=3,Object(l.c)("site_notifications",n,t);case 3:return e.next=5,c.c.set(c.a,"site","mark-notification",{notificationID:t,notificationState:n});case 5:return e.abrupt("return",e.sent);case 6:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function p(e){return g.apply(this,arguments)}function g(){return(g=o()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,f(t,"accepted");case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function h(e){return m.apply(this,arguments)}function m(){return(m=o()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,f(t,"dismissed");case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})))).apply(this,arguments)}},12:function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"Children",(function(){return l})),n.d(t,"createRef",(function(){return f})),n.d(t,"Component",(function(){return d})),n.d(t,"PureComponent",(function(){return p})),n.d(t,"createContext",(function(){return g})),n.d(t,"forwardRef",(function(){return h})),n.d(t,"lazy",(function(){return m})),n.d(t,"memo",(function(){return b})),n.d(t,"useCallback",(function(){return v})),n.d(t,"useContext",(function(){return y})),n.d(t,"useEffect",(function(){return k})),n.d(t,"useImperativeHandle",(function(){return _})),n.d(t,"useDebugValue",(function(){return O})),n.d(t,"useLayoutEffect",(function(){return j})),n.d(t,"useMemo",(function(){return w})),n.d(t,"useReducer",(function(){return E})),n.d(t,"useRef",(function(){return D})),n.d(t,"useState",(function(){return S})),n.d(t,"Fragment",(function(){return R})),n.d(t,"Profiler",(function(){return x})),n.d(t,"StrictMode",(function(){return P})),n.d(t,"Suspense",(function(){return N})),n.d(t,"createElement",(function(){return C})),n.d(t,"cloneElement",(function(){return A})),n.d(t,"createFactory",(function(){return L})),n.d(t,"isValidElement",(function(){return I})),n.d(t,"version",(function(){return T})),n.d(t,"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",(function(){return M}));var r=n(11),a=n.n(r),i=n(59),o=n.n(i);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}void 0===e.googlesitekit&&(e.googlesitekit={});var s=e.googlesitekit._react||function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({default:o.a},i),u=s.default,l=s.Children,f=s.createRef,d=s.Component,p=s.PureComponent,g=s.createContext,h=s.forwardRef,m=s.lazy,b=s.memo,v=s.useCallback,y=s.useContext,k=s.useEffect,_=s.useImperativeHandle,O=s.useDebugValue,j=s.useLayoutEffect,w=s.useMemo,E=s.useReducer,D=s.useRef,S=s.useState,R=s.Fragment,x=s.Profiler,P=s.StrictMode,N=s.Suspense,C=s.createElement,A=s.cloneElement,L=s.createFactory,I=s.isValidElement,T=s.version,M=s.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;void 0===e.googlesitekit._react&&(e.googlesitekit._react={default:o.a,Children:l,createRef:f,Component:d,PureComponent:p,createContext:g,forwardRef:h,lazy:m,memo:b,useCallback:v,useContext:y,useEffect:k,useImperativeHandle:_,useDebugValue:O,useLayoutEffect:j,useMemo:w,useReducer:E,useRef:D,useState:S,Fragment:R,Profiler:x,StrictMode:P,Suspense:N,createElement:C,cloneElement:A,createFactory:L,isValidElement:I,version:T,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:M}),t.default=u}.call(this,n(13))},120:function(e,t,n){"use strict";(function(e){n(1);t.a=function Warning(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#F9BB2D",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"warning-title warning-desc"},e.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),e.createElement("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-2h2v2zm0-4h-2V7h2v6z"}))}}).call(this,n(12))},122:function(e,t,n){"use strict";(function(e){var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(19),s=n.n(c),u=n(8),l=n.n(u),f=n(20);function d(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function p(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?d(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):d(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var g=l.a.createRegistrySelector,h={permissionError:null,capabilities:void 0},m={clearPermissionScopeError:function(){return{payload:{},type:"CLEAR_PERMISSION_SCOPE_ERROR"}},setPermissionScopeError:function(e){return s()(e,"permissionError is required."),{payload:{permissionError:e},type:"SET_PERMISSION_SCOPE_ERROR"}},receiveCapabilities:function(e){return{type:"RECEIVE_CAPABILITIES",payload:{capabilities:e}}}},b={getCapabilities:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,l.a.commonActions.getRegistry();case 2:if(!t.sent.select(f.c).getCapabilities()){t.next=5;break}return t.abrupt("return");case 5:return(null===(n=e._googlesitekitUserData)||void 0===n?void 0:n.permissions)||e.console.error("Could not load core/user permissions."),t.next=8,m.receiveCapabilities(null===(r=e._googlesitekitUserData)||void 0===r?void 0:r.permissions);case 8:case"end":return t.stop()}}),t)}))},v={getPermissionScopeError:function(e){return e.permissionError},getCapabilities:function(e){return e.capabilities},hasCapability:g((function(e){return function(t,n){var r=e(f.c).getCapabilities();if(r)return!!r[n]}}))};t.a={INITIAL_STATE:h,actions:m,controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"CLEAR_PERMISSION_SCOPE_ERROR":return p(p({},e),{},{permissionError:null});case"SET_PERMISSION_SCOPE_ERROR":var a=r.permissionError;return p(p({},e),{},{permissionError:a});case"RECEIVE_CAPABILITIES":var i=r.capabilities;return p(p({},e),{},{capabilities:i});default:return p({},e)}},resolvers:b,selectors:v}}).call(this,n(13))},123:function(e,t,n){"use strict";(function(e){var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(19),s=n.n(c),u=n(48),l=n(8),f=n.n(l),d=n(20);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=f.a.createRegistrySelector,m={connectURL:void 0,user:void 0,verified:void 0},b={receiveConnectURL:function(e){return s()(e,"connectURL is required."),{payload:{connectURL:e},type:"RECEIVE_CONNECT_URL"}},receiveUserInfo:function(e){return s()(e,"userInfo is required."),{payload:{user:e},type:"RECEIVE_USER_INFO"}},receiveUserIsVerified:function(e){return s()(void 0!==e,"userIsVerified is required."),{payload:{verified:e},type:"RECEIVE_USER_IS_VERIFIED"}}},v={getConnectURL:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,!(0,n.select)(d.c).getConnectURL()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.connectURL,t.next=12,b.receiveConnectURL(r);case 12:case"end":return t.stop()}}),t)})),getUser:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(d.c).getUser()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.user,t.next=12,b.receiveUserInfo(r);case 12:case"end":return t.stop()}}),t)})),isVerified:a.a.mark((function t(){var n,r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.commonActions.getRegistry();case 2:if(n=t.sent,void 0===(0,n.select)(d.c).isVerified()){t.next=6;break}return t.abrupt("return");case 6:if(e._googlesitekitUserData){t.next=9;break}return e.console.error("Could not load core/user info."),t.abrupt("return");case 9:return r=e._googlesitekitUserData.verified,t.next=12,b.receiveUserIsVerified(r);case 12:case"end":return t.stop()}}),t)}))},y={getUser:function(e){return e.user},getConnectURL:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.additionalScopes,r=void 0===n?[]:n,a=t.redirectURL,i=void 0===a?void 0:a,o=e.connectURL,c={redirect:i};if(void 0!==o)return(null==r?void 0:r.length)?Object(u.a)(o,g(g({},c),{},{additional_scopes:r})):Object(u.a)(o,c)},getID:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.id:t}})),getName:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.name:t}})),getEmail:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.email:t}})),getPicture:h((function(e){return function(){var t=e(d.c).getUser();return void 0!==t?t.picture:t}})),isVerified:function(e){return e.verified}};t.a={INITIAL_STATE:m,actions:b,controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"RECEIVE_CONNECT_URL":var a=r.connectURL;return g(g({},e),{},{connectURL:a});case"RECEIVE_USER_INFO":var i=r.user;return g(g({},e),{},{user:i});case"RECEIVE_USER_IS_VERIFIED":var o=r.verified;return g(g({},e),{},{verified:o});default:return g({},e)}},resolvers:v,selectors:y}}).call(this,n(13))},124:function(e,t,n){"use strict";(function(e){n(1);var r=n(2),a=n.n(r),i=n(18),o=n.n(i);function ChangeArrow(t){var n=t.direction,r=t.invertColor;return e.createElement("svg",{className:o()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(n),{"googlesitekit-change-arrow--inverted-color":r}),width:"9",height:"9",viewBox:"0 0 10 10",fill:"none",xmlns:"http://www.w3.org/2000/svg"},e.createElement("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:a.a.string,invertColor:a.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,n(12))},125:function(e,t,n){"use strict";(function(e){n(1);t.a=function Error(){return e.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"#EA4336",width:"34",height:"34",viewBox:"0 0 24 24","aria-labelledby":"error-title error-desc"},e.createElement("path",{d:"M4.47 21h15.06c1.54 0 2.5-1.67 1.73-3L13.73 4.99c-.77-1.33-2.69-1.33-3.46 0L2.74 18c-.77 1.33.19 3 1.73 3zM12 14c-.55 0-1-.45-1-1v-2c0-.55.45-1 1-1s1 .45 1 1v2c0 .55-.45 1-1 1zm1 4h-2v-2h2v2z"}))}}).call(this,n(12))},126:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),a=n(38);t.a=function DashboardPermissionAlert(){return e.createElement(a.a,{id:"permission error",title:Object(r.__)("Permissions issue accessing data","google-site-kit"),description:Object(r.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,n(12))},138:function(e,t,n){"use strict";(function(e){n(1);var r=n(0),a=n(33);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(a.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(a.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(r.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,n(12))},139:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return Root}));n(1);var r=n(2),a=n.n(r),i=n(8),o=n.n(i),c=n(140),s=n(141),u=n(142),l=n(143);function Root(t){var n=t.children,r=t.registry,a=t.dataAPIContext,i=t.dataAPIModuleArgs;return e.createElement(o.a.RegistryProvider,{value:r},e.createElement(c.a,null,e.createElement(u.a,null,n,a&&e.createElement(l.a,{context:a,args:i})),e.createElement(s.a,null)))}Root.propTypes={children:a.a.node.isRequired,registry:a.a.object,dataAPIContext:a.a.string,dataAPIModuleArgs:a.a.object},Root.defaultProps={registry:o.a}}).call(this,n(12))},140:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(9),u=n.n(s),l=n(10),f=n.n(l),d=n(4),p=n.n(d),g=n(1),h=n(2),m=n.n(h),b=n(0),v=n(38);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var k=function(t){u()(ErrorHandler,t);var n=y(ErrorHandler);function ErrorHandler(e){var t;return i()(this,ErrorHandler),(t=n.call(this,e)).state={error:null,info:null},t}return c()(ErrorHandler,[{key:"componentDidCatch",value:function(t,n){e.console.error("Caught an error:",t,n),this.setState({error:t,info:n})}},{key:"render",value:function(){var e=this.props.children,t=this.state,n=t.error,a=t.info;return n?r.createElement(v.a,{id:"googlesitekit-error",title:Object(b.__)("Site Kit encountered an error","google-site-kit"),description:r.createElement("code",null,n.message),isDismissable:!1,format:"small",type:"win-error"},r.createElement("pre",null,a.componentStack)):e}}]),ErrorHandler}(g.a);k.defaultProps={},k.propTypes={children:m.a.node.isRequired},t.a=k}).call(this,n(13),n(12))},141:function(e,t,n){"use strict";(function(e,r){var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(1),u=n(0),l=n(8),f=n.n(l),d=n(96),p=n(111),g=n(116),h=n(87),m=f.a.useSelect,b=f.a.useDispatch,v=f.a.useRegistry;t.a=function PermissionsModal(){var t,n,a,o=v(),l=m((function(e){return e(d.a).getPermissionScopeError()})),f=m((function(t){var n;return t(d.a).getConnectURL({additionalScopes:null==l||null===(n=l.data)||void 0===n?void 0:n.scopes,redirectURL:e.location.href})})),y=b(d.a).clearPermissionScopeError,k=Object(s.l)((function(){y()}),[y]),_=Object(s.l)(c()(i.a.mark((function t(){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,Object(h.c)(o);case 2:e.location.assign(f);case 3:case"end":return t.stop()}}),t)}))),[o,f]);return Object(s.n)((function(){(function(){var e=c()(i.a.mark((function e(){var t,n,r;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!(null==l||null===(t=l.data)||void 0===t?void 0:t.skipModal)||!(null==l||null===(n=l.data)||void 0===n||null===(r=n.scopes)||void 0===r?void 0:r.length)){e.next=3;break}return e.next=3,_();case 3:case"end":return e.stop()}}),e)})));return function(){return e.apply(this,arguments)}})()()}),[_,l]),l?(null==l||null===(t=l.data)||void 0===t||null===(n=t.scopes)||void 0===n?void 0:n.length)?(null==l||null===(a=l.data)||void 0===a?void 0:a.skipModal)?null:r.createElement(g.a,null,r.createElement(p.a,{title:Object(u.__)("Additional Permissions Required","google-site-kit"),subtitle:l.message,confirmButton:Object(u.__)("Proceed","google-site-kit"),dialogActive:!0,handleConfirm:_,handleDialog:k})):(e.console.warn("permissionsError lacks scopes array to use for redirect, so not showing the PermissionsModal. permissionsError was:",l),null):null}}).call(this,n(13),n(12))},142:function(e,t,n){"use strict";var r=n(3),a=n.n(r),i=n(14),o=n.n(i),c=n(35),s=n.n(c),u=n(1),l=n(8),f=n.n(l),d=n(87),p=f.a.useRegistry;t.a=function RestoreSnapshots(e){var t=e.children,n=p(),r=Object(u.s)(!1),i=s()(r,2),c=i[0],l=i[1];return Object(u.n)((function(){c||o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(d.b)(n);case 2:l(!0);case 3:case"end":return e.stop()}}),e)})))()}),[n,c]),c?t:null}},143:function(e,t,n){"use strict";n.d(t,"a",(function(){return CollectModuleData}));var r=n(1),a=n(16),i=(n(17),n(8)),o=n.n(i),c=n(20),s=o.a.useSelect;function CollectModuleData(e){var t=e.context,n=e.args,i=s((function(e){return e(c.c).getDateRange()}));return Object(r.n)((function(){return function(){return Object(a.d)("googlesitekit.moduleDataReset")}}),[i]),Object(r.n)((function(){Object(a.d)("googlesitekit.moduleLoaded",t,n)}),[t,n,i]),null}},157:function(e,t,n){"use strict";(function(e){var r=n(3),a=n.n(r),i=n(14),o=n.n(i),c=n(6),s=n.n(c),u=n(7),l=n.n(u),f=n(9),d=n.n(f),p=n(10),g=n.n(p),h=n(4),m=n.n(h),b=n(1),v=n(0),y=n(119),k=n(38);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=m()(e);if(t){var a=m()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return g()(this,n)}}var O=function(t){d()(DashboardCoreSiteAlerts,t);var n,r=_(DashboardCoreSiteAlerts);function DashboardCoreSiteAlerts(e){var t;return s()(this,DashboardCoreSiteAlerts),(t=r.call(this,e)).state={notifications:!1},t}return l()(DashboardCoreSiteAlerts,[{key:"componentDidMount",value:(n=o()(a.a.mark((function e(){var t;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,Object(y.c)();case 3:t=e.sent,this.setState({notifications:t}),e.next=10;break;case 7:e.prev=7,e.t0=e.catch(0),console.warn("Error caught while fetching notifications",e.t0);case 10:case"end":return e.stop()}}),e,this,[[0,7]])}))),function(){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state.notifications;return Array.isArray(t)?t.map((function(t){return e.createElement(k.a,{key:t.id,id:t.id,title:t.title||"",description:t.content||"",learnMoreURL:t.learnMoreURL||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaURL||"",ctaLabel:t.ctaLabel||"",ctaTarget:t.ctaTarget||"",dismiss:t.dismissLabel||Object(v.__)("OK, Got it!","google-site-kit"),isDismissable:t.dismissible,onCTAClick:o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(y.a)(t.id);case 2:case"end":return e.stop()}}),e)}))),onDismiss:o()(a.a.mark((function e(){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,Object(y.b)(t.id);case 2:case"end":return e.stop()}}),e)})))})})):null}}]),DashboardCoreSiteAlerts}(b.a);t.a=O}).call(this,n(12))},158:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(9),u=n.n(s),l=n(10),f=n.n(l),d=n(4),p=n.n(d),g=n(1),h=n(0),m=n(16),b=n(5),v=n(38),y=n(159);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var _=function(t){u()(DashboardSetupAlerts,t);var n=k(DashboardSetupAlerts);function DashboardSetupAlerts(){return i()(this,DashboardSetupAlerts),n.apply(this,arguments)}return c()(DashboardSetupAlerts,[{key:"render",value:function(){var t=Object(b.k)("notification");if(!t||""===t)return null;var n={id:"connected-successfully",setupTitle:Object(h.__)("Site Kit","google-site-kit"),description:Object(h.__)("Now you’ll be able to see how your site is doing in search. To get even more detailed stats, activate more modules. Here are our recommendations for what to include in your Site Kit:","google-site-kit"),learnMore:{label:"",url:"",description:""}},a=e._googlesitekitLegacyData.permissions.canManageOptions;switch(t){case"authentication_success":if(!a)return null;var i=Object(b.j)(),o=Object(b.k)("slug");return o&&i[o]&&!i[o].active?null:(o&&i[o]&&(n.id="".concat(n.id,"-").concat(o),n.setupTitle=i[o].name,n.description=Object(h.__)("Here are some other services you can connect to see even more stats:","google-site-kit"),n=Object(m.c)("googlesitekit.SetupWinNotification-".concat(o),n)),r.createElement(g.b,null,r.createElement(v.a,{id:n.id
2
+ /* translators: %s: the name of a module that setup was completed for */,title:Object(h.sprintf)(Object(h.__)("Congrats on completing the setup for %s!","google-site-kit"),n.setupTitle),description:n.description,handleDismiss:function(){},winImage:e._googlesitekitLegacyData.admin.assetsRoot+"images/rocket.png",dismiss:Object(h.__)("OK, Got it!","google-site-kit"),format:"large",type:"win-success",learnMoreLabel:n.learnMore.label,learnMoreDescription:n.learnMore.description,learnMoreURL:n.learnMore.url,anchorLink:"pagespeed-insights"===o?"#googlesitekit-pagespeed-header":"",anchorLinkLabel:"pagespeed-insights"===o?Object(h.__)("Jump to the bottom of the dashboard to see how fast your home page is.","google-site-kit"):""},r.createElement(y.a,null))));case"authentication_failure":return r.createElement(g.b,null,r.createElement(v.a,{id:"connection error",title:Object(h.__)("There was a problem connecting to Google!","google-site-kit"),description:"",handleDismiss:function(){},format:"small",type:"win-error"}))}}}]),DashboardSetupAlerts}(g.a);t.a=_}).call(this,n(13),n(12))},159:function(e,t,n){"use strict";(function(e,r){var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(6),u=n.n(s),l=n(7),f=n.n(l),d=n(23),p=n.n(d),g=n(9),h=n.n(g),m=n(10),b=n.n(m),v=n(4),y=n.n(v),k=n(1),_=n(15),O=n(18),j=n.n(O),w=n(0),E=n(5),D=n(117),S=n(28),R=n(17),x=n(110),P=n(93);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=y()(e);if(t){var a=y()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return b()(this,n)}}var C=function(t){h()(ModulesList,t);var n,a=N(ModulesList);function ModulesList(e){var t;return u()(this,ModulesList),(t=a.call(this,e)).setupModuleClick=t.setupModuleClick.bind(p()(t)),t}return f()(ModulesList,[{key:"setupModuleClick",value:(n=c()(i.a.mark((function t(n){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,this.setState({isSaving:!0}),t.next=4,Object(E.b)(R.c,n,!0);case 4:return t.next=6,Object(D.a)();case 6:e.location=Object(E.l)(n,!0),t.next=13;break;case 9:t.prev=9,t.t0=t.catch(0),Object(E.u)(x.a,{id:"setup-module-error",title:Object(w.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"}),this.setState({isSaving:!1});case 13:case"end":return t.stop()}}),t,this,[[0,9]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var e=this,t=Object(E.j)(),n=Object.values(t).filter((function(e){return!e.internal})),a=n.filter((function(e){return e.active&&e.setupComplete})).reduce((function(e,t){return e[t.slug]=t.name,e}),{}),i=n.filter((function(e){return 0===e.required.length})).sort((function(e,t){return e.sort-t.sort}));return r.createElement("div",{className:"googlesitekit-modules-list"},Object(_.map)(i,(function(t){var n=!1,i="",o=t.slug,c=t.name,s=t.setupComplete,u=t.required;return 0<u.length&&u.forEach((function(e){a[e]&&(n=!0,i=a[e])})),r.createElement("div",{key:o,className:j()("googlesitekit-modules-list__module","googlesitekit-modules-list__module--".concat(o),{"googlesitekit-modules-list__module--disabled":n})},r.createElement("div",{className:"googlesitekit-settings-connect-module__wrapper"},r.createElement("div",{className:"googlesitekit-settings-connect-module__logo"},Object(E.p)(o,n)),r.createElement("h3",{className:"googlesitekit-settings-connect-module__title"},c)),r.createElement(P.a,{slug:o,context:"modules-list"}),s&&r.createElement("span",{className:"googlesitekit-settings-module__status"},r.createElement("span",{className:"googlesitekit-settings-module__status-icon googlesitekit-settings-module__status-icon--connected"},r.createElement("span",{className:"screen-reader-text"},Object(w.__)("Connected","google-site-kit"))),Object(w.__)("Connected","google-site-kit")),!s&&!n&&r.createElement(S.a,{arrow:!0,small:!0,inherit:!0,onClick:function(){e.setupModuleClick(o)}}," ",Object(w.__)("Connect Service","google-site-kit")),!s&&n&&r.createElement(S.a,{disabled:!0,small:!0,inherit:!0},
3
  /* translators: %s: parent module name */
4
+ Object(w.sprintf)(Object(w.__)("Enable %s to start setup","google-site-kit"),i)))})))}}]),ModulesList}(k.a);t.a=C}).call(this,n(13),n(12))},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return o})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"d",(function(){return p})),n.d(t,"c",(function(){return g}));var r=n(94);void 0===e.googlesitekit&&(e.googlesitekit={});var a=e.googlesitekit._hooks||r,i=a.addAction,o=a.addFilter,c=a.removeAction,s=a.removeFilter,u=a.hasAction,l=a.hasFilter,f=a.removeAllActions,d=a.removeAllFilters,p=a.doAction,g=a.applyFilters,h=a.currentAction,m=a.currentFilter,b=a.doingAction,v=a.doingFilter,y=a.didAction,k=a.didFilter,_=a.actions,O=a.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:i,addFilter:o,removeAction:c,removeFilter:s,hasAction:u,hasFilter:l,removeAllActions:f,removeAllFilters:d,doAction:p,applyFilters:g,currentAction:h,currentFilter:m,doingAction:b,doingFilter:v,didAction:y,didFilter:k,actions:_,filters:O})}).call(this,n(13))},160:function(e,t,n){"use strict";(function(e,r){var a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=n(9),u=n.n(s),l=n(10),f=n.n(l),d=n(4),p=n.n(d),g=n(1),h=n(15),m=n(0),b=n(5),v=n(38),y=n(79);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=p()(e);if(t){var a=p()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return f()(this,n)}}var _=function(t){u()(DashboardModulesAlerts,t);var n=k(DashboardModulesAlerts);function DashboardModulesAlerts(e){var t;return i()(this,DashboardModulesAlerts),(t=n.call(this,e)).state={data:!1},t}return c()(DashboardModulesAlerts,[{key:"componentDidMount",value:function(){var e=this,t=Object(y.f)();t&&Object(y.b)(t).then((function(t){e.setState({data:t.results})}))}},{key:"render",value:function(){var t=this.state.data;if(0===Object.keys(t).length)return null;var n=Object(b.j)(),a=[];return Object.keys(t).forEach((function(i){Object(h.each)(t[i],(function(t){a.push(e.createElement(v.a,{key:t.id,id:t.id,title:t.title||"",description:t.description||"",blockData:t.blockData||[],winImage:t.winImage?"".concat(r._googlesitekitLegacyData.admin.assetsRoot,"images/").concat(t.winImage):"",format:t.format||"small",learnMoreURL:t.learnMoreURL||"",learnMoreDescription:t.learnMoreDescription||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaURL||"",ctaLabel:t.ctaLabel||"",ctaTarget:t.ctaTarget||"",type:t.severity||"",dismiss:t.dismiss||Object(m.__)("OK, Got it!","google-site-kit"),isDismissable:t.isDismissable||!0,logo:t.logo||!0,module:i,moduleName:n[i].name,pageIndex:t.pageIndex||"",dismissExpires:t.dismissExpires||0,showOnce:t.showOnce||!1}))}))})),e.createElement(g.b,null,a)}}]),DashboardModulesAlerts}(g.a);t.a=_}).call(this,n(12),n(13))},161:function(e,t,n){"use strict";var r=n(3),a=n.n(r),i=n(14),o=n.n(i),c=n(6),s=n.n(c),u=n(7),l=n.n(u),f=n(15),d=n(17),p=function(){function WinsWithData(e){s()(this,WinsWithData),this.wins=e,this.response=[]}var e;return l()(WinsWithData,[{key:"get",value:(e=o()(a.a.mark((function e(){var t,n=this;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=Object(f.filter)(this.wins.map((function(e){return!!e.withData&&(e.withData.callback=function(t){n.response[e.identifier]=t},e.withData)}))),e.next=3,d.c.combinedGetFromCache(t);case 3:return e.abrupt("return",this.response);case 4:case"end":return e.stop()}}),e,this)}))),function(){return e.apply(this,arguments)})}]),WinsWithData}();t.a=p},162:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(15),h=n(0),m=n(16),b=n(38),v=n(79);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(DashboardWinsAlerts,t);var n=y(DashboardWinsAlerts);function DashboardWinsAlerts(e){var t;return a()(this,DashboardWinsAlerts),(t=n.call(this,e)).state={data:!1},t}return o()(DashboardWinsAlerts,[{key:"componentDidMount",value:function(){var e=this;Object(m.a)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetWinsNotifications",(function(){Object(m.f)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetWinsNotifications");var t=Object(v.g)();t&&Object(v.d)(t).then((function(t){e.setState({data:t.results})}))}))}},{key:"render",value:function(){var t=this.state.data;if(0===Object.keys(t).length)return null;var n=[];return Object.keys(t).forEach((function(r){Object(g.each)(t[r],(function(t){n.push(e.createElement(b.a,{key:t.id,id:t.id,title:t.title||"",description:t.description||"",blockData:t.blockData||[],winImage:t.winImage||"",format:t.format||"small",learnMoreURL:t.learnMoreURL||"",learnMoreDescription:t.learnMoreDescription||"",learnMoreLabel:t.learnMoreLabel||"",ctaLink:t.ctaLink||"",ctaLabel:t.ctaLabel||"",type:t.severity||"",dismiss:t.dismiss||Object(h.__)("OK, Got it!","google-site-kit"),isDismissable:t.isDismissable||!0,logo:t.logo||!1,pageIndex:t.pageIndex||"",dismissExpires:t.dismissExpires||0,showOnce:t.showOnce||!1}))}))})),e.createElement(p.b,null,n)}}]),DashboardWinsAlerts}(p.a);t.a=k}).call(this,n(12))},17:function(e,t,n){"use strict";n.d(t,"a",(function(){return v.a})),n.d(t,"b",(function(){return v.b}));var r=n(11),a=n.n(r),i=n(15),o=n(65),c=n(48),s=n(16),u=n(62),l=n(24),f=n(55),d=n(71),p=n.n(d);function g(e){return p()(e)&&e.hasOwnProperty("code")&&("string"==typeof e.code||"number"==typeof e.code)&&e.hasOwnProperty("message")&&"string"==typeof e.message&&e.hasOwnProperty("data")}var h=n(97),m=n(126),b=n(29),v=n(72),y=n(99);function k(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function _(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?k(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):k(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var O=function(e,t){var n=_({data:{}},e);return n.data=_({dateRange:t},n.data),n},j={maxRequests:10,combinedGetFromCache:function(e){var t=this;return new Promise((function(n,r){try{var a=[],o=Object(u.c)();Object(i.each)(e,(function(e){var n=O(e,o);n.key=Object(b.c)(n.type,n.identifier,n.datapoint,n.data);var r=Object(b.b)(n.key,n.maxAge);void 0!==r&&(a[n.key]=r,t.resolve(n,r))})),n(a)}catch(e){r()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=[],a=25,l=Object(u.c)();Object(i.each)(e,(function(e){var n=O(e,l);n.key=Object(b.c)(n.type,n.identifier,n.datapoint,n.data);var i=Object(b.b)(n.key,n.maxAge);void 0!==i?(setTimeout((function(){t.resolve(n,i)}),a),a+=25):r.push(n)})),r=Object(i.sortBy)(r,"priority");var d=[],p=[],h={},m=!!r.find((function(e){return e.priority<10}));Object(i.each)(r,(function(e,t){!n&&10<=e.priority&&m?p.push(e):h[e.key]?h[e.key].push(t):(h[e.key]=[t],d.push(e))}));var v=10,y=d.slice(0,v),k=d.slice(v);if(k=k.concat(p),0!==y.length||0!==k.length){0<k.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(k,!0)}),50):this.maxRequests=10;var _=null!==Object(f.c)("datacache");return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/data/",{datacache:_||void 0}),data:{request:y},method:"POST"}).then((function(e){Object(i.each)(e,(function(e,n){if(h[n]){var a=g(e);a&&t.handleWPError(e),Object(i.each)(h[n],(function(n){var i=r[n];a||Object(b.e)(i.key,e),t.resolve(i,e)})),0===k.length&&Object(s.d)("googlesitekit.dataLoaded","api")}else console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(s.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){console.warn("WP Error in data response",e);var t=e.data;if(t&&t.reason){var n=0;["authError","insufficientPermissions"].includes(t.reason)&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(l.b)(h.a),1),n++),"forbidden"===t.reason&&(Object(s.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(l.b)(m.a),1),n++),n&&Object(s.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(s.g)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+n}))}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},invalidateCacheGroup:y.a,collectModuleData:function(e,t){var n=Object(s.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var r=this,a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},i=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=Object(b.c)(e,t,n,a);if(!i){var u=Object(b.b)(s,3600);if(void 0!==u)return new Promise((function(e){e(u)}))}return Object(o.default)({path:Object(c.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),a)}).then((function(e){return i||Object(b.e)(s,e),Promise.resolve(e)})).catch((function(e){return r.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,r){var a={};return a.data=r,Object(o.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:a,method:"POST"}).then((function(r){return j.invalidateCacheGroup(e,t,n),new Promise((function(e){e(r)}))}))},setModuleActive:function(e,t){return this.set(v.a,"modules","activation",{slug:e,active:t})}};Object(s.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData")||Object(s.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleData",j.collectModuleData.bind(j));t.c=j},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return i}));var r="core/user",a="googlesitekit_manage_options",i="missing_required_scopes"},212:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return j})),n.d(t,"a",(function(){return D})),n.d(t,"c",(function(){return S}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),u=n(19),l=n.n(u),f=n(251),d=n.n(f),p=n(65),g=n(48),h=n(167),m=n(237),b=n(217),v=n(218),y=n(219),k=n(34);function _(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function O(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?_(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):_(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var j=function(){var t=s()(a.a.mark((function t(n){var r,i,o,c,u;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r=e._googlesitekitLegacyData.admin,i=r.homeURL,o=r.ampMode,c={tagverify:1,timestamp:Date.now()},t.next=4,w(Object(g.a)(i,c),n);case 4:if((u=t.sent)||k.b!==o){t.next=9;break}return t.next=8,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map(function(){var e=s()(a.a.mark((function e(t){return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,w(Object(g.a)(t.link,O(O({},c),{},{amp:1})),n);case 2:return e.abrupt("return",e.sent);case 3:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()).pop()}));case 8:u=t.sent;case 9:return t.abrupt("return",Promise.resolve(u||null));case 10:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}(),w=function(){var e=s()(a.a.mark((function e(t,n){var r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.prev=0,e.next=3,fetch(t,{credentials:"omit"}).then((function(e){return e.text()}));case 3:return r=e.sent,e.abrupt("return",E(r,n)||null);case 7:return e.prev=7,e.t0=e.catch(0),e.abrupt("return",null);case 10:case"end":return e.stop()}}),e,null,[[0,7]])})));return function(t,n){return e.apply(this,arguments)}}(),E=function(e,t){var n=({adsense:b.a,analytics:v.a,tagmanager:y.b,setup:m.a}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},D=function(e,t){var n=t.find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},S=d()(function(){var e=s()(a.a.mark((function e(t){var n,r,i,o;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=t.homeURL,r=t.ampMode,l()(Object(h.a)(n),"homeURL must be valid URL"),i=[n],k.b!==r){e.next=14;break}return e.prev=4,e.next=7,Object(p.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return Object(g.a)(e.link,{amp:1})})).pop()}));case 7:(o=e.sent)&&i.push(o),e.next=14;break;case 11:return e.prev=11,e.t0=e.catch(4),e.abrupt("return",i);case 14:return e.abrupt("return",i);case 15:case"end":return e.stop()}}),e,null,[[4,11]])})));return function(t){return e.apply(this,arguments)}}())}).call(this,n(13))},215:function(e,t,n){"use strict";t.a=[/<script[^>]*>[^>]+?www.googletagmanager.com\/gtm[^>]+?['|"](GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtm\.js\?id=(GTM-[0-9A-Z]+)['|"]/,/<script[^>]*src=['|"]https:\/\/www.googletagmanager.com\/ns.html\?id=(GTM-[0-9A-Z]+)['|"]/,/<amp-analytics [^>]*config=['|"]https:\/\/www.googletagmanager.com\/amp.json\?id=(GTM-[0-9A-Z]+)['|"]/]},217:function(e,t,n){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},218:function(e,t,n){"use strict";t.a=[/<script [^>]*src=['|"]https:\/\/www.googletagmanager.com\/gtag\/js\?id=(UA-.*?)['|"][^>]*><\/script>/,/<script[^>]*>[^<]+google-analytics\.com\/analytics\.js[^<]+(UA-\d+-\d+)/,/__gaTracker\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/ga\( ?['|"]create['|"], ?['|"](UA-.*?)['|"], ?['|"]auto['|"] ?\)/,/_gaq.push\( ?\[ ?['|"]_setAccount['|"], ?['|"](UA-.*?)['|"] ?] ?\)/,/<amp-analytics [^>]*type="gtag"[^>]*>[^<]*<script type="application\/json">[^<]*"gtag_id":\s*"(UA-[^"]+)"/,/<amp-analytics [^>]*type="googleanalytics"[^>]*>[^<]*<script type="application\/json">[^<]*"account":\s*"(UA-[^"]+)"/]},219:function(e,t,n){"use strict";function r(e){return(parseInt(e,10)||0)>0}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a.a}));var a=n(215)},236:function(e,t,n){"use strict";(function(e,t){n(1);var r=n(16),a=n(24),i=n(5),o=n(157),c=n(158),s=n(160),u=n(162),l=n(97),f=e._googlesitekitLegacyData.setup,d=Object(i.k)("notification"),p=Object(a.a)(t.createElement(o.a,null)),g=Object(a.a)(t.createElement(c.a,null)),h=Object(a.a)(t.createElement(s.a,null)),m=Object(a.a)(t.createElement(u.a,null)),b=Object(a.a)(t.createElement(l.a,null));Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.SetupNotification",p,10),f.needReauthenticate&&Object(r.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",b,1),"authentication_success"===d||"authentication_failure"===d?Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.SetupNotification",g,1):f.isAuthenticated&&f.isVerified&&(Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.ModulesNotification",h,1),Object(r.b)("googlesitekit.DashboardNotifications","googlesitekit.WinsNotification",m,1))}).call(this,n(13),n(12))},237:function(e,t,n){"use strict";t.a=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/]},24:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o})),n.d(t,"b",(function(){return c}));var r=n(83),a=n.n(r),i=n(1),o=function(e){return function(t){return function FilteredComponent(n){return Object(i.f)(i.b,{},"",Object(i.f)(t,n),e)}}},c=function(t,n){return function(r){return function InnerComponent(i){return e.createElement(t,a()({},i,n,{OriginalComponent:r}))}}}}).call(this,n(12))},257:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(23),s=n.n(c),u=n(9),l=n.n(u),f=n(10),d=n.n(f),p=n(4),g=n.n(p),h=n(1),m=n(18),b=n.n(m),v=n(0),y=n(16),k=n(79);function _(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var a=g()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return d()(this,n)}}var O=function(t){l()(NotificationCounter,t);var n=_(NotificationCounter);function NotificationCounter(e){var t;return a()(this,NotificationCounter),(t=n.call(this,e)).state={count:0},t.handleIncrement=t.handleIncrement.bind(s()(t)),t.handleDecrement=t.handleDecrement.bind(s()(t)),t}return o()(NotificationCounter,[{key:"componentDidMount",value:function(){var e=this;Object(y.a)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetTotalNotifications",(function(){Object(y.f)("googlesitekit.dataLoaded","googlesitekit.dataLoadedGetTotalNotifications"),Object(k.c)().then((function(t){e.setState({count:t})}))})),document.addEventListener("notificationDismissed",this.handleDecrement,!1)}},{key:"componentWillUnmount",value:function(){document.removeEventListener("notificationDismissed",this.handleDecrement)}},{key:"handleIncrement",value:function(){this.setState(k.e)}},{key:"handleDecrement",value:function(){this.setState(k.a)}},{key:"render",value:function(){var t=Object(v.sprintf)(
5
  /* translators: %d: the number of notifications */
6
+ Object(v._n)("%d notification","%d notifications",this.state.count,"google-site-kit"),this.state.count),n=e.createElement("span",{className:b()("googlesitekit-notifications-counter","update-plugins","count-".concat(this.state.count))},e.createElement("span",{className:"plugin-count","aria-hidden":"true"},this.state.count),e.createElement("span",{className:"screen-reader-text"},t));return Object(h.g)(n,document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"))}}]),NotificationCounter}(h.a);t.a=O}).call(this,n(12))},270:function(e,t,n){"use strict";(function(e){var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),u=n(6),l=n.n(u),f=n(7),d=n.n(f),p=n(23),g=n.n(p),h=n(9),m=n.n(h),b=n(10),v=n.n(b),y=n(4),k=n.n(y),_=n(1),O=n(2),j=n.n(O),w=n(18),E=n.n(w),D=n(65),S=n(0),R=n(5),x=n(271),P=n(50);function N(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var C=function(t){m()(OptIn,t);var n,r=N(OptIn);function OptIn(e){var t;return l()(this,OptIn),(t=r.call(this,e)).state={optIn:Object(P.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(g()(t)),t}return d()(OptIn,[{key:"handleOptIn",value:(n=s()(a.a.mark((function e(t){var n,r;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(n=!!t.target.checked,r=Object(R.i)("googlesitekit_tracking_optin"),Object(P.b)(n),!n){e.next=6;break}return e.next=6,Object(P.c)("tracking_plugin",this.props.optinAction);case 6:return e.prev=6,e.next=9,Object(D.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},r,n)}});case 9:this.setState({optIn:n,error:!1}),e.next=15;break;case 12:e.prev=12,e.t0=e.catch(6),this.setState({optIn:!n,error:{errorCode:e.t0.code,errorMsg:e.t0.message}});case 15:case"end":return e.stop()}}),e,this,[[6,12]])}))),function(e){return n.apply(this,arguments)})},{key:"render",value:function(){var t=this.state,n=t.optIn,r=t.error,a=this.props,i=a.id,o=a.name,c=a.className,s=Object(S.sprintf)(
7
  /* translators: %s: privacy policy URL */
8
+ Object(S.__)('Help us improve the Site Kit plugin by allowing tracking of anonymous usage stats. All data are treated in accordance with <a href="%s" target="_blank" rel="noopener noreferrer">Google Privacy Policy</a>',"google-site-kit"),"https://policies.google.com/privacy");return e.createElement("div",{className:E()("googlesitekit-opt-in",c)},e.createElement(x.a,{id:i,name:o,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(R.t)(s,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),r&&e.createElement("div",{className:"googlesitekit-error-text"},r.errorMsg))}}]),OptIn}(_.a);C.propTypes={id:j.a.string,name:j.a.string,className:j.a.string,optinAction:j.a.string},C.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=C}).call(this,n(12))},271:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(Checkbox,t);var n=y(Checkbox);function Checkbox(e){var t;return a()(this,Checkbox),(t=n.call(this,e)).formFieldRef=Object(p.h)(),t.checkboxRef=Object(p.h)(),t}return o()(Checkbox,[{key:"componentDidMount",value:function(){new v.e(this.formFieldRef.current).input=new v.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,r=t.id,a=t.name,i=t.value,o=t.checked,c=t.disabled,s=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:b()("mdc-checkbox",{"mdc-checkbox--disabled":c}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:r,name:a,value:i,checked:o,disabled:c,onChange:n}),e.createElement("div",{className:"mdc-checkbox__background"},e.createElement("svg",{className:"mdc-checkbox__checkmark",viewBox:"0 0 24 24"},e.createElement("path",{className:"mdc-checkbox__checkmark-path",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"})),e.createElement("div",{className:"mdc-checkbox__mixedmark"}))),e.createElement("label",{htmlFor:r},s))}}]),Checkbox}(p.a);k.propTypes={onChange:h.a.func.isRequired,id:h.a.string.isRequired,name:h.a.string.isRequired,value:h.a.string.isRequired,checked:h.a.bool,disabled:h.a.bool,children:h.a.node.isRequired},k.defaultProps={checked:!1,disabled:!1},t.a=k}).call(this,n(12))},28:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var y=function(t){s()(Link,t);var n=v(Link);function Link(){return a()(this,Link),n.apply(this,arguments)}return o()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,r=t.onClick,a=t.href,i=t.children,o=t.className,c=t.arrow,s=t.external,u=t.inverse,l=t.back,f=t.small,d=t.inherit,p=t.caps,g=t.danger,h=t.disabled,m=t.id,v=a&&!h,y=v?"a":"button";return e.createElement(y,{className:b()("googlesitekit-cta-link",o,{"googlesitekit-cta-link--arrow":c,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":u,"googlesitekit-cta-link--back":l,"googlesitekit-cta-link--small":f,"googlesitekit-cta-link--inherit":d,"googlesitekit-cta-link--caps":p,"googlesitekit-cta-link--danger":g,"googlesitekit-cta-link--disabled":h}),onClick:r,id:m,href:v?a:void 0,target:v&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:h,dangerouslySetInnerHTML:n},i)}}]),Link}(p.a);y.propTypes={dangerouslySetInnerHTML:h.a.shape({__html:h.a.string}),onClick:h.a.func,href:h.a.string,children:h.a.oneOfType([h.a.string.isRequired,h.a.array.isRequired]),className:h.a.string,arrow:h.a.bool,external:h.a.bool,inverse:h.a.bool,back:h.a.bool,small:h.a.bool,inherit:h.a.bool,caps:h.a.bool,danger:h.a.bool,disabled:h.a.bool},y.defaultProps={dangerouslySetInnerHTML:void 0,onClick:null,href:"",className:"",arrow:!1,external:!1,inverse:!1,back:!1,small:!1,inherit:!1,caps:!1,danger:!1,disabled:!1},t.a=y}).call(this,n(12))},29:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return s})),n.d(t,"e",(function(){return u})),n.d(t,"b",(function(){return l})),n.d(t,"a",(function(){return f})),n.d(t,"c",(function(){return d}));var r=n(32),a=n.n(r),i=n(15),o=n(40),c=n(56),s=function(){e._googlesitekitLegacyData.admin=e._googlesitekitLegacyData.admin||{},"string"==typeof e._googlesitekitLegacyData.admin.datacache&&(e._googlesitekitLegacyData.admin.datacache=JSON.parse(e._googlesitekitLegacyData.admin.datacache)),"object"!==a()(e._googlesitekitLegacyData.admin.datacache)&&(e._googlesitekitLegacyData.admin.datacache={})},u=function(t,n){if(void 0!==n&&(!n||"object"!==a()(n)||!n.error&&!n.errors)){s(),e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(n);var r={value:n,date:Date.now()/1e3};Object(o.a)().setItem("googlesitekit_"+t,JSON.stringify(r))}},l=function(t,n){if(!e._googlesitekitLegacyData.admin.nojscache){if(s(),void 0!==e._googlesitekitLegacyData.admin.datacache[t])return e._googlesitekitLegacyData.admin.datacache[t];var r=JSON.parse(Object(o.a)().getItem("googlesitekit_"+t));return r&&"object"===a()(r)&&r.date&&(!n||Date.now()/1e3-r.date<n)?(e._googlesitekitLegacyData.admin.datacache[t]=Object(i.cloneDeep)(r.value),Object(i.cloneDeep)(e._googlesitekitLegacyData.admin.datacache[t])):void 0}},f=function(t){s(),delete e._googlesitekitLegacyData.admin.datacache[t],Object(o.a)().removeItem("googlesitekit_"+t)},d=function(e,t,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],s=0,u=o;s<u.length;s++){var l=u[s];if(!l||!l.length)break;i.push(l)}return 3===i.length&&r&&"object"===a()(r)&&Object.keys(r).length&&i.push(Object(c.a)(r)),i.join("::")}}).call(this,n(13))},31:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(23),s=n.n(c),u=n(9),l=n.n(u),f=n(10),d=n.n(f),p=n(4),g=n.n(p),h=n(1),m=n(2),b=n.n(m),v=n(18),y=n.n(v),k=n(124),_=n(63),O=n(82);function j(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=g()(e);if(t){var a=g()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return d()(this,n)}}var w=function(t){l()(DataBlock,t);var n=j(DataBlock);function DataBlock(e){var t;return a()(this,DataBlock),(t=n.call(this,e)).handleClick=t.handleClick.bind(s()(t)),t.handleKeyPress=t.handleKeyPress.bind(s()(t)),t}return o()(DataBlock,[{key:"handleClick",value:function(){var e=this.props,t=e.stat;(0,e.handleStatSelection)(t)}},{key:"handleKeyPress",value:function(e){e.preventDefault();var t=this.props,n=t.stat,r=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||r(n)}},{key:"render",value:function(){var t=this.props,n=t.className,r=t.title,a=t.datapoint,i=t.datapointUnit,o=t.change,c=t.changeDataUnit,s=t.context,u=t.period,l=t.selected,f=t.handleStatSelection,d=t.source,p=t.sparkline,g=t.invertChangeColor,m="button"===s?"button":"",b=p;return b&&g&&(b=Object(h.d)(p,{invertChangeColor:g})),e.createElement("div",{className:y()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":l}),tabIndex:"button"===s?"0":"-1",role:f&&m,onClick:f&&this.handleClick,onKeyPress:f&&this.handleKeyPress,"aria-label":f&&r,"aria-pressed":f&&l},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},r),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(a).concat(i))),b&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},b),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===o&&e.createElement(h.b,null," "),o&&e.createElement(h.b,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(k.a,{direction:0<parseFloat(o)?"up":"down",invertColor:g})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(_.b)(Math.abs(o))).concat(c," ").concat(u)))),d&&e.createElement(O.a,{className:"googlesitekit-data-block__source",name:d.name,href:d.link})))}}]),DataBlock}(h.a);w.propTypes={stat:b.a.number,onClick:b.a.func,className:b.a.string,title:b.a.string,datapoint:b.a.oneOfType([b.a.string,b.a.number]),datapointUnit:b.a.string,change:b.a.oneOfType([b.a.string,b.a.number]),changeDataUnit:b.a.string,context:b.a.string,period:b.a.string,selected:b.a.bool,handleStatSelection:b.a.func,invertChangeColor:b.a.bool},w.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=w}).call(this,n(12))},33:function(e,t,n){"use strict";(function(e,r){n(1);var a=n(2),i=n.n(a),o=n(18),c=n.n(o),s=function SvgIcon(t){var n=t.id,a=t.className,i=t.height,o=t.width,s="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:c()("svg",a),height:i,width:o},r.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:i.a.string.isRequired,className:i.a.string,height:i.a.string,width:i.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(13),n(12))},34:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return i}));var r="core/site",a="primary",i="secondary"},36:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r="_googlesitekitDataLayer",a="data-googlesitekit-gtag"},369:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return I}));var a=n(45),i=n.n(a),o=n(6),c=n.n(o),s=n(7),u=n.n(s),l=n(9),f=n.n(l),d=n(10),p=n.n(d),g=n(4),h=n.n(g),m=n(3),b=n.n(m),v=n(14),y=n.n(v),k=n(1),_=n(0),O=n(2),j=n.n(O),w=n(41),E=n.n(w),D=n(54),S=n(212),R=n(28),x=n(120),P=n(49);function N(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return C(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return C(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function C(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function A(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=h()(e);if(t){var a=h()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return p()(this,n)}}var L=[y()(b.a.mark((function t(){var n;return b.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(n=e.location.hostname,!["localhost","127.0.0.1"].includes(n)&&!n.match(/\.(example|invalid|localhost|test)$/)){t.next=3;break}throw"invalid_hostname";case 3:case"end":return t.stop()}}),t)}))),y()(b.a.mark((function e(){var t,n,r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,E.a.set("core","site","setup-tag");case 2:return t=e.sent,n=t.token,e.next=6,Object(S.b)("setup").catch((function(){throw"check_fetch_failed"}));case 6:if(r=e.sent,n===r){e.next=9;break}throw"setup_token_mismatch";case 9:case"end":return e.stop()}}),e)}))),y()(b.a.mark((function e(){var t,n,r;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,E.a.get("core","site","health-checks",void 0,{useCache:!1}).catch((function(){throw"check_fetch_failed"}));case 2:if(null==(r=e.sent)||null===(t=r.checks)||void 0===t||null===(n=t.googleAPI)||void 0===n?void 0:n.pass){e.next=5;break}throw"google_api_connection_fail";case 5:case"end":return e.stop()}}),e)}))),y()(b.a.mark((function e(){return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,fetch("https://cdn.ampproject.org/v0.js").catch((function(){throw"amp_cdn_restricted"}));case 2:if(e.sent.ok){e.next=5;break}throw"amp_cdn_restricted";case 5:case"end":return e.stop()}}),e)})))],I=function(t){f()(CompatibilityChecks,t);var n,a=A(CompatibilityChecks);function CompatibilityChecks(t){var n;c()(this,CompatibilityChecks);var r=e._googlesitekitLegacyData.setup.isSiteKitConnected;return(n=a.call(this,t)).state={complete:r,error:null,developerPlugin:{}},n}return u()(CompatibilityChecks,[{key:"componentDidMount",value:(n=y()(b.a.mark((function e(){var t,n,r,a;return b.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(!this.state.complete){e.next=2;break}return e.abrupt("return");case 2:e.prev=2,t=N(L),e.prev=4,t.s();case 6:if((n=t.n()).done){e.next=12;break}return r=n.value,e.next=10,r();case 10:e.next=6;break;case 12:e.next=17;break;case 14:e.prev=14,e.t0=e.catch(4),t.e(e.t0);case 17:return e.prev=17,t.f(),e.finish(17);case 20:e.next=28;break;case 22:return e.prev=22,e.t1=e.catch(2),e.next=26,E.a.get("core","site","developer-plugin");case 26:a=e.sent,this.setState({error:e.t1,developerPlugin:a});case 28:this.setState({complete:!0});case 29:case"end":return e.stop()}}),e,this,[[2,22],[4,14,17,20]])}))),function(){return n.apply(this,arguments)})},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,n=e.active,r=e.installURL,a=e.activateURL,i=e.configureURL;return!t&&r?{labelHTML:Object(_.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:r,external:!1}:t&&!n&&a?{labelHTML:Object(_.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:a,external:!1}:t&&n&&i?{labelHTML:Object(_.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:{labelHTML:Object(_.__)('Learn how<span class="screen-reader-text"> to install and use the helper plugin</span>',"google-site-kit"),href:"https://sitekit.withgoogle.com/documentation/using-site-kit-on-a-staging-environment/",external:!0}}},{key:"renderError",value:function(e){var t=this.state.developerPlugin.installed,n=this.helperCTA(),a=n.labelHTML,i=n.href,o=n.external;switch(e){case"invalid_hostname":case"check_fetch_failed":return r.createElement("p",null,!t&&Object(_.__)("Looks like this may be a staging environment. If so, you’ll need to install a helper plugin and verify your production site in Search Console.","google-site-kit"),t&&Object(_.__)("Looks like this may be a staging environment and you already have the helper plugin. Before you can use Site Kit, please make sure you’ve provided the necessary credentials in the Authentication section and verified your production site in Search Console.","google-site-kit")," ",r.createElement(R.a,{href:i,dangerouslySetInnerHTML:{__html:a},external:o,inherit:!0}));case"setup_token_mismatch":return r.createElement("p",null,Object(_.__)("Looks like you may be using a caching plugin which could interfere with setup. Please deactivate any caching plugins before setting up Site Kit. You may reactivate them once setup has been completed.","google-site-kit"));case"google_api_connection_fail":return r.createElement(k.b,null,r.createElement("p",{dangerouslySetInnerHTML:Object(D.a)(Object(_.sprintf)(
9
+ /* translators: %1$s: Support Forum URL, %2$s: Error message */
10
+ Object(_.__)('Looks like your site is having a technical issue with requesting data from Google services.<br/>To get more help, ask a question on our <a href="%1$s">support forum</a> and include the text of the original error message:<br/>%2$s',"google-site-kit"),"https://wordpress.org/support/plugin/google-site-kit/",e),{ALLOWED_TAGS:["a","br"],ALLOWED_ATTR:["href"]})}));case"amp_cdn_restricted":return r.createElement(k.b,null,r.createElement("p",{dangerouslySetInnerHTML:Object(D.a)(Object(_.sprintf)(
11
+ /* translators: %1$s: Support Forum URL, %2$s: Error message */
12
+ Object(_.__)('Looks like the AMP CDN is restricted in your region, which could interfere with setup on the Site Kit service.<br/>To get more help, ask a question on our <a href="%1$s">support forum</a> and include the text of the original error message:<br/>%2$s',"google-site-kit"),"https://wordpress.org/support/plugin/google-site-kit/",e),{ALLOWED_TAGS:["a","br"],ALLOWED_ATTR:["href"]})}))}}},{key:"render",value:function(){var e,t,n=this.state,a=n.complete,o=n.error,c=this.props,s=c.children,u=i()(c,["children"]);return o&&(e=r.createElement(k.b,null,r.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},r.createElement("div",{className:"mdc-layout-grid__inner"},r.createElement(x.a,null),r.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(_.__)("Your site may not be ready for Site Kit","google-site-kit"))),this.renderError(o)))),a||(t=r.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},r.createElement("small",null,Object(_.__)("Checking Compatibility…","google-site-kit")),r.createElement(P.a,{small:!0,compress:!0}))),s({restProps:u,complete:a,error:o,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(k.a);I.propTypes={children:j.a.func.isRequired}}).call(this,n(13),n(12))},38:function(e,t,n){"use strict";(function(e){var r=n(11),a=n.n(r),i=n(3),o=n.n(i),c=n(14),s=n.n(c),u=n(6),l=n.n(u),f=n(7),d=n.n(f),p=n(23),g=n.n(p),h=n(9),m=n.n(h),b=n(10),v=n.n(b),y=n(4),k=n.n(y),_=n(1),O=n(2),j=n.n(O),w=n(18),E=n.n(w),D=n(15),S=n(33),R=n(54),x=n(29),P=n(31),N=n(47),C=n(120),A=n(125),L=n(28);function I(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=k()(e);if(t){var a=k()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return v()(this,n)}}var T=function(t){m()(Notification,t);var n,r,i=I(Notification);function Notification(e){var t;return l()(this,Notification),(t=i.call(this,e)).state={isClosed:!1},t.cardRef=Object(_.h)(),t.handleDismiss=t.handleDismiss.bind(g()(t)),t.handleCTAClick=t.handleCTAClick.bind(g()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&Object(x.e)("notification::displayed::".concat(t.props.id),new Date),t}return d()(Notification,[{key:"handleDismiss",value:(r=s()(o.a.mark((function e(t){var n;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),t.preventDefault(),!(n=this.props.onDismiss)){e.next=6;break}return e.next=6,n(t);case 6:this.dismiss();case 7:case"end":return e.stop()}}),e,this)}))),function(e){return r.apply(this,arguments)})},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){Object(x.e)("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:(n=s()(o.a.mark((function e(t){var n,r,a;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(t.persist(),n=this.props,r=n.isDismissable,!(a=n.onCTAClick)){e.next=5;break}return e.next=5,a(t);case 5:r&&this.dismiss();case 6:case"end":return e.stop()}}),e,this)}))),function(e){return n.apply(this,arguments)})},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,r=Object(x.b)("notification::dismissed::".concat(t));if(r){var a=new Date(r);a.setSeconds(a.getSeconds()+parseInt(n,10)),a<new Date&&Object(x.a)("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,r=this.props,i=r.children,o=r.id,c=r.title,s=r.description,u=r.blockData,l=r.winImage,f=r.smallImage,d=r.format,p=r.learnMoreURL,g=r.learnMoreDescription,h=r.learnMoreLabel,m=r.ctaLink,b=r.ctaLabel,v=r.ctaTarget,y=r.type,k=r.dismiss,O=r.isDismissable,j=r.logo,w=r.module,I=r.moduleName,T=r.pageIndex,M=r.anchorLink,U=r.anchorLinkLabel;if(Object(x.b)("notification::dismissed::".concat(o)))return null;var q,F=n?"is-closed":"is-open",H="large"===d&&"win-stats-increase"===y,G="mdc-layout-grid__cell--span-12";"large"===d?(G="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-6-tablet mdc-layout-grid__cell--span-8-desktop ",H&&(G="mdc-layout-grid__cell--order-2-phone mdc-layout-grid__cell--order-1-tablet mdc-layout-grid__cell--span-5-tablet mdc-layout-grid__cell--span-8-desktop ")):"small"===d&&(G="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),q="win-warning"===y?e.createElement(C.a,null):"win-error"===y?e.createElement(A.a,null):"";var W=e.createElement(_.b,null,u&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(D.map)(u,(function(t,n){return e.createElement("div",{key:n,className:E()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":H,"mdc-layout-grid__cell--span-4-desktop":!H})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(P.a,t)))})))),B=e.createElement(_.b,null,c&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},c),M&&U&&e.createElement("p",{className:"googlesitekit-publisher-win__link"},e.createElement(L.a,{href:M},U)),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(_.i)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(R.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),h&&e.createElement(_.b,null," ",e.createElement(L.a,{href:p,external:!0,inherit:!0},h),g),T&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},T))),i),V=w?e.createElement(S.a,{id:w,height:"19",width:"19"}):e.createElement(S.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:E()("googlesitekit-publisher-win",(t={},a()(t,"googlesitekit-publisher-win--".concat(d),d),a()(t,"googlesitekit-publisher-win--".concat(y),y),a()(t,"googlesitekit-publisher-win--".concat(F),F),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},j&&e.createElement("div",{className:E()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":H,"mdc-layout-grid__cell--order-1-tablet":H})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},V),I&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},I)),f&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("img",{className:"googlesitekit-publisher-win__small-image",alt:"",src:f})),e.createElement("div",{className:E()("mdc-layout-grid__cell",G)},H?e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-5-desktop mdc-layout-grid__cell--span-8-tablet"},B),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-7-desktop mdc-layout-grid__cell--span-8-tablet mdc-layout-grid__cell--align-bottom"},W)):e.createElement(_.b,null,B,W),m&&e.createElement(N.a,{href:m,target:v,onClick:this.handleCTAClick},b),O&&k&&e.createElement(L.a,{onClick:this.handleDismiss},k)),l&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--order-1-phone mdc-layout-grid__cell--order-2-tablet mdc-layout-grid__cell--span-2-tablet mdc-layout-grid__cell--span-4-desktop "},e.createElement("div",{className:"googlesitekit-publisher-win__image-large"},e.createElement("img",{alt:"",src:l}))),("win-error"===y||"win-warning"===y)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},q)))))}}]),Notification}(_.a);T.propTypes={id:j.a.string.isRequired,title:j.a.string.isRequired,description:j.a.node,learnMoreURL:j.a.string,learnMoreDescription:j.a.string,learnMoreLabel:j.a.string,blockData:j.a.array,winImage:j.a.string,smallImage:j.a.string,format:j.a.string,ctaLink:j.a.string,ctaLabel:j.a.string,type:j.a.string,dismiss:j.a.string,isDismissable:j.a.bool,logo:j.a.bool,module:j.a.string,moduleName:j.a.string,pageIndex:j.a.string,dismissExpires:j.a.number,showOnce:j.a.bool,onCTAClick:j.a.func,onDismiss:j.a.func,anchorLink:j.a.string,anchorLinkLabel:j.a.string},T.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=T}).call(this,n(12))},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r,a=n(6),i=n.n(a),o=n(7),c=n.n(o),s=function(t){var n=e[t];if(!n)return!1;try{var r="__storage_test__";return n.setItem(r,r),n.removeItem(r),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},u=function(){function NullStorage(){i()(this,NullStorage)}return c()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),l=function(){return r||(r=s("sessionStorage")?e.sessionStorage:s("localStorage")?e.localStorage:new u),r}}).call(this,n(13))},41:function(e,t){e.exports=googlesitekit.api},43:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return b}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(19),s=n.n(c),u=n(71),l=n.n(u),f=n(67),d=n(5);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=function(e){return g({},e)},m=function(){return{}},b=function(t){var n,r,i=t.baseName,c=t.controlCallback,u=t.reducerCallback,p=void 0===u?h:u,b=t.argsToParams,v=void 0===b?m:b;s()(i,"baseName is required."),s()("function"==typeof c,"controlCallback is required and must be a function."),s()("function"==typeof p,"reducerCallback must be a function."),s()("function"==typeof v,"argsToParams must be a function.");try{v(),r=!1}catch(e){r=!0}var y=Object(f.b)(i),k=Object(f.a)(i),_="FETCH_".concat(k),O="START_".concat(_),j="FINISH_".concat(_),w="CATCH_".concat(_),E="RECEIVE_".concat(k),D="fetch".concat(y),S="receive".concat(y),R="isFetching".concat(y),x=o()({},R,{}),P=(n={},o()(n,D,a.a.mark((function t(){var n,r,i,o=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:t.prev=0,i=v.apply(void 0,o),t.next=9;break;case 4:return t.prev=4,t.t0=t.catch(0),e.console.error(t.t0.message),r=t.t0,t.abrupt("return",{response:n,error:r});case 9:return t.next=11,{payload:{params:i},type:O};case 11:return t.prev=11,t.next=14,{payload:{params:i},type:_};case 14:return n=t.sent,t.next=17,P[S](n,i);case 17:return t.next=19,{payload:{params:i},type:j};case 19:t.next=26;break;case 21:return t.prev=21,t.t1=t.catch(11),r=t.t1,t.next=26,{payload:{error:r,params:i},type:w};case 26:return t.abrupt("return",{response:n,error:r});case 27:case"end":return t.stop()}}),t,null,[[0,4],[11,21]])}))),o()(n,S,(function(e,t){return s()(void 0!==e,"response is required."),r?s()(l()(t),"params is required."):t={},{payload:{response:e,params:t},type:E}})),n),N=o()({},_,(function(e){var t=e.payload;return c(t.params)})),C=o()({},R,(function(e){if(void 0===e[R])return!1;var t;try{for(var n=arguments.length,r=new Array(n>1?n-1:0),a=1;a<n;a++)r[a-1]=arguments[a];t=v.apply(void 0,r)}catch(e){return!1}return!!e[R][Object(d.v)(t)]}));return{INITIAL_STATE:x,actions:P,controls:N,reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case O:var a=r.params;return g(g({},e),{},o()({},R,g(g({},e[R]),{},o()({},Object(d.v)(a),!0))));case E:var i=r.response,c=r.params;return p(e,i,c);case j:var s=r.params;return g(g({},e),{},o()({},R,g(g({},e[R]),{},o()({},Object(d.v)(s),!1))));case w:var u=r.error,l=r.params;return g(g({},e),{},o()({error:u},R,g(g({},e[R]),{},o()({},Object(d.v)(l),!1))));default:return g({},e)}},resolvers:{},selectors:C}}}).call(this,n(13))},44:function(e,t,n){"use strict";var r=n(80),a=n.n(r);n.d(t,"k",(function(){return a.a})),n.d(t,"a",(function(){return r.HelperText})),n.d(t,"b",(function(){return r.Input}));var i=n(137);n.d(t,"g",(function(){return i.a}));var o=n(223);n.d(t,"e",(function(){return o.a}));var c=n(103),s=n.n(c);n.d(t,"j",(function(){return s.a})),n.d(t,"i",(function(){return c.Option}));var u=n(224);n.d(t,"h",(function(){return u.a}));var l=n(221);n.d(t,"d",(function(){return l.a}));var f=n(222);n.d(t,"c",(function(){return f.a}));var d=n(220);n.d(t,"f",(function(){return d.a}))},447:function(e,t,n){"use strict";(function(e,r){n.d(t,"a",(function(){return ActivationApp}));var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(1),u=n(0),l=n(5),f=n(448),d=n(257);function ActivationApp(){var t=e._googlesitekitBaseData,n=t.proxySetupURL,a=t.splashURL,o=e._googlesitekitLegacyData.permissions.canViewDashboard,p=e._googlesitekitLegacyData.dashboardPermalink,g=n||a,h=Object(u.__)("Start setup","google-site-kit");o&&(g=p,h=Object(u.__)("Go to Dashboard","google-site-kit"));var m=Object(s.l)(function(){var t=c()(i.a.mark((function t(r){return i.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return r.preventDefault(),t.next=3,Object(l.w)("plugin_setup",n?"proxy_start_setup_banner":"goto_sitekit");case 3:e.location.assign(g);case 4:case"end":return t.stop()}}),t)})));return function(e){return t.apply(this,arguments)}}());return r.createElement(s.b,null,r.createElement(d.a,null),r.createElement(f.a,{buttonURL:g,buttonLabel:h,onButtonClick:m}))}}).call(this,n(13),n(12))},448:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return ActivationMain}));var r=n(1),a=n(0),i=n(2),o=n.n(i),c=n(47),s=n(138),u=n(270),l=n(369);function ActivationMain(t){var n=t.buttonURL,i=t.onButtonClick,o=t.buttonLabel;return e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(s.a,null),e.createElement("h3",{className:"googlesitekit-heading-3 googlesitekit-activation__title"},Object(a.__)("Congratulations, the Site Kit plugin is now activated.","google-site-kit")),e.createElement(l.a,null,(function(t){var a=t.complete,s=t.inProgressFeedback,l=t.CTAFeedback;return e.createElement(r.b,null,l,e.createElement(u.a,{optinAction:"analytics_optin_setup_banner"}),e.createElement("div",{className:"googlesitekit-start-setup-wrap"},e.createElement(c.a,{id:"start-setup-link",className:"googlesitekit-start-setup",href:n,onClick:i,disabled:!a},o),s))})))))}ActivationMain.propTypes={buttonURL:o.a.string.isRequired,onButtonClick:o.a.func,buttonLabel:o.a.string.isRequired}}).call(this,n(12))},47:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(44);function y(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var k=function(t){s()(Button,t);var n=y(Button);function Button(e){var t;return a()(this,Button),(t=n.call(this,e)).buttonRef=Object(p.h)(),t}return o()(Button,[{key:"componentDidMount",value:function(){new v.g(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,r=t.children,a=t.href,i=t.text,o=t.className,c=t.danger,s=t.disabled,u=t.target,l=t.id,f=t.icon,d=t.trailingIcon,p=t.ariaHaspopup,g=t.ariaExpanded,h=t.ariaControls,m=a&&!s?"a":"button";return e.createElement(m,{className:b()("mdc-button",o,{"mdc-button--raised":!i,"mdc-button--danger":c}),onClick:n,href:s?void 0:a,ref:this.buttonRef,disabled:!!s,target:u||"_self",id:l,"aria-haspopup":p,"aria-expanded":g,"aria-controls":h,role:"a"===m?"button":void 0},f&&f,e.createElement("span",{className:"mdc-button__label"},r),d&&d)}}]),Button}(p.a);k.propTypes={onClick:h.a.func,children:h.a.string.isRequired,href:h.a.string,text:h.a.bool,className:h.a.string,danger:h.a.bool,disabled:h.a.bool,icon:h.a.element,trailingIcon:h.a.element,ariaHaspopup:h.a.string,ariaExpanded:h.a.bool,ariaControls:h.a.string},k.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=k}).call(this,n(12))},49:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m);function v(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var y=function(t){s()(ProgressBar,t);var n=v(ProgressBar);function ProgressBar(){return a()(this,ProgressBar),n.apply(this,arguments)}return o()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,r=t.small,a=t.compress,i=t.height,o=i?Math.round(i/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:o,marginBottom:o},className:b()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":r,"mdc-linear-progress--compress":a})},e.createElement("div",{className:"mdc-linear-progress__buffering-dots"}),e.createElement("div",{className:"mdc-linear-progress__buffer"}),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__primary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})),e.createElement("div",{className:"mdc-linear-progress__bar mdc-linear-progress__secondary-bar"},e.createElement("span",{className:"mdc-linear-progress__bar-inner"})))}}]),ProgressBar}(p.a);y.propTypes={className:h.a.string,small:h.a.bool,compress:h.a.bool},y.defaultProps={className:"",small:!1,compress:!1},t.a=y}).call(this,n(12))},5:function(e,t,n){"use strict";(function(e,r){n.d(t,"s",(function(){return x})),n.d(t,"q",(function(){return P})),n.d(t,"n",(function(){return C})),n.d(t,"r",(function(){return A})),n.d(t,"h",(function(){return L})),n.d(t,"c",(function(){return I})),n.d(t,"f",(function(){return T})),n.d(t,"j",(function(){return M})),n.d(t,"l",(function(){return U})),n.d(t,"m",(function(){return q})),n.d(t,"x",(function(){return F})),n.d(t,"b",(function(){return H})),n.d(t,"u",(function(){return G})),n.d(t,"e",(function(){return W})),n.d(t,"p",(function(){return B})),n.d(t,"i",(function(){return V}));var a=n(3),i=n.n(a),o=n(14),c=n.n(o),s=n(11),u=n.n(s),l=n(45),f=n.n(l),d=n(32),p=n.n(d),g=(n(1),n(15)),h=n(16),m=n(0),b=n(48),v=n(145),y=n(33);n.d(t,"a",(function(){return y.a}));var k=n(50);n.d(t,"w",(function(){return k.c}));var _=n(24),O=n(54);n.d(t,"t",(function(){return O.a}));var j=n(56);n.d(t,"v",(function(){return j.a}));var w=n(55);n.d(t,"d",(function(){return w.b})),n.d(t,"k",(function(){return w.c}));n(40);var E=n(63);function D(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function S(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?D(Object(n),!0).forEach((function(t){u()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return E.a})),n.d(t,"g",(function(){return _.b}));var R=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},x=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(g.isFinite)(e)?e:Number(e),Object(g.isFinite)(e)||(console.warn("Invalid number",e,p()(e)),e=0),t)return P(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in millions.
13
+ Object(m.__)("%sM","google-site-kit"),P(R(e),e%10==0?{}:n)):1e4<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
14
+ Object(m.__)("%sK","google-site-kit"),P(R(e))):1e3<=e?Object(m.sprintf)(// translators: %s: an abbreviated number in thousands.
15
+ Object(m.__)("%sK","google-site-kit"),P(R(e),e%10==0?{}:n)):e.toString()},P=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?N():n,a=f()(t,["locale"]);return new Intl.NumberFormat(r,a).format(e)},N=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(g.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language},C=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},A=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},L=function(e,t){var n=1e3*C("day"),r=e.getTime(),a=t.getTime();return Math.round(Math.abs(r-a)/n)},I=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},T=function(e,t){return Object(g.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},M=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==p()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:S(S({},e),{},u()({},t,n[t]))}),{}):{}},U=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,a=r.admin,i=a.connectURL,o=a.adminRoot,c=r.setup.needReauthenticate,s=M(r)[t].screenID,u="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(b.a)(o,S({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},u));if(!c)return l;var f=encodeURIComponent(Object(v.a)(l));return l=o+"?"+f,Object(b.a)(i,{redirect:l,status:n})},q=function(t,n){var r=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=S({page:t},n),Object(b.a)(r,n)},F=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},H=function(){var e=c()(i.a.mark((function e(t,n,r){var a,o,c,s,u=arguments;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=u.length>3&&void 0!==u[3]?u[3]:k.c,o=u.length>4&&void 0!==u[4]?u[4]:M,e.next=4,t.setModuleActive(n,r);case 4:return c=e.sent,(s=o())[n]&&(s[n].active=r),e.next=9,a("".concat(n,"_setup"),r?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",c);case 10:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),G=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(_.b)(e,t),1)},W=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(g.unescape)(t)};function B(t,n){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var c=r.createElement(y.a,{id:t,width:a,height:i,className:o});return n?c=r.createElement(y.a,{id:"".concat(t,"-disabled"),width:a,height:i,className:o}):"pagespeed-insights"===t&&(c=r.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:a,alt:"",className:o})),c}}function V(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix,a=n.isNetworkMode;return a?t:r+t}}).call(this,n(13),n(12))},50:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return p})),n.d(t,"c",(function(){return d}));var r=n(68),a=e._googlesitekitBaseData||{},i=a.isFirstAdmin,o=a.trackingAllowed,c={isFirstAdmin:i,trackingEnabled:a.trackingEnabled,trackingID:a.trackingID,referenceSiteURL:a.referenceSiteURL,userIDHash:a.userIDHash},s=Object(r.a)(c),u=s.enableTracking,l=s.disableTracking,f=s.isTrackingEnabled,d=s.trackEvent;function p(e){e?u():l()}!0===o&&p(f())}).call(this,n(13))},52:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(36);function a(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return a}));var r=n(78),a=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:r.a.sanitize(e,t)}}},55:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return s})),n.d(t,"b",(function(){return u})),n.d(t,"c",(function(){return f}));var r=n(35),a=n.n(r),i=n(0);function o(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,s=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){s=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(s)throw i}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var s=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,n=null,r=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),a=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(r&&a)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),n=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===n)return!1;var o=document.createElement("span");o.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var c=document.createElement("span");c.setAttribute("class","plugin-count"),c.setAttribute("aria-hidden","true"),c.textContent=e;var s=document.createElement("span");return s.setAttribute("class","screen-reader-text"),s.textContent=Object(i.sprintf)(
16
  /* translators: %d is the number of notifications */
17
+ Object(i._n)("%d notification","%d notifications",e,"google-site-kit"),e),o.appendChild(c),o.appendChild(s),t&&null===r&&t.appendChild(o),n&&null===a&&n.appendChild(o),o},u=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),n={},r=0;r<t.length;r++)n[t[r].split("=")[0]]=decodeURIComponent(t[r].split("=")[1]);return e?n.hasOwnProperty(e)?decodeURIComponent(n[e].replace(/\+/g," ")):"":n},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,n=new URL(t.href);if(e)return n.searchParams&&n.searchParams.get?n.searchParams.get(e):l(e);var r,i={},c=o(n.searchParams.entries());try{for(c.s();!(r=c.n()).done;){var s=a()(r.value,2),u=s[0],f=s[1];i[u]=f}}catch(e){c.e(e)}finally{c.f()}return i}}).call(this,n(13))},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(32),a=n.n(r),i=n(106),o=n.n(i),c=function(e){return o()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(r){var i=t[r];i&&"object"===a()(i)&&!Array.isArray(i)&&(i=e(i)),n[r]=i})),n}(e)))}},62:function(e,t,n){"use strict";n.d(t,"b",(function(){return c})),n.d(t,"c",(function(){return s})),n.d(t,"a",(function(){return u}));var r=n(0),a=n(8),i=n.n(a),o=n(20);function c(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:s(),t=e.match(/last-(\d+)-days/);if(t&&t[1])return Object(r.sprintf)(
18
  /* translators: %s: Number of days matched. */
19
  Object(r._n)("%s day","%s days",parseInt(t[1],10),"google-site-kit"),t[1]);throw new Error("Unrecognized date range slug.")}function s(){return i.a.select(o.c).getDateRange()}function u(){
20
  /* translators: %s: Number of days to request data. */
21
+ var e=Object(r.__)("Last %s days","google-site-kit");return{"last-7-days":{slug:"last-7-days",label:Object(r.sprintf)(e,7)},"last-14-days":{slug:"last-14-days",label:Object(r.sprintf)(e,14)},"last-28-days":{slug:"last-28-days",label:Object(r.sprintf)(e,28)},"last-90-days":{slug:"last-90-days",label:Object(r.sprintf)(e,90)}}}},63:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return s}));var r=n(45),a=n.n(r),i=n(15),o=n(0);function c(){Object(o.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var s=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?u():n,i=a()(t,["locale"]);return new Intl.NumberFormat(r,i).format(e)},u=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(i.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(13))},630:function(e,t,n){"use strict";n.r(t),function(e){var t=n(1),r=n(152),a=n(5),i=(n(236),n(447)),o=n(139);Object(r.a)((function(){var n=document.getElementById("js-googlesitekit-activation");n&&(Object(a.o)(),Object(a.w)("plugin_setup","plugin_activated"),Object(t.k)(e.createElement(o.a,{dataAPIContext:"Activation"},e.createElement(i.a,null)),n),n.classList.remove("googlesitekit-activation--loading"))}))}.call(this,n(12))},65:function(e,t,n){"use strict";(function(e){var r=n(26),a=n.n(r),i=n(109),o=e._googlesitekitAPIFetchData||{},c=o.nonce,s=o.nonceEndpoint,u=o.preloadedData,l=o.rootURL;a.a.nonceEndpoint=s,a.a.nonceMiddleware=a.a.createNonceMiddleware(c),a.a.rootURLMiddleware=a.a.createRootURLMiddleware(l),a.a.preloadingMiddleware=Object(i.a)(u),a.a.use(a.a.nonceMiddleware),a.a.use(a.a.mediaUploadMiddleware),a.a.use(a.a.rootURLMiddleware),a.a.use(a.a.preloadingMiddleware),t.default=a.a}).call(this,n(13))},67:function(e,t,n){"use strict";n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return a}));var r=function(e){return e.charAt(0).toUpperCase()+e.slice(1)},a=function(e){return e.replace(/([a-z0-9]{1})([A-Z]{1})/g,"$1_$2").toUpperCase()}},68:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n(11),a=n.n(r),i=n(69),o=n(70);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var u={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,r=s(s({},u),t);return r.referenceSiteURL&&(r.referenceSiteURL=r.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(i.a)(r,n),disableTracking:function(){r.trackingEnabled=!1},isTrackingEnabled:function(){return!!r.trackingEnabled},trackEvent:Object(o.a)(r,n)}}}).call(this,n(13))},69:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var r=n(52),a=n(36);function i(t,n){var i=Object(r.a)(n);return function(){t.trackingEnabled=!0;var n=e.document;if(!n.querySelector("script[".concat(a.b,"]"))){var r=n.createElement("script");r.setAttribute(a.b,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(a.a),n.head.appendChild(r),i("js",new Date),i("config",t.trackingID)}}}}).call(this,n(13))},70:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(3),a=n.n(r),i=n(11),o=n.n(i),c=n(14),s=n.n(c),u=n(52);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(t,n){var r=Object(u.a)(n);return function(){var n=s()(a.a.mark((function n(i,o){var c,s,u,l,d,p,g,h,m=arguments;return a.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(c=m.length>2&&void 0!==m[2]?m[2]:"",s=m.length>3&&void 0!==m[3]?m[3]:"",u=t.isFirstAdmin,l=t.referenceSiteURL,d=t.trackingEnabled,p=t.trackingID,g=t.userIDHash,d){n.next=5;break}return n.abrupt("return");case 5:return h={send_to:p,event_category:i,event_label:c,event_value:s,dimension1:l,dimension2:u?"true":"false",dimension3:g},n.abrupt("return",new Promise((function(t){var n=setTimeout((function(){e.console.warn('Tracking event "'.concat(o,'" (category "').concat(i,'") took too long to fire.')),t()}),1e3);r("event",o,f(f({},h),{},{event_callback:function(){clearTimeout(n),t()}}))})));case 7:case"end":return n.stop()}}),n)})));return function(e,t){return n.apply(this,arguments)}}()}}).call(this,n(13))},72:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return a}));var r="core",a="modules"},74:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return g})),n.d(t,"d",(function(){return h})),n.d(t,"a",(function(){return m})),n.d(t,"c",(function(){return b}));var r=n(3),a=n.n(r),i=n(14),o=n.n(i);n(73);function c(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return s(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return s(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,a=function(){};return{s:a,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:a}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,o=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return o=e.done,e},e:function(e){c=!0,i=e},f:function(){try{o||null==n.return||n.return()}finally{if(c)throw i}}}}function s(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var u,l=["sessionStorage","localStorage"],f=[].concat(l),d=function(){var t=o()(a.a.mark((function t(n){var r,i;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,i="__storage_test__",r.setItem(i,i),r.removeItem(i),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==r.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),p=function(){var t=o()(a.a.mark((function t(){var n,r,i;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==u){t.next=25;break}n=c(f),t.prev=4,n.s();case 6:if((r=n.n()).done){t.next=16;break}if(i=r.value,!u){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,d(i);case 12:if(!t.sent){t.next=14;break}u=e[i];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===u&&(u=null);case 25:return t.abrupt("return",u);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),g=function(){var e=o()(a.a.mark((function e(t){var n,r,i,o,c=arguments;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=c.length>1&&void 0!==c[1]?c[1]:null,e.next=3,p();case 3:if(!(r=e.sent)){e.next=10;break}if(!(i=r.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(o=JSON.parse(i)).timestamp||!(null===n||Math.round(Date.now()/1e3)-o.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:o.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),h=function(){var t=o()(a.a.mark((function t(n,r){var i,o,c=arguments;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=c.length>2&&void 0!==c[2]?c[2]:void 0,t.next=3,p();case 3:if(!(o=t.sent)){t.next=14;break}return t.prev=5,o.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:i||Math.round(Date.now()/1e3),value:r})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),m=function(){var t=o()(a.a.mark((function t(n){var r;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,p();case 2:if(!(r=t.sent)){t.next=13;break}return t.prev=4,r.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),b=function(){var t=o()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,p();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,r=[],i=0;i<n.length;i++)0===(o=n.key(i)).indexOf("googlesitekit_")&&r.push(o.substring("googlesitekit_".length));return t.abrupt("return",r);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:case"end":return t.stop()}}),t,null,[[4,10]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(13))},78:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var r=n(105),a=n.n(r)()(e)}).call(this,n(13))},79:function(e,t,n){"use strict";(function(e){n.d(t,"g",(function(){return g})),n.d(t,"f",(function(){return h})),n.d(t,"c",(function(){return m})),n.d(t,"b",(function(){return k})),n.d(t,"d",(function(){return O})),n.d(t,"e",(function(){return w})),n.d(t,"a",(function(){return E}));var r=n(3),a=n.n(r),i=n(14),o=n.n(i),c=n(16),s=n(15),u=n(5),l=n(161),f=n(17),d=n(29),p=Object(c.c)("googlesitekit.winCallbacks",{}),g=function(){return Object(c.c)("googlesitekit.WinsNotificationsRequest",[])},h=function(){return Object(c.c)("googlesitekit.ModulesNotificationsRequest",[])};function m(){return b.apply(this,arguments)}function b(){return(b=o()(a.a.mark((function t(){var n,r,i,o;return a.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if((n=e._googlesitekitLegacyData.setup).isSiteKitConnected&&(n.isAuthenticated||n.isVerified)){t.next=3;break}return t.abrupt("return",0);case 3:return r=0,t.next=6,k();case 6:return(i=t.sent)&&i.total&&(r+=i.total),t.next=10,O();case 10:return(o=t.sent)&&o.total&&(r+=o.total),r=Object(c.c)("googlesitekit.TotalNotifications",r),r=Math.max(0,Math.abs(r)),e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",r),t.abrupt("return",r);case 16:case"end":return t.stop()}}),t)})))).apply(this,arguments)}var v=function(e){return e?e.length?e.filter((function(e){return!Object(d.b)("notification::dismissed::".concat(e.id))})):e:[]},y=function(e){var t=function(e){return Object.keys(e).slice(0,1).map((function(t){return e[t]}))};if(1>=Object.keys(e).length)return e;var n=Object.values(e).filter((function(e){var t=Object(d.b)("notification::displayed::".concat(e[0].id));if(t){var n=new Date(t),r=new Date,a=new Date(Date.UTC(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()));if(n.setHours(0,0,0),a.setHours(0,0,0),n.getTime()===a.getTime())return!0;7<=Object(u.h)(n,a)&&Object(d.a)("notification::displayed::".concat(e[0].id))}return null===t})),r=null,a=[];return 0<Object.keys(n).length?(r=t(n),a[Object.keys(n)[0]]=r):(r=t(e),a[Object.keys(e)[0]]=r)};function k(){return _.apply(this,arguments)}function _(){return(_=o()(a.a.mark((function e(){var t,n,r,i;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={},n=0,e.next=4,h();case 4:return r=e.sent,i=[],r.map(function(){var e=o()(a.a.mark((function e(t){var n;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=new Promise(function(){var e=o()(a.a.mark((function e(n){var r,i;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r=t.identifier,e.t0=v,e.next=4,f.c.get(f.b,r,"notifications",{},!1);case 4:e.t1=e.sent,i=(0,e.t0)(e.t1),n({identifier:r,notifications:i});case 7:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),i.push(n);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),e.next=9,Promise.all(i).then((function(e){e.forEach((function(e){e.notifications.length&&(n+=e.notifications.length,t[e.identifier]=e.notifications)}))}));case 9:return e.abrupt("return",{results:t,total:n});case 10:case"end":return e.stop()}}),e)})))).apply(this,arguments)}function O(){return j.apply(this,arguments)}function j(){return(j=o()(a.a.mark((function e(){var t,n,r,i,c;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t={},n=0,e.next=4,g();case 4:return r=e.sent,e.next=7,new l.a(r).get();case 7:return i=e.sent,c=[],r.map(function(){var e=o()(a.a.mark((function e(t){var n;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:n=new Promise(function(){var e=o()(a.a.mark((function e(n){var r,o,c,u,l;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:r=t.identifier,o=t.callback||Object(s.camelCase)(r),c=null,u=[],t.withData?(l=i[r]||null,c=p[o](l,r)):c=p[o](r),u=v(u=c?[c]:[]),n({identifier:r,notifications:u});case 8:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),c.push(n);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}()),e.next=12,Promise.all(c).then((function(e){e.forEach((function(e){e.notifications.length&&(t[e.identifier]=e.notifications)}))}));case 12:return t=y(t),n=t.length||Object.keys(t).length||0,e.abrupt("return",{results:t,total:n});case 15:case"end":return e.stop()}}),e)})))).apply(this,arguments)}var w=function(t){var n=Math.abs(t.count)+1;return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}},E=function(t){var n=Math.max(0,Math.abs(t.count)-1);return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}}}).call(this,n(13))},8:function(e,t){e.exports=googlesitekit.data},82:function(e,t,n){"use strict";(function(e){var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(1),g=n(2),h=n.n(g),m=n(18),b=n.n(m),v=n(0),y=n(28);function k(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var _=function(t){s()(SourceLink,t);var n=k(SourceLink);function SourceLink(){return a()(this,SourceLink),n.apply(this,arguments)}return o()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,r=t.href,a=t.className,i=t.external;return e.createElement("div",{className:b()("googlesitekit-source-link",a)},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(y.a,{key:"link",href:r,external:i,inherit:!0},n)])}}]),SourceLink}(p.a);_.propTypes={name:h.a.string,href:h.a.string,className:h.a.string,external:h.a.bool},_.defaultProps={name:"",href:"",className:"",external:!1},t.a=_}).call(this,n(12))},87:function(e,t,n){"use strict";n.d(t,"a",(function(){return b})),n.d(t,"c",(function(){return y})),n.d(t,"b",(function(){return k}));var r=n(45),a=n.n(r),i=n(11),o=n.n(i),c=n(3),s=n.n(c),u=n(19),l=n.n(u),f=n(8),d=n.n(f),p=n(74);function g(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function h(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?g(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var m=d.a.createRegistryControl,b=function(e){var t;l()(e,"storeName is required to create a snapshot store.");var n={},r={deleteSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"DELETE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)})),restoreSnapshot:s.a.mark((function e(){var t,n,r,a,i,o,c=arguments;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return t=c.length>0&&void 0!==c[0]?c[0]:{},n=t.clearAfterRestore,r=void 0===n||n,e.next=4,{payload:{},type:"RESTORE_SNAPSHOT"};case 4:if(a=e.sent,i=a.cacheHit,o=a.value,!i){e.next=13;break}return e.next=10,{payload:{snapshot:o},type:"SET_STATE_FROM_SNAPSHOT"};case 10:if(!r){e.next=13;break}return e.next=13,{payload:{},type:"DELETE_SNAPSHOT"};case 13:return e.abrupt("return",i);case 14:case"end":return e.stop()}}),e)})),createSnapshot:s.a.mark((function e(){var t;return s.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,{payload:{},type:"CREATE_SNAPSHOT"};case 2:return t=e.sent,e.abrupt("return",t);case 4:case"end":return e.stop()}}),e)}))},i=(t={},o()(t,"DELETE_SNAPSHOT",(function(){return Object(p.a)("datastore::cache::".concat(e))})),o()(t,"CREATE_SNAPSHOT",m((function(t){return function(){return Object(p.d)("datastore::cache::".concat(e),t.stores[e].store.getState())}}))),o()(t,"RESTORE_SNAPSHOT",(function(){return Object(p.b)("datastore::cache::".concat(e),3600)})),t);return{INITIAL_STATE:n,actions:r,controls:i,reducer:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:n,t=arguments.length>1?arguments[1]:void 0,r=t.type,i=t.payload;switch(r){case"SET_STATE_FROM_SNAPSHOT":var o=i.snapshot,c=(o.error,a()(o,["error"]));return h({},c);default:return h({},e)}}}},v=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Object.values(e.stores).filter((function(e){return Object.keys(e.getActions()).includes("restoreSnapshot")}))},y=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Promise.all(v(e).map((function(e){return e.getActions().createSnapshot()})))},k=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:d.a;return Promise.all(v(e).map((function(e){return e.getActions().restoreSnapshot()})))}},93:function(e,t,n){"use strict";var r=n(6),a=n.n(r),i=n(7),o=n.n(i),c=n(9),s=n.n(c),u=n(10),l=n.n(u),f=n(4),d=n.n(f),p=n(85);function g(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=d()(e);if(t){var a=d()(this).constructor;n=Reflect.construct(r,arguments,a)}else n=r.apply(this,arguments);return l()(this,n)}}var h=function(e){s()(ModuleSettingsWarning,e);var t=g(ModuleSettingsWarning);function ModuleSettingsWarning(){return a()(this,ModuleSettingsWarning),t.apply(this,arguments)}return o()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(n(1).a);t.a=Object(p.a)("googlesitekit.ModuleSettingsWarning")(h)},96:function(e,t,n){"use strict";n.d(t,"a",(function(){return f.c}));var r=n(8),a=n.n(r),i=n(3),o=n.n(i),c=n(11),s=n.n(c),u=n(41),l=n.n(u),f=n(20),d=n(43);function p(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?p(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):p(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var h=a.a.createRegistrySelector,m=Object(d.a)({baseName:"getAuthentication",controlCallback:function(){return l.a.get("core","user","authentication",void 0,{useCache:!1})},reducerCallback:function(e,t){return g(g({},e),{},{authentication:t})}}),b={authentication:void 0},v={getAuthentication:o.a.mark((function e(){var t;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.a.commonActions.getRegistry();case 2:if(t=e.sent,(0,t.select)(f.c).getAuthentication()){e.next=7;break}return e.next=7,m.actions.fetchGetAuthentication();case 7:case"end":return e.stop()}}),e)}))},y={getAuthentication:function(e){return e.authentication},hasScope:h((function(e){return function(t,n){var r=e(f.c).getGrantedScopes(t);if(void 0!==r)return r.includes(n)}})),isAuthenticated:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).authenticated}})),getGrantedScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).grantedScopes}})),getRequiredScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).requiredScopes}})),getUnsatisfiedScopes:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).unsatisfiedScopes}})),needsReauthentication:h((function(e){return function(){return(e(f.c).getAuthentication()||{}).needsReauthentication}}))},k=a.a.combineStores(m,{INITIAL_STATE:b,resolvers:v,selectors:y}),_=(k.INITIAL_STATE,k.actions,k.controls,k.reducer,k.resolvers,k.selectors,k),O=n(19),j=n.n(O);function w(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function E(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?w(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):w(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var D={INITIAL_STATE:{dateRange:"last-28-days"},actions:{setDateRange:function(e){return j()(e,"Date range slug is required."),{type:"SET_DATE_RANGE",payload:{slug:e}}}},controls:{},reducer:function(e,t){var n=t.type,r=t.payload;switch(n){case"SET_DATE_RANGE":return E(E({},e),{},{dateRange:r.slug});default:return E({},e)}},resolvers:{},selectors:{getDateRange:function(e){return e.dateRange}}};function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function R(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var x=a.a.createRegistrySelector,P=Object(d.a)({baseName:"disconnect",controlCallback:function(){return l.a.set("core","user","disconnect")},reducerCallback:function(e,t){return R(R({},e),{},{disconnected:t})}}),N={disconnected:void 0},C={disconnect:o.a.mark((function e(){return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,P.actions.fetchDisconnect();case 2:case"end":return e.stop()}}),e)}))},A={isDoingDisconnect:x((function(e){return function(){return e(f.c).isFetchingDisconnect()}}))},L=a.a.combineStores(P,{INITIAL_STATE:N,actions:C,selectors:A}),I=(L.INITIAL_STATE,L.actions,L.controls,L.reducer,L.resolvers,L.selectors,L);function T(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}var M={INITIAL_STATE:{error:void 0},actions:{},controls:{},reducer:function(e){return function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?T(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):T(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e)},resolvers:{},selectors:{getError:function(e){return e.error}}},U=n(112),q=Object(U.a)("core","user","notifications",{server:!1}),F=n(122),H=n(123),G=a.a.combineStores(a.a.commonStore,_,D,I,M,q,F.a,H.a);G.INITIAL_STATE,G.actions,G.controls,G.reducer,G.resolvers,G.selectors;a.a.registerStore(f.c,G)},97:function(e,t,n){"use strict";(function(e,r){var a=n(35),i=n.n(a),o=(n(1),n(150)),c=n.n(o),s=n(0),u=n(8),l=n.n(u),f=n(38),d=n(5),p=n(20),g=l.a.useSelect,h={siteverification:"site-verification",webmasters:"search-console"};t.a=function DashboardAuthAlert(){var t,n,a,o,u,l=g((function(e){return e(p.c).getUnsatisfiedScopes()})),m=g((function(t){return t(p.c).getConnectURL({redirectURL:e.location.href})}));if(void 0===l||void 0===m)return null;switch(l.some((function(e){return!e.match(/^https:\/\/www.googleapis.com\/auth\//)}))?t="generic":(a=l,o=Object(d.j)(),t=(n=a.map((function(e){return e.match(/^https:\/\/www.googleapis.com\/auth\/([a-z]+)/)})).map((function(e){var t=i()(e,2)[1];return h[t]||t})).map((function(e){var t;return(null===(t=o[e])||void 0===t?void 0:t.name)||!1}))).some((function(e){return!1===e}))?"generic":1<(n=c()(n)).length?"multiple":"single"),t){case"multiple":
22
  /* translators: used between list items, there is a space after the comma. */
23
  var b=Object(s.__)(", ","google-site-kit");u=Object(s.sprintf)(
24
  /* translators: %s: List of product names */
25
  Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for: %s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n.join(b));break;case"single":u=Object(s.sprintf)(
26
  /* translators: %1$s: Product name */
27
+ Object(s.__)("Site Kit can’t access the relevant data from %1$s because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup for %1$s – make sure to approve all permissions at the authentication stage.","google-site-kit"),n[0]);break;case"generic":u=Object(s.__)("Site Kit can’t access all relevant data because you haven’t granted all permissions requested during setup. To use Site Kit, you’ll need to redo the setup – make sure to approve all permissions at the authentication stage.","google-site-kit")}return r.createElement(f.a,{id:"authentication error",title:Object(s.__)("Site Kit can’t access necessary data","google-site-kit"),description:u,format:"small",type:"win-error",isDismissable:!1,ctaLink:m,ctaLabel:Object(s.__)("Redo setup","google-site-kit")})}}).call(this,n(13),n(12))},99:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var r=n(40),a=n(29),i=function(t,n,i){var o=Object(a.c)(t,n,i);Object(a.d)(),Object.keys(e._googlesitekitLegacyData.admin.datacache).forEach((function(t){0!==t.indexOf(o+"::")&&t!==o||delete e._googlesitekitLegacyData.admin.datacache[t]})),Object.keys(Object(r.a)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(o,"::"))&&e!=="googlesitekit_".concat(o)||Object(r.a)().removeItem(e)}))}}).call(this,n(13))}});
dist/assets/js/googlesitekit-admin.js CHANGED
@@ -1,3 +1,3 @@
1
- !function(e){function t(t){for(var n,a,u=t[0],c=t[1],s=t[2],_=0,p=[];_<u.length;_++)a=u[_],Object.prototype.hasOwnProperty.call(o,a)&&o[a]&&p.push(o[a][0]),o[a]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(l&&l(t);p.length;)p.shift()();return i.push.apply(i,s||[]),r()}function r(){for(var e,t=0;t<i.length;t++){for(var r=i[t],n=!0,a=1;a<r.length;a++){var u=r[a];0!==o[u]&&(n=!1)}n&&(i.splice(t--,1),e=__webpack_require__(__webpack_require__.s=r[0]))}return e}var n={},o={6:0},i=[];function __webpack_require__(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.m=e,__webpack_require__.c=n,__webpack_require__.d=function(e,t,r){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(__webpack_require__.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)__webpack_require__.d(r,n,function(t){return e[t]}.bind(null,n));return r},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],u=a.push.bind(a);a.push=t,a=a.slice();for(var c=0;c<a.length;c++)t(a[c]);var l=u;i.push([640,0]),r()}({55:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return c})),r.d(t,"b",(function(){return l})),r.d(t,"c",(function(){return _}));var n=r(38),o=r.n(n),i=r(0);function a(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return u(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){c=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,r=null,n=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),o=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(n&&o)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),r=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===r)return!1;var a=document.createElement("span");a.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var u=document.createElement("span");u.setAttribute("class","plugin-count"),u.setAttribute("aria-hidden","true"),u.textContent=e;var c=document.createElement("span");return c.setAttribute("class","screen-reader-text"),c.textContent=Object(i.sprintf)(
2
  /* translators: %d is the number of notifications */
3
- Object(i._n)("%d notification","%d notifications",e,"google-site-kit"),e),a.appendChild(u),a.appendChild(c),t&&null===n&&t.appendChild(a),r&&null===o&&r.appendChild(a),a},l=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},s=function(e){for(var t=location.search.substr(1).split("&"),r={},n=0;n<t.length;n++)r[t[n].split("=")[0]]=decodeURIComponent(t[n].split("=")[1]);return e?r.hasOwnProperty(e)?decodeURIComponent(r[e].replace(/\+/g," ")):"":r},_=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,r=new URL(t.href);if(e)return r.searchParams&&r.searchParams.get?r.searchParams.get(e):s(e);var n,i={},u=a(r.searchParams.entries());try{for(u.s();!(n=u.n()).done;){var c=o()(n.value,2),l=c[0],_=c[1];i[l]=_}}catch(e){u.e(e)}finally{u.f()}return i}}).call(this,r(15))},640:function(e,t,r){"use strict";r.r(t),function(e){var t=r(55);if("toplevel_page_googlesitekit-dashboard"!==e.pagenow&&"site-kit_page_googlesitekit-splash"!==e.pagenow&&"admin_page_googlesitekit-splash"!==e.pagenow&&e.localStorage){var n=e.localStorage.getItem("googlesitekit::total-notifications")||0;Object(t.a)(n)}var o=document.querySelector("#wp-admin-bar-logout a");o||(o=document.querySelector(".sidebar__me-signout button")),o&&o.addEventListener("click",(function(){Object(t.b)()}))}.call(this,r(15))}});
1
+ !function(e){function t(t){for(var n,a,u=t[0],c=t[1],s=t[2],_=0,p=[];_<u.length;_++)a=u[_],Object.prototype.hasOwnProperty.call(o,a)&&o[a]&&p.push(o[a][0]),o[a]=0;for(n in c)Object.prototype.hasOwnProperty.call(c,n)&&(e[n]=c[n]);for(l&&l(t);p.length;)p.shift()();return i.push.apply(i,s||[]),r()}function r(){for(var e,t=0;t<i.length;t++){for(var r=i[t],n=!0,a=1;a<r.length;a++){var u=r[a];0!==o[u]&&(n=!1)}n&&(i.splice(t--,1),e=__webpack_require__(__webpack_require__.s=r[0]))}return e}var n={},o={6:0},i=[];function __webpack_require__(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.m=e,__webpack_require__.c=n,__webpack_require__.d=function(e,t,r){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(__webpack_require__.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)__webpack_require__.d(r,n,function(t){return e[t]}.bind(null,n));return r},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],u=a.push.bind(a);a.push=t,a=a.slice();for(var c=0;c<a.length;c++)t(a[c]);var l=u;i.push([637,0]),r()}({55:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return c})),r.d(t,"b",(function(){return l})),r.d(t,"c",(function(){return _}));var n=r(35),o=r.n(n),i=r(0);function a(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return u(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,o=function(){};return{s:o,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){c=!0,i=e},f:function(){try{a||null==r.return||r.return()}finally{if(c)throw i}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,r=null,n=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),o=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(n&&o)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),r=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===r)return!1;var a=document.createElement("span");a.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var u=document.createElement("span");u.setAttribute("class","plugin-count"),u.setAttribute("aria-hidden","true"),u.textContent=e;var c=document.createElement("span");return c.setAttribute("class","screen-reader-text"),c.textContent=Object(i.sprintf)(
2
  /* translators: %d is the number of notifications */
3
+ Object(i._n)("%d notification","%d notifications",e,"google-site-kit"),e),a.appendChild(u),a.appendChild(c),t&&null===n&&t.appendChild(a),r&&null===o&&r.appendChild(a),a},l=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},s=function(e){for(var t=location.search.substr(1).split("&"),r={},n=0;n<t.length;n++)r[t[n].split("=")[0]]=decodeURIComponent(t[n].split("=")[1]);return e?r.hasOwnProperty(e)?decodeURIComponent(r[e].replace(/\+/g," ")):"":r},_=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,r=new URL(t.href);if(e)return r.searchParams&&r.searchParams.get?r.searchParams.get(e):s(e);var n,i={},u=a(r.searchParams.entries());try{for(u.s();!(n=u.n()).done;){var c=o()(n.value,2),l=c[0],_=c[1];i[l]=_}}catch(e){u.e(e)}finally{u.f()}return i}}).call(this,r(13))},637:function(e,t,r){"use strict";r.r(t),function(e){var t=r(55);if("toplevel_page_googlesitekit-dashboard"!==e.pagenow&&"site-kit_page_googlesitekit-splash"!==e.pagenow&&"admin_page_googlesitekit-splash"!==e.pagenow&&e.localStorage){var n=e.localStorage.getItem("googlesitekit::total-notifications")||0;Object(t.a)(n)}var o=document.querySelector("#wp-admin-bar-logout a");o||(o=document.querySelector(".sidebar__me-signout button")),o&&o.addEventListener("click",(function(){Object(t.b)()}))}.call(this,r(13))}});
dist/assets/js/googlesitekit-adminbar-loader.js CHANGED
@@ -1,3 +1,3 @@
1
- !function(e){function t(t){for(var n,a,c=t[0],u=t[1],l=t[2],f=0,p=[];f<c.length;f++)a=c[f],Object.prototype.hasOwnProperty.call(i,a)&&i[a]&&p.push(i[a][0]),i[a]=0;for(n in u)Object.prototype.hasOwnProperty.call(u,n)&&(e[n]=u[n]);for(s&&s(t);p.length;)p.shift()();return o.push.apply(o,l||[]),r()}function r(){for(var e,t=0;t<o.length;t++){for(var r=o[t],n=!0,a=1;a<r.length;a++){var c=r[a];0!==i[c]&&(n=!1)}n&&(o.splice(t--,1),e=__webpack_require__(__webpack_require__.s=r[0]))}return e}var n={},i={7:0},o=[];function __webpack_require__(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.e=function(e){var t=[],r=i[e];if(0!==r)if(r)t.push(r[2]);else{var n=new Promise((function(t,n){r=i[e]=[t,n]}));t.push(r[2]=n);var o,a=document.createElement("script");a.charset="utf-8",a.timeout=120,__webpack_require__.nc&&a.setAttribute("nonce",__webpack_require__.nc),a.src=function(e){return __webpack_require__.p+""+({1:"chunk-googlesitekit-adminbar",28:"vendors~chunk-googlesitekit-adminbar"}[e]||e)+"-"+{1:"e1a01c9625180ff3775e",28:"e61be24cc25b48d3a4ac"}[e]+".js"}(e);var c=new Error;o=function(t){a.onerror=a.onload=null,clearTimeout(u);var r=i[e];if(0!==r){if(r){var n=t&&("load"===t.type?"missing":t.type),o=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+o+")",c.name="ChunkLoadError",c.type=n,c.request=o,r[1](c)}i[e]=void 0}};var u=setTimeout((function(){o({type:"timeout",target:a})}),12e4);a.onerror=a.onload=o,document.head.appendChild(a)}return Promise.all(t)},__webpack_require__.m=e,__webpack_require__.c=n,__webpack_require__.d=function(e,t,r){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(__webpack_require__.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)__webpack_require__.d(r,n,function(t){return e[t]}.bind(null,n));return r},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="",__webpack_require__.oe=function(e){throw console.error(e),e};var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],c=a.push.bind(a);a.push=t,a=a.slice();for(var u=0;u<a.length;u++)t(a[u]);var s=c;o.push([639,0]),r()}({11:function(e,t){e.exports=googlesitekit.data},35:function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return i}));var n="_googlesitekitDataLayer",i="data-googlesitekit-gtag"},41:function(e,t){e.exports=googlesitekit.api},50:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return f})),r.d(t,"b",(function(){return d})),r.d(t,"c",(function(){return p}));var n=r(66),i=e._googlesitekitBaseData||{},o=i.isFirstAdmin,a=i.trackingAllowed,c={isFirstAdmin:o,trackingEnabled:i.trackingEnabled,trackingID:i.trackingID,referenceSiteURL:i.referenceSiteURL,userIDHash:i.userIDHash},u=Object(n.a)(c),s=u.enableTracking,l=u.disableTracking,f=u.isTrackingEnabled,p=u.trackEvent;function d(e){e?s():l()}!0===a&&d(f())}).call(this,r(15))},52:function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(35);function i(e){return function(){e[n.a]=e[n.a]||[],e[n.a].push(arguments)}}},55:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return u})),r.d(t,"b",(function(){return s})),r.d(t,"c",(function(){return f}));var n=r(38),i=r.n(n),o=r(0);function a(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw o}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var u=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,r=null,n=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),i=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(n&&i)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),r=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===r)return!1;var a=document.createElement("span");a.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var c=document.createElement("span");c.setAttribute("class","plugin-count"),c.setAttribute("aria-hidden","true"),c.textContent=e;var u=document.createElement("span");return u.setAttribute("class","screen-reader-text"),u.textContent=Object(o.sprintf)(
2
  /* translators: %d is the number of notifications */
3
- Object(o._n)("%d notification","%d notifications",e,"google-site-kit"),e),a.appendChild(c),a.appendChild(u),t&&null===n&&t.appendChild(a),r&&null===i&&r.appendChild(a),a},s=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),r={},n=0;n<t.length;n++)r[t[n].split("=")[0]]=decodeURIComponent(t[n].split("=")[1]);return e?r.hasOwnProperty(e)?decodeURIComponent(r[e].replace(/\+/g," ")):"":r},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,r=new URL(t.href);if(e)return r.searchParams&&r.searchParams.get?r.searchParams.get(e):l(e);var n,o={},c=a(r.searchParams.entries());try{for(c.s();!(n=c.n()).done;){var u=i()(n.value,2),s=u[0],f=u[1];o[s]=f}}catch(e){c.e(e)}finally{c.f()}return o}}).call(this,r(15))},639:function(e,t,r){"use strict";r.r(t),function(e){var t=r(55),n=r(50);e.googlesitekitAdminbar&&e.googlesitekitAdminbar.publicPath&&(r.p=e.googlesitekitAdminbar.publicPath);var i=!1;function o(){Promise.all([r.e(28),r.e(1)]).then(r.bind(null,649)).then((function(e){return e})).catch((function(){return new Error("Site Kit: An error occurred while loading the Adminbar component files.")})).then((function(e){try{e.init()}catch(e){console.error("Site Kit: An error occurred while loading the Adminbar components."),document.getElementById("js-googlesitekit-adminbar").classList.add("googlesitekit-adminbar--has-error")}document.getElementById("js-googlesitekit-adminbar").classList.remove("googlesitekit-adminbar--loading")}))}e.addEventListener("load",(function(){var r=document.getElementById("wp-admin-bar-google-site-kit");if(r&&e.localStorage){var a=e.localStorage.getItem("googlesitekit::total-notifications")||0;Object(t.a)(a);var c=function(){i||(Object(n.c)("admin_bar","page_stats_view"),o(),i=!0)};"true"===Object(t.c)("googlesitekit_adminbar_open")?(c(),r.classList.add("hover")):r.addEventListener("mouseenter",c,!1)}}))}.call(this,r(15))},66:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return l}));var n=r(10),i=r.n(n),o=r(67),a=r(68);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){i()(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var s={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=u(u({},s),t);return n.referenceSiteURL&&(n.referenceSiteURL=n.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(o.a)(n,r),disableTracking:function(){n.trackingEnabled=!1},isTrackingEnabled:function(){return!!n.trackingEnabled},trackEvent:Object(a.a)(n,r)}}}).call(this,r(15))},67:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return o}));var n=r(52),i=r(35);function o(t,r){var o=Object(n.a)(r);return function(){t.trackingEnabled=!0;var r=e.document;if(!r.querySelector("script[".concat(i.b,"]"))){var n=r.createElement("script");n.setAttribute(i.b,""),n.async=!0,n.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(i.a),r.head.appendChild(n),o("js",new Date),o("config",t.trackingID)}}}}).call(this,r(15))},68:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return p}));var n=r(4),i=r.n(n),o=r(10),a=r.n(o),c=r(14),u=r.n(c),s=r(52);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){a()(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function p(t,r){var n=Object(s.a)(r);return function(){var r=u()(i.a.mark((function r(o,a){var c,u,s,l,p,d,g,b,_=arguments;return i.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(c=_.length>2&&void 0!==_[2]?_[2]:"",u=_.length>3&&void 0!==_[3]?_[3]:"",s=t.isFirstAdmin,l=t.referenceSiteURL,p=t.trackingEnabled,d=t.trackingID,g=t.userIDHash,p){r.next=5;break}return r.abrupt("return");case 5:return b={send_to:d,event_category:o,event_label:c,event_value:u,dimension1:l,dimension2:s?"true":"false",dimension3:g},r.abrupt("return",new Promise((function(t){var r=setTimeout((function(){e.console.warn('Tracking event "'.concat(a,'" (category "').concat(o,'") took too long to fire.')),t()}),1e3);n("event",a,f(f({},b),{},{event_callback:function(){clearTimeout(r),t()}}))})));case 7:case"end":return r.stop()}}),r)})));return function(e,t){return r.apply(this,arguments)}}()}}).call(this,r(15))}});
1
+ !function(e){function t(t){for(var n,a,c=t[0],u=t[1],l=t[2],f=0,d=[];f<c.length;f++)a=c[f],Object.prototype.hasOwnProperty.call(i,a)&&i[a]&&d.push(i[a][0]),i[a]=0;for(n in u)Object.prototype.hasOwnProperty.call(u,n)&&(e[n]=u[n]);for(s&&s(t);d.length;)d.shift()();return o.push.apply(o,l||[]),r()}function r(){for(var e,t=0;t<o.length;t++){for(var r=o[t],n=!0,a=1;a<r.length;a++){var c=r[a];0!==i[c]&&(n=!1)}n&&(o.splice(t--,1),e=__webpack_require__(__webpack_require__.s=r[0]))}return e}var n={},i={7:0},o=[];function __webpack_require__(t){if(n[t])return n[t].exports;var r=n[t]={i:t,l:!1,exports:{}};return e[t].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.e=function(e){var t=[],r=i[e];if(0!==r)if(r)t.push(r[2]);else{var n=new Promise((function(t,n){r=i[e]=[t,n]}));t.push(r[2]=n);var o,a=document.createElement("script");a.charset="utf-8",a.timeout=120,__webpack_require__.nc&&a.setAttribute("nonce",__webpack_require__.nc),a.src=function(e){return __webpack_require__.p+""+({1:"chunk-googlesitekit-adminbar",28:"vendors~chunk-googlesitekit-adminbar"}[e]||e)+"-"+{1:"7bc82ce2559c24c046ce",28:"ebed61d97952a2b9549f"}[e]+".js"}(e);var c=new Error;o=function(t){a.onerror=a.onload=null,clearTimeout(u);var r=i[e];if(0!==r){if(r){var n=t&&("load"===t.type?"missing":t.type),o=t&&t.target&&t.target.src;c.message="Loading chunk "+e+" failed.\n("+n+": "+o+")",c.name="ChunkLoadError",c.type=n,c.request=o,r[1](c)}i[e]=void 0}};var u=setTimeout((function(){o({type:"timeout",target:a})}),12e4);a.onerror=a.onload=o,document.head.appendChild(a)}return Promise.all(t)},__webpack_require__.m=e,__webpack_require__.c=n,__webpack_require__.d=function(e,t,r){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:r})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var r=Object.create(null);if(__webpack_require__.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var n in e)__webpack_require__.d(r,n,function(t){return e[t]}.bind(null,n));return r},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="",__webpack_require__.oe=function(e){throw console.error(e),e};var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],c=a.push.bind(a);a.push=t,a=a.slice();for(var u=0;u<a.length;u++)t(a[u]);var s=c;o.push([636,0]),r()}({36:function(e,t,r){"use strict";r.d(t,"a",(function(){return n})),r.d(t,"b",(function(){return i}));var n="_googlesitekitDataLayer",i="data-googlesitekit-gtag"},41:function(e,t){e.exports=googlesitekit.api},50:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return f})),r.d(t,"b",(function(){return p})),r.d(t,"c",(function(){return d}));var n=r(68),i=e._googlesitekitBaseData||{},o=i.isFirstAdmin,a=i.trackingAllowed,c={isFirstAdmin:o,trackingEnabled:i.trackingEnabled,trackingID:i.trackingID,referenceSiteURL:i.referenceSiteURL,userIDHash:i.userIDHash},u=Object(n.a)(c),s=u.enableTracking,l=u.disableTracking,f=u.isTrackingEnabled,d=u.trackEvent;function p(e){e?s():l()}!0===a&&p(f())}).call(this,r(13))},52:function(e,t,r){"use strict";r.d(t,"a",(function(){return i}));var n=r(36);function i(e){return function(){e[n.a]=e[n.a]||[],e[n.a].push(arguments)}}},55:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return u})),r.d(t,"b",(function(){return s})),r.d(t,"c",(function(){return f}));var n=r(35),i=r.n(n),o=r(0);function a(e,t){var r;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(r=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);"Object"===r&&e.constructor&&(r=e.constructor.name);if("Map"===r||"Set"===r)return Array.from(e);if("Arguments"===r||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){r&&(e=r);var n=0,i=function(){};return{s:i,n:function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(e){throw e},f:i}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var o,a=!0,u=!1;return{s:function(){r=e[Symbol.iterator]()},n:function(){var e=r.next();return a=e.done,e},e:function(e){u=!0,o=e},f:function(){try{a||null==r.return||r.return()}finally{if(u)throw o}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var u=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,r=null,n=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),i=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(n&&i)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),r=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===r)return!1;var a=document.createElement("span");a.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var c=document.createElement("span");c.setAttribute("class","plugin-count"),c.setAttribute("aria-hidden","true"),c.textContent=e;var u=document.createElement("span");return u.setAttribute("class","screen-reader-text"),u.textContent=Object(o.sprintf)(
2
  /* translators: %d is the number of notifications */
3
+ Object(o._n)("%d notification","%d notifications",e,"google-site-kit"),e),a.appendChild(c),a.appendChild(u),t&&null===n&&t.appendChild(a),r&&null===i&&r.appendChild(a),a},s=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),r={},n=0;n<t.length;n++)r[t[n].split("=")[0]]=decodeURIComponent(t[n].split("=")[1]);return e?r.hasOwnProperty(e)?decodeURIComponent(r[e].replace(/\+/g," ")):"":r},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,r=new URL(t.href);if(e)return r.searchParams&&r.searchParams.get?r.searchParams.get(e):l(e);var n,o={},c=a(r.searchParams.entries());try{for(c.s();!(n=c.n()).done;){var u=i()(n.value,2),s=u[0],f=u[1];o[s]=f}}catch(e){c.e(e)}finally{c.f()}return o}}).call(this,r(13))},636:function(e,t,r){"use strict";r.r(t),function(e){var t=r(55),n=r(50);e.googlesitekitAdminbar&&e.googlesitekitAdminbar.publicPath&&(r.p=e.googlesitekitAdminbar.publicPath);var i=!1;function o(){Promise.all([r.e(28),r.e(1)]).then(r.bind(null,647)).then((function(e){return e})).catch((function(){return new Error("Site Kit: An error occurred while loading the Adminbar component files.")})).then((function(e){try{e.init()}catch(e){console.error("Site Kit: An error occurred while loading the Adminbar components."),document.getElementById("js-googlesitekit-adminbar").classList.add("googlesitekit-adminbar--has-error")}document.getElementById("js-googlesitekit-adminbar").classList.remove("googlesitekit-adminbar--loading")}))}e.addEventListener("load",(function(){var r=document.getElementById("wp-admin-bar-google-site-kit");if(r&&e.localStorage){var a=e.localStorage.getItem("googlesitekit::total-notifications")||0;Object(t.a)(a);var c=function(){i||(Object(n.c)("admin_bar","page_stats_view"),o(),i=!0)};"true"===Object(t.c)("googlesitekit_adminbar_open")?(c(),r.classList.add("hover")):r.addEventListener("mouseenter",c,!1)}}))}.call(this,r(13))},68:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return l}));var n=r(11),i=r.n(n),o=r(69),a=r(70);function c(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function u(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?c(Object(r),!0).forEach((function(t){i()(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):c(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}var s={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,n=u(u({},s),t);return n.referenceSiteURL&&(n.referenceSiteURL=n.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(o.a)(n,r),disableTracking:function(){n.trackingEnabled=!1},isTrackingEnabled:function(){return!!n.trackingEnabled},trackEvent:Object(a.a)(n,r)}}}).call(this,r(13))},69:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return o}));var n=r(52),i=r(36);function o(t,r){var o=Object(n.a)(r);return function(){t.trackingEnabled=!0;var r=e.document;if(!r.querySelector("script[".concat(i.b,"]"))){var n=r.createElement("script");n.setAttribute(i.b,""),n.async=!0,n.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(i.a),r.head.appendChild(n),o("js",new Date),o("config",t.trackingID)}}}}).call(this,r(13))},70:function(e,t,r){"use strict";(function(e){r.d(t,"a",(function(){return d}));var n=r(3),i=r.n(n),o=r(11),a=r.n(o),c=r(14),u=r.n(c),s=r(52);function l(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function f(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?l(Object(r),!0).forEach((function(t){a()(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):l(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function d(t,r){var n=Object(s.a)(r);return function(){var r=u()(i.a.mark((function r(o,a){var c,u,s,l,d,p,g,b,_=arguments;return i.a.wrap((function(r){for(;;)switch(r.prev=r.next){case 0:if(c=_.length>2&&void 0!==_[2]?_[2]:"",u=_.length>3&&void 0!==_[3]?_[3]:"",s=t.isFirstAdmin,l=t.referenceSiteURL,d=t.trackingEnabled,p=t.trackingID,g=t.userIDHash,d){r.next=5;break}return r.abrupt("return");case 5:return b={send_to:p,event_category:o,event_label:c,event_value:u,dimension1:l,dimension2:s?"true":"false",dimension3:g},r.abrupt("return",new Promise((function(t){var r=setTimeout((function(){e.console.warn('Tracking event "'.concat(a,'" (category "').concat(o,'") took too long to fire.')),t()}),1e3);n("event",a,f(f({},b),{},{event_callback:function(){clearTimeout(r),t()}}))})));case 7:case"end":return r.stop()}}),r)})));return function(e,t){return r.apply(this,arguments)}}()}}).call(this,r(13))},8:function(e,t){e.exports=googlesitekit.data}});
dist/assets/js/googlesitekit-api.js CHANGED
@@ -1,6 +1,6 @@
1
- !function(e){function t(t){for(var r,i,c=t[0],u=t[1],l=t[2],f=0,d=[];f<c.length;f++)i=c[f],Object.prototype.hasOwnProperty.call(o,i)&&o[i]&&d.push(o[i][0]),o[i]=0;for(r in u)Object.prototype.hasOwnProperty.call(u,r)&&(e[r]=u[r]);for(s&&s(t);d.length;)d.shift()();return a.push.apply(a,l||[]),n()}function n(){for(var e,t=0;t<a.length;t++){for(var n=a[t],r=!0,i=1;i<n.length;i++){var c=n[i];0!==o[c]&&(r=!1)}r&&(a.splice(t--,1),e=__webpack_require__(__webpack_require__.s=n[0]))}return e}var r={},o={8:0},a=[];function __webpack_require__(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,__webpack_require__),n.l=!0,n.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)__webpack_require__.d(n,r,function(t){return e[t]}.bind(null,r));return n},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var i=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],c=i.push.bind(i);i.push=t,i=i.slice();for(var u=0;u<i.length;u++)t(i[u]);var s=c;a.push([564,0]),n()}({1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return i})),n.d(t,"a",(function(){return c})),n.d(t,"e",(function(){return s})),n.d(t,"f",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"h",(function(){return g})),n.d(t,"b",(function(){return h})),n.d(t,"i",(function(){return m})),n.d(t,"j",(function(){return _})),n.d(t,"k",(function(){return O})),n.d(t,"c",(function(){return E})),n.d(t,"l",(function(){return D})),n.d(t,"m",(function(){return A})),n.d(t,"n",(function(){return C})),n.d(t,"o",(function(){return M})),n.d(t,"p",(function(){return N})),n.d(t,"q",(function(){return q})),n.d(t,"r",(function(){return T})),n.d(t,"s",(function(){return L}));var r=n(96);void 0===e.googlesitekit&&(e.googlesitekit={});var o=e.googlesitekit._element||r,a=o.Children,i=o.cloneElement,c=o.Component,u=o.concatChildren,s=o.createContext,l=o.createElement,f=o.createInterpolateElement,d=o.createPortal,g=o.createRef,p=o.findDOMNode,v=o.forwardRef,h=o.Fragment,b=o.isEmptyElement,m=o.isValidElement,_=o.lazy,y=o.memo,k=o.Platform,w=o.RawHTML,O=o.render,j=o.renderToString,S=o.StrictMode,E=o.Suspense,x=o.switchChildrenNodeName,P=o.unmountComponentAtNode,D=o.useCallback,A=o.useContext,I=o.useDebugValue,C=o.useEffect,R=o.useImperativeHandle,M=o.useLayoutEffect,N=o.useMemo,q=o.useReducer,T=o.useRef,L=o.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:a,cloneElement:i,Component:c,concatChildren:u,createContext:s,createElement:l,createInterpolateElement:f,createPortal:d,createRef:g,findDOMNode:p,forwardRef:v,Fragment:h,isEmptyElement:b,isValidElement:m,lazy:_,memo:y,Platform:k,RawHTML:w,render:O,renderToString:j,StrictMode:S,Suspense:E,switchChildrenNodeName:x,unmountComponentAtNode:P,useCallback:D,useContext:A,useDebugValue:I,useEffect:C,useImperativeHandle:R,useLayoutEffect:M,useMemo:N,useReducer:q,useRef:T,useState:L})}).call(this,n(15))},106:function(e,t,n){"use strict";var r=n(98);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(r.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,o){if(n)return o(e);setTimeout((function(){n=!0}),1e3);var a=e.parse,i=void 0===a||a,c=e.path;if("string"==typeof e.path){var u,s=(null===(u=e.method)||void 0===u?void 0:u.toUpperCase())||"GET",l=Object(r.getStablePath)(c);if(i&&"GET"===s&&t[l]){var f=Promise.resolve(t[l].body);return delete t[l],f}if("OPTIONS"===s&&t[s]&&t[s][l]){var d=Promise.resolve(t[s][l]);return delete t[s][l],d}}return o(e)}}},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return i})),n.d(t,"f",(function(){return c})),n.d(t,"g",(function(){return u})),n.d(t,"e",(function(){return s})),n.d(t,"d",(function(){return g})),n.d(t,"c",(function(){return p}));var r=n(92);void 0===e.googlesitekit&&(e.googlesitekit={});var o=e.googlesitekit._hooks||r,a=o.addAction,i=o.addFilter,c=o.removeAction,u=o.removeFilter,s=o.hasAction,l=o.hasFilter,f=o.removeAllActions,d=o.removeAllFilters,g=o.doAction,p=o.applyFilters,v=o.currentAction,h=o.currentFilter,b=o.doingAction,m=o.doingFilter,_=o.didAction,y=o.didFilter,k=o.actions,w=o.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:a,addFilter:i,removeAction:c,removeFilter:u,hasAction:s,hasFilter:l,removeAllActions:f,removeAllFilters:d,doAction:g,applyFilters:p,currentAction:v,currentFilter:h,doingAction:b,doingFilter:m,didAction:_,didFilter:y,actions:k,filters:w})}).call(this,n(15))},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return a}));var r="core/user",o="googlesitekit_manage_options",a="missing_required_scopes"},23:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return c}));var r=n(81),o=n.n(r),a=n(1),i=function(e){return function(t){return function FilteredComponent(n){return Object(a.f)(a.b,{},"",Object(a.f)(t,n),e)}}},c=function(t,n){return function(r){return function InnerComponent(a){return e.createElement(t,o()({},a,n,{OriginalComponent:r}))}}}}).call(this,n(12))},338:function(e,t,n){"use strict";(function(e){var r=n(4),o=n.n(r),a=n(14),i=n.n(a),c=n(19),u=n.n(c),s=n(63),l=n(45),f=n(72),d=n(5),g=n(20),p=!0,v=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=[e,t,n].filter((function(e){return!!e&&e.length}));return 3===o.length&&r&&r.constructor===Object&&Object.keys(r).length&&o.push(Object(d.v)(r)),o.join("::")},h=function(){var t=i()(o.a.mark((function t(n,r,a){var i,c,d,p,h,b,m,y,k,w,O,j,S,E,x,P,D,A,I=arguments;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(i=I.length>3&&void 0!==I[3]?I[3]:{},c=i.bodyParams,d=i.cacheTTL,p=void 0===d?3600:d,h=i.method,b=void 0===h?"GET":h,m=i.queryParams,y=i.useCache,k=void 0===y?void 0:y,u()(n,"`type` argument for requests is required."),u()(r,"`identifier` argument for requests is required."),u()(a,"`datapoint` argument for requests is required."),w="GET"===b&&(void 0!==k?k:_()),O=v(n,r,a,m),!w){t.next=14;break}return t.next=9,Object(f.b)(O,p);case 9:if(j=t.sent,S=j.cacheHit,E=j.value,!S){t.next=14;break}return t.abrupt("return",E);case 14:return t.prev=14,t.next=17,Object(s.default)({data:c,method:b,path:Object(l.a)("/google-site-kit/v1/".concat(n,"/").concat(r,"/data/").concat(a),m)});case 17:if(x=t.sent,!w){t.next=21;break}return t.next=21,Object(f.d)(O,x);case 21:return t.abrupt("return",x);case 24:throw t.prev=24,t.t0=t.catch(14),t.t0.code===g.a&&(null===(P=e.googlesitekit)||void 0===P||null===(D=P.data)||void 0===D||null===(A=D.dispatch)||void 0===A?void 0:A.call(D,g.c))&&e.googlesitekit.data.dispatch(g.c).setPermissionScopeError(t.t0),e.console.error("Google Site Kit API Error",t.t0),t.t0;case 29:case"end":return t.stop()}}),t,null,[[14,24]])})));return function(e,n,r){return t.apply(this,arguments)}}(),b=function(){var e=i()(o.a.mark((function e(t,n,r,a){var i,c,u,s,l,f=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=f.length>4&&void 0!==f[4]?f[4]:{},c=i.cacheTTL,u=void 0===c?3600:c,s=i.useCache,l=void 0===s?void 0:s,e.abrupt("return",h(t,n,r,{cacheTTL:u,queryParams:a,useCache:l}));case 2:case"end":return e.stop()}}),e)})));return function(t,n,r,o){return e.apply(this,arguments)}}(),m=function(){var e=i()(o.a.mark((function e(t,n,r,a){var i,c,u,s,l,f,d=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=d.length>4&&void 0!==d[4]?d[4]:{},c=i.method,u=void 0===c?"POST":c,s=i.queryParams,l=void 0===s?{}:s,e.next=3,h(t,n,r,{bodyParams:{data:a},method:u,queryParams:l,useCache:!1});case 3:return f=e.sent,e.next=6,y(t,n,r);case 6:return e.abrupt("return",f);case 7:case"end":return e.stop()}}),e)})));return function(t,n,r,o){return e.apply(this,arguments)}}(),_=function(){return p},y=function(){var e=i()(o.a.mark((function e(t,n,r){var a;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=v(t,n,r),e.next=3,Object(f.c)();case 3:e.sent.forEach((function(e){0===e.indexOf(a)&&Object(f.a)(e)}));case 5:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),k={invalidateCache:y,get:b,set:m,setUsingCache:function(e){return p=!!e},usingCache:_};t.a=k}).call(this,n(15))},34:function(e,t,n){"use strict";(function(e,r){n(1);var o=n(2),a=n.n(o),i=n(18),c=n.n(i),u=function SvgIcon(t){var n=t.id,o=t.className,a=t.height,i=t.width,u="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:c()("svg",o),height:a,width:i},r.createElement("use",{xlinkHref:"".concat(u,"#").concat(n)}))};u.propTypes={id:a.a.string.isRequired,className:a.a.string,height:a.a.string,width:a.a.string},u.defaultProps={className:"",height:20,width:20},t.a=u}).call(this,n(15),n(12))},35:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return o}));var r="_googlesitekitDataLayer",o="data-googlesitekit-gtag"},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r,o=n(6),a=n.n(o),i=n(7),c=n.n(i),u=function(t){var n=e[t];if(!n)return!1;try{var r="__storage_test__";return n.setItem(r,r),n.removeItem(r),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},s=function(){function NullStorage(){a()(this,NullStorage)}return c()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),l=function(){return r||(r=u("sessionStorage")?e.sessionStorage:u("localStorage")?e.localStorage:new s),r}}).call(this,n(15))},5:function(e,t,n){"use strict";(function(e,r){n.d(t,"s",(function(){return D})),n.d(t,"q",(function(){return A})),n.d(t,"n",(function(){return C})),n.d(t,"r",(function(){return R})),n.d(t,"h",(function(){return M})),n.d(t,"c",(function(){return N})),n.d(t,"f",(function(){return q})),n.d(t,"j",(function(){return T})),n.d(t,"l",(function(){return L})),n.d(t,"m",(function(){return F})),n.d(t,"x",(function(){return U})),n.d(t,"b",(function(){return H})),n.d(t,"u",(function(){return J})),n.d(t,"e",(function(){return G})),n.d(t,"p",(function(){return Q})),n.d(t,"i",(function(){return V}));var o=n(4),a=n.n(o),i=n(14),c=n.n(i),u=n(10),s=n.n(u),l=n(44),f=n.n(l),d=n(33),g=n.n(d),p=(n(1),n(13)),v=n(16),h=n(0),b=n(45),m=n(142),_=n(34);n.d(t,"a",(function(){return _.a}));var y=n(50);n.d(t,"w",(function(){return y.c}));var k=n(23),w=n(54);n.d(t,"t",(function(){return w.a}));var O=n(56);n.d(t,"v",(function(){return O.a}));var j=n(55);n.d(t,"d",(function(){return j.b})),n.d(t,"k",(function(){return j.c}));n(40);var S=n(60);function E(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?E(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):E(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return S.a})),n.d(t,"g",(function(){return k.b}));var P=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},D=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(p.isFinite)(e)?e:Number(e),Object(p.isFinite)(e)||(console.warn("Invalid number",e,g()(e)),e=0),t)return A(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in millions.
2
- Object(h.__)("%sM","google-site-kit"),A(P(e),e%10==0?{}:n)):1e4<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in thousands.
3
- Object(h.__)("%sK","google-site-kit"),A(P(e))):1e3<=e?Object(h.sprintf)(// translators: %s: an abbreviated number in thousands.
4
- Object(h.__)("%sK","google-site-kit"),A(P(e),e%10==0?{}:n)):e.toString()},A=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?I():n,o=f()(t,["locale"]);return new Intl.NumberFormat(r,o).format(e)},I=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(p.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language},C=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},R=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},M=function(e,t){var n=1e3*C("day"),r=e.getTime(),o=t.getTime();return Math.round(Math.abs(r-o)/n)},N=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},q=function(e,t){return Object(p.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},T=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==g()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:x(x({},e),{},s()({},t,n[t]))}),{}):{}},L=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,o=r.admin,a=o.connectURL,i=o.adminRoot,c=r.setup.needReauthenticate,u=T(r)[t].screenID,s="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(b.a)(i,x({page:t&&n&&u?u:"googlesitekit-dashboard",slug:t,reAuth:n},s));if(!c)return l;var f=encodeURIComponent(Object(m.a)(l));return l=i+"?"+f,Object(b.a)(a,{redirect:l,status:n})},F=function(t,n){var r=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=x({page:t},n),Object(b.a)(r,n)},U=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},H=function(){var e=c()(a.a.mark((function e(t,n,r){var o,i,c,u,s=arguments;return a.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=s.length>3&&void 0!==s[3]?s[3]:y.c,i=s.length>4&&void 0!==s[4]?s[4]:T,e.next=4,t.setModuleActive(n,r);case 4:return c=e.sent,(u=i())[n]&&(u[n].active=r),e.next=9,o("".concat(n,"_setup"),r?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",c);case 10:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),J=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(v.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(k.b)(e,t),1)},G=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(p.unescape)(t)};function Q(t,n){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var c=r.createElement(_.a,{id:t,width:o,height:a,className:i});return n?c=r.createElement(_.a,{id:"".concat(t,"-disabled"),width:o,height:a,className:i}):"pagespeed-insights"===t&&(c=r.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:o,alt:"",className:i})),c}}function V(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix,o=n.isNetworkMode;return o?t:r+t}}).call(this,n(15),n(12))},50:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return g})),n.d(t,"c",(function(){return d}));var r=n(66),o=e._googlesitekitBaseData||{},a=o.isFirstAdmin,i=o.trackingAllowed,c={isFirstAdmin:a,trackingEnabled:o.trackingEnabled,trackingID:o.trackingID,referenceSiteURL:o.referenceSiteURL,userIDHash:o.userIDHash},u=Object(r.a)(c),s=u.enableTracking,l=u.disableTracking,f=u.isTrackingEnabled,d=u.trackEvent;function g(e){e?s():l()}!0===i&&g(f())}).call(this,n(15))},52:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(35);function o(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(76),o=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:r.a.sanitize(e,t)}}},55:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return s})),n.d(t,"c",(function(){return f}));var r=n(38),o=n.n(r),a=n(0);function i(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,u=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){u=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(u)throw a}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var u=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,n=null,r=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),o=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(r&&o)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),n=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===n)return!1;var i=document.createElement("span");i.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var c=document.createElement("span");c.setAttribute("class","plugin-count"),c.setAttribute("aria-hidden","true"),c.textContent=e;var u=document.createElement("span");return u.setAttribute("class","screen-reader-text"),u.textContent=Object(a.sprintf)(
5
  /* translators: %d is the number of notifications */
6
- Object(a._n)("%d notification","%d notifications",e,"google-site-kit"),e),i.appendChild(c),i.appendChild(u),t&&null===r&&t.appendChild(i),n&&null===o&&n.appendChild(i),i},s=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),n={},r=0;r<t.length;r++)n[t[r].split("=")[0]]=decodeURIComponent(t[r].split("=")[1]);return e?n.hasOwnProperty(e)?decodeURIComponent(n[e].replace(/\+/g," ")):"":n},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,n=new URL(t.href);if(e)return n.searchParams&&n.searchParams.get?n.searchParams.get(e):l(e);var r,a={},c=i(n.searchParams.entries());try{for(c.s();!(r=c.n()).done;){var u=o()(r.value,2),s=u[0],f=u[1];a[s]=f}}catch(e){c.e(e)}finally{c.f()}return a}}).call(this,n(15))},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return c}));var r=n(33),o=n.n(r),a=n(102),i=n.n(a),c=function(e){return i()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(r){var a=t[r];a&&"object"===o()(a)&&!Array.isArray(a)&&(a=e(a)),n[r]=a})),n}(e)))}},564:function(e,t,n){"use strict";n.r(t),function(e){var r=n(338);void 0===e.googlesitekit&&(e.googlesitekit={}),void 0===e.googlesitekit.api&&(e.googlesitekit.api=r.a),t.default=r.a}.call(this,n(15))},60:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return u}));var r=n(44),o=n.n(r),a=n(13),i=n(0);function c(){Object(i.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var u=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?s():n,a=o()(t,["locale"]);return new Intl.NumberFormat(r,a).format(e)},s=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(a.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(15))},63:function(e,t,n){"use strict";(function(e){var r=n(26),o=n.n(r),a=n(106),i=e._googlesitekitAPIFetchData||{},c=i.nonce,u=i.nonceEndpoint,s=i.preloadedData,l=i.rootURL;o.a.nonceEndpoint=u,o.a.nonceMiddleware=o.a.createNonceMiddleware(c),o.a.rootURLMiddleware=o.a.createRootURLMiddleware(l),o.a.preloadingMiddleware=Object(a.a)(s),o.a.use(o.a.nonceMiddleware),o.a.use(o.a.mediaUploadMiddleware),o.a.use(o.a.rootURLMiddleware),o.a.use(o.a.preloadingMiddleware),t.default=o.a}).call(this,n(15))},66:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n(10),o=n.n(r),a=n(67),i=n(68);function c(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function u(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?c(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):c(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var s={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,r=u(u({},s),t);return r.referenceSiteURL&&(r.referenceSiteURL=r.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(a.a)(r,n),disableTracking:function(){r.trackingEnabled=!1},isTrackingEnabled:function(){return!!r.trackingEnabled},trackEvent:Object(i.a)(r,n)}}}).call(this,n(15))},67:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a}));var r=n(52),o=n(35);function a(t,n){var a=Object(r.a)(n);return function(){t.trackingEnabled=!0;var n=e.document;if(!n.querySelector("script[".concat(o.b,"]"))){var r=n.createElement("script");r.setAttribute(o.b,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(o.a),n.head.appendChild(r),a("js",new Date),a("config",t.trackingID)}}}}).call(this,n(15))},68:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(4),o=n.n(r),a=n(10),i=n.n(a),c=n(14),u=n.n(c),s=n(52);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(t,n){var r=Object(s.a)(n);return function(){var n=u()(o.a.mark((function n(a,i){var c,u,s,l,d,g,p,v,h=arguments;return o.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(c=h.length>2&&void 0!==h[2]?h[2]:"",u=h.length>3&&void 0!==h[3]?h[3]:"",s=t.isFirstAdmin,l=t.referenceSiteURL,d=t.trackingEnabled,g=t.trackingID,p=t.userIDHash,d){n.next=5;break}return n.abrupt("return");case 5:return v={send_to:g,event_category:a,event_label:c,event_value:u,dimension1:l,dimension2:s?"true":"false",dimension3:p},n.abrupt("return",new Promise((function(t){var n=setTimeout((function(){e.console.warn('Tracking event "'.concat(i,'" (category "').concat(a,'") took too long to fire.')),t()}),1e3);r("event",i,f(f({},v),{},{event_callback:function(){clearTimeout(n),t()}}))})));case 7:case"end":return n.stop()}}),n)})));return function(e,t){return n.apply(this,arguments)}}()}}).call(this,n(15))},72:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return p})),n.d(t,"d",(function(){return v})),n.d(t,"a",(function(){return h})),n.d(t,"c",(function(){return b}));var r=n(4),o=n.n(r),a=n(14),i=n.n(a);n(71);function c(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var a,i=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return i=e.done,e},e:function(e){c=!0,a=e},f:function(){try{i||null==n.return||n.return()}finally{if(c)throw a}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var s,l=["sessionStorage","localStorage"],f=[].concat(l),d=function(){var t=i()(o.a.mark((function t(n){var r,a;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,a="__storage_test__",r.setItem(a,a),r.removeItem(a),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==r.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),g=function(){var t=i()(o.a.mark((function t(){var n,r,a;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==s){t.next=25;break}n=c(f),t.prev=4,n.s();case 6:if((r=n.n()).done){t.next=16;break}if(a=r.value,!s){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,d(a);case 12:if(!t.sent){t.next=14;break}s=e[a];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===s&&(s=null);case 25:return t.abrupt("return",s);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),p=function(){var e=i()(o.a.mark((function e(t){var n,r,a,i,c=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=c.length>1&&void 0!==c[1]?c[1]:null,e.next=3,g();case 3:if(!(r=e.sent)){e.next=10;break}if(!(a=r.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(i=JSON.parse(a)).timestamp||!(null===n||Math.round(Date.now()/1e3)-i.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:i.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),v=function(){var t=i()(o.a.mark((function t(n,r){var a,i,c=arguments;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return a=c.length>2&&void 0!==c[2]?c[2]:void 0,t.next=3,g();case 3:if(!(i=t.sent)){t.next=14;break}return t.prev=5,i.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:a||Math.round(Date.now()/1e3),value:r})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),h=function(){var t=i()(o.a.mark((function t(n){var r;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,g();case 2:if(!(r=t.sent)){t.next=13;break}return t.prev=4,r.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),b=function(){var t=i()(o.a.mark((function t(){var n,r,a,i;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,g();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,r=[],a=0;a<n.length;a++)0===(i=n.key(a)).indexOf("googlesitekit_")&&r.push(i.substring("googlesitekit_".length));return t.abrupt("return",r);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:case"end":return t.stop()}}),t,null,[[4,10]])})));return function(){return t.apply(this,arguments)}}()}).call(this,n(15))},76:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return o}));var r=n(101),o=n.n(r)()(e)}).call(this,n(15))}});
1
+ !function(e){function t(t){for(var r,a,u=t[0],c=t[1],l=t[2],f=0,d=[];f<u.length;f++)a=u[f],Object.prototype.hasOwnProperty.call(o,a)&&o[a]&&d.push(o[a][0]),o[a]=0;for(r in c)Object.prototype.hasOwnProperty.call(c,r)&&(e[r]=c[r]);for(s&&s(t);d.length;)d.shift()();return i.push.apply(i,l||[]),n()}function n(){for(var e,t=0;t<i.length;t++){for(var n=i[t],r=!0,a=1;a<n.length;a++){var u=n[a];0!==o[u]&&(r=!1)}r&&(i.splice(t--,1),e=__webpack_require__(__webpack_require__.s=n[0]))}return e}var r={},o={8:0},i=[];function __webpack_require__(t){if(r[t])return r[t].exports;var n=r[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,__webpack_require__),n.l=!0,n.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{enumerable:!0,get:n})},__webpack_require__.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},__webpack_require__.t=function(e,t){if(1&t&&(e=__webpack_require__(e)),8&t)return e;if(4&t&&"object"==typeof e&&e&&e.__esModule)return e;var n=Object.create(null);if(__webpack_require__.r(n),Object.defineProperty(n,"default",{enumerable:!0,value:e}),2&t&&"string"!=typeof e)for(var r in e)__webpack_require__.d(n,r,function(t){return e[t]}.bind(null,r));return n},__webpack_require__.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(t,"a",t),t},__webpack_require__.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},__webpack_require__.p="";var a=window.__googlesitekit_webpackJsonp=window.__googlesitekit_webpackJsonp||[],u=a.push.bind(a);a.push=t,a=a.slice();for(var c=0;c<a.length;c++)t(a[c]);var s=u;i.push([562,0]),n()}({1:function(e,t,n){"use strict";(function(e){n.d(t,"d",(function(){return a})),n.d(t,"a",(function(){return u})),n.d(t,"e",(function(){return s})),n.d(t,"f",(function(){return l})),n.d(t,"g",(function(){return d})),n.d(t,"h",(function(){return g})),n.d(t,"b",(function(){return b})),n.d(t,"i",(function(){return h})),n.d(t,"j",(function(){return _})),n.d(t,"k",(function(){return w})),n.d(t,"c",(function(){return S})),n.d(t,"l",(function(){return D})),n.d(t,"m",(function(){return R})),n.d(t,"n",(function(){return A})),n.d(t,"o",(function(){return N})),n.d(t,"p",(function(){return L})),n.d(t,"q",(function(){return M})),n.d(t,"r",(function(){return T})),n.d(t,"s",(function(){return F}));var r=n(98);void 0===e.googlesitekit&&(e.googlesitekit={});var o=e.googlesitekit._element||r,i=o.Children,a=o.cloneElement,u=o.Component,c=o.concatChildren,s=o.createContext,l=o.createElement,f=o.createInterpolateElement,d=o.createPortal,g=o.createRef,p=o.findDOMNode,v=o.forwardRef,b=o.Fragment,m=o.isEmptyElement,h=o.isValidElement,_=o.lazy,y=o.memo,k=o.Platform,O=o.RawHTML,w=o.render,j=o.renderToString,E=o.StrictMode,S=o.Suspense,x=o.switchChildrenNodeName,P=o.unmountComponentAtNode,D=o.useCallback,R=o.useContext,C=o.useDebugValue,A=o.useEffect,I=o.useImperativeHandle,N=o.useLayoutEffect,L=o.useMemo,M=o.useReducer,T=o.useRef,F=o.useState;void 0===e.googlesitekit._element&&(e.googlesitekit._element={Children:i,cloneElement:a,Component:u,concatChildren:c,createContext:s,createElement:l,createInterpolateElement:f,createPortal:d,createRef:g,findDOMNode:p,forwardRef:v,Fragment:b,isEmptyElement:m,isValidElement:h,lazy:_,memo:y,Platform:k,RawHTML:O,render:w,renderToString:j,StrictMode:E,Suspense:S,switchChildrenNodeName:x,unmountComponentAtNode:P,useCallback:D,useContext:R,useDebugValue:C,useEffect:A,useImperativeHandle:I,useLayoutEffect:N,useMemo:L,useReducer:M,useRef:T,useState:F})}).call(this,n(13))},109:function(e,t,n){"use strict";var r=n(100);t.a=function(e){var t=Object.keys(e).reduce((function(t,n){return t[Object(r.getStablePath)(n)]=e[n],t}),{}),n=!1;return function(e,o){if(n)return o(e);setTimeout((function(){n=!0}),1e3);var i=e.parse,a=void 0===i||i,u=e.path;if("string"==typeof e.path){var c,s=(null===(c=e.method)||void 0===c?void 0:c.toUpperCase())||"GET",l=Object(r.getStablePath)(u);if(a&&"GET"===s&&t[l]){var f=Promise.resolve(t[l].body);return delete t[l],f}if("OPTIONS"===s&&t[s]&&t[s][l]){var d=Promise.resolve(t[s][l]);return delete t[s][l],d}}return o(e)}}},12:function(e,t,n){"use strict";n.r(t),function(e){n.d(t,"Children",(function(){return l})),n.d(t,"createRef",(function(){return f})),n.d(t,"Component",(function(){return d})),n.d(t,"PureComponent",(function(){return g})),n.d(t,"createContext",(function(){return p})),n.d(t,"forwardRef",(function(){return v})),n.d(t,"lazy",(function(){return b})),n.d(t,"memo",(function(){return m})),n.d(t,"useCallback",(function(){return h})),n.d(t,"useContext",(function(){return _})),n.d(t,"useEffect",(function(){return y})),n.d(t,"useImperativeHandle",(function(){return k})),n.d(t,"useDebugValue",(function(){return O})),n.d(t,"useLayoutEffect",(function(){return w})),n.d(t,"useMemo",(function(){return j})),n.d(t,"useReducer",(function(){return E})),n.d(t,"useRef",(function(){return S})),n.d(t,"useState",(function(){return x})),n.d(t,"Fragment",(function(){return P})),n.d(t,"Profiler",(function(){return D})),n.d(t,"StrictMode",(function(){return R})),n.d(t,"Suspense",(function(){return C})),n.d(t,"createElement",(function(){return A})),n.d(t,"cloneElement",(function(){return I})),n.d(t,"createFactory",(function(){return N})),n.d(t,"isValidElement",(function(){return L})),n.d(t,"version",(function(){return M})),n.d(t,"__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED",(function(){return T}));var r=n(11),o=n.n(r),i=n(59),a=n.n(i);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}void 0===e.googlesitekit&&(e.googlesitekit={});var c=e.googlesitekit._react||function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({default:a.a},i),s=c.default,l=c.Children,f=c.createRef,d=c.Component,g=c.PureComponent,p=c.createContext,v=c.forwardRef,b=c.lazy,m=c.memo,h=c.useCallback,_=c.useContext,y=c.useEffect,k=c.useImperativeHandle,O=c.useDebugValue,w=c.useLayoutEffect,j=c.useMemo,E=c.useReducer,S=c.useRef,x=c.useState,P=c.Fragment,D=c.Profiler,R=c.StrictMode,C=c.Suspense,A=c.createElement,I=c.cloneElement,N=c.createFactory,L=c.isValidElement,M=c.version,T=c.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;void 0===e.googlesitekit._react&&(e.googlesitekit._react={default:a.a,Children:l,createRef:f,Component:d,PureComponent:g,createContext:p,forwardRef:v,lazy:b,memo:m,useCallback:h,useContext:_,useEffect:y,useImperativeHandle:k,useDebugValue:O,useLayoutEffect:w,useMemo:j,useReducer:E,useRef:S,useState:x,Fragment:P,Profiler:D,StrictMode:R,Suspense:C,createElement:A,cloneElement:I,createFactory:N,isValidElement:L,version:M,__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED:T}),t.default=s}.call(this,n(13))},16:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a})),n.d(t,"f",(function(){return u})),n.d(t,"g",(function(){return c})),n.d(t,"e",(function(){return s})),n.d(t,"d",(function(){return g})),n.d(t,"c",(function(){return p}));var r=n(94);void 0===e.googlesitekit&&(e.googlesitekit={});var o=e.googlesitekit._hooks||r,i=o.addAction,a=o.addFilter,u=o.removeAction,c=o.removeFilter,s=o.hasAction,l=o.hasFilter,f=o.removeAllActions,d=o.removeAllFilters,g=o.doAction,p=o.applyFilters,v=o.currentAction,b=o.currentFilter,m=o.doingAction,h=o.doingFilter,_=o.didAction,y=o.didFilter,k=o.actions,O=o.filters;void 0===e.googlesitekit._hooks&&(e.googlesitekit._hooks={addAction:i,addFilter:a,removeAction:u,removeFilter:c,hasAction:s,hasFilter:l,removeAllActions:f,removeAllFilters:d,doAction:g,applyFilters:p,currentAction:v,currentFilter:b,doingAction:m,doingFilter:h,didAction:_,didFilter:y,actions:k,filters:O})}).call(this,n(13))},20:function(e,t,n){"use strict";n.d(t,"c",(function(){return r})),n.d(t,"b",(function(){return o})),n.d(t,"a",(function(){return i}));var r="core/user",o="googlesitekit_manage_options",i="missing_required_scopes"},24:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return u}));var r=n(83),o=n.n(r),i=n(1),a=function(e){return function(t){return function FilteredComponent(n){return Object(i.f)(i.b,{},"",Object(i.f)(t,n),e)}}},u=function(t,n){return function(r){return function InnerComponent(i){return e.createElement(t,o()({},i,n,{OriginalComponent:r}))}}}}).call(this,n(12))},33:function(e,t,n){"use strict";(function(e,r){n(1);var o=n(2),i=n.n(o),a=n(18),u=n.n(a),c=function SvgIcon(t){var n=t.id,o=t.className,i=t.height,a=t.width,c="".concat(e._googlesitekitLegacyData.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:u()("svg",o),height:i,width:a},r.createElement("use",{xlinkHref:"".concat(c,"#").concat(n)}))};c.propTypes={id:i.a.string.isRequired,className:i.a.string,height:i.a.string,width:i.a.string},c.defaultProps={className:"",height:20,width:20},t.a=c}).call(this,n(13),n(12))},337:function(e,t,n){"use strict";(function(e){var r=n(3),o=n.n(r),i=n(14),a=n.n(i),u=n(19),c=n.n(u),s=n(65),l=n(48),f=n(74),d=n(5),g=n(20),p=!0,v=function(e,t,n){var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=[e,t,n].filter((function(e){return!!e&&e.length}));return 3===o.length&&r&&r.constructor===Object&&Object.keys(r).length&&o.push(Object(d.v)(r)),o.join("::")},b=function(){var t=a()(o.a.mark((function t(n,r,i){var a,u,d,p,b,m,h,y,k,O,w,j,E,S,x,P,D,R,C=arguments;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(a=C.length>3&&void 0!==C[3]?C[3]:{},u=a.bodyParams,d=a.cacheTTL,p=void 0===d?3600:d,b=a.method,m=void 0===b?"GET":b,h=a.queryParams,y=a.useCache,k=void 0===y?void 0:y,c()(n,"`type` argument for requests is required."),c()(r,"`identifier` argument for requests is required."),c()(i,"`datapoint` argument for requests is required."),O="GET"===m&&(void 0!==k?k:_()),w=v(n,r,i,h),!O){t.next=14;break}return t.next=9,Object(f.b)(w,p);case 9:if(j=t.sent,E=j.cacheHit,S=j.value,!E){t.next=14;break}return t.abrupt("return",S);case 14:return t.prev=14,t.next=17,Object(s.default)({data:u,method:m,path:Object(l.a)("/google-site-kit/v1/".concat(n,"/").concat(r,"/data/").concat(i),h)});case 17:if(x=t.sent,!O){t.next=21;break}return t.next=21,Object(f.d)(w,x);case 21:return t.abrupt("return",x);case 24:throw t.prev=24,t.t0=t.catch(14),t.t0.code===g.a&&(null===(P=e.googlesitekit)||void 0===P||null===(D=P.data)||void 0===D||null===(R=D.dispatch)||void 0===R?void 0:R.call(D,g.c))&&e.googlesitekit.data.dispatch(g.c).setPermissionScopeError(t.t0),e.console.error("Google Site Kit API Error",t.t0),t.t0;case 29:case"end":return t.stop()}}),t,null,[[14,24]])})));return function(e,n,r){return t.apply(this,arguments)}}(),m=function(){var e=a()(o.a.mark((function e(t,n,r,i){var a,u,c,s,l,f=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=f.length>4&&void 0!==f[4]?f[4]:{},u=a.cacheTTL,c=void 0===u?3600:u,s=a.useCache,l=void 0===s?void 0:s,e.abrupt("return",b(t,n,r,{cacheTTL:c,queryParams:i,useCache:l}));case 2:case"end":return e.stop()}}),e)})));return function(t,n,r,o){return e.apply(this,arguments)}}(),h=function(){var e=a()(o.a.mark((function e(t,n,r,i){var a,u,c,s,l,f,d=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return a=d.length>4&&void 0!==d[4]?d[4]:{},u=a.method,c=void 0===u?"POST":u,s=a.queryParams,l=void 0===s?{}:s,e.next=3,b(t,n,r,{bodyParams:{data:i},method:c,queryParams:l,useCache:!1});case 3:return f=e.sent,e.next=6,y(t,n,r);case 6:return e.abrupt("return",f);case 7:case"end":return e.stop()}}),e)})));return function(t,n,r,o){return e.apply(this,arguments)}}(),_=function(){return p},y=function(){var e=a()(o.a.mark((function e(t,n,r){var i;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i=v(t,n,r),e.next=3,Object(f.c)();case 3:e.sent.forEach((function(e){0===e.indexOf(i)&&Object(f.a)(e)}));case 5:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),k={invalidateCache:y,get:m,set:h,setUsingCache:function(e){return p=!!e},usingCache:_};t.a=k}).call(this,n(13))},36:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return o}));var r="_googlesitekitDataLayer",o="data-googlesitekit-gtag"},40:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r,o=n(6),i=n.n(o),a=n(7),u=n.n(a),c=function(t){var n=e[t];if(!n)return!1;try{var r="__storage_test__";return n.setItem(r,r),n.removeItem(r),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==n.length}},s=function(){function NullStorage(){i()(this,NullStorage)}return u()(NullStorage,[{key:"key",value:function(){return null}},{key:"getItem",value:function(){return null}},{key:"setItem",value:function(){}},{key:"removeItem",value:function(){}},{key:"clear",value:function(){}},{key:"length",get:function(){return 0}}]),NullStorage}(),l=function(){return r||(r=c("sessionStorage")?e.sessionStorage:c("localStorage")?e.localStorage:new s),r}}).call(this,n(13))},5:function(e,t,n){"use strict";(function(e,r){n.d(t,"s",(function(){return D})),n.d(t,"q",(function(){return R})),n.d(t,"n",(function(){return A})),n.d(t,"r",(function(){return I})),n.d(t,"h",(function(){return N})),n.d(t,"c",(function(){return L})),n.d(t,"f",(function(){return M})),n.d(t,"j",(function(){return T})),n.d(t,"l",(function(){return F})),n.d(t,"m",(function(){return q})),n.d(t,"x",(function(){return U})),n.d(t,"b",(function(){return H})),n.d(t,"u",(function(){return V})),n.d(t,"e",(function(){return z})),n.d(t,"p",(function(){return J})),n.d(t,"i",(function(){return B}));var o=n(3),i=n.n(o),a=n(14),u=n.n(a),c=n(11),s=n.n(c),l=n(45),f=n.n(l),d=n(32),g=n.n(d),p=(n(1),n(15)),v=n(16),b=n(0),m=n(48),h=n(145),_=n(33);n.d(t,"a",(function(){return _.a}));var y=n(50);n.d(t,"w",(function(){return y.c}));var k=n(24),O=n(54);n.d(t,"t",(function(){return O.a}));var w=n(56);n.d(t,"v",(function(){return w.a}));var j=n(55);n.d(t,"d",(function(){return j.b})),n.d(t,"k",(function(){return j.c}));n(40);var E=n(63);function S(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function x(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?S(Object(n),!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):S(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"o",(function(){return E.a})),n.d(t,"g",(function(){return k.b}));var P=function(e){return 1e6<=e?Math.round(e/1e5)/10:1e4<=e?Math.round(e/1e3):1e3<=e?Math.round(e/100)/10:e},D=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(p.isFinite)(e)?e:Number(e),Object(p.isFinite)(e)||(console.warn("Invalid number",e,g()(e)),e=0),t)return R(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};return 1e6<=e?Object(b.sprintf)(// translators: %s: an abbreviated number in millions.
2
+ Object(b.__)("%sM","google-site-kit"),R(P(e),e%10==0?{}:n)):1e4<=e?Object(b.sprintf)(// translators: %s: an abbreviated number in thousands.
3
+ Object(b.__)("%sK","google-site-kit"),R(P(e))):1e3<=e?Object(b.sprintf)(// translators: %s: an abbreviated number in thousands.
4
+ Object(b.__)("%sK","google-site-kit"),R(P(e),e%10==0?{}:n)):e.toString()},R=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?C():n,o=f()(t,["locale"]);return new Intl.NumberFormat(r,o).format(e)},C=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(p.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language},A=function(e){switch(e){case"minute":return 60;case"hour":return 3600;case"day":return 86400;case"week":return 604800;case"month":return 2592e3;case"year":return 31536e3}},I=function(e){if(e=parseInt(e,10),isNaN(e)||0===e)return"0.0s";var t={};return t.hours=Math.floor(e/60/60),t.minutes=Math.floor(e/60%60),t.seconds=Math.floor(e%60),((t.hours?t.hours+"h ":"")+(t.minutes?t.minutes+"m ":"")+(t.seconds?t.seconds+"s ":"")).trim()},N=function(e,t){var n=1e3*A("day"),r=e.getTime(),o=t.getTime();return Math.round(Math.abs(r-o)/n)},L=function(e,t){if("0"===e||0===e||isNaN(e))return"";var n=((t-e)/e*100).toFixed(1);return isNaN(n)||"Infinity"===n?"":n},M=function(e,t){return Object(p.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},T=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e._googlesitekitLegacyData,n=t.modules;return n?Object.keys(n).reduce((function(e,t){return"object"!==g()(n[t])||void 0===n[t].slug||void 0===n[t].name||n[t].slug!==t?e:x(x({},e),{},s()({},t,n[t]))}),{}):{}},F=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e._googlesitekitLegacyData,o=r.admin,i=o.connectURL,a=o.adminRoot,u=r.setup.needReauthenticate,c=T(r)[t].screenID,s="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(m.a)(a,x({page:t&&n&&c?c:"googlesitekit-dashboard",slug:t,reAuth:n},s));if(!u)return l;var f=encodeURIComponent(Object(h.a)(l));return l=a+"?"+f,Object(m.a)(i,{redirect:l,status:n})},q=function(t,n){var r=e._googlesitekitLegacyData.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=x({page:t},n),Object(m.a)(r,n)},U=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},H=function(){var e=u()(i.a.mark((function e(t,n,r){var o,a,u,c,s=arguments;return i.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return o=s.length>3&&void 0!==s[3]?s[3]:y.c,a=s.length>4&&void 0!==s[4]?s[4]:T,e.next=4,t.setModuleActive(n,r);case 4:return u=e.sent,(c=a())[n]&&(c[n].active=r),e.next=9,o("".concat(n,"_setup"),r?"module_activate":"module_deactivate",n);case 9:return e.abrupt("return",u);case 10:case"end":return e.stop()}}),e)})));return function(t,n,r){return e.apply(this,arguments)}}(),V=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(v.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",Object(k.b)(e,t),1)},z=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(p.unescape)(t)};function J(t,n){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"33",i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:"33",a=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"";if(e._googlesitekitLegacyData){var u=r.createElement(_.a,{id:t,width:o,height:i,className:a});return n?u=r.createElement(_.a,{id:"".concat(t,"-disabled"),width:o,height:i,className:a}):"pagespeed-insights"===t&&(u=r.createElement("img",{src:e._googlesitekitLegacyData.admin.assetsRoot+"images/icon-pagespeed.png",width:o,alt:"",className:a})),u}}function B(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix,o=n.isNetworkMode;return o?t:r+t}}).call(this,n(13),n(12))},50:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return f})),n.d(t,"b",(function(){return g})),n.d(t,"c",(function(){return d}));var r=n(68),o=e._googlesitekitBaseData||{},i=o.isFirstAdmin,a=o.trackingAllowed,u={isFirstAdmin:i,trackingEnabled:o.trackingEnabled,trackingID:o.trackingID,referenceSiteURL:o.referenceSiteURL,userIDHash:o.userIDHash},c=Object(r.a)(u),s=c.enableTracking,l=c.disableTracking,f=c.isTrackingEnabled,d=c.trackEvent;function g(e){e?s():l()}!0===a&&g(f())}).call(this,n(13))},52:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(36);function o(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},54:function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(78),o=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:r.a.sanitize(e,t)}}},55:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return s})),n.d(t,"c",(function(){return f}));var r=n(35),o=n.n(r),i=n(0);function a(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return u(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return u(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,c=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){c=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(c)throw i}}}}function u(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var c=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=null,n=null,r=document.querySelector("#toplevel_page_googlesitekit-dashboard .googlesitekit-notifications-counter"),o=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(r&&o)return!1;if(t=document.querySelector("#toplevel_page_googlesitekit-dashboard .wp-menu-name"),n=document.querySelector("#wp-admin-bar-google-site-kit .ab-item"),null===t&&null===n)return!1;var a=document.createElement("span");a.setAttribute("class","googlesitekit-notifications-counter update-plugins count-".concat(e));var u=document.createElement("span");u.setAttribute("class","plugin-count"),u.setAttribute("aria-hidden","true"),u.textContent=e;var c=document.createElement("span");return c.setAttribute("class","screen-reader-text"),c.textContent=Object(i.sprintf)(
5
  /* translators: %d is the number of notifications */
6
+ Object(i._n)("%d notification","%d notifications",e,"google-site-kit"),e),a.appendChild(u),a.appendChild(c),t&&null===r&&t.appendChild(a),n&&null===o&&n.appendChild(a),a},s=function(){e.localStorage&&e.localStorage.clear(),e.sessionStorage&&e.sessionStorage.clear()},l=function(e){for(var t=location.search.substr(1).split("&"),n={},r=0;r<t.length;r++)n[t[r].split("=")[0]]=decodeURIComponent(t[r].split("=")[1]);return e?n.hasOwnProperty(e)?decodeURIComponent(n[e].replace(/\+/g," ")):"":n},f=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:location,n=new URL(t.href);if(e)return n.searchParams&&n.searchParams.get?n.searchParams.get(e):l(e);var r,i={},u=a(n.searchParams.entries());try{for(u.s();!(r=u.n()).done;){var c=o()(r.value,2),s=c[0],f=c[1];i[s]=f}}catch(e){u.e(e)}finally{u.f()}return i}}).call(this,n(13))},56:function(e,t,n){"use strict";n.d(t,"a",(function(){return u}));var r=n(32),o=n.n(r),i=n(106),a=n.n(i),u=function(e){return a()(JSON.stringify(function e(t){var n={};return Object.keys(t).sort().forEach((function(r){var i=t[r];i&&"object"===o()(i)&&!Array.isArray(i)&&(i=e(i)),n[r]=i})),n}(e)))}},562:function(e,t,n){"use strict";n.r(t),function(e){var r=n(337);void 0===e.googlesitekit&&(e.googlesitekit={}),void 0===e.googlesitekit.api&&(e.googlesitekit.api=r.a),t.default=r.a}.call(this,n(13))},63:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return u})),n.d(t,"b",(function(){return c}));var r=n(45),o=n.n(r),i=n(15),a=n(0);function u(){Object(a.setLocaleData)(e._googlesitekitLegacyData.locale,"google-site-kit")}var c=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.locale,r=void 0===n?s():n,i=o()(t,["locale"]);return new Intl.NumberFormat(r,i).format(e)},s=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:e,n=Object(i.get)(t,["_googlesitekitLegacyData","locale","","lang"]);if(n){var r=n.match(/^(\w{2})?(_)?(\w{2})/);if(r&&r[0])return r[0].replace(/_/g,"-")}return t.navigator.language}}).call(this,n(13))},65:function(e,t,n){"use strict";(function(e){var r=n(26),o=n.n(r),i=n(109),a=e._googlesitekitAPIFetchData||{},u=a.nonce,c=a.nonceEndpoint,s=a.preloadedData,l=a.rootURL;o.a.nonceEndpoint=c,o.a.nonceMiddleware=o.a.createNonceMiddleware(u),o.a.rootURLMiddleware=o.a.createRootURLMiddleware(l),o.a.preloadingMiddleware=Object(i.a)(s),o.a.use(o.a.nonceMiddleware),o.a.use(o.a.mediaUploadMiddleware),o.a.use(o.a.rootURLMiddleware),o.a.use(o.a.preloadingMiddleware),t.default=o.a}).call(this,n(13))},68:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return l}));var r=n(11),o=n.n(r),i=n(69),a=n(70);function u(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?u(Object(n),!0).forEach((function(t){o()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):u(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var s={isFirstAdmin:!1,trackingEnabled:!1,trackingID:"",referenceSiteURL:"",userIDHash:""};function l(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e,r=c(c({},s),t);return r.referenceSiteURL&&(r.referenceSiteURL=r.referenceSiteURL.toString().replace(/\/+$/,"")),{enableTracking:Object(i.a)(r,n),disableTracking:function(){r.trackingEnabled=!1},isTrackingEnabled:function(){return!!r.trackingEnabled},trackEvent:Object(a.a)(r,n)}}}).call(this,n(13))},69:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i}));var r=n(52),o=n(36);function i(t,n){var i=Object(r.a)(n);return function(){t.trackingEnabled=!0;var n=e.document;if(!n.querySelector("script[".concat(o.b,"]"))){var r=n.createElement("script");r.setAttribute(o.b,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(o.a),n.head.appendChild(r),i("js",new Date),i("config",t.trackingID)}}}}).call(this,n(13))},70:function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return d}));var r=n(3),o=n.n(r),i=n(11),a=n.n(i),u=n(14),c=n.n(u),s=n(52);function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function f(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function d(t,n){var r=Object(s.a)(n);return function(){var n=c()(o.a.mark((function n(i,a){var u,c,s,l,d,g,p,v,b=arguments;return o.a.wrap((function(n){for(;;)switch(n.prev=n.next){case 0:if(u=b.length>2&&void 0!==b[2]?b[2]:"",c=b.length>3&&void 0!==b[3]?b[3]:"",s=t.isFirstAdmin,l=t.referenceSiteURL,d=t.trackingEnabled,g=t.trackingID,p=t.userIDHash,d){n.next=5;break}return n.abrupt("return");case 5:return v={send_to:g,event_category:i,event_label:u,event_value:c,dimension1:l,dimension2:s?"true":"false",dimension3:p},n.abrupt("return",new Promise((function(t){var n=setTimeout((function(){e.console.warn('Tracking event "'.concat(a,'" (category "').concat(i,'") took too long to fire.')),t()}),1e3);r("event",a,f(f({},v),{},{event_callback:function(){clearTimeout(n),t()}}))})));case 7:case"end":return n.stop()}}),n)})));return function(e,t){return n.apply(this,arguments)}}()}}).call(this,n(13))},74:function(e,t,n){"use strict";(function(e){n.d(t,"b",(function(){return p})),n.d(t,"d",(function(){return v})),n.d(t,"a",(function(){return b})),n.d(t,"c",(function(){return m}));var r=n(3),o=n.n(r),i=n(14),a=n.n(i);n(73);function u(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return c(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return c(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0,o=function(){};return{s:o,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(e){throw e},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,a=!0,u=!1;return{s:function(){n=e[Symbol.iterator]()},n:function(){var e=n.next();return a=e.done,e},e:function(e){u=!0,i=e},f:function(){try{a||null==n.return||n.return()}finally{if(u)throw i}}}}function c(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var s,l=["sessionStorage","localStorage"],f=[].concat(l),d=function(){var t=a()(o.a.mark((function t(n){var r,i;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(r=e[n]){t.next=3;break}return t.abrupt("return",!1);case 3:return t.prev=3,i="__storage_test__",r.setItem(i,i),r.removeItem(i),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(3),t.abrupt("return",t.t0 instanceof DOMException&&(22===t.t0.code||1014===t.t0.code||"QuotaExceededError"===t.t0.name||"NS_ERROR_DOM_QUOTA_REACHED"===t.t0.name)&&0!==r.length);case 13:case"end":return t.stop()}}),t,null,[[3,10]])})));return function(e){return t.apply(this,arguments)}}(),g=function(){var t=a()(o.a.mark((function t(){var n,r,i;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:if(!(e._googlesitekitLegacyData&&e._googlesitekitLegacyData.admin&&e._googlesitekitLegacyData.admin.nojscache)){t.next=2;break}return t.abrupt("return",null);case 2:if(void 0!==s){t.next=25;break}n=u(f),t.prev=4,n.s();case 6:if((r=n.n()).done){t.next=16;break}if(i=r.value,!s){t.next=10;break}return t.abrupt("continue",14);case 10:return t.next=12,d(i);case 12:if(!t.sent){t.next=14;break}s=e[i];case 14:t.next=6;break;case 16:t.next=21;break;case 18:t.prev=18,t.t0=t.catch(4),n.e(t.t0);case 21:return t.prev=21,n.f(),t.finish(21);case 24:void 0===s&&(s=null);case 25:return t.abrupt("return",s);case 26:case"end":return t.stop()}}),t,null,[[4,18,21,24]])})));return function(){return t.apply(this,arguments)}}(),p=function(){var e=a()(o.a.mark((function e(t){var n,r,i,a,u=arguments;return o.a.wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n=u.length>1&&void 0!==u[1]?u[1]:null,e.next=3,g();case 3:if(!(r=e.sent)){e.next=10;break}if(!(i=r.getItem("".concat("googlesitekit_").concat(t)))){e.next=10;break}if(!(a=JSON.parse(i)).timestamp||!(null===n||Math.round(Date.now()/1e3)-a.timestamp<n)){e.next=10;break}return e.abrupt("return",{cacheHit:!0,value:a.value});case 10:return e.abrupt("return",{cacheHit:!1,value:void 0});case 11:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),v=function(){var t=a()(o.a.mark((function t(n,r){var i,a,u=arguments;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return i=u.length>2&&void 0!==u[2]?u[2]:void 0,t.next=3,g();case 3:if(!(a=t.sent)){t.next=14;break}return t.prev=5,a.setItem("".concat("googlesitekit_").concat(n),JSON.stringify({timestamp:i||Math.round(Date.now()/1e3),value:r})),t.abrupt("return",!0);case 10:return t.prev=10,t.t0=t.catch(5),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 14:return t.abrupt("return",!1);case 15:case"end":return t.stop()}}),t,null,[[5,10]])})));return function(e,n){return t.apply(this,arguments)}}(),b=function(){var t=a()(o.a.mark((function t(n){var r;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,g();case 2:if(!(r=t.sent)){t.next=13;break}return t.prev=4,r.removeItem("".concat("googlesitekit_").concat(n)),t.abrupt("return",!0);case 9:return t.prev=9,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",!1);case 13:return t.abrupt("return",!1);case 14:case"end":return t.stop()}}),t,null,[[4,9]])})));return function(e){return t.apply(this,arguments)}}(),m=function(){var t=a()(o.a.mark((function t(){var n,r,i,a;return o.a.wrap((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,g();case 2:if(!(n=t.sent)){t.next=14;break}for(t.prev=4,r=[],i=0;i<n.length;i++)0===(a=n.key(i)).indexOf("googlesitekit_")&&r.push(a.substring("googlesitekit_".length));return t.abrupt("return",r);case 10:return t.prev=10,t.t0=t.catch(4),e.console.warn("Encountered an unexpected storage error:",t.t0),t.abrupt("return",[]);case 14:return t.abrupt("return",[]);case 15:cas