Version Description
Download this release
Release Info
Developer | flixos90 |
Plugin | Site Kit by Google |
Version | 1.6.0 |
Comparing to | |
See all releases |
Code changes from version 1.5.1 to 1.6.0
- dist/assets/js/ads.js +1 -1
- dist/assets/js/chunk-googlesitekit-adminbar-8a094f23d70361ec3045.js +29 -0
- dist/assets/js/chunk-googlesitekit-adminbar-91cfda9281c30d7cec7f.js +0 -26
- dist/assets/js/{chunk-googlesitekit-adminbar~chunk-googlesitekit-setup-wizard~chunk-googlesitekit-setup-wizard-proxy-b48debf2e0f11591ea2f.js → chunk-googlesitekit-adminbar~chunk-googlesitekit-setup-wizard~chunk-googlesitekit-setup-wizard-proxy-7b6a86fd3073896743e0.js} +1 -1
- dist/assets/js/{chunk-googlesitekit-setup-wizard-bef2f7ac6eca50d2f9fb.js → chunk-googlesitekit-setup-wizard-bd097cea8a9b4de38b8d.js} +3 -3
- dist/assets/js/{chunk-googlesitekit-setup-wizard-proxy-9ca0095ac2fc2ef8d455.js → chunk-googlesitekit-setup-wizard-proxy-7d6f526304725b8d08d5.js} +2 -2
- dist/assets/js/{chunk-googlesitekit-setup-wrapper-998d2adcbb3bf10e34c2.js → chunk-googlesitekit-setup-wrapper-ac29c06e1e81b2730811.js} +1 -1
- dist/assets/js/googlesitekit-activation.js +4 -1
dist/assets/js/ads.js
CHANGED
@@ -1 +1 @@
|
|
1 |
-
!function(e){var r={};function __webpack_require__(_){if(r[_])return r[_].exports;var t=r[_]={i:_,l:!1,exports:{}};return e[_].call(t.exports,t,t.exports,__webpack_require__),t.l=!0,t.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,r,_){__webpack_require__.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:_})},__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,r){if(1&r&&(e=__webpack_require__(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var _=Object.create(null);if(__webpack_require__.r(_),Object.defineProperty(_,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var t in e)__webpack_require__.d(_,t,function(r){return e[r]}.bind(null,t));return _},__webpack_require__.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(r,"a",r),r},__webpack_require__.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},__webpack_require__.p="",__webpack_require__(__webpack_require__.s=
|
1 |
+
!function(e){var r={};function __webpack_require__(_){if(r[_])return r[_].exports;var t=r[_]={i:_,l:!1,exports:{}};return e[_].call(t.exports,t,t.exports,__webpack_require__),t.l=!0,t.exports}__webpack_require__.m=e,__webpack_require__.c=r,__webpack_require__.d=function(e,r,_){__webpack_require__.o(e,r)||Object.defineProperty(e,r,{enumerable:!0,get:_})},__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,r){if(1&r&&(e=__webpack_require__(e)),8&r)return e;if(4&r&&"object"==typeof e&&e&&e.__esModule)return e;var _=Object.create(null);if(__webpack_require__.r(_),Object.defineProperty(_,"default",{enumerable:!0,value:e}),2&r&&"string"!=typeof e)for(var t in e)__webpack_require__.d(_,t,function(r){return e[r]}.bind(null,t));return _},__webpack_require__.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return __webpack_require__.d(r,"a",r),r},__webpack_require__.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},__webpack_require__.p="",__webpack_require__(__webpack_require__.s=354)}({15:function(e,r){var _;_=function(){return this}();try{_=_||new Function("return this")()}catch(e){"object"==typeof window&&(_=window)}e.exports=_},354:function(e,r,_){(function(e){void 0===e.googlesitekit&&(e.googlesitekit={}),e.googlesitekit.canAdsRun=!0,document.addEventListener("DOMContentLoaded",(function(){e.googlesitekit.canAdsRun=!0}))}).call(this,_(15))}});
|
dist/assets/js/chunk-googlesitekit-adminbar-8a094f23d70361ec3045.js
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
(window.webpackJsonp=window.webpackJsonp||[]).push([[2],[,,,function(e,t,a){"use strict";(function(e){a.d(t,"u",(function(){return L})),a.d(t,"s",(function(){return I})),a.d(t,"p",(function(){return W})),a.d(t,"t",(function(){return R})),a.d(t,"i",(function(){return U})),a.d(t,"b",(function(){return F})),a.d(t,"e",(function(){return z})),a.d(t,"v",(function(){return H})),a.d(t,"m",(function(){return G})),a.d(t,"f",(function(){return q})),a.d(t,"n",(function(){return B})),a.d(t,"B",(function(){return K})),a.d(t,"C",(function(){return Y})),a.d(t,"j",(function(){return V})),a.d(t,"a",(function(){return Z})),a.d(t,"z",(function(){return $})),a.d(t,"x",(function(){return Q})),a.d(t,"d",(function(){return ee})),a.d(t,"g",(function(){return te})),a.d(t,"h",(function(){return ae})),a.d(t,"r",(function(){return ne})),a.d(t,"y",(function(){return ie})),a.d(t,"k",(function(){return oe}));var n=a(64),i=a.n(n),o=a(21),s=a.n(o),r=a(11),l=a.n(r),c=a(73),d=a.n(c),g=a(38),u=a.n(g),m=a(13),p=a(10),h=a(24),b=a(1),_=a.n(b),f=a(52),k=a(12),y=a(0),v=a(45),S=a(90),O=a(98),E=a(134),j=a(135),D=a(39),C=a(55);a.d(t,"A",(function(){return C.c}));var w=a(72);a.d(t,"w",(function(){return w.a}));var A=a(89);a.d(t,"c",(function(){return A.b})),a.d(t,"l",(function(){return A.c}));var x=a(121);a.d(t,"o",(function(){return x.a}));var N=a(122);function P(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function T(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?P(a,!0).forEach((function(t){s()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):P(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}a.d(t,"q",(function(){return N.a}));var L=function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(e=Object(m.isFinite)(e)?e:Number(e),Object(m.isFinite)(e)||(console.warn("Invalid number",e,u()(e)),e=0),t)return I(e,{style:"currency",currency:t});var a={minimumFractionDigits:1,maximumFractionDigits:1};switch(!0){case 1e6<e:return Object(y.sprintf)(// translators: %s: an abbreviated number in millions.
|
2 |
+
Object(y.__)("%sM","google-site-kit"),I(e/1e6,a));case 99e3<e:return Object(y.sprintf)(// translators: %s: an abbreviated number in thousands.
|
3 |
+
Object(y.__)("%sK","google-site-kit"),I(Math.round(e/1e3)));case 1e3<e:return Object(y.sprintf)(// translators: %s: an abbreviated number in thousands.
|
4 |
+
Object(y.__)("%sK","google-site-kit"),I(e/1e3,a));default:return e.toString()}},I=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=t.locale,n=void 0===a?M():a,i=d()(t,["locale"]);return new Intl.NumberFormat(n,i).format(e)},M=function(){var t=Object(m.get)(e,["googlesitekit","locale","","lang"]);return t?t.replace("_","-"):e.navigator.language},W=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()},U=function(e,t){var a=1e3*W("day"),n=e.getTime(),i=t.getTime();return Math.round(Math.abs(n-i)/a)},F=function(e,t){if("0"===e||0===e||isNaN(e))return"";var a=((t-e)/e*100).toFixed(1);return isNaN(a)||"Infinity"===a?"":a},z=function(e,t){return Object(m.map)(e,(function(e,a){return[e[0],e[t]||(0===a?"":0)]}))},H=function(){var t,a;return l.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,l.a.awrap(p.c.get(p.a,"user","authentication"));case 3:t=n.sent,a=t.grantedScopes.filter((function(e){return-1!==t.requiredScopes.indexOf(e)})),e.googlesitekit.setup=e.googlesitekit.setup||{},e.googlesitekit.setup.isAuthenticated=t.isAuthenticated,e.googlesitekit.setup.requiredScopes=t.requiredScopes,e.googlesitekit.setup.grantedScopes=t.grantedScopes,e.googlesitekit.setup.needReauthenticate=a.length<t.requiredScopes.length,n.next=14;break;case 12:n.prev=12,n.t0=n.catch(0);case 14:case"end":return n.stop()}}),null,null,[[0,12]])},G=function(t,a){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.googlesitekit,i=n.admin,o=i.connectURL,s=i.adminRoot,r=n.setup.needReauthenticate,l=n.modules[t].screenID,c="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},d=Object(v.a)(s,T({page:t&&a&&l?l:"googlesitekit-dashboard",slug:t,reAuth:a},c));if(!r)return d;var g=encodeURIComponent(Object(S.a)(d));return d=s+"?"+g,Object(v.a)(o,{redirect:d,status:a})},q=function(e,t){return function(a){return function InnerComponent(n){return _.a.createElement(e,i()({},n,t,{OriginalComponent:a}))}}},B=function(t,a){var n=e.googlesitekit.admin.adminRoot;return t||(t="googlesitekit-dashboard"),a=T({page:t},a),Object(v.a)(n,a)},K=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},Y=function(e){return e.match(/^GTM-[a-zA-Z\d]{7}$/)},V=function(t){var a,n,i,o,s;return l.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return a=e.googlesitekit.admin,n=a.homeURL,i=a.ampMode,o={tagverify:1,timestamp:Date.now()},r.next=4,l.a.awrap(J(Object(v.a)(n,o),t));case 4:if((s=r.sent)||"secondary"!==i){r.next=9;break}return r.next=8,l.a.awrap(Object(f.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return l.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,l.a.awrap(J(Object(v.a)(e.link,T({},o,{amp:1})),t));case 2:return a.abrupt("return",a.sent);case 3:case"end":return a.stop()}}))})).pop()})));case 8:s=r.sent;case 9:return r.abrupt("return",Promise.resolve(s||null));case 10:case"end":return r.stop()}}))},J=function(e,t){var a;return l.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,l.a.awrap(fetch(e,{credentials:"omit"}).then((function(e){return e.text()})));case 3:return a=n.sent,n.abrupt("return",X(a,t)||null);case 7:return n.prev=7,n.t0=n.catch(0),n.abrupt("return",null);case 10:case"end":return n.stop()}}),null,null,[[0,7]])},X=function(e,t){var a=({adsense:E.a,analytics:j.a,tagmanager:D.d,setup:O.b}[t]||[]).find((function(t){return t.test(e)}));return!!a&&a.exec(e)[1]},Z=function(t,a,n){return t.setModuleActive(a,n).then((function(t){return e.googlesitekit.modules&&e.googlesitekit.modules[a]&&(e.googlesitekit.modules[a].active=t.active),Object(C.c)("".concat(a,"_setup"),t.active?"module_activate":"module_deactivate",a),new Promise((function(e){e(t)}))}))},$=function(t,a,n){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:e.googlesitekit,s=o.modules[t],r=s.settings,l=s.setupComplete,c=i||document.getElementById("confirm-changes-".concat(t));if(l&&c){var d=!!Object.keys(a).find((function(e){var t=a[e];return!Object(m.isEqual)(n[e],r[t])}));return i||(c.disabled=!d),d}},Q=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(k.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",q(e,t),1)},ee=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(m.unescape)(t)};function te(){var e=Object(k.c)("googlesitekit.dateRange","last-28-days").match(/last-(\d+)-days/);if(e&&e[1])return Object(y.sprintf)(Object(y._n)("%s day","%s days",parseInt(e[1],10),"google-site-kit"),e[1]);throw new Error("Unrecognized date range slug used in `googlesitekit.dateRange`.")}function ae(){return Object(k.c)("googlesitekit.dateRange","last-28-days")}function ne(t,a){var n=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.googlesitekit){var s=_.a.createElement(h.a,{id:t,width:n,height:i,className:o});return a?s=_.a.createElement(h.a,{id:"".concat(t,"-disabled"),width:n,height:i,className:o}):"pagespeed-insights"===t&&(s=_.a.createElement("img",{src:e.googlesitekit.admin.assetsRoot+"images/icon-pagespeed.png",width:n,alt:"",className:o})),s}}function ie(e){var t={};return Object.keys(e).sort().forEach((function(a){var n=e[a];n&&"object"===u()(n)&&!Array.isArray(n)&&(n=ie(n)),t[a]=n})),t}function oe(t){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,n=a.blogPrefix;return a.isNetworkMode?t:n+t}}).call(this,a(15))},,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return f})),a.d(t,"b",(function(){return k}));var n=a(21),i=a.n(n),o=a(38),s=a.n(o),r=a(81),l=a(133),c=a(99),d=a.n(c),g=a(3),u=a(13),m=a(52),p=a(45),h=a(12);function b(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function _(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?b(a,!0).forEach((function(t){i()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):b(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var f="core",k="modules",y=function(){e.googlesitekit.admin=e.googlesitekit.admin||{},"string"==typeof e.googlesitekit.admin.datacache&&(e.googlesitekit.admin.datacache=JSON.parse(e.googlesitekit.admin.datacache)),"object"!==s()(e.googlesitekit.admin.datacache)&&(e.googlesitekit.admin.datacache={})},v=function(e,t){var a=_({data:{}},e);return a.data=_({dateRange:t},a.data),a},S={maxRequests:10,init:function(){Object(h.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingData",this.collectModuleData.bind(this))},combinedGetFromCache:function(e){var t=this;return new Promise((function(a,n){try{var i=[],o=Object(g.h)();Object(u.each)(e,(function(e){var a=v(e,o);a.key=t.getCacheKey(a.type,a.identifier,a.datapoint,a.data);var n=t.getCache(a.key,a.maxAge);void 0!==n&&(i[a.key]=n,t.resolve(a,n))})),a(i)}catch(e){n()}}))},combinedGet:function(e){var t=this,a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=[],i=25,o=Object(g.h)();Object(u.each)(e,(function(e){var a=v(e,o);a.key=t.getCacheKey(a.type,a.identifier,a.datapoint,a.data);var s=t.getCache(a.key,a.maxAge);void 0!==s?(setTimeout((function(){t.resolve(a,s)}),i),i+=25):n.push(a)})),n=Object(u.sortBy)(n,"priority");var s=[],r=[],l={},c=!!n.find((function(e){return e.priority<10}));Object(u.each)(n,(function(e,t){!a&&10<=e.priority&&c?r.push(e):l[e.key]?l[e.key].push(t):(l[e.key]=[t],s.push(e))}));var d=10,b=s.slice(0,d),_=s.slice(d);if(_=_.concat(r),0!==b.length||0!==_.length){0<_.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(_,!0)}),50):this.maxRequests=10;var f=null!==Object(g.l)("datacache");return Object(m.default)({path:Object(p.a)("/google-site-kit/v1/data/",{datacache:f||void 0}),data:{request:b},method:"POST"}).then((function(e){Object(u.each)(e,(function(e,a){l[a]?(t.handleWPError(e),Object(u.each)(l[a],(function(a){var i=n[a];t.setCache(i.key,e),t.resolve(i,e)})),0===_.length&&Object(h.d)("googlesitekit.dataLoaded","api")):console.error("data_error","unknown response key "+a)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(h.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){var t=["code","data","message"],a=Object(u.intersection)(t,Object.keys(e));if(Object(u.isEqual)(t,a)){console.warn("WP Error in data response",e);var n=e.data;if(n&&n.reason){var i=0;["authError","insufficientPermissions"].includes(n.reason)&&(Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(g.f)(r.a),1),i++),"forbidden"===n.reason&&(Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(g.f)(l.a),1),i++),i&&Object(h.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(h.f)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+i}))}}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},setCache:function(t,a){if(void 0!==a&&(!a||"object"!==s()(a)||!a.error&&!a.errors)){y(),e.googlesitekit.admin.datacache[t]=Object(u.cloneDeep)(a);var n={value:a,date:Date.now()/1e3};Object(g.o)().setItem("googlesitekit_"+t,JSON.stringify(n))}},getCache:function(t,a){if(!e.googlesitekit.admin.nojscache){if(y(),void 0!==e.googlesitekit.admin.datacache[t])return e.googlesitekit.admin.datacache[t];var n=JSON.parse(Object(g.o)().getItem("googlesitekit_"+t));return n&&"object"===s()(n)&&n.date&&(!a||Date.now()/1e3-n.date<a)?(e.googlesitekit.admin.datacache[t]=Object(u.cloneDeep)(n.value),Object(u.cloneDeep)(e.googlesitekit.admin.datacache[t])):void 0}},deleteCache:function(t){y(),delete e.googlesitekit.admin.datacache[t],Object(g.o)().removeItem("googlesitekit_"+t)},invalidateCacheGroup:function(t,a,n){var i=this.getCacheKey(t,a,n);y(),Object.keys(e.googlesitekit.admin.datacache).forEach((function(t){0!==t.indexOf(i+"::")&&t!==i||delete e.googlesitekit.admin.datacache[t]})),Object.keys(Object(g.o)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(i,"::"))&&e!=="googlesitekit_".concat(i)||Object(g.o)().removeItem(e)}))},collectModuleData:function(e,t){var a=Object(h.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==a.length&&this.combinedGet(a)},get:function(e,t,a){var n=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=this.getCacheKey(e,t,a,i);if(!o){var r=this.getCache(s,3600);if(void 0!==r)return new Promise((function(e){e(r)}))}return Object(m.default)({path:Object(p.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(a),i)}).then((function(e){return o||n.setCache(s,e),Promise.resolve(e)})).catch((function(e){return n.handleWPError(e),Promise.reject(e)}))},set:function(e,t,a,n){var i={};return i.data=n,Object(m.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(a),data:i,method:"POST"}).then((function(n){return S.invalidateCacheGroup(e,t,a),new Promise((function(e){e(n)}))}))},getCacheKey:function(e,t,a){for(var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,a],r=0,l=o;r<l.length;r++){var c=l[r];if(!c||!c.length)break;i.push(c)}return 3===i.length&&n&&"object"===s()(n)&&Object.keys(n).length&&i.push(d()(JSON.stringify(Object(g.y)(n)))),i.join("::")},setModuleActive:function(e,t){return this.set(f,"modules","activation",{slug:e,active:t})}};S.init(),t.c=S}).call(this,a(15))},,,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"e",(function(){return s})),a.d(t,"c",(function(){return l})),a.d(t,"d",(function(){return c})),a.d(t,"b",(function(){return d})),a.d(t,"f",(function(){return g})),a.d(t,"h",(function(){return u})),a.d(t,"a",(function(){return m})),a.d(t,"j",(function(){return p})),a.d(t,"i",(function(){return h})),a.d(t,"k",(function(){return b})),a.d(t,"g",(function(){return _}));var n=a(3),i=a(13),o=a(0),s=function(e){if(!e||!e.length)return null;var t=e[0].data,a=t.rows,n=t.totals[0].values[0],o=[["Source","Percent"]];return Object(i.each)(a,(function(e){var t=e.metrics[0].values[0]/n;if(1>100*t)return!1;var a=e.dimensions[0].replace(/\(none\)/gi,"direct");o.push([a,t])})),o};function r(e,t){var a=[];return Object(i.each)(e,(function(e){if(e.metrics){var n=e.metrics[0].values,i=e.dimensions[0],o=i.slice(0,4)+"-"+i.slice(4,6)+"-"+i.slice(6,8),s=new Date(o);a.push([s,n[t]])}})),a}var l=function(e,t,a){if(!e||!e.length)return null;var n=e[0].data.rows;if(!n)return!1;var s=n.length;if(2*a>s){for(var l=new Date,c=0;a>c;c++){var d=(l.getMonth()+1).toString(),g=l.getDate().toString(),u=l.getFullYear().toString()+(2>d.length?"0":"")+d+(2>g.length?"0":"")+g;if(c>s){var m={dimensions:[u],metrics:[{values:[0,0,0,0,0]}]};n.unshift(m)}l.setDate(l.getDate()-1)}n.push([0,0])}var p=[Object(o.__)("Users","google-site-kit"),Object(o.__)("Sessions","google-site-kit"),Object(o.__)("Bounce Rate","google-site-kit"),Object(o.__)("Session Duration","google-site-kit")],h=[[{type:"date",label:Object(o.__)("Day","google-site-kit")},{type:"number",label:p[t]},{type:"number",label:Object(o.__)("Previous month","google-site-kit")}]],b=n.slice(n.length-a,n.length),_=n.slice(0,n.length-a),f=r(b,t),k=r(_,t);return Object(i.each)(f,(function(e,t){e[0]&&e[1]&&k[t]&&h.push([e[0],e[1],k[t][1]])})),h},c=function(e){if(!e||!e.length)return null;var t=e[0].data.rows,a=[[{type:"date",label:"Day"},{type:"number",label:"Users"},{type:"number",label:"Sessions"},{type:"number",label:"Goals Completed"}]];return Object(i.each)(t,(function(e){var t=e.metrics[0].values,n=e.dimensions[0],i=n.slice(0,4)+"-"+n.slice(4,6)+"-"+n.slice(6,8),o=new Date(i);a.push([o,t[0],t[1],t[4]])})),a},d=function(e){if(!e||!e.length)return!1;var t=e[0].data.totals,a=t[0].values,i=t[1].values,o=a[0],s=a[1],r=a[2],l=a[3],c=a[4],d=a[5];return{totalUsers:o,totalSessions:s,averageBounceRate:r,averageSessionDuration:l,totalUsersChange:Object(n.b)(i[0],a[0]),totalSessionsChange:Object(n.b)(i[1],a[1]),averageBounceRateChange:Object(n.b)(i[2],a[2]),averageSessionDurationChange:Object(n.b)(i[3],a[3]),goalCompletions:c,goalCompletionsChange:Object(n.b)(i[4],a[4]),totalPageViews:d,totalPageViewsChange:Object(n.b)(i[5],a[5])}},g=function(e){return!(!e.error||!e.error.status)&&function(e,t){var a="";switch(e){case"INVALID_ARGUMENT":a=Object(o.__)("Analytics module needs to be configured.","google-site-kit");break;case"UNAUTHENTICATED":a=Object(o.__)("You need to be authenticated to get this data.","google-site-kit");break;case"PERMISSION_DENIED":a=Object(o.__)("Your account does not have sufficient permission to access this data, please consult to your web administrator.","google-site-kit");break;case"RESOURCE_EXHAUSTED":a=Object(o.__)("Your account exceeded the maximum quota. Please try again later.","google-site-kit");break;case"INTERNAL":a=Object(o.__)("Unexpected internal server error occurred.","google-site-kit");break;case"BACKEND_ERROR":a=Object(o.__)("Analytics server returned unknown error. Please try again later.","google-site-kit");break;case"UNAVAILABLE":a=Object(o.__)("The service was unable to process the request. Please try again later.","google-site-kit");break;default:a=t}return a}(e.error.status,e.error.message)},u=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,a=!0;return Object(i.each)(t,(function(e){0!==parseInt(e)&&(a=!1)})),a}return!1},m={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},p={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},h={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},b={dimensions:"ga:medium",metrics:[{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:users",alias:"Users"},{expression:"ga:newUsers",alias:"New Users"}],orderby:[{fieldName:"ga:sessions",sortOrder:"DESCENDING"}],limit:10},_=function(){var t=[{expression:"ga:pageviews",alias:"Pageviews"},{expression:"ga:uniquePageviews",alias:"Unique Pageviews"},{expression:"ga:bounceRate",alias:"Bounce rate"}];return e.googlesitekit.modules.analytics.settings.adsenseLinked&&t.push({expression:"ga:adsenseRevenue",alias:"AdSense Revenue"},{expression:"ga:adsenseECPM",alias:"AdSense ECPM"}),{dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:t,orderby:[{fieldName:"ga:pageviews",sortOrder:"DESCENDING"}],limit:10}}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function Link(){return i()(this,Link),l()(this,d()(Link).apply(this,arguments))}return u()(Link,t),s()(Link,[{key:"render",value:function(){var t=this.props,a=t.dangerouslySetInnerHTML,n=t.onClick,i=t.href,o=t.children,s=t.className,r=t.arrow,l=t.external,c=t.inverse,d=t.back,g=t.small,u=t.inherit,m=t.caps,p=t.danger,h=t.disabled,_=t.id,f=i&&!h,k=f?"a":"button";return e.createElement(k,{className:b()("googlesitekit-cta-link",s,{"googlesitekit-cta-link--arrow":r,"googlesitekit-cta-link--external":l,"googlesitekit-cta-link--inverse":c,"googlesitekit-cta-link--back":d,"googlesitekit-cta-link--small":g,"googlesitekit-cta-link--inherit":u,"googlesitekit-cta-link--caps":m,"googlesitekit-cta-link--danger":p,"googlesitekit-cta-link--disabled":h}),onClick:n,id:_,href:f?i:void 0,target:f&&l?"_blank":void 0,rel:l?"noopener noreferrer":void 0,disabled:h,dangerouslySetInnerHTML:a},o)}}]),Link}(_.Component);f.propTypes={dangerouslySetInnerHTML:p.a.shape({__html:p.a.string}),onClick:p.a.func,href:p.a.string,children:p.a.oneOfType([p.a.string.isRequired,p.a.array.isRequired]),className:p.a.string,arrow:p.a.bool,external:p.a.bool,inverse:p.a.bool,back:p.a.bool,small:p.a.bool,inherit:p.a.bool,caps:p.a.bool,danger:p.a.bool,disabled:p.a.bool},f.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=f}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(64),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(13),_=a(56),f=a(47),k=a(101),y=a(12),v=a(1),S=a(0);t.a=function(t,a){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{inGrid:!1,fullWidth:!1,createGrid:!1},l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){return!1},d=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(S.__)("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(S.__)("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 a=Object.values(e.errors);if(a[0]&&a[0][0])return a[0][0]}return!1};return function(u){function NewComponent(e){var t;r()(this,NewComponent),(t=g()(this,m()(NewComponent).call(this,e))).state={data:!1,zeroData:!1,error:!1},Object(y.a)("googlesitekit.moduleDataReset","googlesitekit.moduleDataResetHandler",(function(){t.setState({data:!1})}));var n=function(e,a){var n=t.props,i=n.handleDataError,o=n.handleDataSuccess,s=a.datapoint,r=a.identifier,c=a.toState,g=d(e);g?(t.setState({error:g,module:r}),i&&i(g)):l(e,s,a)?(i&&i(g),t.setState({zeroData:!0})):o&&o(),t.setState({requestDataToState:c,data:e,datapoint:s,module:r})};return Object(b.each)(a,(function(e){Array.isArray(e.context)?Object(b.each)(e.context,(function(t){Object(y.b)("googlesitekit.module".concat(t,"DataRequest"),"googlesitekit.data".concat(t),(function(t){return e.callback=function(t){n(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){n(t,e)},t.push(e),t}))})),t}return h()(NewComponent,u),c()(NewComponent,[{key:"render",value:function(){var a=this.state,r=a.data,l=a.datapoint,c=a.module,d=a.zeroData,g=a.error,u=a.requestDataToState;if(!r)return i;var m=c?e.googlesitekit.modules[c].name:Object(S.__)("Site Kit","google-site-kit");return c&&e.googlesitekit.modules[c].active&&!e.googlesitekit.modules[c].setupComplete?Object(k.a)(c,s.inGrid,s.fullWidth,s.createGrid):g?"string"!=typeof g?g:Object(f.a)(m,g,s.inGrid,s.fullWidth,s.createGrid):d?Object(_.a)(m,s.inGrid,s.fullWidth,s.createGrid):n.createElement(t,o()({data:r,datapoint:l,requestDataToState:u},this.props))}}]),NewComponent}(v.Component)}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";a.d(t,"a",(function(){return i}));var n=a(1),i=function(e){return function(t){return function FilteredComponent(a){return Object(n.createElement)(n.Fragment,{},"",Object(n.createElement)(t,a),e)}}}},function(e,t,a){"use strict";(function(e,n){var i=a(2),o=a.n(i),s=a(14),r=a.n(s),l=function SvgIcon(t){var a=t.id,i=t.className,o=t.height,s=t.width,l="".concat(e.googlesitekit.admin.assetsRoot,"svg/svg.svg");return n.createElement("svg",{className:r()("svg",i),height:o,width:s},n.createElement("use",{xlinkHref:"".concat(l,"#").concat(a)}))};l.propTypes={id:o.a.string.isRequired,className:o.a.string,height:o.a.string,width:o.a.string},l.defaultProps={className:"",height:20,width:20},t.a=l}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(70),i=a.n(n);a.d(t,"l",(function(){return i.a})),a.d(t,"a",(function(){return n.HelperText})),a.d(t,"b",(function(){return n.Input}));var o=a(120);a.d(t,"h",(function(){return o.a}));var s=a(127);a.d(t,"e",(function(){return s.a}));var r=a(128);a.d(t,"g",(function(){return r.a}));var l=a(88),c=a.n(l);a.d(t,"k",(function(){return c.a})),a.d(t,"j",(function(){return l.Option}));var d=a(126);a.d(t,"i",(function(){return d.a}));var g=a(124);a.d(t,"d",(function(){return g.a}));var u=a(125);a.d(t,"c",(function(){return u.a}));var m=a(123);a.d(t,"f",(function(){return m.a}))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(16),u=a.n(g),m=a(9),p=a.n(m),h=a(2),b=a.n(h),_=a(58),f=a(14),k=a.n(f),y=a(1),v=a(129),S=a(3),O=function(t){function DataBlock(e){var t;return i()(this,DataBlock),(t=l()(this,d()(DataBlock).call(this,e))).handleClick=t.handleClick.bind(u()(t)),t.handleKeyPress=t.handleKeyPress.bind(u()(t)),t}return p()(DataBlock,t),s()(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,a=t.stat,n=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||n(a)}},{key:"render",value:function(){var t=this.props,a=t.className,n=t.title,i=t.datapoint,o=t.datapointUnit,s=t.change,r=t.changeDataUnit,l=t.context,c=t.period,d=t.selected,g=t.handleStatSelection,u=t.source,m=t.sparkline,p=t.invertChangeColor,h="button"===l?"button":"",b=m;return b&&p&&(b=Object(y.cloneElement)(m,{invertChangeColor:p})),e.createElement("div",{className:k()("googlesitekit-data-block",a,"googlesitekit-data-block--".concat(l),{"googlesitekit-data-block--selected":d}),tabIndex:"button"===l?"0":"-1",role:g&&h,onClick:g&&this.handleClick,onKeyPress:g&&this.handleKeyPress,"aria-label":g&&n,"aria-pressed":g&&d},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},n),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(i).concat(o))),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"},""===s&&e.createElement(y.Fragment,null," "),s&&e.createElement(y.Fragment,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(v.a,{direction:0<parseFloat(s)?"up":"down",invertColor:p})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(S.s)(Math.abs(s))).concat(r," ").concat(c)))),u&&e.createElement(_.a,{className:"googlesitekit-data-block__source",name:u.name,href:u.link})))}}]),DataBlock}(y.Component);O.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},O.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=O}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function PreviewBlock(){return i()(this,PreviewBlock),l()(this,d()(PreviewBlock).apply(this,arguments))}return u()(PreviewBlock,t),s()(PreviewBlock,[{key:"render",value:function(){var t=this.props,a=t.width,n=t.height,i=t.shape,o=t.padding;return e.createElement("div",{className:b()("googlesitekit-preview-block",{"googlesitekit-preview-block--padding":o}),style:{width:a,height:n}},e.createElement("div",{className:b()("googlesitekit-preview-block__wrapper",{"googlesitekit-preview-block__wrapper--circle":"circular"===i})}))}}]),PreviewBlock}(_.Component);f.propTypes={width:p.a.string,height:p.a.string,shape:p.a.string,padding:p.a.bool},f.defaultProps={width:"100px",height:"100px",shape:"square",padding:!1},t.a=f}).call(this,a(1))},,function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return E})),a.d(t,"a",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(2),_=a.n(b),f=a(58),k=a(19),y=a(14),v=a.n(y),S=a(13),O=a(1),E=function(t,a,n){var i=[],o=n.links,s=n.source,r=n.showURLs;n.cap&&(t=t.slice(0,n.cap)),Object(S.each)(t,(function(t,a){var n=[],s=o&&o[a];Object(S.each)(t,(function(a,i){"string"==typeof a&&(a=a.replace(/\(none\)/gi,"direct")),n.push(e.createElement("td",{key:"cell-"+i,className:"googlesitekit-table__body-item"},t[0]===a&&s?e.createElement("div",{className:"googlesitekit-table__body-item-content"},e.createElement(k.a,{className:"googlesitekit-table__body-item-link",href:s,external:!0,inherit:!0},a),r&&""!==Object(S.trim)(s,"/")&&e.createElement(k.a,{className:"googlesitekit-table__body-item-url",href:s,inherit:!0,external:!0},Object(S.trim)(s,"/"))):e.createElement("div",{className:"googlesitekit-table__body-item-content"},a)))})),i.push(e.createElement("tr",{key:"tr-"+a,className:"googlesitekit-table__body-row"},n))}));var l=t&&t[0]&&t[0].length?t[0].length:1;return e.createElement("div",{className:v()("googlesitekit-table",{"googlesitekit-table--with-list":!n||!n.disableListMode})},e.createElement("table",{className:v()("googlesitekit-table__wrapper","googlesitekit-table__wrapper--".concat(l,"-col"))},e.createElement("thead",{className:"googlesitekit-table__head"},e.createElement("tr",{key:"gksc_data_row_header-wrap",style:n&&n.hideHeader?{display:"none"}:{},className:"googlesitekit-table__head-row"},a.map((function(t,a){return e.createElement("th",{key:"gksc_data_row_header-".concat(a),className:v()("googlesitekit-table__head-item",{"googlesitekit-table__head-item--primary":t.primary}),"data-tooltip":t.tooltip},t.title)})))),e.createElement("tbody",{className:"googlesitekit-table__body"},i)),s&&e.createElement(f.a,{className:"googlesitekit-table__source",name:s.name,href:s.link}))},j=function(t){function TableOverflowContainer(){var e;return o()(this,TableOverflowContainer),(e=c()(this,g()(TableOverflowContainer).call(this))).state={isScrolling:!1},e.scrollRef=Object(O.createRef)(),e.updateFadeOnScroll=e.updateFadeOnScroll.bind(m()(e)),e}return h()(TableOverflowContainer,t),r()(TableOverflowContainer,[{key:"componentDidMount",value:function(){var e=this;e.updateFadeOnScroll(),this.resize=Object(S.debounce)((function(){e.updateFadeOnScroll()}),100),n.addEventListener("resize",this.resize)}},{key:"componentWillUnmount",value:function(){n.removeEventListener("resize",this.resize)}},{key:"updateFadeOnScroll",value:function(){var e=this.scrollRef.current,t=e.scrollLeft,a=e.scrollWidth-e.offsetWidth,n=t<a-16&&0<a-16;this.setState({isScrolling:n})}},{key:"render",value:function(){var t=this.props.children,a=this.state.isScrolling;return e.createElement("div",{onScroll:Object(S.debounce)(this.updateFadeOnScroll,100),className:v()("googlesitekit-table-overflow",{"googlesitekit-table-overflow--gradient":a})},e.createElement("div",{ref:this.scrollRef,className:"googlesitekit-table-overflow__container"},t))}}]),TableOverflowContainer}(O.Component);j.propTypes={children:_.a.element}}).call(this,a(1),a(15))},,function(e,t,a){"use strict";(function(e){var n=a(21),i=a.n(n),o=a(11),s=a.n(o),r=a(5),l=a.n(r),c=a(6),d=a.n(c),g=a(7),u=a.n(g),m=a(8),p=a.n(m),h=a(16),b=a.n(h),_=a(9),f=a.n(_),k=a(2),y=a.n(k),v=a(10),S=a(26),O=a(33),E=a(74),j=a(85),D=a(19),C=a(24),w=a(14),A=a.n(w),x=a(13),N=a(1),P=a(72),T=function(t){function Notification(e){var t;return l()(this,Notification),(t=u()(this,p()(Notification).call(this,e))).state={isClosed:!1},t.cardRef=Object(N.createRef)(),t.handleDismiss=t.handleDismiss.bind(b()(t)),t.handleCTAClick=t.handleCTAClick.bind(b()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&v.c.setCache("notification::displayed::".concat(t.props.id),new Date),t}return f()(Notification,t),d()(Notification,[{key:"handleDismiss",value:function(e){var t;return s.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(e.persist(),e.preventDefault(),!(t=this.props.onDismiss)){a.next=6;break}return a.next=6,s.a.awrap(t(e));case 6:this.dismiss();case 7:case"end":return a.stop()}}),null,this)}},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){v.c.setCache("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var a=new Event("notificationDismissed");document.dispatchEvent(a)}),350)}},{key:"handleCTAClick",value:function(e){var t,a,n;return s.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e.persist(),t=this.props,a=t.isDismissable,!(n=t.onCTAClick)){i.next=5;break}return i.next=5,s.a.awrap(n(e));case 5:a&&this.dismiss();case 6:case"end":return i.stop()}}),null,this)}},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,a=e.dismissExpires,n=v.c.getCache("notification::dismissed::".concat(t));if(n){var i=new Date(n);i.setSeconds(i.getSeconds()+parseInt(a,10)),i<new Date&&v.c.deleteCache("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,a=this.state.isClosed,n=this.props,o=n.children,s=n.id,r=n.title,l=n.description,c=n.blockData,d=n.winImage,g=n.smallImage,u=n.format,m=n.learnMoreURL,p=n.learnMoreDescription,h=n.learnMoreLabel,b=n.ctaLink,_=n.ctaLabel,f=n.ctaTarget,k=n.type,y=n.dismiss,w=n.isDismissable,T=n.logo,L=n.module,I=n.moduleName,M=n.pageIndex;if(v.c.getCache("notification::dismissed::".concat(s)))return null;var W,R=a?"is-closed":"is-open",U="large"===u&&"win-stats-increase"===k,F="mdc-layout-grid__cell--span-12";"large"===u?(F="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 ",U&&(F="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"===u&&(F="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),W="win-warning"===k?e.createElement(E.a,null):"win-error"===k?e.createElement(j.a,null):"";var z=e.createElement(N.Fragment,null,c&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(x.map)(c,(function(t,a){return e.createElement("div",{key:a,className:A()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":U,"mdc-layout-grid__cell--span-4-desktop":!U})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(S.a,t)))})))),H=e.createElement(N.Fragment,null,r&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},r),l&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(N.isValidElement)(l)?l:e.createElement("span",{dangerouslySetInnerHTML:Object(P.a)(l,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),h&&e.createElement(N.Fragment,null," ",e.createElement(D.a,{href:m,external:!0,inherit:!0},h),p),M&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},M))),o),G=L?e.createElement(C.a,{id:L,height:"19",width:"19"}):e.createElement(C.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:A()("googlesitekit-publisher-win",(t={},i()(t,"googlesitekit-publisher-win--".concat(u),u),i()(t,"googlesitekit-publisher-win--".concat(k),k),i()(t,"googlesitekit-publisher-win--".concat(R),R),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},T&&e.createElement("div",{className:A()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":U,"mdc-layout-grid__cell--order-1-tablet":U})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},G),I&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},I)),g&&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:g})),e.createElement("div",{className:A()("mdc-layout-grid__cell",F)},U?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"},H),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"},z)):e.createElement(N.Fragment,null,H,z),b&&e.createElement(O.a,{href:b,target:f,onClick:this.handleCTAClick},_),w&&y&&e.createElement(D.a,{onClick:this.handleDismiss},y)),d&&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:d}))),("win-error"===k||"win-warning"===k)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},W)))))}}]),Notification}(N.Component);T.propTypes={id:y.a.string.isRequired,title:y.a.string.isRequired,description:y.a.node,learnMoreURL:y.a.string,learnMoreDescription:y.a.string,learnMoreLabel:y.a.string,blockData:y.a.array,winImage:y.a.string,smallImage:y.a.string,format:y.a.string,ctaLink:y.a.string,ctaLabel:y.a.string,type:y.a.string,dismiss:y.a.string,isDismissable:y.a.bool,logo:y.a.bool,module:y.a.string,moduleName:y.a.string,pageIndex:y.a.string,dismissExpires:y.a.number,showOnce:y.a.bool,onCTAClick:y.a.func,onDismiss:y.a.func},T.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=T}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function ProgressBar(){return i()(this,ProgressBar),l()(this,d()(ProgressBar).apply(this,arguments))}return u()(ProgressBar,t),s()(ProgressBar,[{key:"render",value:function(){var t=this.props,a=t.className,n=t.small,i=t.compress,o=t.height,s=o?Math.round(o/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:s,marginBottom:s},className:b()("mdc-linear-progress","mdc-linear-progress--indeterminate",a,{"mdc-linear-progress--small":n,"mdc-linear-progress--compress":i})},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}(_.Component);f.propTypes={className:p.a.string,small:p.a.bool,compress:p.a.bool},f.defaultProps={className:"",small:!1,compress:!1},t.a=f}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Button(e){var t;return i()(this,Button),(t=l()(this,d()(Button).call(this,e))).buttonRef=Object(f.createRef)(),t}return u()(Button,t),s()(Button,[{key:"componentDidMount",value:function(){new m.h(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,a=t.onClick,n=t.children,i=t.href,o=t.text,s=t.className,r=t.danger,l=t.disabled,c=t.target,d=t.id,g=t.icon,u=t.trailingIcon,m=t.ariaHaspopup,p=t.ariaExpanded,h=t.ariaControls,b=i&&!l?"a":"button";return e.createElement(b,{className:_()("mdc-button",s,{"mdc-button--raised":!o,"mdc-button--danger":r}),onClick:a,href:l?void 0:i,ref:this.buttonRef,disabled:!!l,target:c||"_self",id:d,"aria-haspopup":m,"aria-expanded":p,"aria-controls":h},g&&g,e.createElement("span",{className:"mdc-button__label"},n),u&&u)}}]),Button}(f.Component);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,a(1))},,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(19),b=a(14),_=a.n(b),f=a(1),k=function(t){function CTA(){return i()(this,CTA),l()(this,d()(CTA).apply(this,arguments))}return u()(CTA,t),s()(CTA,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.description,i=t.ctaLink,o=t.ctaLabel,s=t.error,r=t.onClick;return e.createElement("div",{className:_()("googlesitekit-cta",{"googlesitekit-cta--error":s})},a&&e.createElement("h3",{className:"googlesitekit-cta__title"},a),n&&e.createElement("p",{className:"googlesitekit-cta__description"},n),o&&e.createElement(h.a,{href:i,onClick:r,inverse:!s,caps:!0,arrow:!0},o))}}]),CTA}(f.Component);k.propTypes={title:p.a.string.isRequired,description:p.a.string,ctaLink:p.a.string,ctaLabel:p.a.string,error:p.a.bool,onClick:p.a.func},k.defaultProps={title:"",description:"",ctaLink:"",ctaLabel:"",error:!1,onClick:function(){}},t.a=k}).call(this,a(1))},,function(e,t,a){"use strict";function n(e){return{byContext:function(t){return e.filter((function(e){return e.usageContext.includes(t)}))}}}function i(e){return(parseInt(e)||0)>0}function o(e){return!!e&&e.toString().match(/^GTM-[A-Z0-9]+$/)}var s=[/<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]+)['|"]/];a.d(t,"a",(function(){return n})),a.d(t,"b",(function(){return i})),a.d(t,"c",(function(){return o})),a.d(t,"d",(function(){return s}))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(27),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function PreviewTable(){return i()(this,PreviewTable),l()(this,d()(PreviewTable).apply(this,arguments))}return u()(PreviewTable,t),s()(PreviewTable,[{key:"render",value:function(){for(var t=this.props,a=t.rows,n=t.rowHeight,i=t.padding,o=[],s=0;a>s;s++)o.push(e.createElement("div",{className:"googlesitekit-preview-table__row",key:"table-row-"+s},e.createElement(m.a,{width:"100%",height:n+"px"})));return e.createElement("div",{className:_()("googlesitekit-preview-table",{"googlesitekit-preview-table--padding":i})},o)}}]),PreviewTable}(f.Component);k.propTypes={rows:h.a.number,rowHeight:h.a.number,padding:h.a.bool},k.defaultProps={rows:11,rowHeight:35,padding:!1},t.a=k}).call(this,a(1))},function(e,t,a){"use strict";a.d(t,"a",(function(){return s})),a.d(t,"b",(function(){return r}));var n=a(3),i=a(13);function o(e){var t=[[{type:"string",label:"Day"},{type:"number",label:"Clicks"},{type:"number",label:"Impressions"},{type:"number",label:"CTR"},{type:"number",label:"Position"}]],a=0,o=0,s=0,r=0,l=e.length;Object(i.each)(e,(function(e){var n=new Date(e.keys[0]);t.push([n.getMonth()+1+"/"+n.getUTCDate(),e.clicks,e.impressions,e.ctr,e.position]),a+=e.clicks,o+=e.impressions,s+=e.ctr,r+=e.position}));var c=a,d=o;a=Object(n.u)(a),o=Object(n.u)(o);var g=(s/l*100).toFixed(1),u=s/l,m=(r/l).toFixed(1);return{dataMap:t,totalClicks:a,totalClicksRaw:c,totalImpressions:o,totalImpressionsRaw:d,averageCTR:g,averageCTRRaw:u,averagePosition:m}}var s=function(e){var t=Math.floor(e.length/2),a=o(e.slice(t)),i=o(e.slice(0,t));return{dataMap:a.dataMap,totalClicks:a.totalClicks,totalImpressions:a.totalImpressions,averageCTR:a.averageCTR,averagePosition:a.averagePosition,totalClicksChange:Object(n.b)(i.totalClicksRaw,a.totalClicksRaw),totalImpressionsChange:Object(n.b)(i.totalImpressionsRaw,a.totalImpressionsRaw),averageCTRChange:Object(n.b)(i.averageCTRRaw,a.averageCTRRaw),averagePositionChange:Object(n.b)(i.averagePosition,a.averagePosition)}},r=function(e){if(!e.length)return!0;var t=s(e),a=t.totalClicks,n=t.totalImpressions,i=t.averageCTR,o=t.averagePosition;return 0===parseInt(a)&&0===parseInt(n)&&0===parseInt(i)&&0===parseInt(o)}},,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(1),b=function(t){function DashboardModuleHeader(){return i()(this,DashboardModuleHeader),l()(this,d()(DashboardModuleHeader).apply(this,arguments))}return u()(DashboardModuleHeader,t),s()(DashboardModuleHeader,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.description;return e.createElement("header",{className:"googlesitekit-dashboard-module-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},a&&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 "},a),n&&e.createElement("p",{className:"googlesitekit-dashboard-module-header__description"},n))))}}]),DashboardModuleHeader}(h.Component);b.propTypes={title:p.a.string,description:p.a.string},b.defaultProps={title:"",description:""},t.a=b}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"e",(function(){return g})),a.d(t,"d",(function(){return u})),a.d(t,"a",(function(){return m})),a.d(t,"b",(function(){return p})),a.d(t,"c",(function(){return h}));var n=a(11),i=a.n(n),o=a(199),s=a(10),r=a(3),l=a(13),c=a(0),d=a(18);function g(e){var t=[[{type:"date",label:"Day"},{type:"number",label:"RPM"},{type:"number",label:"Earnings"},{type:"number",label:"Impressions"}]];return Object(l.each)(e,(function(e){var a=new Date(e[0]);t.push([a,e[2],e[1],e[3]])})),{dataMap:t}}var u=function(t,a){var n,i,s,l,d,g,u,m,p,h,b,_,f,k=!1,y=!1,v=!1,S=!1,O=!1,E=!1,j=e.googlesitekit.modules.adsense,D=j.accountURL,C=j.signupURL,w=Object(r.n)("googlesitekit-module-adsense",{}),A=new URL(e.googlesitekit.admin.siteURL);switch(t){case"account-connected":a?(m=!1,u="alert",p=Object(c.__)("Site Kit will place AdSense code to your site","google-site-kit"),h=Object(c.__)("This means Google will automatically place ads for you in all the best places.","google-site-kit"),i=Object(c.__)("Continue","google-site-kit"),n=w,k=!0,b=Object(c.__)("Let Site Kit place code on your site","google-site-kit"),_=Object(c.__)("If you don’t let Site Kit place the code you may not get the best ads experience. You can set this up later on the Site Kit settings page.","google-site-kit"),f=Object(c.__)("If you’ve already set up ads on your site, it may change how they appear. You can customize this later in AdSense.","google-site-kit")):(m=!1,u=!1,p=Object(c.__)("Looks like you’re already using AdSense","google-site-kit"),h=Object(c.__)("Site Kit will place AdSense code on your site to connect your site to AdSense and help you get the most out of ads. This means Google will automatically place ads for you in all the best places.","google-site-kit"),i=Object(c.__)("Continue","google-site-kit"),n=w,E={eventCategory:"adsense_setup",eventName:"complete_adsense_setup"},b=Object(c.__)("Let Site Kit place code on your site to get your site approved","google-site-kit"),_=Object(c.__)("If you’ve already got some AdSense code on your site, we recommend you use Site Kit to place code to get the most out of AdSense.","google-site-kit"));break;case"account-connected-nonmatching":m=!1,u=!1,p=Object(c.__)("Your site has code from another AdSense account","google-site-kit"),h=Object(c.__)("We’ve found some AdSense code on your site, but it’s not linked to this AdSense account.","google-site-kit"),S=!1,i=Object(c.__)("Switch Google account","google-site-kit"),n=Object(r.m)("adsense",!0),y={accountStatus:"account-connected",continueText:Object(c.__)("Continue anyway","google-site-kit"),statusHeadline:Object(c.__)("Site Kit will place AdSense code on your site","google-site-kit"),statusMessage:Object(c.__)("To connect your site to your AdSense account, Site Kit will place AdSense code on your site. For a better ads experience, you should remove AdSense code that’s not linked to this AdSense account.","google-site-kit"),profile:!0,ctaLink:w,ctaLinkText:Object(c.__)("Continue","google-site-kit"),continueAction:!1,switchLabel:Object(c.__)("Let Site Kit place code on your site","google-site-kit"),switchOffMessage:Object(c.__)("You can let Site Kit do this later.","google-site-kit")};break;case"ads-display-pending":var x=Object(o.parse)(A.hostname).domain;p=Object(c.__)("Let’s get your site ready for ads","google-site-kit"),h=Object(c.__)("After you’ve finished setting up your account, we’ll let you know when your site is ready to show ads. This usually takes less than a day, but it can sometimes take a bit longer.","google-site-kit"),i=Object(c.__)("Go to your AdSense account to check on your site’s status or to complete setting up","google-site-kit"),n="https://www.google.com/adsense/new/sites?url=".concat(x||A.hostname,"&source=site-kit");break;case"account-pending-review":p=Object(c.__)("We’re getting your site ready for ads","google-site-kit"),h=Object(c.__)("AdSense is reviewing your site. Meanwhile, make sure you’ve completed these steps in AdSense.","google-site-kit"),i=Object(c.__)("Go to your AdSense account to check on your site’s status","google-site-kit"),n="https://www.google.com/adsense/new/sites?url=".concat(A.hostname,"&source=site-kit"),v=!0;break;case"account-required-action":O=!0;break;case"disapproved-account":n=D,i=Object(c.__)("Go to AdSense to find out how to fix the issue","google-site-kit"),p=Object(c.__)("Your site isn’t ready to show ads yet","google-site-kit"),h=Object(c.__)("You need to fix some things before we can connect Site Kit to your AdSense account.","google-site-kit");break;case"disapproved-account-afc":m=Object(c.__)("There is an AdSense account, but the AFC account is disapproved","google-site-kit"),u="error",p=Object(c.__)("Create Account","google-site-kit"),h=Object(c.__)("Create an AdMob account, then open AdSense and try to upgrade.","google-site-kit"),i=Object(c.__)("Create an AdMob Account","google-site-kit"),n="https://google.com/admob";break;case"no-account":p=Object(c.__)("Create your AdSense account","google-site-kit"),h=Object(c.__)("Site Kit will place AdSense code on every page across your site. This means Google will automatically place ads for you in all the best places.","google-site-kit"),S=!0,i=Object(c.__)("Create AdSense Account","google-site-kit"),n=C,g=Object(c.__)("Already have an AdSense account?","google-site-kit"),s=Object(c.__)("to connect to it","google-site-kit"),l=Object(c.__)("Switch Google account","google-site-kit"),d=Object(r.m)("adsense",!0),E={eventCategory:"adsense_setup",eventName:"create_adsense_account"};break;case"no-account-tag-found":p=Object(c.__)("Looks like you’re already using AdSense","google-site-kit"),h=Object(c.__)("We’ve found some AdSense code on your site, but it’s not linked to this Google account.","google-site-kit"),S=!1,i=Object(c.__)("Switch Google account","google-site-kit"),n=Object(r.m)("adsense",!0),b=Object(c.__)("Let Site Kit place code on your site to get your site approved","google-site-kit"),y={statusHeadline:Object(c.__)("Create a new AdSense account","google-site-kit"),statusMessage:Object(c.__)("Site Kit will place additional AdSense code on every page across your site after you create an account. This means Google will automatically place ads for you in all the best places.","google-site-kit"),notice:Object(c.__)("We recommend you remove the old AdSense code from this site.","google-site-kit"),icon:"warning",continueText:Object(c.__)("Continue anyway","google-site-kit"),ctaLinkText:Object(c.__)("Create AdSense Account","google-site-kit"),ctaLink:C,ctaTarget:"_blank",continueAction:!1};break;case"account-connected-no-data":p=Object(c.__)("We’re getting your site ready for ads","google-site-kit"),h=Object(c.__)("AdSense is reviewing your site. Meanwhile, make sure you’ve completed these steps in AdSense.","google-site-kit"),v=!0}return{accountTagMatch:k,continueAction:y,ctaLink:n,ctaLinkText:i,footerAppendedText:s,footerCTA:l,footerCTALink:d,footerText:g,icon:u,incomplete:v,issue:m,profile:S,required:O,setupComplete:!1,statusHeadline:p,statusMessage:h,switchLabel:b,switchOffMessage:_,switchOnMessage:f,tracking:E}},m=function(){var t,a,n,o,d,g,u,m,p,h,b,_,f,k,y,v,S,O,E,j,D,C,w,A,x,N,P,T,L,I=arguments;return i.a.async((function(M){for(;;)switch(M.prev=M.next){case 0:return t=I.length>0&&void 0!==I[0]&&I[0],a=I.length>1&&void 0!==I[1]?I[1]:function(){},o=!1,M.prev=3,a(Object(c.__)("Locating accounts…","google-site-kit")),M.next=7,i.a.awrap(s.c.get(s.b,"adsense","accounts").then((function(e){return e})).catch((function(e){return e})));case 7:if(d=M.sent,!(1<(g=!d.data||d.data.status&&200!==d.data.status?d:d.data).length)){M.next=42;break}a(Object(c.__)("Searching for domain…","google-site-kit")),u=!0,m=!1,p=void 0,M.prev=14,h=g[Symbol.iterator]();case 16:if(u=(b=h.next()).done){M.next=28;break}return _=b.value,f=_.id,M.next=21,i.a.awrap(s.c.get(s.b,"adsense","urlchannels",{clientID:f}).then((function(e){return e})).catch((function(e){return e})));case 21:k=M.sent,y=new URL(e.googlesitekit.admin.siteURL),(v=k&&k.length?Object(l.filter)(k,{urlPattern:y.hostname}):[])&&0!==v.length?(O=v[0].id,Object(r.A)("adsense_setup","adsense_account_detected")):(n="account-pending-review",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status account-pending-review"));case 25:u=!0,M.next=16;break;case 28:M.next=34;break;case 30:M.prev=30,M.t0=M.catch(14),m=!0,p=M.t0;case 34:M.prev=34,M.prev=35,u||null==h.return||h.return();case 37:if(M.prev=37,!m){M.next=40;break}throw p;case 40:return M.finish(37);case 41:return M.finish(34);case 42:if(S=g&&g.message&&g.message.error,O=!!(g&&g.length&&g[0])&&g[0].id,g&&O&&!S){M.next=50;break}E=(S||{}).errors,"noAdSenseAccount"!==(j=E[0].reason)&&g&&O||(n="disapprovedAccount"===j?"disapproved-account":t?"no-account-tag-found":"no-account"),M.next=118;break;case 50:return e.googlesitekit.modules.adsense.accountURL=Object(c.sprintf)("https://www.google.com/adsense/new/%s/home",O),a(Object(c.__)("Account found, checking account status…","google-site-kit")),M.next=54,i.a.awrap(s.c.get(s.b,"adsense","alerts",{accountID:O}).then((function(e){return e})).catch((function(e){return e})));case 54:if(D=M.sent,C=!D.data||D.data.status&&200!==D.data.status?D:D.data,w=C&&C.message&&C.message.error,!Object(l.find)(D,{type:"GRAYLISTED_PUBLISHER"})){M.next=62;break}n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending"),M.next=118;break;case 62:return M.next=64,i.a.awrap(s.c.get(s.b,"adsense","clients").then((function(e){return e})).catch((function(e){return e})));case 64:if(A=M.sent,x=!A.data||A.data.status&&200!==A.data.status?A:A.data,N=x&&x.message&&x.message.error,!(P=!(!x||!x.length)&&Object(l.find)(x,{productCode:"AFC"}))){M.next=72;break}return o=P.id,M.next=72,i.a.awrap(s.c.set(s.b,"adsense","client-id",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 72:if(!w){M.next=77;break}"accountPendingReview"===C.message.error.errors[0].reason&&(n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending")),M.next=118;break;case 77:if(a(Object(c.__)("Looking for AdSense client…","google-site-kit")),!N){M.next=83;break}n="account-required-action",Object(r.A)("adsense_setup","adsense_required_action","accountRequiredAction status"),M.next=118;break;case 83:if(!P){M.next=117;break}return o=P.id,a(Object(c.__)("Looking for site domain…","google-site-kit")),M.next=88,i.a.awrap(s.c.get(s.b,"adsense","urlchannels",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 88:if(T=M.sent,L=T&&T.length&&Object(l.filter)(T,(function(t){return 0<e.googlesitekit.admin.siteURL.indexOf(t.urlPattern)})),0!==T.length){M.next=95;break}n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending"),M.next=115;break;case 95:if(L&&0!==L.length){M.next=100;break}n="account-pending-review",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status account-pending-review"),M.next=115;break;case 100:if(!t||o!==t){M.next=105;break}n="account-connected",Object(r.A)("adsense_setup","adsense_account_connected","existing_matching_tag"),M.next=115;break;case 105:if(!t||o===t){M.next=110;break}n="account-connected-nonmatching",Object(r.A)("adsense_setup","adsense_account_connected","existing_non_matching_tag"),M.next=115;break;case 110:return n="account-connected",a(Object(c.__)("Connecting…","google-site-kit")),Object(r.A)("adsense_setup","adsense_account_connected"),M.next=115,i.a.awrap(s.c.set(s.b,"adsense","setup-complete",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 115:M.next=118;break;case 117:n="disapproved-account-afc";case 118:return M.next=120,i.a.awrap(s.c.set(s.b,"adsense","account-status",{accountStatus:n}).then((function(e){return e})).catch((function(e){return e})));case 120:return M.abrupt("return",{accountStatus:n,clientID:o});case 123:return M.prev=123,M.t1=M.catch(3),M.abrupt("return",{isLoading:!1,error:M.t1.code,message:M.t1.message});case 126:case"end":return M.stop()}}),null,null,[[3,123],[14,30,34,42],[35,,37,41]])},p=function(){var t,a,n;return i.a.async((function(o){for(;;)switch(o.prev=o.next){case 0:if(t=e.googlesitekit.modules.adsense.active,a=e.googlesitekit.modules.analytics.active,n=!0,!t||!a){o.next=6;break}return o.next=6,i.a.awrap(s.c.get(s.b,"analytics","report",d.a).then((function(e){e&&(n=!0)})).catch((function(e){400===e.code&&"INVALID_ARGUMENT"===e.message&&(n=!1)})));case 6:return o.abrupt("return",new Promise((function(e){e(n)})));case 7:case"end":return o.stop()}}))},h=function(e,t,a){if(!a.data||!a.data.dateRange||"last-28-days"!==a.data.dateRange)return!1;var n=[];return e.totals&&(n=e.totals),0===(n=n.filter((function(e){return 0<e}))).length}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){var n=a(37),i=a(82),o=a(3),s=a(198),r=a(0);t.a=function(t,a){var l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],d=arguments.length>4&&void 0!==arguments[4]&&arguments[4],g=e.createElement(n.a
|
5 |
+
/* translators: %s: module name */,{title:Object(r.sprintf)(Object(r.__)("Data error in %s","google-site-kit"),t),description:a,error:!0});return"Invalid Credentials"===a&&Object(o.x)(s.a),Object(i.a)(g,l,c,d)}}).call(this,a(1))},,,,,function(e,t,a){"use strict";(function(e){var n=a(36),i=a.n(n);e._googlesitekitAPIFetchData&&(e._googlesitekitAPIFetchData.rootURL&&i.a.use(i.a.createRootURLMiddleware(e._googlesitekitAPIFetchData.rootURL)),e._googlesitekitAPIFetchData.nonceMiddleware&&(i.a.nonceMiddleware=i.a.createNonceMiddleware(),i.a.use(i.a.createNonceMiddleware(e._googlesitekitAPIFetchData.nonceMiddleware)),i.a.use(i.a.mediaUploadMiddleware),i.a.nonceEndpoint=e._googlesitekitAPIFetchData.nonceEndpoint)),t.default=i.a}).call(this,a(15))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(57),p=a(2),h=a.n(p),b=a(247),_=a(1),f=function(t){function Sparkline(){return i()(this,Sparkline),l()(this,d()(Sparkline).apply(this,arguments))}return u()(Sparkline,t),s()(Sparkline,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.change,i=t.instanceId,o=t.invertChangeColor,s=t.loadSmall,r=t.loadCompressed,l=t.loadHeight,c=t.loadText;if(!a)return"loading...";var d=o?"red":"green",g=o?"green":"red",u={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(n)||0)?d:g]};return e.createElement("div",{className:"googlesitekit-analytics-sparkline-chart-wrap"},e.createElement(m.a,{data:a,options:u,id:"googlesitekit-sparkline-".concat(i),loadSmall:s,loadCompressed:r,loadHeight:l,loadText:c}))}}]),Sparkline}(_.Component);f.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},f.defaultProps={invertChangeColor:!1,loadSmall:!0,loadCompressed:!0,loadHeight:46,loadText:!1},t.a=Object(b.a)(f)}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){var n=a(37),i=a(82),o=a(0);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],s=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],l=e.createElement(n.a
|
6 |
+
/* translators: %s: Module name */,{title:Object(o.sprintf)(Object(o.__)("%s Gathering Data","google-site-kit"),t)
|
7 |
+
/* translators: %s: Module name */,description:Object(o.sprintf)(Object(o.__)("%s data is not yet available, please check back later.","google-site-kit"),t)});return Object(i.a)(l,a,s,r)}}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i,o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),g=a(8),u=a.n(g),m=a(16),p=a.n(m),h=a(9),b=a.n(h),_=a(11),f=a.n(_),k=a(32),y=a(2),v=a.n(y),S=a(0),O=a(1),E=a(13);function j(){var t;return f.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(!i){a.next=2;break}return a.abrupt("return",i);case 2:return e.google&&e.google.charts?i=Promise.resolve():((t=document.createElement("script")).type="text/javascript",i=new Promise((function(a){t.onload=a,e.document.head.appendChild(t),t.src="https://www.gstatic.com/charts/loader.js"}))),a.abrupt("return",i);case 4:case"end":return a.stop()}}))}var D=function(t){function GoogleChart(e){var t;return s()(this,GoogleChart),(t=d()(this,u()(GoogleChart).call(this,e))).state={loading:!0,chart:null},t.onChartsLoad=t.onChartsLoad.bind(p()(t)),t.waitForChart=t.waitForChart.bind(p()(t)),t.getData=t.getData.bind(p()(t)),t.prepareChart=t.prepareChart.bind(p()(t)),t.drawChart=t.drawChart.bind(p()(t)),t.updateChart=t.updateChart.bind(p()(t)),t.chartRef=Object(O.createRef)(),t.resize=Object(E.debounce)(t.drawChart,100),t}return b()(GoogleChart,t),l()(GoogleChart,[{key:"onChartsLoad",value:function(){this.getData(),this.prepareChart(),this.drawChart(),this.setState({loading:!1})}},{key:"componentDidMount",value:function(){return f.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.awrap(j());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()}}),null,this)}},{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 a="pie"===this.props.chartType?new e.google.visualization.PieChart(t):new e.google.visualization.LineChart(t);this.setState({chart:a})}else this.waitForChart(this.prepareChart)}},{key:"drawChart",value:function(){var e=this.state.chart,t=this.props,a=t.selectedStats,n=t.options,i=this.getData();null!==i&&null!==e?(e.draw(i,n),0!==a.length&&this.updateChart()):this.waitForChart(this.drawChart)}},{key:"updateChart",value:function(){var t=this.state.chart,a=this.props,n=a.selectedStats,i=a.options,o=a.singleStat,s=this.getData();if(null!==s&&null!==t){var r=new e.google.visualization.DataView(s);if(!o){var l=[0];l=l.concat(n.map((function(e){return e+1}))),r.setColumns(l)}t.draw(r,i)}else this.waitForChart(this.drawChart)}},{key:"render",value:function(){var e=this.state.loading,t=this.props,a=t.className,i=t.loadSmall,o=t.loadCompressed,s=t.loadHeight,r=t.loadText;return n.createElement("div",{className:"googlesitekit-graph-wrapper"},n.createElement("div",{ref:this.chartRef,className:"googlesitekit-line-chart"},n.createElement("div",{className:"googlesitekit-chart-loading"},e&&n.createElement("div",{className:"googlesitekit-chart-loading__wrapper"},r&&n.createElement("p",null,Object(S.__)("Loading chart...","google-site-kit")),n.createElement(k.a,{className:a,small:i,compress:o,height:s})))))}}]),GoogleChart}(O.Component);D.propTypes={selectedStats:v.a.array,options:v.a.object.isRequired,id:v.a.string,singleStat:v.a.bool,className:v.a.string,loadSmall:v.a.bool,loadCompressed:v.a.bool,loadHeight:v.a.number,loadText:v.a.bool},D.defaultProps={selectedStats:[],id:"",singleStat:!0,className:"",loadSmall:!1,loadCompressed:!1,loadHeight:null,loadText:!0},t.a=D}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(2),p=a.n(m),h=a(19),b=a(14),_=a.n(b),f=a(1),k=a(0),y=function(t){function SourceLink(){return i()(this,SourceLink),l()(this,d()(SourceLink).apply(this,arguments))}return u()(SourceLink,t),s()(SourceLink,[{key:"render",value:function(){var t=this.props,a=t.name,n=t.href,i=t.className,o=t.external;return e.createElement("div",{className:_()("googlesitekit-source-link",i)},[Object(k.__)("Source:","google-site-kit")," ",e.createElement(h.a,{key:"link",href:n,external:o,inherit:!0},a)])}}]),SourceLink}(f.Component);y.propTypes={name:p.a.string,href:p.a.string,className:p.a.string,external:p.a.bool},y.defaultProps={name:"",href:"",className:"",external:!1},t.a=y}).call(this,a(1))},,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(150),p=a(14),h=a.n(p),b=a(2),_=a.n(b),f=a(24),k=a(1),y=a(12),v=function(t){function PageHeader(){return i()(this,PageHeader),l()(this,d()(PageHeader).apply(this,arguments))}return u()(PageHeader,t),s()(PageHeader,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.icon,i=t.iconWidth,o=t.iconHeight,s=t.iconID,r=t.className,l=t.status,c=t.statusText,d=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",g=Object(y.c)("googlesitekit.showDateRangeSelector-".concat(s),!1),u=!(""===l&&!g);return e.createElement("header",{className:"googlesitekit-page-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},a&&e.createElement("div",{className:d},n&&e.createElement(f.a,{id:s,height:o,width:i,className:"googlesitekit-page-header__icon"}),e.createElement("h1",{className:h()("googlesitekit-page-header__title",r)},a)),u&&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"},l&&e.createElement("span",{className:h()("googlesitekit-page-header__status","googlesitekit-page-header__status--".concat(l))},c),g&&e.createElement("span",{className:"googlesitekit-page-header__range"},e.createElement(m.a,null))))))}}]),PageHeader}(k.Component);v.propTypes={title:_.a.string,icon:_.a.bool,iconID:_.a.string,iconWidth:_.a.string,iconHeight:_.a.string,className:_.a.string,status:_.a.string,statusText:_.a.string,fullWidth:_.a.bool},v.defaultProps={title:"",icon:!1,iconID:"",iconWidth:"",iconHeight:"",className:"googlesitekit-heading-3",status:"",statusText:"",fullWidth:!1},t.a=v}).call(this,a(1))},,,function(e,t,a){"use strict";(function(e){var n=a(0),i=a(19);t.a=function HelpLink(){var t=Object(n.__)("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,a(1))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(31),p=a(1),h=function(t){function GenericError(){return i()(this,GenericError),l()(this,d()(GenericError).apply(this,arguments))}return u()(GenericError,t),s()(GenericError,[{key:"render",value:function(){return e.createElement(m.a,this.props)}}]),GenericError}(p.Component);t.a=h}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function ModuleSettingsWarning(){return i()(this,ModuleSettingsWarning),l()(this,d()(ModuleSettingsWarning).apply(this,arguments))}return u()(ModuleSettingsWarning,e),s()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(p.Component);t.a=Object(m.a)("googlesitekit.ModuleSettingsWarning")(h)},,,,function(e,t,a){"use strict";a.d(t,"a",(function(){return i}));var n=a(131),i=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:n.a.sanitize(e,t)}}},,function(e,t,a){"use strict";(function(e){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,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Switch(e){var t;return i()(this,Switch),(t=l()(this,d()(Switch).call(this,e))).switchRef=Object(f.createRef)(),t}return u()(Switch,t),s()(Switch,[{key:"componentDidMount",value:function(){new m.i(this.switchRef.current)}},{key:"render",value:function(){var t=this.props,a=t.id,n=t.onClick,i=t.label,o=t.checked,s=t.hideLabel;return e.createElement(f.Fragment,null,e.createElement("div",{"aria-checked":o?"true":"false",className:_()("mdc-switch",{"mdc-switch--checked":o}),onClick:n,onKeyPress:function(e){"function"==typeof n&&"Enter"===e.code&&n(e)},role:"switch",ref:this.switchRef,tabIndex:0},e.createElement("div",{className:"mdc-switch__track"}," "),e.createElement("div",{className:"mdc-switch__thumb-underlay"},e.createElement("div",{className:"mdc-switch__thumb"},e.createElement("input",{type:"checkbox",id:a,className:"mdc-switch__native-control",role:"switch",checked:o,onChange:function(){}})))),e.createElement("label",{className:_()({"screen-reader-only":s}),htmlFor:a},i))}}]),Switch}(f.Component);k.propTypes={id:h.a.string.isRequired,onClick:h.a.func,label:h.a.string.isRequired,checked:h.a.bool,hideLabel:h.a.bool},k.defaultProps={checked:!1,hideLabel:!0},t.a=k}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"d",(function(){return o})),a.d(t,"b",(function(){return s})),a.d(t,"c",(function(){return r})),a.d(t,"a",(function(){return l}));var n=a(0);function i(e){return.9<=e?"fast":.5<=e?"average":"slow"}var o=function(e){var t=i(e);return"fast"===t?Object(n.__)("Fast","google-site-kit"):"average"===t?Object(n.__)("Average","google-site-kit"):Object(n.__)("Slow","google-site-kit")},s=function PageSpeedReportScoreCategoryWrapper(t){var a=t.score,n=t.children,o="googlesitekit-pagespeed-report__score-category-wrapper googlesitekit-pagespeed-report__score-category-wrapper--".concat(i(a)),s="googlesitekit-pagespeed-report__score-icon googlesitekit-pagespeed-report__score-icon--".concat(i(a));return e.createElement("span",{className:o},n," ",e.createElement("span",{className:s}))},r=function PageSpeedReportScoreGauge(t){var a=t.score,o=parseInt(100*a,10),s="\n\t\tgooglesitekit-percentage-circle\n\t\tgooglesitekit-percentage-circle--".concat(i(a),"\n\t\tgooglesitekit-percentage-circle--percent-").concat(o,"\n\t");return e.createElement("div",{className:"googlesitekit-pagespeed-report__score-gauge"},e.createElement("div",{className:s},e.createElement("div",{className:"googlesitekit-percentage-circle__text"},o),e.createElement("div",{className:"googlesitekit-percentage-circle__slice"},e.createElement("div",{className:"googlesitekit-percentage-circle__bar"}),e.createElement("div",{className:"googlesitekit-percentage-circle__fill"}))),e.createElement("span",{className:"googlesitekit-pagespeed-report__score-gauge-label screen-reader-only"},Object(n.__)("Performance","google-site-kit")))},l=function PageSpeedReportScale(){return e.createElement("div",{className:"googlesitekit-pagespeed-report__scale"},e.createElement("span",null,Object(n.__)("Scale:","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--fast"},Object(n.__)("90-100 (fast)","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--average"},Object(n.__)("50-89 (average)","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--slow"},Object(n.__)("0-49 (slow)","google-site-kit")))}}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(3),_=a(10),f=a(37),k=a(2),y=a.n(k),v=a(67),S=a(1),O=a(0),E=function(t){function AnalyticsInactiveCTA(){return r()(this,AnalyticsInactiveCTA),g()(this,m()(AnalyticsInactiveCTA).apply(this,arguments))}return h()(AnalyticsInactiveCTA,t),c()(AnalyticsInactiveCTA,[{key:"render",value:function(){var t=this.props,a=t.title,i=void 0===a?Object(O.__)("Learn more about what visitors do on your site.","google-site-kit"):a,o=t.description,s=void 0===o?Object(O.__)("Connecting with Google Analytics to see unique vistors, goal completions, top pages and more.","google-site-kit"):o,r=t.ctaLabel,l=void 0===r?Object(O.__)("Set up Analytics","google-site-kit"):r;return e.googlesitekit.permissions.canManageOptions?n.createElement(f.a,{title:i,description:s,onClick:AnalyticsInactiveCTA.setupAnalyticsClick,ctaLabel:l}):null}}],[{key:"setupAnalyticsClick",value:function(){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(Object(b.a)(_.c,"analytics",!0));case 3:return t.next=5,o.a.awrap(Object(b.v)());case 5:e.location=Object(b.m)("analytics",!0),t.next=11;break;case 8:t.prev=8,t.t0=t.catch(0),Object(b.x)(v.a,{id:"analytics-setup-error",title:Object(O.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 11:case"end":return t.stop()}}),null,null,[[0,8]])}}]),AnalyticsInactiveCTA}(S.Component);E.propTypes={title:y.a.string,description:y.a.string,ctaLabel:y.a.string},E.defaultProps={},t.a=E}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,n){var i=a(31),o=a(0);t.a=function DashboardAuthAlert(){var t=e.googlesitekit.admin.connectURL;return n.createElement(i.a,{id:"authentication error",title:Object(o.__)("Issue accessing data","google-site-kit"),description:Object(o.__)("You need to reauthenticate your Google account.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0,ctaLink:t,ctaLabel:Object(o.__)("Click here","google-site-kit")})}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(22),i=a(1);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return e.createElement(i.Fragment,null,a&&o&&s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(n.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))))),a&&!o&&s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(n.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))))),a&&o&&!s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},t),a&&!o&&!s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},t),!a&&!o&&s&&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))),!a&&!o&&!s&&t)}}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(11),i=a.n(n),o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),g=a(8),u=a.n(g),m=a(9),p=a.n(m),h=a(10),b=a(31),_=a(2),f=a.n(_),k=a(0),y=a(1),v=function(t){function Alert(e){var t;return s()(this,Alert),(t=d()(this,u()(Alert).call(this,e))).state={isLoading:!0,alerts:[],error:!1,message:""},t}return p()(Alert,t),l()(Alert,[{key:"componentDidMount",value:function(){this.getAlert()}},{key:"getAlert",value:function(){var e,t;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,e=this.props.module,a.next=4,i.a.awrap(h.c.get(h.b,e,"notifications",{},!1));case 4:t=a.sent,this.setState({isLoading:!1,error:!1,alerts:t}),a.next=11;break;case 8:a.prev=8,a.t0=a.catch(0),this.setState({isLoading:!1,error:a.t0.code});case 11:case"end":return a.stop()}}),null,this,[[0,8]])}},{key:"render",value:function(){var t=this.state,a=t.alerts,n=t.error,i=t.isLoading;if(n||i||!a||!a.length)return null;var o=a.map((function(t){return e.createElement(b.a,{id:t.id,key:t.id,title:t.title,description:t.message||t.description,dismiss:Object(k.__)("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.Fragment,null,o)}}]),Alert}(y.Component);v.propTypes={module:f.a.string.isRequired},t.a=v}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(57),_=a(3),f=a(20),k=a(10),y=a(1),v=a(0),S=a(2),O=a.n(S),E=a(19),j=a(27),D=a(18);function C(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var w=function(t){function DashboardAcquisitionPieChart(){return r()(this,DashboardAcquisitionPieChart),g()(this,m()(DashboardAcquisitionPieChart).apply(this,arguments))}return h()(DashboardAcquisitionPieChart,t),c()(DashboardAcquisitionPieChart,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.source;if(!a||a.error||!a.length)return null;var i=Object(D.e)(a);return e.createElement("div",{className:"googlesitekit-chart googlesitekit-chart--pie"},e.createElement(b.a,{data:i,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}),n&&e.createElement("div",{className:"googlesitekit-chart__source"},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(E.a,{key:"link",href:Object(_.n)("googlesitekit-module-analytics"),inherit:!0},Object(v._x)("Analytics","Service name","google-site-kit"))]))}}]),DashboardAcquisitionPieChart}(y.Component);w.defaultProps={source:!1},w.propTypes={source:O.a.bool},t.a=Object(f.a)(w,[{type:k.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?C(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):C(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},D.k,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(_.p)("day"),context:["Dashboard","Single"]}],e.createElement(j.a,{width:"282px",height:"282px",shape:"circular"}),{},D.h,D.f)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){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,a(1))},,,,,,,,,,,,,function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return C})),a.d(t,"a",(function(){return A}));var i=a(73),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(11),_=a.n(b),f=a(1),k=a(0),y=a(32),v=a(2),S=a.n(v),O=a(74),E=a(3),j=a(10),D=a(19),C=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/],w=[function(){var t;return _.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(t=e.location.hostname,!["localhost","127.0.0.1"].includes(t)&&!t.match(/\.(example|invalid|localhost|test)$/)){a.next=3;break}throw"invalid_hostname";case 3:case"end":return a.stop()}}))},function(){var e,t,a;return _.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,_.a.awrap(j.c.set(j.a,"site","setup-tag"));case 2:return e=n.sent,t=e.token,n.next=6,_.a.awrap(Object(E.j)("setup").catch((function(){throw"tag_fetch_failed"})));case 6:if(a=n.sent,t===a){n.next=9;break}throw"setup_token_mismatch";case 9:case"end":return n.stop()}}))}],A=function(t){function CompatibilityChecks(t){var a;r()(this,CompatibilityChecks);var n=e.googlesitekit.setup.isSiteKitConnected;return(a=g()(this,m()(CompatibilityChecks).call(this,t))).state={complete:n,error:null,developerPlugin:{}},a}return h()(CompatibilityChecks,t),c()(CompatibilityChecks,[{key:"componentDidMount",value:function(){var e,t,a,n;return _.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(!this.state.complete){i.next=2;break}return i.abrupt("return");case 2:i.prev=2,e=0,t=w;case 4:if(!(e<t.length)){i.next=11;break}return a=t[e],i.next=8,_.a.awrap(a());case 8:e++,i.next=4;break;case 11:i.next=19;break;case 13:return i.prev=13,i.t0=i.catch(2),i.next=17,_.a.awrap(j.c.get(j.a,"site","developer-plugin"));case 17:n=i.sent,this.setState({error:i.t0,developerPlugin:n});case 19:this.setState({complete:!0});case 20:case"end":return i.stop()}}),null,this,[[2,13]])}},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,a=e.active,n=e.installURL,i=e.activateURL,o=e.configureURL;return!t&&n?{labelHTML:Object(k.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:n,external:!1}:t&&!a&&i?{labelHTML:Object(k.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:t&&a&&o?{labelHTML:Object(k.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:o,external:!1}:{labelHTML:Object(k.__)('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,a=this.helperCTA(),i=a.labelHTML,o=a.href,s=a.external;switch(e){case"invalid_hostname":case"tag_fetch_failed":return n.createElement(f.Fragment,null,!t&&Object(k.__)("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(k.__)("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")," ",n.createElement(D.a,{href:o,dangerouslySetInnerHTML:{__html:i},external:s,inherit:!0}));case"setup_token_mismatch":return Object(k.__)("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,a=this.state,i=a.complete,s=a.error,r=this.props,l=r.children,c=o()(r,["children"]);return s&&(e=n.createElement(f.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(O.a,null),n.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(k.__)("Your site may not be ready for Site Kit","google-site-kit"))),n.createElement("p",null,this.renderError(s))))),i||(t=n.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},n.createElement("small",null,Object(k.__)("Checking Compatibility...","google-site-kit")),n.createElement(y.a,{small:!0,compress:!0}))),l({restProps:c,complete:i,error:s,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(f.Component);A.propTypes={children:S.a.func.isRequired}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,n){var i=a(37),o=a(82),s=a(3),r=a(0);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],d=e.googlesitekit.modules[t].name,g=n.createElement(i.a
|
8 |
+
/* translators: %s: Module name */,{title:Object(r.sprintf)(Object(r.__)("%s activation","google-site-kit"),d)
|
9 |
+
/* translators: %s: Module name */,description:Object(r.sprintf)(Object(r.__)("%s module needs to be configured","google-site-kit"),d),ctaLabel:Object(r.__)("Complete activation","google-site-kit"),onClick:function(){e.location=Object(s.m)(t,!0)}});return Object(o.a)(g,a,l,c)}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(24),h=a(33),b=a(1),_=a(0),f=function(t){function AdSenseDashboardOutro(){return o()(this,AdSenseDashboardOutro),c()(this,g()(AdSenseDashboardOutro).apply(this,arguments))}return m()(AdSenseDashboardOutro,t),r()(AdSenseDashboardOutro,[{key:"render",value:function(){var t=e.googlesitekit.modules.adsense.accountURL;return n.createElement("section",{className:"googlesitekit-module-outro"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-module-outro__logo"},n.createElement(p.a,{id:"adsense",height:"36",width:"42"}),n.createElement(p.a,{id:"plus",height:"13",width:"13"}),n.createElement(p.a,{id:"analytics",height:"36",width:"34"})),n.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-module-outro__title "},Object(_.__)("Connect Analytics with AdSense to create a powerful team that shows robust metrics for your site.","google-site-kit")),n.createElement("div",{className:"googlesitekit-module-outro__button"},n.createElement(h.a,{href:t,target:"_blank"},Object(_.__)("Connect Accounts","google-site-kit")))))))}}]),AdSenseDashboardOutro}(b.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(19),h=a(85),b=a(32),_=a(1),f=a(0),k=function(t){function AdSenseInProcessStatus(){return o()(this,AdSenseInProcessStatus),c()(this,g()(AdSenseInProcessStatus).apply(this,arguments))}return m()(AdSenseInProcessStatus,t),r()(AdSenseInProcessStatus,[{key:"render",value:function(){var t=this.props,a=t.ctaLink,i=t.ctaLinkText,o=t.header,s=t.incomplete,r=t.loadingMessage,l=t.subHeader,c=t.required,d=new URL(e.googlesitekit.admin.siteURL),g="https://www.google.com/adsense/new/sites?url=".concat(d.hostname,"&source=site-kit"),u=[{id:1,
|
10 |
+
/* translators: %s: Site URL */
|
11 |
+
text:Object(f.sprintf)(Object(f.__)("Added your site %s in ","google-site-kit"),d.hostname),linkText:Object(f.__)("Sites","google-site-kit"),linkURL:g},{id:2,text:Object(f.__)("Enabled ads in","google-site-kit"),linkText:Object(f.__)("Ads","google-site-kit"),linkURL:"https://www.google.com/adsense/new/myads/auto-ads"}];return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},c&&n.createElement(h.a,null),r&&n.createElement(_.Fragment,null,r,n.createElement(b.a,null)),o&&n.createElement("h3",{className:" googlesitekit-heading-4 googlesitekit-setup-module__title "},o),l&&n.createElement("p",null,l),s&&n.createElement("div",{className:"googlesitekit-setup-module__list-wrapper"},n.createElement("ol",{className:"googlesitekit-setup-module__list"},u.map((function(e){return n.createElement("li",{className:"googlesitekit-setup-module__list-item",key:e.id},e.text," ",n.createElement(p.a,{href:e.linkURL,external:!0,inherit:!0},e.linkText))})))),a&&i&&n.createElement("div",{className:"googlesitekit-setup-module__cta"},n.createElement(p.a,{className:"googlesitekit-setup-module__cta-link",href:a,external:!0},i)))}}]),AdSenseInProcessStatus}(_.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(75),_=a(10),f=a(2),k=a.n(f),y=a(3),v=a(1),S=a(0),O=a(12),E=function(t){function AdSenseSettings(t){var a;o()(this,AdSenseSettings),a=c()(this,g()(AdSenseSettings).call(this,t));var n=e.googlesitekit.modules.adsense.settings.useSnippet,i=void 0===n||n;return a.state={useSnippet:!!i,disabled:!1},a.handleUseSnippetSwitch=a.handleUseSnippetSwitch.bind(m()(a)),a}return h()(AdSenseSettings,t),r()(AdSenseSettings,[{key:"componentDidMount",value:function(){var e=this;this._isMounted=!0,Object(O.b)("googlekit.SettingsConfirmed","googlekit.AdSenseSettingsConfirmed",(function(t,a){return"adsense"!==a.replace("-module","")?t:e.save()})),this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(O.f)("googlekit.SettingsConfirmed","googlekit.AdSenseSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"save",value:function(){var t=this.state.useSnippet;this._isMounted&&this.setState({useSnippet:t});var a={useSnippet:t||!1};return e.googlesitekit.modules.adsense.settings&&(e.googlesitekit.modules.adsense.settings.useSnippet=t),_.c.set(_.b,"adsense","use-snippet",a).then((function(e){return e})).catch((function(e){return e}))}},{key:"handleUseSnippetSwitch",value:function(){var e=this.props.saveOnChange,t=this.state.useSnippet;t=!t,this._isMounted&&this.setState({useSnippet:t}),Object(y.A)("adsense_setup",t?"adsense_tag_enabled":"adsense_tag_disabled"),e&&_.c.set(_.b,"adsense","use-snippet",{useSnippet:t}).then((function(e){return e})).catch((function(e){return e}))}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){Object(y.z)("adsense",{useSnippet:"useSnippet"},this.state)}}},{key:"render",value:function(){var e=this.state.useSnippet,t=this.props,a=t.isEditing,i=t.switchLabel,o=void 0===i?Object(S.__)("Let Site Kit place code on your site","google-site-kit"):i,s=t.switchOnMessage,r=t.switchOffMessage;return n.createElement(v.Fragment,null,a?n.createElement(v.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__switch"},n.createElement(b.a,{id:"enableAutoAds",label:o,onClick:this.handleUseSnippetSwitch,checked:e,hideLabel:!1})," ",n.createElement("span",{className:"googlesitekit-recommended"},Object(S.__)("RECOMMENDED","google-site-kit"))),e&&s&&n.createElement("div",{className:"googlesitekit-settings-notice googlesitekit-settings-notice--suggestion"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},s)),!e&&r&&n.createElement("div",{className:"googlesitekit-settings-notice"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},r))):n.createElement(v.Fragment,null,Object(S.__)("The AdSense code has","google-site-kit")," ",e?Object(S.__)("been placed on your site.","google-site-kit"):Object(S.__)("not been placed on your site.","google-site-kit")))}}]),AdSenseSettings}(v.Component);E.propTypes={isEditing:k.a.bool,accountTagMatch:k.a.bool,existingTag:k.a.oneOfType([k.a.bool,k.a.string]),switchLabel:k.a.string,switchOnMessage:k.a.string,switchOffMessage:k.a.string},E.defaultProps={isEditing:!1,accountTagMatch:!1,existingTag:!1,switchOnMessage:"",switchOffMessage:""},t.a=E}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(40),v=a(106),S=a(13),O=a(0),E=a(1),j=a(18);function D(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var C=function(t){function AnalyticsDashboardWidgetTopAcquisitionSources(){return r()(this,AnalyticsDashboardWidgetTopAcquisitionSources),g()(this,m()(AnalyticsDashboardWidgetTopAcquisitionSources).apply(this,arguments))}return h()(AnalyticsDashboardWidgetTopAcquisitionSources,t),c()(AnalyticsDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(f.g)(),n=[{title:Object(O.__)("Medium","google-site-kit"),tooltip:Object(O.__)("Medium refers to where your traffic originated from","google-site-kit")},{title:Object(O.__)("Users","google-site-kit"),tooltip:Object(O.__)("Number of users that originated from that traffic","google-site-kit")},{title:Object(O.__)("New Users","google-site-kit"),
|
12 |
+
/* translators: %s: date range */
|
13 |
+
tooltip:Object(O.sprintf)(Object(O.__)("Number of new users to visit your page over last %s","google-site-kit"),a)},{title:Object(O.__)("Sessions","google-site-kit"),
|
14 |
+
/* translators: %s: date range */
|
15 |
+
tooltip:Object(O.sprintf)(Object(O.__)("Number of sessions users had on your website over last %s","google-site-kit"),a)},{title:Object(O.__)("Percentage","google-site-kit"),tooltip:Object(O.__)("Percentage of sessions","google-site-kit")}],i=t[0].data.totals[0].values[0],o=Object(S.map)(t[0].data.rows,(function(t,a){var n=t.metrics[0].values[0]/i*100;return!(1>n)&&[t.dimensions[0],Object(f.s)(t.metrics[0].values[0]),Object(f.s)(t.metrics[0].values[1]),Object(f.s)(t.metrics[0].values[2]),e.createElement(E.Fragment,{key:"minichart-analytics-top-as-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(n.toFixed(2),"%")," ",e.createElement(v.a,{percent:n.toFixed(1),index:a})))]})),s=Object(k.b)(o,n,{hideHeader:!1,chartsEnabled:!1});return e.createElement("div",{className:"googlesitekit-details-widget"},e.createElement(k.a,null,s))}}]),AnalyticsDashboardWidgetTopAcquisitionSources}(E.Component);t.a=Object(b.a)(C,[{type:_.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?D(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):D(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},j.k,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(f.p)("day"),context:["Single","Dashboard"]}],e.createElement(y.a,{rows:4,rowHeight:50}),{},j.h)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(57),p=a(213),h=a(1),b=function(t){function MiniChart(){return i()(this,MiniChart),l()(this,d()(MiniChart).apply(this,arguments))}return u()(MiniChart,t),s()(MiniChart,[{key:"render",value:function(){var t=this.props,a=t.index,n=t.percent,i={backgroundColor:"transparent",chartArea:{width:"100%",height:"100%"},enableInteractivity:!1,height:28,legend:{position:"none"},slices:{0:{color:p.a[a]},1:{color:"#e6e6e6"}},title:null,tooltip:{trigger:"none"},width:28},o=[["source","percent"],["",+n],["",100-n]];return e.createElement("div",{className:"googlesitekit-mini-chart"},e.createElement(m.a,{data:o,options:i,chartType:"pie",loadSmall:!0,loadCompressed:!0,loadHeight:24,loadText:!1,id:"minichart"+a}))}}]),MiniChart}(h.Component);t.a=b}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(27),p=a(2),h=a.n(p),b=a(1),_=function(t){function PreviewBlocks(){return i()(this,PreviewBlocks),l()(this,d()(PreviewBlocks).apply(this,arguments))}return u()(PreviewBlocks,t),s()(PreviewBlocks,[{key:"render",value:function(){for(var t=this.props,a=t.width,n=t.height,i=t.shape,o=t.count,s=[],r=0;r++<o;)s.push(e.createElement(m.a,{width:a,height:n,shape:i,key:r}));return s}}]),PreviewBlocks}(b.Component);_.propTypes={width:h.a.string,height:h.a.string,shape:h.a.string,count:h.a.number},_.defaultProps={width:"100px",height:"100px",shape:"square",count:1},t.a=_}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(20),h=a(10),b=a(3),_=a(29),f=a(40),k=a(13),y=a(0),v=a(1),S=function(t){function SearchConsoleDashboardWidgetKeywordTable(){return o()(this,SearchConsoleDashboardWidgetKeywordTable),c()(this,g()(SearchConsoleDashboardWidgetKeywordTable).apply(this,arguments))}return m()(SearchConsoleDashboardWidgetKeywordTable,t),r()(SearchConsoleDashboardWidgetKeywordTable,[{key:"render",value:function(){var t=this.props.data,a=[{title:Object(y.__)("Keyword","google-site-kit"),tooltip:Object(y.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(y.__)("Clicks","google-site-kit"),tooltip:Object(y.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(y.__)("Impressions","google-site-kit"),tooltip:Object(y.__)("Counted each time your content appears in search results","google-site-kit")}],i=e.googlesitekit.admin.siteURL,o=[],s=Object(k.map)(t,(function(e,t){var a=e.keys[0];return o[t]=Object(y.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%s&query=!%s&num_of_days=28",i,a),[a,Object(b.s)(e.clicks),Object(b.s)(e.impressions)]})),r={hideHeader:!1,chartsEnabled:!1,links:o},l=Object(_.b)(s,a,r);return n.createElement(_.a,null,l)}}]),SearchConsoleDashboardWidgetKeywordTable}(v.Component);t.a=Object(p.a)(S,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:e.googlesitekit.permaLink,dimensions:"query",limit:10},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"]}],n.createElement(f.a,{padding:!0}),{createGrid:!0},(function(e){return!e.length}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function DashboardSearchFunnelInner(){return i()(this,DashboardSearchFunnelInner),l()(this,d()(DashboardSearchFunnelInner).apply(this,arguments))}return u()(DashboardSearchFunnelInner,e),s()(DashboardSearchFunnelInner,[{key:"render",value:function(){return null}}]),DashboardSearchFunnelInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardSearchFunnel")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(2),h=a.n(p),b=a(1),_=a(0),f=a(31),k=function(t){function ErrorHandler(e){var t;return o()(this,ErrorHandler),(t=c()(this,g()(ErrorHandler).call(this,e))).state={error:null,info:null},t}return m()(ErrorHandler,t),r()(ErrorHandler,[{key:"componentDidCatch",value:function(t,a){e.console.error("Caught an error:",t,a),this.setState({error:t,info:a})}},{key:"render",value:function(){var e=this.props.children,t=this.state,a=t.error,i=t.info;return a?n.createElement(f.a,{id:"googlesitekit-error",title:Object(_.__)("Site Kit encountered an error","google-site-kit"),description:n.createElement("code",null,a.message),isDismissable:!1,format:"small",type:"win-error"},n.createElement("pre",null,i.componentStack)):e}}]),ErrorHandler}(b.Component);k.defaultProps={},k.propTypes={children:h.a.node.isRequired},t.a=k}).call(this,a(15),a(1))},,,,,,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return d}));var n,i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=function(t){var a=e[t];if(!a)return!1;try{var n="__storage_test__";return a.setItem(n,n),a.removeItem(n),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==a.length}},c=function(){function NullStorage(){o()(this,NullStorage)}return r()(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}(),d=function(){return n||(n=l("sessionStorage")?e.sessionStorage:l("localStorage")?e.localStorage:new c),n}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return i}));var n=a(0);function i(){Object(n.setLocaleData)(e.googlesitekit.locale,"google-site-kit")}}).call(this,a(15))},,,,,,,function(e,t,a){"use strict";(function(e){var n=a(2),i=a.n(n),o=a(14),s=a.n(o);function ChangeArrow(t){var a=t.direction,n=t.invertColor;return e.createElement("svg",{className:s()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(a),{"googlesitekit-change-arrow--inverted-color":n}),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:i.a.string,invertColor:i.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return i}));var n=a(132),i=a.n(n)()(e)}).call(this,a(15))},,function(e,t,a){"use strict";(function(e){var n=a(31),i=a(0);t.a=function DashboardPermissionAlert(){return e.createElement(n.a,{id:"permission error",title:Object(i.__)("Permissions issue accessing data","google-site-kit"),description:Object(i.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,a(1))},function(e,t,a){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},function(e,t,a){"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-[^"]+)"/]},,function(e,t,a){"use strict";(function(e){var n=a(24),i=a(0);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(n.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(n.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(i.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,a(1))},,,,,,,function(e,t,a){"use strict";(function(e,n){var i=a(100),o=a.n(i),s=a(11),r=a.n(s),l=a(5),c=a.n(l),d=a(6),g=a.n(d),u=a(7),m=a.n(u),p=a(8),h=a.n(p),b=a(16),_=a.n(b),f=a(9),k=a.n(f),y=a(21),v=a.n(y),S=a(10),O=a(2),E=a.n(O),j=a(33),D=a(32),C=a(19),w=a(145),A=a(75),x=a(25),N=a(24),P=a(3),T=a(14),L=a.n(T),I=a(0),M=a(1),W=a(12);function R(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function U(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?R(a,!0).forEach((function(t){v()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):R(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var F=v()({},"loggedinUsers",Object(I.__)("Logged-in users","google-site-kit")),z=function(t){function AnalyticsSetup(t){var a;c()(this,AnalyticsSetup),a=m()(this,h()(AnalyticsSetup).call(this,t));var n=e.googlesitekit.modules.analytics.settings,i=n.accountID,o=n.anonymizeIP,s=n.internalWebPropertyID,r=n.profileID,l=n.propertyID,d=n.useSnippet,g=n.trackingDisabled;return a.state={anonymizeIP:o,isLoading:!0,isSaving:!1,propertiesLoading:!1,profilesLoading:!1,useSnippet:d||!1,errorCode:!1,errorMsg:"",errorReason:!1,accounts:[],properties:[],profiles:[],selectedAccount:i,selectedProperty:l,selectedProfile:r,selectedinternalWebProperty:s,existingTag:!1,trackingDisabled:g||[]},a.handleAccountChange=a.handleAccountChange.bind(_()(a)),a.handlePropertyChange=a.handlePropertyChange.bind(_()(a)),a.handleProfileChange=a.handleProfileChange.bind(_()(a)),a.processAccountChange=a.processAccountChange.bind(_()(a)),a.processPropertyChange=a.processPropertyChange.bind(_()(a)),a.handleSubmit=a.handleSubmit.bind(_()(a)),a.handleRadioClick=a.handleRadioClick.bind(_()(a)),a.handleRefetchAccount=a.handleRefetchAccount.bind(_()(a)),a.handleExclusionsChange=a.handleExclusionsChange.bind(_()(a)),a.switchStatus=a.switchStatus.bind(_()(a)),a}return k()(AnalyticsSetup,t),g()(AnalyticsSetup,[{key:"componentDidMount",value:function(){var e,t,a,n,i,o=this;return r.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:if(e=this.props,t=e.isOpen,a=e.onSettingsPage,this._isMounted=!0,!a||t){s.next=4;break}return s.abrupt("return");case 4:return s.next=6,r.a.awrap(Object(P.j)("analytics"));case 6:if(!(n=s.sent)||!n.length){s.next=21;break}return s.prev=8,s.next=11,r.a.awrap(S.c.get(S.b,"analytics","tag-permission",{tag:n}));case 11:return i=s.sent,s.next=14,r.a.awrap(this.getAccounts(i));case 14:s.next=19;break;case 16:s.prev=16,s.t0=s.catch(8),this.setState({isLoading:!1,errorCode:s.t0.code,errorMsg:s.t0.message,errorReason:!(!s.t0.data||!s.t0.data.reason)&&s.t0.data.reason});case 19:s.next=23;break;case 21:return s.next=23,r.a.awrap(this.getAccounts());case 23:Object(W.b)("googlekit.SettingsConfirmed","googlekit.AnalyticsSettingsConfirmed",(function(e,t){return"analytics"!==t.replace("-module","")?e:o.props.isEditing?o.handleSubmit():void 0}));case 24:case"end":return s.stop()}}),null,this,[[8,16]])}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(W.f)("googlekit.SettingsConfirmed","googlekit.AnalyticsSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){var e={anonymizeIP:"anonymizeIP",selectedAccount:"accountID",selectedProperty:"propertyID",selectedProfile:"profileID",selectedinternalWebProperty:"internalWebPropertyID",useSnippet:"useSnippet",trackingDisabled:"trackingDisabled"};"-1"===this.state.selectedAccount&&(e={}),Object(P.z)("analytics",e,this.state)}}},{key:"handleAccountChange",value:function(e,t){var a=this.state.selectedAccount,n=t.dataset.value;n!==a&&("0"!==n?(this.setState({propertiesLoading:!0,profilesLoading:!0,selectedAccount:n}),Object(P.A)("analytics_setup","account_change",n),"-1"!==n&&this.processAccountChange(n)):this.setState({selectedAccount:n,selectedProperty:"-1",selectedProfile:"-1",properties:[{id:"-1",name:Object(I.__)("Select an account","google-site-kit")}],profiles:[{id:"-1",name:Object(I.__)("Select an account","google-site-kit")}]}))}},{key:"handlePropertyChange",value:function(e,t){var a=this.state.selectedProperty,n=t.dataset.value;n!==a&&("0"!==n?(this.setState({profilesLoading:!0,selectedProperty:n}),Object(P.A)("analytics_setup","property_change",n),this.processPropertyChange(n)):this.setState({selectedProperty:n,selectedProfile:n,profiles:[{id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")}]}))}},{key:"handleProfileChange",value:function(e,t){var a=t.dataset.value;this.setState({selectedProfile:a}),Object(P.A)("analytics_setup","profile_change",a)}},{key:"getAccounts",value:function(){var e,t,a,n,i,o,s,l,c,d,g,u,m,p,h,b,_=this,f=arguments;return r.a.async((function(k){for(;;)switch(k.prev=k.next){case 0:return e=f.length>0&&void 0!==f[0]&&f[0],t=this.state,a=t.selectedAccount,n=t.selectedProperty,i=t.selectedProfile,o=t.useSnippet,s=this.props,l=s.isEditing,c=s.onSettingsPage,d=this.state.errorCode,g={},k.prev=5,u=e?{existingAccountID:e.accountID,existingPropertyID:e.propertyID}:{},k.next=9,r.a.awrap(S.c.get(S.b,"analytics","accounts-properties-profiles",u));case 9:0===(m=k.sent).accounts.length?(g=U({},g,{errorCode:"no_account",errorReason:"noAccount"}),S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles")):a?"0"===a?m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")}):a&&!m.accounts.find((function(e){return e.id===a}))&&(S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles"),m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")}),l&&(a="0",n="-1",i="-1"),g=U({},g,{errorCode:"insufficient_permissions",errorReason:"insufficientPermissions"})):(p=null,m.matchedProperty&&(p=m.matchedProperty),p?(a=p.accountId,n=p.id,(h=m.profiles.find((function(e){return e.accountId===a})))&&(i=h.id)):m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")})),b={id:"-1",name:Object(I.__)("Select an account","google-site-kit")},this.state.existingTag||m.properties.push({id:0,name:Object(I.__)("Setup a New Property","google-site-kit")}),m.profiles.push({id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")}),c||(o=!e),g=U({},g,{isLoading:!1,accounts:m.accounts,errorCode:d||g.errorCode,selectedAccount:a,selectedProperty:n,selectedProfile:i,properties:[b],profiles:[b],existingTag:!!e&&e.propertyID,useSnippet:o}),a&&"0"!==a&&(g=Object.assign(g,{properties:m.properties,profiles:m.profiles,selectedinternalWebProperty:m.properties[0]?m.properties[0].internalWebPropertyID:0})),k.next=22;break;case 19:k.prev=19,k.t0=k.catch(5),g={isLoading:!1,errorCode:k.t0.code,errorMsg:k.t0.message,errorReason:!(!k.t0.data||!k.t0.data.reason)&&k.t0.data.reason};case 22:return k.abrupt("return",new Promise((function(e){_._isMounted?_.setState(g,e):e()})));case 23:case"end":return k.stop()}}),null,this,[[5,19]])}},{key:"processAccountChange",value:function(e){var t,a,n,i;return r.a.async((function(o){for(;;)switch(o.prev=o.next){case 0:return o.prev=0,t={accountID:e},o.next=4,r.a.awrap(S.c.get(S.b,"analytics","properties-profiles",t));case 4:a=o.sent,n={id:0,name:Object(I.__)("Setup a New Property","google-site-kit")},a.properties.push(n),i={id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")},a.profiles.push(i),this.setState({propertiesLoading:!1,profilesLoading:!1,properties:a.properties,profiles:a.profiles,selectedAccount:e,selectedProperty:a.properties[0].id,selectedinternalWebProperty:a.properties[0].internalWebPropertyID,selectedProfile:a.profiles[0].id,errorCode:!1}),o.next=15;break;case 12:o.prev=12,o.t0=o.catch(0),this.setState({errorCode:o.t0.code,errorMsg:o.t0.message});case 15:case"end":return o.stop()}}),null,this,[[0,12]])}},{key:"processPropertyChange",value:function(e){var t,a,n;return r.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return t=this.state.selectedAccount,i.prev=1,a={accountID:t,propertyID:e},i.next=5,r.a.awrap(S.c.get(S.b,"analytics","profiles",a));case 5:n=i.sent,this.setState({profilesLoading:!1,profiles:n,selectedProperty:e,selectedinternalWebProperty:n[0].internalWebPropertyID,selectedProfile:n[0].id,errorCode:!1}),i.next=12;break;case 9:i.prev=9,i.t0=i.catch(1),this.setState({errorCode:i.t0.code,errorMsg:i.t0.message});case 12:case"end":return i.stop()}}),null,this,[[1,9]])}},{key:"handleSubmit",value:function(t){var a,n,i,o,s,l,c,d,g,u,m,p,h,b,_,f,k;return r.a.async((function(y){for(;;)switch(y.prev=y.next){case 0:if(t&&t.preventDefault(),this.state.selectedAccount&&"-1"!==this.state.selectedAccount){y.next=3;break}return y.abrupt("return");case 3:return a=this.state,n=a.anonymizeIP,i=a.selectedAccount,o=a.selectedProperty,s=a.selectedProfile,l=a.useSnippet,c=a.selectedinternalWebProperty,d=a.accounts,g=a.properties,u=a.profiles,m=a.trackingDisabled,this.setState({isSaving:!0}),p=this.props.finishSetup,h=s||(u[0].id||0===u[0].id?u[0].id.toString():null),b=o||(g[0].id||0===g[0].id?g[0].id.toString():null),_="0"===b?"0":c||(g[0].internalWebPropertyId||0===g[0].internalWebPropertyId?g[0].internalWebPropertyId.toString():null),f={anonymizeIP:n,accountID:i||d[0].id||null,profileID:h,propertyID:b,internalWebPropertyID:_,useSnippet:l||!1,trackingDisabled:m},y.prev=10,y.next=13,r.a.awrap(S.c.set(S.b,"analytics","settings",f));case 13:return k=y.sent,S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles"),y.next=17,r.a.awrap(this.getAccounts());case 17:e.googlesitekit.modules.analytics.settings=k,Object(P.A)("analytics_setup","analytics_configured"),p&&p(),this._isMounted&&this.setState({isSaving:!1,selectedAccount:k.accountID,selectedProfile:k.profileID,selectedProperty:k.propertyID,selectedinternalWebProperty:k.internalWebPropertyID}),y.next=26;break;case 23:y.prev=23,y.t0=y.catch(10),this.setState({isSaving:!1,errorCode:y.t0.code,errorMsg:y.t0.message});case 26:case"end":return y.stop()}}),null,this,[[10,23]])}},{key:"handleRadioClick",value:function(e){var t="1"===e.target.value;this.setState({useSnippet:t}),Object(P.A)("analytics_setup",t?"analytics_tag_enabled":"analytics_tag_disabled")}},{key:"switchStatus",value:function(e){var t=this;return function(){t.setState(v()({},e,!t.state[e]))}}},{key:"handleRefetchAccount",value:function(){this.setState({isLoading:!0,errorCode:!1,errorMsg:"",selectedAccount:"0",selectedProperty:"-1",selectedProfile:"-1",propertiesLoading:!1,profilesLoading:!1},this.getAccounts)}},{key:"handleExclusionsChange",value:function(e){var t=this.state.trackingDisabled,a=e.target,n=a.id,i=a.checked,s=Object.assign.apply(Object,[{}].concat(o()(t.map((function(e){return v()({},e,!0)}))),[v()({},n,i)]));this.setState({trackingDisabled:Object.keys(s).filter((function(e){return s[e]}))})}},{key:"renderAutoInsertSnippetForm",value:function(){var t=this.state,a=t.anonymizeIP,i=t.useSnippet,o=t.isSaving,s=t.existingTag,r=this.props,l=r.isEditing,c=r.onSettingsPage,d=!l,g=e.googlesitekit.admin.ampMode,u=e.googlesitekit.modules.analytics.settings.useSnippet;return n.createElement("div",{className:"googlesitekit-setup-module__inputs googlesitekit-setup-module__inputs--multiline"},(l||o)&&n.createElement(M.Fragment,null,c&&n.createElement(M.Fragment,null,!u&&!s&&n.createElement(M.Fragment,null,n.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(I.__)("Currently there is no Analytics snippet placed on your site, so no stats are being gathered. Would you like Site Kit to insert the Analytics snippet? You can change this setting later.","google-site-kit"))),u&&n.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(I.__)("Do you want to remove the Analytics snippet inserted by Site Kit?","google-site-kit"))),c&&!s&&!i&&u&&n.createElement("p",null,Object(I.__)("If the code snippet is removed, you will no longer be able to gather Analytics insights about your site.","google-site-kit"))),c&&n.createElement(M.Fragment,null,s&&n.createElement("p",null,Object(I.__)("Placing two tags at the same time is not recommended.","google-site-kit")),n.createElement(w.a,{onClick:this.handleRadioClick,id:"useSnippetTrue",name:"useSnippet",value:"1",checked:i,disabled:d},u?Object(I.__)("Not at this time","google-site-kit"):Object(I.__)("Insert snippet","google-site-kit")),n.createElement(w.a,{onClick:this.handleRadioClick,id:"useSnippetFalse",name:"useSnippet",value:"0",checked:!i,disabled:d},u?Object(I.__)("Remove snippet","google-site-kit"):Object(I.__)("Not at this time","google-site-kit"))),c&&i&&"primary"!==g&&n.createElement("div",{className:"googlesitekit-setup-module__input"},n.createElement(A.a,{id:"anonymizeIP",label:Object(I.__)("Anonymize IP addresses","google-site-kit"),onClick:this.switchStatus("anonymizeIP"),checked:a,hideLabel:!1}),n.createElement("p",null,a?Object(I.__)("IP addresses will be anonymized.","google-site-kit"):Object(I.__)("IP addresses will not be anonymized.","google-site-kit")," ",n.createElement(C.a,{href:"https://support.google.com/analytics/answer/2763052",external:!0,inherit:!0,dangerouslySetInnerHTML:{__html:Object(I.__)('Learn more<span class="screen-reader-text"> about IP anonymization.</span>',"google-site-kit")}}))))}},{key:"accountsDropdown",value:function(){var e=this.state,t=e.accounts,a=e.selectedAccount,i=e.existingTag,o=!this.props.isEditing;return i&&a&&(o=!0),n.createElement(x.k,{className:"googlesitekit-analytics__select-account",enhanced:!0,name:"accounts",value:a||"0",onEnhancedChange:this.handleAccountChange,label:Object(I.__)("Account","google-site-kit"),disabled:o,outlined:!0},t.concat(i?[]:[{id:"-1",name:Object(I.__)("Set up a new account","google-site-kit")}]).map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)})))}},{key:"renderForm",value:function(){var t=this.state,a=t.anonymizeIP,i=t.isLoading,o=t.propertiesLoading,s=t.profilesLoading,r=t.accounts,l=t.properties,c=t.profiles,d=t.selectedAccount,g=t.selectedProperty,u=t.selectedProfile,m=t.useSnippet,p=t.existingTag,h=t.errorCode,b=t.trackingDisabled,_=this.props,f=_.onSettingsPage,k=_.isEditing,y=parseInt(d)||0,v=!p&&y>0,S=!!/^UA-/.test(g.toString()),O=e.googlesitekit.admin.ampMode,E=e.googlesitekit.modules.analytics.setupComplete;if(i)return n.createElement(D.a,null);if("google_analytics_existing_tag_permission"===h)return null;if(!r.length||"-1"===d){if(!k)return Object(I.__)("No account found.","google-site-kit");if(!E||k)return n.createElement(M.Fragment,null,"-1"===d&&n.createElement(M.Fragment,null,n.createElement("p",null,Object(I.__)("To create a new account, click the button below which will open the Google Analytics account creation screen in a new window.","google-site-kit")),n.createElement("p",null,Object(I.__)("Once completed, click the link below to re-fetch your accounts to continue.","google-site-kit"))),n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(j.a,{onClick:AnalyticsSetup.createNewAccount},Object(I.__)("Create an account","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(C.a,{onClick:this.handleRefetchAccount},Object(I.__)("Re-fetch My Account","google-site-kit")))))}if(!k){var w=m?Object(I.__)("Snippet is inserted","google-site-kit"):Object(I.__)("Snippet is not inserted","google-site-kit");return p&&(w=Object(I.__)("Inserted by another plugin or theme","google-site-kit")),n.createElement(M.Fragment,null,n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Account","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},d||r[0].name||!1)),n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Property","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},g||l[0].name||!1)),n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("View","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},u||c[0].name||!1))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Analytics Code Snippet","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},w))),f&&m&&"primary"!==O&&n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("IP Address Anonymization","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},a&&Object(I.__)("IP addresses are being anonymized.","google-site-kit"),!a&&Object(I.__)("IP addresses are not being anonymized.","google-site-kit")))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Excluded from Analytics","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},!!b.length&&b.map((function(e){return F[e]})).join(Object(I._x)(", ","list separator","google-site-kit")),!b.length&&Object(I.__)("Analytics is currently enabled for all visitors.","google-site-kit")))))}return n.createElement(M.Fragment,null,!f&&0<r.length&&!p&&n.createElement("p",null,Object(I.__)("Please select the account information below. You can change this view later in your settings.","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},this.accountsDropdown(),o?n.createElement(D.a,{small:!0}):n.createElement(x.k,{className:"googlesitekit-analytics__select-property",enhanced:!0,name:"properties",value:g||0===g?g.toString():"-1",onEnhancedChange:this.handlePropertyChange,label:Object(I.__)("Property","google-site-kit"),disabled:!v,outlined:!0},l.map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)}))),s?n.createElement(D.a,{small:!0}):n.createElement(x.k,{className:"googlesitekit-analytics__select-profile",enhanced:!0,name:"profiles",value:u||0===u?u.toString():"-1",onEnhancedChange:this.handleProfileChange,label:Object(I.__)("View","google-site-kit"),disabled:!S,outlined:!0},c.map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)})))),this.renderAutoInsertSnippetForm(),f&&this.renderExclusionsForm(),!f&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(j.a,{disabled:!this.state.selectedAccount,onClick:this.handleSubmit},Object(I.__)("Configure Analytics","google-site-kit"))))}},{key:"renderExclusionsForm",value:function(){var e=this.state.trackingDisabled;return n.createElement("div",null,n.createElement("p",{className:"googlesitekit-setup-module__text"},Object(I.__)("Exclude from Analytics","google-site-kit")),n.createElement("div",{className:"mdc-form-field"},n.createElement(A.a,{id:"loggedinUsers",label:F.loggedinUsers,onClick:this.handleExclusionsChange,checked:e.includes("loggedinUsers"),hideLabel:!1})),n.createElement("p",null,e.includes("loggedinUsers")?Object(I.__)("Logged-in users will be excluded from Analytics tracking.","google-site-kit"):Object(I.__)("Logged-in users will be included in Analytics tracking.","google-site-kit")))}},{key:"renderErrorOrNotice",value:function(){var e=this.state,t=e.errorCode,a=e.errorMsg,i=e.errorReason,o=e.accounts,s=this.props.onSettingsPage;if(!t)return null;var r=!0,l=a;switch(!0){case"google_analytics_existing_tag_permission"===t:r=!0;break;case s&&t&&"insufficientPermissions"===i:r=!1,l=Object(I.__)("You currently don't have access to this Google Analytics account. You can either request access from your team, or remove this Google Analytics snippet and connect to a different account.","google-site-kit");break;case!s&&0===o.length:r=!1,l=Object(I.__)('Looks like you don\'t have an Analytics account yet. Once you create it, click on "Re-fetch my account" and Site Kit will locate it.',"google-site-kit")}return l&&0!==l.length?n.createElement("div",{className:L()({"googlesitekit-error-text":r})},n.createElement("p",null,r
|
16 |
+
/* translators: %s: Error message */?Object(I.sprintf)(Object(I.__)("Error: %s","google-site-kit"),l):l)):null}},{key:"render",value:function(){var e=this.props.onSettingsPage,t=this.state.existingTag;return e||Object(P.A)("analytics_setup","configure_analytics_screen"),n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--analytics"},!e&&n.createElement(M.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(N.a,{id:"analytics",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(I._x)("Analytics","Service name","google-site-kit"))),!!t&&
|
17 |
+
/* translators: %s: Analytics tag ID */
|
18 |
+
n.createElement("p",null,Object(I.sprintf)(Object(I.__)("An existing analytics tag was found on your site with the ID %s. If later on you decide to replace this tag, Site Kit can place the new tag for you. Make sure you remove the old tag first.","google-site-kit"),t)),this.renderErrorOrNotice(),this.renderForm())}}],[{key:"createNewAccount",value:function(t){t.preventDefault(),Object(P.A)("analytics_setup","new_analytics_account"),e.open("https://analytics.google.com/analytics/web/?#/provision/SignUp","_blank")}}]),AnalyticsSetup}(M.Component);z.propTypes={onSettingsPage:E.a.bool,finishSetup:E.a.func,isEditing:E.a.bool},z.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=z}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Radio(e){var t;return i()(this,Radio),(t=l()(this,d()(Radio).call(this,e))).formFieldRef=Object(f.createRef)(),t.radioRef=Object(f.createRef)(),t}return u()(Radio,t),s()(Radio,[{key:"componentDidMount",value:function(){new m.e(this.formFieldRef.current).input=new m.g(this.radioRef.current)}},{key:"render",value:function(){var t=this.props,a=t.onClick,n=t.id,i=t.name,o=t.value,s=t.checked,r=t.disabled,l=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:_()("mdc-radio",{"mdc-radio--disabled":r}),ref:this.radioRef},e.createElement("input",{className:"mdc-radio__native-control",onClick:a,type:"radio",id:n,name:i,value:o,checked:s,disabled:r,onChange:function(){}}),e.createElement("div",{className:"mdc-radio__background"},e.createElement("div",{className:"mdc-radio__outer-circle"}),e.createElement("div",{className:"mdc-radio__inner-circle"}))),e.createElement("label",{htmlFor:n},l))}}]),Radio}(f.Component);k.propTypes={onClick:h.a.func,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.string.isRequired},k.defaultProps={onClick:null,checked:!1,disabled:!1},t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(33),k=a(19),y=a(10),v=a(25),S=a(24),O=a(2),E=a.n(O),j=a(3),D=a(14),C=a.n(D),w=a(0),A=a(1),x=a(12),N=function(t){function OptimizeSetup(t){var a;r()(this,OptimizeSetup),a=g()(this,m()(OptimizeSetup).call(this,t));var n=e.googlesitekit.modules.optimize.settings,i=n.optimizeID,o=n.ampExperimentJSON,s=(e.googlesitekit.modules.analytics||{}).settings,l=e.googlesitekit.modules.tagmanager||{},c=l.active,d=l.settings,u=!!s&&s.useSnippet,p=!(!c||!d)&&d.useSnippet;return a.state={optimizeID:i||"",analyticsUseSnippet:u,gtmUseSnippet:p,errorCode:!1,errorMsg:"",ampExperimentJSON:o||"",ampExperimentJSONValidated:!0,OptimizeIDValidated:!0},a.handleOptimizeIDEntry=a.handleOptimizeIDEntry.bind(h()(a)),a.handleSubmit=a.handleSubmit.bind(h()(a)),a.renderInstructionInfo=a.renderInstructionInfo.bind(h()(a)),a.handleAMPOptimizeEntry=a.handleAMPOptimizeEntry.bind(h()(a)),a}return _()(OptimizeSetup,t),c()(OptimizeSetup,[{key:"componentDidMount",value:function(){var e=this;this._isMounted=!0,Object(x.b)("googlekit.SettingsConfirmed","googlekit.OptimizeSettingsConfirmed",(function(t,a){return"optimize"!==a.replace("-module","")?t:e.props.isEditing?e.handleSubmit():void 0})),this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(x.f)("googlekit.SettingsConfirmed","googlekit.OptimizeSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){Object(j.z)("optimize",{optimizeID:"optimizeID",ampExperimentJSON:"ampExperimentJSON"},this.state)}}},{key:"handleSubmit",value:function(){var t,a,n,i,s,r,l=this;return o.a.async((function(c){for(;;)switch(c.prev=c.next){case 0:if(t=this.state,a=t.optimizeID,n=t.ampExperimentJSON,i=t.OptimizeIDValidated,s=this.props.finishSetup,i&&0!==a.length){c.next=4;break}return c.abrupt("return",!1);case 4:return r={optimizeID:a,ampExperimentJSON:n},c.next=7,o.a.awrap(y.c.set(y.b,"optimize","settings",r).then((function(){s&&s(),e.googlesitekit.modules.optimize.settings.optimizeID=a,l._isMounted&&l.setState({isSaving:!1})})).catch((function(e){l._isMounted&&l.setState({errorCode:!0,errorMsg:e.errorMsg})})));case 7:return c.abrupt("return",c.sent);case 8:case"end":return c.stop()}}),null,this)}},{key:"handleOptimizeIDEntry",value:function(e){var t=Object(j.C)(e.target.value);this._isMounted&&this.setState({optimizeID:e.target.value,OptimizeIDValidated:t})}},{key:"handleAMPOptimizeEntry",value:function(e){var t=Object(j.B)(e.target.value);this._isMounted&&this.setState({ampExperimentJSON:e.target.value,ampExperimentJSONValidated:t})}},{key:"renderInfo",value:function(){var e=this.state.optimizeID;return n.createElement(A.Fragment,null,e?n.createElement("div",null,Object(w.__)("Your Optimize Container ID","google-site-kit"),": ",n.createElement("strong",null,e)):n.createElement("div",null,Object(w.__)('Optimize Container ID missing, press "edit" to add',"google-site-kit"),"."))}},{key:"renderInstructionInfo",value:function(){var e=this.state,t=e.analyticsUseSnippet,a=e.gtmUseSnippet,i=e.optimizeID;return!t&&a?n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("You are using auto insert snippet with Tag Manager","google-site-kit")),n.createElement("p",null,n.createElement("a",{href:"https://support.google.com/optimize/answer/6314801"},Object(w.__)("Click here","google-site-kit"))," ",Object(w.__)("for how to implement Optimize tag through your Tag Manager","google-site-kit"))):t?null:n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("You disabled analytics auto insert snippet. If You are using Google Analytics code snippet, add the code below:","google-site-kit")),n.createElement("pre",null,'ga("require", "',i||"GTM-XXXXXXX",'");'),n.createElement("p",null,n.createElement("a",{href:"https://support.google.com/optimize/answer/6262084"},Object(w.__)("Click here","google-site-kit"))," ",Object(w.__)("for how to implement Optimize tag in Google Analytics Code Snippet","google-site-kit")))}},{key:"renderAMPSnippet",value:function(){var t=this.state,a=t.analyticsUseSnippet,i=t.ampExperimentJSON,o=t.ampExperimentJSONValidated,s=e.googlesitekit.admin.ampEnabled;return a&&s?n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("Please input your AMP experiment settings in JSON format below.","google-site-kit")," ",n.createElement(k.a,{href:"https://developers.google.com/optimize/devguides/amp-experiments",external:!0,inherit:!0},Object(w.__)("Learn More.","google-site-kit"))),n.createElement(v.l,{className:C()("mdc-text-field",{"mdc-text-field--error":!o}),name:"amp-experiment",onChange:this.handleAMPOptimizeEntry,textarea:!0},n.createElement(v.b,{inputType:"textarea",value:null===i?"":i})),!o&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error: AMP experiment settings are not in a valid JSON format.","google-site-kit"))):null}},{key:"renderForm",value:function(){var e=this.state,t=e.optimizeID,a=e.errorCode,i=e.errorMsg,o=e.OptimizeIDValidated;return n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("Please copy and paste your Optimize ID to complete your setup.","google-site-kit")," ",n.createElement(k.a,{href:"https://support.google.com/optimize/answer/6211921",external:!0,inherit:!0},Object(w.__)("You can locate this here.","google-site-kit"))),a&&0<i.length&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error:","google-site-kit")," ",i),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},n.createElement(v.l,{className:C()("mdc-text-field",{"mdc-text-field--error":a||!o}),label:Object(w.__)("Optimize Container ID","google-site-kit"),name:"optimizeID",onChange:this.handleOptimizeIDEntry,helperText:n.createElement(v.a,null,Object(w.__)("Format: GTM-XXXXXXX.","google-site-kit")),outlined:!0,required:!0},n.createElement(v.b,{value:t}))),!o&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error: Not a valid Optimize ID.","google-site-kit")),this.renderAMPSnippet(),this.renderInstructionInfo())}},{key:"render",value:function(){var e=this.props,t=e.onSettingsPage,a=e.isEditing;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--optimize"},!t&&n.createElement(A.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(S.a,{id:"optimize",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(w._x)("Optimize","Service name","google-site-kit"))),a&&this.renderForm(),!a&&this.renderInfo(),!t&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(f.a,{onClick:this.handleSubmit},Object(w.__)("Configure Optimize","google-site-kit"))))}}]),OptimizeSetup}(A.Component);N.propTypes={onSettingsPage:E.a.bool,finishSetup:E.a.func,isEditing:E.a.bool},N.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=N}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return E})),a.d(t,"a",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(20),h=a(47),b=a(10),_=a(3),f=a(29),k=a(13),y=a(1),v=a(0),S=a(77),O=function(t){function PageSpeedInsightsDashboardWidgetHomepageSpeedColumn(){return o()(this,PageSpeedInsightsDashboardWidgetHomepageSpeedColumn),c()(this,g()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn).apply(this,arguments))}return m()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn,t),r()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn,[{key:"componentDidMount",value:function(){var e=this.props,t=e.data,a=e.handleDataLoaded;t&&a&&a()}},{key:"render",value:function(){var t=this.props,a=t.data,n=t.title;if(!a||a.error)return null;if(!function(e){return!!Object(k.get)(e,"categories.performance.score")}(a))return Object(h.a)(Object(v._x)("PageSpeed Insights","Service name","google-site-kit"),Object(v.__)("An unknown error occurred while trying to fetch PageSpeed Insights data. Please try again later.","google-site-kit"),!0);var i=a.categories.performance.score,o=Object(S.d)(i),s=a.audits.interactive.displayValue,r=Object(f.b)([[Object(v.__)("Real user speed data","google-site-kit"),e.createElement(S.b,{key:"0",score:i},o)],[Object(v.__)("Time to become fully interactive","google-site-kit"),e.createElement(S.b,{key:"0",score:i},s)]],[],{hideHeader:!0,disableListMode:!0,chartsEnabled:!1,links:[]});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("div",{className:"googlesitekit-pagespeed-report__heading-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 "},n),e.createElement(S.c,{score:i})),e.createElement(f.a,null,r))}}]),PageSpeedInsightsDashboardWidgetHomepageSpeedColumn}(y.Component),E=Object(p.a)(O,[{type:b.b,identifier:"pagespeed-insights",datapoint:"pagespeed",data:{url:n.googlesitekit.permaLink,strategy:"mobile",dateRange:null},priority:10,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],null,{inGrid:!0}),j=Object(p.a)(O,[{type:b.b,identifier:"pagespeed-insights",datapoint:"pagespeed",data:{url:n.googlesitekit.permaLink,strategy:"desktop",dateRange:null},priority:10,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],null,{inGrid:!0})}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(11),r=a.n(s),l=a(5),c=a.n(l),d=a(6),g=a.n(d),u=a(7),m=a.n(u),p=a(8),h=a.n(p),b=a(16),_=a.n(b),f=a(9),k=a.n(f),y=a(33),v=a(19),S=a(75),O=a(10),E=a(32),j=a(25),D=a(24),C=a(2),w=a.n(C),A=a(3),x=a(13),N=a(14),P=a.n(N),T=a(0),L=a(1),I=a(12),M=a(39),W="web",R="amp",U=function(t){function TagmanagerSetup(t){var a;c()(this,TagmanagerSetup),a=m()(this,h()(TagmanagerSetup).call(this,t));var n=e.googlesitekit.admin,i=n.ampEnabled,o=n.ampMode,s=e.googlesitekit.modules.tagmanager.settings,r="primary"===o?R:[W,R];return a.state={ampEnabled:i,isLoading:!0,isSecondaryAMP:"secondary"===o,accounts:[],containers:[],containersAMP:[],errorCode:!1,errorMsg:"",existingContainer:"",selectedAccount:s.accountID,selectedContainer:s.containerID,selectedContainerAMP:s.ampContainerID,containersLoading:!1,usageContext:i?r:W,hasExistingTag:!1,useSnippet:s.useSnippet},a.handleSubmit=a.handleSubmit.bind(_()(a)),a.renderAccountDropdownForm=a.renderAccountDropdownForm.bind(_()(a)),a.handleAccountChange=a.handleAccountChange.bind(_()(a)),a.refetchAccount=a.refetchAccount.bind(_()(a)),a}return k()(TagmanagerSetup,t),g()(TagmanagerSetup,[{key:"setState",value:function(){this._isMounted&&L.Component.prototype.setState.apply(this,arguments)}},{key:"componentDidMount",value:function(){var e,t,a,n=this;return r.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e=this.props,t=e.isOpen,a=e.onSettingsPage,this._isMounted=!0,!a||t){i.next=4;break}return i.abrupt("return");case 4:return i.next=6,r.a.awrap(this.loadAccountsContainers());case 6:Object(I.b)("googlekit.SettingsConfirmed","googlekit.TagmanagerSettingsConfirmed",(function(e,t){return"tagmanager"!==t.replace("-module","")?e:n.props.isEditing?n.handleSubmit():void 0})),this.toggleConfirmChangesButton();case 8:case"end":return i.stop()}}),null,this)}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(I.f)("googlekit.SettingsConfirmed","googlekit.TagmanagerSettingsConfirmed")}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){var e={selectedContainer:"containerID",selectedContainerAMP:"ampContainerID",selectedAccount:"accountID",useSnippet:"useSnippet"};this.canSaveSettings()||(e={}),Object(A.z)("tagmanager",e,this.state)}}},{key:"loadAccountsContainers",value:function(){var e,t,a,n,i,o;return r.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,r.a.awrap(Object(A.j)("tagmanager"));case 2:if(!(e=s.sent)){s.next=20;break}return s.prev=4,s.next=7,r.a.awrap(O.c.get(O.b,"tagmanager","tag-permission",{tag:e}));case 7:t=s.sent,a=t.account,n=t.container,i=Object(M.a)([n]).byContext(W),o=Object(M.a)([n]).byContext(R),this.setState({isLoading:!1,existingContainer:e,selectedAccount:a.accountId,selectedContainer:Object(x.get)(i,[0,"publicId"]),selectedContainerAMP:Object(x.get)(o,[0,"publicId"]),accounts:[a],hasExistingTag:!0}),s.next=18;break;case 15:s.prev=15,s.t0=s.catch(4),this.setState({isLoading:!1,errorCode:s.t0.code,errorMsg:s.t0.message,errorReason:!(!s.t0.data||!s.t0.data.reason)&&s.t0.data.reason,existingContainer:e,hasExistingTag:!!e});case 18:s.next=22;break;case 20:return s.next=22,r.a.awrap(this.requestTagManagerAccountsContainers());case 22:case"end":return s.stop()}}),null,this,[[4,15]])}},{key:"requestTagManagerAccounts",value:function(){var e,t;return r.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,e=this.state.selectedAccount,a.next=4,r.a.awrap(O.c.get(O.b,"tagmanager","accounts"));case 4:t=a.sent,this.validateAccounts(t,e),this.setState({isLoading:!1,accounts:t}),a.next=12;break;case 9:a.prev=9,a.t0=a.catch(0),this.setState({isLoading:!1,errorCode:a.t0.code,errorMsg:a.t0.message});case 12:case"end":return a.stop()}}),null,this,[[0,9]])}},{key:"requestTagManagerAccountsContainers",value:function(){var e,t,a,n,i,o,s,l,c,d,g,u,m;return r.a.async((function(p){for(;;)switch(p.prev=p.next){case 0:return p.prev=0,e=this.state,t=e.selectedAccount,a=e.usageContext,n=this.state,i=n.selectedContainer,o=n.selectedContainerAMP,s={accountID:t,usageContext:a},p.next=6,r.a.awrap(O.c.get(O.b,"tagmanager","accounts-containers",s));case 6:l=p.sent,c=l.accounts,d=l.containers,this.validateAccounts(c,t),g=d.map((function(e){return e.publicId})),Object(M.c)(i)&&!g.includes(i)&&(i=""),Object(M.c)(o)&&!g.includes(o)&&(o=""),u=Object(M.a)(d).byContext(W),m=Object(M.a)(d).byContext(R),this.setState({isLoading:!1,accounts:c,containers:u,containersAMP:m,selectedAccount:t||Object(x.get)(d,[0,"accountId"]),selectedContainer:i||Object(x.get)(u,[0,"publicId"]),selectedContainerAMP:o||Object(x.get)(m,[0,"publicId"]),errorCode:!1,errorMsg:""}),p.next=21;break;case 18:p.prev=18,p.t0=p.catch(0),this.setState({isLoading:!1,errorCode:p.t0.code,errorMsg:p.t0.message});case 21:case"end":return p.stop()}}),null,this,[[0,18]])}},{key:"validateAccounts",value:function(e,t){if(!t&&0===e.length)throw{code:"accountEmpty",message:Object(T.__)("We didn’t find an associated Google Tag Manager account, would you like to set it up now? If you’ve just set up an account please re-fetch your account to sync it with Site Kit.","google-site-kit")};if(Object(M.b)(t)&&!e.find((function(e){return e.accountId===t})))throw{code:"insufficientPermissions",message:Object(T.__)("You currently don’t have access to this Google Tag Manager account. You can either request access from your team, or remove this Google Tag Manager snippet and connect to a different account.","google-site-kit")}}},{key:"requestTagManagerContainers",value:function(e){var t,a;return r.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return this.setState({containersLoading:!0}),n.prev=1,t={accountID:e,usageContext:this.state.usageContext},n.next=5,r.a.awrap(O.c.get(O.b,"tagmanager","containers",t));case 5:a=n.sent,this.setState({containersLoading:!1,containers:Object(M.a)(a).byContext(W),containersAMP:Object(M.a)(a).byContext(R),errorCode:!1}),n.next=12;break;case 9:n.prev=9,n.t0=n.catch(1),this.setState({containersLoading:!1,errorCode:n.t0.code,errorMsg:n.t0.message});case 12:case"end":return n.stop()}}),null,this,[[1,9]])}},{key:"handleSubmit",value:function(){var t,a,n,i,o,s,l,c,d,g;return r.a.async((function(u){for(;;)switch(u.prev=u.next){case 0:return t=this.state,a=t.hasExistingTag,n=t.selectedAccount,i=t.selectedContainer,o=t.selectedContainerAMP,s=t.usageContext,l=t.useSnippet,c=this.props.finishSetup,u.prev=2,d={accountID:n,containerID:i,ampContainerID:o,usageContext:s,useSnippet:!a&&l},u.next=6,r.a.awrap(O.c.set(O.b,"tagmanager","settings",d));case 6:g=u.sent,c&&c(),e.googlesitekit.modules.tagmanager.settings=g,this.setState({isSaving:!1}),u.next=16;break;case 12:throw u.prev=12,u.t0=u.catch(2),this.setState({isLoading:!1,isSaving:!1,errorCode:u.t0.code,errorMsg:u.t0.message}),u.t0;case 16:case"end":return u.stop()}}),null,this,[[2,12]])}},{key:"handleAccountChange",value:function(e,t){var a=this.state.selectedAccount,n=t.dataset.value;n!==a&&(this.setState({selectedAccount:n,selectedContainer:"",selectedContainerAMP:""}),Object(M.b)(n)&&this.requestTagManagerContainers(n))}},{key:"refetchAccount",value:function(e){e.preventDefault(),this.setState({isLoading:!0,errorCode:!1,errorMsg:"",selectedAccount:"",selectedContainer:"",selectedContainerAMP:""},this.requestTagManagerAccounts)}},{key:"renderSettingsInfo",value:function(){var t=e.googlesitekit.modules.tagmanager.settings,a=this.state,i=a.ampEnabled,o=a.isSecondaryAMP,s=a.hasExistingTag,r=a.isLoading,l=t.accountID,c=t.useSnippet;return r?n.createElement(E.a,null):n.createElement(L.Fragment,null,n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(T.__)("Account","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},l||!1)),(!i||o)&&n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},o&&Object(T.__)("Web Container ID","google-site-kit"),!i&&Object(T.__)("Container ID","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},t.containerID||!1)),i&&n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},o&&Object(T.__)("AMP Container ID","google-site-kit"),!o&&Object(T.__)("Container ID","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},t.ampContainerID||!1))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(T.__)("Tag Manager Code Snippet","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},c&&Object(T.__)("Snippet is inserted","google-site-kit"),!c&&Object(T.__)("Snippet is not inserted","google-site-kit")),s&&n.createElement("p",null,Object(T.__)("Placing two tags at the same time is not recommended.","google-site-kit")))))}},{key:"renderAccountDropdownForm",value:function(){var e=this,t=this.state,a=t.ampEnabled,i=t.accounts,o=t.selectedAccount,s=t.containers,r=t.containersAMP,l=t.existingContainer,c=t.hasExistingTag,d=t.isLoading,g=t.isSecondaryAMP,u=t.errorCode,m=t.useSnippet,p=this.props.onSettingsPage;if(d)return n.createElement(E.a,null);if("tag_manager_existing_tag_permission"===u)return null;if("accountEmpty"===u)return this.renderCreateAccount();if("account_create"===o)return n.createElement(L.Fragment,null,n.createElement("p",null,Object(T.__)("To create a new account, click the button below which will open the Google Tag Manager account creation screen in a new window.","google-site-kit")),n.createElement("p",null,Object(T.__)("Once completed, click the link below to re-fetch your accounts to continue.","google-site-kit")),this.renderCreateAccount());var h=!a||g,b=a;return n.createElement(L.Fragment,null,c&&n.createElement("p",null,Object(T.sprintf)(// translators: %s: the existing container ID.
|
19 |
+
Object(T.__)("An existing tag was found on your site (%s). If you later decide to replace this tag, Site Kit can place the new tag for you. Make sure you remove the old tag first.","google-site-kit"),l)),!c&&!g&&n.createElement("p",null,Object(T.__)("Please select your Tag Manager account and container below, the snippet will be inserted automatically on your site.","google-site-kit")),!c&&g&&n.createElement("p",null,Object(T.__)("Looks like your site is using paired AMP. Please select your Tag Manager account and relevant containers below, the snippets will be inserted automatically on your site.","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},n.createElement(j.k,{className:"googlesitekit-tagmanager__select-account",enhanced:!0,name:"accounts",label:Object(T.__)("Account","google-site-kit"),value:o,disabled:c,onEnhancedChange:this.handleAccountChange,outlined:!0},[].concat(i).concat(c?[]:{name:Object(T.__)("Set up a new account","google-site-kit"),accountId:"account_create"}).map((function(e){return n.createElement(j.j,{key:e.accountId,value:e.accountId},e.name)}))),h&&this.renderContainerSelect({selectedStateKey:"selectedContainer",containers:s,label:b?Object(T.__)("Web Container","google-site-kit"):null,type:W}),b&&this.renderContainerSelect({selectedStateKey:"selectedContainerAMP",containers:r,label:h?Object(T.__)("AMP Container","google-site-kit"):null,type:R})),p&&n.createElement(L.Fragment,null,c&&n.createElement("p",null,Object(T.__)("Placing two tags at the same time is not recommended.","google-site-kit")),n.createElement(S.a,{id:"tagmanagerUseSnippet",onClick:function(){return e.setState({useSnippet:!m})},name:"useSnippet",checked:m,label:Object(T.__)("Let Site Kit place code on your site","google-site-kit"),hideLabel:!1}),n.createElement("p",null,m?Object(T.__)("Site Kit will add the code automatically","google-site-kit"):Object(T.__)("Site Kit will not add the code to your site","google-site-kit"))),!p&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(y.a,{onClick:this.handleSubmit,disabled:!this.canSaveSettings()},Object(T.__)("Confirm & Continue","google-site-kit"))))}},{key:"renderContainerSelect",value:function(e){var t=this,a=e.label,i=e.selectedStateKey,s=e.containers,r=e.type,l=this.state,c=l.containersLoading,d=l.selectedAccount,g=l.hasExistingTag,u=!!s.length;return c?n.createElement(E.a,{small:!0}):n.createElement(j.k,{className:"\n\t\t\t\t\tgooglesitekit-tagmanager__select-container\n\t\t\t\t\tgooglesitekit-tagmanager__select-container--".concat(r,"\n\t\t\t\t"),label:a||Object(T.__)("Container","google-site-kit"),value:u?this.state[i]:"container_create",onEnhancedChange:function(e,a){return t.setState(o()({},i,a.dataset.value))},disabled:g||!Object(M.b)(d),enhanced:!0,outlined:!0},[].concat(s).concat(g?[]:{name:Object(T.__)("Set up a new container","google-site-kit"),publicId:"container_create"}).map((function(e,t){var a=e.name,i=e.publicId;return n.createElement(j.j,{key:t,value:i},a)})))}},{key:"canSaveSettings",value:function(){var e=this.state,t=e.ampEnabled,a=e.isSecondaryAMP,n=e.errorCode,i=e.isLoading,o=e.selectedAccount,s=e.selectedContainer,r=e.selectedContainerAMP;return!(i||"tag_manager_existing_tag_permission"===n||!Object(M.b)(o))&&(!!(t&&!a||Object(M.c)(s)||"container_create"===s)&&!(t&&!Object(M.c)(r)&&"container_create"!==r))}},{key:"renderCreateAccount",value:function(){return n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(y.a,{onClick:TagmanagerSetup.createNewAccount},Object(T.__)("Create an account","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(v.a,{onClick:this.refetchAccount},Object(T.__)("Re-fetch My Account","google-site-kit"))))}},{key:"renderErrorOrNotice",value:function(){var e=this.state,t=e.errorCode,a=e.errorMsg,i=this.props.onSettingsPage;if(0===a.length)return null;var o=!i||"insufficientPermissions"!==t;return n.createElement("div",{className:P()({"googlesitekit-error-text":o})},n.createElement("p",null,o
|
20 |
+
/* translators: %s: Error message */?Object(T.sprintf)(Object(T.__)("Error: %s","google-site-kit"),a):a))}},{key:"render",value:function(){var e=this.props,t=e.onSettingsPage,a=e.isEditing;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--tag-manager"},!t&&n.createElement(L.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(D.a,{id:"tagmanager",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(T._x)("Tag Manager","Service name","google-site-kit"))),this.renderErrorOrNotice(),a&&this.renderAccountDropdownForm(),!a&&this.renderSettingsInfo())}}],[{key:"createNewAccount",value:function(t){t.preventDefault(),e.open("https://tagmanager.google.com/#/admin/accounts/create","_blank")}}]),TagmanagerSetup}(L.Component);U.propTypes={onSettingsPage:w.a.bool,finishSetup:w.a.func,isEditing:w.a.bool},U.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=U}).call(this,a(15),a(1))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(16),u=a.n(g),m=a(9),p=a.n(m),h=a(25),b=a(0),_=a(1),f=a(12),k=function(t){function DateRangeSelector(e){var t;return i()(this,DateRangeSelector),(t=l()(this,d()(DateRangeSelector).call(this,e))).dateRangeHook="googlesitekit.dateRange",t.dateRangeHandlerHook="googlesitekit.dateRageHandler",t.dateRangeHookAddedHook="googlesitekit.dateRageHookAddedHandler",t.state={context:"Dashboard",dateValue:Object(f.c)(t.dateRangeHook,"last-28-days")},Object(f.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingDataForDateRangeSelector",(function(e){t.setState({context:e}),Object(f.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingDataForDateRangeSelector")})),t.handleSelection=t.handleSelection.bind(u()(t)),t}return p()(DateRangeSelector,t),s()(DateRangeSelector,[{key:"componentDidMount",value:function(){var e=this;Object(f.a)("hookAdded",this.dateRangeHookAddedHook,(function(t){e.dateRangeHook===t&&e.forceUpdate()}))}},{key:"componentWillUnmount",value:function(){Object(f.e)("hookAdded",this.dateRangeHookAddedHook)}},{key:"handleSelection",value:function(e,t){var a=this.state.context,n=t.getAttribute("data-value");return Object(f.f)(this.dateRangeHook,this.dateRangeHandlerHook),Object(f.b)(this.dateRangeHook,this.dateRangeHandlerHook,(function(){return n})),Object(f.d)("googlesitekit.moduleDataReset"),Object(f.d)("googlesitekit.moduleLoaded",a),this.setState({dateValue:Object(f.c)(this.dateRangeHook,"last-28-days")}),!1}},{key:"render",value:function(){var t=this.state.dateValue,a={"last-7-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",7,"google-site-kit"),7),"last-14-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",14,"google-site-kit"),14),"last-28-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",28,"google-site-kit"),28),"last-90-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",90,"google-site-kit"),90)};return e.createElement(h.k,{enhanced:!0,className:"mdc-select--minimal",name:"time_period",label:"",onEnhancedChange:this.handleSelection,value:t},Object.keys(a).map((function(t){return e.createElement(h.j,{key:t,value:t},a[t])})))}}]),DateRangeSelector}(_.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(1),p=function(t){function Spinner(){return i()(this,Spinner),l()(this,d()(Spinner).apply(this,arguments))}return u()(Spinner,t),s()(Spinner,[{key:"render",value:function(){var t=this.props.isSaving;return e.createElement("span",{className:"spinner",style:{display:t?"inline-block":"none",float:"none",marginTop:"0",visibility:"visible"}})}}]),Spinner}(m.Component);t.a=p}).call(this,a(1))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(66),k=a(62),y=a(22),v=a(14),S=a.n(v),O=a(1),E=a(0),j=a(197),D=a(200),C=a(83),w=a(201),A=a(56),x=a(47),N=a(32),P=a(102),T=a(46),L=a(68),I=a(103),M=a(65),W=function(t){function AdSenseDashboardWidget(e){var t;return r()(this,AdSenseDashboardWidget),(t=g()(this,m()(AdSenseDashboardWidget).call(this,e))).state={receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0,zeroData:!1,instructionProps:{}},t.handleDataError=t.handleDataError.bind(h()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(h()(t)),t.handleZeroData=t.handleZeroData.bind(h()(t)),t}return _()(AdSenseDashboardWidget,t),c()(AdSenseDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.a.awrap(Object(T.b)());case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),null,this)}},{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleZeroData",value:function(){var e=Object(T.d)("account-connected-no-data");this.setState({zeroData:!0,loading:!1,instructionProps:e})}},{key:"render",value:function(){var t=this,a=this.state,i=a.receivingData,o=a.error,s=a.loading,r=a.isAdSenseConnected,l=a.zeroData,c=a.instructionProps,d=e.googlesitekit.modules.adsense.homepage,g=s||!i||l?"googlesitekit-nodata":"";return n.createElement(O.Fragment,null,n.createElement(f.a,null),n.createElement("div",{className:g},n.createElement(C.a,{module:"adsense"})),n.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--adsense"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},!o&&e.googlesitekit.modules.adsense.setupComplete?n.createElement(k.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")}):n.createElement(k.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")}),s&&n.createElement(N.a,null)),l&&n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(y.a,{fill:!0},n.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(I.a,{ctaLink:c.ctaLink,ctaLinkText:c.ctaLinkText,header:c.statusHeadline,subHeader:c.statusMessage,incomplete:c.incomplete,required:c.required})))))),!i&&(o?Object(x.a)(Object(E._x)("AdSense","Service name","google-site-kit"),o,!0,!0,!0):Object(A.a)(Object(E._x)("AdSense","Service name","google-site-kit"),!0,!0,!0)),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",g)},n.createElement(L.a,{slug:"adsense",context:"module-dashboard"}),n.createElement(y.a,{header:!0,title:Object(E.__)("Estimated earnings","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:d},n.createElement(j.a,{handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}))),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",g)},n.createElement(y.a,{header:!0,title:Object(E.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:d},n.createElement(D.a,{handleDataError:function(e){e||t.handleZeroData()}}))),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",g)},n.createElement(w.a,null)),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},n.createElement(M.a,null))))),!r&&n.createElement(P.a,null))}}]),AdSenseDashboardWidget}(O.Component);t.a=W}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(26),p=a(27),h=a(3),b=a(20),_=a(10),f=a(46),k=a(0),y=a(1),v=function(t){function AdSenseEstimateEarningsWidget(e){var t;return i()(this,AdSenseEstimateEarningsWidget),(t=l()(this,d()(AdSenseEstimateEarningsWidget).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 u()(AdSenseEstimateEarningsWidget,t),s()(AdSenseEstimateEarningsWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var e=this.state,t=e.today,a=e.yesterday,n=e.sevenDays,i=e.month,o=e.twentyEightDays,s=e.sameDayLastWeek,r=e.prev7Days,l=e.monthLastYear,c=e.prev28Days;if(!(t&&a&&n&&i&&o&&s&&r&&l&&c))return null;var d=t.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),g=!!d&&d.currency,u=t.totals?[{className:"googlesitekit-data-block--today",title:Object(k.__)("Today so far","google-site-kit"),datapoint:Object(h.u)(t.totals[0],g)},{className:"googlesitekit-data-block--yesterday",title:Object(k.__)("Yesterday","google-site-kit"),datapoint:Object(h.u)(a.totals[0],g),change:s.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--7days",title:Object(k.__)("Last 7 days","google-site-kit"),datapoint:Object(h.u)(n.totals[0],g),change:r.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--month",title:Object(k.__)("This month","google-site-kit"),datapoint:Object(h.u)(i.totals[0],g),change:l.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--28days",title:Object(k.__)("Last 28 days","google-site-kit"),datapoint:Object(h.u)(o.totals[0],g),change:c.totals[0],changeDataUnit:"%"}]:[];return AdSenseEstimateEarningsWidget.renderLayout(u)}}],[{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,a){return e.createElement("div",{key:a,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:a,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=[],a=0;5>a;a++)t.push(e.createElement("div",{key:a,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(p.a,{width:"100%",height:"104px"})));return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t))}}]),AdSenseEstimateEarningsWidget}(y.Component);t.a=Object(b.a)(v,[{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.today)return{today:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"yesterday"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.yesterday)return{yesterday:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"same-day-last-week"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.sameDayLastWeek)return{sameDayLastWeek:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-7-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.sevenDays)return{sevenDays:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-7-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev7Days)return{prev7Days:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.month)return{month:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month-last-year"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.monthLastYear)return{monthLastYear:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.twentyEightDays)return{twentyEightDays:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev28Days)return{prev28Days:a}}}],v.renderPreviews(),{createGrid:!0},f.c)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(31),h=a(1),b=a(0),_=function(t){function InvalidCredentialsWarning(){return o()(this,InvalidCredentialsWarning),c()(this,g()(InvalidCredentialsWarning).apply(this,arguments))}return m()(InvalidCredentialsWarning,t),r()(InvalidCredentialsWarning,[{key:"render",value:function(){return e.createElement(p.a,{id:"notification-id",title:Object(b.__)("Security Token Error","google-site-kit"),description:Object(b.__)("We’re unable to retrieve your data because your security token is expired or revoked. Please ","google-site-kit"),learnMoreURL:n.googlesitekit.admin.connectURL,learnMoreLabel:Object(b.__)("reauthenticate your account","google-site-kit"),format:"small",type:"win-error"})}}]),InvalidCredentialsWarning}(h.Component);t.a=_}).call(this,a(1),a(15))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(10),p=a(26),h=a(27),b=a(3),_=a(46),f=a(20),k=a(0),y=a(1),v=a(13),S=function(t){function AdSensePerformanceWidget(e){var t;return i()(this,AdSensePerformanceWidget),(t=l()(this,d()(AdSensePerformanceWidget).call(this,e))).state={twentyEightDays:!1,prev28Days:!1},t}return u()(AdSensePerformanceWidget,t),s()(AdSensePerformanceWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.twentyEightDays,n=t.prev28Days,i=a.totals?[{className:"googlesitekit-data-block--page-rpm",title:Object(k.__)("Page RPM","google-site-kit"),datapoint:Object(b.u)(a.totals[1]),change:Object(v.isUndefined)(n.totals)?0:n.totals[1],changeDataUnit:"%"},{className:"googlesitekit-data-block--impression",title:Object(k.__)("Impressions","google-site-kit"),datapoint:Object(b.u)(a.totals[2]),change:Object(v.isUndefined)(n.totals)?0:n.totals[2],changeDataUnit:"%"}]:[];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},i.map((function(t,a){return e.createElement("div",{key:a,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(p.a,{stat:a,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}(y.Component);t.a=Object(f.a)(S,[{type:m.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.twentyEightDays)return{twentyEightDays:a}}},{type:m.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev28Days)return{prev28Days:a}}}],e.createElement(h.a,{width:"100%",height:"250px"}),{},_.c)}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function DashboardAdSenseTopPages(){return i()(this,DashboardAdSenseTopPages),l()(this,d()(DashboardAdSenseTopPages).apply(this,arguments))}return u()(DashboardAdSenseTopPages,e),s()(DashboardAdSenseTopPages,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopPages}(p.Component);t.a=Object(m.a)("googlesitekit.AnalyticsAdSenseTopPagesTable")(h)},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(44),p=a(203),h=a(204),b=a(68),_=a(1),f=a(0),k=function(t){function DashboardEarnings(){return i()(this,DashboardEarnings),l()(this,d()(DashboardEarnings).apply(this,arguments))}return u()(DashboardEarnings,t),s()(DashboardEarnings,[{key:"render",value:function(){return e.createElement(_.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(f.__)("Earnings","google-site-kit"),description:Object(f.__)("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(h.a,null),e.createElement(p.a,null))}}]),DashboardEarnings}(_.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function DashboardAdSenseTopEarningPagesSmall(){return i()(this,DashboardAdSenseTopEarningPagesSmall),l()(this,d()(DashboardAdSenseTopEarningPagesSmall).apply(this,arguments))}return u()(DashboardAdSenseTopEarningPagesSmall,e),s()(DashboardAdSenseTopEarningPagesSmall,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopEarningPagesSmall}(p.Component);t.a=Object(m.a)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall")(h)},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(20),p=a(10),h=a(27),b=a(3),_=a(26),f=a(54),k=a(0),y=a(1),v=a(46),S=a(22),O=function(t){function AdSenseDashboardMainSummary(e){var t;return i()(this,AdSenseDashboardMainSummary),(t=l()(this,d()(AdSenseDashboardMainSummary).call(this,e))).state={today:!1,period:!1,daily:!1},t}return u()(AdSenseDashboardMainSummary,t),s()(AdSenseDashboardMainSummary,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.today,n=t.period,i=t.daily;if(!(a&&n&&i&&n.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(S.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(h.a,{width:"100%",height:"276px",padding:!0})));var o=Object(v.e)(i.rows),s=Object(b.n)("googlesitekit-module-adsense",{}),r=n.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),l=!!r&&r.currency;return e.createElement(y.Fragment,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(S.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(_.a,{className:"overview-adsense-rpm",title:Object(k.__)("RPM","google-site-kit"),datapoint:Object(b.u)(n.totals[1],l),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,2),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{className:"overview-adsense-earnings",title:Object(k.__)("Total Earnings","google-site-kit"),datapoint:Object(b.u)(n.totals[0],l),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},change:a.totals[0],changeDataUnit:"$",sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,1),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{className:"overview-adsense-impressions",title:Object(k.__)("Ad Impressions","google-site-kit"),datapoint:Object(b.u)(n.totals[2]),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,3),change:1,loadSmall:!1}),context:"compact"})))))))}}]),AdSenseDashboardMainSummary}(y.Component);t.a=Object(m.a)(O,[{type:p.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.today)return{today:a}}},{type:p.b,identifier:"adsense",datapoint:"earnings",data:{},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.period)return{period:a}}},{type:p.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month",dimensions:["DATE"]},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.daily)return{daily:a}}}],e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(S.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(h.a,{width:"100%",height:"276px",padding:!0}))),{inGrid:!0,createGrid:!0},v.c)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(64),o=a.n(i),s=a(21),r=a.n(s),l=a(11),c=a.n(l),d=a(5),g=a.n(d),u=a(6),m=a.n(u),p=a(7),h=a.n(p),b=a(8),_=a.n(b),f=a(9),k=a.n(f),y=a(2),v=a.n(y),S=a(24),O=a(1),E=a(0),j=a(206),D=a(103),C=a(3),w=a(46);function A(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function x(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?A(a,!0).forEach((function(t){r()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):A(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var N=function(t){function AdSenseModuleStatus(e){var t;return g()(this,AdSenseModuleStatus),(t=h()(this,_()(AdSenseModuleStatus).call(this,e))).state={accountStatus:void 0,loadingMessage:Object(E.__)("Loading…","google-site-kit"),instructionProps:{}},t}return k()(AdSenseModuleStatus,t),m()(AdSenseModuleStatus,[{key:"componentDidMount",value:function(){return c.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,c.a.awrap(this.updateAccountStatus());case 2:case"end":return e.stop()}}),null,this)}},{key:"componentDidUpdate",value:function(e,t){var a=this.state.accountStatus;if(t.accountStatus!==a){var n=Object(w.d)(a);this.setState({instructionProps:n})}}},{key:"continueSetup",value:function(e){var t=this.state.instructionProps;e.existingState=x({},t),this.setState({instructionProps:e})}},{key:"goBack",value:function(){var e=x({},this.state.instructionProps).existingState;e&&(e.existingState=!1,this.setState({instructionProps:e}))}},{key:"updateAccountStatus",value:function(){var e,t,a,n,i,o=this;return c.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,c.a.awrap(Object(C.j)("adsense"));case 2:return e=s.sent,t=function(e){o.setState({loadingMessage:e})},s.next=6,c.a.awrap(Object(w.a)(e,t));case 6:a=s.sent,n=a.accountStatus,i=a.clientID,this.setState({accountStatus:n,clientID:i});case 10:case"end":return s.stop()}}),null,this)}},{key:"render",value:function(){var t=this.state,a=t.accountStatus,i=t.clientID,s=t.loadingMessage,r=t.instructionProps,l=!a||!e.googlesitekit.modules.adsense.setupComplete||["ads-display-pending","account-pending-review","account-required-action"].includes(a);return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},n.createElement("div",{className:"googlesitekit-setup-module__step"},n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(S.a,{id:"adsense",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("AdSense","Service name","google-site-kit"))),n.createElement("div",{className:"googlesitekit-setup-module__step"},!e.googlesitekit.canAdsRun&&!e.googlesitekit.modules.adsense.setupComplete&&n.createElement("div",{className:"googlesitekit-settings-module-warning"},n.createElement(S.a,{id:"error",height:"20",width:"23"}),Object(E.__)("Ad blocker detected, you need to disable it in order to setup AdSense.","google-site-kit")),l&&"account-connected"!==a&&n.createElement(D.a,{ctaLink:r.ctaLink,ctaLinkText:r.ctaLinkText,header:r.statusHeadline,subHeader:r.statusMessage,incomplete:r.incomplete,required:r.required,loadingMessage:!a&&s}),e.googlesitekit.canAdsRun&&a&&(e.googlesitekit.modules.adsense.setupComplete||"account-connected"===a)&&n.createElement(j.a,o()({},r,{accountStatus:a,clientID:i,continueSetup:this.continueSetup,goBack:this.goBack}))))}}]),AdSenseModuleStatus}(O.Component);N.propTypes={status:v.a.string,module:v.a.string},t.a=N}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(24),h=a(19),b=a(33),_=a(104),f=a(10),k=a(151),y=a(1),v=a(3),S=a(0),O=function(t){function AdSenseSetupInstructions(e){var t;return o()(this,AdSenseSetupInstructions),(t=c()(this,g()(AdSenseSetupInstructions).call(this,e))).state={isSaving:!1},t}return m()(AdSenseSetupInstructions,t),r()(AdSenseSetupInstructions,[{key:"render",value:function(){var t=this,a=this.props,i=a.error,o=a.message,s=a.issue,r=a.notice,l=a.statusHeadline,c=a.statusMessage,d=a.profile,g=a.ctaLinkText,u=a.ctaLink,m=a.footerText,O=a.footerAppendedText,E=a.footerCTA,j=a.footerCTALink,D=a.continueAction,C=a.continueSetup,w=a.accountStatus,A=a.accountTagMatch,x=a.clientID,N=a.existingTag,P=a.switchLabel,T=a.tracking,L=a.switchOffMessage,I=a.switchOnMessage,M=a.goBack,W=a.existingState,R=this.state.isSaving,U=e.googlesitekit.admin.userData,F=U.email,z=void 0===F?"":F,H=U.picture,G=void 0===H?"":H;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},n.createElement("div",{className:"googlesitekit-setup-module__step"},s&&n.createElement("p",{className:"googlesitekit-setup__notice"},n.createElement(p.a,{id:"error",height:"20",width:"23"}),n.createElement("span",{className:"googlesitekit-setup__notice-text"},s)),n.createElement("h2",{className:" googlesitekit-heading-4 googlesitekit-setup-module__title "},l),n.createElement("p",null,c),d&&n.createElement("p",{className:"googlesitekit-setup-module__user"},G&&n.createElement("img",{className:"googlesitekit-setup-module__user-image",src:G,alt:Object(S.__)("User Avatar","google-site-kit")}),n.createElement("span",{className:"googlesitekit-setup-module__user-email"},z)),"account-connected"===w&&n.createElement(_.a,{isEditing:!0,accountTagMatch:A,existingTag:N,saveOnChange:!0,switchLabel:P,switchOffMessage:L,switchOnMessage:I}),r&&n.createElement("div",{className:"googlesitekit-settings-notice"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},r)),i&&0<o.length&&n.createElement("div",{className:"googlesitekit-error-text"},n.createElement("p",null,Object(S.__)("Error:","google-site-kit")," ",o)),n.createElement("div",{className:"googlesitekit-setup-module__action"},"account-connected"===w&&n.createElement(y.Fragment,null,n.createElement(b.a,{disabled:R,onClick:function(){T&&Object(v.A)(T.eventCategory,T.eventName),t.setState({isSaving:!0});var e=document.getElementById("enableAutoAds"),a=e&&e.checked;f.c.set(f.b,"adsense","setup-complete",{clientID:x,useSnippet:a}).then((function(){document.location=u})).catch((function(){t.setState({isSaving:!1})}))}},g),n.createElement(k.a,{isSaving:R})),"account-connected"!==w&&n.createElement(h.a,{className:"googlesitekit-setup-module__cta-link",external:!0,inherit:!0,href:u},g),D&&n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(h.a,{inherit:!0,onClick:function(){C(D)}},D.continueText)),W&&n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(h.a,{inherit:!0,onClick:function(){M()}},Object(S.__)("Back","google-site-kit")))),m&&n.createElement("p",{className:"googlesitekit-setup-module__footer-text"},m," ",E&&n.createElement(h.a,{href:j,inherit:!0,external:!0},E)," ",O)))}}]),AdSenseSetupInstructions}(y.Component);t.a=O}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(3),h=a(19),b=a(1),_=a(0),f=function(t){function AdSenseSettingsStatus(){return o()(this,AdSenseSettingsStatus),c()(this,g()(AdSenseSettingsStatus).apply(this,arguments))}return m()(AdSenseSettingsStatus,t),r()(AdSenseSettingsStatus,[{key:"render",value:function(){var t=this.props,a=t.slug,i=t.screenID,o=t.OriginalComponent,s=e.googlesitekit.modules.adsense.settings.accountStatus;return s&&"adsense"===a&&("account-pending-review"===s||"ads-display-pending"===s)?n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},Object(_.__)("Site Kit has placed the code on your site, ","google-site-kit"),n.createElement(h.a,{className:"googlesitekit-settings-module__edit-button",onClick:function(){var t=i||"googlesitekit-dashboard";e.location=Object(p.n)(t,{reAuth:!0,slug:a})},inherit:!0},Object(_.__)("check module page","google-site-kit"))):n.createElement(o,this.props)}}]),AdSenseSettingsStatus}(b.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(14),h=a.n(p),b=a(24),_=a(1),f=a(0),k=function(t){function AdSenseSettingsWarning(){return o()(this,AdSenseSettingsWarning),c()(this,g()(AdSenseSettingsWarning).apply(this,arguments))}return m()(AdSenseSettingsWarning,t),r()(AdSenseSettingsWarning,[{key:"render",value:function(){var t=this.props,a=t.slug,i=t.context,o=t.OriginalComponent;if("adsense"!==a)return e.createElement(o,this.props);var s=n.googlesitekit.modules.adsense,r=s.active,l=s.setupComplete,c=Object(f.__)("Ad blocker detected, you need to disable it in order to setup AdSense.","google-site-kit");return r&&l&&(c=Object(f.__)("Ad blocker detected, You need to disable it to get the AdSense latest data.","google-site-kit")),n.googlesitekit.canAdsRun?e.createElement(o,this.props):e.createElement("div",{className:h()("googlesitekit-settings-module-warning","googlesitekit-settings-module-warning--".concat(i))},e.createElement(b.a,{id:"error",height:"20",width:"23"})," ",c)}}]),AdSenseSettingsWarning}(_.Component);t.a=k}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(11),i=a.n(n),o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),g=a(8),u=a.n(g),m=a(16),p=a.n(m),h=a(9),b=a.n(h),_=a(66),f=a(14),k=a.n(f),y=a(1),v=a(0),S=a(210),O=a(211),E=a(212),j=a(105),D=a(22),C=a(62),w=a(84),A=a(83),x=a(32),N=a(56),P=a(47),T=a(102),L=a(46),I=a(3),M=a(65),W=function(t){function AnalyticsDashboardWidget(e){var t;return s()(this,AnalyticsDashboardWidget),(t=d()(this,u()(AnalyticsDashboardWidget).call(this,e))).state={selectedStats:[0],receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0},t.handleStatSelection=t.handleStatSelection.bind(p()(t)),t.buildSeries=t.buildSeries.bind(p()(t)),t.handleDataError=t.handleDataError.bind(p()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(p()(t)),t}return b()(AnalyticsDashboardWidget,t),l()(AnalyticsDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:function(){return i.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,i.a.awrap(Object(L.b)());case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),null,this)}},{key:"handleStatSelection",value:function(e){this.setState({selectedStats:[e]})}},{key:"handleDataError",value:function(e){this.setState({receivingData:!1,loading:!1,error:e})}},{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,a=t.selectedStats,n=t.error,i=t.receivingData,o=t.loading,s=t.isAdSenseConnected,r=this.buildSeries(),l=!o&&i?"":"googlesitekit-nodata",c=Object(I.g)();return e.createElement(y.Fragment,null,e.createElement(_.a,null),e.createElement(A.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(C.a,{title:Object(v._x)("Analytics","Service name","google-site-kit"),icon:!0,iconWidth:"24",iconHeight:"26",iconID:"analytics",status:"connected",statusText:Object(v.__)("Analytics is connected","google-site-kit")}),o&&e.createElement(x.a,null)),!i&&(n?Object(P.a)(Object(v._x)("Analytics","Service name","google-site-kit"),n,!0,!0,!0):Object(N.a)(Object(v._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",l)},e.createElement(D.a,{header:!0
|
21 |
+
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Audience overview for the last %s","google-site-kit"),c),headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),headerCtaLink:"http://analytics.google.com"},e.createElement(E.a,{selectedStats:a,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),e.createElement(S.a,{selectedStats:a,series:r,vAxes:null,dateRangeSlug:Object(I.h)()}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",l)},e.createElement(D.a,{header:!0,footer:!0
|
22 |
+
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Top content over the last %s","google-site-kit"),c),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(v._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement(O.a,null))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",l)},e.createElement(D.a,{header:!0,footer:!0
|
23 |
+
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Top acquisition sources over the last %s","google-site-kit"),c),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(v._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(w.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(j.a,null)))))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(M.a,null))))),!o&&!s&&e.createElement(T.a,null))}}]),AnalyticsDashboardWidget}(y.Component);t.a=W}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(57),_=a(3),f=a(20),k=a(10),y=a(18),v=a(27),S=a(0),O=a(1),E=function(t){function AnalyticsDashboardWidgetSiteStats(e){var t;return o()(this,AnalyticsDashboardWidgetSiteStats),(t=c()(this,g()(AnalyticsDashboardWidgetSiteStats).call(this,e))).setOptions=t.setOptions.bind(m()(t)),t}return h()(AnalyticsDashboardWidgetSiteStats,t),r()(AnalyticsDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,a=t.series,n=t.vAxes,i={chart:{title:""===e.googlesitekit.pageTitle?"":Object(S.__)("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 i.series=a,i.vAxes=n,i}},{key:"render",value:function(){var e=this.props,t=e.data,a=e.selectedStats,i=e.dateRangeSlug;if(!t||!t.length)return null;var o=i?i.match(/\d+/).map(Number)[0]:28,s=Object(y.c)(t,a,o);if(!s)return null;var r=this.setOptions();return n.createElement("section",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(b.a,{selectedStats:a,data:s,options:r}))))}}]),AnalyticsDashboardWidgetSiteStats}(O.Component);t.a=Object(f.a)(E,[{type:k.b,identifier:"analytics",datapoint:"report",data:y.j,priority:1,maxAge:Object(_.p)("day"),context:"Single"}],n.createElement(v.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(14),_=a.n(b),f=a(20),k=a(10),y=a(3),v=a(29),S=a(40),O=a(13),E=a(2),j=a.n(E),D=a(0),C=a(1),w=a(18),A=function(t){function AnalyticsDashboardWidgetTopPagesTable(){return r()(this,AnalyticsDashboardWidgetTopPagesTable),g()(this,m()(AnalyticsDashboardWidgetTopPagesTable).apply(this,arguments))}return h()(AnalyticsDashboardWidgetTopPagesTable,t),c()(AnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.colspan;if(!a||!a.length)return null;var i=[{title:Object(D.__)("Title","google-site-kit"),tooltip:Object(D.__)("Page Title","google-site-kit"),primary:!0},{title:Object(D.__)("Pageviews","google-site-kit"),tooltip:Object(D.__)("Pageviews","google-site-kit")},{title:Object(D.__)("Unique Pageviews","google-site-kit"),tooltip:Object(D.__)("Unique Pageviews","google-site-kit")},{title:Object(D.__)("Bounce Rate","google-site-kit"),tooltip:Object(D.__)("Bounce Rate","google-site-kit")}],s=[],r=Object(O.map)(a[0].data.rows,(function(t,a){var n=Number(t.metrics[0].values[2]),i=o()(t.dimensions,2),r=i[0],l=i[1];return s[a]=AnalyticsDashboardWidgetTopPagesTable.addDeepLink(l),[r,Object(y.s)(t.metrics[0].values[0]),Object(y.s)(t.metrics[0].values[1]),e.createElement(C.Fragment,{key:"minichart-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(n.toFixed(2),"%")))]})),l={hideHeader:!1,chartsEnabled:!1,links:s},c=Object(v.b)(r,i,l);return e.createElement("div",{className:_()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(n))},e.createElement(v.a,null,c))}}],[{key:"addDeepLink",value:function(e){var t=n.googlesitekit.modules.analytics.settings,a=t.accountID,i=t.internalWebPropertyID,o=t.profileID;return a?"https://analytics.google.com/analytics/web/#/report/content-drilldown/a".concat(a,"w").concat(i,"p").concat(o,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:").concat(encodeURIComponent(e.replace(/\//g,"~2F"))):"https://analytics.google.com/analytics/web/"}}]),AnalyticsDashboardWidgetTopPagesTable}(C.Component);A.propTypes={data:j.a.array,colspan:j.a.number},A.defaultProps={data:null,colspan:12},t.a=Object(f.a)(A,[{type:k.b,identifier:"analytics",datapoint:"report",data:Object(w.g)(),priority:1,maxAge:Object(y.p)("day"),context:["Single","Dashboard"]}],e.createElement(S.a,{padding:!0}),{createGrid:!0})}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(26),p=a(20),h=a(10),b=a(3),_=a(18),f=a(27),k=a(2),y=a.n(k),v=a(0),S=a(1),O=function(t){function AnalyticsDashboardWidgetOverview(){return i()(this,AnalyticsDashboardWidgetOverview),l()(this,d()(AnalyticsDashboardWidgetOverview).apply(this,arguments))}return u()(AnalyticsDashboardWidgetOverview,t),s()(AnalyticsDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.selectedStats,i=t.handleStatSelection;if(!a||!a.length)return null;var o=Object(_.b)(a);if(!o)return null;var s=o.totalUsers,r=o.totalSessions,l=o.averageBounceRate,c=o.averageSessionDuration,d=o.totalUsersChange,g=o.totalSessionsChange,u=o.averageBounceRateChange,p=o.averageSessionDurationChange,h=[{className:"googlesitekit-data-block--users googlesitekit-data-block--button-1",title:Object(v.__)("Users","google-site-kit"),datapoint:Object(b.u)(s),change:d,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:i},{className:"googlesitekit-data-block--sessions googlesitekit-data-block--button-2",title:Object(v.__)("Sessions","google-site-kit"),datapoint:Object(b.u)(r),change:g,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:i},{className:"googlesitekit-data-block--bounce googlesitekit-data-block--button-3",title:Object(v.__)("Bounce Rate","google-site-kit"),datapoint:Number(l).toFixed(2),change:u,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:i,datapointUnit:"%",invertChangeColor:!0},{className:"googlesitekit-data-block--duration googlesitekit-data-block--button-4",title:Object(v.__)("Session Duration","google-site-kit"),datapoint:Object(b.t)(c),change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:i}];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,a){return e.createElement("div",{key:a,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:a,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}(S.Component);O.propTypes={handleDataError:y.a.func.isRequired},t.a=Object(p.a)(O,[{type:h.b,identifier:"analytics",datapoint:"report",data:_.i,priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"]}],e.createElement(f.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},_.h,_.f)}).call(this,a(1))},function(e,t,a){"use strict";a.d(t,"a",(function(){return n}));var n=["#178EC5","#54B23B","#EB5729","#ECED33","#34CBE3","#82E88E"]},function(e,t,a){"use strict";(function(e,n){var i=a(38),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(215),_=a(78),f=a(1),k=function(t){function AnalyticsAdminbarWidget(){return r()(this,AnalyticsAdminbarWidget),g()(this,m()(AnalyticsAdminbarWidget).apply(this,arguments))}return h()(AnalyticsAdminbarWidget,t),c()(AnalyticsAdminbarWidget,[{key:"render",value:function(){return"undefined"!==o()(e.googlesitekit.permaLink)&&""===e.googlesitekit.permaLink?null:e.googlesitekit.modules.analytics.active?n.createElement(b.a,null):n.createElement(f.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},n.createElement(_.a,null)))}}]),AnalyticsAdminbarWidget}(f.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(26),_=a(20),f=a(10),k=a(3),y=a(18),v=a(27),S=a(0),O=a(1);function E(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var j=function(t){function AnalyticsAdminbarWidgetOverview(){return r()(this,AnalyticsAdminbarWidgetOverview),g()(this,m()(AnalyticsAdminbarWidgetOverview).apply(this,arguments))}return h()(AnalyticsAdminbarWidgetOverview,t),c()(AnalyticsAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error||!t.length)return null;var a=Object(y.b)(t);if(!a)return null;var n=a.totalUsers,i=a.totalSessions,o=a.totalUsersChange,s=a.totalSessionsChange;return e.createElement(O.Fragment,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(S.__)("Total Users","google-site-kit"),datapoint:Object(k.u)(n),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(b.a,{className:"overview-total-sessions",title:Object(S.__)("Total Sessions","google-site-kit"),datapoint:Object(k.u)(i),change:s,changeDataUnit:"%"})))}}]),AnalyticsAdminbarWidgetOverview}(O.Component);t.a=Object(_.a)(j,[{type:f.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?E(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):E(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},y.i,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(k.p)("day"),context:"Adminbar"}],e.createElement(O.Fragment,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,{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(v.a,{width:"auto",height:"59px"}))),{inGrid:!0},y.h,y.f)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(84),_=a(217),f=a(1),k=a(0),y=a(22),v=a(44),S=a(56),O=a(47),E=a(101),j=a(14),D=a.n(j),C=function(t){function AnalyticsAllTraffic(e){var t;return o()(this,AnalyticsAllTraffic),(t=c()(this,g()(AnalyticsAllTraffic).call(this,e))).state={receivingData:!0,error:!1},t.handleDataError=t.handleDataError.bind(m()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(m()(t)),t}return h()(AnalyticsAllTraffic,t),r()(AnalyticsAllTraffic,[{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0})}},{key:"getErrorDataComponent",value:function(){var t=e.googlesitekit.modules.analytics,a=t.active,n=t.setupComplete,i=this.state,o=i.error,s=i.receivingData;return a&&!n?Object(E.a)("analytics",!0,!0,!0):s?null:o?Object(O.a)(Object(k._x)("Analytics","Service name","google-site-kit"),o,!0,!0,!0):Object(S.a)(Object(k._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)}},{key:"render",value:function(){var e=this.state,t=e.error,a=e.receivingData,i=t||!a?"googlesitekit-nodata":"";return n.createElement(f.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(v.a,{description:Object(k.__)("How people found your site.","google-site-kit"),title:Object(k.__)("All Traffic","google-site-kit")})),this.getErrorDataComponent(),n.createElement("div",{className:D()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",i)},n.createElement(y.a,{className:"googlesitekit-dashboard-all-traffic"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.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 "},n.createElement(b.a,{source:!0,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess})),n.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 "},n.createElement(_.a,null)))))))}}]),AnalyticsAllTraffic}(f.Component);t.a=C}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(20),p=a(10),h=a(3),b=a(29),_=a(106),f=a(40),k=a(13),y=a(0),v=a(1),S=a(18),O=function(t){function AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources(){return i()(this,AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources),l()(this,d()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources).apply(this,arguments))}return u()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,t),s()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(y.__)("Source","google-site-kit"),primary:!0},{title:Object(y.__)("Percent","google-site-kit")}],n=t[0].data.totals[0].values[0],i=Object(k.map)(t[0].data.rows,(function(t,a){var i=t.metrics[0].values[0]/n*100;return!(1>i)&&[t.dimensions[0],e.createElement(v.Fragment,{key:"minichart-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(i.toFixed(2),"%")," ",e.createElement(_.a,{percent:i.toFixed(1),index:a})))]})),o=Object(b.b)(i,a,{hideHeader:!0,chartsEnabled:!0});return e.createElement("div",{className:"googlesitekit-alltraffic-widget"},e.createElement(b.a,null,o))}}]),AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources}(v.Component);t.a=Object(m.a)(O,[{type:p.b,identifier:"analytics",datapoint:"report",data:S.k,priority:1,maxAge:Object(h.p)("day"),context:"Dashboard"}],e.createElement(f.a,{rows:3,rowHeight:50}))}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(26),_=a(20),f=a(10),k=a(54),y=a(37),v=a(27),S=a(3),O=a(13),E=a(0),j=a(1),D=a(18);function C(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function w(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?C(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):C(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var A=function(t){function AnalyticsDashboardWidgetTopLevel(e){var t;return r()(this,AnalyticsDashboardWidgetTopLevel),(t=g()(this,m()(AnalyticsDashboardWidgetTopLevel).call(this,e))).state={accounts:!1,goals:!1},t}return h()(AnalyticsDashboardWidgetTopLevel,t),c()(AnalyticsDashboardWidgetTopLevel,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.overview,i=t.extractedAnalytics,o=t.goals,s=e.googlesitekit.permaLink,r=Object(S.n)("googlesitekit-module-analytics",{}),l="",c="",d="",g="",u="",m="";return a&&(l=a.totalUsers,c=a.totalUsersChange,d=a.goalCompletions,g=a.goalCompletionsChange,u=a.averageBounceRate,m=a.averageBounceRateChange),n.createElement(j.Fragment,null,n.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 "},n.createElement(b.a,{className:"overview-total-users",title:Object(E.__)("Unique Visitors from Search","google-site-kit"),datapoint:Object(S.u)(l),change:c,changeDataUnit:"%",source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,1),change:c})})),n.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&&n.createElement(b.a,{className:"overview-bounce-rate",title:Object(E.__)("Bounce Rate","google-site-kit"),datapoint:Number(u).toFixed(2),datapointUnit:Object(E.__)("%","google-site-kit"),change:m,changeDataUnit:"%",invertChangeColor:!0,source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,2),change:m})}),!s&&o&&Object(O.isEmpty)(o.items)&&n.createElement(y.a,{title:Object(E.__)("Use goals to measure success.","google-site-kit"),description:Object(E.__)("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(E.__)("Create a new goal","google-site-kit")}),!s&&o&&!Object(O.isEmpty)(o.items)&&n.createElement(b.a,{className:"overview-goals-completed",title:Object(E.__)("Goals Completed","google-site-kit"),datapoint:Object(S.u)(d),change:g,changeDataUnit:"%",source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,3),change:g})}),!s&&!o&&n.createElement(v.a,{width:"100%",height:"202px"})))}}]),AnalyticsDashboardWidgetTopLevel}(j.Component);t.a=Object(_.a)(A,[{type:f.b,identifier:"analytics",datapoint:"report",data:w({},D.i,{url:e.googlesitekit.permaLink}),priority:1,maxAge:Object(S.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.overview)return{overview:Object(D.b)(a)}}},{type:f.b,identifier:"analytics",datapoint:"report",data:w({},D.j,{url:e.googlesitekit.permaLink}),priority:1,maxAge:Object(S.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.extractedAnalytics)return{extractedAnalytics:Object(D.d)(a)}}},{type:f.b,identifier:"analytics",datapoint:"goals",data:{url:e.googlesitekit.permaLink},priority:1,maxAge:Object(S.p)("hour"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.goals)return{goals:a}}}],n.createElement(j.Fragment,null,n.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 "},n.createElement(v.a,{width:"100%",height:"202px"})),n.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 "},n.createElement(v.a,{width:"100%",height:"202px"}))),{inGrid:!0},(function(e,t){return"report"===t&&Object(D.h)(e)}),D.f)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(107),p=a(26),h=a(37),b=a(20),_=a(10),f=a(3),k=a(18),y=a(0),v=a(1),S=function(t){function WPAnalyticsDashboardWidgetOverview(){return i()(this,WPAnalyticsDashboardWidgetOverview),l()(this,d()(WPAnalyticsDashboardWidgetOverview).apply(this,arguments))}return u()(WPAnalyticsDashboardWidgetOverview,t),s()(WPAnalyticsDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(k.b)(t);if(!a)return null;var n=a.totalUsers,i=a.averageSessionDuration,o=a.totalUsersChange,s=a.averageSessionDurationChange;return e.createElement(v.Fragment,null,t.length?e.createElement(v.Fragment,null,e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-users",title:Object(y.__)("Total Unique Visitors","google-site-kit"),datapoint:Object(f.u)(n),change:o,changeDataUnit:"%"}),e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-average-session-duration",title:Object(y.__)("Avg. Time on Page","google-site-kit"),datapoint:Object(f.t)(i),change:s,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(h.a,{title:Object(y.__)("Analytics Gathering Data","google-site-kit"),description:Object(y.__)("Analytics data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPAnalyticsDashboardWidgetOverview}(v.Component);t.a=Object(b.a)(S,[{type:_.b,identifier:"analytics",datapoint:"report",data:k.i,priority:1,maxAge:Object(f.p)("day"),context:["WPDashboard"]}],e.createElement(m.a,{width:"23%",height:"94px",count:2}),{},k.h,k.f)}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(44),p=a(22),h=a(1),b=a(0),_=a(105),f=a(84),k=function(t){function AnalyticsDashboardDetailsWidgetTopAcquisitionSources(){return i()(this,AnalyticsDashboardDetailsWidgetTopAcquisitionSources),l()(this,d()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources).apply(this,arguments))}return u()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,t),s()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,[{key:"render",value:function(){return e.createElement(h.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(b.__)("All Traffic","google-site-kit"),description:Object(b.__)("How people found your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{className:"googlesitekit-analytics-acquisition-sources",footer:!0,headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(b.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(b._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(f.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,null)))))))}}]),AnalyticsDashboardDetailsWidgetTopAcquisitionSources}(h.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(40),v=a(13),S=a(0),O=a(1),E=a(18),j=function(t){function WPAnalyticsDashboardWidgetTopPagesTable(){return r()(this,WPAnalyticsDashboardWidgetTopPagesTable),g()(this,m()(WPAnalyticsDashboardWidgetTopPagesTable).apply(this,arguments))}return h()(WPAnalyticsDashboardWidgetTopPagesTable,t),c()(WPAnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data,a=e.googlesitekit.admin.siteURL;if(Object(E.h)(t))return null;var i=[],s=Object(v.map)(t[0].data.rows,(function(e,t){var n=o()(e.dimensions,2),s=n[0],r=n[1];return i[t]=a+r,[s,Object(f.s)(e.metrics[0].values[0])]})),r=[{title:Object(S.__)("Title","google-site-kit"),tooltip:Object(S.__)("Page Title","google-site-kit"),primary:!0},{title:Object(S.__)("Pageviews","google-site-kit"),tooltip:Object(S.__)("Pageviews","google-site-kit")}],l={chartsEnabled:!0,links:i,cap:5,showURLs:!0},c=Object(k.b)(s,r,l);return n.createElement("div",{className:"googlesitekit-search-console-widget"},n.createElement("h2",{className:"googlesitekit-search-console-widget__title"},Object(S.__)("Top content over the last 28 days","google-site-kit")),n.createElement(k.a,null,c))}}]),WPAnalyticsDashboardWidgetTopPagesTable}(O.Component);t.a=Object(b.a)(j,[{type:_.b,identifier:"analytics",datapoint:"report",data:Object(E.g)(),priority:1,maxAge:Object(f.p)("day"),context:"WPDashboard"}],n.createElement(y.a,{rows:6}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(20),h=a(10),b=a(3),_=a(29),f=a(22),k=a(40),y=a(13),v=a(0),S=a(1),O=a(18),E=function(t){function AnalyticsAdSenseDashboardWidgetTopPagesTable(){return o()(this,AnalyticsAdSenseDashboardWidgetTopPagesTable),c()(this,g()(AnalyticsAdSenseDashboardWidgetTopPagesTable).apply(this,arguments))}return m()(AnalyticsAdSenseDashboardWidgetTopPagesTable,t),r()(AnalyticsAdSenseDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Page Title","google-site-kit"),tooltip:Object(v.__)("Page Title","google-site-kit"),primary:!0},{title:Object(v.__)("Earnings","google-site-kit"),tooltip:Object(v.__)("Earnings","google-site-kit")},{title:Object(v.__)("Page RPM","google-site-kit"),tooltip:Object(v.__)("Page RPM","google-site-kit")},{title:Object(v.__)("Impressions","google-site-kit"),tooltip:Object(v.__)("Impressions","google-site-kit")}],i=Object(y.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(b.s)(e.metrics[0].values[2])]})),o=e.googlesitekit.modules.analytics.settings,s=o.accountID,r=o.internalWebPropertyID,l=o.profileID,c="https://analytics.google.com/analytics/web/?pli=1#/report/content-pages/a".concat(s,"w").concat(r,"p").concat(l,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:~2F"),d={hideHeader:!1,chartsEnabled:!1,links:Object(y.map)(t[0].data.rows,(function(e){var t=e.dimensions[1].replace(/\//g,"~2F");return c+t}))},g=Object(_.b)(i,a,d);return AnalyticsAdSenseDashboardWidgetTopPagesTable.renderLayout(n.createElement(_.a,null,g))}}],[{key:"renderLayout",value:function(t){var a=e.googlesitekit.modules.adsense.accountURL;return n.createElement(f.a,{header:!0,title:Object(v.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(v.__)("Advanced Settings","google-site-kit"),headerCtaLink:a},t)}}]),AnalyticsAdSenseDashboardWidgetTopPagesTable}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"analytics",datapoint:"report",data:O.a,priority:1,maxAge:Object(b.p)("day"),context:"Single"}],E.renderLayout(n.createElement(k.a,{padding:!0})),{inGrid:!0,fullWidth:!0,createGrid:!0},(function(){return!1}),(function(t){return!(!t||!t.error)&&(400===t.error.code&&"INVALID_ARGUMENT"===t.error.status&&e.googlesitekit.modules.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(v.__)("Unidentified error","google-site-kit"))}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(40),v=a(22),S=a(13),O=a(0),E=a(1),j=a(18),D=function(t){function AnalyticsDashboardWidgetPopularPagesTable(){return r()(this,AnalyticsDashboardWidgetPopularPagesTable),g()(this,m()(AnalyticsDashboardWidgetPopularPagesTable).apply(this,arguments))}return h()(AnalyticsDashboardWidgetPopularPagesTable,t),c()(AnalyticsDashboardWidgetPopularPagesTable,[{key:"render",value:function(){var t=this.props.data,a=e.googlesitekit.admin.siteURL;if(!t||!t.length)return null;var i=[{title:Object(O.__)("Most popular content","google-site-kit"),primary:!0},{title:Object(O.__)("Views","google-site-kit")}],s=[],r=Object(S.map)(t[0].data.rows,(function(e,t){var n=o()(e.dimensions,2),i=n[0],r=n[1];return s[t]=a+r,[i,Object(f.s)(e.metrics[0].values[0])]})),l={hideHeader:!1,chartsEnabled:!1,links:s,showURLs:!0},c=Object(k.b)(r,i,l);return AnalyticsDashboardWidgetPopularPagesTable.renderLayout(n.createElement(k.a,null,c))}}],[{key:"renderLayout",value:function(t){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},n.createElement(v.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:e.googlesitekit.modules.analytics.homepage,fill:!0},t))}}]),AnalyticsDashboardWidgetPopularPagesTable}(E.Component);t.a=Object(b.a)(D,[{type:_.b,identifier:"analytics",datapoint:"report",data:Object(j.g)(),priority:1,maxAge:Object(f.p)("day"),context:["Single","Dashboard"]}],D.renderLayout(n.createElement(y.a,{padding:!0})),{inGrid:!0,createGrid:!0},j.h)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(13),p=a(20),h=a(10),b=a(3),_=a(29),f=a(40),k=a(22),y=a(37),v=a(0),S=a(1),O=a(18),E=function(t){function AdSenseDashboardWidgetTopPagesTableSmall(){return i()(this,AdSenseDashboardWidgetTopPagesTableSmall),l()(this,d()(AdSenseDashboardWidgetTopPagesTableSmall).apply(this,arguments))}return u()(AdSenseDashboardWidgetTopPagesTableSmall,t),s()(AdSenseDashboardWidgetTopPagesTableSmall,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Top Earning Pages","google-site-kit"),tooltip:Object(v.__)("Top Earning Pages","google-site-kit"),primary:!0},{title:Object(v.__)("Revenue","google-site-kit"),tooltip:Object(v.__)("Revenue","google-site-kit")}],n=[],i=Object(m.map)(t[0].data.rows,(function(e,t){return n[t]=e.dimensions[1],[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2)]})),o={hideHeader:!1,chartsEnabled:!1,cap:5,links:n},s=Object(_.b)(i,a,o);return AdSenseDashboardWidgetTopPagesTableSmall.renderLayout(e.createElement(_.a,null,s))}}],[{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-top-earnings-pages",footer:!0,footerCtaLabel:Object(v._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"http://analytics.google.com",fill:!0},t))}}]),AdSenseDashboardWidgetTopPagesTableSmall}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"analytics",datapoint:"report",data:O.a,priority:1,maxAge:Object(b.p)("day"),context:"Dashboard"}],E.renderLayout(e.createElement(f.a,{rows:5,padding:!0})),{inGrid:!0,createGrid:!0},(function(){return!1}),(function(t){if(t&&t.error_data){var a=Object.values(t.error_data);if(a[0]&&"badRequest"===a[0].reason)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-top-earnings-pages",fill:!0},e.createElement(y.a,{title:Object(v.__)("Restricted metric(s)","google-site-kit"),description:Object(v.__)("You need to link Analytics and AdSense to get report for your top earning pages. Learn more: https://support.google.com/adsense/answer/6084409 ","google-site-kit")})))}if(t&&t.errors){var n=Object.values(t.errors);if(n[0]&&n[0][0])return n[0][0]}return!1}))}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(226),h=a(22),b=a(44),_=a(1),f=a(0),k=function(t){function DashboardSpeed(){return o()(this,DashboardSpeed),c()(this,g()(DashboardSpeed).apply(this,arguments))}return m()(DashboardSpeed,t),r()(DashboardSpeed,[{key:"render",value:function(){var t=e.googlesitekit.permaLink?Object(f.__)("How fast this page is.","google-site-kit"):Object(f.__)("How fast your home page is.","google-site-kit");return n.createElement(_.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(b.a,{title:Object(f.__)("Speed","google-site-kit"),description:t})),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(h.a,{className:"googlesitekit-pagespeed-report"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(p.a,null))))))}}]),DashboardSpeed}(_.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function DashboardSpeedInner(){return i()(this,DashboardSpeedInner),l()(this,d()(DashboardSpeedInner).apply(this,arguments))}return u()(DashboardSpeedInner,e),s()(DashboardSpeedInner,[{key:"render",value:function(){return null}}]),DashboardSpeedInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardSpeed")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(58),_=a(32),f=a(47),k=a(1),y=a(0),v=a(147),S=a(77),O=function(t){function PageSpeedInsightsDashboardWidgetHomepageSpeed(e){var t;return o()(this,PageSpeedInsightsDashboardWidgetHomepageSpeed),(t=c()(this,g()(PageSpeedInsightsDashboardWidgetHomepageSpeed).call(this,e))).state={loading:!0,error:!1},t.handleDataLoaded=t.handleDataLoaded.bind(m()(t)),t.handleDataError=t.handleDataError.bind(m()(t)),t}return h()(PageSpeedInsightsDashboardWidgetHomepageSpeed,t),r()(PageSpeedInsightsDashboardWidgetHomepageSpeed,[{key:"handleDataLoaded",value:function(){this.setState({loading:!1})}},{key:"handleDataError",value:function(e){this.setState({error:e})}},{key:"render",value:function(){var t=this.state,a=t.loading,i=t.error,o={name:Object(y._x)("PageSpeed Insights","Service name","google-site-kit"),link:Object(y.sprintf)("https://developers.google.com/speed/pagespeed/insights/?url=%s",e.googlesitekit.permaLink||e.googlesitekit.admin.siteURL)};return i?n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},Object(f.a)(Object(y._x)("PageSpeed Insights","Service name","google-site-kit"),i,!0,!0,!1)):n.createElement(k.Fragment,null,a&&n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-pagespeed-report__loading"},n.createElement(_.a,null),n.createElement("p",null,Object(y.__)("PageSpeed Insights is preparing data…","google-site-kit")))),n.createElement(v.b,{handleDataLoaded:this.handleDataLoaded,handleDataError:this.handleDataError,title:Object(y.__)("Mobile","google-site-kit")}),n.createElement(v.a,{title:Object(y.__)("Desktop","google-site-kit")}),!a&&n.createElement(k.Fragment,null,n.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 "},n.createElement(b.a,{name:o.name,href:o.link,external:!0})),n.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 mdc-layout-grid__cell--align-right-tablet "},n.createElement(S.a,null))))}}]),PageSpeedInsightsDashboardWidgetHomepageSpeed}(k.Component);t.a=O}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(37),r=a(10),l=a(67),c=a(3),d=a(0);t.a=function PageSpeedInsightsCTA(){var t=e.googlesitekit.modules["pagespeed-insights"],a=t.active,i=t.setupComplete;if(!e.googlesitekit.permissions.canManageOptions&&!i)return null;return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(s.a,{title:!i&&a?Object(d.__)("Complete PageSpeed Insights activation.","google-site-kit"):Object(d.__)("Activate PageSpeed Insights.","google-site-kit"),description:Object(d.__)("Google PageSpeed Insights gives you metrics about performance, accessibility, SEO and PWA.","google-site-kit"),ctaLink:"#",ctaLabel:!i&&a?Object(d.__)("Complete activation","google-site-kit"):Object(d.__)("Activate PageSpeed Insights","google-site-kit"),onClick:function(){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(Object(c.a)(r.c,"pagespeed-insights",!0));case 3:e.location=Object(c.m)("pagespeed-insights"),t.next=9;break;case 6:t.prev=6,t.t0=t.catch(0),Object(c.x)(l.a,{id:"pagespeed-insights-setup-error",title:Object(d.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 9:case"end":return t.stop()}}),null,null,[[0,6]])}}))}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){a.d(t,"a",(function(){return s}));var i=a(0),o=a(3),s=function(){var t=e.googlesitekit.dashboardPermalink,a=Object(i.sprintf)(
|
24 |
+
/* translators: %s is the URL to the Site Kit dashboard. */
|
25 |
+
Object(i.__)('To view insights, <a href="%s">visit the dashboard</a>.',"google-site-kit"),t);return n.createElement("p",{dangerouslySetInnerHTML:Object(o.w)(a,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})})}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(21),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(66),k=a(14),y=a.n(k),v=a(1),S=a(0),O=a(231),E=a(108),j=a(232),D=a(62),C=a(22),w=a(83),A=a(32),x=a(56),N=a(47),P=a(3),T=a(65);function L(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var I=function(t){function GoogleSitekitSearchConsoleDashboardWidget(e){var t;return r()(this,GoogleSitekitSearchConsoleDashboardWidget),(t=g()(this,m()(GoogleSitekitSearchConsoleDashboardWidget).call(this,e))).state={selectedStats:[0,1],receivingData:!0,error:!1,loading:!0},t.handleStatSelection=t.handleStatSelection.bind(h()(t)),t.buildSeries=t.buildSeries.bind(h()(t)),t.buildVAxes=t.buildVAxes.bind(h()(t)),t.handleDataError=t.handleDataError.bind(h()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(h()(t)),t}return _()(GoogleSitekitSearchConsoleDashboardWidget,t),c()(GoogleSitekitSearchConsoleDashboardWidget,[{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleStatSelection",value:function(e){var t=this.state.selectedStats,a=t.slice();t.includes(e)?a=t.filter((function(t){return e!==t})):a.push(e),0!==a.length&&this.setState({selectedStats:a})}},{key:"buildSeries",value:function(){var e=this.state.selectedStats,t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"};return e.map((function(e,a){return{color:t[e],targetAxisIndex:a}}))}},{key:"buildVAxes",value:function(){var e=this.state.selectedStats,t={0:Object(S.__)("Clicks","google-site-kit"),1:Object(S.__)("Impressions","google-site-kit"),2:Object(S.__)("Average CTR","google-site-kit"),3:Object(S.__)("Average Position","google-site-kit")};return e.map((function(e){var a={};return 3===e&&(a.direction=-1),function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?L(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):L(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({title:t[e]},a)}))}},{key:"render",value:function(){var t=this.state,a=t.selectedStats,i=t.receivingData,o=t.error,s=t.loading,r=this.buildSeries(),l=this.buildVAxes(),c=!s&&i?"":"googlesitekit-nodata",d=Object(P.g)(),g=Object(S.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",e.googlesitekit.admin.siteURL);return n.createElement(v.Fragment,null,n.createElement(f.a,null),n.createElement(w.a,{module:"search-console"}),n.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--search-console"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(D.a,{title:Object(S._x)("Search Console","Service name","google-site-kit"),icon:!0,iconWidth:"23",iconHeight:"21",iconID:"search-console",status:"connected",statusText:Object(S.__)("Search Console is connected","google-site-kit")}),s&&n.createElement(A.a,null)),!i&&(o?Object(N.a)(Object(S._x)("Search Console","Service name","google-site-kit"),o,!0,!0,!0):Object(x.a)(Object(S._x)("Search Console","Service name","google-site-kit"),!0,!0,!0)),n.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",c)},n.createElement(C.a,{header:!0
|
26 |
+
/* translators: %s: date range */,title:Object(S.sprintf)(Object(S.__)("Overview for the last %s","google-site-kit"),d),headerCtaLabel:Object(S.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:g},n.createElement(j.a,{selectedStats:a,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),n.createElement(O.a,{selectedStats:a,series:r,vAxes:l}))),n.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",c)},n.createElement(C.a
|
27 |
+
/* translators: %s: date range */,{title:Object(S.sprintf)(Object(S.__)("Top search queries over the last %s","google-site-kit"),d),header:!0,footer:!0,headerCtaLabel:Object(S.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:g,footerCtaLabel:Object(S._x)("Search Console","Service name","google-site-kit"),footerCtaLink:g},n.createElement(E.a,null))),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},n.createElement(T.a,null))))))}}]),GoogleSitekitSearchConsoleDashboardWidget}(v.Component);t.a=I}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(57),k=a(27),y=a(3),v=a(41),S=a(0),O=a(1),E=function(t){function SearchConsoleDashboardWidgetSiteStats(e){var t;return o()(this,SearchConsoleDashboardWidgetSiteStats),(t=c()(this,g()(SearchConsoleDashboardWidgetSiteStats).call(this,e))).setOptions=t.setOptions.bind(m()(t)),t}return h()(SearchConsoleDashboardWidgetSiteStats,t),r()(SearchConsoleDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,a=t.selectedStats,n=t.series,i=t.vAxes,o=e.googlesitekit.pageTitle,s=Object(S.__)("Search Traffic Summary","google-site-kit");o&&o.length&&(
|
28 |
+
/* translators: %s: page title */
|
29 |
+
s=Object(S.sprintf)(Object(S.__)("Search Traffic Summary for %s","google-site-kit"),Object(y.d)(o)));var r={chart:{title:s},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=i,3<=a.length&&(r.vAxis.textPosition="none",r.vAxis.gridlines.color="#fff",r.vAxis.minorGridlines.color="#fff",r.chartArea.width="98%"),r}},{key:"render",value:function(){var e=this.props,t=e.data,a=e.selectedStats;if(!t||!t.length)return null;var i=this.setOptions(),o=Object(v.a)(t);return n.createElement("section",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(f.a,{selectedStats:a,data:o.dataMap,options:i,singleStat:!1}))))}}]),SearchConsoleDashboardWidgetSiteStats}(O.Component);t.a=Object(b.a)(E,[{type:_.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(y.p)("day"),context:"Single"}],n.createElement(k.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(26),p=a(20),h=a(10),b=a(27),_=a(3),f=a(41),k=a(2),y=a.n(k),v=a(0),S=a(1),O=function(t){function SearchConsoleDashboardWidgetOverview(){return i()(this,SearchConsoleDashboardWidgetOverview),l()(this,d()(SearchConsoleDashboardWidgetOverview).apply(this,arguments))}return u()(SearchConsoleDashboardWidgetOverview,t),s()(SearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.selectedStats,i=t.handleStatSelection;if(!a||!a.length)return null;var o=Object(f.a)(a),s=o.totalClicks,r=o.totalImpressions,l=o.averageCTR,c=o.averagePosition,d=o.totalClicksChange,g=o.totalImpressionsChange,u=o.averageCTRChange,p=o.averagePositionChange,h=[{className:"googlesitekit-data-block--clicks googlesitekit-data-block--button-1",title:Object(v.__)("Total Clicks","google-site-kit"),datapoint:s,change:d,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:i},{className:"googlesitekit-data-block--impressions googlesitekit-data-block--button-2",title:Object(v.__)("Total Impressions","google-site-kit"),datapoint:r,change:g,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:i},{className:"googlesitekit-data-block--ctr googlesitekit-data-block--button-3",title:Object(v.__)("Average CTR","google-site-kit"),datapoint:l+"%",change:u,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:i},{className:"googlesitekit-data-block--position googlesitekit-data-block--button-4",title:Object(v.__)("Average Position","google-site-kit"),datapoint:c,change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:i}];return e.createElement(S.Fragment,null,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,a){return e.createElement("div",{key:a,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:a,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}(S.Component);O.propTypes={handleDataError:y.a.func.isRequired},t.a=Object(p.a)(O,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],e.createElement(b.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},f.b)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(38),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(9),h=a.n(p),b=a(234),_=a(1),f=function(t){function GoogleSitekitSearchConsoleAdminbarWidget(){return r()(this,GoogleSitekitSearchConsoleAdminbarWidget),g()(this,m()(GoogleSitekitSearchConsoleAdminbarWidget).apply(this,arguments))}return h()(GoogleSitekitSearchConsoleAdminbarWidget,t),c()(GoogleSitekitSearchConsoleAdminbarWidget,[{key:"render",value:function(){return"undefined"!==o()(e.googlesitekit.permaLink)&&""===e.googlesitekit.permaLink?null:n.createElement(b.a,null)}}]),GoogleSitekitSearchConsoleAdminbarWidget}(_.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(26),h=a(20),b=a(10),_=a(3),f=a(41),k=a(27),y=a(0),v=a(1),S=function(t){function SearchConsoleAdminbarWidgetOverview(){return o()(this,SearchConsoleAdminbarWidgetOverview),c()(this,g()(SearchConsoleAdminbarWidgetOverview).apply(this,arguments))}return m()(SearchConsoleAdminbarWidgetOverview,t),r()(SearchConsoleAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error)return null;var a=Object(f.a)(t),n=a.totalClicks,i=a.totalImpressions,o=a.totalClicksChange,s=a.totalImpressionsChange;return e.createElement(v.Fragment,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(p.a,{className:"overview-total-impressions",title:Object(y.__)("Total Impressions","google-site-kit"),datapoint:i,change:s,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(p.a,{className:"overview-total-clicks",title:Object(y.__)("Total Clicks","google-site-kit"),datapoint:n,change:o,changeDataUnit:"%"})))}}]),SearchConsoleAdminbarWidgetOverview}(v.Component);t.a=Object(h.a)(S,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:n.googlesitekit.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:"Adminbar"}],e.createElement(v.Fragment,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},f.b)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(236),p=a(1),h=function(t){function WPSearchConsoleDashboardWidget(){return i()(this,WPSearchConsoleDashboardWidget),l()(this,d()(WPSearchConsoleDashboardWidget).apply(this,arguments))}return u()(WPSearchConsoleDashboardWidget,t),s()(WPSearchConsoleDashboardWidget,[{key:"render",value:function(){return e.createElement(p.Fragment,null,e.createElement(m.a,null))}}]),WPSearchConsoleDashboardWidget}(p.Component);t.a=h}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(107),p=a(26),h=a(20),b=a(10),_=a(3),f=a(41),k=a(37),y=a(0),v=a(1),S=function(t){function WPSearchConsoleDashboardWidgetOverview(){return i()(this,WPSearchConsoleDashboardWidgetOverview),l()(this,d()(WPSearchConsoleDashboardWidgetOverview).apply(this,arguments))}return u()(WPSearchConsoleDashboardWidgetOverview,t),s()(WPSearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(f.a)(t),n=a.totalClicks,i=a.totalImpressions,o=a.totalClicksChange,s=a.totalImpressionsChange;return e.createElement(v.Fragment,null,t.length?e.createElement(v.Fragment,null,e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-impressions",title:Object(y.__)("Total Impressions","google-site-kit"),datapoint:i,change:s,changeDataUnit:"%"}),e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-clicks",title:Object(y.__)("Total Clicks","google-site-kit"),datapoint:n,change:o,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(k.a,{title:Object(y.__)("Search Console Data Empty","google-site-kit"),description:Object(y.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPSearchConsoleDashboardWidgetOverview}(v.Component);t.a=Object(h.a)(S,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:["WPDashboard"]}],e.createElement(m.a,{width:"23%",height:"94px",count:2}),{},f.b)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(109),h=a(22),b=a(44),_=a(78),f=a(14),k=a.n(f),y=a(1),v=a(0),S=function(t){function DashboardSearchFunnel(){return o()(this,DashboardSearchFunnel),c()(this,g()(DashboardSearchFunnel).apply(this,arguments))}return m()(DashboardSearchFunnel,t),r()(DashboardSearchFunnel,[{key:"render",value:function(){var t=e.googlesitekit.permissions.canManageOptions,a=e.googlesitekit.modules.analytics.active||t?12:6;return n.createElement(y.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(b.a,{title:Object(v.__)("Search Funnel","google-site-kit"),description:Object(v.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit")})),n.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(a))},n.createElement(h.a,{className:"googlesitekit-analytics-search-funnel"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(p.a,null),!e.googlesitekit.modules.analytics.active&&n.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 "},n.createElement(_.a,null)))))))}}]),DashboardSearchFunnel}(y.Component);t.a=S}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(26),h=a(20),b=a(10),_=a(0),f=a(1),k=a(41),y=a(54),v=a(27),S=a(3),O=a(37),E=function(t){function SearchConsoleDashboardWidgetTopLevel(){return o()(this,SearchConsoleDashboardWidgetTopLevel),c()(this,g()(SearchConsoleDashboardWidgetTopLevel).apply(this,arguments))}return m()(SearchConsoleDashboardWidgetTopLevel,t),r()(SearchConsoleDashboardWidgetTopLevel,[{key:"render",value:function(){var t=this.props.data,a=t.error;if(a)return Object(S.A)("plugin_setup","search_console_error",a.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(O.a,{title:Object(_.__)("Something went wrong","google-site-kit"),description:a.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(O.a,{title:Object(_.__)("Search Console Data Empty","google-site-kit"),description:Object(_.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""}));var n=Object(S.n)("googlesitekit-module-search-console",{}),i=Object(k.a)(t),o=i.totalClicks,s=i.totalImpressions,r=i.totalClicksChange,l=i.totalImpressionsChange,c=i.dataMap;return e.createElement(f.Fragment,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(p.a,{className:"overview-total-impressions",title:Object(_.__)("Impressions","google-site-kit"),datapoint:s,change:l,changeDataUnit:"%",source:{name:Object(_._x)("Search Console","Service name","google-site-kit"),link:n},sparkline:e.createElement(y.a,{data:Object(S.e)(c,2),change:l})})),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(p.a,{className:"overview-total-clicks",title:Object(_.__)("Clicks","google-site-kit"),datapoint:o,change:r,changeDataUnit:"%",source:{name:Object(_._x)("Search Console","Service name","google-site-kit"),link:n},sparkline:e.createElement(y.a,{data:Object(S.e)(c,1),change:r})})))}}]),SearchConsoleDashboardWidgetTopLevel}(f.Component);t.a=Object(h.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:n.googlesitekit.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(S.p)("day"),context:["Single","Dashboard"]}],e.createElement(f.Fragment,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(v.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(v.a,{width:"100%",height:"202px"}))),{inGrid:!0},k.b)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(44),h=a(22),b=a(1),_=a(0),f=a(108),k=function(t){function DashboardDetailsWidgetKeywordsTable(){return o()(this,DashboardDetailsWidgetKeywordsTable),c()(this,g()(DashboardDetailsWidgetKeywordsTable).apply(this,arguments))}return m()(DashboardDetailsWidgetKeywordsTable,t),r()(DashboardDetailsWidgetKeywordsTable,[{key:"render",value:function(){return e.createElement(b.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{title:Object(_.__)("Top Queries","google-site-kit"),description:Object(_.__)("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(h.a,{footer:!0,footerCtaLabel:Object(_._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(_.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",n.googlesitekit.admin.siteURL)},e.createElement(f.a,null))))}}]),DashboardDetailsWidgetKeywordsTable}(b.Component);t.a=k}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(20),h=a(10),b=a(3),_=a(29),f=a(40),k=a(22),y=a(13),v=a(0),S=a(1),O=a(41),E=function(t){function DashboardWidgetPopularKeywordsTable(){return o()(this,DashboardWidgetPopularKeywordsTable),c()(this,g()(DashboardWidgetPopularKeywordsTable).apply(this,arguments))}return m()(DashboardWidgetPopularKeywordsTable,t),r()(DashboardWidgetPopularKeywordsTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Top search queries for your site","google-site-kit"),tooltip:Object(v.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(v.__)("Clicks","google-site-kit"),tooltip:Object(v.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(v.__)("Impressions","google-site-kit"),tooltip:Object(v.__)("Counted each time your content appears in search results","google-site-kit")}],i=e.googlesitekit.admin.siteURL,o=[],s=Object(y.map)(t,(function(e,t){var a=e.keys[0];return o[t]=Object(v.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%s&query=!%s&num_of_days=28",i,a),[a,Object(b.s)(e.clicks),Object(b.s)(e.impressions)]})),r={hideHeader:!1,chartsEnabled:!1,links:o},l=Object(_.b)(s,a,r);return DashboardWidgetPopularKeywordsTable.renderLayout(n.createElement(_.a,null,l))}}],[{key:"renderLayout",value:function(t){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},n.createElement(k.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(v._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(v.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",e.googlesitekit.admin.siteURL),fill:!0},t))}}]),DashboardWidgetPopularKeywordsTable}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"query",limit:10},priority:1,maxAge:Object(b.p)("day"),context:["Dashboard"]}],E.renderLayout(n.createElement(f.a,{padding:!0})),{inGrid:!0,createGrid:!0},O.b)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(78),h=a(44),b=a(22),_=a(1),f=a(0),k=a(109),y=function(t){function DashboardDetailsSearchFunnel(){return o()(this,DashboardDetailsSearchFunnel),c()(this,g()(DashboardDetailsSearchFunnel).apply(this,arguments))}return m()(DashboardDetailsSearchFunnel,t),r()(DashboardDetailsSearchFunnel,[{key:"render",value:function(){return e.createElement(_.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{description:Object(f.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit"),title:Object(f.__)("Search Funnel","google-site-kit")})),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},e.createElement(b.a,{className:"googlesitekit-analytics-search-funnel"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement(k.a,null),!n.googlesitekit.modules.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(p.a,null)))))))}}]),DashboardDetailsSearchFunnel}(_.Component);t.a=y}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(243),p=a(44),h=a(1),b=a(0),_=function(t){function DashboardPopularity(){return i()(this,DashboardPopularity),l()(this,d()(DashboardPopularity).apply(this,arguments))}return u()(DashboardPopularity,t),s()(DashboardPopularity,[{key:"render",value:function(){return e.createElement(h.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{title:Object(b.__)("Popularity","google-site-kit"),description:Object(b.__)("Your most popular pages and how people found them from Search.","google-site-kit")})),e.createElement(m.a,null))}}]),DashboardPopularity}(h.Component);t.a=_}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(e){function DashboardPopularityInner(){return i()(this,DashboardPopularityInner),l()(this,d()(DashboardPopularityInner).apply(this,arguments))}return u()(DashboardPopularityInner,e),s()(DashboardPopularityInner,[{key:"render",value:function(){return null}}]),DashboardPopularityInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardPopularity")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),g=a.n(d),u=a(8),m=a.n(u),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(13),k=a(245),y=a.n(k),v=a(10),S=a(33),O=a(22),E=a(3),j=a(1),D=a(0),C=function(t){function PostSearcher(e){var t;return r()(this,PostSearcher),(t=g()(this,m()(PostSearcher).call(this,e))).state={isSearching:!1,results:[],error:!1,message:""},t.postSearch=t.postSearch.bind(h()(t)),t.onClick=t.onClick.bind(h()(t)),t.onConfirm=t.onConfirm.bind(h()(t)),t}return _()(PostSearcher,t),c()(PostSearcher,[{key:"postSearch",value:function(e,t){var a;return o.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return t([Object(D.__)("Loading...","google-site-kit")]),n.prev=1,n.next=4,o.a.awrap(v.c.get(v.a,"search","post-search",{query:encodeURIComponent(e)}));case 4:0<(a=n.sent).length?t(Object(f.map)(a,(function(e){return e.post_title}))):t([Object(D.__)("No results found","google-site-kit")]),this.setState({isSearching:!0,results:a,error:!1,message:""}),n.next=13;break;case 9:n.prev=9,n.t0=n.catch(1),t([Object(D.__)("No results found","google-site-kit")]),this.setState({isSearching:!1,error:n.t0.code,message:n.t0.message});case 13:case"end":return n.stop()}}),null,this,[[1,9]])}},{key:"getURLPathname",value:function(e){try{var t=new URL(e);return Object(f.trim)(t.pathname,"/")}catch(e){return!1}}},{key:"onConfirm",value:function(e){this.setState({selection:e})}},{key:"onClick",value:function(){var e=this.state,t=e.results,a=e.selection,n=Object(f.find)(t,(function(e){return e.post_title===a}));document.location=Object(E.n)("googlesitekit-dashboard",{id:n.id,permaLink:n.permalink,pageTitle:a})}},{key:"render",value:function(){var t=e.googlesitekit.modules,a=t.analytics&&t.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 n.createElement("div",{className:a},n.createElement(O.a,{title:Object(D.__)("Search for individual page or post information","google-site-kit"),header:!0},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement("div",{className:"googlesitekit-post-searcher"},n.createElement("label",{className:"googlesitekit-post-searcher__label",htmlFor:"autocomplete"},Object(D.__)("Title or URL","google-site-kit")),n.createElement(y.a,{id:"autocomplete",source:Object(f.debounce)(this.postSearch,200),minLength:2,onConfirm:this.onConfirm,showNoOptionsFound:!1}),n.createElement("div",{className:"googlesitekit-post-searcher__button-wrapper"},n.createElement(S.a,{onClick:this.onClick,className:"googlesitekit-post-searcher__button"},Object(D.__)("View Data","google-site-kit")))))))))}}]),PostSearcher}(j.Component);t.a=C}).call(this,a(15),a(1))},,function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(9),m=a.n(u),p=a(1),h=a(0),b=e.googlesitekit.admin.siteURL,_=function(e){function SearchConsoleSettingStatus(){return o()(this,SearchConsoleSettingStatus),c()(this,g()(SearchConsoleSettingStatus).apply(this,arguments))}return m()(SearchConsoleSettingStatus,e),r()(SearchConsoleSettingStatus,[{key:"render",value:function(){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-settings-module__meta-item-type"},Object(h.__)("Connected URL","google-site-kit")),n.createElement("div",{className:"googlesitekit-settings-module__meta-item-data"},b))}}]),SearchConsoleSettingStatus}(p.Component);t.a=_}).call(this,a(15),a(1))},,,,,,,,,function(e,t,a){"use strict";a(256),a(259),a(260),a(261),a(262),a(264)},function(e,t,a){"use strict";(function(e,t){var n=a(23),i=a(3),o=a(194),s=a(202),r=a(104),l=a(205),c=a(207),d=a(208),g=a(12),u="adsense";if(Object(g.b)("googlesitekit.ModuleSettingsWarning","googlesitekit.adsenseSettingsWarning",Object(i.f)(d.a,{})),Object(g.b)("googlesitekit.SetupModuleShowLink","googlesitekit.adsenseSetupModuleShowLink",(function(t,a){return!("adsense"===a&&!e.googlesitekit.canAdsRun)&&t})),e.googlesitekit.modules.adsense.active){var m=Object(n.a)(t.createElement(o.a,null)),p=Object(n.a)(t.createElement(s.a,null));if(e.googlesitekit.modules[u].setupComplete)Object(g.b)("googlesitekit.ModuleApp-".concat(u),"googlesitekit.ModuleApp",m),Object(g.b)("googlesitekit.DashboardModule","googlesitekit.DashboardEarningModule",p,50);else{var h=e.googlesitekit.admin,b=h.reAuth,_=h.currentScreen,f=_?_.id:null;b||"site-kit_page_googlesitekit-module-adsense"!==f||(e.location=Object(i.n)("googlesitekit-module-".concat(u),{reAuth:!0,slug:u})),Object(g.b)("googlesitekit.Connected-".concat(u),"googlesitekit.AdSenseModuleConnected",(function(t){var a=e.googlesitekit.modules[u].settings;return!(t||void 0===a||"account-pending-review"!==a.accountStatus&&"ads-display-pending"!==a.accountStatus)||t}))}Object(g.b)("googlesitekit.ModuleSettingsDetails-".concat(u),"googlesitekit.AdSenseModuleSettingsDetails",Object(i.f)(r.a,{onSettingsPage:!0})),Object(g.b)("googlesitekit.ModuleSetup-".concat(u),"googlesitekit.TagmanagerModuleSetupWizard",Object(i.f)(l.a,{onSettingsPage:!1})),Object(g.b)("googlesitekit.autoRefreshModules","googlesitekit.AdSenseAutoRefresh",(function(t){return t.push({identifier:"adsense",toRefresh:function(){var t="";return e.googlesitekit.modules.adsense&&e.googlesitekit.modules.adsense["account-status"]&&(t=e.googlesitekit.modules.adsense["account-status"].accountStatus),!(t&&-1<t.indexOf("account-connected"))}}),t})),Object(g.b)("googlesitekit.ModulesNotificationsRequest","googlesitekit.adsenseNotifications",(function(e){return e.push({identifier:"adsense"}),e})),Object(g.b)("googlesitekit.ModuleSetupIncomplete","googlesitekit.adsenseSettingStatus",Object(i.f)(c.a,{}))}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,t){var n=a(3),i=a(23),o=a(209),s=a(214),r=a(216),l=a(218),c=a(219),d=a(220),g=a(221),u=a(222),m=a(223),p=a(224),h=a(144),b=a(12),_="analytics",f=Object(i.a)(e.createElement(s.a,null));if(Object(b.b)("googlesitekit.AdminbarModules","googlesitekit.Analytics",f,11),!t.googlesitekit.modules[_].setupComplete){var k=t.googlesitekit.admin,y=k.reAuth,v=k.currentScreen,S=v?v.id:null;y||"site-kit_page_googlesitekit-module-analytics"!==S||(t.location=Object(n.n)("googlesitekit-module-".concat(_),{reAuth:!0,slug:_}))}if(t.googlesitekit.modules.analytics.active){var O=Object(i.a)(e.createElement(o.a,null)),E=Object(i.a)(e.createElement(r.a,null)),j=Object(i.a)(e.createElement(c.a,null)),D=Object(i.a)(e.createElement(g.a,null)),C=Object(i.a)(e.createElement(l.a,null)),w=Object(i.a)(e.createElement(d.a,null)),A=Object(i.a)(e.createElement(u.a,null)),x=Object(i.a)(e.createElement(m.a,null)),N=Object(i.a)(e.createElement(p.a,null));Object(b.b)("googlesitekit.DashboardModule","googlesitekit.Analytics",E,9),Object(b.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.Analytics",C,11),Object(b.b)("googlesitekit.DashboardPopularity","googlesitekit.Analytics",x,20),Object(b.b)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall","googlesitekit.Analytics",N,20),Object(b.b)("googlesitekit.DashboardDetailsModule","googlesitekit.Analytics",w,20),Object(b.b)("googlesitekit.WPDashboardHeader","googlesitekit.Analytics",j),Object(b.b)("googlesitekit.WPDashboardModule","googlesitekit.Analytics",D),Object(b.b)("googlesitekit.ModuleApp-"+_,"googlesitekit.Analytics",O),Object(b.b)("googlesitekit.AnalyticsAdSenseTopPagesTable","googlesitekit.Analytics",A,11),Object(b.b)("googlesitekit.ModuleSettingsDetails-".concat(_),"googlesitekit.AnalyticsModuleSettingsDetails",Object(n.f)(h.a,{onSettingsPage:!0})),Object(b.b)("googlesitekit.showDateRangeSelector-".concat(_),"googlesitekit.analyticsShowDateRangeSelector",(function(){return!0})),Object(b.b)("googlesitekit.ModuleSetup-".concat(_),"googlesitekit.AnalyticsModuleSetupWizard",Object(n.f)(h.a,{onSettingsPage:!1}))}}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var t=a(3),n=a(146),i=a(12),o=a(0),s="optimize";e.googlesitekit.modules.optimize.active&&(Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat(s),"googlesitekit.OptimizeModuleSettingsDetails",Object(t.f)(n.a,{onSettingsPage:!0})),Object(i.b)("googlesitekit.ModuleSetup-".concat(s),"googlesitekit.OptimizeModuleSetupWizard",Object(t.f)(n.a,{onSettingsPage:!1})),Object(i.b)("googlesitekit.SetupWinNotification-".concat(s),"googlesitekit.OptimizeSetupWinNotification",(function(e){return e.description=Object(o.__)("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})))}).call(this,a(15))},function(e,t,a){"use strict";(function(e,t){var n=a(23),i=a(12),o=a(225),s=a(227),r=a(228),l=a(229),c="pagespeed-insights",d=e.googlesitekit.modules[c],g=d.active,u=d.setupComplete;if(g&&u){var m=Object(n.a)(t.createElement(o.a,null)),p=Object(n.a)(t.createElement(s.a,null));Object(i.b)("googlesitekit.DashboardModule","googlesitekit.PageSpeedInsights",m,45),Object(i.b)("googlesitekit.DashboardDetailsModule","googlesitekit.PageSpeedInsights",m,45),Object(i.b)("googlesitekit.DashboardSpeed","googlesitekit.PageSpeedInsightsHomepageSpeed",p)}else{var h=Object(n.a)(t.createElement(r.a,null));Object(i.b)("googlesitekit.DashboardModule","googlesitekit.PageSpeedInsights",h,45)}Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat(c),"googlesitekit.PageSpeedInsightsModuleSettingsDetails",Object(n.a)(t.createElement(l.a,null)),10)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var t=a(230),n=a(233),i=a(235),o=a(237),s=a(238),r=a(239),l=a(240),c=a(241),d=a(242),g=a(244),u=a(246),m=a(23),p=a(3),h=a(12),b="search-console",_=Object(m.a)(e.createElement(t.a,null)),f=Object(m.a)(e.createElement(n.a,null)),k=Object(m.a)(e.createElement(i.a,null)),y=Object(m.a)(e.createElement(o.a,null)),v=Object(m.a)(e.createElement(s.a,null)),S=Object(m.a)(e.createElement(c.a,null)),O=Object(m.a)(e.createElement(r.a,null)),E=Object(m.a)(e.createElement(l.a,null)),j=Object(m.a)(e.createElement(d.a,null)),D=Object(m.a)(e.createElement(g.a,null));Object(h.b)("googlesitekit.ModuleSettingsDetails-".concat(b),"googlesitekit.SearchConsoleModuleSettingsDetails",Object(p.f)(u.a,{onSettingsPage:!0})),Object(h.b)("googlesitekit.DashboardModule","googlesitekit.SearchConsole",y,11),Object(h.b)("googlesitekit.DashboardModule","googlesitekit.DashboardPopularityModule",j,40),Object(h.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.SearchConsoleSearchFunnel",v),Object(h.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",S),Object(h.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",O,40),Object(h.b)("googlesitekit.DashboardPopularity","googlesitekit.SearchConsoleDashboardPopularity",E),Object(h.b)("googlesitekit.DashboardPopularity","googlesitekit.DashboardPPostSearcherModule",D,30),Object(h.b)("googlesitekit.WPDashboardHeader","googlesitekit.SearchConsole",k,11),Object(h.b)("googlesitekit.ModuleApp-"+b,"googlesitekit.ModuleApp",_),Object(h.b)("googlesitekit.showDateRangeSelector-".concat(b),"googlesitekit.searchConsoleShowDateRangeSelector",(function(){return!0})),Object(h.b)("googlesitekit.AdminbarModules","googlesitekit.SearchConsole",f)}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){var t=a(3),n=a(148),i=a(12);e.googlesitekit.modules.tagmanager.active&&(Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat("tagmanager"),"googlesitekit.TagmanagerModuleSettingsDetails",Object(t.f)(n.a,{onSettingsPage:!0})),Object(i.b)("googlesitekit.ModuleSetup-".concat("tagmanager"),"googlesitekit.TagmanagerModuleSetupWizard",Object(t.f)(n.a,{onSettingsPage:!1})))}).call(this,a(15))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,a){"use strict";a.r(t),function(e,n){a.d(t,"GoogleSitekitAdminbar",(function(){return E})),a.d(t,"init",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),g=a.n(d),u=a(16),m=a.n(u),p=a(9),h=a.n(p),b=a(19),_=a(3),f=(a(255),a(12)),k=a(1),y=a(80),v=a(0),S=a(367),O=a(110),E=function(t){function GoogleSitekitAdminbar(e){var t;return o()(this,GoogleSitekitAdminbar),(t=c()(this,g()(GoogleSitekitAdminbar).call(this,e))).handleMoreDetailsLink=t.handleMoreDetailsLink.bind(m()(t)),t}return h()(GoogleSitekitAdminbar,t),r()(GoogleSitekitAdminbar,[{key:"handleMoreDetailsLink",value:function(){var t=e.googlesitekit,a=t.permaLink,n=t.postID,i=t.postType,o=t.pageTitle,s=Object(_.n)("googlesitekit-dashboard",{permaLink:a,id:n,postType:i,pageTitle:o});Object(_.A)("admin_bar","post_details_click"),document.location=s}},{key:"render",value:function(){var t=e.googlesitekit,a=t.pageTitle,i=t.permaLink;return n.createElement(O.a,null,n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-3 mdc-layout-grid__cell--align-middle "},n.createElement("div",{className:"googlesitekit-adminbar__subtitle"},Object(v.__)("Stats for","google-site-kit")),n.createElement("div",{className:"googlesitekit-adminbar__title"},a?Object(_.d)(a):i)),n.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 "},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(S.a,null))),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2 mdc-layout-grid__cell--align-middle "},n.createElement(b.a,{className:"googlesitekit-adminbar__link",href:"#",onClick:this.handleMoreDetailsLink},Object(v.__)("More details","google-site-kit"))))),n.createElement(b.a,{className:"googlesitekit-adminbar__link googlesitekit-adminbar__link--mobile",href:"#",onClick:this.handleMoreDetailsLink},Object(v.__)("More details","google-site-kit")))}}]),GoogleSitekitAdminbar}(k.Component);function j(){var e=document.getElementById("js-googlesitekit-adminbar-modules");e&&(Object(_.q)(),Object(y.render)(n.createElement(E,null),e),Object(f.d)("googlesitekit.moduleLoaded","Adminbar"))}}.call(this,a(15),a(1))},,,,,,,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),g=a(9),u=a.n(g),m=a(60),p=a(1),h=function(t){function AdminbarModules(){return i()(this,AdminbarModules),l()(this,d()(AdminbarModules).apply(this,arguments))}return u()(AdminbarModules,t),s()(AdminbarModules,[{key:"render",value:function(){return e.createElement(p.Fragment,null)}}]),AdminbarModules}(p.Component);t.a=Object(m.a)("googlesitekit.AdminbarModules")(h)}).call(this,a(1))}]]);
|
dist/assets/js/chunk-googlesitekit-adminbar-91cfda9281c30d7cec7f.js
DELETED
@@ -1,26 +0,0 @@
|
|
1 |
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[2],[,,,function(e,t,a){"use strict";(function(e){a.d(t,"u",(function(){return P})),a.d(t,"s",(function(){return T})),a.d(t,"p",(function(){return L})),a.d(t,"t",(function(){return I})),a.d(t,"i",(function(){return M})),a.d(t,"b",(function(){return W})),a.d(t,"e",(function(){return R})),a.d(t,"v",(function(){return U})),a.d(t,"m",(function(){return F})),a.d(t,"f",(function(){return z})),a.d(t,"n",(function(){return H})),a.d(t,"B",(function(){return G})),a.d(t,"C",(function(){return q})),a.d(t,"j",(function(){return B})),a.d(t,"a",(function(){return V})),a.d(t,"z",(function(){return J})),a.d(t,"x",(function(){return X})),a.d(t,"d",(function(){return Z})),a.d(t,"g",(function(){return $})),a.d(t,"h",(function(){return Q})),a.d(t,"r",(function(){return ee})),a.d(t,"y",(function(){return te})),a.d(t,"k",(function(){return ae}));var n=a(41),i=a.n(n),o=a(64),s=a.n(o),r=a(22),l=a.n(r),c=a(11),d=a.n(c),u=a(13),g=a(10),m=a(24),p=a(1),h=a.n(p),b=a(52),_=a(12),f=a(0),k=a(45),y=a(88),v=a(94),S=a(132),O=a(133),E=a(38),j=a(55);a.d(t,"A",(function(){return j.c}));var D=a(72);a.d(t,"w",(function(){return D.a}));var C=a(87);a.d(t,"c",(function(){return C.b})),a.d(t,"l",(function(){return C.c}));var w=a(118);a.d(t,"o",(function(){return w.a}));var A=a(119);function x(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function N(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?x(a,!0).forEach((function(t){l()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):x(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}a.d(t,"q",(function(){return A.a}));var P=function(e){var t,a=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t=Object(u.isUndefined)(e)?0:1e6<e?(e/=1e6).toFixed(1)+"M":1e3<e?99<(e/=1e3)?Math.round(e)+"K":e.toFixed(1)+"K":e,(Object(u.isNull)(e)||Object(u.isUndefined)(e)||isNaN(e))&&(t="",e=0),0===e)return t="0.00",a?new Intl.NumberFormat(navigator.language,{style:"currency",currency:a}).format(e):e;if(!1!==a&&""!==t){var n=new Intl.NumberFormat(navigator.language,{style:"currency",currency:a}).formatToParts(e),i=n.find((function(e){return"decimal"===e.type}));!Object(u.isUndefined)(i)&&!Object(u.isUndefined)(i.value)&&1e3>e&&(t=Number.isInteger(e)?e:e.replace(".",i.value));var o=n.find((function(e){return"currency"===e.type})),s=o?o.value:"";return"".concat(s).concat(t)}return t.toString()},T=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t||(t=navigator.language),t=t.replace("_","-").toLocaleLowerCase(),new Intl.NumberFormat(t).format(e)},L=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()},M=function(e,t){var a=1e3*L("day"),n=e.getTime(),i=t.getTime();return Math.round(Math.abs(n-i)/a)},W=function(e,t){if("0"===e||0===e||isNaN(e))return"";var a=((t-e)/e*100).toFixed(1);return isNaN(a)||"Infinity"===a?"":a},R=function(e,t){return Object(u.map)(e,(function(e,a){return[e[0],e[t]||(0===a?"":0)]}))},U=function(){var t,a;return d.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,d.a.awrap(g.c.get(g.a,"user","authentication"));case 3:t=n.sent,a=t.grantedScopes.filter((function(e){return-1!==t.requiredScopes.indexOf(e)})),e.googlesitekit.setup=e.googlesitekit.setup||{},e.googlesitekit.setup.isAuthenticated=t.isAuthenticated,e.googlesitekit.setup.requiredScopes=t.requiredScopes,e.googlesitekit.setup.grantedScopes=t.grantedScopes,e.googlesitekit.setup.needReauthenticate=a.length<t.requiredScopes.length,n.next=14;break;case 12:n.prev=12,n.t0=n.catch(0);case 14:case"end":return n.stop()}}),null,null,[[0,12]])},F=function(t,a){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.googlesitekit,i=n.admin,o=i.connectURL,s=i.adminRoot,r=n.setup.needReauthenticate,l=n.modules[t].screenID,c="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},d=Object(k.a)(s,N({page:t&&a&&l?l:"googlesitekit-dashboard",slug:t,reAuth:a},c));if(!r)return d;var u=encodeURIComponent(Object(y.a)(d));return d=s+"?"+u,Object(k.a)(o,{redirect:d,status:a})},z=function(e,t){return function(a){return function InnerComponent(n){return h.a.createElement(e,s()({},n,t,{OriginalComponent:a}))}}},H=function(t,a){var n=e.googlesitekit.admin.adminRoot;return t||(t="googlesitekit-dashboard"),a=N({page:t},a),Object(k.a)(n,a)},G=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},q=function(e){return e.match(/^GTM-[a-zA-Z\d]{7}$/)},B=function(t){var a,n,i,o,s;return d.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return a=e.googlesitekit.admin,n=a.homeURL,i=a.ampMode,o={tagverify:1,timestamp:Date.now()},r.next=4,d.a.awrap(K(Object(k.a)(n,o),t));case 4:if((s=r.sent)||"secondary"!==i){r.next=9;break}return r.next=8,d.a.awrap(Object(b.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return d.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.next=2,d.a.awrap(K(Object(k.a)(e.link,N({},o,{amp:1})),t));case 2:return a.abrupt("return",a.sent);case 3:case"end":return a.stop()}}))})).pop()})));case 8:s=r.sent;case 9:return r.abrupt("return",Promise.resolve(s||null));case 10:case"end":return r.stop()}}))},K=function(e,t){var a;return d.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.prev=0,n.next=3,d.a.awrap(fetch(e,{credentials:"omit"}).then((function(e){return e.text()})));case 3:return a=n.sent,n.abrupt("return",Y(a,t)||null);case 7:return n.prev=7,n.t0=n.catch(0),n.abrupt("return",null);case 10:case"end":return n.stop()}}),null,null,[[0,7]])},Y=function(e,t){var a=({adsense:S.a,analytics:O.a,tagmanager:E.d,setup:v.b}[t]||[]).find((function(t){return t.test(e)}));return!!a&&a.exec(e)[1]},V=function(t,a,n){return t.setModuleActive(a,n).then((function(t){return e.googlesitekit.modules&&e.googlesitekit.modules[a]&&(e.googlesitekit.modules[a].active=t.active),Object(j.c)("".concat(a,"_setup"),t.active?"module_activate":"module_deactivate",a),new Promise((function(e){e(t)}))}))},J=function(t,a,n){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:e.googlesitekit,s=o.modules[t],r=s.settings,l=s.setupComplete,c=i||document.getElementById("confirm-changes-".concat(t));if(l&&c){var d=!!Object.keys(a).find((function(e){var t=a[e];return!Object(u.isEqual)(n[e],r[t])}));return i||(c.disabled=!d),d}},X=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(_.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",z(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(u.unescape)(t)};function $(){var e=Object(_.c)("googlesitekit.dateRange","last-28-days").match(/last-(\d+)-days/);if(e&&e[1])return Object(f.sprintf)(Object(f._n)("%s day","%s days",parseInt(e[1],10),"google-site-kit"),e[1]);throw new Error("Unrecognized date range slug used in `googlesitekit.dateRange`.")}function Q(){return Object(_.c)("googlesitekit.dateRange","last-28-days")}function ee(t,a){var n=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.googlesitekit){var s=h.a.createElement(m.a,{id:t,width:n,height:i,className:o});return a?s=h.a.createElement(m.a,{id:"".concat(t,"-disabled"),width:n,height:i,className:o}):"pagespeed-insights"===t&&(s=h.a.createElement("img",{src:e.googlesitekit.admin.assetsRoot+"images/icon-pagespeed.png",width:n,alt:"",className:o})),s}}function te(e){var t={};return Object.keys(e).sort().forEach((function(a){var n=e[a];n&&"object"===i()(n)&&!Array.isArray(n)&&(n=te(n)),t[a]=n})),t}function ae(t){var a=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,n=a.blogPrefix;return a.isNetworkMode?t:n+t}}).call(this,a(15))},,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return f})),a.d(t,"b",(function(){return k}));var n=a(22),i=a.n(n),o=a(41),s=a.n(o),r=a(80),l=a(130),c=a(95),d=a.n(c),u=a(3),g=a(13),m=a(52),p=a(45),h=a(12);function b(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function _(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?b(a,!0).forEach((function(t){i()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):b(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var f="core",k="modules",y=function(){e.googlesitekit.admin=e.googlesitekit.admin||{},"string"==typeof e.googlesitekit.admin.datacache&&(e.googlesitekit.admin.datacache=JSON.parse(e.googlesitekit.admin.datacache)),"object"!==s()(e.googlesitekit.admin.datacache)&&(e.googlesitekit.admin.datacache={})},v=function(e,t){var a=_({data:{}},e);return a.data=_({dateRange:t},a.data),a},S={maxRequests:10,init:function(){Object(h.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingData",this.collectModuleData.bind(this))},combinedGetFromCache:function(e){var t=this;return new Promise((function(a,n){try{var i=[],o=Object(u.h)();Object(g.each)(e,(function(e){var a=v(e,o);a.key=t.getCacheKey(a.type,a.identifier,a.datapoint,a.data);var n=t.getCache(a.key,a.maxAge);void 0!==n&&(i[a.key]=n,t.resolve(a,n))})),a(i)}catch(e){n()}}))},combinedGet:function(e){var t=this,a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=[],i=25,o=Object(u.h)();Object(g.each)(e,(function(e){var a=v(e,o);a.key=t.getCacheKey(a.type,a.identifier,a.datapoint,a.data);var s=t.getCache(a.key,a.maxAge);void 0!==s?(setTimeout((function(){t.resolve(a,s)}),i),i+=25):n.push(a)})),n=Object(g.sortBy)(n,"priority");var s=[],r=[],l={},c=!!n.find((function(e){return e.priority<10}));Object(g.each)(n,(function(e,t){!a&&10<=e.priority&&c?r.push(e):l[e.key]?l[e.key].push(t):(l[e.key]=[t],s.push(e))}));var d=10,b=s.slice(0,d),_=s.slice(d);if(_=_.concat(r),0!==b.length||0!==_.length){0<_.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(_,!0)}),50):this.maxRequests=10;var f=null!==Object(u.l)("datacache");return Object(m.default)({path:Object(p.a)("/google-site-kit/v1/data/",{datacache:f||void 0}),data:{request:b},method:"POST"}).then((function(e){Object(g.each)(e,(function(e,a){l[a]?(t.handleWPError(e),Object(g.each)(l[a],(function(a){var i=n[a];t.setCache(i.key,e),t.resolve(i,e)})),0===_.length&&Object(h.d)("googlesitekit.dataLoaded","api")):console.error("data_error","unknown response key "+a)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(h.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){var t=["code","data","message"],a=Object(g.intersection)(t,Object.keys(e));if(Object(g.isEqual)(t,a)){console.warn("WP Error in data response",e);var n=e.data;if(n&&n.reason){var i=0;["authError","insufficientPermissions"].includes(n.reason)&&(Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.f)(r.a),1),i++),"forbidden"===n.reason&&(Object(h.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(u.f)(l.a),1),i++),i&&Object(h.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(h.f)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+i}))}}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},setCache:function(t,a){if(void 0!==a&&(!a||"object"!==s()(a)||!a.error&&!a.errors)){y(),e.googlesitekit.admin.datacache[t]=Object(g.cloneDeep)(a);var n={value:a,date:Date.now()/1e3};Object(u.o)().setItem("googlesitekit_"+t,JSON.stringify(n))}},getCache:function(t,a){if(!e.googlesitekit.admin.nojscache){if(y(),void 0!==e.googlesitekit.admin.datacache[t])return e.googlesitekit.admin.datacache[t];var n=JSON.parse(Object(u.o)().getItem("googlesitekit_"+t));return n&&"object"===s()(n)&&n.date&&(!a||Date.now()/1e3-n.date<a)?(e.googlesitekit.admin.datacache[t]=Object(g.cloneDeep)(n.value),Object(g.cloneDeep)(e.googlesitekit.admin.datacache[t])):void 0}},deleteCache:function(t){y(),delete e.googlesitekit.admin.datacache[t],Object(u.o)().removeItem("googlesitekit_"+t)},invalidateCacheGroup:function(t,a,n){var i=this.getCacheKey(t,a,n);y(),Object.keys(e.googlesitekit.admin.datacache).forEach((function(t){0!==t.indexOf(i+"::")&&t!==i||delete e.googlesitekit.admin.datacache[t]})),Object.keys(Object(u.o)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(i,"::"))&&e!=="googlesitekit_".concat(i)||Object(u.o)().removeItem(e)}))},collectModuleData:function(e,t){var a=Object(h.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==a.length&&this.combinedGet(a)},get:function(e,t,a){var n=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],s=this.getCacheKey(e,t,a,i);if(!o){var r=this.getCache(s,3600);if(void 0!==r)return new Promise((function(e){e(r)}))}return Object(m.default)({path:Object(p.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(a),i)}).then((function(e){return o||n.setCache(s,e),Promise.resolve(e)})).catch((function(e){return n.handleWPError(e),Promise.reject(e)}))},set:function(e,t,a,n){var i={};return i.data=n,Object(m.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(a),data:i,method:"POST"}).then((function(n){return S.invalidateCacheGroup(e,t,a),new Promise((function(e){e(n)}))}))},getCacheKey:function(e,t,a){for(var n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,a],r=0,l=o;r<l.length;r++){var c=l[r];if(!c||!c.length)break;i.push(c)}return 3===i.length&&n&&"object"===s()(n)&&Object.keys(n).length&&i.push(d()(JSON.stringify(Object(u.y)(n)))),i.join("::")},setModuleActive:function(e,t){return this.set(f,"modules","activation",{slug:e,active:t})}};S.init(),t.c=S}).call(this,a(15))},,,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"e",(function(){return s})),a.d(t,"c",(function(){return l})),a.d(t,"d",(function(){return c})),a.d(t,"b",(function(){return d})),a.d(t,"f",(function(){return u})),a.d(t,"h",(function(){return g})),a.d(t,"a",(function(){return m})),a.d(t,"j",(function(){return p})),a.d(t,"i",(function(){return h})),a.d(t,"k",(function(){return b})),a.d(t,"g",(function(){return _}));var n=a(3),i=a(13),o=a(0),s=function(e){if(!e||!e.length)return null;var t=e[0].data,a=t.rows,n=t.totals[0].values[0],o=[["Source","Percent"]];return Object(i.each)(a,(function(e){var t=e.metrics[0].values[0]/n;if(1>100*t)return!1;var a=e.dimensions[0].replace(/\(none\)/gi,"direct");o.push([a,t])})),o};function r(e,t){var a=[];return Object(i.each)(e,(function(e){if(e.metrics){var n=e.metrics[0].values,i=e.dimensions[0],o=i.slice(0,4)+"-"+i.slice(4,6)+"-"+i.slice(6,8),s=new Date(o);a.push([s,n[t]])}})),a}var l=function(e,t,a){if(!e||!e.length)return null;var n=e[0].data.rows;if(!n)return!1;var s=n.length;if(2*a>s){for(var l=new Date,c=0;a>c;c++){var d=(l.getMonth()+1).toString(),u=l.getDate().toString(),g=l.getFullYear().toString()+(2>d.length?"0":"")+d+(2>u.length?"0":"")+u;if(c>s){var m={dimensions:[g],metrics:[{values:[0,0,0,0,0]}]};n.unshift(m)}l.setDate(l.getDate()-1)}n.push([0,0])}var p=[Object(o.__)("Users","google-site-kit"),Object(o.__)("Sessions","google-site-kit"),Object(o.__)("Bounce Rate","google-site-kit"),Object(o.__)("Session Duration","google-site-kit")],h=[[{type:"date",label:Object(o.__)("Day","google-site-kit")},{type:"number",label:p[t]},{type:"number",label:Object(o.__)("Previous month","google-site-kit")}]],b=n.slice(n.length-a,n.length),_=n.slice(0,n.length-a),f=r(b,t),k=r(_,t);return Object(i.each)(f,(function(e,t){e[0]&&e[1]&&k[t]&&h.push([e[0],e[1],k[t][1]])})),h},c=function(e){if(!e||!e.length)return null;var t=e[0].data.rows,a=[[{type:"date",label:"Day"},{type:"number",label:"Users"},{type:"number",label:"Sessions"},{type:"number",label:"Goals Completed"}]];return Object(i.each)(t,(function(e){var t=e.metrics[0].values,n=e.dimensions[0],i=n.slice(0,4)+"-"+n.slice(4,6)+"-"+n.slice(6,8),o=new Date(i);a.push([o,t[0],t[1],t[4]])})),a},d=function(e){if(!e||!e.length)return!1;var t=e[0].data.totals,a=t[0].values,i=t[1].values,o=a[0],s=a[1],r=a[2],l=a[3],c=a[4],d=a[5];return{totalUsers:o,totalSessions:s,averageBounceRate:r,averageSessionDuration:l,totalUsersChange:Object(n.b)(i[0],a[0]),totalSessionsChange:Object(n.b)(i[1],a[1]),averageBounceRateChange:Object(n.b)(i[2],a[2]),averageSessionDurationChange:Object(n.b)(i[3],a[3]),goalCompletions:c,goalCompletionsChange:Object(n.b)(i[4],a[4]),totalPageViews:d,totalPageViewsChange:Object(n.b)(i[5],a[5])}},u=function(e){return!(!e.error||!e.error.status)&&function(e,t){var a="";switch(e){case"INVALID_ARGUMENT":a=Object(o.__)("Analytics module needs to be configured.","google-site-kit");break;case"UNAUTHENTICATED":a=Object(o.__)("You need to be authenticated to get this data.","google-site-kit");break;case"PERMISSION_DENIED":a=Object(o.__)("Your account does not have sufficient permission to access this data, please consult to your web administrator.","google-site-kit");break;case"RESOURCE_EXHAUSTED":a=Object(o.__)("Your account exceeded the maximum quota. Please try again later.","google-site-kit");break;case"INTERNAL":a=Object(o.__)("Unexpected internal server error occurred.","google-site-kit");break;case"BACKEND_ERROR":a=Object(o.__)("Analytics server returned unknown error. Please try again later.","google-site-kit");break;case"UNAVAILABLE":a=Object(o.__)("The service was unable to process the request. Please try again later.","google-site-kit");break;default:a=t}return a}(e.error.status,e.error.message)},g=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,a=!0;return Object(i.each)(t,(function(e){0!==parseInt(e)&&(a=!1)})),a}return!1},m={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},p={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},h={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},b={dimensions:"ga:medium",metrics:[{expression:"ga:sessions",alias:"Sessions"},{expression:"ga:users",alias:"Users"},{expression:"ga:newUsers",alias:"New Users"}],orderby:[{fieldName:"ga:sessions",sortOrder:"DESCENDING"}],limit:10},_=function(){var t=[{expression:"ga:pageviews",alias:"Pageviews"},{expression:"ga:uniquePageviews",alias:"Unique Pageviews"},{expression:"ga:bounceRate",alias:"Bounce rate"}];return e.googlesitekit.modules.analytics.settings.adsenseLinked&&t.push({expression:"ga:adsenseRevenue",alias:"AdSense Revenue"},{expression:"ga:adsenseECPM",alias:"AdSense ECPM"}),{dimensions:["ga:pageTitle","ga:pagePath"].join(","),metrics:t,orderby:[{fieldName:"ga:pageviews",sortOrder:"DESCENDING"}],limit:10}}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function Link(){return i()(this,Link),l()(this,d()(Link).apply(this,arguments))}return g()(Link,t),s()(Link,[{key:"render",value:function(){var t=this.props,a=t.dangerouslySetInnerHTML,n=t.onClick,i=t.href,o=t.children,s=t.className,r=t.arrow,l=t.external,c=t.inverse,d=t.back,u=t.small,g=t.inherit,m=t.caps,p=t.danger,h=t.disabled,_=t.id,f=i&&!h,k=f?"a":"button";return e.createElement(k,{className:b()("googlesitekit-cta-link",s,{"googlesitekit-cta-link--arrow":r,"googlesitekit-cta-link--external":l,"googlesitekit-cta-link--inverse":c,"googlesitekit-cta-link--back":d,"googlesitekit-cta-link--small":u,"googlesitekit-cta-link--inherit":g,"googlesitekit-cta-link--caps":m,"googlesitekit-cta-link--danger":p,"googlesitekit-cta-link--disabled":h}),onClick:n,id:_,href:f?i:void 0,target:f&&l?"_blank":void 0,rel:l?"noopener noreferrer":void 0,disabled:h,dangerouslySetInnerHTML:a},o)}}]),Link}(_.Component);f.propTypes={dangerouslySetInnerHTML:p.a.shape({__html:p.a.string}),onClick:p.a.func,href:p.a.string,children:p.a.oneOfType([p.a.string.isRequired,p.a.array.isRequired]),className:p.a.string,arrow:p.a.bool,external:p.a.bool,inverse:p.a.bool,back:p.a.bool,small:p.a.bool,inherit:p.a.bool,caps:p.a.bool,danger:p.a.bool,disabled:p.a.bool},f.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=f}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(64),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(13),_=a(56),f=a(47),k=a(97),y=a(12),v=a(1),S=a(0);t.a=function(t,a){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,s=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{inGrid:!1,fullWidth:!1,createGrid:!1},l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:function(){return!1},d=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(S.__)("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(S.__)("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 a=Object.values(e.errors);if(a[0]&&a[0][0])return a[0][0]}return!1};return function(g){function NewComponent(e){var t;r()(this,NewComponent),(t=u()(this,m()(NewComponent).call(this,e))).state={data:!1,zeroData:!1,error:!1},Object(y.a)("googlesitekit.moduleDataReset","googlesitekit.moduleDataResetHandler",(function(){t.setState({data:!1})}));var n=function(e,a){var n=t.props,i=n.handleDataError,o=n.handleDataSuccess,s=a.datapoint,r=a.identifier,c=a.toState,u=d(e);u?(t.setState({error:u,module:r}),i&&i(u)):l(e,s,a)?(i&&i(u),t.setState({zeroData:!0})):o&&o(),t.setState({requestDataToState:c,data:e,datapoint:s,module:r})};return Object(b.each)(a,(function(e){Array.isArray(e.context)?Object(b.each)(e.context,(function(t){Object(y.b)("googlesitekit.module".concat(t,"DataRequest"),"googlesitekit.data".concat(t),(function(t){return e.callback=function(t){n(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){n(t,e)},t.push(e),t}))})),t}return h()(NewComponent,g),c()(NewComponent,[{key:"render",value:function(){var a=this.state,r=a.data,l=a.datapoint,c=a.module,d=a.zeroData,u=a.error,g=a.requestDataToState;if(!r)return i;var m=c?e.googlesitekit.modules[c].name:Object(S.__)("Site Kit","google-site-kit");return c&&e.googlesitekit.modules[c].active&&!e.googlesitekit.modules[c].setupComplete?Object(k.a)(c,s.inGrid,s.fullWidth,s.createGrid):u?"string"!=typeof u?u:Object(f.a)(m,u,s.inGrid,s.fullWidth,s.createGrid):d?Object(_.a)(m,s.inGrid,s.fullWidth,s.createGrid):n.createElement(t,o()({data:r,datapoint:l,requestDataToState:g},this.props))}}]),NewComponent}(v.Component)}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";a.d(t,"a",(function(){return i}));var n=a(1),i=function(e){return function(t){return function FilteredComponent(a){return Object(n.createElement)(n.Fragment,{},"",Object(n.createElement)(t,a),e)}}}},function(e,t,a){"use strict";(function(e,n){var i=a(2),o=a.n(i),s=a(14),r=a.n(s),l=function SvgIcon(t){var a=t.id,i=t.className,o=t.height,s=t.width,l="".concat(e.googlesitekit.admin.assetsRoot,"svg/svg.svg");return n.createElement("svg",{className:r()("svg",i),height:o,width:s},n.createElement("use",{xlinkHref:"".concat(l,"#").concat(a)}))};l.propTypes={id:o.a.string.isRequired,className:o.a.string,height:o.a.string,width:o.a.string},l.defaultProps={className:"",height:20,width:20},t.a=l}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(70),i=a.n(n);a.d(t,"l",(function(){return i.a})),a.d(t,"a",(function(){return n.HelperText})),a.d(t,"b",(function(){return n.Input}));var o=a(117);a.d(t,"h",(function(){return o.a}));var s=a(123);a.d(t,"e",(function(){return s.a}));var r=a(125);a.d(t,"g",(function(){return r.a}));var l=a(86),c=a.n(l);a.d(t,"k",(function(){return c.a})),a.d(t,"j",(function(){return l.Option}));var d=a(124);a.d(t,"i",(function(){return d.a}));var u=a(122);a.d(t,"d",(function(){return u.a}));var g=a(121);a.d(t,"c",(function(){return g.a}));var m=a(120);a.d(t,"f",(function(){return m.a}))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(16),g=a.n(u),m=a(9),p=a.n(m),h=a(2),b=a.n(h),_=a(58),f=a(14),k=a.n(f),y=a(1),v=a(126),S=function(t){function DataBlock(e){var t;return i()(this,DataBlock),(t=l()(this,d()(DataBlock).call(this,e))).handleClick=t.handleClick.bind(g()(t)),t.handleKeyPress=t.handleKeyPress.bind(g()(t)),t}return p()(DataBlock,t),s()(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,a=t.stat,n=t.handleStatSelection;"Enter"!==e.key&&" "!==e.key||n(a)}},{key:"render",value:function(){var t=this.props,a=t.className,n=t.title,i=t.datapoint,o=t.datapointUnit,s=t.change,r=t.changeDataUnit,l=t.context,c=t.period,d=t.selected,u=t.handleStatSelection,g=t.source,m=t.sparkline,p=t.invertChangeColor,h="button"===l?"button":"",b=m;return b&&p&&(b=Object(y.cloneElement)(m,{invertChangeColor:p})),e.createElement("div",{className:k()("googlesitekit-data-block",a,"googlesitekit-data-block--".concat(l),{"googlesitekit-data-block--selected":d}),tabIndex:"button"===l?"0":"-1",role:u&&h,onClick:u&&this.handleClick,onKeyPress:u&&this.handleKeyPress,"aria-label":u&&n,"aria-pressed":u&&d},e.createElement("div",{className:"googlesitekit-data-block__title-datapoint-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 googlesitekit-data-block__title "},n),e.createElement("div",{className:"googlesitekit-data-block__datapoint"},"".concat(i).concat(o))),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"},""===s&&e.createElement(y.Fragment,null," "),s&&e.createElement(y.Fragment,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(v.a,{direction:0<parseFloat(s)?"up":"down",invertColor:p})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Math.abs(s)).concat(r," ").concat(c)))),g&&e.createElement(_.a,{className:"googlesitekit-data-block__source",name:g.name,href:g.link})))}}]),DataBlock}(y.Component);S.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},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,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function PreviewBlock(){return i()(this,PreviewBlock),l()(this,d()(PreviewBlock).apply(this,arguments))}return g()(PreviewBlock,t),s()(PreviewBlock,[{key:"render",value:function(){var t=this.props,a=t.width,n=t.height,i=t.shape,o=t.padding;return e.createElement("div",{className:b()("googlesitekit-preview-block",{"googlesitekit-preview-block--padding":o}),style:{width:a,height:n}},e.createElement("div",{className:b()("googlesitekit-preview-block__wrapper",{"googlesitekit-preview-block__wrapper--circle":"circular"===i})}))}}]),PreviewBlock}(_.Component);f.propTypes={width:p.a.string,height:p.a.string,shape:p.a.string,padding:p.a.bool},f.defaultProps={width:"100px",height:"100px",shape:"square",padding:!1},t.a=f}).call(this,a(1))},,function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return E})),a.d(t,"a",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(2),_=a.n(b),f=a(58),k=a(19),y=a(14),v=a.n(y),S=a(13),O=a(1),E=function(t,a,n){var i=[],o=n.links,s=n.source,r=n.showURLs;n.cap&&(t=t.slice(0,n.cap)),Object(S.each)(t,(function(t,a){var n=[],s=o&&o[a];Object(S.each)(t,(function(a,i){"string"==typeof a&&(a=a.replace(/\(none\)/gi,"direct")),n.push(e.createElement("td",{key:"cell-"+i,className:"googlesitekit-table__body-item"},t[0]===a&&s?e.createElement("div",{className:"googlesitekit-table__body-item-content"},e.createElement(k.a,{className:"googlesitekit-table__body-item-link",href:s,external:!0,inherit:!0},a),r&&""!==Object(S.trim)(s,"/")&&e.createElement(k.a,{className:"googlesitekit-table__body-item-url",href:s,inherit:!0,external:!0},Object(S.trim)(s,"/"))):e.createElement("div",{className:"googlesitekit-table__body-item-content"},a)))})),i.push(e.createElement("tr",{key:"tr-"+a,className:"googlesitekit-table__body-row"},n))}));var l=t&&t[0]&&t[0].length?t[0].length:1;return e.createElement("div",{className:v()("googlesitekit-table",{"googlesitekit-table--with-list":!n||!n.disableListMode})},e.createElement("table",{className:v()("googlesitekit-table__wrapper","googlesitekit-table__wrapper--".concat(l,"-col"))},e.createElement("thead",{className:"googlesitekit-table__head"},e.createElement("tr",{key:"gksc_data_row_header-wrap",style:n&&n.hideHeader?{display:"none"}:{},className:"googlesitekit-table__head-row"},a.map((function(t,a){return e.createElement("th",{key:"gksc_data_row_header-".concat(a),className:v()("googlesitekit-table__head-item",{"googlesitekit-table__head-item--primary":t.primary}),"data-tooltip":t.tooltip},t.title)})))),e.createElement("tbody",{className:"googlesitekit-table__body"},i)),s&&e.createElement(f.a,{className:"googlesitekit-table__source",name:s.name,href:s.link}))},j=function(t){function TableOverflowContainer(){var e;return o()(this,TableOverflowContainer),(e=c()(this,u()(TableOverflowContainer).call(this))).state={isScrolling:!1},e.scrollRef=Object(O.createRef)(),e.updateFadeOnScroll=e.updateFadeOnScroll.bind(m()(e)),e}return h()(TableOverflowContainer,t),r()(TableOverflowContainer,[{key:"componentDidMount",value:function(){var e=this;e.updateFadeOnScroll(),this.resize=Object(S.debounce)((function(){e.updateFadeOnScroll()}),100),n.addEventListener("resize",this.resize)}},{key:"componentWillUnmount",value:function(){n.removeEventListener("resize",this.resize)}},{key:"updateFadeOnScroll",value:function(){var e=this.scrollRef.current,t=e.scrollLeft,a=e.scrollWidth-e.offsetWidth,n=t<a-16&&0<a-16;this.setState({isScrolling:n})}},{key:"render",value:function(){var t=this.props.children,a=this.state.isScrolling;return e.createElement("div",{onScroll:Object(S.debounce)(this.updateFadeOnScroll,100),className:v()("googlesitekit-table-overflow",{"googlesitekit-table-overflow--gradient":a})},e.createElement("div",{ref:this.scrollRef,className:"googlesitekit-table-overflow__container"},t))}}]),TableOverflowContainer}(O.Component);j.propTypes={children:_.a.element}}).call(this,a(1),a(15))},,function(e,t,a){"use strict";(function(e){var n=a(22),i=a.n(n),o=a(11),s=a.n(o),r=a(5),l=a.n(r),c=a(6),d=a.n(c),u=a(7),g=a.n(u),m=a(8),p=a.n(m),h=a(16),b=a.n(h),_=a(9),f=a.n(_),k=a(2),y=a.n(k),v=a(10),S=a(26),O=a(33),E=a(73),j=a(84),D=a(19),C=a(24),w=a(14),A=a.n(w),x=a(13),N=a(1),P=a(72),T=function(t){function Notification(e){var t;return l()(this,Notification),(t=g()(this,p()(Notification).call(this,e))).state={isClosed:!1},t.cardRef=Object(N.createRef)(),t.handleDismiss=t.handleDismiss.bind(b()(t)),t.handleCTAClick=t.handleCTAClick.bind(b()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&v.c.setCache("notification::displayed::".concat(t.props.id),new Date),t}return f()(Notification,t),d()(Notification,[{key:"handleDismiss",value:function(e){var t;return s.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(e.persist(),e.preventDefault(),!(t=this.props.onDismiss)){a.next=6;break}return a.next=6,s.a.awrap(t(e));case 6:this.dismiss();case 7:case"end":return a.stop()}}),null,this)}},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){v.c.setCache("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var a=new Event("notificationDismissed");document.dispatchEvent(a)}),350)}},{key:"handleCTAClick",value:function(e){var t,a,n;return s.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e.persist(),t=this.props,a=t.isDismissable,!(n=t.onCTAClick)){i.next=5;break}return i.next=5,s.a.awrap(n(e));case 5:a&&this.dismiss();case 6:case"end":return i.stop()}}),null,this)}},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,a=e.dismissExpires,n=v.c.getCache("notification::dismissed::".concat(t));if(n){var i=new Date(n);i.setSeconds(i.getSeconds()+parseInt(a,10)),i<new Date&&v.c.deleteCache("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,a=this.state.isClosed,n=this.props,o=n.children,s=n.id,r=n.title,l=n.description,c=n.blockData,d=n.winImage,u=n.smallImage,g=n.format,m=n.learnMoreURL,p=n.learnMoreDescription,h=n.learnMoreLabel,b=n.ctaLink,_=n.ctaLabel,f=n.ctaTarget,k=n.type,y=n.dismiss,w=n.isDismissable,T=n.logo,L=n.module,I=n.moduleName,M=n.pageIndex;if(v.c.getCache("notification::dismissed::".concat(s)))return null;var W,R=a?"is-closed":"is-open",U="large"===g&&"win-stats-increase"===k,F="mdc-layout-grid__cell--span-12";"large"===g?(F="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 ",U&&(F="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&&(F="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),W="win-warning"===k?e.createElement(E.a,null):"win-error"===k?e.createElement(j.a,null):"";var z=e.createElement(N.Fragment,null,c&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(x.map)(c,(function(t,a){return e.createElement("div",{key:a,className:A()("mdc-layout-grid__cell",{"mdc-layout-grid__cell--span-5-desktop":U,"mdc-layout-grid__cell--span-4-desktop":!U})},e.createElement("div",{className:"googlesitekit-publisher-win__stats"},e.createElement(S.a,t)))})))),H=e.createElement(N.Fragment,null,r&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},r),l&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(N.isValidElement)(l)?l:e.createElement("span",{dangerouslySetInnerHTML:Object(P.a)(l,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),h&&e.createElement(N.Fragment,null," ",e.createElement(D.a,{href:m,external:!0,inherit:!0},h),p),M&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},M))),o),G=L?e.createElement(C.a,{id:L,height:"19",width:"19"}):e.createElement(C.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:A()("googlesitekit-publisher-win",(t={},i()(t,"googlesitekit-publisher-win--".concat(g),g),i()(t,"googlesitekit-publisher-win--".concat(k),k),i()(t,"googlesitekit-publisher-win--".concat(R),R),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},T&&e.createElement("div",{className:A()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",{"mdc-layout-grid__cell--order-2-phone":U,"mdc-layout-grid__cell--order-1-tablet":U})},e.createElement("div",{className:"googlesitekit-publisher-win__logo"},G),I&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},I)),u&&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:u})),e.createElement("div",{className:A()("mdc-layout-grid__cell",F)},U?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"},H),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"},z)):e.createElement(N.Fragment,null,H,z),b&&e.createElement(O.a,{href:b,target:f,onClick:this.handleCTAClick},_),w&&y&&e.createElement(D.a,{onClick:this.handleDismiss},y)),d&&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:d}))),("win-error"===k||"win-warning"===k)&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-1 "},e.createElement("div",{className:"googlesitekit-publisher-win__icons"},W)))))}}]),Notification}(N.Component);T.propTypes={id:y.a.string.isRequired,title:y.a.string.isRequired,description:y.a.node,learnMoreURL:y.a.string,learnMoreDescription:y.a.string,learnMoreLabel:y.a.string,blockData:y.a.array,winImage:y.a.string,smallImage:y.a.string,format:y.a.string,ctaLink:y.a.string,ctaLabel:y.a.string,type:y.a.string,dismiss:y.a.string,isDismissable:y.a.bool,logo:y.a.bool,module:y.a.string,moduleName:y.a.string,pageIndex:y.a.string,dismissExpires:y.a.number,showOnce:y.a.bool,onCTAClick:y.a.func,onDismiss:y.a.func},T.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=T}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(14),b=a.n(h),_=a(1),f=function(t){function ProgressBar(){return i()(this,ProgressBar),l()(this,d()(ProgressBar).apply(this,arguments))}return g()(ProgressBar,t),s()(ProgressBar,[{key:"render",value:function(){var t=this.props,a=t.className,n=t.small,i=t.compress,o=t.height,s=o?Math.round(o/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:s,marginBottom:s},className:b()("mdc-linear-progress","mdc-linear-progress--indeterminate",a,{"mdc-linear-progress--small":n,"mdc-linear-progress--compress":i})},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}(_.Component);f.propTypes={className:p.a.string,small:p.a.bool,compress:p.a.bool},f.defaultProps={className:"",small:!1,compress:!1},t.a=f}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Button(e){var t;return i()(this,Button),(t=l()(this,d()(Button).call(this,e))).buttonRef=Object(f.createRef)(),t}return g()(Button,t),s()(Button,[{key:"componentDidMount",value:function(){new m.h(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,a=t.onClick,n=t.children,i=t.href,o=t.text,s=t.className,r=t.danger,l=t.disabled,c=t.target,d=t.id,u=t.icon,g=t.trailingIcon,m=t.ariaHaspopup,p=t.ariaExpanded,h=t.ariaControls,b=i&&!l?"a":"button";return e.createElement(b,{className:_()("mdc-button",s,{"mdc-button--raised":!o,"mdc-button--danger":r}),onClick:a,href:l?void 0:i,ref:this.buttonRef,disabled:!!l,target:c||"_self",id:d,"aria-haspopup":m,"aria-expanded":p,"aria-controls":h},u&&u,e.createElement("span",{className:"mdc-button__label"},n),g&&g)}}]),Button}(f.Component);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,a(1))},,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(19),b=a(14),_=a.n(b),f=a(1),k=function(t){function CTA(){return i()(this,CTA),l()(this,d()(CTA).apply(this,arguments))}return g()(CTA,t),s()(CTA,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.description,i=t.ctaLink,o=t.ctaLabel,s=t.error,r=t.onClick;return e.createElement("div",{className:_()("googlesitekit-cta",{"googlesitekit-cta--error":s})},a&&e.createElement("h3",{className:"googlesitekit-cta__title"},a),n&&e.createElement("p",{className:"googlesitekit-cta__description"},n),o&&e.createElement(h.a,{href:i,onClick:r,inverse:!s,caps:!0,arrow:!0},o))}}]),CTA}(f.Component);k.propTypes={title:p.a.string.isRequired,description:p.a.string,ctaLink:p.a.string,ctaLabel:p.a.string,error:p.a.bool,onClick:p.a.func},k.defaultProps={title:"",description:"",ctaLink:"",ctaLabel:"",error:!1,onClick:function(){}},t.a=k}).call(this,a(1))},function(e,t,a){"use strict";function n(e){return{byContext:function(t){return e.filter((function(e){return e.usageContext.includes(t)}))}}}function i(e){return(parseInt(e)||0)>0}function o(e){return!!e&&e.toString().match(/^GTM-[A-Z0-9]+$/)}var s=[/<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]+)['|"]/];a.d(t,"a",(function(){return n})),a.d(t,"b",(function(){return i})),a.d(t,"c",(function(){return o})),a.d(t,"d",(function(){return s}))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(27),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function PreviewTable(){return i()(this,PreviewTable),l()(this,d()(PreviewTable).apply(this,arguments))}return g()(PreviewTable,t),s()(PreviewTable,[{key:"render",value:function(){for(var t=this.props,a=t.rows,n=t.rowHeight,i=t.padding,o=[],s=0;a>s;s++)o.push(e.createElement("div",{className:"googlesitekit-preview-table__row",key:"table-row-"+s},e.createElement(m.a,{width:"100%",height:n+"px"})));return e.createElement("div",{className:_()("googlesitekit-preview-table",{"googlesitekit-preview-table--padding":i})},o)}}]),PreviewTable}(f.Component);k.propTypes={rows:h.a.number,rowHeight:h.a.number,padding:h.a.bool},k.defaultProps={rows:11,rowHeight:35,padding:!1},t.a=k}).call(this,a(1))},function(e,t,a){"use strict";a.d(t,"a",(function(){return s})),a.d(t,"b",(function(){return r}));var n=a(3),i=a(13);function o(e){var t=[[{type:"string",label:"Day"},{type:"number",label:"Clicks"},{type:"number",label:"Impressions"},{type:"number",label:"CTR"},{type:"number",label:"Position"}]],a=0,o=0,s=0,r=0,l=e.length;Object(i.each)(e,(function(e){var n=new Date(e.keys[0]);t.push([n.getMonth()+1+"/"+n.getUTCDate(),e.clicks,e.impressions,e.ctr,e.position]),a+=e.clicks,o+=e.impressions,s+=e.ctr,r+=e.position}));var c=a,d=o;a=Object(n.u)(a),o=Object(n.u)(o);var u=(s/l*100).toFixed(1),g=s/l,m=(r/l).toFixed(1);return{dataMap:t,totalClicks:a,totalClicksRaw:c,totalImpressions:o,totalImpressionsRaw:d,averageCTR:u,averageCTRRaw:g,averagePosition:m}}var s=function(e){var t=Math.floor(e.length/2),a=o(e.slice(t)),i=o(e.slice(0,t));return{dataMap:a.dataMap,totalClicks:a.totalClicks,totalImpressions:a.totalImpressions,averageCTR:a.averageCTR,averagePosition:a.averagePosition,totalClicksChange:Object(n.b)(i.totalClicksRaw,a.totalClicksRaw),totalImpressionsChange:Object(n.b)(i.totalImpressionsRaw,a.totalImpressionsRaw),averageCTRChange:Object(n.b)(i.averageCTRRaw,a.averageCTRRaw),averagePositionChange:Object(n.b)(i.averagePosition,a.averagePosition)}},r=function(e){if(!e.length)return!0;var t=s(e),a=t.totalClicks,n=t.totalImpressions,i=t.averageCTR,o=t.averagePosition;return 0===parseInt(a)&&0===parseInt(n)&&0===parseInt(i)&&0===parseInt(o)}},,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(1),b=function(t){function DashboardModuleHeader(){return i()(this,DashboardModuleHeader),l()(this,d()(DashboardModuleHeader).apply(this,arguments))}return g()(DashboardModuleHeader,t),s()(DashboardModuleHeader,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.description;return e.createElement("header",{className:"googlesitekit-dashboard-module-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},a&&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 "},a),n&&e.createElement("p",{className:"googlesitekit-dashboard-module-header__description"},n))))}}]),DashboardModuleHeader}(h.Component);b.propTypes={title:p.a.string,description:p.a.string},b.defaultProps={title:"",description:""},t.a=b}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"e",(function(){return u})),a.d(t,"d",(function(){return g})),a.d(t,"a",(function(){return m})),a.d(t,"b",(function(){return p})),a.d(t,"c",(function(){return h}));var n=a(11),i=a.n(n),o=a(197),s=a(10),r=a(3),l=a(13),c=a(0),d=a(18);function u(e){var t=[[{type:"date",label:"Day"},{type:"number",label:"RPM"},{type:"number",label:"Earnings"},{type:"number",label:"Impressions"}]];return Object(l.each)(e,(function(e){var a=new Date(e[0]);t.push([a,e[2],e[1],e[3]])})),{dataMap:t}}var g=function(t,a){var n,i,s,l,d,u,g,m,p,h,b,_,f,k=!1,y=!1,v=!1,S=!1,O=!1,E=!1,j=e.googlesitekit.modules.adsense,D=j.accountURL,C=j.signupURL,w=Object(r.n)("googlesitekit-module-adsense",{}),A=new URL(e.googlesitekit.admin.siteURL);switch(t){case"account-connected":a?(m=!1,g="alert",p=Object(c.__)("Site Kit will place AdSense code to your site","google-site-kit"),h=Object(c.__)("This means Google will automatically place ads for you in all the best places.","google-site-kit"),i=Object(c.__)("Continue","google-site-kit"),n=w,k=!0,b=Object(c.__)("Let Site Kit place code on your site","google-site-kit"),_=Object(c.__)("If you don’t let Site Kit place the code you may not get the best ads experience. You can set this up later on the Site Kit settings page.","google-site-kit"),f=Object(c.__)("If you’ve already set up ads on your site, it may change how they appear. You can customize this later in AdSense.","google-site-kit")):(m=!1,g=!1,p=Object(c.__)("Looks like you’re already using AdSense","google-site-kit"),h=Object(c.__)("Site Kit will place AdSense code on your site to connect your site to AdSense and help you get the most out of ads. This means Google will automatically place ads for you in all the best places.","google-site-kit"),i=Object(c.__)("Continue","google-site-kit"),n=w,E={eventCategory:"adsense_setup",eventName:"complete_adsense_setup"},b=Object(c.__)("Let Site Kit place code on your site to get your site approved","google-site-kit"),_=Object(c.__)("If you’ve already got some AdSense code on your site, we recommend you use Site Kit to place code to get the most out of AdSense.","google-site-kit"));break;case"account-connected-nonmatching":m=!1,g=!1,p=Object(c.__)("Your site has code from another AdSense account","google-site-kit"),h=Object(c.__)("We’ve found some AdSense code on your site, but it’s not linked to this AdSense account.","google-site-kit"),S=!1,i=Object(c.__)("Switch Google account","google-site-kit"),n=Object(r.m)("adsense",!0),y={accountStatus:"account-connected",continueText:Object(c.__)("Continue anyway","google-site-kit"),statusHeadline:Object(c.__)("Site Kit will place AdSense code on your site","google-site-kit"),statusMessage:Object(c.__)("To connect your site to your AdSense account, Site Kit will place AdSense code on your site. For a better ads experience, you should remove AdSense code that’s not linked to this AdSense account.","google-site-kit"),profile:!0,ctaLink:w,ctaLinkText:Object(c.__)("Continue","google-site-kit"),continueAction:!1,switchLabel:Object(c.__)("Let Site Kit place code on your site","google-site-kit"),switchOffMessage:Object(c.__)("You can let Site Kit do this later.","google-site-kit")};break;case"ads-display-pending":var x=Object(o.parse)(A.hostname).domain;p=Object(c.__)("Let’s get your site ready for ads","google-site-kit"),h=Object(c.__)("After you’ve finished setting up your account, we’ll let you know when your site is ready to show ads. This usually takes less than a day, but it can sometimes take a bit longer.","google-site-kit"),i=Object(c.__)("Go to your AdSense account to check on your site’s status or to complete setting up","google-site-kit"),n="https://www.google.com/adsense/new/sites?url=".concat(x||A.hostname,"&source=site-kit");break;case"account-pending-review":p=Object(c.__)("We’re getting your site ready for ads","google-site-kit"),h=Object(c.__)("AdSense is reviewing your site. Meanwhile, make sure you’ve completed these steps in AdSense.","google-site-kit"),i=Object(c.__)("Go to your AdSense account to check on your site’s status","google-site-kit"),n="https://www.google.com/adsense/new/sites?url=".concat(A.hostname,"&source=site-kit"),v=!0;break;case"account-required-action":O=!0;break;case"disapproved-account":n=D,i=Object(c.__)("Go to AdSense to find out how to fix the issue","google-site-kit"),p=Object(c.__)("Your site isn’t ready to show ads yet","google-site-kit"),h=Object(c.__)("You need to fix some things before we can connect Site Kit to your AdSense account.","google-site-kit");break;case"disapproved-account-afc":m=Object(c.__)("There is an AdSense account, but the AFC account is disapproved","google-site-kit"),g="error",p=Object(c.__)("Create Account","google-site-kit"),h=Object(c.__)("Create an AdMob account, then open AdSense and try to upgrade.","google-site-kit"),i=Object(c.__)("Create an AdMob Account","google-site-kit"),n="https://google.com/admob";break;case"no-account":p=Object(c.__)("Create your AdSense account","google-site-kit"),h=Object(c.__)("Site Kit will place AdSense code on every page across your site. This means Google will automatically place ads for you in all the best places.","google-site-kit"),S=!0,i=Object(c.__)("Create AdSense Account","google-site-kit"),n=C,u=Object(c.__)("Already have an AdSense account?","google-site-kit"),s=Object(c.__)("to connect to it","google-site-kit"),l=Object(c.__)("Switch Google account","google-site-kit"),d=Object(r.m)("adsense",!0),E={eventCategory:"adsense_setup",eventName:"create_adsense_account"};break;case"no-account-tag-found":p=Object(c.__)("Looks like you’re already using AdSense","google-site-kit"),h=Object(c.__)("We’ve found some AdSense code on your site, but it’s not linked to this Google account.","google-site-kit"),S=!1,i=Object(c.__)("Switch Google account","google-site-kit"),n=Object(r.m)("adsense",!0),b=Object(c.__)("Let Site Kit place code on your site to get your site approved","google-site-kit"),y={statusHeadline:Object(c.__)("Create a new AdSense account","google-site-kit"),statusMessage:Object(c.__)("Site Kit will place additional AdSense code on every page across your site after you create an account. This means Google will automatically place ads for you in all the best places.","google-site-kit"),notice:Object(c.__)("We recommend you remove the old AdSense code from this site.","google-site-kit"),icon:"warning",continueText:Object(c.__)("Continue anyway","google-site-kit"),ctaLinkText:Object(c.__)("Create AdSense Account","google-site-kit"),ctaLink:C,ctaTarget:"_blank",continueAction:!1};break;case"account-connected-no-data":p=Object(c.__)("We’re getting your site ready for ads","google-site-kit"),h=Object(c.__)("AdSense is reviewing your site. Meanwhile, make sure you’ve completed these steps in AdSense.","google-site-kit"),v=!0}return{accountTagMatch:k,continueAction:y,ctaLink:n,ctaLinkText:i,footerAppendedText:s,footerCTA:l,footerCTALink:d,footerText:u,icon:g,incomplete:v,issue:m,profile:S,required:O,setupComplete:!1,statusHeadline:p,statusMessage:h,switchLabel:b,switchOffMessage:_,switchOnMessage:f,tracking:E}},m=function(){var t,a,n,o,d,u,g,m,p,h,b,_,f,k,y,v,S,O,E,j,D,C,w,A,x,N,P,T,L,I=arguments;return i.a.async((function(M){for(;;)switch(M.prev=M.next){case 0:return t=I.length>0&&void 0!==I[0]&&I[0],a=I.length>1&&void 0!==I[1]?I[1]:function(){},o=!1,M.prev=3,a(Object(c.__)("Locating accounts…","google-site-kit")),M.next=7,i.a.awrap(s.c.get(s.b,"adsense","accounts").then((function(e){return e})).catch((function(e){return e})));case 7:if(d=M.sent,!(1<(u=!d.data||d.data.status&&200!==d.data.status?d:d.data).length)){M.next=42;break}a(Object(c.__)("Searching for domain…","google-site-kit")),g=!0,m=!1,p=void 0,M.prev=14,h=u[Symbol.iterator]();case 16:if(g=(b=h.next()).done){M.next=28;break}return _=b.value,f=_.id,M.next=21,i.a.awrap(s.c.get(s.b,"adsense","urlchannels",{clientID:f}).then((function(e){return e})).catch((function(e){return e})));case 21:k=M.sent,y=new URL(e.googlesitekit.admin.siteURL),(v=k&&k.length?Object(l.filter)(k,{urlPattern:y.hostname}):[])&&0!==v.length?(O=v[0].id,Object(r.A)("adsense_setup","adsense_account_detected")):(n="account-pending-review",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status account-pending-review"));case 25:g=!0,M.next=16;break;case 28:M.next=34;break;case 30:M.prev=30,M.t0=M.catch(14),m=!0,p=M.t0;case 34:M.prev=34,M.prev=35,g||null==h.return||h.return();case 37:if(M.prev=37,!m){M.next=40;break}throw p;case 40:return M.finish(37);case 41:return M.finish(34);case 42:if(S=u&&u.message&&u.message.error,O=!!(u&&u.length&&u[0])&&u[0].id,u&&O&&!S){M.next=50;break}E=(S||{}).errors,"noAdSenseAccount"!==(j=E[0].reason)&&u&&O||(n="disapprovedAccount"===j?"disapproved-account":t?"no-account-tag-found":"no-account"),M.next=118;break;case 50:return e.googlesitekit.modules.adsense.accountURL=Object(c.sprintf)("https://www.google.com/adsense/new/%s/home",O),a(Object(c.__)("Account found, checking account status…","google-site-kit")),M.next=54,i.a.awrap(s.c.get(s.b,"adsense","alerts",{accountID:O}).then((function(e){return e})).catch((function(e){return e})));case 54:if(D=M.sent,C=!D.data||D.data.status&&200!==D.data.status?D:D.data,w=C&&C.message&&C.message.error,!Object(l.find)(D,{type:"GRAYLISTED_PUBLISHER"})){M.next=62;break}n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending"),M.next=118;break;case 62:return M.next=64,i.a.awrap(s.c.get(s.b,"adsense","clients").then((function(e){return e})).catch((function(e){return e})));case 64:if(A=M.sent,x=!A.data||A.data.status&&200!==A.data.status?A:A.data,N=x&&x.message&&x.message.error,!(P=!(!x||!x.length)&&Object(l.find)(x,{productCode:"AFC"}))){M.next=72;break}return o=P.id,M.next=72,i.a.awrap(s.c.set(s.b,"adsense","client-id",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 72:if(!w){M.next=77;break}"accountPendingReview"===C.message.error.errors[0].reason&&(n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending")),M.next=118;break;case 77:if(a(Object(c.__)("Looking for AdSense client…","google-site-kit")),!N){M.next=83;break}n="account-required-action",Object(r.A)("adsense_setup","adsense_required_action","accountRequiredAction status"),M.next=118;break;case 83:if(!P){M.next=117;break}return o=P.id,a(Object(c.__)("Looking for site domain…","google-site-kit")),M.next=88,i.a.awrap(s.c.get(s.b,"adsense","urlchannels",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 88:if(T=M.sent,L=T&&T.length&&Object(l.filter)(T,(function(t){return 0<e.googlesitekit.admin.siteURL.indexOf(t.urlPattern)})),0!==T.length){M.next=95;break}n="ads-display-pending",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status ads-display-pending"),M.next=115;break;case 95:if(L&&0!==L.length){M.next=100;break}n="account-pending-review",Object(r.A)("adsense_setup","adsense_account_pending","accountPendingReview status account-pending-review"),M.next=115;break;case 100:if(!t||o!==t){M.next=105;break}n="account-connected",Object(r.A)("adsense_setup","adsense_account_connected","existing_matching_tag"),M.next=115;break;case 105:if(!t||o===t){M.next=110;break}n="account-connected-nonmatching",Object(r.A)("adsense_setup","adsense_account_connected","existing_non_matching_tag"),M.next=115;break;case 110:return n="account-connected",a(Object(c.__)("Connecting…","google-site-kit")),Object(r.A)("adsense_setup","adsense_account_connected"),M.next=115,i.a.awrap(s.c.set(s.b,"adsense","setup-complete",{clientID:o}).then((function(e){return e})).catch((function(e){return e})));case 115:M.next=118;break;case 117:n="disapproved-account-afc";case 118:return M.next=120,i.a.awrap(s.c.set(s.b,"adsense","account-status",{accountStatus:n}).then((function(e){return e})).catch((function(e){return e})));case 120:return M.abrupt("return",{accountStatus:n,clientID:o});case 123:return M.prev=123,M.t1=M.catch(3),M.abrupt("return",{isLoading:!1,error:M.t1.code,message:M.t1.message});case 126:case"end":return M.stop()}}),null,null,[[3,123],[14,30,34,42],[35,,37,41]])},p=function(){var t,a,n;return i.a.async((function(o){for(;;)switch(o.prev=o.next){case 0:if(t=e.googlesitekit.modules.adsense.active,a=e.googlesitekit.modules.analytics.active,n=!0,!t||!a){o.next=6;break}return o.next=6,i.a.awrap(s.c.get(s.b,"analytics","report",d.a).then((function(e){e&&(n=!0)})).catch((function(e){400===e.code&&"INVALID_ARGUMENT"===e.message&&(n=!1)})));case 6:return o.abrupt("return",new Promise((function(e){e(n)})));case 7:case"end":return o.stop()}}))},h=function(e,t,a){if(!a.data||!a.data.dateRange||"last-28-days"!==a.data.dateRange)return!1;var n=[];return e.totals&&(n=e.totals),0===(n=n.filter((function(e){return 0<e}))).length}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){var n=a(37),i=a(81),o=a(3),s=a(196),r=a(0);t.a=function(t,a){var l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],d=arguments.length>4&&void 0!==arguments[4]&&arguments[4],u=e.createElement(n.a
|
2 |
-
/* translators: %s: module name */,{title:Object(r.sprintf)(Object(r.__)("Data error in %s","google-site-kit"),t),description:a,error:!0});return"Invalid Credentials"===a&&Object(o.x)(s.a),Object(i.a)(u,l,c,d)}}).call(this,a(1))},,,,,function(e,t,a){"use strict";(function(e){var n=a(36),i=a.n(n);e._googlesitekitAPIFetchData&&(e._googlesitekitAPIFetchData.rootURL&&i.a.use(i.a.createRootURLMiddleware(e._googlesitekitAPIFetchData.rootURL)),e._googlesitekitAPIFetchData.nonceMiddleware&&(i.a.nonceMiddleware=i.a.createNonceMiddleware(),i.a.use(i.a.createNonceMiddleware(e._googlesitekitAPIFetchData.nonceMiddleware)),i.a.use(i.a.mediaUploadMiddleware),i.a.nonceEndpoint=e._googlesitekitAPIFetchData.nonceEndpoint)),t.default=i.a}).call(this,a(15))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(57),p=a(2),h=a.n(p),b=a(245),_=a(1),f=function(t){function Sparkline(){return i()(this,Sparkline),l()(this,d()(Sparkline).apply(this,arguments))}return g()(Sparkline,t),s()(Sparkline,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.change,i=t.instanceId,o=t.invertChangeColor,s=t.loadSmall,r=t.loadCompressed,l=t.loadHeight,c=t.loadText;if(!a)return"loading...";var d=o?"red":"green",u=o?"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(n)||0)?d:u]};return e.createElement("div",{className:"googlesitekit-analytics-sparkline-chart-wrap"},e.createElement(m.a,{data:a,options:g,id:"googlesitekit-sparkline-".concat(i),loadSmall:s,loadCompressed:r,loadHeight:l,loadText:c}))}}]),Sparkline}(_.Component);f.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},f.defaultProps={invertChangeColor:!1,loadSmall:!0,loadCompressed:!0,loadHeight:46,loadText:!1},t.a=Object(b.a)(f)}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){var n=a(37),i=a(81),o=a(0);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],s=arguments.length>2&&void 0!==arguments[2]&&arguments[2],r=arguments.length>3&&void 0!==arguments[3]&&arguments[3],l=e.createElement(n.a
|
3 |
-
/* translators: %s: Module name */,{title:Object(o.sprintf)(Object(o.__)("%s Gathering Data","google-site-kit"),t)
|
4 |
-
/* translators: %s: Module name */,description:Object(o.sprintf)(Object(o.__)("%s data is not yet available, please check back later.","google-site-kit"),t)});return Object(i.a)(l,a,s,r)}}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i,o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),u=a(8),g=a.n(u),m=a(16),p=a.n(m),h=a(9),b=a.n(h),_=a(11),f=a.n(_),k=a(32),y=a(2),v=a.n(y),S=a(0),O=a(1),E=a(13);function j(){var t;return f.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(!i){a.next=2;break}return a.abrupt("return",i);case 2:return e.google&&e.google.charts?i=Promise.resolve():((t=document.createElement("script")).type="text/javascript",i=new Promise((function(a){t.onload=a,e.document.head.appendChild(t),t.src="https://www.gstatic.com/charts/loader.js"}))),a.abrupt("return",i);case 4:case"end":return a.stop()}}))}var D=function(t){function GoogleChart(e){var t;return s()(this,GoogleChart),(t=d()(this,g()(GoogleChart).call(this,e))).state={loading:!0,chart:null},t.onChartsLoad=t.onChartsLoad.bind(p()(t)),t.waitForChart=t.waitForChart.bind(p()(t)),t.getData=t.getData.bind(p()(t)),t.prepareChart=t.prepareChart.bind(p()(t)),t.drawChart=t.drawChart.bind(p()(t)),t.updateChart=t.updateChart.bind(p()(t)),t.chartRef=Object(O.createRef)(),t.resize=Object(E.debounce)(t.drawChart,100),t}return b()(GoogleChart,t),l()(GoogleChart,[{key:"onChartsLoad",value:function(){this.getData(),this.prepareChart(),this.drawChart(),this.setState({loading:!1})}},{key:"componentDidMount",value:function(){return f.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,f.a.awrap(j());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()}}),null,this)}},{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 a="pie"===this.props.chartType?new e.google.visualization.PieChart(t):new e.google.visualization.LineChart(t);this.setState({chart:a})}else this.waitForChart(this.prepareChart)}},{key:"drawChart",value:function(){var e=this.state.chart,t=this.props,a=t.selectedStats,n=t.options,i=this.getData();null!==i&&null!==e?(e.draw(i,n),0!==a.length&&this.updateChart()):this.waitForChart(this.drawChart)}},{key:"updateChart",value:function(){var t=this.state.chart,a=this.props,n=a.selectedStats,i=a.options,o=a.singleStat,s=this.getData();if(null!==s&&null!==t){var r=new e.google.visualization.DataView(s);if(!o){var l=[0];l=l.concat(n.map((function(e){return e+1}))),r.setColumns(l)}t.draw(r,i)}else this.waitForChart(this.drawChart)}},{key:"render",value:function(){var e=this.state.loading,t=this.props,a=t.className,i=t.loadSmall,o=t.loadCompressed,s=t.loadHeight,r=t.loadText;return n.createElement("div",{className:"googlesitekit-graph-wrapper"},n.createElement("div",{ref:this.chartRef,className:"googlesitekit-line-chart"},n.createElement("div",{className:"googlesitekit-chart-loading"},e&&n.createElement("div",{className:"googlesitekit-chart-loading__wrapper"},r&&n.createElement("p",null,Object(S.__)("Loading chart...","google-site-kit")),n.createElement(k.a,{className:a,small:i,compress:o,height:s})))))}}]),GoogleChart}(O.Component);D.propTypes={selectedStats:v.a.array,options:v.a.object.isRequired,id:v.a.string,singleStat:v.a.bool,className:v.a.string,loadSmall:v.a.bool,loadCompressed:v.a.bool,loadHeight:v.a.number,loadText:v.a.bool},D.defaultProps={selectedStats:[],id:"",singleStat:!0,className:"",loadSmall:!1,loadCompressed:!1,loadHeight:null,loadText:!0},t.a=D}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(2),p=a.n(m),h=a(19),b=a(14),_=a.n(b),f=a(1),k=a(0),y=function(t){function SourceLink(){return i()(this,SourceLink),l()(this,d()(SourceLink).apply(this,arguments))}return g()(SourceLink,t),s()(SourceLink,[{key:"render",value:function(){var t=this.props,a=t.name,n=t.href,i=t.className,o=t.external;return e.createElement("div",{className:_()("googlesitekit-source-link",i)},[Object(k.__)("Source:","google-site-kit")," ",e.createElement(h.a,{key:"link",href:n,external:o,inherit:!0},a)])}}]),SourceLink}(f.Component);y.propTypes={name:p.a.string,href:p.a.string,className:p.a.string,external:p.a.bool},y.defaultProps={name:"",href:"",className:"",external:!1},t.a=y}).call(this,a(1))},,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(146),p=a(14),h=a.n(p),b=a(2),_=a.n(b),f=a(24),k=a(1),y=a(12),v=function(t){function PageHeader(){return i()(this,PageHeader),l()(this,d()(PageHeader).apply(this,arguments))}return g()(PageHeader,t),s()(PageHeader,[{key:"render",value:function(){var t=this.props,a=t.title,n=t.icon,i=t.iconWidth,o=t.iconHeight,s=t.iconID,r=t.className,l=t.status,c=t.statusText,d=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",u=Object(y.c)("googlesitekit.showDateRangeSelector-".concat(s),!1),g=!(""===l&&!u);return e.createElement("header",{className:"googlesitekit-page-header"},e.createElement("div",{className:"mdc-layout-grid__inner"},a&&e.createElement("div",{className:d},n&&e.createElement(f.a,{id:s,height:o,width:i,className:"googlesitekit-page-header__icon"}),e.createElement("h1",{className:h()("googlesitekit-page-header__title",r)},a)),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"},l&&e.createElement("span",{className:h()("googlesitekit-page-header__status","googlesitekit-page-header__status--".concat(l))},c),u&&e.createElement("span",{className:"googlesitekit-page-header__range"},e.createElement(m.a,null))))))}}]),PageHeader}(k.Component);v.propTypes={title:_.a.string,icon:_.a.bool,iconID:_.a.string,iconWidth:_.a.string,iconHeight:_.a.string,className:_.a.string,status:_.a.string,statusText:_.a.string,fullWidth:_.a.bool},v.defaultProps={title:"",icon:!1,iconID:"",iconWidth:"",iconHeight:"",className:"googlesitekit-heading-3",status:"",statusText:"",fullWidth:!1},t.a=v}).call(this,a(1))},,,function(e,t,a){"use strict";(function(e){var n=a(0),i=a(19);t.a=function HelpLink(){var t=Object(n.__)("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,a(1))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(31),p=a(1),h=function(t){function GenericError(){return i()(this,GenericError),l()(this,d()(GenericError).apply(this,arguments))}return g()(GenericError,t),s()(GenericError,[{key:"render",value:function(){return e.createElement(m.a,this.props)}}]),GenericError}(p.Component);t.a=h}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function ModuleSettingsWarning(){return i()(this,ModuleSettingsWarning),l()(this,d()(ModuleSettingsWarning).apply(this,arguments))}return g()(ModuleSettingsWarning,e),s()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(p.Component);t.a=Object(m.a)("googlesitekit.ModuleSettingsWarning")(h)},,,,function(e,t,a){"use strict";a.d(t,"a",(function(){return i}));var n=a(128),i=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:n.a.sanitize(e,t)}}},function(e,t,a){"use strict";(function(e){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,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Switch(e){var t;return i()(this,Switch),(t=l()(this,d()(Switch).call(this,e))).switchRef=Object(f.createRef)(),t}return g()(Switch,t),s()(Switch,[{key:"componentDidMount",value:function(){new m.i(this.switchRef.current)}},{key:"render",value:function(){var t=this.props,a=t.id,n=t.onClick,i=t.label,o=t.checked,s=t.hideLabel;return e.createElement(f.Fragment,null,e.createElement("div",{"aria-checked":o?"true":"false",className:_()("mdc-switch",{"mdc-switch--checked":o}),onClick:n,onKeyPress:function(e){"function"==typeof n&&"Enter"===e.code&&n(e)},role:"switch",ref:this.switchRef,tabIndex:0},e.createElement("div",{className:"mdc-switch__track"}," "),e.createElement("div",{className:"mdc-switch__thumb-underlay"},e.createElement("div",{className:"mdc-switch__thumb"},e.createElement("input",{type:"checkbox",id:a,className:"mdc-switch__native-control",role:"switch",checked:o,onChange:function(){}})))),e.createElement("label",{className:_()({"screen-reader-only":s}),htmlFor:a},i))}}]),Switch}(f.Component);k.propTypes={id:h.a.string.isRequired,onClick:h.a.func,label:h.a.string.isRequired,checked:h.a.bool,hideLabel:h.a.bool},k.defaultProps={checked:!1,hideLabel:!0},t.a=k}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"d",(function(){return o})),a.d(t,"b",(function(){return s})),a.d(t,"c",(function(){return r})),a.d(t,"a",(function(){return l}));var n=a(0);function i(e){return.9<=e?"fast":.5<=e?"average":"slow"}var o=function(e){var t=i(e);return"fast"===t?Object(n.__)("Fast","google-site-kit"):"average"===t?Object(n.__)("Average","google-site-kit"):Object(n.__)("Slow","google-site-kit")},s=function PageSpeedReportScoreCategoryWrapper(t){var a=t.score,n=t.children,o="googlesitekit-pagespeed-report__score-category-wrapper googlesitekit-pagespeed-report__score-category-wrapper--".concat(i(a)),s="googlesitekit-pagespeed-report__score-icon googlesitekit-pagespeed-report__score-icon--".concat(i(a));return e.createElement("span",{className:o},n," ",e.createElement("span",{className:s}))},r=function PageSpeedReportScoreGauge(t){var a=t.score,o=parseInt(100*a,10),s="\n\t\tgooglesitekit-percentage-circle\n\t\tgooglesitekit-percentage-circle--".concat(i(a),"\n\t\tgooglesitekit-percentage-circle--percent-").concat(o,"\n\t");return e.createElement("div",{className:"googlesitekit-pagespeed-report__score-gauge"},e.createElement("div",{className:s},e.createElement("div",{className:"googlesitekit-percentage-circle__text"},o),e.createElement("div",{className:"googlesitekit-percentage-circle__slice"},e.createElement("div",{className:"googlesitekit-percentage-circle__bar"}),e.createElement("div",{className:"googlesitekit-percentage-circle__fill"}))),e.createElement("span",{className:"googlesitekit-pagespeed-report__score-gauge-label screen-reader-only"},Object(n.__)("Performance","google-site-kit")))},l=function PageSpeedReportScale(){return e.createElement("div",{className:"googlesitekit-pagespeed-report__scale"},e.createElement("span",null,Object(n.__)("Scale:","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--fast"},Object(n.__)("90-100 (fast)","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--average"},Object(n.__)("50-89 (average)","google-site-kit")),e.createElement("span",{className:"googlesitekit-pagespeed-report__scale-range googlesitekit-pagespeed-report__scale-range--slow"},Object(n.__)("0-49 (slow)","google-site-kit")))}}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(3),_=a(10),f=a(37),k=a(2),y=a.n(k),v=a(67),S=a(1),O=a(0),E=function(t){function AnalyticsInactiveCTA(){return r()(this,AnalyticsInactiveCTA),u()(this,m()(AnalyticsInactiveCTA).apply(this,arguments))}return h()(AnalyticsInactiveCTA,t),c()(AnalyticsInactiveCTA,[{key:"render",value:function(){var t=this.props,a=t.title,i=void 0===a?Object(O.__)("Learn more about what visitors do on your site.","google-site-kit"):a,o=t.description,s=void 0===o?Object(O.__)("Connecting with Google Analytics to see unique vistors, goal completions, top pages and more.","google-site-kit"):o,r=t.ctaLabel,l=void 0===r?Object(O.__)("Set up Analytics","google-site-kit"):r;return e.googlesitekit.permissions.canManageOptions?n.createElement(f.a,{title:i,description:s,onClick:AnalyticsInactiveCTA.setupAnalyticsClick,ctaLabel:l}):null}}],[{key:"setupAnalyticsClick",value:function(){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(Object(b.a)(_.c,"analytics",!0));case 3:return t.next=5,o.a.awrap(Object(b.v)());case 5:e.location=Object(b.m)("analytics",!0),t.next=11;break;case 8:t.prev=8,t.t0=t.catch(0),Object(b.x)(v.a,{id:"analytics-setup-error",title:Object(O.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 11:case"end":return t.stop()}}),null,null,[[0,8]])}}]),AnalyticsInactiveCTA}(S.Component);E.propTypes={title:y.a.string,description:y.a.string,ctaLabel:y.a.string},E.defaultProps={},t.a=E}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,n){var i=a(31),o=a(0);t.a=function DashboardAuthAlert(){var t=e.googlesitekit.admin.connectURL;return n.createElement(i.a,{id:"authentication error",title:Object(o.__)("Issue accessing data","google-site-kit"),description:Object(o.__)("You need to reauthenticate your Google account.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0,ctaLink:t,ctaLabel:Object(o.__)("Click here","google-site-kit")})}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(21),i=a(1);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],o=arguments.length>2&&void 0!==arguments[2]&&arguments[2],s=arguments.length>3&&void 0!==arguments[3]&&arguments[3];return e.createElement(i.Fragment,null,a&&o&&s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(n.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))))),a&&!o&&s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(n.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))))),a&&o&&!s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},t),a&&!o&&!s&&e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},t),!a&&!o&&s&&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))),!a&&!o&&!s&&t)}}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(11),i=a.n(n),o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),u=a(8),g=a.n(u),m=a(9),p=a.n(m),h=a(10),b=a(31),_=a(2),f=a.n(_),k=a(0),y=a(1),v=function(t){function Alert(e){var t;return s()(this,Alert),(t=d()(this,g()(Alert).call(this,e))).state={isLoading:!0,alerts:[],error:!1,message:""},t}return p()(Alert,t),l()(Alert,[{key:"componentDidMount",value:function(){this.getAlert()}},{key:"getAlert",value:function(){var e,t;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,e=this.props.module,a.next=4,i.a.awrap(h.c.get(h.b,e,"notifications",{},!1));case 4:t=a.sent,this.setState({isLoading:!1,error:!1,alerts:t}),a.next=11;break;case 8:a.prev=8,a.t0=a.catch(0),this.setState({isLoading:!1,error:a.t0.code});case 11:case"end":return a.stop()}}),null,this,[[0,8]])}},{key:"render",value:function(){var t=this.state,a=t.alerts,n=t.error,i=t.isLoading;if(n||i||!a||!a.length)return null;var o=a.map((function(t){return e.createElement(b.a,{id:t.id,key:t.id,title:t.title,description:t.message||t.description,dismiss:Object(k.__)("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.Fragment,null,o)}}]),Alert}(y.Component);v.propTypes={module:f.a.string.isRequired},t.a=v}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(57),_=a(3),f=a(20),k=a(10),y=a(1),v=a(0),S=a(2),O=a.n(S),E=a(19),j=a(27),D=a(18);function C(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var w=function(t){function DashboardAcquisitionPieChart(){return r()(this,DashboardAcquisitionPieChart),u()(this,m()(DashboardAcquisitionPieChart).apply(this,arguments))}return h()(DashboardAcquisitionPieChart,t),c()(DashboardAcquisitionPieChart,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.source;if(!a||a.error||!a.length)return null;var i=Object(D.e)(a);return e.createElement("div",{className:"googlesitekit-chart googlesitekit-chart--pie"},e.createElement(b.a,{data:i,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}),n&&e.createElement("div",{className:"googlesitekit-chart__source"},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(E.a,{key:"link",href:Object(_.n)("googlesitekit-module-analytics"),inherit:!0},Object(v._x)("Analytics","Service name","google-site-kit"))]))}}]),DashboardAcquisitionPieChart}(y.Component);w.defaultProps={source:!1},w.propTypes={source:O.a.bool},t.a=Object(f.a)(w,[{type:k.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?C(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):C(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},D.k,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(_.p)("day"),context:["Dashboard","Single"]}],e.createElement(j.a,{width:"282px",height:"282px",shape:"circular"}),{},D.h,D.f)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){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,a(1))},,,,,,,,,,function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return C})),a.d(t,"a",(function(){return A}));var i=a(131),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(11),_=a.n(b),f=a(1),k=a(0),y=a(32),v=a(2),S=a.n(v),O=a(73),E=a(3),j=a(10),D=a(19),C=[/<meta name="googlesitekit-setup" content="([a-z0-9-]+)"/],w=[function(){var t;return _.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if(t=e.location.hostname,!["localhost","127.0.0.1"].includes(t)&&!t.match(/\.(example|invalid|localhost|test)$/)){a.next=3;break}throw"invalid_hostname";case 3:case"end":return a.stop()}}))},function(){var e,t,a;return _.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,_.a.awrap(j.c.set(j.a,"site","setup-tag"));case 2:return e=n.sent,t=e.token,n.next=6,_.a.awrap(Object(E.j)("setup").catch((function(){throw"tag_fetch_failed"})));case 6:if(a=n.sent,t===a){n.next=9;break}throw"setup_token_mismatch";case 9:case"end":return n.stop()}}))}],A=function(t){function CompatibilityChecks(t){var a;r()(this,CompatibilityChecks);var n=e.googlesitekit.setup.isSiteKitConnected;return(a=u()(this,m()(CompatibilityChecks).call(this,t))).state={complete:n,error:null,developerPlugin:{}},a}return h()(CompatibilityChecks,t),c()(CompatibilityChecks,[{key:"componentDidMount",value:function(){var e,t,a,n;return _.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(!this.state.complete){i.next=2;break}return i.abrupt("return");case 2:i.prev=2,e=0,t=w;case 4:if(!(e<t.length)){i.next=11;break}return a=t[e],i.next=8,_.a.awrap(a());case 8:e++,i.next=4;break;case 11:i.next=19;break;case 13:return i.prev=13,i.t0=i.catch(2),i.next=17,_.a.awrap(j.c.get(j.a,"site","developer-plugin"));case 17:n=i.sent,this.setState({error:i.t0,developerPlugin:n});case 19:this.setState({complete:!0});case 20:case"end":return i.stop()}}),null,this,[[2,13]])}},{key:"helperCTA",value:function(){var e=this.state.developerPlugin,t=e.installed,a=e.active,n=e.installURL,i=e.activateURL,o=e.configureURL;return!t&&n?{labelHTML:Object(k.__)('Install<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:n,external:!1}:t&&!a&&i?{labelHTML:Object(k.__)('Activate<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:i,external:!1}:t&&a&&o?{labelHTML:Object(k.__)('Configure<span class="screen-reader-text"> the helper plugin</span>',"google-site-kit"),href:o,external:!1}:{labelHTML:Object(k.__)('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,a=this.helperCTA(),i=a.labelHTML,o=a.href,s=a.external;switch(e){case"invalid_hostname":case"tag_fetch_failed":return n.createElement(f.Fragment,null,!t&&Object(k.__)("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(k.__)("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")," ",n.createElement(D.a,{href:o,dangerouslySetInnerHTML:{__html:i},external:s,inherit:!0}));case"setup_token_mismatch":return Object(k.__)("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,a=this.state,i=a.complete,s=a.error,r=this.props,l=r.children,c=o()(r,["children"]);return s&&(e=n.createElement(f.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-compat mdc-layout-grid mdc-layout-grid--align-left"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(O.a,null),n.createElement("div",{className:"googlesitekit-heading-4 mdc-layout-grid__cell--span-11"},Object(k.__)("Your site may not be ready for Site Kit","google-site-kit"))),n.createElement("p",null,this.renderError(s))))),i||(t=n.createElement("div",{style:{alignSelf:"center",marginLeft:"1rem"}},n.createElement("small",null,Object(k.__)("Checking Compatibility...","google-site-kit")),n.createElement(y.a,{small:!0,compress:!0}))),l({restProps:c,complete:i,error:s,inProgressFeedback:t,CTAFeedback:e})}}]),CompatibilityChecks}(f.Component);A.propTypes={children:S.a.func.isRequired}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,n){var i=a(37),o=a(81),s=a(3),r=a(0);t.a=function(t){var a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],l=arguments.length>2&&void 0!==arguments[2]&&arguments[2],c=arguments.length>3&&void 0!==arguments[3]&&arguments[3],d=e.googlesitekit.modules[t].name,u=n.createElement(i.a
|
5 |
-
/* translators: %s: Module name */,{title:Object(r.sprintf)(Object(r.__)("%s activation","google-site-kit"),d)
|
6 |
-
/* translators: %s: Module name */,description:Object(r.sprintf)(Object(r.__)("%s module needs to be configured","google-site-kit"),d),ctaLabel:Object(r.__)("Complete activation","google-site-kit"),onClick:function(){e.location=Object(s.m)(t,!0)}});return Object(o.a)(u,a,l,c)}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(24),h=a(33),b=a(1),_=a(0),f=function(t){function AdSenseDashboardOutro(){return o()(this,AdSenseDashboardOutro),c()(this,u()(AdSenseDashboardOutro).apply(this,arguments))}return m()(AdSenseDashboardOutro,t),r()(AdSenseDashboardOutro,[{key:"render",value:function(){var t=e.googlesitekit.modules.adsense.accountURL;return n.createElement("section",{className:"googlesitekit-module-outro"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-module-outro__logo"},n.createElement(p.a,{id:"adsense",height:"36",width:"42"}),n.createElement(p.a,{id:"plus",height:"13",width:"13"}),n.createElement(p.a,{id:"analytics",height:"36",width:"34"})),n.createElement("h3",{className:" googlesitekit-heading-3 googlesitekit-module-outro__title "},Object(_.__)("Connect Analytics with AdSense to create a powerful team that shows robust metrics for your site.","google-site-kit")),n.createElement("div",{className:"googlesitekit-module-outro__button"},n.createElement(h.a,{href:t,target:"_blank"},Object(_.__)("Connect Accounts","google-site-kit")))))))}}]),AdSenseDashboardOutro}(b.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(19),h=a(84),b=a(32),_=a(1),f=a(0),k=function(t){function AdSenseInProcessStatus(){return o()(this,AdSenseInProcessStatus),c()(this,u()(AdSenseInProcessStatus).apply(this,arguments))}return m()(AdSenseInProcessStatus,t),r()(AdSenseInProcessStatus,[{key:"render",value:function(){var t=this.props,a=t.ctaLink,i=t.ctaLinkText,o=t.header,s=t.incomplete,r=t.loadingMessage,l=t.subHeader,c=t.required,d=new URL(e.googlesitekit.admin.siteURL),u="https://www.google.com/adsense/new/sites?url=".concat(d.hostname,"&source=site-kit"),g=[{id:1,
|
7 |
-
/* translators: %s: Site URL */
|
8 |
-
text:Object(f.sprintf)(Object(f.__)("Added your site %s in ","google-site-kit"),d.hostname),linkText:Object(f.__)("Sites","google-site-kit"),linkURL:u},{id:2,text:Object(f.__)("Enabled ads in","google-site-kit"),linkText:Object(f.__)("Ads","google-site-kit"),linkURL:"https://www.google.com/adsense/new/myads/auto-ads"}];return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},c&&n.createElement(h.a,null),r&&n.createElement(_.Fragment,null,r,n.createElement(b.a,null)),o&&n.createElement("h3",{className:" googlesitekit-heading-4 googlesitekit-setup-module__title "},o),l&&n.createElement("p",null,l),s&&n.createElement("div",{className:"googlesitekit-setup-module__list-wrapper"},n.createElement("ol",{className:"googlesitekit-setup-module__list"},g.map((function(e){return n.createElement("li",{className:"googlesitekit-setup-module__list-item",key:e.id},e.text," ",n.createElement(p.a,{href:e.linkURL,external:!0,inherit:!0},e.linkText))})))),a&&i&&n.createElement("div",{className:"googlesitekit-setup-module__cta"},n.createElement(p.a,{className:"googlesitekit-setup-module__cta-link",href:a,external:!0},i)))}}]),AdSenseInProcessStatus}(_.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(74),_=a(10),f=a(2),k=a.n(f),y=a(3),v=a(1),S=a(0),O=a(12),E=function(t){function AdSenseSettings(t){var a;o()(this,AdSenseSettings),a=c()(this,u()(AdSenseSettings).call(this,t));var n=e.googlesitekit.modules.adsense.settings.useSnippet,i=void 0===n||n;return a.state={useSnippet:!!i,disabled:!1},a.handleUseSnippetSwitch=a.handleUseSnippetSwitch.bind(m()(a)),a}return h()(AdSenseSettings,t),r()(AdSenseSettings,[{key:"componentDidMount",value:function(){var e=this;this._isMounted=!0,Object(O.b)("googlekit.SettingsConfirmed","googlekit.AdSenseSettingsConfirmed",(function(t,a){return"adsense"!==a.replace("-module","")?t:e.save()})),this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(O.f)("googlekit.SettingsConfirmed","googlekit.AdSenseSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"save",value:function(){var t=this.state.useSnippet;this._isMounted&&this.setState({useSnippet:t});var a={useSnippet:t||!1};return e.googlesitekit.modules.adsense.settings&&(e.googlesitekit.modules.adsense.settings.useSnippet=t),_.c.set(_.b,"adsense","use-snippet",a).then((function(e){return e})).catch((function(e){return e}))}},{key:"handleUseSnippetSwitch",value:function(){var e=this.props.saveOnChange,t=this.state.useSnippet;t=!t,this._isMounted&&this.setState({useSnippet:t}),Object(y.A)("adsense_setup",t?"adsense_tag_enabled":"adsense_tag_disabled"),e&&_.c.set(_.b,"adsense","use-snippet",{useSnippet:t}).then((function(e){return e})).catch((function(e){return e}))}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){Object(y.z)("adsense",{useSnippet:"useSnippet"},this.state)}}},{key:"render",value:function(){var e=this.state.useSnippet,t=this.props,a=t.isEditing,i=t.switchLabel,o=void 0===i?Object(S.__)("Let Site Kit place code on your site","google-site-kit"):i,s=t.switchOnMessage,r=t.switchOffMessage;return n.createElement(v.Fragment,null,a?n.createElement(v.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__switch"},n.createElement(b.a,{id:"enableAutoAds",label:o,onClick:this.handleUseSnippetSwitch,checked:e,hideLabel:!1})," ",n.createElement("span",{className:"googlesitekit-recommended"},Object(S.__)("RECOMMENDED","google-site-kit"))),e&&s&&n.createElement("div",{className:"googlesitekit-settings-notice googlesitekit-settings-notice--suggestion"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},s)),!e&&r&&n.createElement("div",{className:"googlesitekit-settings-notice"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},r))):n.createElement(v.Fragment,null,Object(S.__)("The AdSense code has","google-site-kit")," ",e?Object(S.__)("been placed on your site.","google-site-kit"):Object(S.__)("not been placed on your site.","google-site-kit")))}}]),AdSenseSettings}(v.Component);E.propTypes={isEditing:k.a.bool,accountTagMatch:k.a.bool,existingTag:k.a.oneOfType([k.a.bool,k.a.string]),switchLabel:k.a.string,switchOnMessage:k.a.string,switchOffMessage:k.a.string},E.defaultProps={isEditing:!1,accountTagMatch:!1,existingTag:!1,switchOnMessage:"",switchOffMessage:""},t.a=E}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(39),v=a(102),S=a(13),O=a(0),E=a(1),j=a(18);function D(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var C=function(t){function AnalyticsDashboardWidgetTopAcquisitionSources(){return r()(this,AnalyticsDashboardWidgetTopAcquisitionSources),u()(this,m()(AnalyticsDashboardWidgetTopAcquisitionSources).apply(this,arguments))}return h()(AnalyticsDashboardWidgetTopAcquisitionSources,t),c()(AnalyticsDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(f.g)(),n=[{title:Object(O.__)("Medium","google-site-kit"),tooltip:Object(O.__)("Medium refers to where your traffic originated from","google-site-kit")},{title:Object(O.__)("Users","google-site-kit"),tooltip:Object(O.__)("Number of users that originated from that traffic","google-site-kit")},{title:Object(O.__)("New Users","google-site-kit"),
|
9 |
-
/* translators: %s: date range */
|
10 |
-
tooltip:Object(O.sprintf)(Object(O.__)("Number of new users to visit your page over last %s","google-site-kit"),a)},{title:Object(O.__)("Sessions","google-site-kit"),
|
11 |
-
/* translators: %s: date range */
|
12 |
-
tooltip:Object(O.sprintf)(Object(O.__)("Number of sessions users had on your website over last %s","google-site-kit"),a)},{title:Object(O.__)("Percentage","google-site-kit"),tooltip:Object(O.__)("Percentage of sessions","google-site-kit")}],i=t[0].data.totals[0].values[0],o=Object(S.map)(t[0].data.rows,(function(t,a){var n=t.metrics[0].values[0]/i*100;return!(1>n)&&[t.dimensions[0],Object(f.s)(t.metrics[0].values[0]),Object(f.s)(t.metrics[0].values[1]),Object(f.s)(t.metrics[0].values[2]),e.createElement(E.Fragment,{key:"minichart-analytics-top-as-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(n.toFixed(2),"%")," ",e.createElement(v.a,{percent:n.toFixed(1),index:a})))]})),s=Object(k.b)(o,n,{hideHeader:!1,chartsEnabled:!1});return e.createElement("div",{className:"googlesitekit-details-widget"},e.createElement(k.a,null,s))}}]),AnalyticsDashboardWidgetTopAcquisitionSources}(E.Component);t.a=Object(b.a)(C,[{type:_.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?D(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):D(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},j.k,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(f.p)("day"),context:["Single","Dashboard"]}],e.createElement(y.a,{rows:4,rowHeight:50}),{},j.h)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(57),p=a(211),h=a(1),b=function(t){function MiniChart(){return i()(this,MiniChart),l()(this,d()(MiniChart).apply(this,arguments))}return g()(MiniChart,t),s()(MiniChart,[{key:"render",value:function(){var t=this.props,a=t.index,n=t.percent,i={backgroundColor:"transparent",chartArea:{width:"100%",height:"100%"},enableInteractivity:!1,height:28,legend:{position:"none"},slices:{0:{color:p.a[a]},1:{color:"#e6e6e6"}},title:null,tooltip:{trigger:"none"},width:28},o=[["source","percent"],["",+n],["",100-n]];return e.createElement("div",{className:"googlesitekit-mini-chart"},e.createElement(m.a,{data:o,options:i,chartType:"pie",loadSmall:!0,loadCompressed:!0,loadHeight:24,loadText:!1,id:"minichart"+a}))}}]),MiniChart}(h.Component);t.a=b}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(27),p=a(2),h=a.n(p),b=a(1),_=function(t){function PreviewBlocks(){return i()(this,PreviewBlocks),l()(this,d()(PreviewBlocks).apply(this,arguments))}return g()(PreviewBlocks,t),s()(PreviewBlocks,[{key:"render",value:function(){for(var t=this.props,a=t.width,n=t.height,i=t.shape,o=t.count,s=[],r=0;r++<o;)s.push(e.createElement(m.a,{width:a,height:n,shape:i,key:r}));return s}}]),PreviewBlocks}(b.Component);_.propTypes={width:h.a.string,height:h.a.string,shape:h.a.string,count:h.a.number},_.defaultProps={width:"100px",height:"100px",shape:"square",count:1},t.a=_}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(20),h=a(10),b=a(3),_=a(29),f=a(39),k=a(13),y=a(0),v=a(1),S=function(t){function SearchConsoleDashboardWidgetKeywordTable(){return o()(this,SearchConsoleDashboardWidgetKeywordTable),c()(this,u()(SearchConsoleDashboardWidgetKeywordTable).apply(this,arguments))}return m()(SearchConsoleDashboardWidgetKeywordTable,t),r()(SearchConsoleDashboardWidgetKeywordTable,[{key:"render",value:function(){var t=this.props.data,a=[{title:Object(y.__)("Keyword","google-site-kit"),tooltip:Object(y.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(y.__)("Clicks","google-site-kit"),tooltip:Object(y.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(y.__)("Impressions","google-site-kit"),tooltip:Object(y.__)("Counted each time your content appears in search results","google-site-kit")}],i=e.googlesitekit.admin.siteURL,o=[],s=Object(k.map)(t,(function(e,t){var a=e.keys[0];return o[t]=Object(y.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%s&query=!%s&num_of_days=28",i,a),[a,Object(b.s)(e.clicks),Object(b.s)(e.impressions)]})),r={hideHeader:!1,chartsEnabled:!1,links:o},l=Object(_.b)(s,a,r);return n.createElement(_.a,null,l)}}]),SearchConsoleDashboardWidgetKeywordTable}(v.Component);t.a=Object(p.a)(S,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:e.googlesitekit.permaLink,dimensions:"query",limit:10},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"]}],n.createElement(f.a,{padding:!0}),{createGrid:!0},(function(e){return!e.length}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function DashboardSearchFunnelInner(){return i()(this,DashboardSearchFunnelInner),l()(this,d()(DashboardSearchFunnelInner).apply(this,arguments))}return g()(DashboardSearchFunnelInner,e),s()(DashboardSearchFunnelInner,[{key:"render",value:function(){return null}}]),DashboardSearchFunnelInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardSearchFunnel")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(2),h=a.n(p),b=a(1),_=a(0),f=a(31),k=function(t){function ErrorHandler(e){var t;return o()(this,ErrorHandler),(t=c()(this,u()(ErrorHandler).call(this,e))).state={error:null,info:null},t}return m()(ErrorHandler,t),r()(ErrorHandler,[{key:"componentDidCatch",value:function(t,a){e.console.error("Caught an error:",t,a),this.setState({error:t,info:a})}},{key:"render",value:function(){var e=this.props.children,t=this.state,a=t.error,i=t.info;return a?n.createElement(f.a,{id:"googlesitekit-error",title:Object(_.__)("Site Kit encountered an error","google-site-kit"),description:n.createElement("code",null,a.message),isDismissable:!1,format:"small",type:"win-error"},n.createElement("pre",null,i.componentStack)):e}}]),ErrorHandler}(b.Component);k.defaultProps={},k.propTypes={children:h.a.node.isRequired},t.a=k}).call(this,a(15),a(1))},,,,,,,,,,,,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return d}));var n,i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=function(t){var a=e[t];if(!a)return!1;try{var n="__storage_test__";return a.setItem(n,n),a.removeItem(n),!0}catch(e){return e instanceof DOMException&&(22===e.code||1014===e.code||"QuotaExceededError"===e.name||"NS_ERROR_DOM_QUOTA_REACHED"===e.name)&&0!==a.length}},c=function(){function NullStorage(){o()(this,NullStorage)}return r()(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}(),d=function(){return n||(n=l("sessionStorage")?e.sessionStorage:l("localStorage")?e.localStorage:new c),n}}).call(this,a(15))},function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return i}));var n=a(0);function i(){Object(n.setLocaleData)(e.googlesitekit.locale,"google-site-kit")}}).call(this,a(15))},,,,,,,function(e,t,a){"use strict";(function(e){var n=a(2),i=a.n(n),o=a(14),s=a.n(o);function ChangeArrow(t){var a=t.direction,n=t.invertColor;return e.createElement("svg",{className:s()("googlesitekit-change-arrow","googlesitekit-change-arrow--".concat(a),{"googlesitekit-change-arrow--inverted-color":n}),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:i.a.string,invertColor:i.a.bool},ChangeArrow.defaultProps={direction:"up",invertColor:!1},t.a=ChangeArrow}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){a.d(t,"a",(function(){return i}));var n=a(129),i=a.n(n)()(e)}).call(this,a(15))},,function(e,t,a){"use strict";(function(e){var n=a(31),i=a(0);t.a=function DashboardPermissionAlert(){return e.createElement(n.a,{id:"permission error",title:Object(i.__)("Permissions issue accessing data","google-site-kit"),description:Object(i.__)("This account does not have access to the requested data.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0})}}).call(this,a(1))},,function(e,t,a){"use strict";t.a=[/google_ad_client: ?["|'](.*?)["|']/,/<(?:script|amp-auto-ads) [^>]*data-ad-client="([^"]+)"/]},function(e,t,a){"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-[^"]+)"/]},,function(e,t,a){"use strict";(function(e){var n=a(24),i=a(0);t.a=function Logo(){return e.createElement("div",{className:"googlesitekit-logo","aria-hidden":"true"},e.createElement(n.a,{id:"logo-g",className:"googlesitekit-logo__logo-g",height:"34",width:"32"}),e.createElement(n.a,{id:"logo-sitekit",className:"googlesitekit-logo__logo-sitekit",height:"26",width:"99"}),e.createElement("span",{className:"screen-reader-text"},Object(i.__)("Site Kit by Google Logo","google-site-kit")))}}).call(this,a(1))},,,,,function(e,t,a){"use strict";(function(e,n){var i=a(96),o=a.n(i),s=a(11),r=a.n(s),l=a(5),c=a.n(l),d=a(6),u=a.n(d),g=a(7),m=a.n(g),p=a(8),h=a.n(p),b=a(16),_=a.n(b),f=a(9),k=a.n(f),y=a(22),v=a.n(y),S=a(10),O=a(2),E=a.n(O),j=a(33),D=a(32),C=a(19),w=a(141),A=a(74),x=a(25),N=a(24),P=a(3),T=a(14),L=a.n(T),I=a(0),M=a(1),W=a(12);function R(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function U(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?R(a,!0).forEach((function(t){v()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):R(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var F=v()({},"loggedinUsers",Object(I.__)("Logged-in users","google-site-kit")),z=function(t){function AnalyticsSetup(t){var a;c()(this,AnalyticsSetup),a=m()(this,h()(AnalyticsSetup).call(this,t));var n=e.googlesitekit.modules.analytics.settings,i=n.accountID,o=n.anonymizeIP,s=n.internalWebPropertyID,r=n.profileID,l=n.propertyID,d=n.useSnippet,u=n.trackingDisabled;return a.state={anonymizeIP:o,isLoading:!0,isSaving:!1,propertiesLoading:!1,profilesLoading:!1,useSnippet:d||!1,errorCode:!1,errorMsg:"",errorReason:!1,accounts:[],properties:[],profiles:[],selectedAccount:i,selectedProperty:l,selectedProfile:r,selectedinternalWebProperty:s,existingTag:!1,trackingDisabled:u||[]},a.handleAccountChange=a.handleAccountChange.bind(_()(a)),a.handlePropertyChange=a.handlePropertyChange.bind(_()(a)),a.handleProfileChange=a.handleProfileChange.bind(_()(a)),a.processAccountChange=a.processAccountChange.bind(_()(a)),a.processPropertyChange=a.processPropertyChange.bind(_()(a)),a.handleSubmit=a.handleSubmit.bind(_()(a)),a.handleRadioClick=a.handleRadioClick.bind(_()(a)),a.handleRefetchAccount=a.handleRefetchAccount.bind(_()(a)),a.handleExclusionsChange=a.handleExclusionsChange.bind(_()(a)),a.switchStatus=a.switchStatus.bind(_()(a)),a}return k()(AnalyticsSetup,t),u()(AnalyticsSetup,[{key:"componentDidMount",value:function(){var e,t,a,n,i,o=this;return r.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:if(e=this.props,t=e.isOpen,a=e.onSettingsPage,this._isMounted=!0,!a||t){s.next=4;break}return s.abrupt("return");case 4:return s.next=6,r.a.awrap(Object(P.j)("analytics"));case 6:if(!(n=s.sent)||!n.length){s.next=21;break}return s.prev=8,s.next=11,r.a.awrap(S.c.get(S.b,"analytics","tag-permission",{tag:n}));case 11:return i=s.sent,s.next=14,r.a.awrap(this.getAccounts(i));case 14:s.next=19;break;case 16:s.prev=16,s.t0=s.catch(8),this.setState({isLoading:!1,errorCode:s.t0.code,errorMsg:s.t0.message,errorReason:!(!s.t0.data||!s.t0.data.reason)&&s.t0.data.reason});case 19:s.next=23;break;case 21:return s.next=23,r.a.awrap(this.getAccounts());case 23:Object(W.b)("googlekit.SettingsConfirmed","googlekit.AnalyticsSettingsConfirmed",(function(e,t){return"analytics"!==t.replace("-module","")?e:o.props.isEditing?o.handleSubmit():void 0}));case 24:case"end":return s.stop()}}),null,this,[[8,16]])}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(W.f)("googlekit.SettingsConfirmed","googlekit.AnalyticsSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){var e={anonymizeIP:"anonymizeIP",selectedAccount:"accountID",selectedProperty:"propertyID",selectedProfile:"profileID",selectedinternalWebProperty:"internalWebPropertyID",useSnippet:"useSnippet",trackingDisabled:"trackingDisabled"};"-1"===this.state.selectedAccount&&(e={}),Object(P.z)("analytics",e,this.state)}}},{key:"handleAccountChange",value:function(e,t){var a=this.state.selectedAccount,n=t.dataset.value;n!==a&&("0"!==n?(this.setState({propertiesLoading:!0,profilesLoading:!0,selectedAccount:n}),Object(P.A)("analytics_setup","account_change",n),"-1"!==n&&this.processAccountChange(n)):this.setState({selectedAccount:n,selectedProperty:"-1",selectedProfile:"-1",properties:[{id:"-1",name:Object(I.__)("Select an account","google-site-kit")}],profiles:[{id:"-1",name:Object(I.__)("Select an account","google-site-kit")}]}))}},{key:"handlePropertyChange",value:function(e,t){var a=this.state.selectedProperty,n=t.dataset.value;n!==a&&("0"!==n?(this.setState({profilesLoading:!0,selectedProperty:n}),Object(P.A)("analytics_setup","property_change",n),this.processPropertyChange(n)):this.setState({selectedProperty:n,selectedProfile:n,profiles:[{id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")}]}))}},{key:"handleProfileChange",value:function(e,t){var a=t.dataset.value;this.setState({selectedProfile:a}),Object(P.A)("analytics_setup","profile_change",a)}},{key:"getAccounts",value:function(){var e,t,a,n,i,o,s,l,c,d,u,g,m,p,h,b,_=this,f=arguments;return r.a.async((function(k){for(;;)switch(k.prev=k.next){case 0:return e=f.length>0&&void 0!==f[0]&&f[0],t=this.state,a=t.selectedAccount,n=t.selectedProperty,i=t.selectedProfile,o=t.useSnippet,s=this.props,l=s.isEditing,c=s.onSettingsPage,d=this.state.errorCode,u={},k.prev=5,g=e?{existingAccountID:e.accountID,existingPropertyID:e.propertyID}:{},k.next=9,r.a.awrap(S.c.get(S.b,"analytics","accounts-properties-profiles",g));case 9:0===(m=k.sent).accounts.length?(u=U({},u,{errorCode:"no_account",errorReason:"noAccount"}),S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles")):a?"0"===a?m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")}):a&&!m.accounts.find((function(e){return e.id===a}))&&(S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles"),m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")}),l&&(a="0",n="-1",i="-1"),u=U({},u,{errorCode:"insufficient_permissions",errorReason:"insufficientPermissions"})):(p=null,m.matchedProperty&&(p=m.matchedProperty),p?(a=p.accountId,n=p.id,(h=m.profiles.find((function(e){return e.accountId===a})))&&(i=h.id)):m.accounts.unshift({id:0,name:Object(I.__)("Select one...","google-site-kit")})),b={id:"-1",name:Object(I.__)("Select an account","google-site-kit")},this.state.existingTag||m.properties.push({id:0,name:Object(I.__)("Setup a New Property","google-site-kit")}),m.profiles.push({id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")}),c||(o=!e),u=U({},u,{isLoading:!1,accounts:m.accounts,errorCode:d||u.errorCode,selectedAccount:a,selectedProperty:n,selectedProfile:i,properties:[b],profiles:[b],existingTag:!!e&&e.propertyID,useSnippet:o}),a&&"0"!==a&&(u=Object.assign(u,{properties:m.properties,profiles:m.profiles,selectedinternalWebProperty:m.properties[0]?m.properties[0].internalWebPropertyID:0})),k.next=22;break;case 19:k.prev=19,k.t0=k.catch(5),u={isLoading:!1,errorCode:k.t0.code,errorMsg:k.t0.message,errorReason:!(!k.t0.data||!k.t0.data.reason)&&k.t0.data.reason};case 22:return k.abrupt("return",new Promise((function(e){_._isMounted?_.setState(u,e):e()})));case 23:case"end":return k.stop()}}),null,this,[[5,19]])}},{key:"processAccountChange",value:function(e){var t,a,n,i;return r.a.async((function(o){for(;;)switch(o.prev=o.next){case 0:return o.prev=0,t={accountID:e},o.next=4,r.a.awrap(S.c.get(S.b,"analytics","properties-profiles",t));case 4:a=o.sent,n={id:0,name:Object(I.__)("Setup a New Property","google-site-kit")},a.properties.push(n),i={id:0,name:Object(I.__)("Setup a New Profile","google-site-kit")},a.profiles.push(i),this.setState({propertiesLoading:!1,profilesLoading:!1,properties:a.properties,profiles:a.profiles,selectedAccount:e,selectedProperty:a.properties[0].id,selectedinternalWebProperty:a.properties[0].internalWebPropertyID,selectedProfile:a.profiles[0].id,errorCode:!1}),o.next=15;break;case 12:o.prev=12,o.t0=o.catch(0),this.setState({errorCode:o.t0.code,errorMsg:o.t0.message});case 15:case"end":return o.stop()}}),null,this,[[0,12]])}},{key:"processPropertyChange",value:function(e){var t,a,n;return r.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return t=this.state.selectedAccount,i.prev=1,a={accountID:t,propertyID:e},i.next=5,r.a.awrap(S.c.get(S.b,"analytics","profiles",a));case 5:n=i.sent,this.setState({profilesLoading:!1,profiles:n,selectedProperty:e,selectedinternalWebProperty:n[0].internalWebPropertyID,selectedProfile:n[0].id,errorCode:!1}),i.next=12;break;case 9:i.prev=9,i.t0=i.catch(1),this.setState({errorCode:i.t0.code,errorMsg:i.t0.message});case 12:case"end":return i.stop()}}),null,this,[[1,9]])}},{key:"handleSubmit",value:function(t){var a,n,i,o,s,l,c,d,u,g,m,p,h,b,_,f,k;return r.a.async((function(y){for(;;)switch(y.prev=y.next){case 0:if(t&&t.preventDefault(),this.state.selectedAccount&&"-1"!==this.state.selectedAccount){y.next=3;break}return y.abrupt("return");case 3:return a=this.state,n=a.anonymizeIP,i=a.selectedAccount,o=a.selectedProperty,s=a.selectedProfile,l=a.useSnippet,c=a.selectedinternalWebProperty,d=a.accounts,u=a.properties,g=a.profiles,m=a.trackingDisabled,this.setState({isSaving:!0}),p=this.props.finishSetup,h=s||(g[0].id||0===g[0].id?g[0].id.toString():null),b=o||(u[0].id||0===u[0].id?u[0].id.toString():null),_="0"===b?"0":c||(u[0].internalWebPropertyId||0===u[0].internalWebPropertyId?u[0].internalWebPropertyId.toString():null),f={anonymizeIP:n,accountID:i||d[0].id||null,profileID:h,propertyID:b,internalWebPropertyID:_,useSnippet:l||!1,trackingDisabled:m},y.prev=10,y.next=13,r.a.awrap(S.c.set(S.b,"analytics","settings",f));case 13:return k=y.sent,S.c.invalidateCacheGroup(S.b,"analytics","accounts-properties-profiles"),y.next=17,r.a.awrap(this.getAccounts());case 17:e.googlesitekit.modules.analytics.settings=k,Object(P.A)("analytics_setup","analytics_configured"),p&&p(),this._isMounted&&this.setState({isSaving:!1,selectedAccount:k.accountID,selectedProfile:k.profileID,selectedProperty:k.propertyID,selectedinternalWebProperty:k.internalWebPropertyID}),y.next=26;break;case 23:y.prev=23,y.t0=y.catch(10),this.setState({isSaving:!1,errorCode:y.t0.code,errorMsg:y.t0.message});case 26:case"end":return y.stop()}}),null,this,[[10,23]])}},{key:"handleRadioClick",value:function(e){var t="1"===e.target.value;this.setState({useSnippet:t}),Object(P.A)("analytics_setup",t?"analytics_tag_enabled":"analytics_tag_disabled")}},{key:"switchStatus",value:function(e){var t=this;return function(){t.setState(v()({},e,!t.state[e]))}}},{key:"handleRefetchAccount",value:function(){this.setState({isLoading:!0,errorCode:!1,errorMsg:"",selectedAccount:"0",selectedProperty:"-1",selectedProfile:"-1",propertiesLoading:!1,profilesLoading:!1},this.getAccounts)}},{key:"handleExclusionsChange",value:function(e){var t=this.state.trackingDisabled,a=e.target,n=a.id,i=a.checked,s=Object.assign.apply(Object,[{}].concat(o()(t.map((function(e){return v()({},e,!0)}))),[v()({},n,i)]));this.setState({trackingDisabled:Object.keys(s).filter((function(e){return s[e]}))})}},{key:"renderAutoInsertSnippetForm",value:function(){var t=this.state,a=t.anonymizeIP,i=t.useSnippet,o=t.isSaving,s=t.existingTag,r=this.props,l=r.isEditing,c=r.onSettingsPage,d=!l,u=e.googlesitekit.admin.ampMode,g=e.googlesitekit.modules.analytics.settings.useSnippet;return n.createElement("div",{className:"googlesitekit-setup-module__inputs googlesitekit-setup-module__inputs--multiline"},(l||o)&&n.createElement(M.Fragment,null,c&&n.createElement(M.Fragment,null,!g&&!s&&n.createElement(M.Fragment,null,n.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(I.__)("Currently there is no Analytics snippet placed on your site, so no stats are being gathered. Would you like Site Kit to insert the Analytics snippet? You can change this setting later.","google-site-kit"))),g&&n.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(I.__)("Do you want to remove the Analytics snippet inserted by Site Kit?","google-site-kit"))),c&&!s&&!i&&g&&n.createElement("p",null,Object(I.__)("If the code snippet is removed, you will no longer be able to gather Analytics insights about your site.","google-site-kit"))),c&&n.createElement(M.Fragment,null,s&&n.createElement("p",null,Object(I.__)("Placing two tags at the same time is not recommended.","google-site-kit")),n.createElement(w.a,{onClick:this.handleRadioClick,id:"useSnippetTrue",name:"useSnippet",value:"1",checked:i,disabled:d},g?Object(I.__)("Not at this time","google-site-kit"):Object(I.__)("Insert snippet","google-site-kit")),n.createElement(w.a,{onClick:this.handleRadioClick,id:"useSnippetFalse",name:"useSnippet",value:"0",checked:!i,disabled:d},g?Object(I.__)("Remove snippet","google-site-kit"):Object(I.__)("Not at this time","google-site-kit"))),c&&i&&"primary"!==u&&n.createElement("div",{className:"googlesitekit-setup-module__input"},n.createElement(A.a,{id:"anonymizeIP",label:Object(I.__)("Anonymize IP addresses","google-site-kit"),onClick:this.switchStatus("anonymizeIP"),checked:a,hideLabel:!1}),n.createElement("p",null,a?Object(I.__)("IP addresses will be anonymized.","google-site-kit"):Object(I.__)("IP addresses will not be anonymized.","google-site-kit")," ",n.createElement(C.a,{href:"https://support.google.com/analytics/answer/2763052",external:!0,inherit:!0,dangerouslySetInnerHTML:{__html:Object(I.__)('Learn more<span class="screen-reader-text"> about IP anonymization.</span>',"google-site-kit")}}))))}},{key:"accountsDropdown",value:function(){var e=this.state,t=e.accounts,a=e.selectedAccount,i=e.existingTag,o=!this.props.isEditing;return i&&a&&(o=!0),n.createElement(x.k,{className:"googlesitekit-analytics__select-account",enhanced:!0,name:"accounts",value:a||"0",onEnhancedChange:this.handleAccountChange,label:Object(I.__)("Account","google-site-kit"),disabled:o,outlined:!0},t.concat(i?[]:[{id:"-1",name:Object(I.__)("Set up a new account","google-site-kit")}]).map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)})))}},{key:"renderForm",value:function(){var t=this.state,a=t.anonymizeIP,i=t.isLoading,o=t.propertiesLoading,s=t.profilesLoading,r=t.accounts,l=t.properties,c=t.profiles,d=t.selectedAccount,u=t.selectedProperty,g=t.selectedProfile,m=t.useSnippet,p=t.existingTag,h=t.errorCode,b=t.trackingDisabled,_=this.props,f=_.onSettingsPage,k=_.isEditing,y=parseInt(d)||0,v=!p&&y>0,S=!!/^UA-/.test(u.toString()),O=e.googlesitekit.admin.ampMode,E=e.googlesitekit.modules.analytics.setupComplete;if(i)return n.createElement(D.a,null);if("google_analytics_existing_tag_permission"===h)return null;if(!r.length||"-1"===d){if(!k)return Object(I.__)("No account found.","google-site-kit");if(!E||k)return n.createElement(M.Fragment,null,"-1"===d&&n.createElement(M.Fragment,null,n.createElement("p",null,Object(I.__)("To create a new account, click the button below which will open the Google Analytics account creation screen in a new window.","google-site-kit")),n.createElement("p",null,Object(I.__)("Once completed, click the link below to re-fetch your accounts to continue.","google-site-kit"))),n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(j.a,{onClick:AnalyticsSetup.createNewAccount},Object(I.__)("Create an account","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(C.a,{onClick:this.handleRefetchAccount},Object(I.__)("Re-fetch My Account","google-site-kit")))))}if(!k){var w=m?Object(I.__)("Snippet is inserted","google-site-kit"):Object(I.__)("Snippet is not inserted","google-site-kit");return p&&(w=Object(I.__)("Inserted by another plugin or theme","google-site-kit")),n.createElement(M.Fragment,null,n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Account","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},d||r[0].name||!1)),n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Property","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},u||l[0].name||!1)),n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("View","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},g||c[0].name||!1))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Analytics Code Snippet","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},w))),f&&m&&"primary"!==O&&n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("IP Address Anonymization","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},a&&Object(I.__)("IP addresses are being anonymized.","google-site-kit"),!a&&Object(I.__)("IP addresses are not being anonymized.","google-site-kit")))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:" googlesitekit-settings-module__meta-item "},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(I.__)("Excluded from Analytics","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},!!b.length&&b.map((function(e){return F[e]})).join(Object(I._x)(", ","list separator","google-site-kit")),!b.length&&Object(I.__)("Analytics is currently enabled for all visitors.","google-site-kit")))))}return n.createElement(M.Fragment,null,!f&&0<r.length&&!p&&n.createElement("p",null,Object(I.__)("Please select the account information below. You can change this view later in your settings.","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},this.accountsDropdown(),o?n.createElement(D.a,{small:!0}):n.createElement(x.k,{className:"googlesitekit-analytics__select-property",enhanced:!0,name:"properties",value:u||0===u?u.toString():"-1",onEnhancedChange:this.handlePropertyChange,label:Object(I.__)("Property","google-site-kit"),disabled:!v,outlined:!0},l.map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)}))),s?n.createElement(D.a,{small:!0}):n.createElement(x.k,{className:"googlesitekit-analytics__select-profile",enhanced:!0,name:"profiles",value:g||0===g?g.toString():"-1",onEnhancedChange:this.handleProfileChange,label:Object(I.__)("View","google-site-kit"),disabled:!S,outlined:!0},c.map((function(e,t){return n.createElement(x.j,{key:t,value:e.id},e.name)})))),this.renderAutoInsertSnippetForm(),f&&this.renderExclusionsForm(),!f&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(j.a,{disabled:!this.state.selectedAccount,onClick:this.handleSubmit},Object(I.__)("Configure Analytics","google-site-kit"))))}},{key:"renderExclusionsForm",value:function(){var e=this.state.trackingDisabled;return n.createElement("div",null,n.createElement("p",{className:"googlesitekit-setup-module__text"},Object(I.__)("Exclude from Analytics","google-site-kit")),n.createElement("div",{className:"mdc-form-field"},n.createElement(A.a,{id:"loggedinUsers",label:F.loggedinUsers,onClick:this.handleExclusionsChange,checked:e.includes("loggedinUsers"),hideLabel:!1})),n.createElement("p",null,e.includes("loggedinUsers")?Object(I.__)("Logged-in users will be excluded from Analytics tracking.","google-site-kit"):Object(I.__)("Logged-in users will be included in Analytics tracking.","google-site-kit")))}},{key:"renderErrorOrNotice",value:function(){var e=this.state,t=e.errorCode,a=e.errorMsg,i=e.errorReason,o=e.accounts,s=this.props.onSettingsPage;if(!t)return null;var r=!0,l=a;switch(!0){case"google_analytics_existing_tag_permission"===t:r=!0;break;case s&&t&&"insufficientPermissions"===i:r=!1,l=Object(I.__)("You currently don't have access to this Google Analytics account. You can either request access from your team, or remove this Google Analytics snippet and connect to a different account.","google-site-kit");break;case!s&&0===o.length:r=!1,l=Object(I.__)('Looks like you don\'t have an Analytics account yet. Once you create it, click on "Re-fetch my account" and Site Kit will locate it.',"google-site-kit")}return l&&0!==l.length?n.createElement("div",{className:L()({"googlesitekit-error-text":r})},n.createElement("p",null,r
|
13 |
-
/* translators: %s: Error message */?Object(I.sprintf)(Object(I.__)("Error: %s","google-site-kit"),l):l)):null}},{key:"render",value:function(){var e=this.props.onSettingsPage,t=this.state.existingTag;return e||Object(P.A)("analytics_setup","configure_analytics_screen"),n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--analytics"},!e&&n.createElement(M.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(N.a,{id:"analytics",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(I._x)("Analytics","Service name","google-site-kit"))),!!t&&
|
14 |
-
/* translators: %s: Analytics tag ID */
|
15 |
-
n.createElement("p",null,Object(I.sprintf)(Object(I.__)("An existing analytics tag was found on your site with the ID %s. If later on you decide to replace this tag, Site Kit can place the new tag for you. Make sure you remove the old tag first.","google-site-kit"),t)),this.renderErrorOrNotice(),this.renderForm())}}],[{key:"createNewAccount",value:function(t){t.preventDefault(),Object(P.A)("analytics_setup","new_analytics_account"),e.open("https://analytics.google.com/analytics/web/?#/provision/SignUp","_blank")}}]),AnalyticsSetup}(M.Component);z.propTypes={onSettingsPage:E.a.bool,finishSetup:E.a.func,isEditing:E.a.bool},z.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=z}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(25),p=a(2),h=a.n(p),b=a(14),_=a.n(b),f=a(1),k=function(t){function Radio(e){var t;return i()(this,Radio),(t=l()(this,d()(Radio).call(this,e))).formFieldRef=Object(f.createRef)(),t.radioRef=Object(f.createRef)(),t}return g()(Radio,t),s()(Radio,[{key:"componentDidMount",value:function(){new m.e(this.formFieldRef.current).input=new m.g(this.radioRef.current)}},{key:"render",value:function(){var t=this.props,a=t.onClick,n=t.id,i=t.name,o=t.value,s=t.checked,r=t.disabled,l=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:_()("mdc-radio",{"mdc-radio--disabled":r}),ref:this.radioRef},e.createElement("input",{className:"mdc-radio__native-control",onClick:a,type:"radio",id:n,name:i,value:o,checked:s,disabled:r,onChange:function(){}}),e.createElement("div",{className:"mdc-radio__background"},e.createElement("div",{className:"mdc-radio__outer-circle"}),e.createElement("div",{className:"mdc-radio__inner-circle"}))),e.createElement("label",{htmlFor:n},l))}}]),Radio}(f.Component);k.propTypes={onClick:h.a.func,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.string.isRequired},k.defaultProps={onClick:null,checked:!1,disabled:!1},t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(33),k=a(19),y=a(10),v=a(25),S=a(24),O=a(2),E=a.n(O),j=a(3),D=a(14),C=a.n(D),w=a(0),A=a(1),x=a(12),N=function(t){function OptimizeSetup(t){var a;r()(this,OptimizeSetup),a=u()(this,m()(OptimizeSetup).call(this,t));var n=e.googlesitekit.modules.optimize.settings,i=n.optimizeID,o=n.ampExperimentJSON,s=(e.googlesitekit.modules.analytics||{}).settings,l=e.googlesitekit.modules.tagmanager||{},c=l.active,d=l.settings,g=!!s&&s.useSnippet,p=!(!c||!d)&&d.useSnippet;return a.state={optimizeID:i||"",analyticsUseSnippet:g,gtmUseSnippet:p,errorCode:!1,errorMsg:"",ampExperimentJSON:o||"",ampExperimentJSONValidated:!0,OptimizeIDValidated:!0},a.handleOptimizeIDEntry=a.handleOptimizeIDEntry.bind(h()(a)),a.handleSubmit=a.handleSubmit.bind(h()(a)),a.renderInstructionInfo=a.renderInstructionInfo.bind(h()(a)),a.handleAMPOptimizeEntry=a.handleAMPOptimizeEntry.bind(h()(a)),a}return _()(OptimizeSetup,t),c()(OptimizeSetup,[{key:"componentDidMount",value:function(){var e=this;this._isMounted=!0,Object(x.b)("googlekit.SettingsConfirmed","googlekit.OptimizeSettingsConfirmed",(function(t,a){return"optimize"!==a.replace("-module","")?t:e.props.isEditing?e.handleSubmit():void 0})),this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(x.f)("googlekit.SettingsConfirmed","googlekit.OptimizeSettingsConfirmed")}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){Object(j.z)("optimize",{optimizeID:"optimizeID",ampExperimentJSON:"ampExperimentJSON"},this.state)}}},{key:"handleSubmit",value:function(){var t,a,n,i,s,r,l=this;return o.a.async((function(c){for(;;)switch(c.prev=c.next){case 0:if(t=this.state,a=t.optimizeID,n=t.ampExperimentJSON,i=t.OptimizeIDValidated,s=this.props.finishSetup,i&&0!==a.length){c.next=4;break}return c.abrupt("return",!1);case 4:return r={optimizeID:a,ampExperimentJSON:n},c.next=7,o.a.awrap(y.c.set(y.b,"optimize","settings",r).then((function(){s&&s(),e.googlesitekit.modules.optimize.settings.optimizeID=a,l._isMounted&&l.setState({isSaving:!1})})).catch((function(e){l._isMounted&&l.setState({errorCode:!0,errorMsg:e.errorMsg})})));case 7:return c.abrupt("return",c.sent);case 8:case"end":return c.stop()}}),null,this)}},{key:"handleOptimizeIDEntry",value:function(e){var t=Object(j.C)(e.target.value);this._isMounted&&this.setState({optimizeID:e.target.value,OptimizeIDValidated:t})}},{key:"handleAMPOptimizeEntry",value:function(e){var t=Object(j.B)(e.target.value);this._isMounted&&this.setState({ampExperimentJSON:e.target.value,ampExperimentJSONValidated:t})}},{key:"renderInfo",value:function(){var e=this.state.optimizeID;return n.createElement(A.Fragment,null,e?n.createElement("div",null,Object(w.__)("Your Optimize Container ID","google-site-kit"),": ",n.createElement("strong",null,e)):n.createElement("div",null,Object(w.__)('Optimize Container ID missing, press "edit" to add',"google-site-kit"),"."))}},{key:"renderInstructionInfo",value:function(){var e=this.state,t=e.analyticsUseSnippet,a=e.gtmUseSnippet,i=e.optimizeID;return!t&&a?n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("You are using auto insert snippet with Tag Manager","google-site-kit")),n.createElement("p",null,n.createElement("a",{href:"https://support.google.com/optimize/answer/6314801"},Object(w.__)("Click here","google-site-kit"))," ",Object(w.__)("for how to implement Optimize tag through your Tag Manager","google-site-kit"))):t?null:n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("You disabled analytics auto insert snippet. If You are using Google Analytics code snippet, add the code below:","google-site-kit")),n.createElement("pre",null,'ga("require", "',i||"GTM-XXXXXXX",'");'),n.createElement("p",null,n.createElement("a",{href:"https://support.google.com/optimize/answer/6262084"},Object(w.__)("Click here","google-site-kit"))," ",Object(w.__)("for how to implement Optimize tag in Google Analytics Code Snippet","google-site-kit")))}},{key:"renderAMPSnippet",value:function(){var t=this.state,a=t.analyticsUseSnippet,i=t.ampExperimentJSON,o=t.ampExperimentJSONValidated,s=e.googlesitekit.admin.ampEnabled;return a&&s?n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("Please input your AMP experiment settings in JSON format below.","google-site-kit")," ",n.createElement(k.a,{href:"https://developers.google.com/optimize/devguides/amp-experiments",external:!0,inherit:!0},Object(w.__)("Learn More.","google-site-kit"))),n.createElement(v.l,{className:C()("mdc-text-field",{"mdc-text-field--error":!o}),name:"amp-experiment",onChange:this.handleAMPOptimizeEntry,textarea:!0},n.createElement(v.b,{inputType:"textarea",value:null===i?"":i})),!o&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error: AMP experiment settings are not in a valid JSON format.","google-site-kit"))):null}},{key:"renderForm",value:function(){var e=this.state,t=e.optimizeID,a=e.errorCode,i=e.errorMsg,o=e.OptimizeIDValidated;return n.createElement(A.Fragment,null,n.createElement("p",null,Object(w.__)("Please copy and paste your Optimize ID to complete your setup.","google-site-kit")," ",n.createElement(k.a,{href:"https://support.google.com/optimize/answer/6211921",external:!0,inherit:!0},Object(w.__)("You can locate this here.","google-site-kit"))),a&&0<i.length&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error:","google-site-kit")," ",i),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},n.createElement(v.l,{className:C()("mdc-text-field",{"mdc-text-field--error":a||!o}),label:Object(w.__)("Optimize Container ID","google-site-kit"),name:"optimizeID",onChange:this.handleOptimizeIDEntry,helperText:n.createElement(v.a,null,Object(w.__)("Format: GTM-XXXXXXX.","google-site-kit")),outlined:!0,required:!0},n.createElement(v.b,{value:t}))),!o&&n.createElement("p",{className:"googlesitekit-error-text"},Object(w.__)("Error: Not a valid Optimize ID.","google-site-kit")),this.renderAMPSnippet(),this.renderInstructionInfo())}},{key:"render",value:function(){var e=this.props,t=e.onSettingsPage,a=e.isEditing;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--optimize"},!t&&n.createElement(A.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(S.a,{id:"optimize",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(w._x)("Optimize","Service name","google-site-kit"))),a&&this.renderForm(),!a&&this.renderInfo(),!t&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(f.a,{onClick:this.handleSubmit},Object(w.__)("Configure Optimize","google-site-kit"))))}}]),OptimizeSetup}(A.Component);N.propTypes={onSettingsPage:E.a.bool,finishSetup:E.a.func,isEditing:E.a.bool},N.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=N}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){a.d(t,"b",(function(){return E})),a.d(t,"a",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(20),h=a(47),b=a(10),_=a(3),f=a(29),k=a(13),y=a(1),v=a(0),S=a(76),O=function(t){function PageSpeedInsightsDashboardWidgetHomepageSpeedColumn(){return o()(this,PageSpeedInsightsDashboardWidgetHomepageSpeedColumn),c()(this,u()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn).apply(this,arguments))}return m()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn,t),r()(PageSpeedInsightsDashboardWidgetHomepageSpeedColumn,[{key:"componentDidMount",value:function(){var e=this.props,t=e.data,a=e.handleDataLoaded;t&&a&&a()}},{key:"render",value:function(){var t=this.props,a=t.data,n=t.title;if(!a||a.error)return null;if(!function(e){return!!Object(k.get)(e,"categories.performance.score")}(a))return Object(h.a)(Object(v._x)("PageSpeed Insights","Service name","google-site-kit"),Object(v.__)("An unknown error occurred while trying to fetch PageSpeed Insights data. Please try again later.","google-site-kit"),!0);var i=a.categories.performance.score,o=Object(S.d)(i),s=a.audits.interactive.displayValue,r=Object(f.b)([[Object(v.__)("Real user speed data","google-site-kit"),e.createElement(S.b,{key:"0",score:i},o)],[Object(v.__)("Time to become fully interactive","google-site-kit"),e.createElement(S.b,{key:"0",score:i},s)]],[],{hideHeader:!0,disableListMode:!0,chartsEnabled:!1,links:[]});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("div",{className:"googlesitekit-pagespeed-report__heading-wrapper"},e.createElement("h3",{className:" googlesitekit-subheading-1 "},n),e.createElement(S.c,{score:i})),e.createElement(f.a,null,r))}}]),PageSpeedInsightsDashboardWidgetHomepageSpeedColumn}(y.Component),E=Object(p.a)(O,[{type:b.b,identifier:"pagespeed-insights",datapoint:"pagespeed",data:{url:n.googlesitekit.permaLink,strategy:"mobile",dateRange:null},priority:10,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],null,{inGrid:!0}),j=Object(p.a)(O,[{type:b.b,identifier:"pagespeed-insights",datapoint:"pagespeed",data:{url:n.googlesitekit.permaLink,strategy:"desktop",dateRange:null},priority:10,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],null,{inGrid:!0})}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(11),r=a.n(s),l=a(5),c=a.n(l),d=a(6),u=a.n(d),g=a(7),m=a.n(g),p=a(8),h=a.n(p),b=a(16),_=a.n(b),f=a(9),k=a.n(f),y=a(33),v=a(19),S=a(74),O=a(10),E=a(32),j=a(25),D=a(24),C=a(2),w=a.n(C),A=a(3),x=a(13),N=a(14),P=a.n(N),T=a(0),L=a(1),I=a(12),M=a(38),W="web",R="amp",U=function(t){function TagmanagerSetup(t){var a;c()(this,TagmanagerSetup),a=m()(this,h()(TagmanagerSetup).call(this,t));var n=e.googlesitekit.admin,i=n.ampEnabled,o=n.ampMode,s=e.googlesitekit.modules.tagmanager.settings,r="primary"===o?R:[W,R];return a.state={ampEnabled:i,isLoading:!0,isSecondaryAMP:"secondary"===o,accounts:[],containers:[],containersAMP:[],errorCode:!1,errorMsg:"",existingContainer:"",selectedAccount:s.accountID,selectedContainer:s.containerID,selectedContainerAMP:s.ampContainerID,containersLoading:!1,usageContext:i?r:W,hasExistingTag:!1,useSnippet:s.useSnippet},a.handleSubmit=a.handleSubmit.bind(_()(a)),a.renderAccountDropdownForm=a.renderAccountDropdownForm.bind(_()(a)),a.handleAccountChange=a.handleAccountChange.bind(_()(a)),a.refetchAccount=a.refetchAccount.bind(_()(a)),a}return k()(TagmanagerSetup,t),u()(TagmanagerSetup,[{key:"setState",value:function(){this._isMounted&&L.Component.prototype.setState.apply(this,arguments)}},{key:"componentDidMount",value:function(){var e,t,a,n=this;return r.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e=this.props,t=e.isOpen,a=e.onSettingsPage,this._isMounted=!0,!a||t){i.next=4;break}return i.abrupt("return");case 4:return i.next=6,r.a.awrap(this.loadAccountsContainers());case 6:Object(I.b)("googlekit.SettingsConfirmed","googlekit.TagmanagerSettingsConfirmed",(function(e,t){return"tagmanager"!==t.replace("-module","")?e:n.props.isEditing?n.handleSubmit():void 0})),this.toggleConfirmChangesButton();case 8:case"end":return i.stop()}}),null,this)}},{key:"componentDidUpdate",value:function(){this.toggleConfirmChangesButton()}},{key:"componentWillUnmount",value:function(){this._isMounted=!1,Object(I.f)("googlekit.SettingsConfirmed","googlekit.TagmanagerSettingsConfirmed")}},{key:"toggleConfirmChangesButton",value:function(){if(this.props.isEditing){var e={selectedContainer:"containerID",selectedContainerAMP:"ampContainerID",selectedAccount:"accountID",useSnippet:"useSnippet"};this.canSaveSettings()||(e={}),Object(A.z)("tagmanager",e,this.state)}}},{key:"loadAccountsContainers",value:function(){var e,t,a,n,i,o;return r.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,r.a.awrap(Object(A.j)("tagmanager"));case 2:if(!(e=s.sent)){s.next=20;break}return s.prev=4,s.next=7,r.a.awrap(O.c.get(O.b,"tagmanager","tag-permission",{tag:e}));case 7:t=s.sent,a=t.account,n=t.container,i=Object(M.a)([n]).byContext(W),o=Object(M.a)([n]).byContext(R),this.setState({isLoading:!1,existingContainer:e,selectedAccount:a.accountId,selectedContainer:Object(x.get)(i,[0,"publicId"]),selectedContainerAMP:Object(x.get)(o,[0,"publicId"]),accounts:[a],hasExistingTag:!0}),s.next=18;break;case 15:s.prev=15,s.t0=s.catch(4),this.setState({isLoading:!1,errorCode:s.t0.code,errorMsg:s.t0.message,errorReason:!(!s.t0.data||!s.t0.data.reason)&&s.t0.data.reason,existingContainer:e,hasExistingTag:!!e});case 18:s.next=22;break;case 20:return s.next=22,r.a.awrap(this.requestTagManagerAccountsContainers());case 22:case"end":return s.stop()}}),null,this,[[4,15]])}},{key:"requestTagManagerAccounts",value:function(){var e,t;return r.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return a.prev=0,e=this.state.selectedAccount,a.next=4,r.a.awrap(O.c.get(O.b,"tagmanager","accounts"));case 4:t=a.sent,this.validateAccounts(t,e),this.setState({isLoading:!1,accounts:t}),a.next=12;break;case 9:a.prev=9,a.t0=a.catch(0),this.setState({isLoading:!1,errorCode:a.t0.code,errorMsg:a.t0.message});case 12:case"end":return a.stop()}}),null,this,[[0,9]])}},{key:"requestTagManagerAccountsContainers",value:function(){var e,t,a,n,i,o,s,l,c,d,u,g,m;return r.a.async((function(p){for(;;)switch(p.prev=p.next){case 0:return p.prev=0,e=this.state,t=e.selectedAccount,a=e.usageContext,n=this.state,i=n.selectedContainer,o=n.selectedContainerAMP,s={accountID:t,usageContext:a},p.next=6,r.a.awrap(O.c.get(O.b,"tagmanager","accounts-containers",s));case 6:l=p.sent,c=l.accounts,d=l.containers,this.validateAccounts(c,t),u=d.map((function(e){return e.publicId})),Object(M.c)(i)&&!u.includes(i)&&(i=""),Object(M.c)(o)&&!u.includes(o)&&(o=""),g=Object(M.a)(d).byContext(W),m=Object(M.a)(d).byContext(R),this.setState({isLoading:!1,accounts:c,containers:g,containersAMP:m,selectedAccount:t||Object(x.get)(d,[0,"accountId"]),selectedContainer:i||Object(x.get)(g,[0,"publicId"]),selectedContainerAMP:o||Object(x.get)(m,[0,"publicId"]),errorCode:!1,errorMsg:""}),p.next=21;break;case 18:p.prev=18,p.t0=p.catch(0),this.setState({isLoading:!1,errorCode:p.t0.code,errorMsg:p.t0.message});case 21:case"end":return p.stop()}}),null,this,[[0,18]])}},{key:"validateAccounts",value:function(e,t){if(!t&&0===e.length)throw{code:"accountEmpty",message:Object(T.__)("We didn’t find an associated Google Tag Manager account, would you like to set it up now? If you’ve just set up an account please re-fetch your account to sync it with Site Kit.","google-site-kit")};if(Object(M.b)(t)&&!e.find((function(e){return e.accountId===t})))throw{code:"insufficientPermissions",message:Object(T.__)("You currently don’t have access to this Google Tag Manager account. You can either request access from your team, or remove this Google Tag Manager snippet and connect to a different account.","google-site-kit")}}},{key:"requestTagManagerContainers",value:function(e){var t,a;return r.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return this.setState({containersLoading:!0}),n.prev=1,t={accountID:e,usageContext:this.state.usageContext},n.next=5,r.a.awrap(O.c.get(O.b,"tagmanager","containers",t));case 5:a=n.sent,this.setState({containersLoading:!1,containers:Object(M.a)(a).byContext(W),containersAMP:Object(M.a)(a).byContext(R),errorCode:!1}),n.next=12;break;case 9:n.prev=9,n.t0=n.catch(1),this.setState({containersLoading:!1,errorCode:n.t0.code,errorMsg:n.t0.message});case 12:case"end":return n.stop()}}),null,this,[[1,9]])}},{key:"handleSubmit",value:function(){var t,a,n,i,o,s,l,c,d,u;return r.a.async((function(g){for(;;)switch(g.prev=g.next){case 0:return t=this.state,a=t.hasExistingTag,n=t.selectedAccount,i=t.selectedContainer,o=t.selectedContainerAMP,s=t.usageContext,l=t.useSnippet,c=this.props.finishSetup,g.prev=2,d={accountID:n,containerID:i,ampContainerID:o,usageContext:s,useSnippet:!a&&l},g.next=6,r.a.awrap(O.c.set(O.b,"tagmanager","settings",d));case 6:u=g.sent,c&&c(),e.googlesitekit.modules.tagmanager.settings=u,this.setState({isSaving:!1}),g.next=16;break;case 12:throw g.prev=12,g.t0=g.catch(2),this.setState({isLoading:!1,isSaving:!1,errorCode:g.t0.code,errorMsg:g.t0.message}),g.t0;case 16:case"end":return g.stop()}}),null,this,[[2,12]])}},{key:"handleAccountChange",value:function(e,t){var a=this.state.selectedAccount,n=t.dataset.value;n!==a&&(this.setState({selectedAccount:n,selectedContainer:"",selectedContainerAMP:""}),Object(M.b)(n)&&this.requestTagManagerContainers(n))}},{key:"refetchAccount",value:function(e){e.preventDefault(),this.setState({isLoading:!0,errorCode:!1,errorMsg:"",selectedAccount:"",selectedContainer:"",selectedContainerAMP:""},this.requestTagManagerAccounts)}},{key:"renderSettingsInfo",value:function(){var t=e.googlesitekit.modules.tagmanager.settings,a=this.state,i=a.ampEnabled,o=a.isSecondaryAMP,s=a.hasExistingTag,r=a.isLoading,l=t.accountID,c=t.useSnippet;return r?n.createElement(E.a,null):n.createElement(L.Fragment,null,n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(T.__)("Account","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},l||!1)),(!i||o)&&n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},o&&Object(T.__)("Web Container ID","google-site-kit"),!i&&Object(T.__)("Container ID","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},t.containerID||!1)),i&&n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},o&&Object(T.__)("AMP Container ID","google-site-kit"),!o&&Object(T.__)("Container ID","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},t.ampContainerID||!1))),n.createElement("div",{className:"googlesitekit-settings-module__meta-items"},n.createElement("div",{className:"googlesitekit-settings-module__meta-item"},n.createElement("p",{className:"googlesitekit-settings-module__meta-item-type"},Object(T.__)("Tag Manager Code Snippet","google-site-kit")),n.createElement("h5",{className:"googlesitekit-settings-module__meta-item-data"},c&&Object(T.__)("Snippet is inserted","google-site-kit"),!c&&Object(T.__)("Snippet is not inserted","google-site-kit")),s&&n.createElement("p",null,Object(T.__)("Placing two tags at the same time is not recommended.","google-site-kit")))))}},{key:"renderAccountDropdownForm",value:function(){var e=this,t=this.state,a=t.ampEnabled,i=t.accounts,o=t.selectedAccount,s=t.containers,r=t.containersAMP,l=t.existingContainer,c=t.hasExistingTag,d=t.isLoading,u=t.isSecondaryAMP,g=t.errorCode,m=t.useSnippet,p=this.props.onSettingsPage;if(d)return n.createElement(E.a,null);if("tag_manager_existing_tag_permission"===g)return null;if("accountEmpty"===g)return this.renderCreateAccount();if("account_create"===o)return n.createElement(L.Fragment,null,n.createElement("p",null,Object(T.__)("To create a new account, click the button below which will open the Google Tag Manager account creation screen in a new window.","google-site-kit")),n.createElement("p",null,Object(T.__)("Once completed, click the link below to re-fetch your accounts to continue.","google-site-kit")),this.renderCreateAccount());var h=!a||u,b=a;return n.createElement(L.Fragment,null,c&&n.createElement("p",null,Object(T.sprintf)(// translators: %s: the existing container ID.
|
16 |
-
Object(T.__)("An existing tag was found on your site (%s). If you later decide to replace this tag, Site Kit can place the new tag for you. Make sure you remove the old tag first.","google-site-kit"),l)),!c&&!u&&n.createElement("p",null,Object(T.__)("Please select your Tag Manager account and container below, the snippet will be inserted automatically on your site.","google-site-kit")),!c&&u&&n.createElement("p",null,Object(T.__)("Looks like your site is using paired AMP. Please select your Tag Manager account and relevant containers below, the snippets will be inserted automatically on your site.","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__inputs"},n.createElement(j.k,{className:"googlesitekit-tagmanager__select-account",enhanced:!0,name:"accounts",label:Object(T.__)("Account","google-site-kit"),value:o,disabled:c,onEnhancedChange:this.handleAccountChange,outlined:!0},[].concat(i).concat(c?[]:{name:Object(T.__)("Set up a new account","google-site-kit"),accountId:"account_create"}).map((function(e){return n.createElement(j.j,{key:e.accountId,value:e.accountId},e.name)}))),h&&this.renderContainerSelect({selectedStateKey:"selectedContainer",containers:s,label:b?Object(T.__)("Web Container","google-site-kit"):null,type:W}),b&&this.renderContainerSelect({selectedStateKey:"selectedContainerAMP",containers:r,label:h?Object(T.__)("AMP Container","google-site-kit"):null,type:R})),p&&n.createElement(L.Fragment,null,c&&n.createElement("p",null,Object(T.__)("Placing two tags at the same time is not recommended.","google-site-kit")),n.createElement(S.a,{id:"tagmanagerUseSnippet",onClick:function(){return e.setState({useSnippet:!m})},name:"useSnippet",checked:m,label:Object(T.__)("Let Site Kit place code on your site","google-site-kit"),hideLabel:!1}),n.createElement("p",null,m?Object(T.__)("Site Kit will add the code automatically","google-site-kit"):Object(T.__)("Site Kit will not add the code to your site","google-site-kit"))),!p&&n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(y.a,{onClick:this.handleSubmit,disabled:!this.canSaveSettings()},Object(T.__)("Confirm & Continue","google-site-kit"))))}},{key:"renderContainerSelect",value:function(e){var t=this,a=e.label,i=e.selectedStateKey,s=e.containers,r=e.type,l=this.state,c=l.containersLoading,d=l.selectedAccount,u=l.hasExistingTag,g=!!s.length;return c?n.createElement(E.a,{small:!0}):n.createElement(j.k,{className:"\n\t\t\t\t\tgooglesitekit-tagmanager__select-container\n\t\t\t\t\tgooglesitekit-tagmanager__select-container--".concat(r,"\n\t\t\t\t"),label:a||Object(T.__)("Container","google-site-kit"),value:g?this.state[i]:"container_create",onEnhancedChange:function(e,a){return t.setState(o()({},i,a.dataset.value))},disabled:u||!Object(M.b)(d),enhanced:!0,outlined:!0},[].concat(s).concat(u?[]:{name:Object(T.__)("Set up a new container","google-site-kit"),publicId:"container_create"}).map((function(e,t){var a=e.name,i=e.publicId;return n.createElement(j.j,{key:t,value:i},a)})))}},{key:"canSaveSettings",value:function(){var e=this.state,t=e.ampEnabled,a=e.isSecondaryAMP,n=e.errorCode,i=e.isLoading,o=e.selectedAccount,s=e.selectedContainer,r=e.selectedContainerAMP;return!(i||"tag_manager_existing_tag_permission"===n||!Object(M.b)(o))&&(!!(t&&!a||Object(M.c)(s)||"container_create"===s)&&!(t&&!Object(M.c)(r)&&"container_create"!==r))}},{key:"renderCreateAccount",value:function(){return n.createElement("div",{className:"googlesitekit-setup-module__action"},n.createElement(y.a,{onClick:TagmanagerSetup.createNewAccount},Object(T.__)("Create an account","google-site-kit")),n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(v.a,{onClick:this.refetchAccount},Object(T.__)("Re-fetch My Account","google-site-kit"))))}},{key:"renderErrorOrNotice",value:function(){var e=this.state,t=e.errorCode,a=e.errorMsg,i=this.props.onSettingsPage;if(0===a.length)return null;var o=!i||"insufficientPermissions"!==t;return n.createElement("div",{className:P()({"googlesitekit-error-text":o})},n.createElement("p",null,o
|
17 |
-
/* translators: %s: Error message */?Object(T.sprintf)(Object(T.__)("Error: %s","google-site-kit"),a):a))}},{key:"render",value:function(){var e=this.props,t=e.onSettingsPage,a=e.isEditing;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--tag-manager"},!t&&n.createElement(L.Fragment,null,n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(D.a,{id:"tagmanager",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(T._x)("Tag Manager","Service name","google-site-kit"))),this.renderErrorOrNotice(),a&&this.renderAccountDropdownForm(),!a&&this.renderSettingsInfo())}}],[{key:"createNewAccount",value:function(t){t.preventDefault(),e.open("https://tagmanager.google.com/#/admin/accounts/create","_blank")}}]),TagmanagerSetup}(L.Component);U.propTypes={onSettingsPage:w.a.bool,finishSetup:w.a.func,isEditing:w.a.bool},U.defaultProps={onSettingsPage:!0,isEditing:!1},t.a=U}).call(this,a(15),a(1))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(16),g=a.n(u),m=a(9),p=a.n(m),h=a(25),b=a(0),_=a(1),f=a(12),k=function(t){function DateRangeSelector(e){var t;return i()(this,DateRangeSelector),(t=l()(this,d()(DateRangeSelector).call(this,e))).dateRangeHook="googlesitekit.dateRange",t.dateRangeHandlerHook="googlesitekit.dateRageHandler",t.dateRangeHookAddedHook="googlesitekit.dateRageHookAddedHandler",t.state={context:"Dashboard",dateValue:Object(f.c)(t.dateRangeHook,"last-28-days")},Object(f.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingDataForDateRangeSelector",(function(e){t.setState({context:e}),Object(f.e)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingDataForDateRangeSelector")})),t.handleSelection=t.handleSelection.bind(g()(t)),t}return p()(DateRangeSelector,t),s()(DateRangeSelector,[{key:"componentDidMount",value:function(){var e=this;Object(f.a)("hookAdded",this.dateRangeHookAddedHook,(function(t){e.dateRangeHook===t&&e.forceUpdate()}))}},{key:"componentWillUnmount",value:function(){Object(f.e)("hookAdded",this.dateRangeHookAddedHook)}},{key:"handleSelection",value:function(e,t){var a=this.state.context,n=t.getAttribute("data-value");return Object(f.f)(this.dateRangeHook,this.dateRangeHandlerHook),Object(f.b)(this.dateRangeHook,this.dateRangeHandlerHook,(function(){return n})),Object(f.d)("googlesitekit.moduleDataReset"),Object(f.d)("googlesitekit.moduleLoaded",a),this.setState({dateValue:Object(f.c)(this.dateRangeHook,"last-28-days")}),!1}},{key:"render",value:function(){var t=this.state.dateValue,a={"last-7-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",7,"google-site-kit"),7),"last-14-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",14,"google-site-kit"),14),"last-28-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",28,"google-site-kit"),28),"last-90-days":Object(b.sprintf)(Object(b._n)("Last %s day","Last %s days",90,"google-site-kit"),90)};return e.createElement(h.k,{enhanced:!0,className:"mdc-select--minimal",name:"time_period",label:"",onEnhancedChange:this.handleSelection,value:t},Object.keys(a).map((function(t){return e.createElement(h.j,{key:t,value:t},a[t])})))}}]),DateRangeSelector}(_.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(1),p=function(t){function Spinner(){return i()(this,Spinner),l()(this,d()(Spinner).apply(this,arguments))}return g()(Spinner,t),s()(Spinner,[{key:"render",value:function(){var t=this.props.isSaving;return e.createElement("span",{className:"spinner",style:{display:t?"inline-block":"none",float:"none",marginTop:"0",visibility:"visible"}})}}]),Spinner}(m.Component);t.a=p}).call(this,a(1))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(66),k=a(62),y=a(21),v=a(14),S=a.n(v),O=a(1),E=a(0),j=a(195),D=a(198),C=a(82),w=a(199),A=a(56),x=a(47),N=a(32),P=a(98),T=a(46),L=a(68),I=a(99),M=a(65),W=function(t){function AdSenseDashboardWidget(e){var t;return r()(this,AdSenseDashboardWidget),(t=u()(this,m()(AdSenseDashboardWidget).call(this,e))).state={receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0,zeroData:!1,instructionProps:{}},t.handleDataError=t.handleDataError.bind(h()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(h()(t)),t.handleZeroData=t.handleZeroData.bind(h()(t)),t}return _()(AdSenseDashboardWidget,t),c()(AdSenseDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.a.awrap(Object(T.b)());case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),null,this)}},{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleZeroData",value:function(){var e=Object(T.d)("account-connected-no-data");this.setState({zeroData:!0,loading:!1,instructionProps:e})}},{key:"render",value:function(){var t=this,a=this.state,i=a.receivingData,o=a.error,s=a.loading,r=a.isAdSenseConnected,l=a.zeroData,c=a.instructionProps,d=e.googlesitekit.modules.adsense.homepage,u=s||!i||l?"googlesitekit-nodata":"";return n.createElement(O.Fragment,null,n.createElement(f.a,null),n.createElement("div",{className:u},n.createElement(C.a,{module:"adsense"})),n.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--adsense"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},!o&&e.googlesitekit.modules.adsense.setupComplete?n.createElement(k.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")}):n.createElement(k.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")}),s&&n.createElement(N.a,null)),l&&n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(y.a,{fill:!0},n.createElement("div",{className:"mdc-layout-grid mdc-layout-grid--fill"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(I.a,{ctaLink:c.ctaLink,ctaLinkText:c.ctaLinkText,header:c.statusHeadline,subHeader:c.statusMessage,incomplete:c.incomplete,required:c.required})))))),!i&&(o?Object(x.a)(Object(E._x)("AdSense","Service name","google-site-kit"),o,!0,!0,!0):Object(A.a)(Object(E._x)("AdSense","Service name","google-site-kit"),!0,!0,!0)),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},n.createElement(L.a,{slug:"adsense",context:"module-dashboard"}),n.createElement(y.a,{header:!0,title:Object(E.__)("Estimated earnings","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:d},n.createElement(j.a,{handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}))),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},n.createElement(y.a,{header:!0,title:Object(E.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(E.__)("Advanced Settings","google-site-kit"),headerCtaLink:d},n.createElement(D.a,{handleDataError:function(e){e||t.handleZeroData()}}))),n.createElement("div",{className:S()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",u)},n.createElement(w.a,null)),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},n.createElement(M.a,null))))),!r&&n.createElement(P.a,null))}}]),AdSenseDashboardWidget}(O.Component);t.a=W}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(26),p=a(27),h=a(3),b=a(20),_=a(10),f=a(46),k=a(0),y=a(1),v=function(t){function AdSenseEstimateEarningsWidget(e){var t;return i()(this,AdSenseEstimateEarningsWidget),(t=l()(this,d()(AdSenseEstimateEarningsWidget).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 g()(AdSenseEstimateEarningsWidget,t),s()(AdSenseEstimateEarningsWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var e=this.state,t=e.today,a=e.yesterday,n=e.sevenDays,i=e.month,o=e.twentyEightDays,s=e.sameDayLastWeek,r=e.prev7Days,l=e.monthLastYear,c=e.prev28Days;if(!(t&&a&&n&&i&&o&&s&&r&&l&&c))return null;var d=t.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),u=!!d&&d.currency,g=t.totals?[{className:"googlesitekit-data-block--today",title:Object(k.__)("Today so far","google-site-kit"),datapoint:Object(h.u)(t.totals[0],u)},{className:"googlesitekit-data-block--yesterday",title:Object(k.__)("Yesterday","google-site-kit"),datapoint:Object(h.u)(a.totals[0],u),change:s.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--7days",title:Object(k.__)("Last 7 days","google-site-kit"),datapoint:Object(h.u)(n.totals[0],u),change:r.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--month",title:Object(k.__)("This month","google-site-kit"),datapoint:Object(h.u)(i.totals[0],u),change:l.totals[0],changeDataUnit:"%"},{className:"googlesitekit-data-block--28days",title:Object(k.__)("Last 28 days","google-site-kit"),datapoint:Object(h.u)(o.totals[0],u),change:c.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,a){return e.createElement("div",{key:a,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:a,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=[],a=0;5>a;a++)t.push(e.createElement("div",{key:a,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(p.a,{width:"100%",height:"104px"})));return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},t))}}]),AdSenseEstimateEarningsWidget}(y.Component);t.a=Object(b.a)(v,[{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.today)return{today:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"yesterday"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.yesterday)return{yesterday:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"same-day-last-week"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.sameDayLastWeek)return{sameDayLastWeek:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-7-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.sevenDays)return{sevenDays:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-7-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev7Days)return{prev7Days:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.month)return{month:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month-last-year"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.monthLastYear)return{monthLastYear:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.twentyEightDays)return{twentyEightDays:a}}},{type:_.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(h.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev28Days)return{prev28Days:a}}}],v.renderPreviews(),{createGrid:!0},f.c)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(31),h=a(1),b=a(0),_=function(t){function InvalidCredentialsWarning(){return o()(this,InvalidCredentialsWarning),c()(this,u()(InvalidCredentialsWarning).apply(this,arguments))}return m()(InvalidCredentialsWarning,t),r()(InvalidCredentialsWarning,[{key:"render",value:function(){return e.createElement(p.a,{id:"notification-id",title:Object(b.__)("Security Token Error","google-site-kit"),description:Object(b.__)("We’re unable to retrieve your data because your security token is expired or revoked. Please ","google-site-kit"),learnMoreURL:n.googlesitekit.admin.connectURL,learnMoreLabel:Object(b.__)("reauthenticate your account","google-site-kit"),format:"small",type:"win-error"})}}]),InvalidCredentialsWarning}(h.Component);t.a=_}).call(this,a(1),a(15))},,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(10),p=a(26),h=a(27),b=a(3),_=a(46),f=a(20),k=a(0),y=a(1),v=a(13),S=function(t){function AdSensePerformanceWidget(e){var t;return i()(this,AdSensePerformanceWidget),(t=l()(this,d()(AdSensePerformanceWidget).call(this,e))).state={twentyEightDays:!1,prev28Days:!1},t}return g()(AdSensePerformanceWidget,t),s()(AdSensePerformanceWidget,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.twentyEightDays,n=t.prev28Days,i=a.totals?[{className:"googlesitekit-data-block--page-rpm",title:Object(k.__)("Page RPM","google-site-kit"),datapoint:Object(b.u)(a.totals[1]),change:Object(v.isUndefined)(n.totals)?0:n.totals[1],changeDataUnit:"%"},{className:"googlesitekit-data-block--impression",title:Object(k.__)("Impressions","google-site-kit"),datapoint:Object(b.u)(a.totals[2]),change:Object(v.isUndefined)(n.totals)?0:n.totals[2],changeDataUnit:"%"}]:[];return e.createElement("section",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},i.map((function(t,a){return e.createElement("div",{key:a,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(p.a,{stat:a,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}(y.Component);t.a=Object(f.a)(S,[{type:m.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"last-28-days"},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.twentyEightDays)return{twentyEightDays:a}}},{type:m.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"prev-28-days"},priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"],toState:function(e,t){var a=t.data;if(!e.prev28Days)return{prev28Days:a}}}],e.createElement(h.a,{width:"100%",height:"250px"}),{},_.c)}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function DashboardAdSenseTopPages(){return i()(this,DashboardAdSenseTopPages),l()(this,d()(DashboardAdSenseTopPages).apply(this,arguments))}return g()(DashboardAdSenseTopPages,e),s()(DashboardAdSenseTopPages,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopPages}(p.Component);t.a=Object(m.a)("googlesitekit.AnalyticsAdSenseTopPagesTable")(h)},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(44),p=a(201),h=a(202),b=a(68),_=a(1),f=a(0),k=function(t){function DashboardEarnings(){return i()(this,DashboardEarnings),l()(this,d()(DashboardEarnings).apply(this,arguments))}return g()(DashboardEarnings,t),s()(DashboardEarnings,[{key:"render",value:function(){return e.createElement(_.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(f.__)("Earnings","google-site-kit"),description:Object(f.__)("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(h.a,null),e.createElement(p.a,null))}}]),DashboardEarnings}(_.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function DashboardAdSenseTopEarningPagesSmall(){return i()(this,DashboardAdSenseTopEarningPagesSmall),l()(this,d()(DashboardAdSenseTopEarningPagesSmall).apply(this,arguments))}return g()(DashboardAdSenseTopEarningPagesSmall,e),s()(DashboardAdSenseTopEarningPagesSmall,[{key:"render",value:function(){return null}}]),DashboardAdSenseTopEarningPagesSmall}(p.Component);t.a=Object(m.a)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall")(h)},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(20),p=a(10),h=a(27),b=a(3),_=a(26),f=a(54),k=a(0),y=a(1),v=a(46),S=a(21),O=function(t){function AdSenseDashboardMainSummary(e){var t;return i()(this,AdSenseDashboardMainSummary),(t=l()(this,d()(AdSenseDashboardMainSummary).call(this,e))).state={today:!1,period:!1,daily:!1},t}return g()(AdSenseDashboardMainSummary,t),s()(AdSenseDashboardMainSummary,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.today,n=t.period,i=t.daily;if(!(a&&n&&i&&n.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(S.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(h.a,{width:"100%",height:"276px",padding:!0})));var o=Object(v.e)(i.rows),s=Object(b.n)("googlesitekit-module-adsense",{}),r=n.headers.find((function(e){return null!==e.currency&&0<e.currency.length})),l=!!r&&r.currency;return e.createElement(y.Fragment,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(S.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(_.a,{className:"overview-adsense-rpm",title:Object(k.__)("RPM","google-site-kit"),datapoint:Object(b.u)(n.totals[1],l),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,2),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{className:"overview-adsense-earnings",title:Object(k.__)("Total Earnings","google-site-kit"),datapoint:Object(b.u)(n.totals[0],l),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},change:a.totals[0],changeDataUnit:"$",sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,1),change:1,loadSmall:!1}),context:"compact"})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(_.a,{className:"overview-adsense-impressions",title:Object(k.__)("Ad Impressions","google-site-kit"),datapoint:Object(b.u)(n.totals[2]),source:{name:Object(k._x)("AdSense","Service name","google-site-kit"),link:s},sparkline:i&&e.createElement(f.a,{data:Object(b.e)(o.dataMap,3),change:1,loadSmall:!1}),context:"compact"})))))))}}]),AdSenseDashboardMainSummary}(y.Component);t.a=Object(m.a)(O,[{type:p.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"today"},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.today)return{today:a}}},{type:p.b,identifier:"adsense",datapoint:"earnings",data:{},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.period)return{period:a}}},{type:p.b,identifier:"adsense",datapoint:"earnings",data:{dateRange:"this-month",dimensions:["DATE"]},priority:1,maxAge:Object(b.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.daily)return{daily:a}}}],e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},e.createElement(S.a,{className:"googlesitekit-dashboard-adsense-stats",fill:!0},e.createElement(h.a,{width:"100%",height:"276px",padding:!0}))),{inGrid:!0,createGrid:!0},v.c)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(64),o=a.n(i),s=a(22),r=a.n(s),l=a(11),c=a.n(l),d=a(5),u=a.n(d),g=a(6),m=a.n(g),p=a(7),h=a.n(p),b=a(8),_=a.n(b),f=a(9),k=a.n(f),y=a(2),v=a.n(y),S=a(24),O=a(1),E=a(0),j=a(204),D=a(99),C=a(3),w=a(46);function A(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function x(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?A(a,!0).forEach((function(t){r()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):A(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var N=function(t){function AdSenseModuleStatus(e){var t;return u()(this,AdSenseModuleStatus),(t=h()(this,_()(AdSenseModuleStatus).call(this,e))).state={accountStatus:void 0,loadingMessage:Object(E.__)("Loading…","google-site-kit"),instructionProps:{}},t}return k()(AdSenseModuleStatus,t),m()(AdSenseModuleStatus,[{key:"componentDidMount",value:function(){return c.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,c.a.awrap(this.updateAccountStatus());case 2:case"end":return e.stop()}}),null,this)}},{key:"componentDidUpdate",value:function(e,t){var a=this.state.accountStatus;if(t.accountStatus!==a){var n=Object(w.d)(a);this.setState({instructionProps:n})}}},{key:"continueSetup",value:function(e){var t=this.state.instructionProps;e.existingState=x({},t),this.setState({instructionProps:e})}},{key:"goBack",value:function(){var e=x({},this.state.instructionProps).existingState;e&&(e.existingState=!1,this.setState({instructionProps:e}))}},{key:"updateAccountStatus",value:function(){var e,t,a,n,i,o=this;return c.a.async((function(s){for(;;)switch(s.prev=s.next){case 0:return s.next=2,c.a.awrap(Object(C.j)("adsense"));case 2:return e=s.sent,t=function(e){o.setState({loadingMessage:e})},s.next=6,c.a.awrap(Object(w.a)(e,t));case 6:a=s.sent,n=a.accountStatus,i=a.clientID,this.setState({accountStatus:n,clientID:i});case 10:case"end":return s.stop()}}),null,this)}},{key:"render",value:function(){var t=this.state,a=t.accountStatus,i=t.clientID,s=t.loadingMessage,r=t.instructionProps,l=!a||!e.googlesitekit.modules.adsense.setupComplete||["ads-display-pending","account-pending-review","account-required-action"].includes(a);return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},n.createElement("div",{className:"googlesitekit-setup-module__step"},n.createElement("div",{className:"googlesitekit-setup-module__logo"},n.createElement(S.a,{id:"adsense",width:"33",height:"33"})),n.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(E._x)("AdSense","Service name","google-site-kit"))),n.createElement("div",{className:"googlesitekit-setup-module__step"},!e.googlesitekit.canAdsRun&&!e.googlesitekit.modules.adsense.setupComplete&&n.createElement("div",{className:"googlesitekit-settings-module-warning"},n.createElement(S.a,{id:"error",height:"20",width:"23"}),Object(E.__)("Ad blocker detected, you need to disable it in order to setup AdSense.","google-site-kit")),l&&"account-connected"!==a&&n.createElement(D.a,{ctaLink:r.ctaLink,ctaLinkText:r.ctaLinkText,header:r.statusHeadline,subHeader:r.statusMessage,incomplete:r.incomplete,required:r.required,loadingMessage:!a&&s}),e.googlesitekit.canAdsRun&&a&&(e.googlesitekit.modules.adsense.setupComplete||"account-connected"===a)&&n.createElement(j.a,o()({},r,{accountStatus:a,clientID:i,continueSetup:this.continueSetup,goBack:this.goBack}))))}}]),AdSenseModuleStatus}(O.Component);N.propTypes={status:v.a.string,module:v.a.string},t.a=N}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(24),h=a(19),b=a(33),_=a(100),f=a(10),k=a(147),y=a(1),v=a(3),S=a(0),O=function(t){function AdSenseSetupInstructions(e){var t;return o()(this,AdSenseSetupInstructions),(t=c()(this,u()(AdSenseSetupInstructions).call(this,e))).state={isSaving:!1},t}return m()(AdSenseSetupInstructions,t),r()(AdSenseSetupInstructions,[{key:"render",value:function(){var t=this,a=this.props,i=a.error,o=a.message,s=a.issue,r=a.notice,l=a.statusHeadline,c=a.statusMessage,d=a.profile,u=a.ctaLinkText,g=a.ctaLink,m=a.footerText,O=a.footerAppendedText,E=a.footerCTA,j=a.footerCTALink,D=a.continueAction,C=a.continueSetup,w=a.accountStatus,A=a.accountTagMatch,x=a.clientID,N=a.existingTag,P=a.switchLabel,T=a.tracking,L=a.switchOffMessage,I=a.switchOnMessage,M=a.goBack,W=a.existingState,R=this.state.isSaving,U=e.googlesitekit.admin.userData,F=U.email,z=void 0===F?"":F,H=U.picture,G=void 0===H?"":H;return n.createElement("div",{className:"googlesitekit-setup-module googlesitekit-setup-module--adsense"},n.createElement("div",{className:"googlesitekit-setup-module__step"},s&&n.createElement("p",{className:"googlesitekit-setup__notice"},n.createElement(p.a,{id:"error",height:"20",width:"23"}),n.createElement("span",{className:"googlesitekit-setup__notice-text"},s)),n.createElement("h2",{className:" googlesitekit-heading-4 googlesitekit-setup-module__title "},l),n.createElement("p",null,c),d&&n.createElement("p",{className:"googlesitekit-setup-module__user"},G&&n.createElement("img",{className:"googlesitekit-setup-module__user-image",src:G,alt:Object(S.__)("User Avatar","google-site-kit")}),n.createElement("span",{className:"googlesitekit-setup-module__user-email"},z)),"account-connected"===w&&n.createElement(_.a,{isEditing:!0,accountTagMatch:A,existingTag:N,saveOnChange:!0,switchLabel:P,switchOffMessage:L,switchOnMessage:I}),r&&n.createElement("div",{className:"googlesitekit-settings-notice"},n.createElement("div",{className:"googlesitekit-settings-notice__text"},r)),i&&0<o.length&&n.createElement("div",{className:"googlesitekit-error-text"},n.createElement("p",null,Object(S.__)("Error:","google-site-kit")," ",o)),n.createElement("div",{className:"googlesitekit-setup-module__action"},"account-connected"===w&&n.createElement(y.Fragment,null,n.createElement(b.a,{disabled:R,onClick:function(){T&&Object(v.A)(T.eventCategory,T.eventName),t.setState({isSaving:!0});var e=document.getElementById("enableAutoAds"),a=e&&e.checked;f.c.set(f.b,"adsense","setup-complete",{clientID:x,useSnippet:a}).then((function(){document.location=g})).catch((function(){t.setState({isSaving:!1})}))}},u),n.createElement(k.a,{isSaving:R})),"account-connected"!==w&&n.createElement(h.a,{className:"googlesitekit-setup-module__cta-link",external:!0,inherit:!0,href:g},u),D&&n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(h.a,{inherit:!0,onClick:function(){C(D)}},D.continueText)),W&&n.createElement("div",{className:"googlesitekit-setup-module__sub-action"},n.createElement(h.a,{inherit:!0,onClick:function(){M()}},Object(S.__)("Back","google-site-kit")))),m&&n.createElement("p",{className:"googlesitekit-setup-module__footer-text"},m," ",E&&n.createElement(h.a,{href:j,inherit:!0,external:!0},E)," ",O)))}}]),AdSenseSetupInstructions}(y.Component);t.a=O}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(3),h=a(19),b=a(1),_=a(0),f=function(t){function AdSenseSettingsStatus(){return o()(this,AdSenseSettingsStatus),c()(this,u()(AdSenseSettingsStatus).apply(this,arguments))}return m()(AdSenseSettingsStatus,t),r()(AdSenseSettingsStatus,[{key:"render",value:function(){var t=this.props,a=t.slug,i=t.screenID,o=t.OriginalComponent,s=e.googlesitekit.modules.adsense.settings.accountStatus;return s&&"adsense"===a&&("account-pending-review"===s||"ads-display-pending"===s)?n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},Object(_.__)("Site Kit has placed the code on your site, ","google-site-kit"),n.createElement(h.a,{className:"googlesitekit-settings-module__edit-button",onClick:function(){var t=i||"googlesitekit-dashboard";e.location=Object(p.n)(t,{reAuth:!0,slug:a})},inherit:!0},Object(_.__)("check module page","google-site-kit"))):n.createElement(o,this.props)}}]),AdSenseSettingsStatus}(b.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(14),h=a.n(p),b=a(24),_=a(1),f=a(0),k=function(t){function AdSenseSettingsWarning(){return o()(this,AdSenseSettingsWarning),c()(this,u()(AdSenseSettingsWarning).apply(this,arguments))}return m()(AdSenseSettingsWarning,t),r()(AdSenseSettingsWarning,[{key:"render",value:function(){var t=this.props,a=t.slug,i=t.context,o=t.OriginalComponent;if("adsense"!==a)return e.createElement(o,this.props);var s=n.googlesitekit.modules.adsense,r=s.active,l=s.setupComplete,c=Object(f.__)("Ad blocker detected, you need to disable it in order to setup AdSense.","google-site-kit");return r&&l&&(c=Object(f.__)("Ad blocker detected, You need to disable it to get the AdSense latest data.","google-site-kit")),n.googlesitekit.canAdsRun?e.createElement(o,this.props):e.createElement("div",{className:h()("googlesitekit-settings-module-warning","googlesitekit-settings-module-warning--".concat(i))},e.createElement(b.a,{id:"error",height:"20",width:"23"})," ",c)}}]),AdSenseSettingsWarning}(_.Component);t.a=k}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(11),i=a.n(n),o=a(5),s=a.n(o),r=a(6),l=a.n(r),c=a(7),d=a.n(c),u=a(8),g=a.n(u),m=a(16),p=a.n(m),h=a(9),b=a.n(h),_=a(66),f=a(14),k=a.n(f),y=a(1),v=a(0),S=a(208),O=a(209),E=a(210),j=a(101),D=a(21),C=a(62),w=a(83),A=a(82),x=a(32),N=a(56),P=a(47),T=a(98),L=a(46),I=a(3),M=a(65),W=function(t){function AnalyticsDashboardWidget(e){var t;return s()(this,AnalyticsDashboardWidget),(t=d()(this,g()(AnalyticsDashboardWidget).call(this,e))).state={selectedStats:[0],receivingData:!0,error:!1,loading:!0,isAdSenseConnected:!0},t.handleStatSelection=t.handleStatSelection.bind(p()(t)),t.buildSeries=t.buildSeries.bind(p()(t)),t.handleDataError=t.handleDataError.bind(p()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(p()(t)),t}return b()(AnalyticsDashboardWidget,t),l()(AnalyticsDashboardWidget,[{key:"componentDidMount",value:function(){this.isAdSenseConnected()}},{key:"isAdSenseConnected",value:function(){return i.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,i.a.awrap(Object(L.b)());case 2:e.sent?this.setState({isAdSenseConnected:!0}):this.setState({isAdSenseConnected:!1});case 4:case"end":return e.stop()}}),null,this)}},{key:"handleStatSelection",value:function(e){this.setState({selectedStats:[e]})}},{key:"handleDataError",value:function(e){this.setState({receivingData:!1,loading:!1,error:e})}},{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,a=t.selectedStats,n=t.error,i=t.receivingData,o=t.loading,s=t.isAdSenseConnected,r=this.buildSeries(),l=!o&&i?"":"googlesitekit-nodata",c=Object(I.g)();return e.createElement(y.Fragment,null,e.createElement(_.a,null),e.createElement(A.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(C.a,{title:Object(v._x)("Analytics","Service name","google-site-kit"),icon:!0,iconWidth:"24",iconHeight:"26",iconID:"analytics",status:"connected",statusText:Object(v.__)("Analytics is connected","google-site-kit")}),o&&e.createElement(x.a,null)),!i&&(n?Object(P.a)(Object(v._x)("Analytics","Service name","google-site-kit"),n,!0,!0,!0):Object(N.a)(Object(v._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",l)},e.createElement(D.a,{header:!0
|
18 |
-
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Audience overview for the last %s","google-site-kit"),c),headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),headerCtaLink:"http://analytics.google.com"},e.createElement(E.a,{selectedStats:a,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),e.createElement(S.a,{selectedStats:a,series:r,vAxes:null,dateRangeSlug:Object(I.h)()}))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",l)},e.createElement(D.a,{header:!0,footer:!0
|
19 |
-
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Top content over the last %s","google-site-kit"),c),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(v._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"https://analytics.google.com"},e.createElement(O.a,null))),e.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",l)},e.createElement(D.a,{header:!0,footer:!0
|
20 |
-
/* translators: %s: date range */,title:Object(v.sprintf)(Object(v.__)("Top acquisition sources over the last %s","google-site-kit"),c),headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(v.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(v._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(w.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(j.a,null)))))),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},e.createElement(M.a,null))))),!o&&!s&&e.createElement(T.a,null))}}]),AnalyticsDashboardWidget}(y.Component);t.a=W}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(57),_=a(3),f=a(20),k=a(10),y=a(18),v=a(27),S=a(0),O=a(1),E=function(t){function AnalyticsDashboardWidgetSiteStats(e){var t;return o()(this,AnalyticsDashboardWidgetSiteStats),(t=c()(this,u()(AnalyticsDashboardWidgetSiteStats).call(this,e))).setOptions=t.setOptions.bind(m()(t)),t}return h()(AnalyticsDashboardWidgetSiteStats,t),r()(AnalyticsDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,a=t.series,n=t.vAxes,i={chart:{title:""===e.googlesitekit.pageTitle?"":Object(S.__)("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 i.series=a,i.vAxes=n,i}},{key:"render",value:function(){var e=this.props,t=e.data,a=e.selectedStats,i=e.dateRangeSlug;if(!t||!t.length)return null;var o=i?i.match(/\d+/).map(Number)[0]:28,s=Object(y.c)(t,a,o);if(!s)return null;var r=this.setOptions();return n.createElement("section",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(b.a,{selectedStats:a,data:s,options:r}))))}}]),AnalyticsDashboardWidgetSiteStats}(O.Component);t.a=Object(f.a)(E,[{type:k.b,identifier:"analytics",datapoint:"report",data:y.j,priority:1,maxAge:Object(_.p)("day"),context:"Single"}],n.createElement(v.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(14),_=a.n(b),f=a(20),k=a(10),y=a(3),v=a(29),S=a(39),O=a(13),E=a(2),j=a.n(E),D=a(0),C=a(1),w=a(18),A=function(t){function AnalyticsDashboardWidgetTopPagesTable(){return r()(this,AnalyticsDashboardWidgetTopPagesTable),u()(this,m()(AnalyticsDashboardWidgetTopPagesTable).apply(this,arguments))}return h()(AnalyticsDashboardWidgetTopPagesTable,t),c()(AnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.colspan;if(!a||!a.length)return null;var i=[{title:Object(D.__)("Title","google-site-kit"),tooltip:Object(D.__)("Page Title","google-site-kit"),primary:!0},{title:Object(D.__)("Pageviews","google-site-kit"),tooltip:Object(D.__)("Pageviews","google-site-kit")},{title:Object(D.__)("Unique Pageviews","google-site-kit"),tooltip:Object(D.__)("Unique Pageviews","google-site-kit")},{title:Object(D.__)("Bounce Rate","google-site-kit"),tooltip:Object(D.__)("Bounce Rate","google-site-kit")}],s=[],r=Object(O.map)(a[0].data.rows,(function(t,a){var n=Number(t.metrics[0].values[2]),i=o()(t.dimensions,2),r=i[0],l=i[1];return s[a]=AnalyticsDashboardWidgetTopPagesTable.addDeepLink(l),[r,Object(y.s)(t.metrics[0].values[0]),Object(y.s)(t.metrics[0].values[1]),e.createElement(C.Fragment,{key:"minichart-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(n.toFixed(2),"%")))]})),l={hideHeader:!1,chartsEnabled:!1,links:s},c=Object(v.b)(r,i,l);return e.createElement("div",{className:_()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(n))},e.createElement(v.a,null,c))}}],[{key:"addDeepLink",value:function(e){var t=n.googlesitekit.modules.analytics.settings,a=t.accountID,i=t.internalWebPropertyID,o=t.profileID;return a?"https://analytics.google.com/analytics/web/#/report/content-drilldown/a".concat(a,"w").concat(i,"p").concat(o,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:").concat(encodeURIComponent(e.replace(/\//g,"~2F"))):"https://analytics.google.com/analytics/web/"}}]),AnalyticsDashboardWidgetTopPagesTable}(C.Component);A.propTypes={data:j.a.array,colspan:j.a.number},A.defaultProps={data:null,colspan:12},t.a=Object(f.a)(A,[{type:k.b,identifier:"analytics",datapoint:"report",data:Object(w.g)(),priority:1,maxAge:Object(y.p)("day"),context:["Single","Dashboard"]}],e.createElement(S.a,{padding:!0}),{createGrid:!0})}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(26),p=a(20),h=a(10),b=a(3),_=a(18),f=a(27),k=a(2),y=a.n(k),v=a(0),S=a(1),O=function(t){function AnalyticsDashboardWidgetOverview(){return i()(this,AnalyticsDashboardWidgetOverview),l()(this,d()(AnalyticsDashboardWidgetOverview).apply(this,arguments))}return g()(AnalyticsDashboardWidgetOverview,t),s()(AnalyticsDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.selectedStats,i=t.handleStatSelection;if(!a||!a.length)return null;var o=Object(_.b)(a);if(!o)return null;var s=o.totalUsers,r=o.totalSessions,l=o.averageBounceRate,c=o.averageSessionDuration,d=o.totalUsersChange,u=o.totalSessionsChange,g=o.averageBounceRateChange,p=o.averageSessionDurationChange,h=[{className:"googlesitekit-data-block--users googlesitekit-data-block--button-1",title:Object(v.__)("Users","google-site-kit"),datapoint:Object(b.u)(s),change:d,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:i},{className:"googlesitekit-data-block--sessions googlesitekit-data-block--button-2",title:Object(v.__)("Sessions","google-site-kit"),datapoint:Object(b.u)(r),change:u,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:i},{className:"googlesitekit-data-block--bounce googlesitekit-data-block--button-3",title:Object(v.__)("Bounce Rate","google-site-kit"),datapoint:Number(l).toFixed(2),change:g,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:i,datapointUnit:"%",invertChangeColor:!0},{className:"googlesitekit-data-block--duration googlesitekit-data-block--button-4",title:Object(v.__)("Session Duration","google-site-kit"),datapoint:Object(b.t)(c),change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:i}];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,a){return e.createElement("div",{key:a,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:a,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}(S.Component);O.propTypes={handleDataError:y.a.func.isRequired},t.a=Object(p.a)(O,[{type:h.b,identifier:"analytics",datapoint:"report",data:_.i,priority:1,maxAge:Object(b.p)("day"),context:["Single","Dashboard"]}],e.createElement(f.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},_.h,_.f)}).call(this,a(1))},function(e,t,a){"use strict";a.d(t,"a",(function(){return n}));var n=["#178EC5","#54B23B","#EB5729","#ECED33","#34CBE3","#82E88E"]},function(e,t,a){"use strict";(function(e,n){var i=a(41),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(213),_=a(77),f=a(1),k=function(t){function AnalyticsAdminbarWidget(){return r()(this,AnalyticsAdminbarWidget),u()(this,m()(AnalyticsAdminbarWidget).apply(this,arguments))}return h()(AnalyticsAdminbarWidget,t),c()(AnalyticsAdminbarWidget,[{key:"render",value:function(){return"undefined"!==o()(e.googlesitekit.permaLink)&&""===e.googlesitekit.permaLink?null:e.googlesitekit.modules.analytics.active?n.createElement(b.a,null):n.createElement(f.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-4-tablet mdc-layout-grid__cell--span-6-desktop "},n.createElement(_.a,null)))}}]),AnalyticsAdminbarWidget}(f.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(26),_=a(20),f=a(10),k=a(3),y=a(18),v=a(27),S=a(0),O=a(1);function E(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var j=function(t){function AnalyticsAdminbarWidgetOverview(){return r()(this,AnalyticsAdminbarWidgetOverview),u()(this,m()(AnalyticsAdminbarWidgetOverview).apply(this,arguments))}return h()(AnalyticsAdminbarWidgetOverview,t),c()(AnalyticsAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error||!t.length)return null;var a=Object(y.b)(t);if(!a)return null;var n=a.totalUsers,i=a.totalSessions,o=a.totalUsersChange,s=a.totalSessionsChange;return e.createElement(O.Fragment,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(S.__)("Total Users","google-site-kit"),datapoint:Object(k.u)(n),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(b.a,{className:"overview-total-sessions",title:Object(S.__)("Total Sessions","google-site-kit"),datapoint:Object(k.u)(i),change:s,changeDataUnit:"%"})))}}]),AnalyticsAdminbarWidgetOverview}(O.Component);t.a=Object(_.a)(j,[{type:f.b,identifier:"analytics",datapoint:"report",data:function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?E(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):E(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({},y.i,{url:n.googlesitekit.permaLink}),priority:1,maxAge:Object(k.p)("day"),context:"Adminbar"}],e.createElement(O.Fragment,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,{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(v.a,{width:"auto",height:"59px"}))),{inGrid:!0},y.h,y.f)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(83),_=a(215),f=a(1),k=a(0),y=a(21),v=a(44),S=a(56),O=a(47),E=a(97),j=a(14),D=a.n(j),C=function(t){function AnalyticsAllTraffic(e){var t;return o()(this,AnalyticsAllTraffic),(t=c()(this,u()(AnalyticsAllTraffic).call(this,e))).state={receivingData:!0,error:!1},t.handleDataError=t.handleDataError.bind(m()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(m()(t)),t}return h()(AnalyticsAllTraffic,t),r()(AnalyticsAllTraffic,[{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0})}},{key:"getErrorDataComponent",value:function(){var t=e.googlesitekit.modules.analytics,a=t.active,n=t.setupComplete,i=this.state,o=i.error,s=i.receivingData;return a&&!n?Object(E.a)("analytics",!0,!0,!0):s?null:o?Object(O.a)(Object(k._x)("Analytics","Service name","google-site-kit"),o,!0,!0,!0):Object(S.a)(Object(k._x)("Analytics","Service name","google-site-kit"),!0,!0,!0)}},{key:"render",value:function(){var e=this.state,t=e.error,a=e.receivingData,i=t||!a?"googlesitekit-nodata":"";return n.createElement(f.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(v.a,{description:Object(k.__)("How people found your site.","google-site-kit"),title:Object(k.__)("All Traffic","google-site-kit")})),this.getErrorDataComponent(),n.createElement("div",{className:D()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",i)},n.createElement(y.a,{className:"googlesitekit-dashboard-all-traffic"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.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 "},n.createElement(b.a,{source:!0,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess})),n.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 "},n.createElement(_.a,null)))))))}}]),AnalyticsAllTraffic}(f.Component);t.a=C}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(20),p=a(10),h=a(3),b=a(29),_=a(102),f=a(39),k=a(13),y=a(0),v=a(1),S=a(18),O=function(t){function AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources(){return i()(this,AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources),l()(this,d()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources).apply(this,arguments))}return g()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,t),s()(AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(y.__)("Source","google-site-kit"),primary:!0},{title:Object(y.__)("Percent","google-site-kit")}],n=t[0].data.totals[0].values[0],i=Object(k.map)(t[0].data.rows,(function(t,a){var i=t.metrics[0].values[0]/n*100;return!(1>i)&&[t.dimensions[0],e.createElement(v.Fragment,{key:"minichart-"+a},e.createElement("div",{className:"googlesitekit-table__body-item-chart-wrap"},"".concat(i.toFixed(2),"%")," ",e.createElement(_.a,{percent:i.toFixed(1),index:a})))]})),o=Object(b.b)(i,a,{hideHeader:!0,chartsEnabled:!0});return e.createElement("div",{className:"googlesitekit-alltraffic-widget"},e.createElement(b.a,null,o))}}]),AnalyticsAllTrafficDashboardWidgetTopAcquisitionSources}(v.Component);t.a=Object(m.a)(O,[{type:p.b,identifier:"analytics",datapoint:"report",data:S.k,priority:1,maxAge:Object(h.p)("day"),context:"Dashboard"}],e.createElement(f.a,{rows:3,rowHeight:50}))}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(26),_=a(20),f=a(10),k=a(54),y=a(37),v=a(27),S=a(3),O=a(13),E=a(0),j=a(1),D=a(18);function C(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}function w(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?C(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):C(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}var A=function(t){function AnalyticsDashboardWidgetTopLevel(e){var t;return r()(this,AnalyticsDashboardWidgetTopLevel),(t=u()(this,m()(AnalyticsDashboardWidgetTopLevel).call(this,e))).state={accounts:!1,goals:!1},t}return h()(AnalyticsDashboardWidgetTopLevel,t),c()(AnalyticsDashboardWidgetTopLevel,[{key:"componentDidUpdate",value:function(){this.processCallbackData()}},{key:"componentDidMount",value:function(){this.processCallbackData()}},{key:"processCallbackData",value:function(){var e=this.props,t=e.data,a=e.requestDataToState;t&&!t.error&&"function"==typeof a&&this.setState(a)}},{key:"render",value:function(){var t=this.state,a=t.overview,i=t.extractedAnalytics,o=t.goals,s=e.googlesitekit.permaLink,r=Object(S.n)("googlesitekit-module-analytics",{}),l="",c="",d="",u="",g="",m="";return a&&(l=a.totalUsers,c=a.totalUsersChange,d=a.goalCompletions,u=a.goalCompletionsChange,g=a.averageBounceRate,m=a.averageBounceRateChange),n.createElement(j.Fragment,null,n.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 "},n.createElement(b.a,{className:"overview-total-users",title:Object(E.__)("Unique Visitors from Search","google-site-kit"),datapoint:Object(S.u)(l),change:c,changeDataUnit:"%",source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,1),change:c})})),n.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&&n.createElement(b.a,{className:"overview-bounce-rate",title:Object(E.__)("Bounce Rate","google-site-kit"),datapoint:Number(g).toFixed(2),datapointUnit:Object(E.__)("%","google-site-kit"),change:m,changeDataUnit:"%",invertChangeColor:!0,source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,2),change:m})}),!s&&o&&Object(O.isEmpty)(o.items)&&n.createElement(y.a,{title:Object(E.__)("Use goals to measure success.","google-site-kit"),description:Object(E.__)("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(E.__)("Create a new goal","google-site-kit")}),!s&&o&&!Object(O.isEmpty)(o.items)&&n.createElement(b.a,{className:"overview-goals-completed",title:Object(E.__)("Goals Completed","google-site-kit"),datapoint:Object(S.u)(d),change:u,changeDataUnit:"%",source:{name:Object(E._x)("Analytics","Service name","google-site-kit"),link:r},sparkline:i&&n.createElement(k.a,{data:Object(S.e)(i,3),change:u})}),!s&&!o&&n.createElement(v.a,{width:"100%",height:"202px"})))}}]),AnalyticsDashboardWidgetTopLevel}(j.Component);t.a=Object(_.a)(A,[{type:f.b,identifier:"analytics",datapoint:"report",data:w({},D.i,{url:e.googlesitekit.permaLink}),priority:1,maxAge:Object(S.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.overview)return{overview:Object(D.b)(a)}}},{type:f.b,identifier:"analytics",datapoint:"report",data:w({},D.j,{url:e.googlesitekit.permaLink}),priority:1,maxAge:Object(S.p)("day"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.extractedAnalytics)return{extractedAnalytics:Object(D.d)(a)}}},{type:f.b,identifier:"analytics",datapoint:"goals",data:{url:e.googlesitekit.permaLink},priority:1,maxAge:Object(S.p)("hour"),context:"Dashboard",toState:function(e,t){var a=t.data;if(!e.goals)return{goals:a}}}],n.createElement(j.Fragment,null,n.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 "},n.createElement(v.a,{width:"100%",height:"202px"})),n.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 "},n.createElement(v.a,{width:"100%",height:"202px"}))),{inGrid:!0},(function(e,t){return"report"===t&&Object(D.h)(e)}),D.f)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(103),p=a(26),h=a(37),b=a(20),_=a(10),f=a(3),k=a(18),y=a(0),v=a(1),S=function(t){function WPAnalyticsDashboardWidgetOverview(){return i()(this,WPAnalyticsDashboardWidgetOverview),l()(this,d()(WPAnalyticsDashboardWidgetOverview).apply(this,arguments))}return g()(WPAnalyticsDashboardWidgetOverview,t),s()(WPAnalyticsDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(k.b)(t);if(!a)return null;var n=a.totalUsers,i=a.averageSessionDuration,o=a.totalUsersChange,s=a.averageSessionDurationChange;return e.createElement(v.Fragment,null,t.length?e.createElement(v.Fragment,null,e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-users",title:Object(y.__)("Total Unique Visitors","google-site-kit"),datapoint:Object(f.u)(n),change:o,changeDataUnit:"%"}),e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-average-session-duration",title:Object(y.__)("Avg. Time on Page","google-site-kit"),datapoint:Object(f.t)(i),change:s,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(h.a,{title:Object(y.__)("Analytics Gathering Data","google-site-kit"),description:Object(y.__)("Analytics data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPAnalyticsDashboardWidgetOverview}(v.Component);t.a=Object(b.a)(S,[{type:_.b,identifier:"analytics",datapoint:"report",data:k.i,priority:1,maxAge:Object(f.p)("day"),context:["WPDashboard"]}],e.createElement(m.a,{width:"23%",height:"94px",count:2}),{},k.h,k.f)}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(44),p=a(21),h=a(1),b=a(0),_=a(101),f=a(83),k=function(t){function AnalyticsDashboardDetailsWidgetTopAcquisitionSources(){return i()(this,AnalyticsDashboardDetailsWidgetTopAcquisitionSources),l()(this,d()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources).apply(this,arguments))}return g()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,t),s()(AnalyticsDashboardDetailsWidgetTopAcquisitionSources,[{key:"render",value:function(){return e.createElement(h.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(m.a,{title:Object(b.__)("All Traffic","google-site-kit"),description:Object(b.__)("How people found your page.","google-site-kit")})),e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{className:"googlesitekit-analytics-acquisition-sources",footer:!0,headerCtaLink:"https://analytics.google.com",headerCtaLabel:Object(b.__)("See full stats in Analytics","google-site-kit"),footerCtaLabel:Object(b._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(f.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,null)))))))}}]),AnalyticsDashboardDetailsWidgetTopAcquisitionSources}(h.Component);t.a=k}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(39),v=a(13),S=a(0),O=a(1),E=a(18),j=function(t){function WPAnalyticsDashboardWidgetTopPagesTable(){return r()(this,WPAnalyticsDashboardWidgetTopPagesTable),u()(this,m()(WPAnalyticsDashboardWidgetTopPagesTable).apply(this,arguments))}return h()(WPAnalyticsDashboardWidgetTopPagesTable,t),c()(WPAnalyticsDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data,a=e.googlesitekit.admin.siteURL;if(Object(E.h)(t))return null;var i=[],s=Object(v.map)(t[0].data.rows,(function(e,t){var n=o()(e.dimensions,2),s=n[0],r=n[1];return i[t]=a+r,[s,Object(f.s)(e.metrics[0].values[0])]})),r=[{title:Object(S.__)("Title","google-site-kit"),tooltip:Object(S.__)("Page Title","google-site-kit"),primary:!0},{title:Object(S.__)("Pageviews","google-site-kit"),tooltip:Object(S.__)("Pageviews","google-site-kit")}],l={chartsEnabled:!0,links:i,cap:5,showURLs:!0},c=Object(k.b)(s,r,l);return n.createElement("div",{className:"googlesitekit-search-console-widget"},n.createElement("h2",{className:"googlesitekit-search-console-widget__title"},Object(S.__)("Top content over the last 28 days","google-site-kit")),n.createElement(k.a,null,c))}}]),WPAnalyticsDashboardWidgetTopPagesTable}(O.Component);t.a=Object(b.a)(j,[{type:_.b,identifier:"analytics",datapoint:"report",data:Object(E.g)(),priority:1,maxAge:Object(f.p)("day"),context:"WPDashboard"}],n.createElement(y.a,{rows:6}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(20),h=a(10),b=a(3),_=a(29),f=a(21),k=a(39),y=a(13),v=a(0),S=a(1),O=a(18),E=function(t){function AnalyticsAdSenseDashboardWidgetTopPagesTable(){return o()(this,AnalyticsAdSenseDashboardWidgetTopPagesTable),c()(this,u()(AnalyticsAdSenseDashboardWidgetTopPagesTable).apply(this,arguments))}return m()(AnalyticsAdSenseDashboardWidgetTopPagesTable,t),r()(AnalyticsAdSenseDashboardWidgetTopPagesTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Page Title","google-site-kit"),tooltip:Object(v.__)("Page Title","google-site-kit"),primary:!0},{title:Object(v.__)("Earnings","google-site-kit"),tooltip:Object(v.__)("Earnings","google-site-kit")},{title:Object(v.__)("Page RPM","google-site-kit"),tooltip:Object(v.__)("Page RPM","google-site-kit")},{title:Object(v.__)("Impressions","google-site-kit"),tooltip:Object(v.__)("Impressions","google-site-kit")}],i=Object(y.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(b.s)(e.metrics[0].values[2])]})),o=e.googlesitekit.modules.analytics.settings,s=o.accountID,r=o.internalWebPropertyID,l=o.profileID,c="https://analytics.google.com/analytics/web/?pli=1#/report/content-pages/a".concat(s,"w").concat(r,"p").concat(l,"/explorer-table.plotKeys=%5B%5D&_r.drilldown=analytics.pagePath:~2F"),d={hideHeader:!1,chartsEnabled:!1,links:Object(y.map)(t[0].data.rows,(function(e){var t=e.dimensions[1].replace(/\//g,"~2F");return c+t}))},u=Object(_.b)(i,a,d);return AnalyticsAdSenseDashboardWidgetTopPagesTable.renderLayout(n.createElement(_.a,null,u))}}],[{key:"renderLayout",value:function(t){var a=e.googlesitekit.modules.adsense.accountURL;return n.createElement(f.a,{header:!0,title:Object(v.__)("Performance over previous 28 days","google-site-kit"),headerCtaLabel:Object(v.__)("Advanced Settings","google-site-kit"),headerCtaLink:a},t)}}]),AnalyticsAdSenseDashboardWidgetTopPagesTable}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"analytics",datapoint:"report",data:O.a,priority:1,maxAge:Object(b.p)("day"),context:"Single"}],E.renderLayout(n.createElement(k.a,{padding:!0})),{inGrid:!0,fullWidth:!0,createGrid:!0},(function(){return!1}),(function(t){return!(!t||!t.error)&&(400===t.error.code&&"INVALID_ARGUMENT"===t.error.status&&e.googlesitekit.modules.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(v.__)("Unidentified error","google-site-kit"))}))}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(53),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(3),k=a(29),y=a(39),v=a(21),S=a(13),O=a(0),E=a(1),j=a(18),D=function(t){function AnalyticsDashboardWidgetPopularPagesTable(){return r()(this,AnalyticsDashboardWidgetPopularPagesTable),u()(this,m()(AnalyticsDashboardWidgetPopularPagesTable).apply(this,arguments))}return h()(AnalyticsDashboardWidgetPopularPagesTable,t),c()(AnalyticsDashboardWidgetPopularPagesTable,[{key:"render",value:function(){var t=this.props.data,a=e.googlesitekit.admin.siteURL;if(!t||!t.length)return null;var i=[{title:Object(O.__)("Most popular content","google-site-kit"),primary:!0},{title:Object(O.__)("Views","google-site-kit")}],s=[],r=Object(S.map)(t[0].data.rows,(function(e,t){var n=o()(e.dimensions,2),i=n[0],r=n[1];return s[t]=a+r,[i,Object(f.s)(e.metrics[0].values[0])]})),l={hideHeader:!1,chartsEnabled:!1,links:s,showURLs:!0},c=Object(k.b)(r,i,l);return AnalyticsDashboardWidgetPopularPagesTable.renderLayout(n.createElement(k.a,null,c))}}],[{key:"renderLayout",value:function(t){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},n.createElement(v.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(O._x)("Analytics","Service name","google-site-kit"),footerCtaLink:e.googlesitekit.modules.analytics.homepage,fill:!0},t))}}]),AnalyticsDashboardWidgetPopularPagesTable}(E.Component);t.a=Object(b.a)(D,[{type:_.b,identifier:"analytics",datapoint:"report",data:Object(j.g)(),priority:1,maxAge:Object(f.p)("day"),context:["Single","Dashboard"]}],D.renderLayout(n.createElement(y.a,{padding:!0})),{inGrid:!0,createGrid:!0},j.h)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(13),p=a(20),h=a(10),b=a(3),_=a(29),f=a(39),k=a(21),y=a(37),v=a(0),S=a(1),O=a(18),E=function(t){function AdSenseDashboardWidgetTopPagesTableSmall(){return i()(this,AdSenseDashboardWidgetTopPagesTableSmall),l()(this,d()(AdSenseDashboardWidgetTopPagesTableSmall).apply(this,arguments))}return g()(AdSenseDashboardWidgetTopPagesTableSmall,t),s()(AdSenseDashboardWidgetTopPagesTableSmall,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Top Earning Pages","google-site-kit"),tooltip:Object(v.__)("Top Earning Pages","google-site-kit"),primary:!0},{title:Object(v.__)("Revenue","google-site-kit"),tooltip:Object(v.__)("Revenue","google-site-kit")}],n=[],i=Object(m.map)(t[0].data.rows,(function(e,t){return n[t]=e.dimensions[1],[e.dimensions[0],Number(e.metrics[0].values[0]).toFixed(2)]})),o={hideHeader:!1,chartsEnabled:!1,cap:5,links:n},s=Object(_.b)(i,a,o);return AdSenseDashboardWidgetTopPagesTableSmall.renderLayout(e.createElement(_.a,null,s))}}],[{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-top-earnings-pages",footer:!0,footerCtaLabel:Object(v._x)("Analytics","Service name","google-site-kit"),footerCtaLink:"http://analytics.google.com",fill:!0},t))}}]),AdSenseDashboardWidgetTopPagesTableSmall}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"analytics",datapoint:"report",data:O.a,priority:1,maxAge:Object(b.p)("day"),context:"Dashboard"}],E.renderLayout(e.createElement(f.a,{rows:5,padding:!0})),{inGrid:!0,createGrid:!0},(function(){return!1}),(function(t){if(t&&t.error_data){var a=Object.values(t.error_data);if(a[0]&&"badRequest"===a[0].reason)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-top-earnings-pages",fill:!0},e.createElement(y.a,{title:Object(v.__)("Restricted metric(s)","google-site-kit"),description:Object(v.__)("You need to link Analytics and AdSense to get report for your top earning pages. Learn more: https://support.google.com/adsense/answer/6084409 ","google-site-kit")})))}if(t&&t.errors){var n=Object.values(t.errors);if(n[0]&&n[0][0])return n[0][0]}return!1}))}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(224),h=a(21),b=a(44),_=a(1),f=a(0),k=function(t){function DashboardSpeed(){return o()(this,DashboardSpeed),c()(this,u()(DashboardSpeed).apply(this,arguments))}return m()(DashboardSpeed,t),r()(DashboardSpeed,[{key:"render",value:function(){var t=e.googlesitekit.permaLink?Object(f.__)("How fast this page is.","google-site-kit"):Object(f.__)("How fast your home page is.","google-site-kit");return n.createElement(_.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(b.a,{title:Object(f.__)("Speed","google-site-kit"),description:t})),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(h.a,{className:"googlesitekit-pagespeed-report"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(p.a,null))))))}}]),DashboardSpeed}(_.Component);t.a=k}).call(this,a(15),a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function DashboardSpeedInner(){return i()(this,DashboardSpeedInner),l()(this,d()(DashboardSpeedInner).apply(this,arguments))}return g()(DashboardSpeedInner,e),s()(DashboardSpeedInner,[{key:"render",value:function(){return null}}]),DashboardSpeedInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardSpeed")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(58),_=a(32),f=a(47),k=a(1),y=a(0),v=a(143),S=a(76),O=function(t){function PageSpeedInsightsDashboardWidgetHomepageSpeed(e){var t;return o()(this,PageSpeedInsightsDashboardWidgetHomepageSpeed),(t=c()(this,u()(PageSpeedInsightsDashboardWidgetHomepageSpeed).call(this,e))).state={loading:!0,error:!1},t.handleDataLoaded=t.handleDataLoaded.bind(m()(t)),t.handleDataError=t.handleDataError.bind(m()(t)),t}return h()(PageSpeedInsightsDashboardWidgetHomepageSpeed,t),r()(PageSpeedInsightsDashboardWidgetHomepageSpeed,[{key:"handleDataLoaded",value:function(){this.setState({loading:!1})}},{key:"handleDataError",value:function(e){this.setState({error:e})}},{key:"render",value:function(){var t=this.state,a=t.loading,i=t.error,o={name:Object(y._x)("PageSpeed Insights","Service name","google-site-kit"),link:Object(y.sprintf)("https://developers.google.com/speed/pagespeed/insights/?url=%s",e.googlesitekit.permaLink||e.googlesitekit.admin.siteURL)};return i?n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},Object(f.a)(Object(y._x)("PageSpeed Insights","Service name","google-site-kit"),i,!0,!0,!1)):n.createElement(k.Fragment,null,a&&n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-pagespeed-report__loading"},n.createElement(_.a,null),n.createElement("p",null,Object(y.__)("PageSpeed Insights is preparing data…","google-site-kit")))),n.createElement(v.b,{handleDataLoaded:this.handleDataLoaded,handleDataError:this.handleDataError,title:Object(y.__)("Mobile","google-site-kit")}),n.createElement(v.a,{title:Object(y.__)("Desktop","google-site-kit")}),!a&&n.createElement(k.Fragment,null,n.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 "},n.createElement(b.a,{name:o.name,href:o.link,external:!0})),n.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 mdc-layout-grid__cell--align-right-tablet "},n.createElement(S.a,null))))}}]),PageSpeedInsightsDashboardWidgetHomepageSpeed}(k.Component);t.a=O}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(37),r=a(10),l=a(67),c=a(3),d=a(0);t.a=function PageSpeedInsightsCTA(){var t=e.googlesitekit.modules["pagespeed-insights"],a=t.active,i=t.setupComplete;if(!e.googlesitekit.permissions.canManageOptions&&!i)return null;return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(s.a,{title:!i&&a?Object(d.__)("Complete PageSpeed Insights activation.","google-site-kit"):Object(d.__)("Activate PageSpeed Insights.","google-site-kit"),description:Object(d.__)("Google PageSpeed Insights gives you metrics about performance, accessibility, SEO and PWA.","google-site-kit"),ctaLink:"#",ctaLabel:!i&&a?Object(d.__)("Complete activation","google-site-kit"):Object(d.__)("Activate PageSpeed Insights","google-site-kit"),onClick:function(){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(Object(c.a)(r.c,"pagespeed-insights",!0));case 3:e.location=Object(c.m)("pagespeed-insights"),t.next=9;break;case 6:t.prev=6,t.t0=t.catch(0),Object(c.x)(l.a,{id:"pagespeed-insights-setup-error",title:Object(d.__)("Internal Server Error","google-site-kit"),description:t.t0.message,format:"small",type:"win-error"});case 9:case"end":return t.stop()}}),null,null,[[0,6]])}}))}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){a.d(t,"a",(function(){return s}));var i=a(0),o=a(3),s=function(){var t=e.googlesitekit.dashboardPermalink,a=Object(i.sprintf)(
|
21 |
-
/* translators: %s is the URL to the Site Kit dashboard. */
|
22 |
-
Object(i.__)('To view insights, <a href="%s">visit the dashboard</a>.',"google-site-kit"),t);return n.createElement("p",{dangerouslySetInnerHTML:Object(o.w)(a,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href"]})})}}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(22),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(66),k=a(14),y=a.n(k),v=a(1),S=a(0),O=a(229),E=a(104),j=a(230),D=a(62),C=a(21),w=a(82),A=a(32),x=a(56),N=a(47),P=a(3),T=a(65);function L(e,t){var a=Object.keys(e);return Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(e)),t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),a}var I=function(t){function GoogleSitekitSearchConsoleDashboardWidget(e){var t;return r()(this,GoogleSitekitSearchConsoleDashboardWidget),(t=u()(this,m()(GoogleSitekitSearchConsoleDashboardWidget).call(this,e))).state={selectedStats:[0,1],receivingData:!0,error:!1,loading:!0},t.handleStatSelection=t.handleStatSelection.bind(h()(t)),t.buildSeries=t.buildSeries.bind(h()(t)),t.buildVAxes=t.buildVAxes.bind(h()(t)),t.handleDataError=t.handleDataError.bind(h()(t)),t.handleDataSuccess=t.handleDataSuccess.bind(h()(t)),t}return _()(GoogleSitekitSearchConsoleDashboardWidget,t),c()(GoogleSitekitSearchConsoleDashboardWidget,[{key:"handleDataError",value:function(e){this.setState({receivingData:!1,error:e,loading:!1})}},{key:"handleDataSuccess",value:function(){this.setState({receivingData:!0,loading:!1})}},{key:"handleStatSelection",value:function(e){var t=this.state.selectedStats,a=t.slice();t.includes(e)?a=t.filter((function(t){return e!==t})):a.push(e),0!==a.length&&this.setState({selectedStats:a})}},{key:"buildSeries",value:function(){var e=this.state.selectedStats,t={0:"#4285f4",1:"#27bcd4",2:"#1b9688",3:"#673ab7"};return e.map((function(e,a){return{color:t[e],targetAxisIndex:a}}))}},{key:"buildVAxes",value:function(){var e=this.state.selectedStats,t={0:Object(S.__)("Clicks","google-site-kit"),1:Object(S.__)("Impressions","google-site-kit"),2:Object(S.__)("Average CTR","google-site-kit"),3:Object(S.__)("Average Position","google-site-kit")};return e.map((function(e){var a={};return 3===e&&(a.direction=-1),function(e){for(var t=1;t<arguments.length;t++){var a=null!=arguments[t]?arguments[t]:{};t%2?L(a,!0).forEach((function(t){o()(e,t,a[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(a)):L(a).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(a,t))}))}return e}({title:t[e]},a)}))}},{key:"render",value:function(){var t=this.state,a=t.selectedStats,i=t.receivingData,o=t.error,s=t.loading,r=this.buildSeries(),l=this.buildVAxes(),c=!s&&i?"":"googlesitekit-nodata",d=Object(P.g)(),u=Object(S.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",e.googlesitekit.admin.siteURL);return n.createElement(v.Fragment,null,n.createElement(f.a,null),n.createElement(w.a,{module:"search-console"}),n.createElement("div",{className:"googlesitekit-module-page googlesitekit-module-page--search-console"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(D.a,{title:Object(S._x)("Search Console","Service name","google-site-kit"),icon:!0,iconWidth:"23",iconHeight:"21",iconID:"search-console",status:"connected",statusText:Object(S.__)("Search Console is connected","google-site-kit")}),s&&n.createElement(A.a,null)),!i&&(o?Object(N.a)(Object(S._x)("Search Console","Service name","google-site-kit"),o,!0,!0,!0):Object(x.a)(Object(S._x)("Search Console","Service name","google-site-kit"),!0,!0,!0)),n.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",c)},n.createElement(C.a,{header:!0
|
23 |
-
/* translators: %s: date range */,title:Object(S.sprintf)(Object(S.__)("Overview for the last %s","google-site-kit"),d),headerCtaLabel:Object(S.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:u},n.createElement(j.a,{selectedStats:a,handleStatSelection:this.handleStatSelection,handleDataError:this.handleDataError,handleDataSuccess:this.handleDataSuccess}),n.createElement(O.a,{selectedStats:a,series:r,vAxes:l}))),n.createElement("div",{className:y()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-12",c)},n.createElement(C.a
|
24 |
-
/* translators: %s: date range */,{title:Object(S.sprintf)(Object(S.__)("Top search queries over the last %s","google-site-kit"),d),header:!0,footer:!0,headerCtaLabel:Object(S.__)("See full stats in Search Console","google-site-kit"),headerCtaLink:u,footerCtaLabel:Object(S._x)("Search Console","Service name","google-site-kit"),footerCtaLink:u},n.createElement(E.a,null))),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 mdc-layout-grid__cell--align-right "},n.createElement(T.a,null))))))}}]),GoogleSitekitSearchConsoleDashboardWidget}(v.Component);t.a=I}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(20),_=a(10),f=a(57),k=a(27),y=a(3),v=a(40),S=a(0),O=a(1),E=function(t){function SearchConsoleDashboardWidgetSiteStats(e){var t;return o()(this,SearchConsoleDashboardWidgetSiteStats),(t=c()(this,u()(SearchConsoleDashboardWidgetSiteStats).call(this,e))).setOptions=t.setOptions.bind(m()(t)),t}return h()(SearchConsoleDashboardWidgetSiteStats,t),r()(SearchConsoleDashboardWidgetSiteStats,[{key:"setOptions",value:function(){var t=this.props,a=t.selectedStats,n=t.series,i=t.vAxes,o=e.googlesitekit.pageTitle,s=Object(S.__)("Search Traffic Summary","google-site-kit");o&&o.length&&(
|
25 |
-
/* translators: %s: page title */
|
26 |
-
s=Object(S.sprintf)(Object(S.__)("Search Traffic Summary for %s","google-site-kit"),Object(y.d)(o)));var r={chart:{title:s},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=i,3<=a.length&&(r.vAxis.textPosition="none",r.vAxis.gridlines.color="#fff",r.vAxis.minorGridlines.color="#fff",r.chartArea.width="98%"),r}},{key:"render",value:function(){var e=this.props,t=e.data,a=e.selectedStats;if(!t||!t.length)return null;var i=this.setOptions(),o=Object(v.a)(t);return n.createElement("section",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement(f.a,{selectedStats:a,data:o.dataMap,options:i,singleStat:!1}))))}}]),SearchConsoleDashboardWidgetSiteStats}(O.Component);t.a=Object(b.a)(E,[{type:_.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(y.p)("day"),context:"Single"}],n.createElement(k.a,{width:"100%",height:"270px",padding:!0}),{createGrid:!0})}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(26),p=a(20),h=a(10),b=a(27),_=a(3),f=a(40),k=a(2),y=a.n(k),v=a(0),S=a(1),O=function(t){function SearchConsoleDashboardWidgetOverview(){return i()(this,SearchConsoleDashboardWidgetOverview),l()(this,d()(SearchConsoleDashboardWidgetOverview).apply(this,arguments))}return g()(SearchConsoleDashboardWidgetOverview,t),s()(SearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props,a=t.data,n=t.selectedStats,i=t.handleStatSelection;if(!a||!a.length)return null;var o=Object(f.a)(a),s=o.totalClicks,r=o.totalImpressions,l=o.averageCTR,c=o.averagePosition,d=o.totalClicksChange,u=o.totalImpressionsChange,g=o.averageCTRChange,p=o.averagePositionChange,h=[{className:"googlesitekit-data-block--clicks googlesitekit-data-block--button-1",title:Object(v.__)("Total Clicks","google-site-kit"),datapoint:s,change:d,changeDataUnit:"%",context:"button",selected:n.includes(0),handleStatSelection:i},{className:"googlesitekit-data-block--impressions googlesitekit-data-block--button-2",title:Object(v.__)("Total Impressions","google-site-kit"),datapoint:r,change:u,changeDataUnit:"%",context:"button",selected:n.includes(1),handleStatSelection:i},{className:"googlesitekit-data-block--ctr googlesitekit-data-block--button-3",title:Object(v.__)("Average CTR","google-site-kit"),datapoint:l+"%",change:g,changeDataUnit:"%",context:"button",selected:n.includes(2),handleStatSelection:i},{className:"googlesitekit-data-block--position googlesitekit-data-block--button-4",title:Object(v.__)("Average Position","google-site-kit"),datapoint:c,change:p,changeDataUnit:"%",context:"button",selected:n.includes(3),handleStatSelection:i}];return e.createElement(S.Fragment,null,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,a){return e.createElement("div",{key:a,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:a,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}(S.Component);O.propTypes={handleDataError:y.a.func.isRequired},t.a=Object(p.a)(O,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:["Single","Dashboard"]}],e.createElement(b.a,{width:"100%",height:"190px",padding:!0}),{createGrid:!0},f.b)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(41),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(9),h=a.n(p),b=a(232),_=a(1),f=function(t){function GoogleSitekitSearchConsoleAdminbarWidget(){return r()(this,GoogleSitekitSearchConsoleAdminbarWidget),u()(this,m()(GoogleSitekitSearchConsoleAdminbarWidget).apply(this,arguments))}return h()(GoogleSitekitSearchConsoleAdminbarWidget,t),c()(GoogleSitekitSearchConsoleAdminbarWidget,[{key:"render",value:function(){return"undefined"!==o()(e.googlesitekit.permaLink)&&""===e.googlesitekit.permaLink?null:n.createElement(b.a,null)}}]),GoogleSitekitSearchConsoleAdminbarWidget}(_.Component);t.a=f}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(26),h=a(20),b=a(10),_=a(3),f=a(40),k=a(27),y=a(0),v=a(1),S=function(t){function SearchConsoleAdminbarWidgetOverview(){return o()(this,SearchConsoleAdminbarWidgetOverview),c()(this,u()(SearchConsoleAdminbarWidgetOverview).apply(this,arguments))}return m()(SearchConsoleAdminbarWidgetOverview,t),r()(SearchConsoleAdminbarWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||t.error)return null;var a=Object(f.a)(t),n=a.totalClicks,i=a.totalImpressions,o=a.totalClicksChange,s=a.totalImpressionsChange;return e.createElement(v.Fragment,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(p.a,{className:"overview-total-impressions",title:Object(y.__)("Total Impressions","google-site-kit"),datapoint:i,change:s,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(p.a,{className:"overview-total-clicks",title:Object(y.__)("Total Clicks","google-site-kit"),datapoint:n,change:o,changeDataUnit:"%"})))}}]),SearchConsoleAdminbarWidgetOverview}(v.Component);t.a=Object(h.a)(S,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:n.googlesitekit.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:"Adminbar"}],e.createElement(v.Fragment,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},f.b)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(234),p=a(1),h=function(t){function WPSearchConsoleDashboardWidget(){return i()(this,WPSearchConsoleDashboardWidget),l()(this,d()(WPSearchConsoleDashboardWidget).apply(this,arguments))}return g()(WPSearchConsoleDashboardWidget,t),s()(WPSearchConsoleDashboardWidget,[{key:"render",value:function(){return e.createElement(p.Fragment,null,e.createElement(m.a,null))}}]),WPSearchConsoleDashboardWidget}(p.Component);t.a=h}).call(this,a(1))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(103),p=a(26),h=a(20),b=a(10),_=a(3),f=a(40),k=a(37),y=a(0),v=a(1),S=function(t){function WPSearchConsoleDashboardWidgetOverview(){return i()(this,WPSearchConsoleDashboardWidgetOverview),l()(this,d()(WPSearchConsoleDashboardWidgetOverview).apply(this,arguments))}return g()(WPSearchConsoleDashboardWidgetOverview,t),s()(WPSearchConsoleDashboardWidgetOverview,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=Object(f.a)(t),n=a.totalClicks,i=a.totalImpressions,o=a.totalClicksChange,s=a.totalImpressionsChange;return e.createElement(v.Fragment,null,t.length?e.createElement(v.Fragment,null,e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-impressions",title:Object(y.__)("Total Impressions","google-site-kit"),datapoint:i,change:s,changeDataUnit:"%"}),e.createElement(p.a,{className:"googlesitekit-wp-dashboard-stats__data-table overview-total-clicks",title:Object(y.__)("Total Clicks","google-site-kit"),datapoint:n,change:o,changeDataUnit:"%"})):e.createElement("div",{className:"googlesitekit-wp-dashboard-stats__cta"},e.createElement(k.a,{title:Object(y.__)("Search Console Data Empty","google-site-kit"),description:Object(y.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""})))}}]),WPSearchConsoleDashboardWidgetOverview}(v.Component);t.a=Object(h.a)(S,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(_.p)("day"),context:["WPDashboard"]}],e.createElement(m.a,{width:"23%",height:"94px",count:2}),{},f.b)}).call(this,a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(105),h=a(21),b=a(44),_=a(77),f=a(14),k=a.n(f),y=a(1),v=a(0),S=function(t){function DashboardSearchFunnel(){return o()(this,DashboardSearchFunnel),c()(this,u()(DashboardSearchFunnel).apply(this,arguments))}return m()(DashboardSearchFunnel,t),r()(DashboardSearchFunnel,[{key:"render",value:function(){var t=e.googlesitekit.permissions.canManageOptions,a=e.googlesitekit.modules.analytics.active||t?12:6;return n.createElement(y.Fragment,null,n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(b.a,{title:Object(v.__)("Search Funnel","google-site-kit"),description:Object(v.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit")})),n.createElement("div",{className:k()("mdc-layout-grid__cell","mdc-layout-grid__cell--span-".concat(a))},n.createElement(h.a,{className:"googlesitekit-analytics-search-funnel"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(p.a,null),!e.googlesitekit.modules.analytics.active&&n.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 "},n.createElement(_.a,null)))))))}}]),DashboardSearchFunnel}(y.Component);t.a=S}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(26),h=a(20),b=a(10),_=a(0),f=a(1),k=a(40),y=a(54),v=a(27),S=a(3),O=a(37),E=function(t){function SearchConsoleDashboardWidgetTopLevel(){return o()(this,SearchConsoleDashboardWidgetTopLevel),c()(this,u()(SearchConsoleDashboardWidgetTopLevel).apply(this,arguments))}return m()(SearchConsoleDashboardWidgetTopLevel,t),r()(SearchConsoleDashboardWidgetTopLevel,[{key:"render",value:function(){var t=this.props.data,a=t.error;if(a)return Object(S.A)("plugin_setup","search_console_error",a.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(O.a,{title:Object(_.__)("Something went wrong","google-site-kit"),description:a.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(O.a,{title:Object(_.__)("Search Console Data Empty","google-site-kit"),description:Object(_.__)("Search Console data is not yet available, please check back later.","google-site-kit"),ctaLink:"",ctaLabel:""}));var n=Object(S.n)("googlesitekit-module-search-console",{}),i=Object(k.a)(t),o=i.totalClicks,s=i.totalImpressions,r=i.totalClicksChange,l=i.totalImpressionsChange,c=i.dataMap;return e.createElement(f.Fragment,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(p.a,{className:"overview-total-impressions",title:Object(_.__)("Impressions","google-site-kit"),datapoint:s,change:l,changeDataUnit:"%",source:{name:Object(_._x)("Search Console","Service name","google-site-kit"),link:n},sparkline:e.createElement(y.a,{data:Object(S.e)(c,2),change:l})})),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(p.a,{className:"overview-total-clicks",title:Object(_.__)("Clicks","google-site-kit"),datapoint:o,change:r,changeDataUnit:"%",source:{name:Object(_._x)("Search Console","Service name","google-site-kit"),link:n},sparkline:e.createElement(y.a,{data:Object(S.e)(c,1),change:r})})))}}]),SearchConsoleDashboardWidgetTopLevel}(f.Component);t.a=Object(h.a)(E,[{type:b.b,identifier:"search-console",datapoint:"searchanalytics",data:{url:n.googlesitekit.permaLink,dimensions:"date",compareDateRanges:!0},priority:1,maxAge:Object(S.p)("day"),context:["Single","Dashboard"]}],e.createElement(f.Fragment,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(v.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(v.a,{width:"100%",height:"202px"}))),{inGrid:!0},k.b)}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(44),h=a(21),b=a(1),_=a(0),f=a(104),k=function(t){function DashboardDetailsWidgetKeywordsTable(){return o()(this,DashboardDetailsWidgetKeywordsTable),c()(this,u()(DashboardDetailsWidgetKeywordsTable).apply(this,arguments))}return m()(DashboardDetailsWidgetKeywordsTable,t),r()(DashboardDetailsWidgetKeywordsTable,[{key:"render",value:function(){return e.createElement(b.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{title:Object(_.__)("Top Queries","google-site-kit"),description:Object(_.__)("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(h.a,{footer:!0,footerCtaLabel:Object(_._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(_.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",n.googlesitekit.admin.siteURL)},e.createElement(f.a,null))))}}]),DashboardDetailsWidgetKeywordsTable}(b.Component);t.a=k}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(20),h=a(10),b=a(3),_=a(29),f=a(39),k=a(21),y=a(13),v=a(0),S=a(1),O=a(40),E=function(t){function DashboardWidgetPopularKeywordsTable(){return o()(this,DashboardWidgetPopularKeywordsTable),c()(this,u()(DashboardWidgetPopularKeywordsTable).apply(this,arguments))}return m()(DashboardWidgetPopularKeywordsTable,t),r()(DashboardWidgetPopularKeywordsTable,[{key:"render",value:function(){var t=this.props.data;if(!t||!t.length)return null;var a=[{title:Object(v.__)("Top search queries for your site","google-site-kit"),tooltip:Object(v.__)("Most searched for keywords related to your content","google-site-kit"),primary:!0},{title:Object(v.__)("Clicks","google-site-kit"),tooltip:Object(v.__)("Number of times users clicked on your content in search results","google-site-kit")},{title:Object(v.__)("Impressions","google-site-kit"),tooltip:Object(v.__)("Counted each time your content appears in search results","google-site-kit")}],i=e.googlesitekit.admin.siteURL,o=[],s=Object(y.map)(t,(function(e,t){var a=e.keys[0];return o[t]=Object(v.sprintf)("https://search.google.com/search-console/performance/search-analytics?resource_id=%s&query=!%s&num_of_days=28",i,a),[a,Object(b.s)(e.clicks),Object(b.s)(e.impressions)]})),r={hideHeader:!1,chartsEnabled:!1,links:o},l=Object(_.b)(s,a,r);return DashboardWidgetPopularKeywordsTable.renderLayout(n.createElement(_.a,null,l))}}],[{key:"renderLayout",value:function(t){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-6-desktop mdc-layout-grid__cell--span-4-tablet "},n.createElement(k.a,{className:"googlesitekit-popular-content",footer:!0,footerCtaLabel:Object(v._x)("Search Console","Service name","google-site-kit"),footerCtaLink:Object(v.sprintf)("https://search.google.com/u/1/search-console?resource_id=%s",e.googlesitekit.admin.siteURL),fill:!0},t))}}]),DashboardWidgetPopularKeywordsTable}(S.Component);t.a=Object(p.a)(E,[{type:h.b,identifier:"search-console",datapoint:"searchanalytics",data:{dimensions:"query",limit:10},priority:1,maxAge:Object(b.p)("day"),context:["Dashboard"]}],E.renderLayout(n.createElement(f.a,{padding:!0})),{inGrid:!0,createGrid:!0},O.b)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(77),h=a(44),b=a(21),_=a(1),f=a(0),k=a(105),y=function(t){function DashboardDetailsSearchFunnel(){return o()(this,DashboardDetailsSearchFunnel),c()(this,u()(DashboardDetailsSearchFunnel).apply(this,arguments))}return m()(DashboardDetailsSearchFunnel,t),r()(DashboardDetailsSearchFunnel,[{key:"render",value:function(){return e.createElement(_.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(h.a,{description:Object(f.__)("How your site appeared in Search results and how many visitors you got from Search.","google-site-kit"),title:Object(f.__)("Search Funnel","google-site-kit")})),e.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},e.createElement(b.a,{className:"googlesitekit-analytics-search-funnel"},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},e.createElement(k.a,null),!n.googlesitekit.modules.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(p.a,null)))))))}}]),DashboardDetailsSearchFunnel}(_.Component);t.a=y}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(241),p=a(44),h=a(1),b=a(0),_=function(t){function DashboardPopularity(){return i()(this,DashboardPopularity),l()(this,d()(DashboardPopularity).apply(this,arguments))}return g()(DashboardPopularity,t),s()(DashboardPopularity,[{key:"render",value:function(){return e.createElement(h.Fragment,null,e.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},e.createElement(p.a,{title:Object(b.__)("Popularity","google-site-kit"),description:Object(b.__)("Your most popular pages and how people found them from Search.","google-site-kit")})),e.createElement(m.a,null))}}]),DashboardPopularity}(h.Component);t.a=_}).call(this,a(1))},function(e,t,a){"use strict";var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(e){function DashboardPopularityInner(){return i()(this,DashboardPopularityInner),l()(this,d()(DashboardPopularityInner).apply(this,arguments))}return g()(DashboardPopularityInner,e),s()(DashboardPopularityInner,[{key:"render",value:function(){return null}}]),DashboardPopularityInner}(p.Component);t.a=Object(m.a)("googlesitekit.DashboardPopularity")(h)},function(e,t,a){"use strict";(function(e,n){var i=a(11),o=a.n(i),s=a(5),r=a.n(s),l=a(6),c=a.n(l),d=a(7),u=a.n(d),g=a(8),m=a.n(g),p=a(16),h=a.n(p),b=a(9),_=a.n(b),f=a(13),k=a(243),y=a.n(k),v=a(10),S=a(33),O=a(21),E=a(3),j=a(1),D=a(0),C=function(t){function PostSearcher(e){var t;return r()(this,PostSearcher),(t=u()(this,m()(PostSearcher).call(this,e))).state={isSearching:!1,results:[],error:!1,message:""},t.postSearch=t.postSearch.bind(h()(t)),t.onClick=t.onClick.bind(h()(t)),t.onConfirm=t.onConfirm.bind(h()(t)),t}return _()(PostSearcher,t),c()(PostSearcher,[{key:"postSearch",value:function(e,t){var a;return o.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return t([Object(D.__)("Loading...","google-site-kit")]),n.prev=1,n.next=4,o.a.awrap(v.c.get(v.a,"search","post-search",{query:encodeURIComponent(e)}));case 4:0<(a=n.sent).length?t(Object(f.map)(a,(function(e){return e.post_title}))):t([Object(D.__)("No results found","google-site-kit")]),this.setState({isSearching:!0,results:a,error:!1,message:""}),n.next=13;break;case 9:n.prev=9,n.t0=n.catch(1),t([Object(D.__)("No results found","google-site-kit")]),this.setState({isSearching:!1,error:n.t0.code,message:n.t0.message});case 13:case"end":return n.stop()}}),null,this,[[1,9]])}},{key:"getURLPathname",value:function(e){try{var t=new URL(e);return Object(f.trim)(t.pathname,"/")}catch(e){return!1}}},{key:"onConfirm",value:function(e){this.setState({selection:e})}},{key:"onClick",value:function(){var e=this.state,t=e.results,a=e.selection,n=Object(f.find)(t,(function(e){return e.post_title===a}));document.location=Object(E.n)("googlesitekit-dashboard",{id:n.id,permaLink:n.permalink,pageTitle:a})}},{key:"render",value:function(){var t=e.googlesitekit.modules,a=t.analytics&&t.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 n.createElement("div",{className:a},n.createElement(O.a,{title:Object(D.__)("Search for individual page or post information","google-site-kit"),header:!0},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:"mdc-layout-grid__cell mdc-layout-grid__cell--span-12"},n.createElement("div",{className:"googlesitekit-post-searcher"},n.createElement("label",{className:"googlesitekit-post-searcher__label",htmlFor:"autocomplete"},Object(D.__)("Title or URL","google-site-kit")),n.createElement(y.a,{id:"autocomplete",source:Object(f.debounce)(this.postSearch,200),minLength:2,onConfirm:this.onConfirm,showNoOptionsFound:!1}),n.createElement("div",{className:"googlesitekit-post-searcher__button-wrapper"},n.createElement(S.a,{onClick:this.onClick,className:"googlesitekit-post-searcher__button"},Object(D.__)("View Data","google-site-kit")))))))))}}]),PostSearcher}(j.Component);t.a=C}).call(this,a(15),a(1))},,function(e,t,a){"use strict";(function(e,n){var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(9),m=a.n(g),p=a(1),h=a(0),b=e.googlesitekit.admin.siteURL,_=function(e){function SearchConsoleSettingStatus(){return o()(this,SearchConsoleSettingStatus),c()(this,u()(SearchConsoleSettingStatus).apply(this,arguments))}return m()(SearchConsoleSettingStatus,e),r()(SearchConsoleSettingStatus,[{key:"render",value:function(){return n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("div",{className:"googlesitekit-settings-module__meta-item-type"},Object(h.__)("Connected URL","google-site-kit")),n.createElement("div",{className:"googlesitekit-settings-module__meta-item-data"},b))}}]),SearchConsoleSettingStatus}(p.Component);t.a=_}).call(this,a(15),a(1))},,,,,,,,,,function(e,t,a){"use strict";a(255),a(258),a(259),a(260),a(261),a(263)},function(e,t,a){"use strict";(function(e,t){var n=a(23),i=a(3),o=a(192),s=a(200),r=a(100),l=a(203),c=a(205),d=a(206),u=a(12),g="adsense";if(Object(u.b)("googlesitekit.ModuleSettingsWarning","googlesitekit.adsenseSettingsWarning",Object(i.f)(d.a,{})),Object(u.b)("googlesitekit.SetupModuleShowLink","googlesitekit.adsenseSetupModuleShowLink",(function(t,a){return!("adsense"===a&&!e.googlesitekit.canAdsRun)&&t})),e.googlesitekit.modules.adsense.active){var m=Object(n.a)(t.createElement(o.a,null)),p=Object(n.a)(t.createElement(s.a,null));if(e.googlesitekit.modules[g].setupComplete)Object(u.b)("googlesitekit.ModuleApp-".concat(g),"googlesitekit.ModuleApp",m),Object(u.b)("googlesitekit.DashboardModule","googlesitekit.DashboardEarningModule",p,50);else{var h=e.googlesitekit.admin,b=h.reAuth,_=h.currentScreen,f=_?_.id:null;b||"site-kit_page_googlesitekit-module-adsense"!==f||(e.location=Object(i.n)("googlesitekit-module-".concat(g),{reAuth:!0,slug:g})),Object(u.b)("googlesitekit.Connected-".concat(g),"googlesitekit.AdSenseModuleConnected",(function(t){var a=e.googlesitekit.modules[g].settings;return!(t||void 0===a||"account-pending-review"!==a.accountStatus&&"ads-display-pending"!==a.accountStatus)||t}))}Object(u.b)("googlesitekit.ModuleSettingsDetails-".concat(g),"googlesitekit.AdSenseModuleSettingsDetails",Object(i.f)(r.a,{onSettingsPage:!0})),Object(u.b)("googlesitekit.ModuleSetup-".concat(g),"googlesitekit.TagmanagerModuleSetupWizard",Object(i.f)(l.a,{onSettingsPage:!1})),Object(u.b)("googlesitekit.autoRefreshModules","googlesitekit.AdSenseAutoRefresh",(function(t){return t.push({identifier:"adsense",toRefresh:function(){var t="";return e.googlesitekit.modules.adsense&&e.googlesitekit.modules.adsense["account-status"]&&(t=e.googlesitekit.modules.adsense["account-status"].accountStatus),!(t&&-1<t.indexOf("account-connected"))}}),t})),Object(u.b)("googlesitekit.ModulesNotificationsRequest","googlesitekit.adsenseNotifications",(function(e){return e.push({identifier:"adsense"}),e})),Object(u.b)("googlesitekit.ModuleSetupIncomplete","googlesitekit.adsenseSettingStatus",Object(i.f)(c.a,{}))}}).call(this,a(15),a(1))},,,function(e,t,a){"use strict";(function(e,t){var n=a(3),i=a(23),o=a(207),s=a(212),r=a(214),l=a(216),c=a(217),d=a(218),u=a(219),g=a(220),m=a(221),p=a(222),h=a(140),b=a(12),_="analytics",f=Object(i.a)(e.createElement(s.a,null));if(Object(b.b)("googlesitekit.AdminbarModules","googlesitekit.Analytics",f,11),!t.googlesitekit.modules[_].setupComplete){var k=t.googlesitekit.admin,y=k.reAuth,v=k.currentScreen,S=v?v.id:null;y||"site-kit_page_googlesitekit-module-analytics"!==S||(t.location=Object(n.n)("googlesitekit-module-".concat(_),{reAuth:!0,slug:_}))}if(t.googlesitekit.modules.analytics.active){var O=Object(i.a)(e.createElement(o.a,null)),E=Object(i.a)(e.createElement(r.a,null)),j=Object(i.a)(e.createElement(c.a,null)),D=Object(i.a)(e.createElement(u.a,null)),C=Object(i.a)(e.createElement(l.a,null)),w=Object(i.a)(e.createElement(d.a,null)),A=Object(i.a)(e.createElement(g.a,null)),x=Object(i.a)(e.createElement(m.a,null)),N=Object(i.a)(e.createElement(p.a,null));Object(b.b)("googlesitekit.DashboardModule","googlesitekit.Analytics",E,9),Object(b.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.Analytics",C,11),Object(b.b)("googlesitekit.DashboardPopularity","googlesitekit.Analytics",x,20),Object(b.b)("googlesitekit.AnalyticsAdSenseTopPagesTableSmall","googlesitekit.Analytics",N,20),Object(b.b)("googlesitekit.DashboardDetailsModule","googlesitekit.Analytics",w,20),Object(b.b)("googlesitekit.WPDashboardHeader","googlesitekit.Analytics",j),Object(b.b)("googlesitekit.WPDashboardModule","googlesitekit.Analytics",D),Object(b.b)("googlesitekit.ModuleApp-"+_,"googlesitekit.Analytics",O),Object(b.b)("googlesitekit.AnalyticsAdSenseTopPagesTable","googlesitekit.Analytics",A,11),Object(b.b)("googlesitekit.ModuleSettingsDetails-".concat(_),"googlesitekit.AnalyticsModuleSettingsDetails",Object(n.f)(h.a,{onSettingsPage:!0})),Object(b.b)("googlesitekit.showDateRangeSelector-".concat(_),"googlesitekit.analyticsShowDateRangeSelector",(function(){return!0})),Object(b.b)("googlesitekit.ModuleSetup-".concat(_),"googlesitekit.AnalyticsModuleSetupWizard",Object(n.f)(h.a,{onSettingsPage:!1}))}}).call(this,a(1),a(15))},function(e,t,a){"use strict";(function(e){var t=a(3),n=a(142),i=a(12),o=a(0),s="optimize";e.googlesitekit.modules.optimize.active&&(Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat(s),"googlesitekit.OptimizeModuleSettingsDetails",Object(t.f)(n.a,{onSettingsPage:!0})),Object(i.b)("googlesitekit.ModuleSetup-".concat(s),"googlesitekit.OptimizeModuleSetupWizard",Object(t.f)(n.a,{onSettingsPage:!1})),Object(i.b)("googlesitekit.SetupWinNotification-".concat(s),"googlesitekit.OptimizeSetupWinNotification",(function(e){return e.description=Object(o.__)("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})))}).call(this,a(15))},function(e,t,a){"use strict";(function(e,t){var n=a(23),i=a(12),o=a(223),s=a(225),r=a(226),l=a(227),c="pagespeed-insights",d=e.googlesitekit.modules[c],u=d.active,g=d.setupComplete;if(u&&g){var m=Object(n.a)(t.createElement(o.a,null)),p=Object(n.a)(t.createElement(s.a,null));Object(i.b)("googlesitekit.DashboardModule","googlesitekit.PageSpeedInsights",m,45),Object(i.b)("googlesitekit.DashboardDetailsModule","googlesitekit.PageSpeedInsights",m,45),Object(i.b)("googlesitekit.DashboardSpeed","googlesitekit.PageSpeedInsightsHomepageSpeed",p)}else{var h=Object(n.a)(t.createElement(r.a,null));Object(i.b)("googlesitekit.DashboardModule","googlesitekit.PageSpeedInsights",h,45)}Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat(c),"googlesitekit.PageSpeedInsightsModuleSettingsDetails",Object(n.a)(t.createElement(l.a,null)),10)}).call(this,a(15),a(1))},function(e,t,a){"use strict";(function(e){var t=a(228),n=a(231),i=a(233),o=a(235),s=a(236),r=a(237),l=a(238),c=a(239),d=a(240),u=a(242),g=a(244),m=a(23),p=a(3),h=a(12),b="search-console",_=Object(m.a)(e.createElement(t.a,null)),f=Object(m.a)(e.createElement(n.a,null)),k=Object(m.a)(e.createElement(i.a,null)),y=Object(m.a)(e.createElement(o.a,null)),v=Object(m.a)(e.createElement(s.a,null)),S=Object(m.a)(e.createElement(c.a,null)),O=Object(m.a)(e.createElement(r.a,null)),E=Object(m.a)(e.createElement(l.a,null)),j=Object(m.a)(e.createElement(d.a,null)),D=Object(m.a)(e.createElement(u.a,null));Object(h.b)("googlesitekit.ModuleSettingsDetails-".concat(b),"googlesitekit.SearchConsoleModuleSettingsDetails",Object(p.f)(g.a,{onSettingsPage:!0})),Object(h.b)("googlesitekit.DashboardModule","googlesitekit.SearchConsole",y,11),Object(h.b)("googlesitekit.DashboardModule","googlesitekit.DashboardPopularityModule",j,40),Object(h.b)("googlesitekit.DashboardSearchFunnel","googlesitekit.SearchConsoleSearchFunnel",v),Object(h.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",S),Object(h.b)("googlesitekit.DashboardDetailsModule","googlesitekit.SearchConsole",O,40),Object(h.b)("googlesitekit.DashboardPopularity","googlesitekit.SearchConsoleDashboardPopularity",E),Object(h.b)("googlesitekit.DashboardPopularity","googlesitekit.DashboardPPostSearcherModule",D,30),Object(h.b)("googlesitekit.WPDashboardHeader","googlesitekit.SearchConsole",k,11),Object(h.b)("googlesitekit.ModuleApp-"+b,"googlesitekit.ModuleApp",_),Object(h.b)("googlesitekit.showDateRangeSelector-".concat(b),"googlesitekit.searchConsoleShowDateRangeSelector",(function(){return!0})),Object(h.b)("googlesitekit.AdminbarModules","googlesitekit.SearchConsole",f)}).call(this,a(1))},,function(e,t,a){"use strict";(function(e){var t=a(3),n=a(144),i=a(12);e.googlesitekit.modules.tagmanager.active&&(Object(i.b)("googlesitekit.ModuleSettingsDetails-".concat("tagmanager"),"googlesitekit.TagmanagerModuleSettingsDetails",Object(t.f)(n.a,{onSettingsPage:!0})),Object(i.b)("googlesitekit.ModuleSetup-".concat("tagmanager"),"googlesitekit.TagmanagerModuleSetupWizard",Object(t.f)(n.a,{onSettingsPage:!1})))}).call(this,a(15))},,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,,function(e,t,a){"use strict";a.r(t),function(e,n){a.d(t,"GoogleSitekitAdminbar",(function(){return E})),a.d(t,"init",(function(){return j}));var i=a(5),o=a.n(i),s=a(6),r=a.n(s),l=a(7),c=a.n(l),d=a(8),u=a.n(d),g=a(16),m=a.n(g),p=a(9),h=a.n(p),b=a(19),_=a(3),f=(a(254),a(12)),k=a(1),y=a(79),v=a(0),S=a(364),O=a(106),E=function(t){function GoogleSitekitAdminbar(e){var t;return o()(this,GoogleSitekitAdminbar),(t=c()(this,u()(GoogleSitekitAdminbar).call(this,e))).handleMoreDetailsLink=t.handleMoreDetailsLink.bind(m()(t)),t}return h()(GoogleSitekitAdminbar,t),r()(GoogleSitekitAdminbar,[{key:"handleMoreDetailsLink",value:function(){var t=e.googlesitekit,a=t.permaLink,n=t.postID,i=t.postType,o=t.pageTitle,s=Object(_.n)("googlesitekit-dashboard",{permaLink:a,id:n,postType:i,pageTitle:o});Object(_.A)("admin_bar","post_details_click"),document.location=s}},{key:"render",value:function(){var t=e.googlesitekit,a=t.pageTitle,i=t.permaLink;return n.createElement(O.a,null,n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-3 mdc-layout-grid__cell--align-middle "},n.createElement("div",{className:"googlesitekit-adminbar__subtitle"},Object(v.__)("Stats for","google-site-kit")),n.createElement("div",{className:"googlesitekit-adminbar__title"},a?Object(_.d)(a):i)),n.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 "},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement(S.a,null))),n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-2 mdc-layout-grid__cell--align-middle "},n.createElement(b.a,{className:"googlesitekit-adminbar__link",href:"#",onClick:this.handleMoreDetailsLink},Object(v.__)("More details","google-site-kit"))))),n.createElement(b.a,{className:"googlesitekit-adminbar__link googlesitekit-adminbar__link--mobile",href:"#",onClick:this.handleMoreDetailsLink},Object(v.__)("More details","google-site-kit")))}}]),GoogleSitekitAdminbar}(k.Component);function j(){var e=document.getElementById("js-googlesitekit-adminbar-modules");e&&(Object(_.q)(),Object(y.render)(n.createElement(E,null),e),Object(f.d)("googlesitekit.moduleLoaded","Adminbar"))}}.call(this,a(15),a(1))},,,,,,,,,function(e,t,a){"use strict";(function(e){var n=a(5),i=a.n(n),o=a(6),s=a.n(o),r=a(7),l=a.n(r),c=a(8),d=a.n(c),u=a(9),g=a.n(u),m=a(60),p=a(1),h=function(t){function AdminbarModules(){return i()(this,AdminbarModules),l()(this,d()(AdminbarModules).apply(this,arguments))}return g()(AdminbarModules,t),s()(AdminbarModules,[{key:"render",value:function(){return e.createElement(p.Fragment,null)}}]),AdminbarModules}(p.Component);t.a=Object(m.a)("googlesitekit.AdminbarModules")(h)}).call(this,a(1))}]]);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
dist/assets/js/{chunk-googlesitekit-adminbar~chunk-googlesitekit-setup-wizard~chunk-googlesitekit-setup-wizard-proxy-b48debf2e0f11591ea2f.js → chunk-googlesitekit-adminbar~chunk-googlesitekit-setup-wizard~chunk-googlesitekit-setup-wizard-proxy-7b6a86fd3073896743e0.js}
RENAMED
@@ -1 +1 @@
|
|
1 |
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[0],{145:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(33),f=n(19),_=n(25),y=n(188),v=n.n(y),k=n(14),b=n.n(k),E=n(245),C=n(1),L=n(0),N=function(t){function Dialog(){var e;return i()(this,Dialog),(e=c()(this,u()(Dialog).call(this))).state={attributes:[Object(L.__)("Audience overview","google-site-kit"),Object(L.__)("Top pages","google-site-kit"),Object(L.__)("Top acquisition sources","google-site-kit"),Object(L.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(C.createRef)(),e}return m()(Dialog,t),l()(Dialog,[{key:"componentDidMount",value:function(){new _.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,a=t.handleDialog,i=t.title,o=t.provides,l=t.handleConfirm,r=t.subtitle,c=t.confirmButton,s=t.dependentModules,u=t.instanceId,d="googlesitekit-dialog-label-".concat(u),m="googlesitekit-dialog-description-".concat(u),g=!(!o||!o.length);return e.createElement("div",{ref:this.dialogRef,className:b()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":i?d:void 0,"aria-describedby":g?m:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(v.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},i&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},i),r&&e.createElement("p",{className:"mdc-dialog__lead"},r),g&&e.createElement("section",{id:m,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},o.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),s&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(L.__)("Note: ","google-site-kit")),s),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(p.a,{onClick:l,danger:!0},c||Object(L.__)("Disconnect","google-site-kit")),e.createElement(f.a,{className:"mdc-dialog__cancel-button",onClick:function(){return a()},inherit:!0},Object(L.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(C.Component);N.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},N.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null},t.a=Object(E.a)(N)}).call(this,n(1))},157:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(79),h=n(1),p=function(e){function Modal(e){var t;return i()(this,Modal),(t=c()(this,u()(Modal).call(this,e))).el=document.createElement("div"),t.root=document.querySelector(".googlesitekit-plugin")||document.body,t}return m()(Modal,e),l()(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(g.createPortal)(this.props.children,this.el)}}]),Modal}(h.Component)},189:function(e,t,n){"use strict";var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(60),h=n(1),p=function(e){function ErrorNotification(){return i()(this,ErrorNotification),c()(this,u()(ErrorNotification).apply(this,arguments))}return m()(ErrorNotification,e),l()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(h.Component);t.a=Object(g.a)("googlesitekit.ErrorNotification")(p)},190:function(e,t,n){"use strict";(function(e,a){var i=n(11),o=n.n(i),l=n(5),r=n.n(l),c=n(6),s=n.n(c),u=n(7),d=n.n(u),m=n(8),g=n.n(m),h=n(16),p=n.n(h),f=n(9),_=n.n(f),y=n(145),v=n(33),k=n(191),b=n(157),E=n(3),C=n(1),L=n(0),N=function(t){function UserMenu(e){var t;return r()(this,UserMenu),(t=d()(this,g()(UserMenu).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(C.createRef)(),t.menuRef=Object(C.createRef)(),t}return _()(UserMenu,t),s()(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.googlesitekit.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:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(E.c)(),document.location=Object(E.n)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),null,this)}},{key:"render",value:function(){var t=e.googlesitekit.admin,n=t.userData,i=n.email,o=void 0===i?"":i,l=n.picture,r=void 0===l?"":l,c=t.proxyPermissionsURL,s=this.state,u=s.dialogActive,d=s.menuOpen;return a.createElement(C.Fragment,null,a.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},a.createElement(v.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(L.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},o),a.createElement(k.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(L.__)("Disconnect","google-site-kit")].concat(c?[Object(L.__)("Manage sites...","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),a.createElement(b.a,null,a.createElement(y.a,{dialogActive:u,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(L.__)("Disconnect","google-site-kit"),subtitle:Object(L.__)("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(L.__)("Disconnect","google-site-kit"),provides:[]})))}}]),UserMenu}(C.Component);t.a=N}).call(this,n(15),n(1))},191:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(25),h=n(2),p=n.n(h),f=n(1),_=function(t){function Menu(e){var t;return i()(this,Menu),(t=c()(this,u()(Menu).call(this,e))).menuRef=Object(f.createRef)(),t}return m()(Menu,t),l()(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,a=t.menuItems,i=t.onSelected,o=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:o,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}(f.Component);_.propTypes={menuOpen:p.a.bool.isRequired,menuItems:p.a.array.isRequired,id:p.a.string.isRequired},t.a=_}).call(this,n(1))},193:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(19),f=n(14),_=n.n(f),y=n(1),v=function(t){function LayoutHeader(){return i()(this,LayoutHeader),c()(this,u()(LayoutHeader).apply(this,arguments))}return m()(LayoutHeader,t),l()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=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:_()("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(p.a,{href:i,external:!0,inherit:!0},a)))))}}]),LayoutHeader}(y.Component);v.propTypes={title:h.a.string,ctaLabel:h.a.string,ctaLink:h.a.string},v.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=v}).call(this,n(1))},194:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(58),f=n(1),_=function(t){function LayoutFooter(){return i()(this,LayoutFooter),c()(this,u()(LayoutFooter).apply(this,arguments))}return m()(LayoutFooter,t),l()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,a=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"},a&&n&&e.createElement(p.a,{className:"googlesitekit-data-block__source",name:n,href:a,external:!0}),i))))}}]),LayoutFooter}(f.Component);_.propTypes={ctaLabel:h.a.string,ctaLink:h.a.string},t.a=_}).call(this,n(1))},21:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(193),f=n(194),_=n(14),y=n.n(_),v=n(1),k=function(t){function Layout(){return i()(this,Layout),c()(this,u()(Layout).apply(this,arguments))}return m()(Layout,t),l()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,a=t.footer,i=t.children,o=t.title,l=t.headerCtaLabel,r=t.headerCtaLink,c=t.footerCtaLabel,s=t.footerCtaLink,u=t.footerContent,d=t.className,m=t.fill,g=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":m,"googlesitekit-layout--relative":g})},n&&e.createElement(p.a,{title:o,ctaLabel:l,ctaLink:r}),i,a&&e.createElement(f.a,{ctaLabel:c,ctaLink:s,footerContent:u}))}}]),Layout}(v.Component);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(1))},66:function(e,t,n){"use strict";(function(e,a){var i=n(5),o=n.n(i),l=n(6),r=n.n(l),c=n(7),s=n.n(c),u=n(8),d=n.n(u),m=n(9),g=n.n(m),h=n(189),p=n(135),f=n(190),_=n(1),y=function(t){function Header(){return o()(this,Header),s()(this,d()(Header).apply(this,arguments))}return g()(Header,t),r()(Header,[{key:"render",value:function(){var t=e.googlesitekit.setup.isAuthenticated;return a.createElement(_.Fragment,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(p.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(f.a,null))))),a.createElement(h.a,null))}}]),Header}(_.Component);t.a=y}).call(this,n(15),n(1))}}]);
|
1 |
+
(window.webpackJsonp=window.webpackJsonp||[]).push([[0],{149:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(33),f=n(19),_=n(25),y=n(190),v=n.n(y),k=n(14),b=n.n(k),E=n(247),C=n(1),L=n(0),N=function(t){function Dialog(){var e;return i()(this,Dialog),(e=c()(this,u()(Dialog).call(this))).state={attributes:[Object(L.__)("Audience overview","google-site-kit"),Object(L.__)("Top pages","google-site-kit"),Object(L.__)("Top acquisition sources","google-site-kit"),Object(L.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(C.createRef)(),e}return m()(Dialog,t),l()(Dialog,[{key:"componentDidMount",value:function(){new _.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,a=t.handleDialog,i=t.title,o=t.provides,l=t.handleConfirm,r=t.subtitle,c=t.confirmButton,s=t.dependentModules,u=t.instanceId,d="googlesitekit-dialog-label-".concat(u),m="googlesitekit-dialog-description-".concat(u),g=!(!o||!o.length);return e.createElement("div",{ref:this.dialogRef,className:b()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":i?d:void 0,"aria-describedby":g?m:void 0,"aria-hidden":n?"false":"true",tabIndex:"-1"},e.createElement("div",{className:"mdc-dialog__scrim"}," "),e.createElement(v.a,{active:n},e.createElement("div",null,e.createElement("div",{className:"mdc-dialog__container"},e.createElement("div",{className:"mdc-dialog__surface"},i&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},i),r&&e.createElement("p",{className:"mdc-dialog__lead"},r),g&&e.createElement("section",{id:m,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},o.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),s&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(L.__)("Note: ","google-site-kit")),s),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(p.a,{onClick:l,danger:!0},c||Object(L.__)("Disconnect","google-site-kit")),e.createElement(f.a,{className:"mdc-dialog__cancel-button",onClick:function(){return a()},inherit:!0},Object(L.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(C.Component);N.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},N.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null},t.a=Object(E.a)(N)}).call(this,n(1))},159:function(e,t,n){"use strict";n.d(t,"a",(function(){return p}));var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(80),h=n(1),p=function(e){function Modal(e){var t;return i()(this,Modal),(t=c()(this,u()(Modal).call(this,e))).el=document.createElement("div"),t.root=document.querySelector(".googlesitekit-plugin")||document.body,t}return m()(Modal,e),l()(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(g.createPortal)(this.props.children,this.el)}}]),Modal}(h.Component)},191:function(e,t,n){"use strict";var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(60),h=n(1),p=function(e){function ErrorNotification(){return i()(this,ErrorNotification),c()(this,u()(ErrorNotification).apply(this,arguments))}return m()(ErrorNotification,e),l()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(h.Component);t.a=Object(g.a)("googlesitekit.ErrorNotification")(p)},192:function(e,t,n){"use strict";(function(e,a){var i=n(11),o=n.n(i),l=n(5),r=n.n(l),c=n(6),s=n.n(c),u=n(7),d=n.n(u),m=n(8),g=n.n(m),h=n(16),p=n.n(h),f=n(9),_=n.n(f),y=n(149),v=n(33),k=n(193),b=n(159),E=n(3),C=n(1),L=n(0),N=function(t){function UserMenu(e){var t;return r()(this,UserMenu),(t=d()(this,g()(UserMenu).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(C.createRef)(),t.menuRef=Object(C.createRef)(),t}return _()(UserMenu,t),s()(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.googlesitekit.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:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(E.c)(),document.location=Object(E.n)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),null,this)}},{key:"render",value:function(){var t=e.googlesitekit.admin,n=t.userData,i=n.email,o=void 0===i?"":i,l=n.picture,r=void 0===l?"":l,c=t.proxyPermissionsURL,s=this.state,u=s.dialogActive,d=s.menuOpen;return a.createElement(C.Fragment,null,a.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},a.createElement(v.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(L.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},o),a.createElement(k.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(L.__)("Disconnect","google-site-kit")].concat(c?[Object(L.__)("Manage sites...","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),a.createElement(b.a,null,a.createElement(y.a,{dialogActive:u,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(L.__)("Disconnect","google-site-kit"),subtitle:Object(L.__)("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(L.__)("Disconnect","google-site-kit"),provides:[]})))}}]),UserMenu}(C.Component);t.a=N}).call(this,n(15),n(1))},193:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(25),h=n(2),p=n.n(h),f=n(1),_=function(t){function Menu(e){var t;return i()(this,Menu),(t=c()(this,u()(Menu).call(this,e))).menuRef=Object(f.createRef)(),t}return m()(Menu,t),l()(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,a=t.menuItems,i=t.onSelected,o=t.id;return e.createElement("div",{className:"mdc-menu mdc-menu-surface",ref:this.menuRef},e.createElement("ul",{id:o,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}(f.Component);_.propTypes={menuOpen:p.a.bool.isRequired,menuItems:p.a.array.isRequired,id:p.a.string.isRequired},t.a=_}).call(this,n(1))},195:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(19),f=n(14),_=n.n(f),y=n(1),v=function(t){function LayoutHeader(){return i()(this,LayoutHeader),c()(this,u()(LayoutHeader).apply(this,arguments))}return m()(LayoutHeader,t),l()(LayoutHeader,[{key:"render",value:function(){var t=this.props,n=t.title,a=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:_()("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(p.a,{href:i,external:!0,inherit:!0},a)))))}}]),LayoutHeader}(y.Component);v.propTypes={title:h.a.string,ctaLabel:h.a.string,ctaLink:h.a.string},v.defaultProps={title:"",ctaLabel:"",ctaLink:""},t.a=v}).call(this,n(1))},196:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(58),f=n(1),_=function(t){function LayoutFooter(){return i()(this,LayoutFooter),c()(this,u()(LayoutFooter).apply(this,arguments))}return m()(LayoutFooter,t),l()(LayoutFooter,[{key:"render",value:function(){var t=this.props,n=t.ctaLabel,a=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"},a&&n&&e.createElement(p.a,{className:"googlesitekit-data-block__source",name:n,href:a,external:!0}),i))))}}]),LayoutFooter}(f.Component);_.propTypes={ctaLabel:h.a.string,ctaLink:h.a.string},t.a=_}).call(this,n(1))},22:function(e,t,n){"use strict";(function(e){var a=n(5),i=n.n(a),o=n(6),l=n.n(o),r=n(7),c=n.n(r),s=n(8),u=n.n(s),d=n(9),m=n.n(d),g=n(2),h=n.n(g),p=n(195),f=n(196),_=n(14),y=n.n(_),v=n(1),k=function(t){function Layout(){return i()(this,Layout),c()(this,u()(Layout).apply(this,arguments))}return m()(Layout,t),l()(Layout,[{key:"render",value:function(){var t=this.props,n=t.header,a=t.footer,i=t.children,o=t.title,l=t.headerCtaLabel,r=t.headerCtaLink,c=t.footerCtaLabel,s=t.footerCtaLink,u=t.footerContent,d=t.className,m=t.fill,g=t.relative;return e.createElement("div",{className:y()("googlesitekit-layout",d,{"googlesitekit-layout--fill":m,"googlesitekit-layout--relative":g})},n&&e.createElement(p.a,{title:o,ctaLabel:l,ctaLink:r}),i,a&&e.createElement(f.a,{ctaLabel:c,ctaLink:s,footerContent:u}))}}]),Layout}(v.Component);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(1))},66:function(e,t,n){"use strict";(function(e,a){var i=n(5),o=n.n(i),l=n(6),r=n.n(l),c=n(7),s=n.n(c),u=n(8),d=n.n(u),m=n(9),g=n.n(m),h=n(191),p=n(137),f=n(192),_=n(1),y=function(t){function Header(){return o()(this,Header),s()(this,d()(Header).apply(this,arguments))}return g()(Header,t),r()(Header,[{key:"render",value:function(){var t=e.googlesitekit.setup.isAuthenticated;return a.createElement(_.Fragment,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(p.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(f.a,null))))),a.createElement(h.a,null))}}]),Header}(_.Component);t.a=y}).call(this,n(15),n(1))}}]);
|
dist/assets/js/{chunk-googlesitekit-setup-wizard-bef2f7ac6eca50d2f9fb.js → chunk-googlesitekit-setup-wizard-bd097cea8a9b4de38b8d.js}
RENAMED
@@ -1,7 +1,7 @@
|
|
1 |
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[3,19],{188:function(e,t,n){"use strict";var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}();var r=n(1),o=n(79),a=n(251),s=function(e){function FocusTrap(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FocusTrap);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(FocusTrap.__proto__||Object.getPrototypeOf(FocusTrap)).call(this,e));return t.setFocusTrapElement=function(e){t.focusTrapElement=e},"undefined"!=typeof document&&(t.previouslyFocusedElement=document.activeElement),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(FocusTrap,e),i(FocusTrap,[{key:"componentDidMount",value:function(){var e=this.props.focusTrapOptions,t={returnFocusOnDeactivate:!1};for(var n in e)e.hasOwnProperty(n)&&"returnFocusOnDeactivate"!==n&&(t[n]=e[n]);var i=o.findDOMNode(this.focusTrapElement);this.focusTrap=this.props._createFocusTrap(i,t),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()}},{key:"componentDidUpdate",value:function(e){if(e.active&&!this.props.active){var t={returnFocus:this.props.focusTrapOptions.returnFocusOnDeactivate||!1};this.focusTrap.deactivate(t)}else!e.active&&this.props.active&&this.focusTrap.activate();e.paused&&!this.props.paused?this.focusTrap.unpause():!e.paused&&this.props.paused&&this.focusTrap.pause()}},{key:"componentWillUnmount",value:function(){this.focusTrap.deactivate(),!1!==this.props.focusTrapOptions.returnFocusOnDeactivate&&this.previouslyFocusedElement&&this.previouslyFocusedElement.focus&&this.previouslyFocusedElement.focus()}},{key:"render",value:function(){var e=this,t=r.Children.only(this.props.children);return r.cloneElement(t,{ref:function(n){e.setFocusTrapElement(n),"function"==typeof t.ref&&t.ref(n)}})}}]),FocusTrap}(r.Component);s.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:a},e.exports=s},245:function(e,t,n){"use strict";function i(){return(i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e}).apply(this,arguments)}function r(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var l=n(1),u=n(13);var p=function(e,t){return function(n){var i=e(n),r=n.displayName,o=void 0===r?n.name||"Component":r;return i.displayName="".concat(Object(u.upperFirst)(Object(u.camelCase)(t)),"(").concat(o,")"),i}};t.a=p((function(e){var t=0;return(function(n){function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=a(this,s(o).apply(this,arguments))).instanceId=t++,e}var u,p,d;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(o,n),u=o,(p=[{key:"render",value:function(){return Object(l.createElement)(e,i({},this.props,{instanceId:this.instanceId}))}}])&&r(u.prototype,p),d&&r(u,d),o}(l.Component))}),"withInstanceId")},251:function(e,t,n){var i=n(252),r=n(134),o=null;function a(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,s="string"==typeof e?n.querySelector(e):e,c=r({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),l={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},u={activate:function(e){if(l.active)return;_(),l.active=!0,l.paused=!1,l.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:c.onActivate;t&&t();return d(),u},deactivate:p,pause:function(){if(l.paused||!l.active)return;l.paused=!0,g()},unpause:function(){if(!l.paused||!l.active)return;l.paused=!1,d()}};return u;function p(e){if(l.active){g(),l.active=!1,l.paused=!1;var t=e&&void 0!==e.onDeactivate?e.onDeactivate:c.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:c.returnFocusOnDeactivate)&&a((function(){k(l.nodeFocusedBeforeActivation)})),u}}function d(){if(l.active)return o&&o.pause(),o=u,_(),a((function(){k(h())})),n.addEventListener("focusin",v,!0),n.addEventListener("mousedown",f,!0),n.addEventListener("touchstart",f,!0),n.addEventListener("click",y,!0),n.addEventListener("keydown",b,!0),u}function g(){if(l.active&&o===u)return n.removeEventListener("focusin",v,!0),n.removeEventListener("mousedown",f,!0),n.removeEventListener("touchstart",f,!0),n.removeEventListener("click",y,!0),n.removeEventListener("keydown",b,!0),o=null,u}function m(e){var t=c[e],i=t;if(!t)return null;if("string"==typeof t&&!(i=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(i=t()))throw new Error("`"+e+"` did not return a node");return i}function h(){var e;if(!(e=null!==m("initialFocus")?m("initialFocus"):s.contains(n.activeElement)?n.activeElement:l.firstTabbableNode||m("fallbackFocus")))throw new Error("You can't have a focus-trap without at least one focusable element");return e}function f(e){s.contains(e.target)||(c.clickOutsideDeactivates?p({returnFocus:!i.isFocusable(e.target)}):e.preventDefault())}function v(e){s.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),k(l.mostRecentlyFocusedNode||h()))}function b(e){if(!1!==c.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void p();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(_(),e.shiftKey&&e.target===l.firstTabbableNode)return e.preventDefault(),void k(l.lastTabbableNode);if(!e.shiftKey&&e.target===l.lastTabbableNode)e.preventDefault(),k(l.firstTabbableNode)}(e)}function y(e){c.clickOutsideDeactivates||s.contains(e.target)||(e.preventDefault(),e.stopImmediatePropagation())}function _(){var e=i(s);l.firstTabbableNode=e[0]||h(),l.lastTabbableNode=e[e.length-1]||h()}function k(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),l.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):k(h()))}}},252:function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],i=n.join(","),r="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function o(e,t){t=t||{};var n,o,s,c=[],p=[],d=new UntouchabilityChecker(e.ownerDocument||e),g=e.querySelectorAll(i);for(t.includeContainer&&r.call(e,i)&&(g=Array.prototype.slice.apply(g)).unshift(e),n=0;n<g.length;n++)a(o=g[n],d)&&(0===(s=l(o))?c.push(o):p.push({documentOrder:n,tabIndex:s,node:o}));return p.sort(u).map((function(e){return e.node})).concat(c)}function a(e,t){return!(!s(e,t)||function(e){return function(e){return p(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||l(e)<0)}function s(e,t){return t=t||new UntouchabilityChecker(e.ownerDocument||e),!(e.disabled||function(e){return p(e)&&"hidden"===e.type}(e)||t.isUntouchable(e))}o.isTabbable=function(e,t){if(!e)throw new Error("No node provided");return!1!==r.call(e,i)&&a(e,t)},o.isFocusable=function(e,t){if(!e)throw new Error("No node provided");return!1!==r.call(e,c)&&s(e,t)};var c=n.concat("iframe").join(",");function l(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function u(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function p(e){return"INPUT"===e.tagName}function UntouchabilityChecker(e){this.doc=e,this.cache=[]}UntouchabilityChecker.prototype.hasDisplayNone=function(e,t){if(e===this.doc.documentElement)return!1;var n=function(e,t){for(var n=0,i=e.length;n<i;n++)if(t(e[n]))return e[n]}(this.cache,(function(t){return t===e}));if(n)return n[1];var i=!1;return"none"===(t=t||this.doc.defaultView.getComputedStyle(e)).display?i=!0:e.parentNode&&(i=this.hasDisplayNone(e.parentNode)),this.cache.push([e,i]),i},UntouchabilityChecker.prototype.isUntouchable=function(e){if(e===this.doc.documentElement)return!1;var t=this.doc.defaultView.getComputedStyle(e);return!!this.hasDisplayNone(e,t)||"hidden"===t.visibility},e.exports=o},267:function(e,t,n){"use strict";(function(e){var i=n(22),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(16),m=n.n(g),h=n(9),f=n.n(h),v=n(268),b=n(2),y=n.n(b),_=n(3),k=n(14),S=n.n(k),E=n(52),C=n(1),w=n(0),O=n(55),N=function(t){function OptIn(e){var t;return a()(this,OptIn),(t=u()(this,d()(OptIn).call(this,e))).state={optIn:Object(O.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(m()(t)),t}return f()(OptIn,t),c()(OptIn,[{key:"handleOptIn",value:function(e){var t=this,n=!!e.target.checked,i=Object(_.k)("googlesitekit_tracking_optin");Object(O.b)(n),n&&Object(O.c)("tracking_plugin",this.props.optinAction),Object(E.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:r()({},i,n)}}).then((function(){t.setState({optIn:n,error:!1})})).catch((function(e){t.setState({optIn:!n,error:{errorCode:e.code,errorMsg:e.message}})}))}},{key:"render",value:function(){var t=this.state,n=t.optIn,i=t.error,r=this.props,o=r.id,a=r.name,s=r.className,c=Object(w.sprintf)(
|
2 |
/* translators: %s: privacy policy URL */
|
3 |
-
Object(w.__)('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:S()("googlesitekit-opt-in",s)},e.createElement(v.a,{id:o,name:a,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(_.w)(c,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),i&&e.createElement("div",{className:"googlesitekit-error-text"},i.errorMsg))}}]),OptIn}(C.Component);N.propTypes={id:y.a.string,name:y.a.string,className:y.a.string,optinAction:y.a.string},N.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=N}).call(this,n(1))},268:function(e,t,n){"use strict";(function(e){var i=n(5),r=n.n(i),o=n(6),a=n.n(o),s=n(7),c=n.n(s),l=n(8),u=n.n(l),p=n(9),d=n.n(p),g=n(25),m=n(2),h=n.n(m),f=n(14),v=n.n(f),b=n(1),y=function(t){function Checkbox(e){var t;return r()(this,Checkbox),(t=c()(this,u()(Checkbox).call(this,e))).formFieldRef=Object(b.createRef)(),t.checkboxRef=Object(b.createRef)(),t}return d()(Checkbox,t),a()(Checkbox,[{key:"componentDidMount",value:function(){new g.e(this.formFieldRef.current).input=new g.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,i=t.id,r=t.name,o=t.value,a=t.checked,s=t.disabled,c=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:v()("mdc-checkbox",{"mdc-checkbox--disabled":s}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:i,name:r,value:o,checked:a,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:i},c))}}]),Checkbox}(b.Component);y.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},y.defaultProps={checked:!1,disabled:!1},t.a=y}).call(this,n(1))},354:function(e,t,n){"use strict";n.r(t),function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(13),y=n(0),_=n(1),k=n(66),S=n(33),E=n(21),C=n(10),w=n(3),O=n(356),N=n(363),R=function(t){function Setup(t){var n;s()(this,Setup),n=p()(this,g()(Setup).call(this,t));var i=e.googlesitekit.admin.connectURL,r=e.googlesitekit.setup,o=r.isAuthenticated,a=r.hasSearchConsoleProperty,c=r.isSiteKitConnected,l=r.isVerified,u=r.needReauthenticate,d=e.googlesitekit.permissions.canSetup;return n.state={canSetup:d,isAuthenticated:o,isVerified:l,needReauthenticate:u,hasSearchConsoleProperty:a,hasSearchConsolePropertyFromTheStart:a,connectURL:i,errorMsg:"",isSiteKitConnected:c,completeSetup:!1},n.siteConnectedSetup=n.siteConnectedSetup.bind(h()(n)),n.siteVerificationSetup=n.siteVerificationSetup.bind(h()(n)),n.searchConsoleSetup=n.searchConsoleSetup.bind(h()(n)),n.resetAndRestart=n.resetAndRestart.bind(h()(n)),n.completeSetup=n.completeSetup.bind(h()(n)),n.setErrorMessage=n.setErrorMessage.bind(h()(n)),n}return v()(Setup,t),l()(Setup,[{key:"resetAndRestart",value:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.a.awrap(C.c.set(C.a,"site","reset"));case 2:Object(w.c)(),this.setState({isSiteKitConnected:!1,isAuthenticated:!1,isVerified:!1,hasSearchConsoleProperty:!1,completeSetup:!1,errorMsg:""});case 4:case"end":return e.stop()}}),null,this)}},{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,i=e.isVerified,r=e.hasSearchConsoleProperty,o=e.completeSetup;return t&&n&&i&&r&&o}},{key:"setErrorMessage",value:function(e){this.setState({errorMsg:e})}},{key:"getApplicableSteps",value:function(){var e,t=O.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,r=n.canSetup,o=n.isAuthenticated,a=n.isVerified,s=n.needReauthenticate,c=n.hasSearchConsoleProperty,l=n.connectURL,u=n.isSiteKitConnected;if(this.isSetupFinished()){var p=Object(w.n)("googlesitekit-dashboard",{notification:"authentication_success"});Object(b.delay)((function(){e.location.replace(p)}),500,"later")}var d=this.getApplicableSteps(),g=this.currentStep(d),m=d[g].Component,h=i.createElement(m,{siteConnectedSetup:this.siteConnectedSetup,connectURL:l,siteVerificationSetup:this.siteVerificationSetup,searchConsoleSetup:this.searchConsoleSetup,completeSetup:this.completeSetup,isSiteKitConnected:u,isAuthenticated:o,isVerified:a,needReauthenticate:s,hasSearchConsoleProperty:c,setErrorMessage:this.setErrorMessage,resetAndRestart:d.clientCredentials?this.resetAndRestart:void 0}),f=r,v=!f&&!o;return i.createElement(_.Fragment,null,i.createElement(k.a,null),i.createElement("div",{className:"googlesitekit-wizard"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement(E.a,null,i.createElement("section",{className:"googlesitekit-wizard-progress"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},f&&i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement("div",{className:"googlesitekit-wizard-progress__steps"},Object.keys(d).map((function(e,n){return i.createElement(N.a,{key:d[e].title,currentStep:g===e,title:d[e].title,step:n+1,status:t.stepStatus(d,e),warning:d[e].warning,error:d[e].error,stepKey:e})})))))),v&&i.createElement("div",{className:"googlesitekit-setup__footer"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement("h1",{className:"googlesitekit-setup__title"},Object(y.__)("Authenticate Site Kit","google-site-kit")),i.createElement("p",{className:"googlesitekit-setup__description"},Object(y.__)("Please sign into your Google account to begin.","google-site-kit")),i.createElement(S.a,{href:"#",onClick:function(){Object(w.A)("plugin_setup","signin_with_google"),document.location=l}},Object(y.__)("Sign in with Google","google-site-kit"))))))),f&&h))))))}}]),Setup}(_.Component);t.default=R}.call(this,n(15),n(1))},356:function(e,t,n){"use strict";var i=n(357),r=n(358),o=n(360),a=n(362),s=n(0),c={authentication:{title:Object(s.__)("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(s.__)("Verify URL","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified},Component:r.a},seachConsoleProperty:{title:Object(s.__)("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(s.__)("Finish","google-site-kit"),required:!1,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:a.a}};t.a=c},357:function(e,t,n){"use strict";(function(e){var i=n(5),r=n.n(i),o=n(6),a=n.n(o),s=n(7),c=n.n(s),l=n(8),u=n.n(l),p=n(9),d=n.n(p),g=n(2),m=n.n(g),h=n(33),f=n(19),v=n(3),b=n(267),y=n(65),_=n(0),k=n(1),S=function(t){function WizardStepAuthentication(){return r()(this,WizardStepAuthentication),c()(this,u()(WizardStepAuthentication).apply(this,arguments))}return d()(WizardStepAuthentication,t),a()(WizardStepAuthentication,[{key:"render",value:function(){var t=this.props,n=t.connectURL,i=t.needReauthenticate,r=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(_.__)("Authenticate with Google","google-site-kit")),e.createElement("p",null,Object(_.__)("Please sign into your Google account to begin.","google-site-kit")),i&&e.createElement("p",{className:"googlesitekit-error-text"},Object(_.__)("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(h.a,{onClick:function(){Object(v.A)("plugin_setup","signin_with_google"),document.location=n}},Object(_.__)("Sign in with Google","google-site-kit")),r&&e.createElement(f.a,{className:"googlesitekit-wizard-step__back",onClick:r},Object(_.__)("Back","google-site-kit"))),e.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},e.createElement(b.a,{optinAction:"analytics_optin_setup_fallback"}),e.createElement(y.a,null))))))}}]),WizardStepAuthentication}(k.Component);S.propTypes={connectURL:m.a.string.isRequired,resetAndRestart:m.a.func},t.a=S}).call(this,n(1))},358:function(e,t,n){"use strict";(function(e){var i=n(64),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(9),m=n.n(g),h=n(2),f=n.n(h),v=n(359),b=n(1),y=function(t){function WizardStepVerification(){return a()(this,WizardStepVerification),u()(this,d()(WizardStepVerification).apply(this,arguments))}return m()(WizardStepVerification,t),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,r()({shouldSetup:t},this.props))))))}}]),WizardStepVerification}(b.Component);y.propTypes={siteVerificationSetup:f.a.func.isRequired},t.a=y}).call(this,n(1))},359:function(e,t,n){"use strict";(function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(10),y=n(33),_=n(32),k=n(25),S=n(2),E=n.n(S),C=n(3),w=n(65),O=n(0),N=n(1),R=function(t){function SiteVerification(e){var t;s()(this,SiteVerification);var n=(t=p()(this,g()(SiteVerification).call(this,e))).props,i=n.isAuthenticated,r=n.shouldSetup;return t.state={loading:i&&r,loadingMsg:Object(O.__)("Getting your verified sites...","google-site-kit"),siteURL:" ",selectedURL:"",errorCode:!1,errorMsg:""},t.onProceed=t.onProceed.bind(h()(t)),t}return v()(SiteVerification,t),l()(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,n,i,r,a,s=this,c=this.props.setErrorMessage;o.a.async((function(l){for(;;)switch(l.prev=l.next){case 0:return l.prev=0,l.next=3,o.a.awrap(b.c.get(b.b,"site-verification","verification"));case 3:if(t=l.sent,n=t.verified,i=t.identifier,!n){l.next=16;break}return Object(C.A)("verification_setup","verification_check_true"),l.next=10,o.a.awrap(s.insertSiteVerification(i));case 10:if(!0!==l.sent.verified){l.next=14;break}return s.props.siteVerificationSetup(!0),l.abrupt("return",!0);case 14:l.next=17;break;case 16:Object(C.A)("verification_setup","verification_check_false");case 17:s.setState({loading:!1,siteURL:i}),l.next=26;break;case 20:l.prev=20,l.t0=l.catch(0),r=l.t0.message,Object(C.B)(l.t0.message)&&(a=JSON.parse(l.t0.message),r=a.error.message||l.t0.message),c(r),s.setState({loading:!1,errorCode:l.t0.code,errorMsg:r,siteURL:e.googlesitekit.admin.siteURL});case 26:case"end":return l.stop()}}),null,null,[[0,20]])}},{key:"insertSiteVerification",value:function(e){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,o.a.awrap(b.c.set(b.b,"site-verification","verification",{siteURL:e}));case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}))}},{key:"onProceed",value:function(){var t,n,i,r;return o.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return t=this.props.setErrorMessage,n=this.state.siteURL?this.state.siteURL:e.googlesitekit.admin.siteURL,t(""),this.setState({loading:!0,loadingMsg:Object(O.__)("Verifying...","google-site-kit"),errorCode:!1,errorMsg:""}),a.prev=4,a.next=7,o.a.awrap(this.insertSiteVerification(n));case 7:!0===a.sent.verified&&(Object(C.A)("verification_setup","verification_insert_tag"),this.props.siteVerificationSetup(!0)),a.next=17;break;case 11:a.prev=11,a.t0=a.catch(4),i=a.t0.message,Object(C.B)(a.t0.message)&&(r=JSON.parse(a.t0.message),i=r.error.message||a.t0.message),t(i),this.setState({loading:!1,errorCode:a.t0.code,errorMsg:i});case 17:case"end":return a.stop()}}),null,this,[[4,11]])}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.loadingMsg,r=e.siteURL,o=i.createElement(N.Fragment,null,n&&i.createElement("p",null,n),i.createElement(_.a,null));return t?o:i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-wizard-step__inputs"},i.createElement(k.l,{label:Object(O.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},i.createElement(k.b,{value:r}))),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(y.a,{onClick:this.onProceed},Object(O.__)("Continue","google-site-kit")),i.createElement(w.a,null)))}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,r=this.state.errorMsg;return n?i.createElement(N.Fragment,null,i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(O.__)("Verify URL","google-site-kit")),i.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(O.__)("We will need to verify your URL for Site Kit.","google-site-kit")),r&&0<r.length&&i.createElement("p",{className:"googlesitekit-error-text"},r),t&&this.renderForm()):SiteVerification.renderSetupDone()}}],[{key:"renderSetupDone",value:function(){return i.createElement(N.Fragment,null,i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(O.__)("Verify URL","google-site-kit")),i.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(O.__)("Congratulations, your site has been verified!","google-site-kit")))}}]),SiteVerification}(N.Component);R.propTypes={isAuthenticated:E.a.bool.isRequired,shouldSetup:E.a.bool.isRequired,siteVerificationSetup:E.a.func.isRequired,completeSetup:E.a.func,setErrorMessage:E.a.func.isRequired},t.a=R}).call(this,n(15),n(1))},360:function(e,t,n){"use strict";(function(e){var i=n(64),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(9),m=n.n(g),h=n(2),f=n.n(h),v=n(361),b=n(1),y=function(t){function WizardStepSearchConsoleProperty(){return a()(this,WizardStepSearchConsoleProperty),u()(this,d()(WizardStepSearchConsoleProperty).apply(this,arguments))}return m()(WizardStepSearchConsoleProperty,t),c()(WizardStepSearchConsoleProperty,[{key:"render",value:function(){var t=this.props,n=t.isVerified,i=t.hasSearchConsoleProperty,o=n&&!i;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 "},o?e.createElement(v.a,r()({shouldSetup:o},this.props)):v.a.connected()))))}}]),WizardStepSearchConsoleProperty}(b.Component);y.propTypes={searchConsoleSetup:f.a.func.isRequired},t.a=y}).call(this,n(1))},361:function(e,t,n){"use strict";(function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(10),y=n(32),_=n(25),k=n(2),S=n.n(k),E=n(33),C=n(65),w=n(3),O=n(0),N=n(1),R=function(t){function SearchConsole(t){var n;s()(this,SearchConsole),n=p()(this,g()(SearchConsole).call(this,t));var i=e.googlesitekit.admin.siteURL;return n.state={loading:!0,sites:!1,selectedURL:i,siteURL:i,connected:!1,errorCode:!1,errorMsg:""},n.handleURLSelect=n.handleURLSelect.bind(h()(n)),n.insertPropertyToSearchConsole=n.insertPropertyToSearchConsole.bind(h()(n)),n.submitPropertyEventHandler=n.submitPropertyEventHandler.bind(h()(n)),n}return v()(SearchConsole,t),l()(SearchConsole,[{key:"componentDidMount",value:function(){var e,t,n;return o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e=this.props,t=e.isAuthenticated,n=e.shouldSetup,t&&n){i.next=3;break}return i.abrupt("return");case 3:this.requestSearchConsoleSiteList();case 4:case"end":return i.stop()}}),null,this)}},{key:"requestSearchConsoleSiteList",value:function(){var e,t=this,n=this.props.setErrorMessage;o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return i.prev=0,i.next=3,o.a.awrap(b.c.get(b.b,"search-console","matched-sites"));case 3:if(1!==(e=i.sent).length){i.next=9;break}return i.next=7,o.a.awrap(t.insertPropertyToSearchConsole(e[0].siteURL));case 7:return t.props.searchConsoleSetup(e[0].siteURL),i.abrupt("return");case 9:if(e.length){i.next=11;break}throw{code:"no_property_matched",message:Object(O.__)("Your site has not been added to Search Console yet. Would you like to add it now?","google-site-kit")};case 11:throw n(""),t.setState({loading:!1,selectedURL:e[0].siteURL,sites:e}),{code:"multiple_properties_matched",message:Object(O.sprintf)(
|
4 |
/* translators: %d: the number of matching properties */
|
5 |
Object(O.__)("We found %d existing accounts. Please choose which one to use below.","google-site-kit"),e.length)};case 16:i.prev=16,i.t0=i.catch(0),n(i.t0.message),t.setState({loading:!1,errorCode:i.t0.code,errorMsg:i.t0.message});case 20:case"end":return i.stop()}}),null,null,[[0,16]])}},{key:"insertPropertyToSearchConsole",value:function(e){var t,n=arguments;return o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return t=n.length>1&&void 0!==n[1]&&n[1],i.next=3,o.a.awrap(b.c.set(b.b,"search-console","site",{siteURL:e}));case 3:t&&Object(w.A)("search_console_setup","add_new_sc_property"),this.setState({loading:!1,connected:!0});case 5:case"end":return i.stop()}}),null,this)}},{key:"submitPropertyEventHandler",value:function(){var e=this,t=this.state,n=t.selectedURL,i=t.errorCode,r=this.props.setErrorMessage;o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(e.insertPropertyToSearchConsole(n,"no_property_matched"===i));case 3:r(""),e.props.searchConsoleSetup(n),t.next=11;break;case 7:t.prev=7,t.t0=t.catch(0),r(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()}}),null,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 r=t.map((function(e){var t=e.siteURL;return t.startsWith("sc-domain:")&&(
|
6 |
/* translators: %s: Search Console property domain name */
|
7 |
-
t=Object(O.sprintf)(Object(O.__)("%s (domain property)","google-site-kit"),t.replace(/^sc-domain:/,""))),{label:t,value:e.siteURL}}));return i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-setup-module__inputs"},i.createElement(_.k,{enhanced:!0,name:"siteProperty",label:Object(O.__)("Choose URL","google-site-kit"),outlined:!0,onEnhancedChange:this.handleURLSelect,options:r,value:n})),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(E.a,{onClick:this.submitPropertyEventHandler},Object(O.__)("Continue","google-site-kit")),i.createElement(C.a,null)))}},{key:"noSiteForm",value:function(){var e=this.state.siteURL;return i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-setup-module__inputs"},i.createElement(_.l,{label:Object(O.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},i.createElement(_.b,{value:e}))),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(E.a,{onClick:this.submitPropertyEventHandler},Object(O.__)("Continue","google-site-kit")),i.createElement(C.a,null)))}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.sites;return t?i.createElement(N.Fragment,null,i.createElement("p",null,Object(O.__)("We’re locating your Search Console account.","google-site-kit")),i.createElement(y.a,null)):0===n.length?this.noSiteForm():this.matchedForm()}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,r=this.state,o=r.errorMsg,a=r.connected;return!n||a?SearchConsole.connected():i.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(O._x)("Search Console","Service name","google-site-kit")),o&&0<o.length&&i.createElement("p",{className:"googlesitekit-error-text"},o),t&&n&&this.renderForm())}}],[{key:"connected",value:function(){return i.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(O._x)("Search Console","Service name","google-site-kit")),i.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(O.__)("Your Search Console is set up with Site Kit.","google-site-kit")))}}]),SearchConsole}(N.Component);R.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,searchConsoleSetup:S.a.func.isRequired,setErrorMessage:S.a.func.isRequired},t.a=R}).call(this,n(15),n(1))},
|
1 |
+
(window.webpackJsonp=window.webpackJsonp||[]).push([[3,20],{190:function(e,t,n){"use strict";var i=function(){function e(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}return function(t,n,i){return n&&e(t.prototype,n),i&&e(t,i),t}}();var r=n(1),o=n(80),a=n(252),s=function(e){function FocusTrap(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FocusTrap);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(FocusTrap.__proto__||Object.getPrototypeOf(FocusTrap)).call(this,e));return t.setFocusTrapElement=function(e){t.focusTrapElement=e},"undefined"!=typeof document&&(t.previouslyFocusedElement=document.activeElement),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(FocusTrap,e),i(FocusTrap,[{key:"componentDidMount",value:function(){var e=this.props.focusTrapOptions,t={returnFocusOnDeactivate:!1};for(var n in e)e.hasOwnProperty(n)&&"returnFocusOnDeactivate"!==n&&(t[n]=e[n]);var i=o.findDOMNode(this.focusTrapElement);this.focusTrap=this.props._createFocusTrap(i,t),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()}},{key:"componentDidUpdate",value:function(e){if(e.active&&!this.props.active){var t={returnFocus:this.props.focusTrapOptions.returnFocusOnDeactivate||!1};this.focusTrap.deactivate(t)}else!e.active&&this.props.active&&this.focusTrap.activate();e.paused&&!this.props.paused?this.focusTrap.unpause():!e.paused&&this.props.paused&&this.focusTrap.pause()}},{key:"componentWillUnmount",value:function(){this.focusTrap.deactivate(),!1!==this.props.focusTrapOptions.returnFocusOnDeactivate&&this.previouslyFocusedElement&&this.previouslyFocusedElement.focus&&this.previouslyFocusedElement.focus()}},{key:"render",value:function(){var e=this,t=r.Children.only(this.props.children);return r.cloneElement(t,{ref:function(n){e.setFocusTrapElement(n),"function"==typeof t.ref&&t.ref(n)}})}}]),FocusTrap}(r.Component);s.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:a},e.exports=s},247:function(e,t,n){"use strict";function i(){return(i=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e}).apply(this,arguments)}function r(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function c(e,t){return(c=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var l=n(1),u=n(13);var p=function(e,t){return function(n){var i=e(n),r=n.displayName,o=void 0===r?n.name||"Component":r;return i.displayName="".concat(Object(u.upperFirst)(Object(u.camelCase)(t)),"(").concat(o,")"),i}};t.a=p((function(e){var t=0;return(function(n){function o(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,o),(e=a(this,s(o).apply(this,arguments))).instanceId=t++,e}var u,p,d;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&c(e,t)}(o,n),u=o,(p=[{key:"render",value:function(){return Object(l.createElement)(e,i({},this.props,{instanceId:this.instanceId}))}}])&&r(u.prototype,p),d&&r(u,d),o}(l.Component))}),"withInstanceId")},252:function(e,t,n){var i=n(253),r=n(136),o=null;function a(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,s="string"==typeof e?n.querySelector(e):e,c=r({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),l={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},u={activate:function(e){if(l.active)return;_(),l.active=!0,l.paused=!1,l.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:c.onActivate;t&&t();return d(),u},deactivate:p,pause:function(){if(l.paused||!l.active)return;l.paused=!0,g()},unpause:function(){if(!l.paused||!l.active)return;l.paused=!1,d()}};return u;function p(e){if(l.active){g(),l.active=!1,l.paused=!1;var t=e&&void 0!==e.onDeactivate?e.onDeactivate:c.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:c.returnFocusOnDeactivate)&&a((function(){k(l.nodeFocusedBeforeActivation)})),u}}function d(){if(l.active)return o&&o.pause(),o=u,_(),a((function(){k(h())})),n.addEventListener("focusin",v,!0),n.addEventListener("mousedown",f,!0),n.addEventListener("touchstart",f,!0),n.addEventListener("click",y,!0),n.addEventListener("keydown",b,!0),u}function g(){if(l.active&&o===u)return n.removeEventListener("focusin",v,!0),n.removeEventListener("mousedown",f,!0),n.removeEventListener("touchstart",f,!0),n.removeEventListener("click",y,!0),n.removeEventListener("keydown",b,!0),o=null,u}function m(e){var t=c[e],i=t;if(!t)return null;if("string"==typeof t&&!(i=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(i=t()))throw new Error("`"+e+"` did not return a node");return i}function h(){var e;if(!(e=null!==m("initialFocus")?m("initialFocus"):s.contains(n.activeElement)?n.activeElement:l.firstTabbableNode||m("fallbackFocus")))throw new Error("You can't have a focus-trap without at least one focusable element");return e}function f(e){s.contains(e.target)||(c.clickOutsideDeactivates?p({returnFocus:!i.isFocusable(e.target)}):e.preventDefault())}function v(e){s.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),k(l.mostRecentlyFocusedNode||h()))}function b(e){if(!1!==c.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void p();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(_(),e.shiftKey&&e.target===l.firstTabbableNode)return e.preventDefault(),void k(l.lastTabbableNode);if(!e.shiftKey&&e.target===l.lastTabbableNode)e.preventDefault(),k(l.firstTabbableNode)}(e)}function y(e){c.clickOutsideDeactivates||s.contains(e.target)||(e.preventDefault(),e.stopImmediatePropagation())}function _(){var e=i(s);l.firstTabbableNode=e[0]||h(),l.lastTabbableNode=e[e.length-1]||h()}function k(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),l.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):k(h()))}}},253:function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],i=n.join(","),r="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function o(e,t){t=t||{};var n,o,s,c=[],p=[],d=new UntouchabilityChecker(e.ownerDocument||e),g=e.querySelectorAll(i);for(t.includeContainer&&r.call(e,i)&&(g=Array.prototype.slice.apply(g)).unshift(e),n=0;n<g.length;n++)a(o=g[n],d)&&(0===(s=l(o))?c.push(o):p.push({documentOrder:n,tabIndex:s,node:o}));return p.sort(u).map((function(e){return e.node})).concat(c)}function a(e,t){return!(!s(e,t)||function(e){return function(e){return p(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||l(e)<0)}function s(e,t){return t=t||new UntouchabilityChecker(e.ownerDocument||e),!(e.disabled||function(e){return p(e)&&"hidden"===e.type}(e)||t.isUntouchable(e))}o.isTabbable=function(e,t){if(!e)throw new Error("No node provided");return!1!==r.call(e,i)&&a(e,t)},o.isFocusable=function(e,t){if(!e)throw new Error("No node provided");return!1!==r.call(e,c)&&s(e,t)};var c=n.concat("iframe").join(",");function l(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function u(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function p(e){return"INPUT"===e.tagName}function UntouchabilityChecker(e){this.doc=e,this.cache=[]}UntouchabilityChecker.prototype.hasDisplayNone=function(e,t){if(e===this.doc.documentElement)return!1;var n=function(e,t){for(var n=0,i=e.length;n<i;n++)if(t(e[n]))return e[n]}(this.cache,(function(t){return t===e}));if(n)return n[1];var i=!1;return"none"===(t=t||this.doc.defaultView.getComputedStyle(e)).display?i=!0:e.parentNode&&(i=this.hasDisplayNone(e.parentNode)),this.cache.push([e,i]),i},UntouchabilityChecker.prototype.isUntouchable=function(e){if(e===this.doc.documentElement)return!1;var t=this.doc.defaultView.getComputedStyle(e);return!!this.hasDisplayNone(e,t)||"hidden"===t.visibility},e.exports=o},268:function(e,t,n){"use strict";(function(e){var i=n(21),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(16),m=n.n(g),h=n(9),f=n.n(h),v=n(269),b=n(2),y=n.n(b),_=n(3),k=n(14),S=n.n(k),E=n(52),C=n(1),w=n(0),O=n(55),N=function(t){function OptIn(e){var t;return a()(this,OptIn),(t=u()(this,d()(OptIn).call(this,e))).state={optIn:Object(O.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(m()(t)),t}return f()(OptIn,t),c()(OptIn,[{key:"handleOptIn",value:function(e){var t=this,n=!!e.target.checked,i=Object(_.k)("googlesitekit_tracking_optin");Object(O.b)(n),n&&Object(O.c)("tracking_plugin",this.props.optinAction),Object(E.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:r()({},i,n)}}).then((function(){t.setState({optIn:n,error:!1})})).catch((function(e){t.setState({optIn:!n,error:{errorCode:e.code,errorMsg:e.message}})}))}},{key:"render",value:function(){var t=this.state,n=t.optIn,i=t.error,r=this.props,o=r.id,a=r.name,s=r.className,c=Object(w.sprintf)(
|
2 |
/* translators: %s: privacy policy URL */
|
3 |
+
Object(w.__)('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:S()("googlesitekit-opt-in",s)},e.createElement(v.a,{id:o,name:a,value:"1",checked:n,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(_.w)(c,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),i&&e.createElement("div",{className:"googlesitekit-error-text"},i.errorMsg))}}]),OptIn}(C.Component);N.propTypes={id:y.a.string,name:y.a.string,className:y.a.string,optinAction:y.a.string},N.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=N}).call(this,n(1))},269:function(e,t,n){"use strict";(function(e){var i=n(5),r=n.n(i),o=n(6),a=n.n(o),s=n(7),c=n.n(s),l=n(8),u=n.n(l),p=n(9),d=n.n(p),g=n(25),m=n(2),h=n.n(m),f=n(14),v=n.n(f),b=n(1),y=function(t){function Checkbox(e){var t;return r()(this,Checkbox),(t=c()(this,u()(Checkbox).call(this,e))).formFieldRef=Object(b.createRef)(),t.checkboxRef=Object(b.createRef)(),t}return d()(Checkbox,t),a()(Checkbox,[{key:"componentDidMount",value:function(){new g.e(this.formFieldRef.current).input=new g.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onChange,i=t.id,r=t.name,o=t.value,a=t.checked,s=t.disabled,c=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:v()("mdc-checkbox",{"mdc-checkbox--disabled":s}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:i,name:r,value:o,checked:a,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:i},c))}}]),Checkbox}(b.Component);y.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},y.defaultProps={checked:!1,disabled:!1},t.a=y}).call(this,n(1))},357:function(e,t,n){"use strict";n.r(t),function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(13),y=n(0),_=n(1),k=n(66),S=n(33),E=n(22),C=n(10),w=n(3),O=n(359),N=n(366),R=function(t){function Setup(t){var n;s()(this,Setup),n=p()(this,g()(Setup).call(this,t));var i=e.googlesitekit.admin.connectURL,r=e.googlesitekit.setup,o=r.isAuthenticated,a=r.hasSearchConsoleProperty,c=r.isSiteKitConnected,l=r.isVerified,u=r.needReauthenticate,d=e.googlesitekit.permissions.canSetup;return n.state={canSetup:d,isAuthenticated:o,isVerified:l,needReauthenticate:u,hasSearchConsoleProperty:a,hasSearchConsolePropertyFromTheStart:a,connectURL:i,errorMsg:"",isSiteKitConnected:c,completeSetup:!1},n.siteConnectedSetup=n.siteConnectedSetup.bind(h()(n)),n.siteVerificationSetup=n.siteVerificationSetup.bind(h()(n)),n.searchConsoleSetup=n.searchConsoleSetup.bind(h()(n)),n.resetAndRestart=n.resetAndRestart.bind(h()(n)),n.completeSetup=n.completeSetup.bind(h()(n)),n.setErrorMessage=n.setErrorMessage.bind(h()(n)),n}return v()(Setup,t),l()(Setup,[{key:"resetAndRestart",value:function(){return o.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,o.a.awrap(C.c.set(C.a,"site","reset"));case 2:Object(w.c)(),this.setState({isSiteKitConnected:!1,isAuthenticated:!1,isVerified:!1,hasSearchConsoleProperty:!1,completeSetup:!1,errorMsg:""});case 4:case"end":return e.stop()}}),null,this)}},{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,i=e.isVerified,r=e.hasSearchConsoleProperty,o=e.completeSetup;return t&&n&&i&&r&&o}},{key:"setErrorMessage",value:function(e){this.setState({errorMsg:e})}},{key:"getApplicableSteps",value:function(){var e,t=O.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,r=n.canSetup,o=n.isAuthenticated,a=n.isVerified,s=n.needReauthenticate,c=n.hasSearchConsoleProperty,l=n.connectURL,u=n.isSiteKitConnected;if(this.isSetupFinished()){var p=Object(w.n)("googlesitekit-dashboard",{notification:"authentication_success"});Object(b.delay)((function(){e.location.replace(p)}),500,"later")}var d=this.getApplicableSteps(),g=this.currentStep(d),m=d[g].Component,h=i.createElement(m,{siteConnectedSetup:this.siteConnectedSetup,connectURL:l,siteVerificationSetup:this.siteVerificationSetup,searchConsoleSetup:this.searchConsoleSetup,completeSetup:this.completeSetup,isSiteKitConnected:u,isAuthenticated:o,isVerified:a,needReauthenticate:s,hasSearchConsoleProperty:c,setErrorMessage:this.setErrorMessage,resetAndRestart:d.clientCredentials?this.resetAndRestart:void 0}),f=r,v=!f&&!o;return i.createElement(_.Fragment,null,i.createElement(k.a,null),i.createElement("div",{className:"googlesitekit-wizard"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement(E.a,null,i.createElement("section",{className:"googlesitekit-wizard-progress"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},f&&i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement("div",{className:"googlesitekit-wizard-progress__steps"},Object.keys(d).map((function(e,n){return i.createElement(N.a,{key:d[e].title,currentStep:g===e,title:d[e].title,step:n+1,status:t.stepStatus(d,e),warning:d[e].warning,error:d[e].error,stepKey:e})})))))),v&&i.createElement("div",{className:"googlesitekit-setup__footer"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},i.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},i.createElement("h1",{className:"googlesitekit-setup__title"},Object(y.__)("Authenticate Site Kit","google-site-kit")),i.createElement("p",{className:"googlesitekit-setup__description"},Object(y.__)("Please sign into your Google account to begin.","google-site-kit")),i.createElement(S.a,{href:"#",onClick:function(){Object(w.A)("plugin_setup","signin_with_google"),document.location=l}},Object(y.__)("Sign in with Google","google-site-kit"))))))),f&&h))))))}}]),Setup}(_.Component);t.default=R}.call(this,n(15),n(1))},359:function(e,t,n){"use strict";var i=n(360),r=n(361),o=n(363),a=n(365),s=n(0),c={authentication:{title:Object(s.__)("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(s.__)("Verify URL","google-site-kit"),required:!0,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified},Component:r.a},seachConsoleProperty:{title:Object(s.__)("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(s.__)("Finish","google-site-kit"),required:!1,isApplicable:function(){return!0},isCompleted:function(e){return e.isSiteKitConnected&&e.isAuthenticated&&e.isVerified&&e.hasSearchConsoleProperty},Component:a.a}};t.a=c},360:function(e,t,n){"use strict";(function(e){var i=n(5),r=n.n(i),o=n(6),a=n.n(o),s=n(7),c=n.n(s),l=n(8),u=n.n(l),p=n(9),d=n.n(p),g=n(2),m=n.n(g),h=n(33),f=n(19),v=n(3),b=n(268),y=n(65),_=n(0),k=n(1),S=function(t){function WizardStepAuthentication(){return r()(this,WizardStepAuthentication),c()(this,u()(WizardStepAuthentication).apply(this,arguments))}return d()(WizardStepAuthentication,t),a()(WizardStepAuthentication,[{key:"render",value:function(){var t=this.props,n=t.connectURL,i=t.needReauthenticate,r=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(_.__)("Authenticate with Google","google-site-kit")),e.createElement("p",null,Object(_.__)("Please sign into your Google account to begin.","google-site-kit")),i&&e.createElement("p",{className:"googlesitekit-error-text"},Object(_.__)("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(h.a,{onClick:function(){Object(v.A)("plugin_setup","signin_with_google"),document.location=n}},Object(_.__)("Sign in with Google","google-site-kit")),r&&e.createElement(f.a,{className:"googlesitekit-wizard-step__back",onClick:r},Object(_.__)("Back","google-site-kit"))),e.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},e.createElement(b.a,{optinAction:"analytics_optin_setup_fallback"}),e.createElement(y.a,null))))))}}]),WizardStepAuthentication}(k.Component);S.propTypes={connectURL:m.a.string.isRequired,resetAndRestart:m.a.func},t.a=S}).call(this,n(1))},361:function(e,t,n){"use strict";(function(e){var i=n(64),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(9),m=n.n(g),h=n(2),f=n.n(h),v=n(362),b=n(1),y=function(t){function WizardStepVerification(){return a()(this,WizardStepVerification),u()(this,d()(WizardStepVerification).apply(this,arguments))}return m()(WizardStepVerification,t),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,r()({shouldSetup:t},this.props))))))}}]),WizardStepVerification}(b.Component);y.propTypes={siteVerificationSetup:f.a.func.isRequired},t.a=y}).call(this,n(1))},362:function(e,t,n){"use strict";(function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(10),y=n(33),_=n(32),k=n(25),S=n(2),E=n.n(S),C=n(3),w=n(65),O=n(0),N=n(1),R=function(t){function SiteVerification(e){var t;s()(this,SiteVerification);var n=(t=p()(this,g()(SiteVerification).call(this,e))).props,i=n.isAuthenticated,r=n.shouldSetup;return t.state={loading:i&&r,loadingMsg:Object(O.__)("Getting your verified sites...","google-site-kit"),siteURL:" ",selectedURL:"",errorCode:!1,errorMsg:""},t.onProceed=t.onProceed.bind(h()(t)),t}return v()(SiteVerification,t),l()(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,n,i,r,a,s=this,c=this.props.setErrorMessage;o.a.async((function(l){for(;;)switch(l.prev=l.next){case 0:return l.prev=0,l.next=3,o.a.awrap(b.c.get(b.b,"site-verification","verification"));case 3:if(t=l.sent,n=t.verified,i=t.identifier,!n){l.next=16;break}return Object(C.A)("verification_setup","verification_check_true"),l.next=10,o.a.awrap(s.insertSiteVerification(i));case 10:if(!0!==l.sent.verified){l.next=14;break}return s.props.siteVerificationSetup(!0),l.abrupt("return",!0);case 14:l.next=17;break;case 16:Object(C.A)("verification_setup","verification_check_false");case 17:s.setState({loading:!1,siteURL:i}),l.next=26;break;case 20:l.prev=20,l.t0=l.catch(0),r=l.t0.message,Object(C.B)(l.t0.message)&&(a=JSON.parse(l.t0.message),r=a.error.message||l.t0.message),c(r),s.setState({loading:!1,errorCode:l.t0.code,errorMsg:r,siteURL:e.googlesitekit.admin.siteURL});case 26:case"end":return l.stop()}}),null,null,[[0,20]])}},{key:"insertSiteVerification",value:function(e){return o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.next=2,o.a.awrap(b.c.set(b.b,"site-verification","verification",{siteURL:e}));case 2:return t.abrupt("return",t.sent);case 3:case"end":return t.stop()}}))}},{key:"onProceed",value:function(){var t,n,i,r;return o.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return t=this.props.setErrorMessage,n=this.state.siteURL?this.state.siteURL:e.googlesitekit.admin.siteURL,t(""),this.setState({loading:!0,loadingMsg:Object(O.__)("Verifying...","google-site-kit"),errorCode:!1,errorMsg:""}),a.prev=4,a.next=7,o.a.awrap(this.insertSiteVerification(n));case 7:!0===a.sent.verified&&(Object(C.A)("verification_setup","verification_insert_tag"),this.props.siteVerificationSetup(!0)),a.next=17;break;case 11:a.prev=11,a.t0=a.catch(4),i=a.t0.message,Object(C.B)(a.t0.message)&&(r=JSON.parse(a.t0.message),i=r.error.message||a.t0.message),t(i),this.setState({loading:!1,errorCode:a.t0.code,errorMsg:i});case 17:case"end":return a.stop()}}),null,this,[[4,11]])}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.loadingMsg,r=e.siteURL,o=i.createElement(N.Fragment,null,n&&i.createElement("p",null,n),i.createElement(_.a,null));return t?o:i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-wizard-step__inputs"},i.createElement(k.l,{label:Object(O.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},i.createElement(k.b,{value:r}))),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(y.a,{onClick:this.onProceed},Object(O.__)("Continue","google-site-kit")),i.createElement(w.a,null)))}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,r=this.state.errorMsg;return n?i.createElement(N.Fragment,null,i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(O.__)("Verify URL","google-site-kit")),i.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(O.__)("We will need to verify your URL for Site Kit.","google-site-kit")),r&&0<r.length&&i.createElement("p",{className:"googlesitekit-error-text"},r),t&&this.renderForm()):SiteVerification.renderSetupDone()}}],[{key:"renderSetupDone",value:function(){return i.createElement(N.Fragment,null,i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(O.__)("Verify URL","google-site-kit")),i.createElement("p",{className:"googlesitekit-wizard-step__text"},Object(O.__)("Congratulations, your site has been verified!","google-site-kit")))}}]),SiteVerification}(N.Component);R.propTypes={isAuthenticated:E.a.bool.isRequired,shouldSetup:E.a.bool.isRequired,siteVerificationSetup:E.a.func.isRequired,completeSetup:E.a.func,setErrorMessage:E.a.func.isRequired},t.a=R}).call(this,n(15),n(1))},363:function(e,t,n){"use strict";(function(e){var i=n(64),r=n.n(i),o=n(5),a=n.n(o),s=n(6),c=n.n(s),l=n(7),u=n.n(l),p=n(8),d=n.n(p),g=n(9),m=n.n(g),h=n(2),f=n.n(h),v=n(364),b=n(1),y=function(t){function WizardStepSearchConsoleProperty(){return a()(this,WizardStepSearchConsoleProperty),u()(this,d()(WizardStepSearchConsoleProperty).apply(this,arguments))}return m()(WizardStepSearchConsoleProperty,t),c()(WizardStepSearchConsoleProperty,[{key:"render",value:function(){var t=this.props,n=t.isVerified,i=t.hasSearchConsoleProperty,o=n&&!i;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 "},o?e.createElement(v.a,r()({shouldSetup:o},this.props)):v.a.connected()))))}}]),WizardStepSearchConsoleProperty}(b.Component);y.propTypes={searchConsoleSetup:f.a.func.isRequired},t.a=y}).call(this,n(1))},364:function(e,t,n){"use strict";(function(e,i){var r=n(11),o=n.n(r),a=n(5),s=n.n(a),c=n(6),l=n.n(c),u=n(7),p=n.n(u),d=n(8),g=n.n(d),m=n(16),h=n.n(m),f=n(9),v=n.n(f),b=n(10),y=n(32),_=n(25),k=n(2),S=n.n(k),E=n(33),C=n(65),w=n(3),O=n(0),N=n(1),R=function(t){function SearchConsole(t){var n;s()(this,SearchConsole),n=p()(this,g()(SearchConsole).call(this,t));var i=e.googlesitekit.admin.siteURL;return n.state={loading:!0,sites:!1,selectedURL:i,siteURL:i,connected:!1,errorCode:!1,errorMsg:""},n.handleURLSelect=n.handleURLSelect.bind(h()(n)),n.insertPropertyToSearchConsole=n.insertPropertyToSearchConsole.bind(h()(n)),n.submitPropertyEventHandler=n.submitPropertyEventHandler.bind(h()(n)),n}return v()(SearchConsole,t),l()(SearchConsole,[{key:"componentDidMount",value:function(){var e,t,n;return o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e=this.props,t=e.isAuthenticated,n=e.shouldSetup,t&&n){i.next=3;break}return i.abrupt("return");case 3:this.requestSearchConsoleSiteList();case 4:case"end":return i.stop()}}),null,this)}},{key:"requestSearchConsoleSiteList",value:function(){var e,t=this,n=this.props.setErrorMessage;o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return i.prev=0,i.next=3,o.a.awrap(b.c.get(b.b,"search-console","matched-sites"));case 3:if(1!==(e=i.sent).length){i.next=9;break}return i.next=7,o.a.awrap(t.insertPropertyToSearchConsole(e[0].siteURL));case 7:return t.props.searchConsoleSetup(e[0].siteURL),i.abrupt("return");case 9:if(e.length){i.next=11;break}throw{code:"no_property_matched",message:Object(O.__)("Your site has not been added to Search Console yet. Would you like to add it now?","google-site-kit")};case 11:throw n(""),t.setState({loading:!1,selectedURL:e[0].siteURL,sites:e}),{code:"multiple_properties_matched",message:Object(O.sprintf)(
|
4 |
/* translators: %d: the number of matching properties */
|
5 |
Object(O.__)("We found %d existing accounts. Please choose which one to use below.","google-site-kit"),e.length)};case 16:i.prev=16,i.t0=i.catch(0),n(i.t0.message),t.setState({loading:!1,errorCode:i.t0.code,errorMsg:i.t0.message});case 20:case"end":return i.stop()}}),null,null,[[0,16]])}},{key:"insertPropertyToSearchConsole",value:function(e){var t,n=arguments;return o.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:return t=n.length>1&&void 0!==n[1]&&n[1],i.next=3,o.a.awrap(b.c.set(b.b,"search-console","site",{siteURL:e}));case 3:t&&Object(w.A)("search_console_setup","add_new_sc_property"),this.setState({loading:!1,connected:!0});case 5:case"end":return i.stop()}}),null,this)}},{key:"submitPropertyEventHandler",value:function(){var e=this,t=this.state,n=t.selectedURL,i=t.errorCode,r=this.props.setErrorMessage;o.a.async((function(t){for(;;)switch(t.prev=t.next){case 0:return t.prev=0,t.next=3,o.a.awrap(e.insertPropertyToSearchConsole(n,"no_property_matched"===i));case 3:r(""),e.props.searchConsoleSetup(n),t.next=11;break;case 7:t.prev=7,t.t0=t.catch(0),r(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()}}),null,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 r=t.map((function(e){var t=e.siteURL;return t.startsWith("sc-domain:")&&(
|
6 |
/* translators: %s: Search Console property domain name */
|
7 |
+
t=Object(O.sprintf)(Object(O.__)("%s (domain property)","google-site-kit"),t.replace(/^sc-domain:/,""))),{label:t,value:e.siteURL}}));return i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-setup-module__inputs"},i.createElement(_.k,{enhanced:!0,name:"siteProperty",label:Object(O.__)("Choose URL","google-site-kit"),outlined:!0,onEnhancedChange:this.handleURLSelect,options:r,value:n})),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(E.a,{onClick:this.submitPropertyEventHandler},Object(O.__)("Continue","google-site-kit")),i.createElement(C.a,null)))}},{key:"noSiteForm",value:function(){var e=this.state.siteURL;return i.createElement(N.Fragment,null,i.createElement("div",{className:"googlesitekit-setup-module__inputs"},i.createElement(_.l,{label:Object(O.__)("Website Address","google-site-kit"),name:"siteProperty",floatingLabelClassName:"mdc-floating-label--float-above",outlined:!0,disabled:!0},i.createElement(_.b,{value:e}))),i.createElement("div",{className:"googlesitekit-wizard-step__action googlesitekit-wizard-step__action--justify"},i.createElement(E.a,{onClick:this.submitPropertyEventHandler},Object(O.__)("Continue","google-site-kit")),i.createElement(C.a,null)))}},{key:"renderForm",value:function(){var e=this.state,t=e.loading,n=e.sites;return t?i.createElement(N.Fragment,null,i.createElement("p",null,Object(O.__)("We’re locating your Search Console account.","google-site-kit")),i.createElement(y.a,null)):0===n.length?this.noSiteForm():this.matchedForm()}},{key:"render",value:function(){var e=this.props,t=e.isAuthenticated,n=e.shouldSetup,r=this.state,o=r.errorMsg,a=r.connected;return!n||a?SearchConsole.connected():i.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(O._x)("Search Console","Service name","google-site-kit")),o&&0<o.length&&i.createElement("p",{className:"googlesitekit-error-text"},o),t&&n&&this.renderForm())}}],[{key:"connected",value:function(){return i.createElement("section",{className:"googlesitekit-setup-module googlesitekit-setup-module--search-console"},i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-setup-module__title "},Object(O._x)("Search Console","Service name","google-site-kit")),i.createElement("p",{className:"googlesitekit-setup-module__text--no-margin"},Object(O.__)("Your Search Console is set up with Site Kit.","google-site-kit")))}}]),SearchConsole}(N.Component);R.propTypes={isAuthenticated:S.a.bool.isRequired,shouldSetup:S.a.bool.isRequired,searchConsoleSetup:S.a.func.isRequired,setErrorMessage:S.a.func.isRequired},t.a=R}).call(this,n(15),n(1))},365:function(e,t,n){"use strict";(function(e,i){var r=n(5),o=n.n(r),a=n(6),s=n.n(a),c=n(7),l=n.n(c),u=n(8),p=n.n(u),d=n(9),g=n.n(d),m=n(2),h=n.n(m),f=n(33),v=n(3),b=n(0),y=n(1),_=function(t){function WizardStepCompleteSetup(t){var n;return o()(this,WizardStepCompleteSetup),n=l()(this,p()(WizardStepCompleteSetup).call(this,t)),e.googlesitekit.setup.hasSearchConsoleProperty?Object(v.A)("plugin_setup","user_verified"):Object(v.A)("plugin_setup","site_verified"),n}return g()(WizardStepCompleteSetup,t),s()(WizardStepCompleteSetup,[{key:"render",value:function(){return i.createElement("section",{className:"googlesitekit-wizard-step googlesitekit-wizard-step--five"},i.createElement("div",{className:"mdc-layout-grid"},i.createElement("div",{className:"mdc-layout-grid__inner"},i.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 "},i.createElement("h2",{className:" googlesitekit-heading-3 googlesitekit-wizard-step__title "},Object(b.__)("Congratulations!","google-site-kit")),i.createElement("p",null,Object(b.__)("You successfully completed the Site Kit setup and connected Search Console. Check the dashboard for more services to connect.","google-site-kit")),i.createElement("div",{className:"googlesitekit-wizard-step__action"},i.createElement(f.a,{id:"wizard-step-five-proceed",onClick:this.props.completeSetup},Object(b.__)("Go to Dashboard","google-site-kit")))),i.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 "},i.createElement("div",{className:"googlesitekit-rocket"},i.createElement("img",{className:"googlesitekit-rocket__body",alt:"",src:e.googlesitekit.admin.assetsRoot+"images/rocket-body.png"}),i.createElement("img",{className:"googlesitekit-rocket__clouds",alt:"",src:e.googlesitekit.admin.assetsRoot+"images/rocket-clouds.png"}),i.createElement("img",{className:"googlesitekit-rocket__dust",alt:"",src:e.googlesitekit.admin.assetsRoot+"images/rocket-dust.png"}))))))}}]),WizardStepCompleteSetup}(y.Component);_.propTypes={completeSetup:h.a.func.isRequired},t.a=_}).call(this,n(15),n(1))},366:function(e,t,n){"use strict";var i=n(5),r=n.n(i),o=n(6),a=n.n(o),s=n(7),c=n.n(s),l=n(8),u=n.n(l),p=n(9),d=n.n(p),g=n(2),m=n.n(g),h=n(24),f=n(1),v=n.n(f),b=n(14),y=n.n(b),_=function(e){function WizardProgressStep(){return r()(this,WizardProgressStep),c()(this,u()(WizardProgressStep).apply(this,arguments))}return d()(WizardProgressStep,e),a()(WizardProgressStep,[{key:"render",value:function(){var e=this.props,t=e.currentStep,n=e.step,i=e.title,r=e.status,o=e.warning,a=e.error,s=e.stepKey,c=r;o?c="warning":a&&(c="error");var l=!1;switch(c){case"warning":case"error":l=v.a.createElement(h.a,{id:"exclamation",height:"12",width:"2"});break;case"completed":l=v.a.createElement(h.a,{id:"check",height:"12",width:"16"})}return v.a.createElement("div",{className:y()("googlesitekit-wizard-progress-step","googlesitekit-wizard-progress-step--".concat(n),"googlesitekit-wizard-progress-step--".concat(s),{"googlesitekit-wizard-progress-step--current":t})},v.a.createElement("div",{className:"googlesitekit-wizard-progress-step__number-wrapper"},v.a.createElement("div",{className:y()("googlesitekit-wizard-progress-step__number","googlesitekit-wizard-progress-step__number--".concat(c))},v.a.createElement("span",{className:y()("googlesitekit-wizard-progress-step__number-text","googlesitekit-wizard-progress-step__number-text--".concat(c))},n),l&&v.a.createElement("span",{className:y()("googlesitekit-wizard-progress-step__number-icon","googlesitekit-wizard-progress-step__number-icon--".concat(c))},l))),v.a.createElement("p",{className:"googlesitekit-wizard-progress-step__text"},i))}}]),WizardProgressStep}(f.Component);_.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},_.defaultProps={title:"",status:"",warning:!1,error:!1,removeFirstStep:!1},t.a=_},65:function(e,t,n){"use strict";(function(e){var i=n(0),r=n(19);t.a=function HelpLink(){var t=Object(i.__)("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(1))}}]);
|
dist/assets/js/{chunk-googlesitekit-setup-wizard-proxy-9ca0095ac2fc2ef8d455.js → chunk-googlesitekit-setup-wizard-proxy-7d6f526304725b8d08d5.js}
RENAMED
@@ -1,5 +1,5 @@
|
|
1 |
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{
|
2 |
/* translators: %s: privacy policy URL */
|
3 |
-
Object(R.__)('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:O()("googlesitekit-opt-in",c)},e.createElement(f.a,{id:a,name:s,value:"1",checked:i,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(v.w)(l,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),n&&e.createElement("div",{className:"googlesitekit-error-text"},n.errorMsg))}}]),OptIn}(E.Component);w.propTypes={id:_.a.string,name:_.a.string,className:_.a.string,optinAction:_.a.string},w.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=w}).call(this,i(1))},
|
4 |
/* translators: %s is the site's hostname. (e.g. example.com) */
|
5 |
Object(S.__)("You revoked access to Site Kit for %s","google-site-kit"),g),o=Object(S.__)('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"),a=Object(S.__)("Sign in with Google","google-site-kit")):m?(i=Object(S.__)("Sign in with Google to configure Site Kit","google-site-kit"),o=Object(S.__)("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"),a=Object(S.__)("Sign in with Google","google-site-kit")):(i=Object(S.__)("Sign in with Google to set up Site Kit","google-site-kit"),o=Object(S.__)("The Site Kit service will guide you through 3 simple setup steps.","google-site-kit"),a=Object(S.__)("Start setup","google-site-kit")),n.createElement(O.Fragment,null,n.createElement(h.a,null),l&&n.createElement(b.a,{id:"setup_error",type:"win-error",title:Object(S.__)("Oops! There was a problem during set up. Please try again.","google-site-kit"),description:l,isDismissable:!1}),d&&n.createElement(b.a,{id:"reset_success",title:Object(S.__)("Site Kit by Google was successfully reset.","google-site-kit"),isDismissable:!1}),n.createElement("div",{className:"googlesitekit-wizard"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(f.a,null,n.createElement("section",{className:"googlesitekit-wizard-progress"},n.createElement("div",{className:"googlesitekit-setup__footer"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("h1",{className:"googlesitekit-setup__title"},i),n.createElement("p",{className:"googlesitekit-setup__description"},o),n.createElement(R.a,null,(function(e){var t=e.complete,i=e.inProgressFeedback,o=e.CTAFeedback;return n.createElement(O.Fragment,null,o,n.createElement(_.a,{optinAction:"analytics_optin_setup_fallback"}),n.createElement("div",{className:"googlesitekit-start-setup-wrap"},n.createElement(p.a,{className:"googlesitekit-start-setup",href:u,onClick:function(){Object(v.A)("plugin_setup","proxy_start_setup_landing_page")},disabled:!t},a),i,r&&n.createElement(k.a,null)))})))))))))))))}}]),SetupUsingProxy}(O.Component);t.default=x}.call(this,i(15),i(1))}}]);
|
1 |
+
(window.webpackJsonp=window.webpackJsonp||[]).push([[4],{268:function(e,t,i){"use strict";(function(e){var n=i(21),o=i.n(n),a=i(5),s=i.n(a),c=i(6),l=i.n(c),r=i(7),u=i.n(r),d=i(8),g=i.n(d),m=i(16),h=i.n(m),p=i(9),k=i.n(p),f=i(269),b=i(2),_=i.n(b),v=i(3),y=i(14),O=i.n(y),S=i(52),E=i(1),R=i(0),x=i(55),w=function(t){function OptIn(e){var t;return s()(this,OptIn),(t=u()(this,g()(OptIn).call(this,e))).state={optIn:Object(x.a)(),error:!1},t.handleOptIn=t.handleOptIn.bind(h()(t)),t}return k()(OptIn,t),l()(OptIn,[{key:"handleOptIn",value:function(e){var t=this,i=!!e.target.checked,n=Object(v.k)("googlesitekit_tracking_optin");Object(x.b)(i),i&&Object(x.c)("tracking_plugin",this.props.optinAction),Object(S.default)({path:"/wp/v2/users/me",method:"POST",data:{meta:o()({},n,i)}}).then((function(){t.setState({optIn:i,error:!1})})).catch((function(e){t.setState({optIn:!i,error:{errorCode:e.code,errorMsg:e.message}})}))}},{key:"render",value:function(){var t=this.state,i=t.optIn,n=t.error,o=this.props,a=o.id,s=o.name,c=o.className,l=Object(R.sprintf)(
|
2 |
/* translators: %s: privacy policy URL */
|
3 |
+
Object(R.__)('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:O()("googlesitekit-opt-in",c)},e.createElement(f.a,{id:a,name:s,value:"1",checked:i,onChange:this.handleOptIn},e.createElement("span",{dangerouslySetInnerHTML:Object(v.w)(l,{ALLOWED_TAGS:["a"],ALLOWED_ATTR:["href","target","rel"]})})),n&&e.createElement("div",{className:"googlesitekit-error-text"},n.errorMsg))}}]),OptIn}(E.Component);w.propTypes={id:_.a.string,name:_.a.string,className:_.a.string,optinAction:_.a.string},w.defaultProps={id:"googlesitekit-opt-in",name:"optIn"},t.a=w}).call(this,i(1))},269:function(e,t,i){"use strict";(function(e){var n=i(5),o=i.n(n),a=i(6),s=i.n(a),c=i(7),l=i.n(c),r=i(8),u=i.n(r),d=i(9),g=i.n(d),m=i(25),h=i(2),p=i.n(h),k=i(14),f=i.n(k),b=i(1),_=function(t){function Checkbox(e){var t;return o()(this,Checkbox),(t=l()(this,u()(Checkbox).call(this,e))).formFieldRef=Object(b.createRef)(),t.checkboxRef=Object(b.createRef)(),t}return g()(Checkbox,t),s()(Checkbox,[{key:"componentDidMount",value:function(){new m.e(this.formFieldRef.current).input=new m.c(this.checkboxRef.current)}},{key:"render",value:function(){var t=this.props,i=t.onChange,n=t.id,o=t.name,a=t.value,s=t.checked,c=t.disabled,l=t.children;return e.createElement("div",{className:"mdc-form-field",ref:this.formFieldRef},e.createElement("div",{className:f()("mdc-checkbox",{"mdc-checkbox--disabled":c}),ref:this.checkboxRef},e.createElement("input",{className:"mdc-checkbox__native-control",type:"checkbox",id:n,name:o,value:a,checked:s,disabled:c,onChange:i}),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:n},l))}}]),Checkbox}(b.Component);_.propTypes={onChange:p.a.func.isRequired,id:p.a.string.isRequired,name:p.a.string.isRequired,value:p.a.string.isRequired,checked:p.a.bool,disabled:p.a.bool,children:p.a.node.isRequired},_.defaultProps={checked:!1,disabled:!1},t.a=_}).call(this,i(1))},291:function(e,t,i){"use strict";(function(e,n){i.d(t,"a",(function(){return x}));var o=i(11),a=i.n(o),s=i(5),c=i.n(s),l=i(6),r=i.n(l),u=i(7),d=i.n(u),g=i(8),m=i.n(g),h=i(16),p=i.n(h),k=i(9),f=i.n(k),b=i(10),_=i(3),v=i(149),y=i(0),O=i(1),S=i(45),E=i(19),R=i(159),x=function(t){function ResetButton(t){var i;c()(this,ResetButton),i=d()(this,m()(ResetButton).call(this,t));var n=e._googlesitekitBaseData.splashURL;return i.state={dialogActive:!1,postResetURL:Object(S.a)(n,{notification:"reset_success"})},i.handleDialog=i.handleDialog.bind(p()(i)),i.handleUnlinkConfirm=i.handleUnlinkConfirm.bind(p()(i)),i.handleCloseModal=i.handleCloseModal.bind(p()(i)),i}return f()(ResetButton,t),r()(ResetButton,[{key:"componentDidMount",value:function(){e.addEventListener("keyup",this.handleCloseModal,!1)}},{key:"componentWillUnmount",value:function(){e.removeEventListener("keyup",this.handleCloseModal)}},{key:"handleUnlinkConfirm",value:function(){return a.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:return e.next=2,a.a.awrap(b.c.set(b.a,"site","reset"));case 2:Object(_.c)(),this.handleDialog(),document.location=this.state.postResetURL;case 5:case"end":return e.stop()}}),null,this)}},{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,i=this.state.dialogActive;return n.createElement(O.Fragment,null,n.createElement(E.a,{className:"googlesitekit-reset-button",onClick:function(){return e.setState({dialogActive:!0})},inherit:!0},t||Object(y.__)("Reset Site Kit","google-site-kit")),n.createElement(R.a,null,n.createElement(v.a,{dialogActive:i,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(y.__)("Reset Site Kit","google-site-kit"),subtitle:Object(y.__)("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(y.__)("Reset","google-site-kit"),provides:[]})))}}]),ResetButton}(O.Component)}).call(this,i(15),i(1))},356:function(e,t,i){"use strict";i.r(t),function(e,n){var o=i(5),a=i.n(o),s=i(6),c=i.n(s),l=i(7),r=i.n(l),u=i(8),d=i.n(u),g=i(9),m=i.n(g),h=i(66),p=i(33),k=i(291),f=i(22),b=i(31),_=i(268),v=i(3),y=i(13),O=i(1),S=i(0),E=i(71),R=i(98),x=function(t){function SetupUsingProxy(t){var i;a()(this,SetupUsingProxy),i=r()(this,d()(SetupUsingProxy).call(this,t));var n=e.googlesitekit.admin,o=n.proxySetupURL,s=n.siteURL,c=e.googlesitekit.setup,l=c.isSiteKitConnected,u=c.isResettable,g=c.errorMessage,m=e.googlesitekit.permissions.canSetup;return i.state={canSetup:m,errorMessage:g,isSiteKitConnected:l,isResettable:u,completeSetup:!1,proxySetupURL:o,resetSuccess:"reset_success"===Object(E.a)(location.href,"notification"),context:Object(E.a)(location.href,"googlesitekit_context"),siteHostname:new URL(s).hostname},i}return m()(SetupUsingProxy,t),c()(SetupUsingProxy,[{key:"isSetupFinished",value:function(){var e=this.state,t=e.isSiteKitConnected,i=e.completeSetup;return t&&i}},{key:"render",value:function(){if(this.isSetupFinished()){var t=Object(v.n)("googlesitekit-dashboard",{notification:"authentication_success"});Object(y.delay)((function(){e.location.replace(t)}),500,"later")}var i,o,a,s=this.state,c=s.context,l=s.errorMessage,r=s.isResettable,u=s.proxySetupURL,d=s.resetSuccess,g=s.siteHostname,m=r;return"revoked"===c?(i=Object(S.sprintf)(
|
4 |
/* translators: %s is the site's hostname. (e.g. example.com) */
|
5 |
Object(S.__)("You revoked access to Site Kit for %s","google-site-kit"),g),o=Object(S.__)('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"),a=Object(S.__)("Sign in with Google","google-site-kit")):m?(i=Object(S.__)("Sign in with Google to configure Site Kit","google-site-kit"),o=Object(S.__)("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"),a=Object(S.__)("Sign in with Google","google-site-kit")):(i=Object(S.__)("Sign in with Google to set up Site Kit","google-site-kit"),o=Object(S.__)("The Site Kit service will guide you through 3 simple setup steps.","google-site-kit"),a=Object(S.__)("Start setup","google-site-kit")),n.createElement(O.Fragment,null,n.createElement(h.a,null),l&&n.createElement(b.a,{id:"setup_error",type:"win-error",title:Object(S.__)("Oops! There was a problem during set up. Please try again.","google-site-kit"),description:l,isDismissable:!1}),d&&n.createElement(b.a,{id:"reset_success",title:Object(S.__)("Site Kit by Google was successfully reset.","google-site-kit"),isDismissable:!1}),n.createElement("div",{className:"googlesitekit-wizard"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement(f.a,null,n.createElement("section",{className:"googlesitekit-wizard-progress"},n.createElement("div",{className:"googlesitekit-setup__footer"},n.createElement("div",{className:"mdc-layout-grid"},n.createElement("div",{className:"mdc-layout-grid__inner"},n.createElement("div",{className:" mdc-layout-grid__cell mdc-layout-grid__cell--span-12 "},n.createElement("h1",{className:"googlesitekit-setup__title"},i),n.createElement("p",{className:"googlesitekit-setup__description"},o),n.createElement(R.a,null,(function(e){var t=e.complete,i=e.inProgressFeedback,o=e.CTAFeedback;return n.createElement(O.Fragment,null,o,n.createElement(_.a,{optinAction:"analytics_optin_setup_fallback"}),n.createElement("div",{className:"googlesitekit-start-setup-wrap"},n.createElement(p.a,{className:"googlesitekit-start-setup",href:u,onClick:function(){Object(v.A)("plugin_setup","proxy_start_setup_landing_page")},disabled:!t},a),i,r&&n.createElement(k.a,null)))})))))))))))))}}]),SetupUsingProxy}(O.Component);t.default=x}.call(this,i(15),i(1))}}]);
|
dist/assets/js/{chunk-googlesitekit-setup-wrapper-998d2adcbb3bf10e34c2.js → chunk-googlesitekit-setup-wrapper-ac29c06e1e81b2730811.js}
RENAMED
@@ -1 +1 @@
|
|
1 |
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[5,19],{145:function(e,t,n){"use strict";(function(e){var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(2),f=n.n(p),h=n(33),v=n(19),g=n(25),y=n(188),b=n.n(y),_=n(14),k=n.n(_),E=n(245),O=n(1),N=n(0),D=function(t){function Dialog(){var e;return i()(this,Dialog),(e=u()(this,l()(Dialog).call(this))).state={attributes:[Object(N.__)("Audience overview","google-site-kit"),Object(N.__)("Top pages","google-site-kit"),Object(N.__)("Top acquisition sources","google-site-kit"),Object(N.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(O.createRef)(),e}return m()(Dialog,t),a()(Dialog,[{key:"componentDidMount",value:function(){new g.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,o=t.handleDialog,i=t.title,r=t.provides,a=t.handleConfirm,c=t.subtitle,u=t.confirmButton,s=t.dependentModules,l=t.instanceId,d="googlesitekit-dialog-label-".concat(l),m="googlesitekit-dialog-description-".concat(l),p=!(!r||!r.length);return e.createElement("div",{ref:this.dialogRef,className:k()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":i?d:void 0,"aria-describedby":p?m: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"},i&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},i),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),p&&e.createElement("section",{id:m,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},r.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),s&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(N.__)("Note: ","google-site-kit")),s),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(h.a,{onClick:a,danger:!0},u||Object(N.__)("Disconnect","google-site-kit")),e.createElement(v.a,{className:"mdc-dialog__cancel-button",onClick:function(){return o()},inherit:!0},Object(N.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(O.Component);D.propTypes={dialogActive:f.a.bool,handleDialog:f.a.func,handleConfirm:f.a.func.isRequired,title:f.a.string,description:f.a.string,confirmButton:f.a.string},D.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null},t.a=Object(E.a)(D)}).call(this,n(1))},157:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(79),f=n(1),h=function(e){function Modal(e){var t;return i()(this,Modal),(t=u()(this,l()(Modal).call(this,e))).el=document.createElement("div"),t.root=document.querySelector(".googlesitekit-plugin")||document.body,t}return m()(Modal,e),a()(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.createPortal)(this.props.children,this.el)}}]),Modal}(f.Component)},188:function(e,t,n){"use strict";var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();var i=n(1),r=n(79),a=n(251),c=function(e){function FocusTrap(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FocusTrap);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(FocusTrap.__proto__||Object.getPrototypeOf(FocusTrap)).call(this,e));return t.setFocusTrapElement=function(e){t.focusTrapElement=e},"undefined"!=typeof document&&(t.previouslyFocusedElement=document.activeElement),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(FocusTrap,e),o(FocusTrap,[{key:"componentDidMount",value:function(){var e=this.props.focusTrapOptions,t={returnFocusOnDeactivate:!1};for(var n in e)e.hasOwnProperty(n)&&"returnFocusOnDeactivate"!==n&&(t[n]=e[n]);var o=r.findDOMNode(this.focusTrapElement);this.focusTrap=this.props._createFocusTrap(o,t),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()}},{key:"componentDidUpdate",value:function(e){if(e.active&&!this.props.active){var t={returnFocus:this.props.focusTrapOptions.returnFocusOnDeactivate||!1};this.focusTrap.deactivate(t)}else!e.active&&this.props.active&&this.focusTrap.activate();e.paused&&!this.props.paused?this.focusTrap.unpause():!e.paused&&this.props.paused&&this.focusTrap.pause()}},{key:"componentWillUnmount",value:function(){this.focusTrap.deactivate(),!1!==this.props.focusTrapOptions.returnFocusOnDeactivate&&this.previouslyFocusedElement&&this.previouslyFocusedElement.focus&&this.previouslyFocusedElement.focus()}},{key:"render",value:function(){var e=this,t=i.Children.only(this.props.children);return i.cloneElement(t,{ref:function(n){e.setFocusTrapElement(n),"function"==typeof t.ref&&t.ref(n)}})}}]),FocusTrap}(i.Component);c.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:a},e.exports=c},189:function(e,t,n){"use strict";var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(60),f=n(1),h=function(e){function ErrorNotification(){return i()(this,ErrorNotification),u()(this,l()(ErrorNotification).apply(this,arguments))}return m()(ErrorNotification,e),a()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(f.Component);t.a=Object(p.a)("googlesitekit.ErrorNotification")(h)},190:function(e,t,n){"use strict";(function(e,o){var i=n(11),r=n.n(i),a=n(5),c=n.n(a),u=n(6),s=n.n(u),l=n(7),d=n.n(l),m=n(8),p=n.n(m),f=n(16),h=n.n(f),v=n(9),g=n.n(v),y=n(145),b=n(33),_=n(191),k=n(157),E=n(3),O=n(1),N=n(0),D=function(t){function UserMenu(e){var t;return c()(this,UserMenu),(t=d()(this,p()(UserMenu).call(this,e))).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(h()(t)),t.handleMenuClose=t.handleMenuClose.bind(h()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(h()(t)),t.handleDialog=t.handleDialog.bind(h()(t)),t.handleDialogClose=t.handleDialogClose.bind(h()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(h()(t)),t.menuButtonRef=Object(O.createRef)(),t.menuRef=Object(O.createRef)(),t}return g()(UserMenu,t),s()(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 o=e.googlesitekit.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(o);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:function(){return r.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(E.c)(),document.location=Object(E.n)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),null,this)}},{key:"render",value:function(){var t=e.googlesitekit.admin,n=t.userData,i=n.email,r=void 0===i?"":i,a=n.picture,c=void 0===a?"":a,u=t.proxyPermissionsURL,s=this.state,l=s.dialogActive,d=s.menuOpen;return o.createElement(O.Fragment,null,o.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},o.createElement(b.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:c?o.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},o.createElement("img",{className:"mdc-button__icon--image",src:c,alt:Object(N.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},r),o.createElement(_.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(N.__)("Disconnect","google-site-kit")].concat(u?[Object(N.__)("Manage sites...","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),o.createElement(k.a,null,o.createElement(y.a,{dialogActive:l,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(N.__)("Disconnect","google-site-kit"),subtitle:Object(N.__)("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(N.__)("Disconnect","google-site-kit"),provides:[]})))}}]),UserMenu}(O.Component);t.a=D}).call(this,n(15),n(1))},191:function(e,t,n){"use strict";(function(e){var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(25),f=n(2),h=n.n(f),v=n(1),g=function(t){function Menu(e){var t;return i()(this,Menu),(t=u()(this,l()(Menu).call(this,e))).menuRef=Object(v.createRef)(),t}return m()(Menu,t),a()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new p.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,o=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"},o.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}(v.Component);g.propTypes={menuOpen:h.a.bool.isRequired,menuItems:h.a.array.isRequired,id:h.a.string.isRequired},t.a=g}).call(this,n(1))},245:function(e,t,n){"use strict";function o(){return(o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function i(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var s=n(1),l=n(13);var d=function(e,t){return function(n){var o=e(n),i=n.displayName,r=void 0===i?n.name||"Component":i;return o.displayName="".concat(Object(l.upperFirst)(Object(l.camelCase)(t)),"(").concat(r,")"),o}};t.a=d((function(e){var t=0;return(function(n){function r(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),(e=a(this,c(r).apply(this,arguments))).instanceId=t++,e}var l,d,m;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(r,n),l=r,(d=[{key:"render",value:function(){return Object(s.createElement)(e,o({},this.props,{instanceId:this.instanceId}))}}])&&i(l.prototype,d),m&&i(l,m),r}(s.Component))}),"withInstanceId")},251:function(e,t,n){var o=n(252),i=n(134),r=null;function a(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,c="string"==typeof e?n.querySelector(e):e,u=i({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),s={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},l={activate:function(e){if(s.active)return;_(),s.active=!0,s.paused=!1,s.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:u.onActivate;t&&t();return m(),l},deactivate:d,pause:function(){if(s.paused||!s.active)return;s.paused=!0,p()},unpause:function(){if(!s.paused||!s.active)return;s.paused=!1,m()}};return l;function d(e){if(s.active){p(),s.active=!1,s.paused=!1;var t=e&&void 0!==e.onDeactivate?e.onDeactivate:u.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:u.returnFocusOnDeactivate)&&a((function(){k(s.nodeFocusedBeforeActivation)})),l}}function m(){if(s.active)return r&&r.pause(),r=l,_(),a((function(){k(h())})),n.addEventListener("focusin",g,!0),n.addEventListener("mousedown",v,!0),n.addEventListener("touchstart",v,!0),n.addEventListener("click",b,!0),n.addEventListener("keydown",y,!0),l}function p(){if(s.active&&r===l)return n.removeEventListener("focusin",g,!0),n.removeEventListener("mousedown",v,!0),n.removeEventListener("touchstart",v,!0),n.removeEventListener("click",b,!0),n.removeEventListener("keydown",y,!0),r=null,l}function f(e){var t=u[e],o=t;if(!t)return null;if("string"==typeof t&&!(o=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(o=t()))throw new Error("`"+e+"` did not return a node");return o}function h(){var e;if(!(e=null!==f("initialFocus")?f("initialFocus"):c.contains(n.activeElement)?n.activeElement:s.firstTabbableNode||f("fallbackFocus")))throw new Error("You can't have a focus-trap without at least one focusable element");return e}function v(e){c.contains(e.target)||(u.clickOutsideDeactivates?d({returnFocus:!o.isFocusable(e.target)}):e.preventDefault())}function g(e){c.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),k(s.mostRecentlyFocusedNode||h()))}function y(e){if(!1!==u.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void d();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(_(),e.shiftKey&&e.target===s.firstTabbableNode)return e.preventDefault(),void k(s.lastTabbableNode);if(!e.shiftKey&&e.target===s.lastTabbableNode)e.preventDefault(),k(s.firstTabbableNode)}(e)}function b(e){u.clickOutsideDeactivates||c.contains(e.target)||(e.preventDefault(),e.stopImmediatePropagation())}function _(){var e=o(c);s.firstTabbableNode=e[0]||h(),s.lastTabbableNode=e[e.length-1]||h()}function k(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),s.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):k(h()))}}},252:function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],o=n.join(","),i="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function r(e,t){t=t||{};var n,r,c,u=[],d=[],m=new UntouchabilityChecker(e.ownerDocument||e),p=e.querySelectorAll(o);for(t.includeContainer&&i.call(e,o)&&(p=Array.prototype.slice.apply(p)).unshift(e),n=0;n<p.length;n++)a(r=p[n],m)&&(0===(c=s(r))?u.push(r):d.push({documentOrder:n,tabIndex:c,node:r}));return d.sort(l).map((function(e){return e.node})).concat(u)}function a(e,t){return!(!c(e,t)||function(e){return function(e){return d(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||s(e)<0)}function c(e,t){return t=t||new UntouchabilityChecker(e.ownerDocument||e),!(e.disabled||function(e){return d(e)&&"hidden"===e.type}(e)||t.isUntouchable(e))}r.isTabbable=function(e,t){if(!e)throw new Error("No node provided");return!1!==i.call(e,o)&&a(e,t)},r.isFocusable=function(e,t){if(!e)throw new Error("No node provided");return!1!==i.call(e,u)&&c(e,t)};var u=n.concat("iframe").join(",");function s(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function l(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function d(e){return"INPUT"===e.tagName}function UntouchabilityChecker(e){this.doc=e,this.cache=[]}UntouchabilityChecker.prototype.hasDisplayNone=function(e,t){if(e===this.doc.documentElement)return!1;var n=function(e,t){for(var n=0,o=e.length;n<o;n++)if(t(e[n]))return e[n]}(this.cache,(function(t){return t===e}));if(n)return n[1];var o=!1;return"none"===(t=t||this.doc.defaultView.getComputedStyle(e)).display?o=!0:e.parentNode&&(o=this.hasDisplayNone(e.parentNode)),this.cache.push([e,o]),o},UntouchabilityChecker.prototype.isUntouchable=function(e){if(e===this.doc.documentElement)return!1;var t=this.doc.defaultView.getComputedStyle(e);return!!this.hasDisplayNone(e,t)||"hidden"===t.visibility},e.exports=r},280:function(e,t,n){"use strict";n.r(t),function(e,o){var i=n(16),r=n.n(i),a=n(5),c=n.n(a),u=n(6),s=n.n(u),l=n(7),d=n.n(l),m=n(8),p=n.n(m),f=n(9),h=n.n(f),v=n(13),g=n(66),y=n(19),b=n(65),_=n(3),k=n(60),E=n(1),O=n(0),N=n(12),D=function(t){function BaseComponent(){return c()(this,BaseComponent),d()(this,p()(BaseComponent).apply(this,arguments))}return h()(BaseComponent,t),s()(BaseComponent,[{key:"render",value:function(){var t=this.props.children;return e.createElement(E.Fragment,null,t)}}]),BaseComponent}(E.Component),C=function(t){function SetupWrapper(e){var t;c()(this,SetupWrapper),t=d()(this,p()(SetupWrapper).call(this,e));var n=o.googlesitekit.setup.moduleToSetup;return t.state={currentModule:n,refresh:!1},t.timeoutID=null,t.unfocusedTime=0,t.autoRefreshModules=Object(N.c)("googlesitekit.autoRefreshModules",[]),t.moduleRefresh=t.autoRefreshModules.find((function(e){return t.state.currentModule===e.identifier})),t.refreshStatus=t.refreshStatus.bind(r()(t)),t.startUnfocusedTimer=t.startUnfocusedTimer.bind(r()(t)),t}return h()(SetupWrapper,t),s()(SetupWrapper,[{key:"componentDidMount",value:function(){o.addEventListener("focus",this.refreshStatus),o.addEventListener("blur",this.startUnfocusedTimer)}},{key:"componentWillUnmount",value:function(){o.removeEventListener("focus",this.refreshStatus),o.removeEventListener("blur",this.startUnfocusedTimer)}},{key:"startUnfocusedTimer",value:function(){var e=this;if(this.moduleRefresh){var t=!0;this.moduleRefresh.toRefresh&&(t=this.moduleRefresh.toRefresh()),t&&(this.timeoutID=o.setInterval((function(){e.unfocusedTime++}),1e3))}}},{key:"refreshStatus",value:function(){if(this.moduleRefresh){var e=this.moduleRefresh.idleTime||15,t=!0;this.moduleRefresh.toRefresh&&(t=this.moduleRefresh.toRefresh()),t&&(e<this.unfocusedTime&&this.setState({refresh:this.timeoutID}),o.clearTimeout(this.timeoutID),this.unfocusedTime=0,this.timeoutID=null)}}},{key:"render",value:function(){var t=this.state.currentModule,n=SetupWrapper.loadSetupModule(t),o=Object(_.n)("googlesitekit-settings",{});return e.createElement(E.Fragment,null,e.createElement(g.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(O.__)("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(y.a,{id:"setup-".concat(t,"-cancel"),href:o},Object(O.__)("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(b.a,null)))))))))))}}],[{key:"loadSetupModule",value:function(t){var n=Object(k.a)("googlesitekit.ModuleSetup-".concat(t))(D);return e.createElement(n,{finishSetup:SetupWrapper.finishSetup,onSettingsPage:!1,isEditing:!0})}},{key:"finishSetup",value:function(){var e={notification:"authentication_success"};o.googlesitekit.setup&&o.googlesitekit.setup.moduleToSetup&&(e.slug=o.googlesitekit.setup.moduleToSetup);var t=Object(_.n)("googlesitekit-dashboard",e);Object(v.delay)((function(){o.location.replace(t)}),500,"later")}}]),SetupWrapper}(E.Component);t.default=C}.call(this,n(1),n(15))},65:function(e,t,n){"use strict";(function(e){var o=n(0),i=n(19);t.a=function HelpLink(){var t=Object(o.__)("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(1))},66:function(e,t,n){"use strict";(function(e,o){var i=n(5),r=n.n(i),a=n(6),c=n.n(a),u=n(7),s=n.n(u),l=n(8),d=n.n(l),m=n(9),p=n.n(m),f=n(189),h=n(135),v=n(190),g=n(1),y=function(t){function Header(){return r()(this,Header),s()(this,d()(Header).apply(this,arguments))}return p()(Header,t),c()(Header,[{key:"render",value:function(){var t=e.googlesitekit.setup.isAuthenticated;return o.createElement(g.Fragment,null,o.createElement("header",{className:"googlesitekit-header"},o.createElement("section",{className:"mdc-layout-grid"},o.createElement("div",{className:"mdc-layout-grid__inner"},o.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 "},o.createElement(h.a,null)),o.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&&o.createElement(v.a,null))))),o.createElement(f.a,null))}}]),Header}(g.Component);t.a=y}).call(this,n(15),n(1))}}]);
|
1 |
+
(window.webpackJsonp=window.webpackJsonp||[]).push([[5,20],{149:function(e,t,n){"use strict";(function(e){var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(2),f=n.n(p),h=n(33),v=n(19),g=n(25),y=n(190),b=n.n(y),_=n(14),k=n.n(_),E=n(247),O=n(1),N=n(0),D=function(t){function Dialog(){var e;return i()(this,Dialog),(e=u()(this,l()(Dialog).call(this))).state={attributes:[Object(N.__)("Audience overview","google-site-kit"),Object(N.__)("Top pages","google-site-kit"),Object(N.__)("Top acquisition sources","google-site-kit"),Object(N.__)("AdSense & Analytics metrics for top pages","google-site-kit")]},e.dialogRef=Object(O.createRef)(),e}return m()(Dialog,t),a()(Dialog,[{key:"componentDidMount",value:function(){new g.d(this.dialogRef.current)}},{key:"render",value:function(){var t=this.props,n=t.dialogActive,o=t.handleDialog,i=t.title,r=t.provides,a=t.handleConfirm,c=t.subtitle,u=t.confirmButton,s=t.dependentModules,l=t.instanceId,d="googlesitekit-dialog-label-".concat(l),m="googlesitekit-dialog-description-".concat(l),p=!(!r||!r.length);return e.createElement("div",{ref:this.dialogRef,className:k()("mdc-dialog",{"mdc-dialog--open":n}),role:"alertdialog","aria-modal":"true","aria-labelledby":i?d:void 0,"aria-describedby":p?m: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"},i&&e.createElement("h2",{id:d,className:"mdc-dialog__title"},i),c&&e.createElement("p",{className:"mdc-dialog__lead"},c),p&&e.createElement("section",{id:m,className:"mdc-dialog__content"},e.createElement("ul",{className:"mdc-list mdc-list--underlined mdc-list--non-interactive"},r.map((function(t){return e.createElement("li",{className:"mdc-list-item",key:t},e.createElement("span",{className:"mdc-list-item__text"},t))})))),s&&e.createElement("p",{className:"mdc-dialog__dependecies"},e.createElement("strong",null,Object(N.__)("Note: ","google-site-kit")),s),e.createElement("footer",{className:"mdc-dialog__actions"},e.createElement(h.a,{onClick:a,danger:!0},u||Object(N.__)("Disconnect","google-site-kit")),e.createElement(v.a,{className:"mdc-dialog__cancel-button",onClick:function(){return o()},inherit:!0},Object(N.__)("Cancel","google-site-kit"))))))))}}]),Dialog}(O.Component);D.propTypes={dialogActive:f.a.bool,handleDialog:f.a.func,handleConfirm:f.a.func.isRequired,title:f.a.string,description:f.a.string,confirmButton:f.a.string},D.defaultProps={dialogActive:!1,handleDialog:null,title:null,description:null,confirmButton:null},t.a=Object(E.a)(D)}).call(this,n(1))},159:function(e,t,n){"use strict";n.d(t,"a",(function(){return h}));var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(80),f=n(1),h=function(e){function Modal(e){var t;return i()(this,Modal),(t=u()(this,l()(Modal).call(this,e))).el=document.createElement("div"),t.root=document.querySelector(".googlesitekit-plugin")||document.body,t}return m()(Modal,e),a()(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.createPortal)(this.props.children,this.el)}}]),Modal}(f.Component)},190:function(e,t,n){"use strict";var o=function(){function e(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}return function(t,n,o){return n&&e(t.prototype,n),o&&e(t,o),t}}();var i=n(1),r=n(80),a=n(252),c=function(e){function FocusTrap(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FocusTrap);var t=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(FocusTrap.__proto__||Object.getPrototypeOf(FocusTrap)).call(this,e));return t.setFocusTrapElement=function(e){t.focusTrapElement=e},"undefined"!=typeof document&&(t.previouslyFocusedElement=document.activeElement),t}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(FocusTrap,e),o(FocusTrap,[{key:"componentDidMount",value:function(){var e=this.props.focusTrapOptions,t={returnFocusOnDeactivate:!1};for(var n in e)e.hasOwnProperty(n)&&"returnFocusOnDeactivate"!==n&&(t[n]=e[n]);var o=r.findDOMNode(this.focusTrapElement);this.focusTrap=this.props._createFocusTrap(o,t),this.props.active&&this.focusTrap.activate(),this.props.paused&&this.focusTrap.pause()}},{key:"componentDidUpdate",value:function(e){if(e.active&&!this.props.active){var t={returnFocus:this.props.focusTrapOptions.returnFocusOnDeactivate||!1};this.focusTrap.deactivate(t)}else!e.active&&this.props.active&&this.focusTrap.activate();e.paused&&!this.props.paused?this.focusTrap.unpause():!e.paused&&this.props.paused&&this.focusTrap.pause()}},{key:"componentWillUnmount",value:function(){this.focusTrap.deactivate(),!1!==this.props.focusTrapOptions.returnFocusOnDeactivate&&this.previouslyFocusedElement&&this.previouslyFocusedElement.focus&&this.previouslyFocusedElement.focus()}},{key:"render",value:function(){var e=this,t=i.Children.only(this.props.children);return i.cloneElement(t,{ref:function(n){e.setFocusTrapElement(n),"function"==typeof t.ref&&t.ref(n)}})}}]),FocusTrap}(i.Component);c.defaultProps={active:!0,paused:!1,focusTrapOptions:{},_createFocusTrap:a},e.exports=c},191:function(e,t,n){"use strict";var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(60),f=n(1),h=function(e){function ErrorNotification(){return i()(this,ErrorNotification),u()(this,l()(ErrorNotification).apply(this,arguments))}return m()(ErrorNotification,e),a()(ErrorNotification,[{key:"render",value:function(){return null}}]),ErrorNotification}(f.Component);t.a=Object(p.a)("googlesitekit.ErrorNotification")(h)},192:function(e,t,n){"use strict";(function(e,o){var i=n(11),r=n.n(i),a=n(5),c=n.n(a),u=n(6),s=n.n(u),l=n(7),d=n.n(l),m=n(8),p=n.n(m),f=n(16),h=n.n(f),v=n(9),g=n.n(v),y=n(149),b=n(33),_=n(193),k=n(159),E=n(3),O=n(1),N=n(0),D=function(t){function UserMenu(e){var t;return c()(this,UserMenu),(t=d()(this,p()(UserMenu).call(this,e))).state={dialogActive:!1,menuOpen:!1},t.handleMenu=t.handleMenu.bind(h()(t)),t.handleMenuClose=t.handleMenuClose.bind(h()(t)),t.handleMenuItemSelect=t.handleMenuItemSelect.bind(h()(t)),t.handleDialog=t.handleDialog.bind(h()(t)),t.handleDialogClose=t.handleDialogClose.bind(h()(t)),t.handleUnlinkConfirm=t.handleUnlinkConfirm.bind(h()(t)),t.menuButtonRef=Object(O.createRef)(),t.menuRef=Object(O.createRef)(),t}return g()(UserMenu,t),s()(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 o=e.googlesitekit.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(o);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:function(){return r.a.async((function(e){for(;;)switch(e.prev=e.next){case 0:this.setState({dialogActive:!1}),Object(E.c)(),document.location=Object(E.n)("googlesitekit-splash",{googlesitekit_context:"revoked"});case 3:case"end":return e.stop()}}),null,this)}},{key:"render",value:function(){var t=e.googlesitekit.admin,n=t.userData,i=n.email,r=void 0===i?"":i,a=n.picture,c=void 0===a?"":a,u=t.proxyPermissionsURL,s=this.state,l=s.dialogActive,d=s.menuOpen;return o.createElement(O.Fragment,null,o.createElement("div",{className:"googlesitekit-dropdown-menu mdc-menu-surface--anchor"},o.createElement(b.a,{ref:this.menuButtonRef,className:"googlesitekit-header__dropdown mdc-button--dropdown",text:!0,onClick:this.handleMenu,icon:c?o.createElement("i",{className:"mdc-button__icon","aria-hidden":"true"},o.createElement("img",{className:"mdc-button__icon--image",src:c,alt:Object(N.__)("User Avatar","google-site-kit")})):void 0,ariaHaspopup:"menu",ariaExpanded:d,ariaControls:"user-menu"},r),o.createElement(_.a,{ref:this.menuRef,menuOpen:d,menuItems:[Object(N.__)("Disconnect","google-site-kit")].concat(u?[Object(N.__)("Manage sites...","google-site-kit")]:[]),onSelected:this.handleMenuItemSelect,id:"user-menu"})),o.createElement(k.a,null,o.createElement(y.a,{dialogActive:l,handleConfirm:this.handleUnlinkConfirm,handleDialog:this.handleDialog,title:Object(N.__)("Disconnect","google-site-kit"),subtitle:Object(N.__)("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(N.__)("Disconnect","google-site-kit"),provides:[]})))}}]),UserMenu}(O.Component);t.a=D}).call(this,n(15),n(1))},193:function(e,t,n){"use strict";(function(e){var o=n(5),i=n.n(o),r=n(6),a=n.n(r),c=n(7),u=n.n(c),s=n(8),l=n.n(s),d=n(9),m=n.n(d),p=n(25),f=n(2),h=n.n(f),v=n(1),g=function(t){function Menu(e){var t;return i()(this,Menu),(t=u()(this,l()(Menu).call(this,e))).menuRef=Object(v.createRef)(),t}return m()(Menu,t),a()(Menu,[{key:"componentDidMount",value:function(){var e=this.props.menuOpen;this.menu=new p.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,o=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"},o.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}(v.Component);g.propTypes={menuOpen:h.a.bool.isRequired,menuItems:h.a.array.isRequired,id:h.a.string.isRequired},t.a=g}).call(this,n(1))},247:function(e,t,n){"use strict";function o(){return(o=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(e[o]=n[o])}return e}).apply(this,arguments)}function i(e,t){for(var n=0;n<t.length;n++){var o=t[n];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(e,o.key,o)}}function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function a(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function c(e){return(c=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var s=n(1),l=n(13);var d=function(e,t){return function(n){var o=e(n),i=n.displayName,r=void 0===i?n.name||"Component":i;return o.displayName="".concat(Object(l.upperFirst)(Object(l.camelCase)(t)),"(").concat(r,")"),o}};t.a=d((function(e){var t=0;return(function(n){function r(){var e;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,r),(e=a(this,c(r).apply(this,arguments))).instanceId=t++,e}var l,d,m;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(r,n),l=r,(d=[{key:"render",value:function(){return Object(s.createElement)(e,o({},this.props,{instanceId:this.instanceId}))}}])&&i(l.prototype,d),m&&i(l,m),r}(s.Component))}),"withInstanceId")},252:function(e,t,n){var o=n(253),i=n(136),r=null;function a(e){return setTimeout(e,0)}e.exports=function(e,t){var n=document,c="string"==typeof e?n.querySelector(e):e,u=i({returnFocusOnDeactivate:!0,escapeDeactivates:!0},t),s={firstTabbableNode:null,lastTabbableNode:null,nodeFocusedBeforeActivation:null,mostRecentlyFocusedNode:null,active:!1,paused:!1},l={activate:function(e){if(s.active)return;_(),s.active=!0,s.paused=!1,s.nodeFocusedBeforeActivation=n.activeElement;var t=e&&e.onActivate?e.onActivate:u.onActivate;t&&t();return m(),l},deactivate:d,pause:function(){if(s.paused||!s.active)return;s.paused=!0,p()},unpause:function(){if(!s.paused||!s.active)return;s.paused=!1,m()}};return l;function d(e){if(s.active){p(),s.active=!1,s.paused=!1;var t=e&&void 0!==e.onDeactivate?e.onDeactivate:u.onDeactivate;return t&&t(),(e&&void 0!==e.returnFocus?e.returnFocus:u.returnFocusOnDeactivate)&&a((function(){k(s.nodeFocusedBeforeActivation)})),l}}function m(){if(s.active)return r&&r.pause(),r=l,_(),a((function(){k(h())})),n.addEventListener("focusin",g,!0),n.addEventListener("mousedown",v,!0),n.addEventListener("touchstart",v,!0),n.addEventListener("click",b,!0),n.addEventListener("keydown",y,!0),l}function p(){if(s.active&&r===l)return n.removeEventListener("focusin",g,!0),n.removeEventListener("mousedown",v,!0),n.removeEventListener("touchstart",v,!0),n.removeEventListener("click",b,!0),n.removeEventListener("keydown",y,!0),r=null,l}function f(e){var t=u[e],o=t;if(!t)return null;if("string"==typeof t&&!(o=n.querySelector(t)))throw new Error("`"+e+"` refers to no known node");if("function"==typeof t&&!(o=t()))throw new Error("`"+e+"` did not return a node");return o}function h(){var e;if(!(e=null!==f("initialFocus")?f("initialFocus"):c.contains(n.activeElement)?n.activeElement:s.firstTabbableNode||f("fallbackFocus")))throw new Error("You can't have a focus-trap without at least one focusable element");return e}function v(e){c.contains(e.target)||(u.clickOutsideDeactivates?d({returnFocus:!o.isFocusable(e.target)}):e.preventDefault())}function g(e){c.contains(e.target)||e.target instanceof Document||(e.stopImmediatePropagation(),k(s.mostRecentlyFocusedNode||h()))}function y(e){if(!1!==u.escapeDeactivates&&function(e){return"Escape"===e.key||"Esc"===e.key||27===e.keyCode}(e))return e.preventDefault(),void d();(function(e){return"Tab"===e.key||9===e.keyCode})(e)&&function(e){if(_(),e.shiftKey&&e.target===s.firstTabbableNode)return e.preventDefault(),void k(s.lastTabbableNode);if(!e.shiftKey&&e.target===s.lastTabbableNode)e.preventDefault(),k(s.firstTabbableNode)}(e)}function b(e){u.clickOutsideDeactivates||c.contains(e.target)||(e.preventDefault(),e.stopImmediatePropagation())}function _(){var e=o(c);s.firstTabbableNode=e[0]||h(),s.lastTabbableNode=e[e.length-1]||h()}function k(e){e!==n.activeElement&&(e&&e.focus?(e.focus(),s.mostRecentlyFocusedNode=e,function(e){return e.tagName&&"input"===e.tagName.toLowerCase()&&"function"==typeof e.select}(e)&&e.select()):k(h()))}}},253:function(e,t){var n=["input","select","textarea","a[href]","button","[tabindex]","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],o=n.join(","),i="undefined"==typeof Element?function(){}:Element.prototype.matches||Element.prototype.msMatchesSelector||Element.prototype.webkitMatchesSelector;function r(e,t){t=t||{};var n,r,c,u=[],d=[],m=new UntouchabilityChecker(e.ownerDocument||e),p=e.querySelectorAll(o);for(t.includeContainer&&i.call(e,o)&&(p=Array.prototype.slice.apply(p)).unshift(e),n=0;n<p.length;n++)a(r=p[n],m)&&(0===(c=s(r))?u.push(r):d.push({documentOrder:n,tabIndex:c,node:r}));return d.sort(l).map((function(e){return e.node})).concat(u)}function a(e,t){return!(!c(e,t)||function(e){return function(e){return d(e)&&"radio"===e.type}(e)&&!function(e){if(!e.name)return!0;var t=function(e){for(var t=0;t<e.length;t++)if(e[t].checked)return e[t]}(e.ownerDocument.querySelectorAll('input[type="radio"][name="'+e.name+'"]'));return!t||t===e}(e)}(e)||s(e)<0)}function c(e,t){return t=t||new UntouchabilityChecker(e.ownerDocument||e),!(e.disabled||function(e){return d(e)&&"hidden"===e.type}(e)||t.isUntouchable(e))}r.isTabbable=function(e,t){if(!e)throw new Error("No node provided");return!1!==i.call(e,o)&&a(e,t)},r.isFocusable=function(e,t){if(!e)throw new Error("No node provided");return!1!==i.call(e,u)&&c(e,t)};var u=n.concat("iframe").join(",");function s(e){var t=parseInt(e.getAttribute("tabindex"),10);return isNaN(t)?function(e){return"true"===e.contentEditable}(e)?0:e.tabIndex:t}function l(e,t){return e.tabIndex===t.tabIndex?e.documentOrder-t.documentOrder:e.tabIndex-t.tabIndex}function d(e){return"INPUT"===e.tagName}function UntouchabilityChecker(e){this.doc=e,this.cache=[]}UntouchabilityChecker.prototype.hasDisplayNone=function(e,t){if(e===this.doc.documentElement)return!1;var n=function(e,t){for(var n=0,o=e.length;n<o;n++)if(t(e[n]))return e[n]}(this.cache,(function(t){return t===e}));if(n)return n[1];var o=!1;return"none"===(t=t||this.doc.defaultView.getComputedStyle(e)).display?o=!0:e.parentNode&&(o=this.hasDisplayNone(e.parentNode)),this.cache.push([e,o]),o},UntouchabilityChecker.prototype.isUntouchable=function(e){if(e===this.doc.documentElement)return!1;var t=this.doc.defaultView.getComputedStyle(e);return!!this.hasDisplayNone(e,t)||"hidden"===t.visibility},e.exports=r},281:function(e,t,n){"use strict";n.r(t),function(e,o){var i=n(16),r=n.n(i),a=n(5),c=n.n(a),u=n(6),s=n.n(u),l=n(7),d=n.n(l),m=n(8),p=n.n(m),f=n(9),h=n.n(f),v=n(13),g=n(66),y=n(19),b=n(65),_=n(3),k=n(60),E=n(1),O=n(0),N=n(12),D=function(t){function BaseComponent(){return c()(this,BaseComponent),d()(this,p()(BaseComponent).apply(this,arguments))}return h()(BaseComponent,t),s()(BaseComponent,[{key:"render",value:function(){var t=this.props.children;return e.createElement(E.Fragment,null,t)}}]),BaseComponent}(E.Component),C=function(t){function SetupWrapper(e){var t;c()(this,SetupWrapper),t=d()(this,p()(SetupWrapper).call(this,e));var n=o.googlesitekit.setup.moduleToSetup;return t.state={currentModule:n,refresh:!1},t.timeoutID=null,t.unfocusedTime=0,t.autoRefreshModules=Object(N.c)("googlesitekit.autoRefreshModules",[]),t.moduleRefresh=t.autoRefreshModules.find((function(e){return t.state.currentModule===e.identifier})),t.refreshStatus=t.refreshStatus.bind(r()(t)),t.startUnfocusedTimer=t.startUnfocusedTimer.bind(r()(t)),t}return h()(SetupWrapper,t),s()(SetupWrapper,[{key:"componentDidMount",value:function(){o.addEventListener("focus",this.refreshStatus),o.addEventListener("blur",this.startUnfocusedTimer)}},{key:"componentWillUnmount",value:function(){o.removeEventListener("focus",this.refreshStatus),o.removeEventListener("blur",this.startUnfocusedTimer)}},{key:"startUnfocusedTimer",value:function(){var e=this;if(this.moduleRefresh){var t=!0;this.moduleRefresh.toRefresh&&(t=this.moduleRefresh.toRefresh()),t&&(this.timeoutID=o.setInterval((function(){e.unfocusedTime++}),1e3))}}},{key:"refreshStatus",value:function(){if(this.moduleRefresh){var e=this.moduleRefresh.idleTime||15,t=!0;this.moduleRefresh.toRefresh&&(t=this.moduleRefresh.toRefresh()),t&&(e<this.unfocusedTime&&this.setState({refresh:this.timeoutID}),o.clearTimeout(this.timeoutID),this.unfocusedTime=0,this.timeoutID=null)}}},{key:"render",value:function(){var t=this.state.currentModule,n=SetupWrapper.loadSetupModule(t),o=Object(_.n)("googlesitekit-settings",{});return e.createElement(E.Fragment,null,e.createElement(g.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(O.__)("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(y.a,{id:"setup-".concat(t,"-cancel"),href:o},Object(O.__)("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(b.a,null)))))))))))}}],[{key:"loadSetupModule",value:function(t){var n=Object(k.a)("googlesitekit.ModuleSetup-".concat(t))(D);return e.createElement(n,{finishSetup:SetupWrapper.finishSetup,onSettingsPage:!1,isEditing:!0})}},{key:"finishSetup",value:function(){var e={notification:"authentication_success"};o.googlesitekit.setup&&o.googlesitekit.setup.moduleToSetup&&(e.slug=o.googlesitekit.setup.moduleToSetup);var t=Object(_.n)("googlesitekit-dashboard",e);Object(v.delay)((function(){o.location.replace(t)}),500,"later")}}]),SetupWrapper}(E.Component);t.default=C}.call(this,n(1),n(15))},65:function(e,t,n){"use strict";(function(e){var o=n(0),i=n(19);t.a=function HelpLink(){var t=Object(o.__)("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(1))},66:function(e,t,n){"use strict";(function(e,o){var i=n(5),r=n.n(i),a=n(6),c=n.n(a),u=n(7),s=n.n(u),l=n(8),d=n.n(l),m=n(9),p=n.n(m),f=n(191),h=n(137),v=n(192),g=n(1),y=function(t){function Header(){return r()(this,Header),s()(this,d()(Header).apply(this,arguments))}return p()(Header,t),c()(Header,[{key:"render",value:function(){var t=e.googlesitekit.setup.isAuthenticated;return o.createElement(g.Fragment,null,o.createElement("header",{className:"googlesitekit-header"},o.createElement("section",{className:"mdc-layout-grid"},o.createElement("div",{className:"mdc-layout-grid__inner"},o.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 "},o.createElement(h.a,null)),o.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&&o.createElement(v.a,null))))),o.createElement(f.a,null))}}]),Header}(g.Component);t.a=y}).call(this,n(15),n(1))}}]);
|
dist/assets/js/googlesitekit-activation.js
CHANGED
@@ -1,10 +1,13 @@
|
|
1 |
-
!function(e){var t={};function __webpack_require__(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.m=e,__webpack_require__.c=t,__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="",__webpack_require__(__webpack_require__.s=339)}([function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(Object(n));"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){r(e,t,n[t])}))}return e}n.r(t);var o=n(89),a=n(85),u=n.n(a),s=n(75),c=n.n(s);n.d(t,"setLocaleData",(function(){return p})),n.d(t,"__",(function(){return __})),n.d(t,"_x",(function(){return _x})),n.d(t,"_n",(function(){return _n})),n.d(t,"_nx",(function(){return _nx})),n.d(t,"sprintf",(function(){return build_module_sprintf}));var l={"":{plural_forms:function(e){return 1===e?0:1}}},d=u()(console.error),f=new o.a({});function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";f.data[t]=i({},l,f.data[t],e),f.data[t][""]=i({},l[""],f.data[t][""])}function h(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;return f.data[e]||p(void 0,e),f.dcnpgettext(e,t,n,r,i)}function __(e,t){return h(t,void 0,e)}function _x(e,t,n){return h(n,t,e)}function _n(e,t,n,r){return h(r,void 0,e,t,n)}function _nx(e,t,n,r,i){return h(i,r,e,t,n)}function build_module_sprintf(e){try{for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return c.a.sprintf.apply(c.a,[e].concat(n))}catch(t){return d("sprintf error: \n\n"+t.toString()),e}}},function(e,t,n){"use strict";e.exports=n(150)},function(e,t,n){e.exports=n(178)()},function(e,t,n){"use strict";(function(e){n.d(t,"u",(function(){return A})),n.d(t,"s",(function(){return F})),n.d(t,"p",(function(){return L})),n.d(t,"t",(function(){return N})),n.d(t,"i",(function(){return P})),n.d(t,"b",(function(){return R})),n.d(t,"e",(function(){return j})),n.d(t,"v",(function(){return H})),n.d(t,"m",(function(){return B})),n.d(t,"f",(function(){return U})),n.d(t,"n",(function(){return z})),n.d(t,"B",(function(){return V})),n.d(t,"C",(function(){return W})),n.d(t,"j",(function(){return G})),n.d(t,"a",(function(){return X})),n.d(t,"z",(function(){return Q})),n.d(t,"x",(function(){return $})),n.d(t,"d",(function(){return Y})),n.d(t,"g",(function(){return Z})),n.d(t,"h",(function(){return J})),n.d(t,"r",(function(){return ee})),n.d(t,"y",(function(){return te})),n.d(t,"k",(function(){return ne}));var r=n(41),i=n.n(r),o=n(64),a=n.n(o),u=n(22),s=n.n(u),c=n(11),l=n.n(c),d=n(13),f=n(10),p=n(24),h=n(1),_=n.n(h),m=n(52),g=n(12),y=n(0),v=n(45),b=n(88),C=n(94),E=n(132),O=n(133),T=n(38),S=n(55);n.d(t,"A",(function(){return S.c}));var x=n(72);n.d(t,"w",(function(){return x.a}));var M=n(87);n.d(t,"c",(function(){return M.b})),n.d(t,"l",(function(){return M.c}));var I=n(118);n.d(t,"o",(function(){return I.a}));var w=n(119);function D(e,t){var n=Object.keys(e);return Object.getOwnPropertySymbols&&n.push.apply(n,Object.getOwnPropertySymbols(e)),t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n}function k(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?D(n,!0).forEach((function(t){s()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):D(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"q",(function(){return w.a}));var A=function(e){var t,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t=Object(d.isUndefined)(e)?0:1e6<e?(e/=1e6).toFixed(1)+"M":1e3<e?99<(e/=1e3)?Math.round(e)+"K":e.toFixed(1)+"K":e,(Object(d.isNull)(e)||Object(d.isUndefined)(e)||isNaN(e))&&(t="",e=0),0===e)return t="0.00",n?new Intl.NumberFormat(navigator.language,{style:"currency",currency:n}).format(e):e;if(!1!==n&&""!==t){var r=new Intl.NumberFormat(navigator.language,{style:"currency",currency:n}).formatToParts(e),i=r.find((function(e){return"decimal"===e.type}));!Object(d.isUndefined)(i)&&!Object(d.isUndefined)(i.value)&&1e3>e&&(t=Number.isInteger(e)?e:e.replace(".",i.value));var o=r.find((function(e){return"currency"===e.type})),a=o?o.value:"";return"".concat(a).concat(t)}return t.toString()},F=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return t||(t=navigator.language),t=t.replace("_","-").toLocaleLowerCase(),new Intl.NumberFormat(t).format(e)},L=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}},N=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()},P=function(e,t){var n=1e3*L("day"),r=e.getTime(),i=t.getTime();return Math.round(Math.abs(r-i)/n)},R=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},j=function(e,t){return Object(d.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},H=function(){var t,n;return l.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,l.a.awrap(f.c.get(f.a,"user","authentication"));case 3:t=r.sent,n=t.grantedScopes.filter((function(e){return-1!==t.requiredScopes.indexOf(e)})),e.googlesitekit.setup=e.googlesitekit.setup||{},e.googlesitekit.setup.isAuthenticated=t.isAuthenticated,e.googlesitekit.setup.requiredScopes=t.requiredScopes,e.googlesitekit.setup.grantedScopes=t.grantedScopes,e.googlesitekit.setup.needReauthenticate=n.length<t.requiredScopes.length,r.next=14;break;case 12:r.prev=12,r.t0=r.catch(0);case 14:case"end":return r.stop()}}),null,null,[[0,12]])},B=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.googlesitekit,i=r.admin,o=i.connectURL,a=i.adminRoot,u=r.setup.needReauthenticate,s=r.modules[t].screenID,c="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(v.a)(a,k({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},c));if(!u)return l;var d=encodeURIComponent(Object(b.a)(l));return l=a+"?"+d,Object(v.a)(o,{redirect:l,status:n})},U=function(e,t){return function(n){return function InnerComponent(r){return _.a.createElement(e,a()({},r,t,{OriginalComponent:n}))}}},z=function(t,n){var r=e.googlesitekit.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=k({page:t},n),Object(v.a)(r,n)},V=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},W=function(e){return e.match(/^GTM-[a-zA-Z\d]{7}$/)},G=function(t){var n,r,i,o,a;return l.a.async((function(u){for(;;)switch(u.prev=u.next){case 0:return n=e.googlesitekit.admin,r=n.homeURL,i=n.ampMode,o={tagverify:1,timestamp:Date.now()},u.next=4,l.a.awrap(q(Object(v.a)(r,o),t));case 4:if((a=u.sent)||"secondary"!==i){u.next=9;break}return u.next=8,l.a.awrap(Object(m.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return l.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,l.a.awrap(q(Object(v.a)(e.link,k({},o,{amp:1})),t));case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}}))})).pop()})));case 8:a=u.sent;case 9:return u.abrupt("return",Promise.resolve(a||null));case 10:case"end":return u.stop()}}))},q=function(e,t){var n;return l.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,l.a.awrap(fetch(e,{credentials:"omit"}).then((function(e){return e.text()})));case 3:return n=r.sent,r.abrupt("return",K(n,t)||null);case 7:return r.prev=7,r.t0=r.catch(0),r.abrupt("return",null);case 10:case"end":return r.stop()}}),null,null,[[0,7]])},K=function(e,t){var n=({adsense:E.a,analytics:O.a,tagmanager:T.d,setup:C.b}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},X=function(t,n,r){return t.setModuleActive(n,r).then((function(t){return e.googlesitekit.modules&&e.googlesitekit.modules[n]&&(e.googlesitekit.modules[n].active=t.active),Object(S.c)("".concat(n,"_setup"),t.active?"module_activate":"module_deactivate",n),new Promise((function(e){e(t)}))}))},Q=function(t,n,r){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:e.googlesitekit,a=o.modules[t],u=a.settings,s=a.setupComplete,c=i||document.getElementById("confirm-changes-".concat(t));if(s&&c){var l=!!Object.keys(n).find((function(e){var t=n[e];return!Object(d.isEqual)(r[e],u[t])}));return i||(c.disabled=!l),l}},$=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(g.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",U(e,t),1)},Y=function(e){if(!e)return"";var t=e.replace(/&#(\d+);/g,(function(e,t){return String.fromCharCode(t)})).replace(/(\\)/g,"");return Object(d.unescape)(t)};function Z(){var e=Object(g.c)("googlesitekit.dateRange","last-28-days").match(/last-(\d+)-days/);if(e&&e[1])return Object(y.sprintf)(Object(y._n)("%s day","%s days",parseInt(e[1],10),"google-site-kit"),e[1]);throw new Error("Unrecognized date range slug used in `googlesitekit.dateRange`.")}function J(){return Object(g.c)("googlesitekit.dateRange","last-28-days")}function ee(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.googlesitekit){var a=_.a.createElement(p.a,{id:t,width:r,height:i,className:o});return n?a=_.a.createElement(p.a,{id:"".concat(t,"-disabled"),width:r,height:i,className:o}):"pagespeed-insights"===t&&(a=_.a.createElement("img",{src:e.googlesitekit.admin.assetsRoot+"images/icon-pagespeed.png",width:r,alt:"",className:o})),a}}function te(e){var t={};return Object.keys(e).sort().forEach((function(n){var r=e[n];r&&"object"===i()(r)&&!Array.isArray(r)&&(r=te(r)),t[n]=r})),t}function ne(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix;return n.isNetworkMode?t:r+t}}).call(this,n(15))},,function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.exports=function(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}},function(e,t,n){var r=n(41),i=n(16);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(177);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return y})),n.d(t,"b",(function(){return v}));var r=n(22),i=n.n(r),o=n(41),a=n.n(o),u=n(80),s=n(130),c=n(95),l=n.n(c),d=n(3),f=n(13),p=n(52),h=n(45),_=n(12);function m(e,t){var n=Object.keys(e);return Object.getOwnPropertySymbols&&n.push.apply(n,Object.getOwnPropertySymbols(e)),t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(n,!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var y="core",v="modules",b=function(){e.googlesitekit.admin=e.googlesitekit.admin||{},"string"==typeof e.googlesitekit.admin.datacache&&(e.googlesitekit.admin.datacache=JSON.parse(e.googlesitekit.admin.datacache)),"object"!==a()(e.googlesitekit.admin.datacache)&&(e.googlesitekit.admin.datacache={})},C=function(e,t){var n=g({data:{}},e);return n.data=g({dateRange:t},n.data),n},E={maxRequests:10,init:function(){Object(_.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingData",this.collectModuleData.bind(this))},combinedGetFromCache:function(e){var t=this;return new Promise((function(n,r){try{var i=[],o=Object(d.h)();Object(f.each)(e,(function(e){var n=C(e,o);n.key=t.getCacheKey(n.type,n.identifier,n.datapoint,n.data);var r=t.getCache(n.key,n.maxAge);void 0!==r&&(i[n.key]=r,t.resolve(n,r))})),n(i)}catch(e){r()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=[],i=25,o=Object(d.h)();Object(f.each)(e,(function(e){var n=C(e,o);n.key=t.getCacheKey(n.type,n.identifier,n.datapoint,n.data);var a=t.getCache(n.key,n.maxAge);void 0!==a?(setTimeout((function(){t.resolve(n,a)}),i),i+=25):r.push(n)})),r=Object(f.sortBy)(r,"priority");var a=[],u=[],s={},c=!!r.find((function(e){return e.priority<10}));Object(f.each)(r,(function(e,t){!n&&10<=e.priority&&c?u.push(e):s[e.key]?s[e.key].push(t):(s[e.key]=[t],a.push(e))}));var l=10,m=a.slice(0,l),g=a.slice(l);if(g=g.concat(u),0!==m.length||0!==g.length){0<g.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(g,!0)}),50):this.maxRequests=10;var y=null!==Object(d.l)("datacache");return Object(p.default)({path:Object(h.a)("/google-site-kit/v1/data/",{datacache:y||void 0}),data:{request:m},method:"POST"}).then((function(e){Object(f.each)(e,(function(e,n){s[n]?(t.handleWPError(e),Object(f.each)(s[n],(function(n){var i=r[n];t.setCache(i.key,e),t.resolve(i,e)})),0===g.length&&Object(_.d)("googlesitekit.dataLoaded","api")):console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(_.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){var t=["code","data","message"],n=Object(f.intersection)(t,Object.keys(e));if(Object(f.isEqual)(t,n)){console.warn("WP Error in data response",e);var r=e.data;if(r&&r.reason){var i=0;["authError","insufficientPermissions"].includes(r.reason)&&(Object(_.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(d.f)(u.a),1),i++),"forbidden"===r.reason&&(Object(_.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(d.f)(s.a),1),i++),i&&Object(_.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(_.f)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+i}))}}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},setCache:function(t,n){if(void 0!==n&&(!n||"object"!==a()(n)||!n.error&&!n.errors)){b(),e.googlesitekit.admin.datacache[t]=Object(f.cloneDeep)(n);var r={value:n,date:Date.now()/1e3};Object(d.o)().setItem("googlesitekit_"+t,JSON.stringify(r))}},getCache:function(t,n){if(!e.googlesitekit.admin.nojscache){if(b(),void 0!==e.googlesitekit.admin.datacache[t])return e.googlesitekit.admin.datacache[t];var r=JSON.parse(Object(d.o)().getItem("googlesitekit_"+t));return r&&"object"===a()(r)&&r.date&&(!n||Date.now()/1e3-r.date<n)?(e.googlesitekit.admin.datacache[t]=Object(f.cloneDeep)(r.value),Object(f.cloneDeep)(e.googlesitekit.admin.datacache[t])):void 0}},deleteCache:function(t){b(),delete e.googlesitekit.admin.datacache[t],Object(d.o)().removeItem("googlesitekit_"+t)},invalidateCacheGroup:function(t,n,r){var i=this.getCacheKey(t,n,r);b(),Object.keys(e.googlesitekit.admin.datacache).forEach((function(t){0!==t.indexOf(i+"::")&&t!==i||delete e.googlesitekit.admin.datacache[t]})),Object.keys(Object(d.o)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(i,"::"))&&e!=="googlesitekit_".concat(i)||Object(d.o)().removeItem(e)}))},collectModuleData:function(e,t){var n=Object(_.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var r=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=this.getCacheKey(e,t,n,i);if(!o){var u=this.getCache(a,3600);if(void 0!==u)return new Promise((function(e){e(u)}))}return Object(p.default)({path:Object(h.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),i)}).then((function(e){return o||r.setCache(a,e),Promise.resolve(e)})).catch((function(e){return r.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,r){var i={};return i.data=r,Object(p.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:i,method:"POST"}).then((function(r){return E.invalidateCacheGroup(e,t,n),new Promise((function(e){e(r)}))}))},getCacheKey:function(e,t,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],u=0,s=o;u<s.length;u++){var c=s[u];if(!c||!c.length)break;i.push(c)}return 3===i.length&&r&&"object"===a()(r)&&Object.keys(r).length&&i.push(l()(JSON.stringify(Object(d.y)(r)))),i.join("::")},setModuleActive:function(e,t){return this.set(y,"modules","activation",{slug:e,active:t})}};E.init(),t.c=E}).call(this,n(15))},function(e,t,n){e.exports=n(148)},function(e,t,n){"use strict";var r=function(e){return"string"!=typeof e||""===e?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(e)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)};var i=function(e){return"string"!=typeof e||""===e?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(e)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(e)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)};var o=function(e){return function(t,n,o){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10;if(i(t)&&r(n))if("function"==typeof o)if("number"==typeof a){var u={callback:o,priority:a,namespace:n};if(e[t]){var s,c=e[t].handlers;for(s=c.length;s>0&&!(a>=c[s-1].priority);s--);s===c.length?c[s]=u:c.splice(s,0,u),(e.__current||[]).forEach((function(e){e.name===t&&e.currentIndex>=s&&e.currentIndex++}))}else e[t]={handlers:[u],runs:0};"hookAdded"!==t&&y("hookAdded",t,n,o,a)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}};var a=function(e,t){return function(n,o){if(i(n)&&(t||r(o))){if(!e[n])return 0;var a=0;if(t)a=e[n].handlers.length,e[n]={runs:e[n].runs,handlers:[]};else for(var u=e[n].handlers,s=function(t){u[t].namespace===o&&(u.splice(t,1),a++,(e.__current||[]).forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},c=u.length-1;c>=0;c--)s(c);return"hookRemoved"!==n&&y("hookRemoved",n,o),a}}};var u=function(e){return function(t,n){return void 0!==n?t in e&&e[t].handlers.some((function(e){return e.namespace===n})):t in e}};var s=function(e,t){return function(n){e[n]||(e[n]={handlers:[],runs:0}),e[n].runs++;var r=e[n].handlers;for(var i=arguments.length,o=new Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];if(!r||!r.length)return t?o[0]:void 0;var u={name:n,currentIndex:0};for(e.__current.push(u);u.currentIndex<r.length;){var s=r[u.currentIndex],c=s.callback.apply(null,o);t&&(o[0]=c),u.currentIndex++}return e.__current.pop(),t?o[0]:void 0}};var c=function(e){return function(){return e.__current&&e.__current.length?e.__current[e.__current.length-1].name:null}};var l=function(e){return function(t){return void 0===t?void 0!==e.__current[0]:!!e.__current[0]&&t===e.__current[0].name}};var d=function(e){return function(t){if(i(t))return e[t]&&e[t].runs?e[t].runs:0}};var f=function(){var e=Object.create(null),t=Object.create(null);return e.__current=[],t.__current=[],{addAction:o(e),addFilter:o(t),removeAction:a(e),removeFilter:a(t),hasAction:u(e),hasFilter:u(t),removeAllActions:a(e,!0),removeAllFilters:a(t,!0),doAction:s(e),applyFilters:s(t,!0),currentAction:c(e),currentFilter:c(t),doingAction:l(e),doingFilter:l(t),didAction:d(e),didFilter:d(t),actions:e,filters:t}};n.d(t,"a",(function(){return h})),n.d(t,"b",(function(){return _})),n.d(t,"e",(function(){return m})),n.d(t,"f",(function(){return g})),n.d(t,"d",(function(){return y})),n.d(t,"c",(function(){return v}));var p=f(),h=p.addAction,_=p.addFilter,m=p.removeAction,g=p.removeFilter,y=(p.hasAction,p.hasFilter,p.removeAllActions,p.removeAllFilters,p.doAction),v=p.applyFilters;p.currentAction,p.currentFilter,p.doingAction,p.doingFilter,p.didAction,p.didFilter,p.actions,p.filters},function(e,t,n){(function(e,n){(function(){var r,i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",u="__lodash_hash_undefined__",s=500,c="__lodash_placeholder__",l=1,d=2,f=4,p=1,h=2,_=1,m=2,g=4,y=8,v=16,b=32,C=64,E=128,O=256,T=512,S=30,x="...",M=800,I=16,w=1,D=2,k=1/0,A=9007199254740991,F=17976931348623157e292,L=NaN,N=4294967295,P=N-1,R=N>>>1,j=[["ary",E],["bind",_],["bindKey",m],["curry",y],["curryRight",v],["flip",T],["partial",b],["partialRight",C],["rearg",O]],H="[object Arguments]",B="[object Array]",U="[object AsyncFunction]",z="[object Boolean]",V="[object Date]",W="[object DOMException]",G="[object Error]",q="[object Function]",K="[object GeneratorFunction]",X="[object Map]",Q="[object Number]",$="[object Null]",Y="[object Object]",Z="[object Proxy]",J="[object RegExp]",ee="[object Set]",te="[object String]",ne="[object Symbol]",re="[object Undefined]",ie="[object WeakMap]",oe="[object WeakSet]",ae="[object ArrayBuffer]",ue="[object DataView]",se="[object Float32Array]",ce="[object Float64Array]",le="[object Int8Array]",de="[object Int16Array]",fe="[object Int32Array]",pe="[object Uint8Array]",he="[object Uint8ClampedArray]",_e="[object Uint16Array]",me="[object Uint32Array]",ge=/\b__p \+= '';/g,ye=/\b(__p \+=) '' \+/g,ve=/(__e\(.*?\)|\b__t\)) \+\n'';/g,be=/&(?:amp|lt|gt|quot|#39);/g,Ce=/[&<>"']/g,Ee=RegExp(be.source),Oe=RegExp(Ce.source),Te=/<%-([\s\S]+?)%>/g,Se=/<%([\s\S]+?)%>/g,xe=/<%=([\s\S]+?)%>/g,Me=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Ie=/^\w*$/,we=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,De=/[\\^$.*+?()[\]{}|]/g,ke=RegExp(De.source),Ae=/^\s+|\s+$/g,Fe=/^\s+/,Le=/\s+$/,Ne=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Pe=/\{\n\/\* \[wrapped with (.+)\] \*/,Re=/,? & /,je=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,He=/\\(\\)?/g,Be=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ue=/\w*$/,ze=/^[-+]0x[0-9a-f]+$/i,Ve=/^0b[01]+$/i,We=/^\[object .+?Constructor\]$/,Ge=/^0o[0-7]+$/i,qe=/^(?:0|[1-9]\d*)$/,Ke=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Xe=/($^)/,Qe=/['\n\r\u2028\u2029\\]/g,$e="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Ye="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ze="[\\ud800-\\udfff]",Je="["+Ye+"]",et="["+$e+"]",tt="\\d+",nt="[\\u2700-\\u27bf]",rt="[a-z\\xdf-\\xf6\\xf8-\\xff]",it="[^\\ud800-\\udfff"+Ye+tt+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",ot="\\ud83c[\\udffb-\\udfff]",at="[^\\ud800-\\udfff]",ut="(?:\\ud83c[\\udde6-\\uddff]){2}",st="[\\ud800-\\udbff][\\udc00-\\udfff]",ct="[A-Z\\xc0-\\xd6\\xd8-\\xde]",lt="(?:"+rt+"|"+it+")",dt="(?:"+ct+"|"+it+")",ft="(?:"+et+"|"+ot+")"+"?",pt="[\\ufe0e\\ufe0f]?"+ft+("(?:\\u200d(?:"+[at,ut,st].join("|")+")[\\ufe0e\\ufe0f]?"+ft+")*"),ht="(?:"+[nt,ut,st].join("|")+")"+pt,_t="(?:"+[at+et+"?",et,ut,st,Ze].join("|")+")",mt=RegExp("['’]","g"),gt=RegExp(et,"g"),yt=RegExp(ot+"(?="+ot+")|"+_t+pt,"g"),vt=RegExp([ct+"?"+rt+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[Je,ct,"$"].join("|")+")",dt+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[Je,ct+lt,"$"].join("|")+")",ct+"?"+lt+"+(?:['’](?:d|ll|m|re|s|t|ve))?",ct+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tt,ht].join("|"),"g"),bt=RegExp("[\\u200d\\ud800-\\udfff"+$e+"\\ufe0e\\ufe0f]"),Ct=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Et=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ot=-1,Tt={};Tt[se]=Tt[ce]=Tt[le]=Tt[de]=Tt[fe]=Tt[pe]=Tt[he]=Tt[_e]=Tt[me]=!0,Tt[H]=Tt[B]=Tt[ae]=Tt[z]=Tt[ue]=Tt[V]=Tt[G]=Tt[q]=Tt[X]=Tt[Q]=Tt[Y]=Tt[J]=Tt[ee]=Tt[te]=Tt[ie]=!1;var St={};St[H]=St[B]=St[ae]=St[ue]=St[z]=St[V]=St[se]=St[ce]=St[le]=St[de]=St[fe]=St[X]=St[Q]=St[Y]=St[J]=St[ee]=St[te]=St[ne]=St[pe]=St[he]=St[_e]=St[me]=!0,St[G]=St[q]=St[ie]=!1;var xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Mt=parseFloat,It=parseInt,wt="object"==typeof e&&e&&e.Object===Object&&e,Dt="object"==typeof self&&self&&self.Object===Object&&self,kt=wt||Dt||Function("return this")(),At=t&&!t.nodeType&&t,Ft=At&&"object"==typeof n&&n&&!n.nodeType&&n,Lt=Ft&&Ft.exports===At,Nt=Lt&&wt.process,Pt=function(){try{var e=Ft&&Ft.require&&Ft.require("util").types;return e||Nt&&Nt.binding&&Nt.binding("util")}catch(e){}}(),Rt=Pt&&Pt.isArrayBuffer,jt=Pt&&Pt.isDate,Ht=Pt&&Pt.isMap,Bt=Pt&&Pt.isRegExp,Ut=Pt&&Pt.isSet,zt=Pt&&Pt.isTypedArray;function Vt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function Wt(e,t,n,r){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(r,a,n(a),e)}return r}function Gt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function qt(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function Kt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function Xt(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function Qt(e,t){return!!(null==e?0:e.length)&&an(e,t,0)>-1}function $t(e,t,n){for(var r=-1,i=null==e?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function Yt(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function Zt(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function Jt(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}function en(e,t,n,r){var i=null==e?0:e.length;for(r&&i&&(n=e[--i]);i--;)n=t(n,e[i],i,e);return n}function tn(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var nn=ln("length");function rn(e,t,n){var r;return n(e,(function(e,n,i){if(t(e,n,i))return r=n,!1})),r}function on(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o<i;)if(t(e[o],o,e))return o;return-1}function an(e,t,n){return t==t?function(e,t,n){var r=n-1,i=e.length;for(;++r<i;)if(e[r]===t)return r;return-1}(e,t,n):on(e,sn,n)}function un(e,t,n,r){for(var i=n-1,o=e.length;++i<o;)if(r(e[i],t))return i;return-1}function sn(e){return e!=e}function cn(e,t){var n=null==e?0:e.length;return n?pn(e,t)/n:L}function ln(e){return function(t){return null==t?r:t[e]}}function dn(e){return function(t){return null==e?r:e[t]}}function fn(e,t,n,r,i){return i(e,(function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)})),n}function pn(e,t){for(var n,i=-1,o=e.length;++i<o;){var a=t(e[i]);a!==r&&(n=n===r?a:n+a)}return n}function hn(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function _n(e){return function(t){return e(t)}}function mn(e,t){return Yt(t,(function(t){return e[t]}))}function gn(e,t){return e.has(t)}function yn(e,t){for(var n=-1,r=e.length;++n<r&&an(t,e[n],0)>-1;);return n}function vn(e,t){for(var n=e.length;n--&&an(t,e[n],0)>-1;);return n}var bn=dn({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),Cn=dn({"&":"&","<":"<",">":">",'"':""","'":"'"});function En(e){return"\\"+xt[e]}function On(e){return bt.test(e)}function Tn(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Sn(e,t){return function(n){return e(t(n))}}function xn(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n];a!==t&&a!==c||(e[n]=c,o[i++]=n)}return o}function Mn(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function In(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function wn(e){return On(e)?function(e){var t=yt.lastIndex=0;for(;yt.test(e);)++t;return t}(e):nn(e)}function Dn(e){return On(e)?function(e){return e.match(yt)||[]}(e):function(e){return e.split("")}(e)}var kn=dn({"&":"&","<":"<",">":">",""":'"',"'":"'"});var An=function e(t){var n,$e=(t=null==t?kt:An.defaults(kt.Object(),t,An.pick(kt,Et))).Array,Ye=t.Date,Ze=t.Error,Je=t.Function,et=t.Math,tt=t.Object,nt=t.RegExp,rt=t.String,it=t.TypeError,ot=$e.prototype,at=Je.prototype,ut=tt.prototype,st=t["__core-js_shared__"],ct=at.toString,lt=ut.hasOwnProperty,dt=0,ft=(n=/[^.]+$/.exec(st&&st.keys&&st.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",pt=ut.toString,ht=ct.call(tt),_t=kt._,yt=nt("^"+ct.call(lt).replace(De,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),bt=Lt?t.Buffer:r,xt=t.Symbol,wt=t.Uint8Array,Dt=bt?bt.allocUnsafe:r,At=Sn(tt.getPrototypeOf,tt),Ft=tt.create,Nt=ut.propertyIsEnumerable,Pt=ot.splice,nn=xt?xt.isConcatSpreadable:r,dn=xt?xt.iterator:r,Fn=xt?xt.toStringTag:r,Ln=function(){try{var e=Ao(tt,"defineProperty");return e({},"",{}),e}catch(e){}}(),Nn=t.clearTimeout!==kt.clearTimeout&&t.clearTimeout,Pn=Ye&&Ye.now!==kt.Date.now&&Ye.now,Rn=t.setTimeout!==kt.setTimeout&&t.setTimeout,jn=et.ceil,Hn=et.floor,Bn=tt.getOwnPropertySymbols,Un=bt?bt.isBuffer:r,zn=t.isFinite,Vn=ot.join,Wn=Sn(tt.keys,tt),Gn=et.max,qn=et.min,Kn=Ye.now,Xn=t.parseInt,Qn=et.random,$n=ot.reverse,Yn=Ao(t,"DataView"),Zn=Ao(t,"Map"),Jn=Ao(t,"Promise"),er=Ao(t,"Set"),tr=Ao(t,"WeakMap"),nr=Ao(tt,"create"),rr=tr&&new tr,ir={},or=ia(Yn),ar=ia(Zn),ur=ia(Jn),sr=ia(er),cr=ia(tr),lr=xt?xt.prototype:r,dr=lr?lr.valueOf:r,fr=lr?lr.toString:r;function pr(e){if(Cu(e)&&!lu(e)&&!(e instanceof LazyWrapper)){if(e instanceof LodashWrapper)return e;if(lt.call(e,"__wrapped__"))return oa(e)}return new LodashWrapper(e)}var hr=function(){function e(){}return function(t){if(!bu(t))return{};if(Ft)return Ft(t);e.prototype=t;var n=new e;return e.prototype=r,n}}();function _r(){}function LodashWrapper(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=r}function LazyWrapper(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=N,this.__views__=[]}function Hash(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ListCache(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function MapCache(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function SetCache(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new MapCache;++t<n;)this.add(e[t])}function Stack(e){var t=this.__data__=new ListCache(e);this.size=t.size}function mr(e,t){var n=lu(e),r=!n&&cu(e),i=!n&&!r&&hu(e),o=!n&&!r&&!i&&wu(e),a=n||r||i||o,u=a?hn(e.length,rt):[],s=u.length;for(var c in e)!t&&!lt.call(e,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Ho(c,s))||u.push(c);return u}function gr(e){var t=e.length;return t?e[hi(0,t-1)]:r}function yr(e,t){return ta(Qi(e),Mr(t,0,e.length))}function vr(e){return ta(Qi(e))}function br(e,t,n){(n===r||au(e[t],n))&&(n!==r||t in e)||Sr(e,t,n)}function Cr(e,t,n){var i=e[t];lt.call(e,t)&&au(i,n)&&(n!==r||t in e)||Sr(e,t,n)}function Er(e,t){for(var n=e.length;n--;)if(au(e[n][0],t))return n;return-1}function Or(e,t,n,r){return Ar(e,(function(e,i,o){t(r,e,n(e),o)})),r}function Tr(e,t){return e&&$i(t,Yu(t),e)}function Sr(e,t,n){"__proto__"==t&&Ln?Ln(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function xr(e,t){for(var n=-1,i=t.length,o=$e(i),a=null==e;++n<i;)o[n]=a?r:qu(e,t[n]);return o}function Mr(e,t,n){return e==e&&(n!==r&&(e=e<=n?e:n),t!==r&&(e=e>=t?e:t)),e}function Ir(e,t,n,i,o,a){var u,s=t&l,c=t&d,p=t&f;if(n&&(u=o?n(e,i,o,a):n(e)),u!==r)return u;if(!bu(e))return e;var h=lu(e);if(h){if(u=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&<.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!s)return Qi(e,u)}else{var _=No(e),m=_==q||_==K;if(hu(e))return Vi(e,s);if(_==Y||_==H||m&&!o){if(u=c||m?{}:Ro(e),!s)return c?function(e,t){return $i(e,Lo(e),t)}(e,function(e,t){return e&&$i(t,Zu(t),e)}(u,e)):function(e,t){return $i(e,Fo(e),t)}(e,Tr(u,e))}else{if(!St[_])return o?e:{};u=function(e,t,n){var r=e.constructor;switch(t){case ae:return Wi(e);case z:case V:return new r(+e);case ue:return function(e,t){var n=t?Wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case se:case ce:case le:case de:case fe:case pe:case he:case _e:case me:return Gi(e,n);case X:return new r;case Q:case te:return new r(e);case J:return function(e){var t=new e.constructor(e.source,Ue.exec(e));return t.lastIndex=e.lastIndex,t}(e);case ee:return new r;case ne:return i=e,dr?tt(dr.call(i)):{}}var i}(e,_,s)}}a||(a=new Stack);var g=a.get(e);if(g)return g;a.set(e,u),xu(e)?e.forEach((function(r){u.add(Ir(r,t,n,r,e,a))})):Eu(e)&&e.forEach((function(r,i){u.set(i,Ir(r,t,n,i,e,a))}));var y=h?r:(p?c?So:To:c?Zu:Yu)(e);return Gt(y||e,(function(r,i){y&&(r=e[i=r]),Cr(u,i,Ir(r,t,n,i,e,a))})),u}function wr(e,t,n){var i=n.length;if(null==e)return!i;for(e=tt(e);i--;){var o=n[i],a=t[o],u=e[o];if(u===r&&!(o in e)||!a(u))return!1}return!0}function Dr(e,t,n){if("function"!=typeof e)throw new it(a);return Yo((function(){e.apply(r,n)}),t)}function kr(e,t,n,r){var o=-1,a=Qt,u=!0,s=e.length,c=[],l=t.length;if(!s)return c;n&&(t=Yt(t,_n(n))),r?(a=$t,u=!1):t.length>=i&&(a=gn,u=!1,t=new SetCache(t));e:for(;++o<s;){var d=e[o],f=null==n?d:n(d);if(d=r||0!==d?d:0,u&&f==f){for(var p=l;p--;)if(t[p]===f)continue e;c.push(d)}else a(t,f,r)||c.push(d)}return c}pr.templateSettings={escape:Te,evaluate:Se,interpolate:xe,variable:"",imports:{_:pr}},pr.prototype=_r.prototype,pr.prototype.constructor=pr,LodashWrapper.prototype=hr(_r.prototype),LodashWrapper.prototype.constructor=LodashWrapper,LazyWrapper.prototype=hr(_r.prototype),LazyWrapper.prototype.constructor=LazyWrapper,Hash.prototype.clear=function(){this.__data__=nr?nr(null):{},this.size=0},Hash.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Hash.prototype.get=function(e){var t=this.__data__;if(nr){var n=t[e];return n===u?r:n}return lt.call(t,e)?t[e]:r},Hash.prototype.has=function(e){var t=this.__data__;return nr?t[e]!==r:lt.call(t,e)},Hash.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=nr&&t===r?u:t,this},ListCache.prototype.clear=function(){this.__data__=[],this.size=0},ListCache.prototype.delete=function(e){var t=this.__data__,n=Er(t,e);return!(n<0)&&(n==t.length-1?t.pop():Pt.call(t,n,1),--this.size,!0)},ListCache.prototype.get=function(e){var t=this.__data__,n=Er(t,e);return n<0?r:t[n][1]},ListCache.prototype.has=function(e){return Er(this.__data__,e)>-1},ListCache.prototype.set=function(e,t){var n=this.__data__,r=Er(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},MapCache.prototype.clear=function(){this.size=0,this.__data__={hash:new Hash,map:new(Zn||ListCache),string:new Hash}},MapCache.prototype.delete=function(e){var t=Do(this,e).delete(e);return this.size-=t?1:0,t},MapCache.prototype.get=function(e){return Do(this,e).get(e)},MapCache.prototype.has=function(e){return Do(this,e).has(e)},MapCache.prototype.set=function(e,t){var n=Do(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},SetCache.prototype.add=SetCache.prototype.push=function(e){return this.__data__.set(e,u),this},SetCache.prototype.has=function(e){return this.__data__.has(e)},Stack.prototype.clear=function(){this.__data__=new ListCache,this.size=0},Stack.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},Stack.prototype.get=function(e){return this.__data__.get(e)},Stack.prototype.has=function(e){return this.__data__.has(e)},Stack.prototype.set=function(e,t){var n=this.__data__;if(n instanceof ListCache){var r=n.__data__;if(!Zn||r.length<i-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new MapCache(r)}return n.set(e,t),this.size=n.size,this};var Ar=Ji(Br),Fr=Ji(Ur,!0);function Lr(e,t){var n=!0;return Ar(e,(function(e,r,i){return n=!!t(e,r,i)})),n}function Nr(e,t,n){for(var i=-1,o=e.length;++i<o;){var a=e[i],u=t(a);if(null!=u&&(s===r?u==u&&!Iu(u):n(u,s)))var s=u,c=a}return c}function Pr(e,t){var n=[];return Ar(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n}function Rr(e,t,n,r,i){var o=-1,a=e.length;for(n||(n=jo),i||(i=[]);++o<a;){var u=e[o];t>0&&n(u)?t>1?Rr(u,t-1,n,r,i):Zt(i,u):r||(i[i.length]=u)}return i}var jr=eo(),Hr=eo(!0);function Br(e,t){return e&&jr(e,t,Yu)}function Ur(e,t){return e&&Hr(e,t,Yu)}function zr(e,t){return Xt(t,(function(t){return gu(e[t])}))}function Vr(e,t){for(var n=0,i=(t=Hi(t,e)).length;null!=e&&n<i;)e=e[ra(t[n++])];return n&&n==i?e:r}function Wr(e,t,n){var r=t(e);return lu(e)?r:Zt(r,n(e))}function Gr(e){return null==e?e===r?re:$:Fn&&Fn in tt(e)?function(e){var t=lt.call(e,Fn),n=e[Fn];try{e[Fn]=r;var i=!0}catch(e){}var o=pt.call(e);i&&(t?e[Fn]=n:delete e[Fn]);return o}(e):function(e){return pt.call(e)}(e)}function qr(e,t){return e>t}function Kr(e,t){return null!=e&<.call(e,t)}function Xr(e,t){return null!=e&&t in tt(e)}function Qr(e,t,n){for(var i=n?$t:Qt,o=e[0].length,a=e.length,u=a,s=$e(a),c=1/0,l=[];u--;){var d=e[u];u&&t&&(d=Yt(d,_n(t))),c=qn(d.length,c),s[u]=!n&&(t||o>=120&&d.length>=120)?new SetCache(u&&d):r}d=e[0];var f=-1,p=s[0];e:for(;++f<o&&l.length<c;){var h=d[f],_=t?t(h):h;if(h=n||0!==h?h:0,!(p?gn(p,_):i(l,_,n))){for(u=a;--u;){var m=s[u];if(!(m?gn(m,_):i(e[u],_,n)))continue e}p&&p.push(_),l.push(h)}}return l}function $r(e,t,n){var i=null==(e=Xo(e,t=Hi(t,e)))?e:e[ra(ma(t))];return null==i?r:Vt(i,e,n)}function Yr(e){return Cu(e)&&Gr(e)==H}function Zr(e,t,n,i,o){return e===t||(null==e||null==t||!Cu(e)&&!Cu(t)?e!=e&&t!=t:function(e,t,n,i,o,a){var u=lu(e),s=lu(t),c=u?B:No(e),l=s?B:No(t),d=(c=c==H?Y:c)==Y,f=(l=l==H?Y:l)==Y,_=c==l;if(_&&hu(e)){if(!hu(t))return!1;u=!0,d=!1}if(_&&!d)return a||(a=new Stack),u||wu(e)?Eo(e,t,n,i,o,a):function(e,t,n,r,i,o,a){switch(n){case ue:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case ae:return!(e.byteLength!=t.byteLength||!o(new wt(e),new wt(t)));case z:case V:case Q:return au(+e,+t);case G:return e.name==t.name&&e.message==t.message;case J:case te:return e==t+"";case X:var u=Tn;case ee:var s=r&p;if(u||(u=Mn),e.size!=t.size&&!s)return!1;var c=a.get(e);if(c)return c==t;r|=h,a.set(e,t);var l=Eo(u(e),u(t),r,i,o,a);return a.delete(e),l;case ne:if(dr)return dr.call(e)==dr.call(t)}return!1}(e,t,c,n,i,o,a);if(!(n&p)){var m=d&<.call(e,"__wrapped__"),g=f&<.call(t,"__wrapped__");if(m||g){var y=m?e.value():e,v=g?t.value():t;return a||(a=new Stack),o(y,v,n,i,a)}}if(!_)return!1;return a||(a=new Stack),function(e,t,n,i,o,a){var u=n&p,s=To(e),c=s.length,l=To(t).length;if(c!=l&&!u)return!1;var d=c;for(;d--;){var f=s[d];if(!(u?f in t:lt.call(t,f)))return!1}var h=a.get(e);if(h&&a.get(t))return h==t;var _=!0;a.set(e,t),a.set(t,e);var m=u;for(;++d<c;){f=s[d];var g=e[f],y=t[f];if(i)var v=u?i(y,g,f,t,e,a):i(g,y,f,e,t,a);if(!(v===r?g===y||o(g,y,n,i,a):v)){_=!1;break}m||(m="constructor"==f)}if(_&&!m){var b=e.constructor,C=t.constructor;b!=C&&"constructor"in e&&"constructor"in t&&!("function"==typeof b&&b instanceof b&&"function"==typeof C&&C instanceof C)&&(_=!1)}return a.delete(e),a.delete(t),_}(e,t,n,i,o,a)}(e,t,n,i,Zr,o))}function Jr(e,t,n,i){var o=n.length,a=o,u=!i;if(null==e)return!a;for(e=tt(e);o--;){var s=n[o];if(u&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<a;){var c=(s=n[o])[0],l=e[c],d=s[1];if(u&&s[2]){if(l===r&&!(c in e))return!1}else{var f=new Stack;if(i)var _=i(l,d,c,e,t,f);if(!(_===r?Zr(d,l,p|h,i,f):_))return!1}}return!0}function ei(e){return!(!bu(e)||(t=e,ft&&ft in t))&&(gu(e)?yt:We).test(ia(e));var t}function ti(e){return"function"==typeof e?e:null==e?Os:"object"==typeof e?lu(e)?ui(e[0],e[1]):ai(e):As(e)}function ni(e){if(!Wo(e))return Wn(e);var t=[];for(var n in tt(e))lt.call(e,n)&&"constructor"!=n&&t.push(n);return t}function ri(e){if(!bu(e))return function(e){var t=[];if(null!=e)for(var n in tt(e))t.push(n);return t}(e);var t=Wo(e),n=[];for(var r in e)("constructor"!=r||!t&<.call(e,r))&&n.push(r);return n}function ii(e,t){return e<t}function oi(e,t){var n=-1,r=fu(e)?$e(e.length):[];return Ar(e,(function(e,i,o){r[++n]=t(e,i,o)})),r}function ai(e){var t=ko(e);return 1==t.length&&t[0][2]?qo(t[0][0],t[0][1]):function(n){return n===e||Jr(n,e,t)}}function ui(e,t){return Uo(e)&&Go(t)?qo(ra(e),t):function(n){var i=qu(n,e);return i===r&&i===t?Ku(n,e):Zr(t,i,p|h)}}function si(e,t,n,i,o){e!==t&&jr(t,(function(a,u){if(o||(o=new Stack),bu(a))!function(e,t,n,i,o,a,u){var s=Qo(e,n),c=Qo(t,n),l=u.get(c);if(l)return void br(e,n,l);var d=a?a(s,c,n+"",e,t,u):r,f=d===r;if(f){var p=lu(c),h=!p&&hu(c),_=!p&&!h&&wu(c);d=c,p||h||_?lu(s)?d=s:pu(s)?d=Qi(s):h?(f=!1,d=Vi(c,!0)):_?(f=!1,d=Gi(c,!0)):d=[]:Tu(c)||cu(c)?(d=s,cu(s)?d=Ru(s):bu(s)&&!gu(s)||(d=Ro(c))):f=!1}f&&(u.set(c,d),o(d,c,i,a,u),u.delete(c));br(e,n,d)}(e,t,u,n,si,i,o);else{var s=i?i(Qo(e,u),a,u+"",e,t,o):r;s===r&&(s=a),br(e,u,s)}}),Zu)}function ci(e,t){var n=e.length;if(n)return Ho(t+=t<0?n:0,n)?e[t]:r}function li(e,t,n){var r=-1;return t=Yt(t.length?t:[Os],_n(wo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(oi(e,(function(e,n,i){return{criteria:Yt(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,i=e.criteria,o=t.criteria,a=i.length,u=n.length;for(;++r<a;){var s=qi(i[r],o[r]);if(s){if(r>=u)return s;var c=n[r];return s*("desc"==c?-1:1)}}return e.index-t.index}(e,t,n)}))}function di(e,t,n){for(var r=-1,i=t.length,o={};++r<i;){var a=t[r],u=Vr(e,a);n(u,a)&&vi(o,Hi(a,e),u)}return o}function fi(e,t,n,r){var i=r?un:an,o=-1,a=t.length,u=e;for(e===t&&(t=Qi(t)),n&&(u=Yt(e,_n(n)));++o<a;)for(var s=0,c=t[o],l=n?n(c):c;(s=i(u,l,s,r))>-1;)u!==e&&Pt.call(u,s,1),Pt.call(e,s,1);return e}function pi(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==o){var o=i;Ho(i)?Pt.call(e,i,1):ki(e,i)}}return e}function hi(e,t){return e+Hn(Qn()*(t-e+1))}function _i(e,t){var n="";if(!e||t<1||t>A)return n;do{t%2&&(n+=e),(t=Hn(t/2))&&(e+=e)}while(t);return n}function mi(e,t){return Zo(Ko(e,t,Os),e+"")}function gi(e){return gr(as(e))}function yi(e,t){var n=as(e);return ta(n,Mr(t,0,n.length))}function vi(e,t,n,i){if(!bu(e))return e;for(var o=-1,a=(t=Hi(t,e)).length,u=a-1,s=e;null!=s&&++o<a;){var c=ra(t[o]),l=n;if(o!=u){var d=s[c];(l=i?i(d,c,s):r)===r&&(l=bu(d)?d:Ho(t[o+1])?[]:{})}Cr(s,c,l),s=s[c]}return e}var bi=rr?function(e,t){return rr.set(e,t),e}:Os,Ci=Ln?function(e,t){return Ln(e,"toString",{configurable:!0,enumerable:!1,value:bs(t),writable:!0})}:Os;function Ei(e){return ta(as(e))}function Oi(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=$e(i);++r<i;)o[r]=e[r+t];return o}function Ti(e,t){var n;return Ar(e,(function(e,r,i){return!(n=t(e,r,i))})),!!n}function Si(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t==t&&i<=R){for(;r<i;){var o=r+i>>>1,a=e[o];null!==a&&!Iu(a)&&(n?a<=t:a<t)?r=o+1:i=o}return i}return xi(e,t,Os,n)}function xi(e,t,n,i){t=n(t);for(var o=0,a=null==e?0:e.length,u=t!=t,s=null===t,c=Iu(t),l=t===r;o<a;){var d=Hn((o+a)/2),f=n(e[d]),p=f!==r,h=null===f,_=f==f,m=Iu(f);if(u)var g=i||_;else g=l?_&&(i||p):s?_&&p&&(i||!h):c?_&&p&&!h&&(i||!m):!h&&!m&&(i?f<=t:f<t);g?o=d+1:a=d}return qn(a,P)}function Mi(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n],u=t?t(a):a;if(!n||!au(u,s)){var s=u;o[i++]=0===a?0:a}}return o}function Ii(e){return"number"==typeof e?e:Iu(e)?L:+e}function wi(e){if("string"==typeof e)return e;if(lu(e))return Yt(e,wi)+"";if(Iu(e))return fr?fr.call(e):"";var t=e+"";return"0"==t&&1/e==-k?"-0":t}function Di(e,t,n){var r=-1,o=Qt,a=e.length,u=!0,s=[],c=s;if(n)u=!1,o=$t;else if(a>=i){var l=t?null:mo(e);if(l)return Mn(l);u=!1,o=gn,c=new SetCache}else c=t?[]:s;e:for(;++r<a;){var d=e[r],f=t?t(d):d;if(d=n||0!==d?d:0,u&&f==f){for(var p=c.length;p--;)if(c[p]===f)continue e;t&&c.push(f),s.push(d)}else o(c,f,n)||(c!==s&&c.push(f),s.push(d))}return s}function ki(e,t){return null==(e=Xo(e,t=Hi(t,e)))||delete e[ra(ma(t))]}function Ai(e,t,n,r){return vi(e,t,n(Vr(e,t)),r)}function Fi(e,t,n,r){for(var i=e.length,o=r?i:-1;(r?o--:++o<i)&&t(e[o],o,e););return n?Oi(e,r?0:o,r?o+1:i):Oi(e,r?o+1:0,r?i:o)}function Li(e,t){var n=e;return n instanceof LazyWrapper&&(n=n.value()),Jt(t,(function(e,t){return t.func.apply(t.thisArg,Zt([e],t.args))}),n)}function Ni(e,t,n){var r=e.length;if(r<2)return r?Di(e[0]):[];for(var i=-1,o=$e(r);++i<r;)for(var a=e[i],u=-1;++u<r;)u!=i&&(o[i]=kr(o[i]||a,e[u],t,n));return Di(Rr(o,1),t,n)}function Pi(e,t,n){for(var i=-1,o=e.length,a=t.length,u={};++i<o;){var s=i<a?t[i]:r;n(u,e[i],s)}return u}function Ri(e){return pu(e)?e:[]}function ji(e){return"function"==typeof e?e:Os}function Hi(e,t){return lu(e)?e:Uo(e,t)?[e]:na(ju(e))}var Bi=mi;function Ui(e,t,n){var i=e.length;return n=n===r?i:n,!t&&n>=i?e:Oi(e,t,n)}var zi=Nn||function(e){return kt.clearTimeout(e)};function Vi(e,t){if(t)return e.slice();var n=e.length,r=Dt?Dt(n):new e.constructor(n);return e.copy(r),r}function Wi(e){var t=new e.constructor(e.byteLength);return new wt(t).set(new wt(e)),t}function Gi(e,t){var n=t?Wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function qi(e,t){if(e!==t){var n=e!==r,i=null===e,o=e==e,a=Iu(e),u=t!==r,s=null===t,c=t==t,l=Iu(t);if(!s&&!l&&!a&&e>t||a&&u&&c&&!s&&!l||i&&u&&c||!n&&c||!o)return 1;if(!i&&!a&&!l&&e<t||l&&n&&o&&!i&&!a||s&&n&&o||!u&&o||!c)return-1}return 0}function Ki(e,t,n,r){for(var i=-1,o=e.length,a=n.length,u=-1,s=t.length,c=Gn(o-a,0),l=$e(s+c),d=!r;++u<s;)l[u]=t[u];for(;++i<a;)(d||i<o)&&(l[n[i]]=e[i]);for(;c--;)l[u++]=e[i++];return l}function Xi(e,t,n,r){for(var i=-1,o=e.length,a=-1,u=n.length,s=-1,c=t.length,l=Gn(o-u,0),d=$e(l+c),f=!r;++i<l;)d[i]=e[i];for(var p=i;++s<c;)d[p+s]=t[s];for(;++a<u;)(f||i<o)&&(d[p+n[a]]=e[i++]);return d}function Qi(e,t){var n=-1,r=e.length;for(t||(t=$e(r));++n<r;)t[n]=e[n];return t}function $i(e,t,n,i){var o=!n;n||(n={});for(var a=-1,u=t.length;++a<u;){var s=t[a],c=i?i(n[s],e[s],s,n,e):r;c===r&&(c=e[s]),o?Sr(n,s,c):Cr(n,s,c)}return n}function Yi(e,t){return function(n,r){var i=lu(n)?Wt:Or,o=t?t():{};return i(n,e,wo(r,2),o)}}function Zi(e){return mi((function(t,n){var i=-1,o=n.length,a=o>1?n[o-1]:r,u=o>2?n[2]:r;for(a=e.length>3&&"function"==typeof a?(o--,a):r,u&&Bo(n[0],n[1],u)&&(a=o<3?r:a,o=1),t=tt(t);++i<o;){var s=n[i];s&&e(t,s,i,a)}return t}))}function Ji(e,t){return function(n,r){if(null==n)return n;if(!fu(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=tt(n);(t?o--:++o<i)&&!1!==r(a[o],o,a););return n}}function eo(e){return function(t,n,r){for(var i=-1,o=tt(t),a=r(t),u=a.length;u--;){var s=a[e?u:++i];if(!1===n(o[s],s,o))break}return t}}function to(e){return function(t){var n=On(t=ju(t))?Dn(t):r,i=n?n[0]:t.charAt(0),o=n?Ui(n,1).join(""):t.slice(1);return i[e]()+o}}function no(e){return function(t){return Jt(gs(cs(t).replace(mt,"")),e,"")}}function ro(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=hr(e.prototype),r=e.apply(n,t);return bu(r)?r:n}}function io(e){return function(t,n,i){var o=tt(t);if(!fu(t)){var a=wo(n,3);t=Yu(t),n=function(e){return a(o[e],e,o)}}var u=e(t,n,i);return u>-1?o[a?t[u]:u]:r}}function oo(e){return Oo((function(t){var n=t.length,i=n,o=LodashWrapper.prototype.thru;for(e&&t.reverse();i--;){var u=t[i];if("function"!=typeof u)throw new it(a);if(o&&!s&&"wrapper"==Mo(u))var s=new LodashWrapper([],!0)}for(i=s?i:n;++i<n;){var c=Mo(u=t[i]),l="wrapper"==c?xo(u):r;s=l&&zo(l[0])&&l[1]==(E|y|b|O)&&!l[4].length&&1==l[9]?s[Mo(l[0])].apply(s,l[3]):1==u.length&&zo(u)?s[c]():s.thru(u)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&lu(r))return s.plant(r).value();for(var i=0,o=n?t[i].apply(this,e):r;++i<n;)o=t[i].call(this,o);return o}}))}function ao(e,t,n,i,o,a,u,s,c,l){var d=t&E,f=t&_,p=t&m,h=t&(y|v),g=t&T,b=p?r:ro(e);return function _(){for(var m=arguments.length,y=$e(m),v=m;v--;)y[v]=arguments[v];if(h)var C=Io(_),E=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}(y,C);if(i&&(y=Ki(y,i,o,h)),a&&(y=Xi(y,a,u,h)),m-=E,h&&m<l){var O=xn(y,C);return ho(e,t,ao,_.placeholder,n,y,O,s,c,l-m)}var T=f?n:this,S=p?T[e]:e;return m=y.length,s?y=function(e,t){var n=e.length,i=qn(t.length,n),o=Qi(e);for(;i--;){var a=t[i];e[i]=Ho(a,n)?o[a]:r}return e}(y,s):g&&m>1&&y.reverse(),d&&c<m&&(y.length=c),this&&this!==kt&&this instanceof _&&(S=b||ro(S)),S.apply(T,y)}}function uo(e,t){return function(n,r){return function(e,t,n,r){return Br(e,(function(e,i,o){t(r,n(e),i,o)})),r}(n,e,t(r),{})}}function so(e,t){return function(n,i){var o;if(n===r&&i===r)return t;if(n!==r&&(o=n),i!==r){if(o===r)return i;"string"==typeof n||"string"==typeof i?(n=wi(n),i=wi(i)):(n=Ii(n),i=Ii(i)),o=e(n,i)}return o}}function co(e){return Oo((function(t){return t=Yt(t,_n(wo())),mi((function(n){var r=this;return e(t,(function(e){return Vt(e,r,n)}))}))}))}function lo(e,t){var n=(t=t===r?" ":wi(t)).length;if(n<2)return n?_i(t,e):t;var i=_i(t,jn(e/wn(t)));return On(t)?Ui(Dn(i),0,e).join(""):i.slice(0,e)}function fo(e){return function(t,n,i){return i&&"number"!=typeof i&&Bo(t,n,i)&&(n=i=r),t=Fu(t),n===r?(n=t,t=0):n=Fu(n),function(e,t,n,r){for(var i=-1,o=Gn(jn((t-e)/(n||1)),0),a=$e(o);o--;)a[r?o:++i]=e,e+=n;return a}(t,n,i=i===r?t<n?1:-1:Fu(i),e)}}function po(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=Pu(t),n=Pu(n)),e(t,n)}}function ho(e,t,n,i,o,a,u,s,c,l){var d=t&y;t|=d?b:C,(t&=~(d?C:b))&g||(t&=~(_|m));var f=[e,t,o,d?a:r,d?u:r,d?r:a,d?r:u,s,c,l],p=n.apply(r,f);return zo(e)&&$o(p,f),p.placeholder=i,Jo(p,e,t)}function _o(e){var t=et[e];return function(e,n){if(e=Pu(e),(n=null==n?0:qn(Lu(n),292))&&zn(e)){var r=(ju(e)+"e").split("e");return+((r=(ju(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var mo=er&&1/Mn(new er([,-0]))[1]==k?function(e){return new er(e)}:Is;function go(e){return function(t){var n=No(t);return n==X?Tn(t):n==ee?In(t):function(e,t){return Yt(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function yo(e,t,n,i,o,u,s,l){var d=t&m;if(!d&&"function"!=typeof e)throw new it(a);var f=i?i.length:0;if(f||(t&=~(b|C),i=o=r),s=s===r?s:Gn(Lu(s),0),l=l===r?l:Lu(l),f-=o?o.length:0,t&C){var p=i,h=o;i=o=r}var T=d?r:xo(e),S=[e,t,n,i,o,p,h,u,s,l];if(T&&function(e,t){var n=e[1],r=t[1],i=n|r,o=i<(_|m|E),a=r==E&&n==y||r==E&&n==O&&e[7].length<=t[8]||r==(E|O)&&t[7].length<=t[8]&&n==y;if(!o&&!a)return e;r&_&&(e[2]=t[2],i|=n&_?0:g);var u=t[3];if(u){var s=e[3];e[3]=s?Ki(s,u,t[4]):u,e[4]=s?xn(e[3],c):t[4]}(u=t[5])&&(s=e[5],e[5]=s?Xi(s,u,t[6]):u,e[6]=s?xn(e[5],c):t[6]);(u=t[7])&&(e[7]=u);r&E&&(e[8]=null==e[8]?t[8]:qn(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(S,T),e=S[0],t=S[1],n=S[2],i=S[3],o=S[4],!(l=S[9]=S[9]===r?d?0:e.length:Gn(S[9]-f,0))&&t&(y|v)&&(t&=~(y|v)),t&&t!=_)x=t==y||t==v?function(e,t,n){var i=ro(e);return function o(){for(var a=arguments.length,u=$e(a),s=a,c=Io(o);s--;)u[s]=arguments[s];var l=a<3&&u[0]!==c&&u[a-1]!==c?[]:xn(u,c);return(a-=l.length)<n?ho(e,t,ao,o.placeholder,r,u,l,r,r,n-a):Vt(this&&this!==kt&&this instanceof o?i:e,this,u)}}(e,t,l):t!=b&&t!=(_|b)||o.length?ao.apply(r,S):function(e,t,n,r){var i=t&_,o=ro(e);return function t(){for(var a=-1,u=arguments.length,s=-1,c=r.length,l=$e(c+u),d=this&&this!==kt&&this instanceof t?o:e;++s<c;)l[s]=r[s];for(;u--;)l[s++]=arguments[++a];return Vt(d,i?n:this,l)}}(e,t,n,i);else var x=function(e,t,n){var r=t&_,i=ro(e);return function t(){return(this&&this!==kt&&this instanceof t?i:e).apply(r?n:this,arguments)}}(e,t,n);return Jo((T?bi:$o)(x,S),e,t)}function vo(e,t,n,i){return e===r||au(e,ut[n])&&!lt.call(i,n)?t:e}function bo(e,t,n,i,o,a){return bu(e)&&bu(t)&&(a.set(t,e),si(e,t,r,bo,a),a.delete(t)),e}function Co(e){return Tu(e)?r:e}function Eo(e,t,n,i,o,a){var u=n&p,s=e.length,c=t.length;if(s!=c&&!(u&&c>s))return!1;var l=a.get(e);if(l&&a.get(t))return l==t;var d=-1,f=!0,_=n&h?new SetCache:r;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],g=t[d];if(i)var y=u?i(g,m,d,t,e,a):i(m,g,d,e,t,a);if(y!==r){if(y)continue;f=!1;break}if(_){if(!tn(t,(function(e,t){if(!gn(_,t)&&(m===e||o(m,e,n,i,a)))return _.push(t)}))){f=!1;break}}else if(m!==g&&!o(m,g,n,i,a)){f=!1;break}}return a.delete(e),a.delete(t),f}function Oo(e){return Zo(Ko(e,r,da),e+"")}function To(e){return Wr(e,Yu,Fo)}function So(e){return Wr(e,Zu,Lo)}var xo=rr?function(e){return rr.get(e)}:Is;function Mo(e){for(var t=e.name+"",n=ir[t],r=lt.call(ir,t)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function Io(e){return(lt.call(pr,"placeholder")?pr:e).placeholder}function wo(){var e=pr.iteratee||Ts;return e=e===Ts?ti:e,arguments.length?e(arguments[0],arguments[1]):e}function Do(e,t){var n,r,i=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof t?"string":"hash"]:i.map}function ko(e){for(var t=Yu(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Go(i)]}return t}function Ao(e,t){var n=function(e,t){return null==e?r:e[t]}(e,t);return ei(n)?n:r}var Fo=Bn?function(e){return null==e?[]:(e=tt(e),Xt(Bn(e),(function(t){return Nt.call(e,t)})))}:Ns,Lo=Bn?function(e){for(var t=[];e;)Zt(t,Fo(e)),e=At(e);return t}:Ns,No=Gr;function Po(e,t,n){for(var r=-1,i=(t=Hi(t,e)).length,o=!1;++r<i;){var a=ra(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&vu(i)&&Ho(a,i)&&(lu(e)||cu(e))}function Ro(e){return"function"!=typeof e.constructor||Wo(e)?{}:hr(At(e))}function jo(e){return lu(e)||cu(e)||!!(nn&&e&&e[nn])}function Ho(e,t){var n=typeof e;return!!(t=null==t?A:t)&&("number"==n||"symbol"!=n&&qe.test(e))&&e>-1&&e%1==0&&e<t}function Bo(e,t,n){if(!bu(n))return!1;var r=typeof t;return!!("number"==r?fu(n)&&Ho(t,n.length):"string"==r&&t in n)&&au(n[t],e)}function Uo(e,t){if(lu(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Iu(e))||(Ie.test(e)||!Me.test(e)||null!=t&&e in tt(t))}function zo(e){var t=Mo(e),n=pr[t];if("function"!=typeof n||!(t in LazyWrapper.prototype))return!1;if(e===n)return!0;var r=xo(n);return!!r&&e===r[0]}(Yn&&No(new Yn(new ArrayBuffer(1)))!=ue||Zn&&No(new Zn)!=X||Jn&&"[object Promise]"!=No(Jn.resolve())||er&&No(new er)!=ee||tr&&No(new tr)!=ie)&&(No=function(e){var t=Gr(e),n=t==Y?e.constructor:r,i=n?ia(n):"";if(i)switch(i){case or:return ue;case ar:return X;case ur:return"[object Promise]";case sr:return ee;case cr:return ie}return t});var Vo=st?gu:Ps;function Wo(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||ut)}function Go(e){return e==e&&!bu(e)}function qo(e,t){return function(n){return null!=n&&(n[e]===t&&(t!==r||e in tt(n)))}}function Ko(e,t,n){return t=Gn(t===r?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=Gn(r.length-t,0),a=$e(o);++i<o;)a[i]=r[t+i];i=-1;for(var u=$e(t+1);++i<t;)u[i]=r[i];return u[t]=n(a),Vt(e,this,u)}}function Xo(e,t){return t.length<2?e:Vr(e,Oi(t,0,-1))}function Qo(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var $o=ea(bi),Yo=Rn||function(e,t){return kt.setTimeout(e,t)},Zo=ea(Ci);function Jo(e,t,n){var r=t+"";return Zo(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(Ne,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return Gt(j,(function(n){var r="_."+n[0];t&n[1]&&!Qt(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(Pe);return t?t[1].split(Re):[]}(r),n)))}function ea(e){var t=0,n=0;return function(){var i=Kn(),o=I-(i-n);if(n=i,o>0){if(++t>=M)return arguments[0]}else t=0;return e.apply(r,arguments)}}function ta(e,t){var n=-1,i=e.length,o=i-1;for(t=t===r?i:t;++n<t;){var a=hi(n,o),u=e[a];e[a]=e[n],e[n]=u}return e.length=t,e}var na=function(e){var t=eu(e,(function(e){return n.size===s&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(we,(function(e,n,r,i){t.push(r?i.replace(He,"$1"):n||e)})),t}));function ra(e){if("string"==typeof e||Iu(e))return e;var t=e+"";return"0"==t&&1/e==-k?"-0":t}function ia(e){if(null!=e){try{return ct.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function oa(e){if(e instanceof LazyWrapper)return e.clone();var t=new LodashWrapper(e.__wrapped__,e.__chain__);return t.__actions__=Qi(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var aa=mi((function(e,t){return pu(e)?kr(e,Rr(t,1,pu,!0)):[]})),ua=mi((function(e,t){var n=ma(t);return pu(n)&&(n=r),pu(e)?kr(e,Rr(t,1,pu,!0),wo(n,2)):[]})),sa=mi((function(e,t){var n=ma(t);return pu(n)&&(n=r),pu(e)?kr(e,Rr(t,1,pu,!0),r,n):[]}));function ca(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Lu(n);return i<0&&(i=Gn(r+i,0)),on(e,wo(t,3),i)}function la(e,t,n){var i=null==e?0:e.length;if(!i)return-1;var o=i-1;return n!==r&&(o=Lu(n),o=n<0?Gn(i+o,0):qn(o,i-1)),on(e,wo(t,3),o,!0)}function da(e){return(null==e?0:e.length)?Rr(e,1):[]}function fa(e){return e&&e.length?e[0]:r}var pa=mi((function(e){var t=Yt(e,Ri);return t.length&&t[0]===e[0]?Qr(t):[]})),ha=mi((function(e){var t=ma(e),n=Yt(e,Ri);return t===ma(n)?t=r:n.pop(),n.length&&n[0]===e[0]?Qr(n,wo(t,2)):[]})),_a=mi((function(e){var t=ma(e),n=Yt(e,Ri);return(t="function"==typeof t?t:r)&&n.pop(),n.length&&n[0]===e[0]?Qr(n,r,t):[]}));function ma(e){var t=null==e?0:e.length;return t?e[t-1]:r}var ga=mi(ya);function ya(e,t){return e&&e.length&&t&&t.length?fi(e,t):e}var va=Oo((function(e,t){var n=null==e?0:e.length,r=xr(e,t);return pi(e,Yt(t,(function(e){return Ho(e,n)?+e:e})).sort(qi)),r}));function ba(e){return null==e?e:$n.call(e)}var Ca=mi((function(e){return Di(Rr(e,1,pu,!0))})),Ea=mi((function(e){var t=ma(e);return pu(t)&&(t=r),Di(Rr(e,1,pu,!0),wo(t,2))})),Oa=mi((function(e){var t=ma(e);return t="function"==typeof t?t:r,Di(Rr(e,1,pu,!0),r,t)}));function Ta(e){if(!e||!e.length)return[];var t=0;return e=Xt(e,(function(e){if(pu(e))return t=Gn(e.length,t),!0})),hn(t,(function(t){return Yt(e,ln(t))}))}function Sa(e,t){if(!e||!e.length)return[];var n=Ta(e);return null==t?n:Yt(n,(function(e){return Vt(t,r,e)}))}var xa=mi((function(e,t){return pu(e)?kr(e,t):[]})),Ma=mi((function(e){return Ni(Xt(e,pu))})),Ia=mi((function(e){var t=ma(e);return pu(t)&&(t=r),Ni(Xt(e,pu),wo(t,2))})),wa=mi((function(e){var t=ma(e);return t="function"==typeof t?t:r,Ni(Xt(e,pu),r,t)})),Da=mi(Ta);var ka=mi((function(e){var t=e.length,n=t>1?e[t-1]:r;return n="function"==typeof n?(e.pop(),n):r,Sa(e,n)}));function Aa(e){var t=pr(e);return t.__chain__=!0,t}function Fa(e,t){return t(e)}var La=Oo((function(e){var t=e.length,n=t?e[0]:0,i=this.__wrapped__,o=function(t){return xr(t,e)};return!(t>1||this.__actions__.length)&&i instanceof LazyWrapper&&Ho(n)?((i=i.slice(n,+n+(t?1:0))).__actions__.push({func:Fa,args:[o],thisArg:r}),new LodashWrapper(i,this.__chain__).thru((function(e){return t&&!e.length&&e.push(r),e}))):this.thru(o)}));var Na=Yi((function(e,t,n){lt.call(e,n)?++e[n]:Sr(e,n,1)}));var Pa=io(ca),Ra=io(la);function ja(e,t){return(lu(e)?Gt:Ar)(e,wo(t,3))}function Ha(e,t){return(lu(e)?qt:Fr)(e,wo(t,3))}var Ba=Yi((function(e,t,n){lt.call(e,n)?e[n].push(t):Sr(e,n,[t])}));var Ua=mi((function(e,t,n){var r=-1,i="function"==typeof t,o=fu(e)?$e(e.length):[];return Ar(e,(function(e){o[++r]=i?Vt(t,e,n):$r(e,t,n)})),o})),za=Yi((function(e,t,n){Sr(e,n,t)}));function Va(e,t){return(lu(e)?Yt:oi)(e,wo(t,3))}var Wa=Yi((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var Ga=mi((function(e,t){if(null==e)return[];var n=t.length;return n>1&&Bo(e,t[0],t[1])?t=[]:n>2&&Bo(t[0],t[1],t[2])&&(t=[t[0]]),li(e,Rr(t,1),[])})),qa=Pn||function(){return kt.Date.now()};function Ka(e,t,n){return t=n?r:t,t=e&&null==t?e.length:t,yo(e,E,r,r,r,r,t)}function Xa(e,t){var n;if("function"!=typeof t)throw new it(a);return e=Lu(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=r),n}}var Qa=mi((function(e,t,n){var r=_;if(n.length){var i=xn(n,Io(Qa));r|=b}return yo(e,r,t,n,i)})),$a=mi((function(e,t,n){var r=_|m;if(n.length){var i=xn(n,Io($a));r|=b}return yo(t,r,e,n,i)}));function Ya(e,t,n){var i,o,u,s,c,l,d=0,f=!1,p=!1,h=!0;if("function"!=typeof e)throw new it(a);function _(t){var n=i,a=o;return i=o=r,d=t,s=e.apply(a,n)}function m(e){var n=e-l;return l===r||n>=t||n<0||p&&e-d>=u}function g(){var e=qa();if(m(e))return y(e);c=Yo(g,function(e){var n=t-(e-l);return p?qn(n,u-(e-d)):n}(e))}function y(e){return c=r,h&&i?_(e):(i=o=r,s)}function v(){var e=qa(),n=m(e);if(i=arguments,o=this,l=e,n){if(c===r)return function(e){return d=e,c=Yo(g,t),f?_(e):s}(l);if(p)return zi(c),c=Yo(g,t),_(l)}return c===r&&(c=Yo(g,t)),s}return t=Pu(t)||0,bu(n)&&(f=!!n.leading,u=(p="maxWait"in n)?Gn(Pu(n.maxWait)||0,t):u,h="trailing"in n?!!n.trailing:h),v.cancel=function(){c!==r&&zi(c),d=0,i=l=o=c=r},v.flush=function(){return c===r?s:y(qa())},v}var Za=mi((function(e,t){return Dr(e,1,t)})),Ja=mi((function(e,t,n){return Dr(e,Pu(t)||0,n)}));function eu(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new it(a);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(eu.Cache||MapCache),n}function tu(e){if("function"!=typeof e)throw new it(a);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}eu.Cache=MapCache;var nu=Bi((function(e,t){var n=(t=1==t.length&&lu(t[0])?Yt(t[0],_n(wo())):Yt(Rr(t,1),_n(wo()))).length;return mi((function(r){for(var i=-1,o=qn(r.length,n);++i<o;)r[i]=t[i].call(this,r[i]);return Vt(e,this,r)}))})),ru=mi((function(e,t){var n=xn(t,Io(ru));return yo(e,b,r,t,n)})),iu=mi((function(e,t){var n=xn(t,Io(iu));return yo(e,C,r,t,n)})),ou=Oo((function(e,t){return yo(e,O,r,r,r,t)}));function au(e,t){return e===t||e!=e&&t!=t}var uu=po(qr),su=po((function(e,t){return e>=t})),cu=Yr(function(){return arguments}())?Yr:function(e){return Cu(e)&<.call(e,"callee")&&!Nt.call(e,"callee")},lu=$e.isArray,du=Rt?_n(Rt):function(e){return Cu(e)&&Gr(e)==ae};function fu(e){return null!=e&&vu(e.length)&&!gu(e)}function pu(e){return Cu(e)&&fu(e)}var hu=Un||Ps,_u=jt?_n(jt):function(e){return Cu(e)&&Gr(e)==V};function mu(e){if(!Cu(e))return!1;var t=Gr(e);return t==G||t==W||"string"==typeof e.message&&"string"==typeof e.name&&!Tu(e)}function gu(e){if(!bu(e))return!1;var t=Gr(e);return t==q||t==K||t==U||t==Z}function yu(e){return"number"==typeof e&&e==Lu(e)}function vu(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=A}function bu(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Cu(e){return null!=e&&"object"==typeof e}var Eu=Ht?_n(Ht):function(e){return Cu(e)&&No(e)==X};function Ou(e){return"number"==typeof e||Cu(e)&&Gr(e)==Q}function Tu(e){if(!Cu(e)||Gr(e)!=Y)return!1;var t=At(e);if(null===t)return!0;var n=lt.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&ct.call(n)==ht}var Su=Bt?_n(Bt):function(e){return Cu(e)&&Gr(e)==J};var xu=Ut?_n(Ut):function(e){return Cu(e)&&No(e)==ee};function Mu(e){return"string"==typeof e||!lu(e)&&Cu(e)&&Gr(e)==te}function Iu(e){return"symbol"==typeof e||Cu(e)&&Gr(e)==ne}var wu=zt?_n(zt):function(e){return Cu(e)&&vu(e.length)&&!!Tt[Gr(e)]};var Du=po(ii),ku=po((function(e,t){return e<=t}));function Au(e){if(!e)return[];if(fu(e))return Mu(e)?Dn(e):Qi(e);if(dn&&e[dn])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[dn]());var t=No(e);return(t==X?Tn:t==ee?Mn:as)(e)}function Fu(e){return e?(e=Pu(e))===k||e===-k?(e<0?-1:1)*F:e==e?e:0:0===e?e:0}function Lu(e){var t=Fu(e),n=t%1;return t==t?n?t-n:t:0}function Nu(e){return e?Mr(Lu(e),0,N):0}function Pu(e){if("number"==typeof e)return e;if(Iu(e))return L;if(bu(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=bu(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(Ae,"");var n=Ve.test(e);return n||Ge.test(e)?It(e.slice(2),n?2:8):ze.test(e)?L:+e}function Ru(e){return $i(e,Zu(e))}function ju(e){return null==e?"":wi(e)}var Hu=Zi((function(e,t){if(Wo(t)||fu(t))$i(t,Yu(t),e);else for(var n in t)lt.call(t,n)&&Cr(e,n,t[n])})),Bu=Zi((function(e,t){$i(t,Zu(t),e)})),Uu=Zi((function(e,t,n,r){$i(t,Zu(t),e,r)})),zu=Zi((function(e,t,n,r){$i(t,Yu(t),e,r)})),Vu=Oo(xr);var Wu=mi((function(e,t){e=tt(e);var n=-1,i=t.length,o=i>2?t[2]:r;for(o&&Bo(t[0],t[1],o)&&(i=1);++n<i;)for(var a=t[n],u=Zu(a),s=-1,c=u.length;++s<c;){var l=u[s],d=e[l];(d===r||au(d,ut[l])&&!lt.call(e,l))&&(e[l]=a[l])}return e})),Gu=mi((function(e){return e.push(r,bo),Vt(es,r,e)}));function qu(e,t,n){var i=null==e?r:Vr(e,t);return i===r?n:i}function Ku(e,t){return null!=e&&Po(e,t,Xr)}var Xu=uo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),e[t]=n}),bs(Os)),Qu=uo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),lt.call(e,t)?e[t].push(n):e[t]=[n]}),wo),$u=mi($r);function Yu(e){return fu(e)?mr(e):ni(e)}function Zu(e){return fu(e)?mr(e,!0):ri(e)}var Ju=Zi((function(e,t,n){si(e,t,n)})),es=Zi((function(e,t,n,r){si(e,t,n,r)})),ts=Oo((function(e,t){var n={};if(null==e)return n;var r=!1;t=Yt(t,(function(t){return t=Hi(t,e),r||(r=t.length>1),t})),$i(e,So(e),n),r&&(n=Ir(n,l|d|f,Co));for(var i=t.length;i--;)ki(n,t[i]);return n}));var ns=Oo((function(e,t){return null==e?{}:function(e,t){return di(e,t,(function(t,n){return Ku(e,n)}))}(e,t)}));function rs(e,t){if(null==e)return{};var n=Yt(So(e),(function(e){return[e]}));return t=wo(t),di(e,n,(function(e,n){return t(e,n[0])}))}var is=go(Yu),os=go(Zu);function as(e){return null==e?[]:mn(e,Yu(e))}var us=no((function(e,t,n){return t=t.toLowerCase(),e+(n?ss(t):t)}));function ss(e){return ms(ju(e).toLowerCase())}function cs(e){return(e=ju(e))&&e.replace(Ke,bn).replace(gt,"")}var ls=no((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),ds=no((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),fs=to("toLowerCase");var ps=no((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var hs=no((function(e,t,n){return e+(n?" ":"")+ms(t)}));var _s=no((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),ms=to("toUpperCase");function gs(e,t,n){return e=ju(e),(t=n?r:t)===r?function(e){return Ct.test(e)}(e)?function(e){return e.match(vt)||[]}(e):function(e){return e.match(je)||[]}(e):e.match(t)||[]}var ys=mi((function(e,t){try{return Vt(e,r,t)}catch(e){return mu(e)?e:new Ze(e)}})),vs=Oo((function(e,t){return Gt(t,(function(t){t=ra(t),Sr(e,t,Qa(e[t],e))})),e}));function bs(e){return function(){return e}}var Cs=oo(),Es=oo(!0);function Os(e){return e}function Ts(e){return ti("function"==typeof e?e:Ir(e,l))}var Ss=mi((function(e,t){return function(n){return $r(n,e,t)}})),xs=mi((function(e,t){return function(n){return $r(e,n,t)}}));function Ms(e,t,n){var r=Yu(t),i=zr(t,r);null!=n||bu(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=zr(t,Yu(t)));var o=!(bu(n)&&"chain"in n&&!n.chain),a=gu(e);return Gt(i,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__),i=n.__actions__=Qi(this.__actions__);return i.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,Zt([this.value()],arguments))})})),e}function Is(){}var ws=co(Yt),Ds=co(Kt),ks=co(tn);function As(e){return Uo(e)?ln(ra(e)):function(e){return function(t){return Vr(t,e)}}(e)}var Fs=fo(),Ls=fo(!0);function Ns(){return[]}function Ps(){return!1}var Rs=so((function(e,t){return e+t}),0),js=_o("ceil"),Hs=so((function(e,t){return e/t}),1),Bs=_o("floor");var Us,zs=so((function(e,t){return e*t}),1),Vs=_o("round"),Ws=so((function(e,t){return e-t}),0);return pr.after=function(e,t){if("function"!=typeof t)throw new it(a);return e=Lu(e),function(){if(--e<1)return t.apply(this,arguments)}},pr.ary=Ka,pr.assign=Hu,pr.assignIn=Bu,pr.assignInWith=Uu,pr.assignWith=zu,pr.at=Vu,pr.before=Xa,pr.bind=Qa,pr.bindAll=vs,pr.bindKey=$a,pr.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return lu(e)?e:[e]},pr.chain=Aa,pr.chunk=function(e,t,n){t=(n?Bo(e,t,n):t===r)?1:Gn(Lu(t),0);var i=null==e?0:e.length;if(!i||t<1)return[];for(var o=0,a=0,u=$e(jn(i/t));o<i;)u[a++]=Oi(e,o,o+=t);return u},pr.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,i=[];++t<n;){var o=e[t];o&&(i[r++]=o)}return i},pr.concat=function(){var e=arguments.length;if(!e)return[];for(var t=$e(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return Zt(lu(n)?Qi(n):[n],Rr(t,1))},pr.cond=function(e){var t=null==e?0:e.length,n=wo();return e=t?Yt(e,(function(e){if("function"!=typeof e[1])throw new it(a);return[n(e[0]),e[1]]})):[],mi((function(n){for(var r=-1;++r<t;){var i=e[r];if(Vt(i[0],this,n))return Vt(i[1],this,n)}}))},pr.conforms=function(e){return function(e){var t=Yu(e);return function(n){return wr(n,e,t)}}(Ir(e,l))},pr.constant=bs,pr.countBy=Na,pr.create=function(e,t){var n=hr(e);return null==t?n:Tr(n,t)},pr.curry=function e(t,n,i){var o=yo(t,y,r,r,r,r,r,n=i?r:n);return o.placeholder=e.placeholder,o},pr.curryRight=function e(t,n,i){var o=yo(t,v,r,r,r,r,r,n=i?r:n);return o.placeholder=e.placeholder,o},pr.debounce=Ya,pr.defaults=Wu,pr.defaultsDeep=Gu,pr.defer=Za,pr.delay=Ja,pr.difference=aa,pr.differenceBy=ua,pr.differenceWith=sa,pr.drop=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,(t=n||t===r?1:Lu(t))<0?0:t,i):[]},pr.dropRight=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,0,(t=i-(t=n||t===r?1:Lu(t)))<0?0:t):[]},pr.dropRightWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!0,!0):[]},pr.dropWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!0):[]},pr.fill=function(e,t,n,i){var o=null==e?0:e.length;return o?(n&&"number"!=typeof n&&Bo(e,t,n)&&(n=0,i=o),function(e,t,n,i){var o=e.length;for((n=Lu(n))<0&&(n=-n>o?0:o+n),(i=i===r||i>o?o:Lu(i))<0&&(i+=o),i=n>i?0:Nu(i);n<i;)e[n++]=t;return e}(e,t,n,i)):[]},pr.filter=function(e,t){return(lu(e)?Xt:Pr)(e,wo(t,3))},pr.flatMap=function(e,t){return Rr(Va(e,t),1)},pr.flatMapDeep=function(e,t){return Rr(Va(e,t),k)},pr.flatMapDepth=function(e,t,n){return n=n===r?1:Lu(n),Rr(Va(e,t),n)},pr.flatten=da,pr.flattenDeep=function(e){return(null==e?0:e.length)?Rr(e,k):[]},pr.flattenDepth=function(e,t){return(null==e?0:e.length)?Rr(e,t=t===r?1:Lu(t)):[]},pr.flip=function(e){return yo(e,T)},pr.flow=Cs,pr.flowRight=Es,pr.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r},pr.functions=function(e){return null==e?[]:zr(e,Yu(e))},pr.functionsIn=function(e){return null==e?[]:zr(e,Zu(e))},pr.groupBy=Ba,pr.initial=function(e){return(null==e?0:e.length)?Oi(e,0,-1):[]},pr.intersection=pa,pr.intersectionBy=ha,pr.intersectionWith=_a,pr.invert=Xu,pr.invertBy=Qu,pr.invokeMap=Ua,pr.iteratee=Ts,pr.keyBy=za,pr.keys=Yu,pr.keysIn=Zu,pr.map=Va,pr.mapKeys=function(e,t){var n={};return t=wo(t,3),Br(e,(function(e,r,i){Sr(n,t(e,r,i),e)})),n},pr.mapValues=function(e,t){var n={};return t=wo(t,3),Br(e,(function(e,r,i){Sr(n,r,t(e,r,i))})),n},pr.matches=function(e){return ai(Ir(e,l))},pr.matchesProperty=function(e,t){return ui(e,Ir(t,l))},pr.memoize=eu,pr.merge=Ju,pr.mergeWith=es,pr.method=Ss,pr.methodOf=xs,pr.mixin=Ms,pr.negate=tu,pr.nthArg=function(e){return e=Lu(e),mi((function(t){return ci(t,e)}))},pr.omit=ts,pr.omitBy=function(e,t){return rs(e,tu(wo(t)))},pr.once=function(e){return Xa(2,e)},pr.orderBy=function(e,t,n,i){return null==e?[]:(lu(t)||(t=null==t?[]:[t]),lu(n=i?r:n)||(n=null==n?[]:[n]),li(e,t,n))},pr.over=ws,pr.overArgs=nu,pr.overEvery=Ds,pr.overSome=ks,pr.partial=ru,pr.partialRight=iu,pr.partition=Wa,pr.pick=ns,pr.pickBy=rs,pr.property=As,pr.propertyOf=function(e){return function(t){return null==e?r:Vr(e,t)}},pr.pull=ga,pr.pullAll=ya,pr.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?fi(e,t,wo(n,2)):e},pr.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?fi(e,t,r,n):e},pr.pullAt=va,pr.range=Fs,pr.rangeRight=Ls,pr.rearg=ou,pr.reject=function(e,t){return(lu(e)?Xt:Pr)(e,tu(wo(t,3)))},pr.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;for(t=wo(t,3);++r<o;){var a=e[r];t(a,r,e)&&(n.push(a),i.push(r))}return pi(e,i),n},pr.rest=function(e,t){if("function"!=typeof e)throw new it(a);return mi(e,t=t===r?t:Lu(t))},pr.reverse=ba,pr.sampleSize=function(e,t,n){return t=(n?Bo(e,t,n):t===r)?1:Lu(t),(lu(e)?yr:yi)(e,t)},pr.set=function(e,t,n){return null==e?e:vi(e,t,n)},pr.setWith=function(e,t,n,i){return i="function"==typeof i?i:r,null==e?e:vi(e,t,n,i)},pr.shuffle=function(e){return(lu(e)?vr:Ei)(e)},pr.slice=function(e,t,n){var i=null==e?0:e.length;return i?(n&&"number"!=typeof n&&Bo(e,t,n)?(t=0,n=i):(t=null==t?0:Lu(t),n=n===r?i:Lu(n)),Oi(e,t,n)):[]},pr.sortBy=Ga,pr.sortedUniq=function(e){return e&&e.length?Mi(e):[]},pr.sortedUniqBy=function(e,t){return e&&e.length?Mi(e,wo(t,2)):[]},pr.split=function(e,t,n){return n&&"number"!=typeof n&&Bo(e,t,n)&&(t=n=r),(n=n===r?N:n>>>0)?(e=ju(e))&&("string"==typeof t||null!=t&&!Su(t))&&!(t=wi(t))&&On(e)?Ui(Dn(e),0,n):e.split(t,n):[]},pr.spread=function(e,t){if("function"!=typeof e)throw new it(a);return t=null==t?0:Gn(Lu(t),0),mi((function(n){var r=n[t],i=Ui(n,0,t);return r&&Zt(i,r),Vt(e,this,i)}))},pr.tail=function(e){var t=null==e?0:e.length;return t?Oi(e,1,t):[]},pr.take=function(e,t,n){return e&&e.length?Oi(e,0,(t=n||t===r?1:Lu(t))<0?0:t):[]},pr.takeRight=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,(t=i-(t=n||t===r?1:Lu(t)))<0?0:t,i):[]},pr.takeRightWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!1,!0):[]},pr.takeWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3)):[]},pr.tap=function(e,t){return t(e),e},pr.throttle=function(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new it(a);return bu(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Ya(e,t,{leading:r,maxWait:t,trailing:i})},pr.thru=Fa,pr.toArray=Au,pr.toPairs=is,pr.toPairsIn=os,pr.toPath=function(e){return lu(e)?Yt(e,ra):Iu(e)?[e]:Qi(na(ju(e)))},pr.toPlainObject=Ru,pr.transform=function(e,t,n){var r=lu(e),i=r||hu(e)||wu(e);if(t=wo(t,4),null==n){var o=e&&e.constructor;n=i?r?new o:[]:bu(e)&&gu(o)?hr(At(e)):{}}return(i?Gt:Br)(e,(function(e,r,i){return t(n,e,r,i)})),n},pr.unary=function(e){return Ka(e,1)},pr.union=Ca,pr.unionBy=Ea,pr.unionWith=Oa,pr.uniq=function(e){return e&&e.length?Di(e):[]},pr.uniqBy=function(e,t){return e&&e.length?Di(e,wo(t,2)):[]},pr.uniqWith=function(e,t){return t="function"==typeof t?t:r,e&&e.length?Di(e,r,t):[]},pr.unset=function(e,t){return null==e||ki(e,t)},pr.unzip=Ta,pr.unzipWith=Sa,pr.update=function(e,t,n){return null==e?e:Ai(e,t,ji(n))},pr.updateWith=function(e,t,n,i){return i="function"==typeof i?i:r,null==e?e:Ai(e,t,ji(n),i)},pr.values=as,pr.valuesIn=function(e){return null==e?[]:mn(e,Zu(e))},pr.without=xa,pr.words=gs,pr.wrap=function(e,t){return ru(ji(t),e)},pr.xor=Ma,pr.xorBy=Ia,pr.xorWith=wa,pr.zip=Da,pr.zipObject=function(e,t){return Pi(e||[],t||[],Cr)},pr.zipObjectDeep=function(e,t){return Pi(e||[],t||[],vi)},pr.zipWith=ka,pr.entries=is,pr.entriesIn=os,pr.extend=Bu,pr.extendWith=Uu,Ms(pr,pr),pr.add=Rs,pr.attempt=ys,pr.camelCase=us,pr.capitalize=ss,pr.ceil=js,pr.clamp=function(e,t,n){return n===r&&(n=t,t=r),n!==r&&(n=(n=Pu(n))==n?n:0),t!==r&&(t=(t=Pu(t))==t?t:0),Mr(Pu(e),t,n)},pr.clone=function(e){return Ir(e,f)},pr.cloneDeep=function(e){return Ir(e,l|f)},pr.cloneDeepWith=function(e,t){return Ir(e,l|f,t="function"==typeof t?t:r)},pr.cloneWith=function(e,t){return Ir(e,f,t="function"==typeof t?t:r)},pr.conformsTo=function(e,t){return null==t||wr(e,t,Yu(t))},pr.deburr=cs,pr.defaultTo=function(e,t){return null==e||e!=e?t:e},pr.divide=Hs,pr.endsWith=function(e,t,n){e=ju(e),t=wi(t);var i=e.length,o=n=n===r?i:Mr(Lu(n),0,i);return(n-=t.length)>=0&&e.slice(n,o)==t},pr.eq=au,pr.escape=function(e){return(e=ju(e))&&Oe.test(e)?e.replace(Ce,Cn):e},pr.escapeRegExp=function(e){return(e=ju(e))&&ke.test(e)?e.replace(De,"\\$&"):e},pr.every=function(e,t,n){var i=lu(e)?Kt:Lr;return n&&Bo(e,t,n)&&(t=r),i(e,wo(t,3))},pr.find=Pa,pr.findIndex=ca,pr.findKey=function(e,t){return rn(e,wo(t,3),Br)},pr.findLast=Ra,pr.findLastIndex=la,pr.findLastKey=function(e,t){return rn(e,wo(t,3),Ur)},pr.floor=Bs,pr.forEach=ja,pr.forEachRight=Ha,pr.forIn=function(e,t){return null==e?e:jr(e,wo(t,3),Zu)},pr.forInRight=function(e,t){return null==e?e:Hr(e,wo(t,3),Zu)},pr.forOwn=function(e,t){return e&&Br(e,wo(t,3))},pr.forOwnRight=function(e,t){return e&&Ur(e,wo(t,3))},pr.get=qu,pr.gt=uu,pr.gte=su,pr.has=function(e,t){return null!=e&&Po(e,t,Kr)},pr.hasIn=Ku,pr.head=fa,pr.identity=Os,pr.includes=function(e,t,n,r){e=fu(e)?e:as(e),n=n&&!r?Lu(n):0;var i=e.length;return n<0&&(n=Gn(i+n,0)),Mu(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&an(e,t,n)>-1},pr.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Lu(n);return i<0&&(i=Gn(r+i,0)),an(e,t,i)},pr.inRange=function(e,t,n){return t=Fu(t),n===r?(n=t,t=0):n=Fu(n),function(e,t,n){return e>=qn(t,n)&&e<Gn(t,n)}(e=Pu(e),t,n)},pr.invoke=$u,pr.isArguments=cu,pr.isArray=lu,pr.isArrayBuffer=du,pr.isArrayLike=fu,pr.isArrayLikeObject=pu,pr.isBoolean=function(e){return!0===e||!1===e||Cu(e)&&Gr(e)==z},pr.isBuffer=hu,pr.isDate=_u,pr.isElement=function(e){return Cu(e)&&1===e.nodeType&&!Tu(e)},pr.isEmpty=function(e){if(null==e)return!0;if(fu(e)&&(lu(e)||"string"==typeof e||"function"==typeof e.splice||hu(e)||wu(e)||cu(e)))return!e.length;var t=No(e);if(t==X||t==ee)return!e.size;if(Wo(e))return!ni(e).length;for(var n in e)if(lt.call(e,n))return!1;return!0},pr.isEqual=function(e,t){return Zr(e,t)},pr.isEqualWith=function(e,t,n){var i=(n="function"==typeof n?n:r)?n(e,t):r;return i===r?Zr(e,t,r,n):!!i},pr.isError=mu,pr.isFinite=function(e){return"number"==typeof e&&zn(e)},pr.isFunction=gu,pr.isInteger=yu,pr.isLength=vu,pr.isMap=Eu,pr.isMatch=function(e,t){return e===t||Jr(e,t,ko(t))},pr.isMatchWith=function(e,t,n){return n="function"==typeof n?n:r,Jr(e,t,ko(t),n)},pr.isNaN=function(e){return Ou(e)&&e!=+e},pr.isNative=function(e){if(Vo(e))throw new Ze(o);return ei(e)},pr.isNil=function(e){return null==e},pr.isNull=function(e){return null===e},pr.isNumber=Ou,pr.isObject=bu,pr.isObjectLike=Cu,pr.isPlainObject=Tu,pr.isRegExp=Su,pr.isSafeInteger=function(e){return yu(e)&&e>=-A&&e<=A},pr.isSet=xu,pr.isString=Mu,pr.isSymbol=Iu,pr.isTypedArray=wu,pr.isUndefined=function(e){return e===r},pr.isWeakMap=function(e){return Cu(e)&&No(e)==ie},pr.isWeakSet=function(e){return Cu(e)&&Gr(e)==oe},pr.join=function(e,t){return null==e?"":Vn.call(e,t)},pr.kebabCase=ls,pr.last=ma,pr.lastIndexOf=function(e,t,n){var i=null==e?0:e.length;if(!i)return-1;var o=i;return n!==r&&(o=(o=Lu(n))<0?Gn(i+o,0):qn(o,i-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):on(e,sn,o,!0)},pr.lowerCase=ds,pr.lowerFirst=fs,pr.lt=Du,pr.lte=ku,pr.max=function(e){return e&&e.length?Nr(e,Os,qr):r},pr.maxBy=function(e,t){return e&&e.length?Nr(e,wo(t,2),qr):r},pr.mean=function(e){return cn(e,Os)},pr.meanBy=function(e,t){return cn(e,wo(t,2))},pr.min=function(e){return e&&e.length?Nr(e,Os,ii):r},pr.minBy=function(e,t){return e&&e.length?Nr(e,wo(t,2),ii):r},pr.stubArray=Ns,pr.stubFalse=Ps,pr.stubObject=function(){return{}},pr.stubString=function(){return""},pr.stubTrue=function(){return!0},pr.multiply=zs,pr.nth=function(e,t){return e&&e.length?ci(e,Lu(t)):r},pr.noConflict=function(){return kt._===this&&(kt._=_t),this},pr.noop=Is,pr.now=qa,pr.pad=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return lo(Hn(i),n)+e+lo(jn(i),n)},pr.padEnd=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;return t&&r<t?e+lo(t-r,n):e},pr.padStart=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;return t&&r<t?lo(t-r,n)+e:e},pr.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),Xn(ju(e).replace(Fe,""),t||0)},pr.random=function(e,t,n){if(n&&"boolean"!=typeof n&&Bo(e,t,n)&&(t=n=r),n===r&&("boolean"==typeof t?(n=t,t=r):"boolean"==typeof e&&(n=e,e=r)),e===r&&t===r?(e=0,t=1):(e=Fu(e),t===r?(t=e,e=0):t=Fu(t)),e>t){var i=e;e=t,t=i}if(n||e%1||t%1){var o=Qn();return qn(e+o*(t-e+Mt("1e-"+((o+"").length-1))),t)}return hi(e,t)},pr.reduce=function(e,t,n){var r=lu(e)?Jt:fn,i=arguments.length<3;return r(e,wo(t,4),n,i,Ar)},pr.reduceRight=function(e,t,n){var r=lu(e)?en:fn,i=arguments.length<3;return r(e,wo(t,4),n,i,Fr)},pr.repeat=function(e,t,n){return t=(n?Bo(e,t,n):t===r)?1:Lu(t),_i(ju(e),t)},pr.replace=function(){var e=arguments,t=ju(e[0]);return e.length<3?t:t.replace(e[1],e[2])},pr.result=function(e,t,n){var i=-1,o=(t=Hi(t,e)).length;for(o||(o=1,e=r);++i<o;){var a=null==e?r:e[ra(t[i])];a===r&&(i=o,a=n),e=gu(a)?a.call(e):a}return e},pr.round=Vs,pr.runInContext=e,pr.sample=function(e){return(lu(e)?gr:gi)(e)},pr.size=function(e){if(null==e)return 0;if(fu(e))return Mu(e)?wn(e):e.length;var t=No(e);return t==X||t==ee?e.size:ni(e).length},pr.snakeCase=ps,pr.some=function(e,t,n){var i=lu(e)?tn:Ti;return n&&Bo(e,t,n)&&(t=r),i(e,wo(t,3))},pr.sortedIndex=function(e,t){return Si(e,t)},pr.sortedIndexBy=function(e,t,n){return xi(e,t,wo(n,2))},pr.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=Si(e,t);if(r<n&&au(e[r],t))return r}return-1},pr.sortedLastIndex=function(e,t){return Si(e,t,!0)},pr.sortedLastIndexBy=function(e,t,n){return xi(e,t,wo(n,2),!0)},pr.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=Si(e,t,!0)-1;if(au(e[n],t))return n}return-1},pr.startCase=hs,pr.startsWith=function(e,t,n){return e=ju(e),n=null==n?0:Mr(Lu(n),0,e.length),t=wi(t),e.slice(n,n+t.length)==t},pr.subtract=Ws,pr.sum=function(e){return e&&e.length?pn(e,Os):0},pr.sumBy=function(e,t){return e&&e.length?pn(e,wo(t,2)):0},pr.template=function(e,t,n){var i=pr.templateSettings;n&&Bo(e,t,n)&&(t=r),e=ju(e),t=Uu({},t,i,vo);var o,a,u=Uu({},t.imports,i.imports,vo),s=Yu(u),c=mn(u,s),l=0,d=t.interpolate||Xe,f="__p += '",p=nt((t.escape||Xe).source+"|"+d.source+"|"+(d===xe?Be:Xe).source+"|"+(t.evaluate||Xe).source+"|$","g"),h="//# sourceURL="+(lt.call(t,"sourceURL")?(t.sourceURL+"").replace(/[\r\n]/g," "):"lodash.templateSources["+ ++Ot+"]")+"\n";e.replace(p,(function(t,n,r,i,u,s){return r||(r=i),f+=e.slice(l,s).replace(Qe,En),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),u&&(a=!0,f+="';\n"+u+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=s+t.length,t})),f+="';\n";var _=lt.call(t,"variable")&&t.variable;_||(f="with (obj) {\n"+f+"\n}\n"),f=(a?f.replace(ge,""):f).replace(ye,"$1").replace(ve,"$1;"),f="function("+(_||"obj")+") {\n"+(_?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var m=ys((function(){return Je(s,h+"return "+f).apply(r,c)}));if(m.source=f,mu(m))throw m;return m},pr.times=function(e,t){if((e=Lu(e))<1||e>A)return[];var n=N,r=qn(e,N);t=wo(t),e-=N;for(var i=hn(r,t);++n<e;)t(n);return i},pr.toFinite=Fu,pr.toInteger=Lu,pr.toLength=Nu,pr.toLower=function(e){return ju(e).toLowerCase()},pr.toNumber=Pu,pr.toSafeInteger=function(e){return e?Mr(Lu(e),-A,A):0===e?e:0},pr.toString=ju,pr.toUpper=function(e){return ju(e).toUpperCase()},pr.trim=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Ae,"");if(!e||!(t=wi(t)))return e;var i=Dn(e),o=Dn(t);return Ui(i,yn(i,o),vn(i,o)+1).join("")},pr.trimEnd=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Le,"");if(!e||!(t=wi(t)))return e;var i=Dn(e);return Ui(i,0,vn(i,Dn(t))+1).join("")},pr.trimStart=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Fe,"");if(!e||!(t=wi(t)))return e;var i=Dn(e);return Ui(i,yn(i,Dn(t))).join("")},pr.truncate=function(e,t){var n=S,i=x;if(bu(t)){var o="separator"in t?t.separator:o;n="length"in t?Lu(t.length):n,i="omission"in t?wi(t.omission):i}var a=(e=ju(e)).length;if(On(e)){var u=Dn(e);a=u.length}if(n>=a)return e;var s=n-wn(i);if(s<1)return i;var c=u?Ui(u,0,s).join(""):e.slice(0,s);if(o===r)return c+i;if(u&&(s+=c.length-s),Su(o)){if(e.slice(s).search(o)){var l,d=c;for(o.global||(o=nt(o.source,ju(Ue.exec(o))+"g")),o.lastIndex=0;l=o.exec(d);)var f=l.index;c=c.slice(0,f===r?s:f)}}else if(e.indexOf(wi(o),s)!=s){var p=c.lastIndexOf(o);p>-1&&(c=c.slice(0,p))}return c+i},pr.unescape=function(e){return(e=ju(e))&&Ee.test(e)?e.replace(be,kn):e},pr.uniqueId=function(e){var t=++dt;return ju(e)+t},pr.upperCase=_s,pr.upperFirst=ms,pr.each=ja,pr.eachRight=Ha,pr.first=fa,Ms(pr,(Us={},Br(pr,(function(e,t){lt.call(pr.prototype,t)||(Us[t]=e)})),Us),{chain:!1}),pr.VERSION="4.17.15",Gt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){pr[e].placeholder=pr})),Gt(["drop","take"],(function(e,t){LazyWrapper.prototype[e]=function(n){n=n===r?1:Gn(Lu(n),0);var i=this.__filtered__&&!t?new LazyWrapper(this):this.clone();return i.__filtered__?i.__takeCount__=qn(n,i.__takeCount__):i.__views__.push({size:qn(n,N),type:e+(i.__dir__<0?"Right":"")}),i},LazyWrapper.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),Gt(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=n==w||3==n;LazyWrapper.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:wo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),Gt(["head","last"],(function(e,t){var n="take"+(t?"Right":"");LazyWrapper.prototype[e]=function(){return this[n](1).value()[0]}})),Gt(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");LazyWrapper.prototype[e]=function(){return this.__filtered__?new LazyWrapper(this):this[n](1)}})),LazyWrapper.prototype.compact=function(){return this.filter(Os)},LazyWrapper.prototype.find=function(e){return this.filter(e).head()},LazyWrapper.prototype.findLast=function(e){return this.reverse().find(e)},LazyWrapper.prototype.invokeMap=mi((function(e,t){return"function"==typeof e?new LazyWrapper(this):this.map((function(n){return $r(n,e,t)}))})),LazyWrapper.prototype.reject=function(e){return this.filter(tu(wo(e)))},LazyWrapper.prototype.slice=function(e,t){e=Lu(e);var n=this;return n.__filtered__&&(e>0||t<0)?new LazyWrapper(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==r&&(n=(t=Lu(t))<0?n.dropRight(-t):n.take(t-e)),n)},LazyWrapper.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},LazyWrapper.prototype.toArray=function(){return this.take(N)},Br(LazyWrapper.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),i=/^(?:head|last)$/.test(t),o=pr[i?"take"+("last"==t?"Right":""):t],a=i||/^find/.test(t);o&&(pr.prototype[t]=function(){var t=this.__wrapped__,u=i?[1]:arguments,s=t instanceof LazyWrapper,c=u[0],l=s||lu(t),d=function(e){var t=o.apply(pr,Zt([e],u));return i&&f?t[0]:t};l&&n&&"function"==typeof c&&1!=c.length&&(s=l=!1);var f=this.__chain__,p=!!this.__actions__.length,h=a&&!f,_=s&&!p;if(!a&&l){t=_?t:new LazyWrapper(this);var m=e.apply(t,u);return m.__actions__.push({func:Fa,args:[d],thisArg:r}),new LodashWrapper(m,f)}return h&&_?e.apply(this,u):(m=this.thru(d),h?i?m.value()[0]:m.value():m)})})),Gt(["pop","push","shift","sort","splice","unshift"],(function(e){var t=ot[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);pr.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(lu(i)?i:[],e)}return this[n]((function(n){return t.apply(lu(n)?n:[],e)}))}})),Br(LazyWrapper.prototype,(function(e,t){var n=pr[t];if(n){var r=n.name+"";lt.call(ir,r)||(ir[r]=[]),ir[r].push({name:t,func:n})}})),ir[ao(r,m).name]=[{name:"wrapper",func:r}],LazyWrapper.prototype.clone=function(){var e=new LazyWrapper(this.__wrapped__);return e.__actions__=Qi(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=Qi(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=Qi(this.__views__),e},LazyWrapper.prototype.reverse=function(){if(this.__filtered__){var e=new LazyWrapper(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},LazyWrapper.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=lu(e),r=t<0,i=n?e.length:0,o=function(e,t,n){var r=-1,i=n.length;for(;++r<i;){var o=n[r],a=o.size;switch(o.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=qn(t,e+a);break;case"takeRight":e=Gn(e,t-a)}}return{start:e,end:t}}(0,i,this.__views__),a=o.start,u=o.end,s=u-a,c=r?u:a-1,l=this.__iteratees__,d=l.length,f=0,p=qn(s,this.__takeCount__);if(!n||!r&&i==s&&p==s)return Li(e,this.__actions__);var h=[];e:for(;s--&&f<p;){for(var _=-1,m=e[c+=t];++_<d;){var g=l[_],y=g.iteratee,v=g.type,b=y(m);if(v==D)m=b;else if(!b){if(v==w)continue e;break e}}h[f++]=m}return h},pr.prototype.at=La,pr.prototype.chain=function(){return Aa(this)},pr.prototype.commit=function(){return new LodashWrapper(this.value(),this.__chain__)},pr.prototype.next=function(){this.__values__===r&&(this.__values__=Au(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?r:this.__values__[this.__index__++]}},pr.prototype.plant=function(e){for(var t,n=this;n instanceof _r;){var i=oa(n);i.__index__=0,i.__values__=r,t?o.__wrapped__=i:t=i;var o=i;n=n.__wrapped__}return o.__wrapped__=e,t},pr.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof LazyWrapper){var t=e;return this.__actions__.length&&(t=new LazyWrapper(this)),(t=t.reverse()).__actions__.push({func:Fa,args:[ba],thisArg:r}),new LodashWrapper(t,this.__chain__)}return this.thru(ba)},pr.prototype.toJSON=pr.prototype.valueOf=pr.prototype.value=function(){return Li(this.__wrapped__,this.__actions__)},pr.prototype.first=pr.prototype.head,dn&&(pr.prototype[dn]=function(){return this}),pr}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(kt._=An,define((function(){return An}))):Ft?((Ft.exports=An)._=An,At._=An):kt._=An}).call(this)}).call(this,n(15),n(113)(e))},function(e,t,n){!function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var i=arguments[r];if(i){var o=typeof i;if("string"===o||"number"===o)e.push(i);else if(Array.isArray(i)&&i.length){var a=n.apply(null,i);a&&e.push(a)}else if("object"===o)for(var u in i)t.call(i,u)&&i[u]&&e.push(u)}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t,n){"use strict";n.d(t,"b",(function(){return __extends})),n.d(t,"a",(function(){return __assign})),n.d(t,"d",(function(){return __values})),n.d(t,"c",(function(){return __spread}));var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function __extends(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function __assign(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __values(e){var t="function"==typeof Symbol&&e[Symbol.iterator],n=0;return t?t.call(e):{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}function __read(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}},,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(14),m=n.n(_),g=n(1),y=function(t){function Link(){return i()(this,Link),s()(this,l()(Link).apply(this,arguments))}return f()(Link,t),a()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,r=t.onClick,i=t.href,o=t.children,a=t.className,u=t.arrow,s=t.external,c=t.inverse,l=t.back,d=t.small,f=t.inherit,p=t.caps,h=t.danger,_=t.disabled,g=t.id,y=i&&!_,v=y?"a":"button";return e.createElement(v,{className:m()("googlesitekit-cta-link",a,{"googlesitekit-cta-link--arrow":u,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":c,"googlesitekit-cta-link--back":l,"googlesitekit-cta-link--small":d,"googlesitekit-cta-link--inherit":f,"googlesitekit-cta-link--caps":p,"googlesitekit-cta-link--danger":h,"googlesitekit-cta-link--disabled":_}),onClick:r,id:g,href:y?i:void 0,target:y&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:_,dangerouslySetInnerHTML:n},o)}}]),Link}(g.Component);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(1))},,,function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(1),i=function(e){return function(t){return function FilteredComponent(n){return Object(r.createElement)(r.Fragment,{},"",Object(r.createElement)(t,n),e)}}}},function(e,t,n){"use strict";(function(e,r){var i=n(2),o=n.n(i),a=n(14),u=n.n(a),s=function SvgIcon(t){var n=t.id,i=t.className,o=t.height,a=t.width,s="".concat(e.googlesitekit.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:u()("svg",i),height:o,width:a},r.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:o.a.string.isRequired,className:o.a.string,height:o.a.string,width:o.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(15),n(1))},function(e,t,n){"use strict";var r=n(70),i=n.n(r);n.d(t,"l",(function(){return i.a})),n.d(t,"a",(function(){return r.HelperText})),n.d(t,"b",(function(){return r.Input}));var o=n(117);n.d(t,"h",(function(){return o.a}));var a=n(123);n.d(t,"e",(function(){return a.a}));var u=n(125);n.d(t,"g",(function(){return u.a}));var s=n(86),c=n.n(s);n.d(t,"k",(function(){return c.a})),n.d(t,"j",(function(){return s.Option}));var l=n(124);n.d(t,"i",(function(){return l.a}));var d=n(122);n.d(t,"d",(function(){return d.a}));var f=n(121);n.d(t,"c",(function(){return f.a}));var p=n(120);n.d(t,"f",(function(){return p.a}))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(16),f=n.n(d),p=n(9),h=n.n(p),_=n(2),m=n.n(_),g=n(58),y=n(14),v=n.n(y),b=n(1),C=n(126),E=function(t){function DataBlock(e){var t;return i()(this,DataBlock),(t=s()(this,l()(DataBlock).call(this,e))).handleClick=t.handleClick.bind(f()(t)),t.handleKeyPress=t.handleKeyPress.bind(f()(t)),t}return h()(DataBlock,t),a()(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,i=t.datapoint,o=t.datapointUnit,a=t.change,u=t.changeDataUnit,s=t.context,c=t.period,l=t.selected,d=t.handleStatSelection,f=t.source,p=t.sparkline,h=t.invertChangeColor,_="button"===s?"button":"",m=p;return m&&h&&(m=Object(b.cloneElement)(p,{invertChangeColor:h})),e.createElement("div",{className:v()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":l}),tabIndex:"button"===s?"0":"-1",role:d&&_,onClick:d&&this.handleClick,onKeyPress:d&&this.handleKeyPress,"aria-label":d&&r,"aria-pressed":d&&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(i).concat(o))),m&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},m),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===a&&e.createElement(b.Fragment,null," "),a&&e.createElement(b.Fragment,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(C.a,{direction:0<parseFloat(a)?"up":"down",invertColor:h})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Math.abs(a)).concat(u," ").concat(c)))),f&&e.createElement(g.a,{className:"googlesitekit-data-block__source",name:f.name,href:f.link})))}}]),DataBlock}(b.Component);E.propTypes={stat:m.a.number,onClick:m.a.func,className:m.a.string,title:m.a.string,datapoint:m.a.oneOfType([m.a.string,m.a.number]),datapointUnit:m.a.string,change:m.a.oneOfType([m.a.string,m.a.number]),changeDataUnit:m.a.string,context:m.a.string,period:m.a.string,selected:m.a.bool,handleStatSelection:m.a.func,invertChangeColor:m.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(1))},,function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(){function MDCFoundation(e){void 0===e&&(e={}),this.adapter_=e}return Object.defineProperty(MDCFoundation,"cssClasses",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"strings",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"numbers",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"defaultAdapter",{get:function(){return{}},enumerable:!0,configurable:!0}),MDCFoundation.prototype.init=function(){},MDCFoundation.prototype.destroy=function(){},MDCFoundation}()},,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(17),i=n(28),o=function(){function MDCComponent(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];this.root_=e,this.initialize.apply(this,r.c(n)),this.foundation_=void 0===t?this.getDefaultFoundation():t,this.foundation_.init(),this.initialSyncWithDOM()}return MDCComponent.attachTo=function(e){return new MDCComponent(e,new i.a({}))},MDCComponent.prototype.initialize=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t]},MDCComponent.prototype.getDefaultFoundation=function(){throw new Error("Subclasses must override getDefaultFoundation to return a properly configured foundation class")},MDCComponent.prototype.initialSyncWithDOM=function(){},MDCComponent.prototype.destroy=function(){this.foundation_.destroy()},MDCComponent.prototype.listen=function(e,t){this.root_.addEventListener(e,t)},MDCComponent.prototype.unlisten=function(e,t){this.root_.removeEventListener(e,t)},MDCComponent.prototype.emit=function(e,t,n){var r;void 0===n&&(n=!1),"function"==typeof CustomEvent?r=new CustomEvent(e,{bubbles:n,detail:t}):(r=document.createEvent("CustomEvent")).initCustomEvent(e,n,!1,t),this.root_.dispatchEvent(r)},MDCComponent}()},function(e,t,n){"use strict";(function(e){var r=n(22),i=n.n(r),o=n(11),a=n.n(o),u=n(5),s=n.n(u),c=n(6),l=n.n(c),d=n(7),f=n.n(d),p=n(8),h=n.n(p),_=n(16),m=n.n(_),g=n(9),y=n.n(g),v=n(2),b=n.n(v),C=n(10),E=n(26),O=n(33),T=n(73),S=n(84),x=n(19),M=n(24),I=n(14),w=n.n(I),D=n(13),k=n(1),A=n(72),F=function(t){function Notification(e){var t;return s()(this,Notification),(t=f()(this,h()(Notification).call(this,e))).state={isClosed:!1},t.cardRef=Object(k.createRef)(),t.handleDismiss=t.handleDismiss.bind(m()(t)),t.handleCTAClick=t.handleCTAClick.bind(m()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&C.c.setCache("notification::displayed::".concat(t.props.id),new Date),t}return y()(Notification,t),l()(Notification,[{key:"handleDismiss",value:function(e){var t;return a.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:if(e.persist(),e.preventDefault(),!(t=this.props.onDismiss)){n.next=6;break}return n.next=6,a.a.awrap(t(e));case 6:this.dismiss();case 7:case"end":return n.stop()}}),null,this)}},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){C.c.setCache("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:function(e){var t,n,r;return a.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e.persist(),t=this.props,n=t.isDismissable,!(r=t.onCTAClick)){i.next=5;break}return i.next=5,a.a.awrap(r(e));case 5:n&&this.dismiss();case 6:case"end":return i.stop()}}),null,this)}},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,r=C.c.getCache("notification::dismissed::".concat(t));if(r){var i=new Date(r);i.setSeconds(i.getSeconds()+parseInt(n,10)),i<new Date&&C.c.deleteCache("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,r=this.props,o=r.children,a=r.id,u=r.title,s=r.description,c=r.blockData,l=r.winImage,d=r.smallImage,f=r.format,p=r.learnMoreURL,h=r.learnMoreDescription,_=r.learnMoreLabel,m=r.ctaLink,g=r.ctaLabel,y=r.ctaTarget,v=r.type,b=r.dismiss,I=r.isDismissable,F=r.logo,L=r.module,N=r.moduleName,P=r.pageIndex;if(C.c.getCache("notification::dismissed::".concat(a)))return null;var R,j=n?"is-closed":"is-open",H="large"===f&&"win-stats-increase"===v,B="mdc-layout-grid__cell--span-12";"large"===f?(B="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&&(B="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"===f&&(B="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),R="win-warning"===v?e.createElement(T.a,null):"win-error"===v?e.createElement(S.a,null):"";var U=e.createElement(k.Fragment,null,c&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(D.map)(c,(function(t,n){return e.createElement("div",{key:n,className:w()("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(E.a,t)))})))),z=e.createElement(k.Fragment,null,u&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},u),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(k.isValidElement)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(A.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),_&&e.createElement(k.Fragment,null," ",e.createElement(x.a,{href:p,external:!0,inherit:!0},_),h),P&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},P))),o),V=L?e.createElement(M.a,{id:L,height:"19",width:"19"}):e.createElement(M.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:w()("googlesitekit-publisher-win",(t={},i()(t,"googlesitekit-publisher-win--".concat(f),f),i()(t,"googlesitekit-publisher-win--".concat(v),v),i()(t,"googlesitekit-publisher-win--".concat(j),j),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},F&&e.createElement("div",{className:w()("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),N&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},N)),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:w()("mdc-layout-grid__cell",B)},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"},z),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"},U)):e.createElement(k.Fragment,null,z,U),m&&e.createElement(O.a,{href:m,target:y,onClick:this.handleCTAClick},g),I&&b&&e.createElement(x.a,{onClick:this.handleDismiss},b)),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"===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"},R)))))}}]),Notification}(k.Component);F.propTypes={id:b.a.string.isRequired,title:b.a.string.isRequired,description:b.a.node,learnMoreURL:b.a.string,learnMoreDescription:b.a.string,learnMoreLabel:b.a.string,blockData:b.a.array,winImage:b.a.string,smallImage:b.a.string,format:b.a.string,ctaLink:b.a.string,ctaLabel:b.a.string,type:b.a.string,dismiss:b.a.string,isDismissable:b.a.bool,logo:b.a.bool,module:b.a.string,moduleName:b.a.string,pageIndex:b.a.string,dismissExpires:b.a.number,showOnce:b.a.bool,onCTAClick:b.a.func,onDismiss:b.a.func},F.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=F}).call(this,n(1))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(14),m=n.n(_),g=n(1),y=function(t){function ProgressBar(){return i()(this,ProgressBar),s()(this,l()(ProgressBar).apply(this,arguments))}return f()(ProgressBar,t),a()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,r=t.small,i=t.compress,o=t.height,a=o?Math.round(o/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:a,marginBottom:a},className:m()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":r,"mdc-linear-progress--compress":i})},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}(g.Component);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(1))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(25),h=n(2),_=n.n(h),m=n(14),g=n.n(m),y=n(1),v=function(t){function Button(e){var t;return i()(this,Button),(t=s()(this,l()(Button).call(this,e))).buttonRef=Object(y.createRef)(),t}return f()(Button,t),a()(Button,[{key:"componentDidMount",value:function(){new p.h(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,r=t.children,i=t.href,o=t.text,a=t.className,u=t.danger,s=t.disabled,c=t.target,l=t.id,d=t.icon,f=t.trailingIcon,p=t.ariaHaspopup,h=t.ariaExpanded,_=t.ariaControls,m=i&&!s?"a":"button";return e.createElement(m,{className:g()("mdc-button",a,{"mdc-button--raised":!o,"mdc-button--danger":u}),onClick:n,href:s?void 0:i,ref:this.buttonRef,disabled:!!s,target:c||"_self",id:l,"aria-haspopup":p,"aria-expanded":h,"aria-controls":_},d&&d,e.createElement("span",{className:"mdc-button__label"},r),f&&f)}}]),Button}(y.Component);v.propTypes={onClick:_.a.func,children:_.a.string.isRequired,href:_.a.string,text:_.a.bool,className:_.a.string,danger:_.a.bool,disabled:_.a.bool,icon:_.a.element,trailingIcon:_.a.element,ariaHaspopup:_.a.string,ariaExpanded:_.a.bool,ariaControls:_.a.string},v.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=v}).call(this,n(1))},function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n(17),i=n(30),o=n(35),a=n(42),u=n(43),s=function(e){function MDCRipple(){var t=null!==e&&e.apply(this,arguments)||this;return t.disabled=!1,t}return r.b(MDCRipple,e),MDCRipple.attachTo=function(e,t){void 0===t&&(t={isUnbounded:void 0});var n=new MDCRipple(e);return void 0!==t.isUnbounded&&(n.unbounded=t.isUnbounded),n},MDCRipple.createAdapter=function(e){return{addClass:function(t){return e.root_.classList.add(t)},browserSupportsCssVars:function(){return u.c(window)},computeBoundingRect:function(){return e.root_.getBoundingClientRect()},containsEventTarget:function(t){return e.root_.contains(t)},deregisterDocumentInteractionHandler:function(e,t){return document.documentElement.removeEventListener(e,t,u.a())},deregisterInteractionHandler:function(t,n){return e.root_.removeEventListener(t,n,u.a())},deregisterResizeHandler:function(e){return window.removeEventListener("resize",e)},getWindowPageOffset:function(){return{x:window.pageXOffset,y:window.pageYOffset}},isSurfaceActive:function(){return Object(o.b)(e.root_,":active")},isSurfaceDisabled:function(){return Boolean(e.disabled)},isUnbounded:function(){return Boolean(e.unbounded)},registerDocumentInteractionHandler:function(e,t){return document.documentElement.addEventListener(e,t,u.a())},registerInteractionHandler:function(t,n){return e.root_.addEventListener(t,n,u.a())},registerResizeHandler:function(e){return window.addEventListener("resize",e)},removeClass:function(t){return e.root_.classList.remove(t)},updateCssVariable:function(t,n){return e.root_.style.setProperty(t,n)}}},Object.defineProperty(MDCRipple.prototype,"unbounded",{get:function(){return Boolean(this.unbounded_)},set:function(e){this.unbounded_=Boolean(e),this.setUnbounded_()},enumerable:!0,configurable:!0}),MDCRipple.prototype.activate=function(){this.foundation_.activate()},MDCRipple.prototype.deactivate=function(){this.foundation_.deactivate()},MDCRipple.prototype.layout=function(){this.foundation_.layout()},MDCRipple.prototype.getDefaultFoundation=function(){return new a.a(MDCRipple.createAdapter(this))},MDCRipple.prototype.initialSyncWithDOM=function(){var e=this.root_;this.unbounded="mdcRippleIsUnbounded"in e.dataset},MDCRipple.prototype.setUnbounded_=function(){this.foundation_.setUnbounded(Boolean(this.unbounded_))},MDCRipple}(i.a)},function(e,t,n){"use strict";function r(e,t){if(e.closest)return e.closest(t);for(var n=e;n;){if(i(n,t))return n;n=n.parentElement}return null}function i(e,t){return(e.matches||e.webkitMatchesSelector||e.msMatchesSelector).call(e,t)}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i}))},function(e,t,n){"use strict";var r=n(49);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n(50)),o=r(n(108)),a=n(0),u=r(n(162)),s=r(n(163)),c=r(n(164)),l=r(n(165)),d=r(n(109)),f=r(n(171)),p=r(n(172)),h=r(n(173)),_=n(112),m={Accept:"application/json, */*;q=0.1"},g={credentials:"include"},y=[p.default,d.default,f.default,l.default];var v=function(e){if(e.status>=200&&e.status<300)return e;throw e},b=function(e){var t=e.url,n=e.path,r=e.data,u=e.parse,s=void 0===u||u,c=(0,o.default)(e,["url","path","data","parse"]),l=e.body,d=e.headers;return d=(0,i.default)({},m,d),r&&(l=JSON.stringify(r),d["Content-Type"]="application/json"),window.fetch(t||n,(0,i.default)({},g,c,{body:l,headers:d})).then((function(e){return Promise.resolve(e).then(v).catch((function(e){return(0,_.parseAndThrowError)(e,s)})).then((function(e){return(0,_.parseResponseAndNormalizeError)(e,s)}))}),(function(){throw{code:"fetch_error",message:(0,a.__)("You are probably offline.")}}))};function C(e){var t=[].concat(y,[b]);return new Promise((function(n,r){(function e(n){return function(r){var i=t[n];return n===t.length-1?i(r):i(r,e(n+1))}})(0)(e).then(n).catch((function(t){if("rest_cookie_invalid_nonce"!==t.code)return r(t);window.fetch(C.nonceEndpoint).then(v).then((function(e){return e.text()})).then((function(t){C.nonceMiddleware.nonce=t,C(e).then(n).catch(r)})).catch(r)}))}))}C.use=function(e){y.unshift(e)},C.setFetchHandler=function(e){b=e},C.createNonceMiddleware=u.default,C.createPreloadingMiddleware=c.default,C.createRootURLMiddleware=s.default,C.fetchAllMiddleware=l.default,C.mediaUploadMiddleware=h.default;var E=C;t.default=E},,function(e,t,n){"use strict";function r(e){return{byContext:function(t){return e.filter((function(e){return e.usageContext.includes(t)}))}}}function i(e){return(parseInt(e)||0)>0}function o(e){return!!e&&e.toString().match(/^GTM-[A-Z0-9]+$/)}var 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]+)['|"]/];n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"d",(function(){return a}))},,,function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r(t){return"function"==typeof Symbol&&"symbol"===n(Symbol.iterator)?e.exports=r=function(e){return n(e)}:e.exports=r=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":n(e)},r(t)}e.exports=r},function(e,t,n){"use strict";var r=n(17),i=n(28),o={BG_FOCUSED:"mdc-ripple-upgraded--background-focused",FG_ACTIVATION:"mdc-ripple-upgraded--foreground-activation",FG_DEACTIVATION:"mdc-ripple-upgraded--foreground-deactivation",ROOT:"mdc-ripple-upgraded",UNBOUNDED:"mdc-ripple-upgraded--unbounded"},a={VAR_FG_SCALE:"--mdc-ripple-fg-scale",VAR_FG_SIZE:"--mdc-ripple-fg-size",VAR_FG_TRANSLATE_END:"--mdc-ripple-fg-translate-end",VAR_FG_TRANSLATE_START:"--mdc-ripple-fg-translate-start",VAR_LEFT:"--mdc-ripple-left",VAR_TOP:"--mdc-ripple-top"},u={DEACTIVATION_TIMEOUT_MS:225,FG_DEACTIVATION_MS:150,INITIAL_ORIGIN_SCALE:.6,PADDING:10,TAP_DELAY_MS:300},s=n(43);n.d(t,"a",(function(){return f}));var c=["touchstart","pointerdown","mousedown","keydown"],l=["touchend","pointerup","mouseup","contextmenu"],d=[],f=function(e){function MDCRippleFoundation(t){var n=e.call(this,r.a({},MDCRippleFoundation.defaultAdapter,t))||this;return n.activationAnimationHasEnded_=!1,n.activationTimer_=0,n.fgDeactivationRemovalTimer_=0,n.fgScale_="0",n.frame_={width:0,height:0},n.initialSize_=0,n.layoutFrame_=0,n.maxRadius_=0,n.unboundedCoords_={left:0,top:0},n.activationState_=n.defaultActivationState_(),n.activationTimerCallback_=function(){n.activationAnimationHasEnded_=!0,n.runDeactivationUXLogicIfReady_()},n.activateHandler_=function(e){return n.activate_(e)},n.deactivateHandler_=function(){return n.deactivate_()},n.focusHandler_=function(){return n.handleFocus()},n.blurHandler_=function(){return n.handleBlur()},n.resizeHandler_=function(){return n.layout()},n}return r.b(MDCRippleFoundation,e),Object.defineProperty(MDCRippleFoundation,"cssClasses",{get:function(){return o},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"strings",{get:function(){return a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"numbers",{get:function(){return u},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},browserSupportsCssVars:function(){return!0},computeBoundingRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},containsEventTarget:function(){return!0},deregisterDocumentInteractionHandler:function(){},deregisterInteractionHandler:function(){},deregisterResizeHandler:function(){},getWindowPageOffset:function(){return{x:0,y:0}},isSurfaceActive:function(){return!0},isSurfaceDisabled:function(){return!0},isUnbounded:function(){return!0},registerDocumentInteractionHandler:function(){},registerInteractionHandler:function(){},registerResizeHandler:function(){},removeClass:function(){},updateCssVariable:function(){}}},enumerable:!0,configurable:!0}),MDCRippleFoundation.prototype.init=function(){var e=this,t=this.supportsPressRipple_();if(this.registerRootHandlers_(t),t){var n=MDCRippleFoundation.cssClasses,r=n.ROOT,i=n.UNBOUNDED;requestAnimationFrame((function(){e.adapter_.addClass(r),e.adapter_.isUnbounded()&&(e.adapter_.addClass(i),e.layoutInternal_())}))}},MDCRippleFoundation.prototype.destroy=function(){var e=this;if(this.supportsPressRipple_()){this.activationTimer_&&(clearTimeout(this.activationTimer_),this.activationTimer_=0,this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_ACTIVATION)),this.fgDeactivationRemovalTimer_&&(clearTimeout(this.fgDeactivationRemovalTimer_),this.fgDeactivationRemovalTimer_=0,this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_DEACTIVATION));var t=MDCRippleFoundation.cssClasses,n=t.ROOT,r=t.UNBOUNDED;requestAnimationFrame((function(){e.adapter_.removeClass(n),e.adapter_.removeClass(r),e.removeCssVars_()}))}this.deregisterRootHandlers_(),this.deregisterDeactivationHandlers_()},MDCRippleFoundation.prototype.activate=function(e){this.activate_(e)},MDCRippleFoundation.prototype.deactivate=function(){this.deactivate_()},MDCRippleFoundation.prototype.layout=function(){var e=this;this.layoutFrame_&&cancelAnimationFrame(this.layoutFrame_),this.layoutFrame_=requestAnimationFrame((function(){e.layoutInternal_(),e.layoutFrame_=0}))},MDCRippleFoundation.prototype.setUnbounded=function(e){var t=MDCRippleFoundation.cssClasses.UNBOUNDED;e?this.adapter_.addClass(t):this.adapter_.removeClass(t)},MDCRippleFoundation.prototype.handleFocus=function(){var e=this;requestAnimationFrame((function(){return e.adapter_.addClass(MDCRippleFoundation.cssClasses.BG_FOCUSED)}))},MDCRippleFoundation.prototype.handleBlur=function(){var e=this;requestAnimationFrame((function(){return e.adapter_.removeClass(MDCRippleFoundation.cssClasses.BG_FOCUSED)}))},MDCRippleFoundation.prototype.supportsPressRipple_=function(){return this.adapter_.browserSupportsCssVars()},MDCRippleFoundation.prototype.defaultActivationState_=function(){return{activationEvent:void 0,hasDeactivationUXRun:!1,isActivated:!1,isProgrammatic:!1,wasActivatedByPointer:!1,wasElementMadeActive:!1}},MDCRippleFoundation.prototype.registerRootHandlers_=function(e){var t=this;e&&(c.forEach((function(e){t.adapter_.registerInteractionHandler(e,t.activateHandler_)})),this.adapter_.isUnbounded()&&this.adapter_.registerResizeHandler(this.resizeHandler_)),this.adapter_.registerInteractionHandler("focus",this.focusHandler_),this.adapter_.registerInteractionHandler("blur",this.blurHandler_)},MDCRippleFoundation.prototype.registerDeactivationHandlers_=function(e){var t=this;"keydown"===e.type?this.adapter_.registerInteractionHandler("keyup",this.deactivateHandler_):l.forEach((function(e){t.adapter_.registerDocumentInteractionHandler(e,t.deactivateHandler_)}))},MDCRippleFoundation.prototype.deregisterRootHandlers_=function(){var e=this;c.forEach((function(t){e.adapter_.deregisterInteractionHandler(t,e.activateHandler_)})),this.adapter_.deregisterInteractionHandler("focus",this.focusHandler_),this.adapter_.deregisterInteractionHandler("blur",this.blurHandler_),this.adapter_.isUnbounded()&&this.adapter_.deregisterResizeHandler(this.resizeHandler_)},MDCRippleFoundation.prototype.deregisterDeactivationHandlers_=function(){var e=this;this.adapter_.deregisterInteractionHandler("keyup",this.deactivateHandler_),l.forEach((function(t){e.adapter_.deregisterDocumentInteractionHandler(t,e.deactivateHandler_)}))},MDCRippleFoundation.prototype.removeCssVars_=function(){var e=this,t=MDCRippleFoundation.strings;Object.keys(t).forEach((function(n){0===n.indexOf("VAR_")&&e.adapter_.updateCssVariable(t[n],null)}))},MDCRippleFoundation.prototype.activate_=function(e){var t=this;if(!this.adapter_.isSurfaceDisabled()){var n=this.activationState_;if(!n.isActivated){var r=this.previousActivationEvent_;if(!(r&&void 0!==e&&r.type!==e.type))n.isActivated=!0,n.isProgrammatic=void 0===e,n.activationEvent=e,n.wasActivatedByPointer=!n.isProgrammatic&&(void 0!==e&&("mousedown"===e.type||"touchstart"===e.type||"pointerdown"===e.type)),void 0!==e&&d.length>0&&d.some((function(e){return t.adapter_.containsEventTarget(e)}))?this.resetActivationState_():(void 0!==e&&(d.push(e.target),this.registerDeactivationHandlers_(e)),n.wasElementMadeActive=this.checkElementMadeActive_(e),n.wasElementMadeActive&&this.animateActivation_(),requestAnimationFrame((function(){d=[],n.wasElementMadeActive||void 0===e||" "!==e.key&&32!==e.keyCode||(n.wasElementMadeActive=t.checkElementMadeActive_(e),n.wasElementMadeActive&&t.animateActivation_()),n.wasElementMadeActive||(t.activationState_=t.defaultActivationState_())})))}}},MDCRippleFoundation.prototype.checkElementMadeActive_=function(e){return void 0===e||"keydown"!==e.type||this.adapter_.isSurfaceActive()},MDCRippleFoundation.prototype.animateActivation_=function(){var e=this,t=MDCRippleFoundation.strings,n=t.VAR_FG_TRANSLATE_START,r=t.VAR_FG_TRANSLATE_END,i=MDCRippleFoundation.cssClasses,o=i.FG_DEACTIVATION,a=i.FG_ACTIVATION,u=MDCRippleFoundation.numbers.DEACTIVATION_TIMEOUT_MS;this.layoutInternal_();var s="",c="";if(!this.adapter_.isUnbounded()){var l=this.getFgTranslationCoordinates_(),d=l.startPoint,f=l.endPoint;s=d.x+"px, "+d.y+"px",c=f.x+"px, "+f.y+"px"}this.adapter_.updateCssVariable(n,s),this.adapter_.updateCssVariable(r,c),clearTimeout(this.activationTimer_),clearTimeout(this.fgDeactivationRemovalTimer_),this.rmBoundedActivationClasses_(),this.adapter_.removeClass(o),this.adapter_.computeBoundingRect(),this.adapter_.addClass(a),this.activationTimer_=setTimeout((function(){return e.activationTimerCallback_()}),u)},MDCRippleFoundation.prototype.getFgTranslationCoordinates_=function(){var e,t=this.activationState_,n=t.activationEvent;return{startPoint:e={x:(e=t.wasActivatedByPointer?Object(s.b)(n,this.adapter_.getWindowPageOffset(),this.adapter_.computeBoundingRect()):{x:this.frame_.width/2,y:this.frame_.height/2}).x-this.initialSize_/2,y:e.y-this.initialSize_/2},endPoint:{x:this.frame_.width/2-this.initialSize_/2,y:this.frame_.height/2-this.initialSize_/2}}},MDCRippleFoundation.prototype.runDeactivationUXLogicIfReady_=function(){var e=this,t=MDCRippleFoundation.cssClasses.FG_DEACTIVATION,n=this.activationState_,r=n.hasDeactivationUXRun,i=n.isActivated;(r||!i)&&this.activationAnimationHasEnded_&&(this.rmBoundedActivationClasses_(),this.adapter_.addClass(t),this.fgDeactivationRemovalTimer_=setTimeout((function(){e.adapter_.removeClass(t)}),u.FG_DEACTIVATION_MS))},MDCRippleFoundation.prototype.rmBoundedActivationClasses_=function(){var e=MDCRippleFoundation.cssClasses.FG_ACTIVATION;this.adapter_.removeClass(e),this.activationAnimationHasEnded_=!1,this.adapter_.computeBoundingRect()},MDCRippleFoundation.prototype.resetActivationState_=function(){var e=this;this.previousActivationEvent_=this.activationState_.activationEvent,this.activationState_=this.defaultActivationState_(),setTimeout((function(){return e.previousActivationEvent_=void 0}),MDCRippleFoundation.numbers.TAP_DELAY_MS)},MDCRippleFoundation.prototype.deactivate_=function(){var e=this,t=this.activationState_;if(t.isActivated){var n=r.a({},t);t.isProgrammatic?(requestAnimationFrame((function(){return e.animateDeactivation_(n)})),this.resetActivationState_()):(this.deregisterDeactivationHandlers_(),requestAnimationFrame((function(){e.activationState_.hasDeactivationUXRun=!0,e.animateDeactivation_(n),e.resetActivationState_()})))}},MDCRippleFoundation.prototype.animateDeactivation_=function(e){var t=e.wasActivatedByPointer,n=e.wasElementMadeActive;(t||n)&&this.runDeactivationUXLogicIfReady_()},MDCRippleFoundation.prototype.layoutInternal_=function(){var e=this;this.frame_=this.adapter_.computeBoundingRect();var t=Math.max(this.frame_.height,this.frame_.width);this.maxRadius_=this.adapter_.isUnbounded()?t:Math.sqrt(Math.pow(e.frame_.width,2)+Math.pow(e.frame_.height,2))+MDCRippleFoundation.numbers.PADDING,this.initialSize_=Math.floor(t*MDCRippleFoundation.numbers.INITIAL_ORIGIN_SCALE),this.fgScale_=""+this.maxRadius_/this.initialSize_,this.updateLayoutCssVars_()},MDCRippleFoundation.prototype.updateLayoutCssVars_=function(){var e=MDCRippleFoundation.strings,t=e.VAR_FG_SIZE,n=e.VAR_LEFT,r=e.VAR_TOP,i=e.VAR_FG_SCALE;this.adapter_.updateCssVariable(t,this.initialSize_+"px"),this.adapter_.updateCssVariable(i,this.fgScale_),this.adapter_.isUnbounded()&&(this.unboundedCoords_={left:Math.round(this.frame_.width/2-this.initialSize_/2),top:Math.round(this.frame_.height/2-this.initialSize_/2)},this.adapter_.updateCssVariable(n,this.unboundedCoords_.left+"px"),this.adapter_.updateCssVariable(r,this.unboundedCoords_.top+"px"))},MDCRippleFoundation}(i.a)},function(e,t,n){"use strict";var r,i;function o(e,t){void 0===t&&(t=!1);var n=e.CSS,i=r;if("boolean"==typeof r&&!t)return r;if(!(n&&"function"==typeof n.supports))return!1;var o=n.supports("--css-vars","yes"),a=n.supports("(--css-vars: yes)")&&n.supports("color","#00000000");return i=!(!o&&!a)&&!function(e){var t=e.document,n=t.createElement("div");n.className="mdc-ripple-surface--test-edge-var-bug",t.body.appendChild(n);var r=e.getComputedStyle(n),i=null!==r&&"solid"===r.borderTopStyle;return n.parentNode&&n.parentNode.removeChild(n),i}(e),t||(r=i),i}function a(e,t){if(void 0===e&&(e=window),void 0===t&&(t=!1),void 0===i||t){var n=!1;try{e.document.addEventListener("test",(function(){}),{get passive(){return n=!0}})}catch(e){}i=n}return!!i&&{passive:!0}}function u(e,t,n){if(!e)return{x:0,y:0};var r,i,o=t.x,a=t.y,u=o+n.left,s=a+n.top;if("touchstart"===e.type){var c=e;r=c.changedTouches[0].pageX-u,i=c.changedTouches[0].pageY-s}else{var l=e;r=l.pageX-u,i=l.pageY-s}return{x:r,y:i}}n.d(t,"c",(function(){return o})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return u}))},,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(48);function i(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;if(!t||!Object.keys(t).length)return e;var n=e,i=e.indexOf("?");return-1!==i&&(t=Object.assign(Object(r.parse)(e.substr(i+1)),t),n=n.substr(0,i)),n+"?"+Object(r.stringify)(t)}},,,function(e,t,n){"use strict";var r=n(169),i=n(170),o=n(111);e.exports={formats:o,parse:i,stringify:r}},function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){var r=n(160);e.exports=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(Object(n));"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){r(e,t,n[t])}))}return e}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a}));var r=n(63),i="_googlesitekitDataLayer",o="data-googlesitekit-gtag";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,"]"))){var r=n.createElement("script");r.setAttribute(o,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(i),n.head.appendChild(r),a("js",new Date),a("config",t.trackingID)}}}}).call(this,n(15))},function(e,t,n){"use strict";(function(e){var r=n(36),i=n.n(r);e._googlesitekitAPIFetchData&&(e._googlesitekitAPIFetchData.rootURL&&i.a.use(i.a.createRootURLMiddleware(e._googlesitekitAPIFetchData.rootURL)),e._googlesitekitAPIFetchData.nonceMiddleware&&(i.a.nonceMiddleware=i.a.createNonceMiddleware(),i.a.use(i.a.createNonceMiddleware(e._googlesitekitAPIFetchData.nonceMiddleware)),i.a.use(i.a.mediaUploadMiddleware),i.a.nonceEndpoint=e._googlesitekitAPIFetchData.nonceEndpoint)),t.default=i.a}).call(this,n(15))},function(e,t,n){var r=n(137),i=n(138),o=n(139);e.exports=function(e,t){return r(e)||i(e,t)||o()}},,function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return d})),n.d(t,"c",(function(){return l}));var r=n(91),i=e._googlesitekitBaseData||{},o={isFirstAdmin:i.isFirstAdmin,trackingEnabled:i.trackingEnabled,trackingID:i.trackingID,referenceSiteURL:i.referenceSiteURL,userIDHash:i.userIDHash},a=Object(r.a)(o),u=a.enableTracking,s=a.disableTracking,c=a.isTrackingEnabled,l=a.trackEvent;function d(e){e?u():s()}d(c())}).call(this,n(15))},,,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(19),m=n(14),g=n.n(m),y=n(1),v=n(0),b=function(t){function SourceLink(){return i()(this,SourceLink),s()(this,l()(SourceLink).apply(this,arguments))}return f()(SourceLink,t),a()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,r=t.href,i=t.className,o=t.external;return e.createElement("div",{className:g()("googlesitekit-source-link",i)},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(_.a,{key:"link",href:r,external:o,inherit:!0},n)])}}]),SourceLink}(y.Component);b.propTypes={name:h.a.string,href:h.a.string,className:h.a.string,external:h.a.bool},b.defaultProps={name:"",href:"",className:"",external:!1},t.a=b}).call(this,n(1))},function(e,t,n){"use strict";(function(e){n.d(t,"g",(function(){return d})),n.d(t,"f",(function(){return f})),n.d(t,"c",(function(){return p})),n.d(t,"b",(function(){return m})),n.d(t,"d",(function(){return g})),n.d(t,"e",(function(){return y})),n.d(t,"a",(function(){return v}));var r=n(11),i=n.n(r),o=n(10),a=n(3),u=n(155),s=n(12),c=n(13),l=Object(s.c)("googlesitekit.winCallbacks",{}),d=function(){return Object(s.c)("googlesitekit.WinsNotificationsRequest",[])},f=function(){return Object(s.c)("googlesitekit.ModulesNotificationsRequest",[])};function p(){var t,n,r,o;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if((t=e.googlesitekit.setup).isSiteKitConnected&&(t.isAuthenticated||t.isVerified)){a.next=3;break}return a.abrupt("return",0);case 3:return n=0,a.next=6,i.a.awrap(m());case 6:return(r=a.sent)&&r.total&&(n+=r.total),a.next=10,i.a.awrap(g());case 10:return(o=a.sent)&&o.total&&(n+=o.total),n=Object(s.c)("googlesitekit.TotalNotifications",n),n=Math.max(0,Math.abs(n)),e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),a.abrupt("return",n);case 16:case"end":return a.stop()}}))}var h=function(e){return e?e.length?e.filter((function(e){return!o.c.getCache("notification::dismissed::".concat(e.id))})):e:[]},_=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=o.c.getCache("notification::displayed::".concat(e[0].id));if(t){var n=new Date(t),r=new Date,i=new Date(Date.UTC(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()));if(n.setHours(0,0,0),i.setHours(0,0,0),n.getTime()===i.getTime())return!0;7<=Object(a.i)(n,i)&&o.c.deleteCache("notification::displayed::".concat(e[0].id))}return null===t})),r=null,i=[];return 0<Object.keys(n).length?(r=t(n),i[Object.keys(n)[0]]=r):(r=t(e),i[Object.keys(e)[0]]=r)};function m(){var e,t,n,r;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return e={},t=0,a.next=4,i.a.awrap(f());case 4:return n=a.sent,r=[],n.map((function(e){var t;return i.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:t=new Promise((function(t){var n,r;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return n=e.identifier,a.t0=h,a.next=4,i.a.awrap(o.c.get(o.b,n,"notifications",{},!1));case 4:a.t1=a.sent,r=(0,a.t0)(a.t1),t({identifier:n,notifications:r});case 7:case"end":return a.stop()}}))})),r.push(t);case 2:case"end":return n.stop()}}))})),a.next=9,i.a.awrap(Promise.all(r).then((function(n){n.forEach((function(n){n.notifications.length&&(t+=n.notifications.length,e[n.identifier]=n.notifications)}))})));case 9:return a.abrupt("return",{results:e,total:t});case 10:case"end":return a.stop()}}))}function g(){var e,t,n,r,o;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return e={},t=0,a.next=4,i.a.awrap(d());case 4:return n=a.sent,a.next=7,i.a.awrap(new u.a(n).get());case 7:return r=a.sent,o=[],n.map((function(e){var t;return i.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:t=new Promise((function(t){var n,o,a,u,s;return i.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:n=e.identifier,o=e.callback||Object(c.camelCase)(n),a=null,u=[],e.withData?(s=r[n]||null,a=l[o](s,n)):a=l[o](n),u=h(u=a?[a]:[]),t({identifier:n,notifications:u});case 8:case"end":return i.stop()}}))})),o.push(t);case 2:case"end":return n.stop()}}))})),a.next=12,i.a.awrap(Promise.all(o).then((function(t){t.forEach((function(t){t.notifications.length&&(e[t.identifier]=t.notifications)}))})));case 12:return e=_(e),t=e.length||Object.keys(e).length||0,a.abrupt("return",{results:e,total:t});case 15:case"end":return a.stop()}}))}var y=function(t){var n=Math.abs(t.count)+1;return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}},v=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))},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function a(e){return(a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var s=n(1),c=n(13),l=n(12);var d=function(e,t){return function(n){var r=e(n),i=n.displayName,o=void 0===i?n.name||"Component":i;return r.displayName="".concat(Object(c.upperFirst)(Object(c.camelCase)(t)),"(").concat(o,")"),r}};n.d(t,"a",(function(){return p}));var f=16;function p(e){return d((function(t){var n,i="core/with-filters/"+e;var d=function(d){function FilteredComponentRenderer(){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FilteredComponentRenderer),r=o(this,a(FilteredComponentRenderer).apply(this,arguments)),void 0===n&&(n=Object(l.c)(e,t)),r}var f,p,_;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(FilteredComponentRenderer,d),f=FilteredComponentRenderer,(p=[{key:"componentDidMount",value:function(){FilteredComponentRenderer.instances.push(this),1===FilteredComponentRenderer.instances.length&&(Object(l.a)("hookRemoved",i,h),Object(l.a)("hookAdded",i,h))}},{key:"componentWillUnmount",value:function(){FilteredComponentRenderer.instances=Object(c.without)(FilteredComponentRenderer.instances,this),0===FilteredComponentRenderer.instances.length&&(Object(l.e)("hookRemoved",i),Object(l.e)("hookAdded",i))}},{key:"render",value:function(){return Object(s.createElement)(n,this.props)}}])&&r(f.prototype,p),_&&r(f,_),FilteredComponentRenderer}(s.Component);d.instances=[];var p=Object(c.debounce)((function(){n=Object(l.c)(e,t),d.instances.forEach((function(e){e.forceUpdate()}))}),f);function h(t){t===e&&p()}return d}),"withFilters")}},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(51);function i(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},n.apply(this,arguments)}e.exports=n},,,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(31),h=n(1),_=function(t){function GenericError(){return i()(this,GenericError),s()(this,l()(GenericError).apply(this,arguments))}return f()(GenericError,t),a()(GenericError,[{key:"render",value:function(){return e.createElement(p.a,this.props)}}]),GenericError}(h.Component);t.a=_}).call(this,n(1))},function(e,t,n){"use strict";var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(60),h=n(1),_=function(e){function ModuleSettingsWarning(){return i()(this,ModuleSettingsWarning),s()(this,l()(ModuleSettingsWarning).apply(this,arguments))}return f()(ModuleSettingsWarning,e),a()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(h.Component);t.a=Object(p.a)("googlesitekit.ModuleSettingsWarning")(_)},function(e,t,n){"use strict";n.r(t);var r=/^(?:https?:)?\/\/\S+$/i;function i(e){return r.test(e)}var o=/^(mailto:)?[a-z0-9._%+-]+@[a-z0-9][a-z0-9.-]*\.[a-z]{2,63}$/i;function a(e){return o.test(e)}function u(e){var t=/^([^\s:]+:)/.exec(e);if(t)return t[1]}function s(e){return!!e&&/^[a-z\-.\+]+[0-9]*:$/i.test(e)}function c(e){var t=/^[^\/\s:]+:(?:\/\/)?\/?([^\/\s#?]+)[\/#?]{0,1}\S*$/.exec(e);if(t)return t[1]}function l(e){return!!e&&/^[^\s#?]+$/.test(e)}function d(e){var t=/^[^\/\s:]+:(?:\/\/)?[^\/\s#?]+[\/]([^\s#?]+)[#?]{0,1}\S*$/.exec(e);if(t)return t[1]}function f(e){return!!e&&/^[^\s#?]+$/.test(e)}var p=n(88);function h(e){return!!e&&/^[^\s#?\/]+$/.test(e)}function _(e){var t=/^\S+?(#[^\s\?]*)/.exec(e);if(t)return t[1]}function m(e){return!!e&&/^#[^\s#?\/]*$/.test(e)}var g=n(45),y=n(71);function v(e,t){return void 0!==Object(y.a)(e,t)}var b=n(48);function C(e){for(var t=e.indexOf("?"),n=-1!==t?Object(b.parse)(e.substr(t+1)):{},r=-1!==t?e.substr(0,t):e,i=arguments.length,o=new Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];return o.forEach((function(e){return delete n[e]})),r+"?"+Object(b.stringify)(n)}var E=/^(?:[a-z]+:|#|\?|\.|\/)/i;function O(e){return e?(e=e.trim(),E.test(e)||a(e)?e:"http://"+e):e}function T(e){try{return decodeURI(e)}catch(t){return e}}function S(e){try{return decodeURIComponent(e)}catch(t){return e}}function x(e){var t=e.replace(/^(?:https?:)\/\/(?:www\.)?/,"");return t.match(/^[^\/]+\/$/)?t.replace("/",""):t}n.d(t,"isURL",(function(){return i})),n.d(t,"isEmail",(function(){return a})),n.d(t,"getProtocol",(function(){return u})),n.d(t,"isValidProtocol",(function(){return s})),n.d(t,"getAuthority",(function(){return c})),n.d(t,"isValidAuthority",(function(){return l})),n.d(t,"getPath",(function(){return d})),n.d(t,"isValidPath",(function(){return f})),n.d(t,"getQueryString",(function(){return p.a})),n.d(t,"isValidQueryString",(function(){return h})),n.d(t,"getFragment",(function(){return _})),n.d(t,"isValidFragment",(function(){return m})),n.d(t,"addQueryArgs",(function(){return g.a})),n.d(t,"getQueryArg",(function(){return y.a})),n.d(t,"hasQueryArg",(function(){return v})),n.d(t,"removeQueryArgs",(function(){return C})),n.d(t,"prependHTTP",(function(){return O})),n.d(t,"safeDecodeURI",(function(){return T})),n.d(t,"safeDecodeURIComponent",(function(){return S})),n.d(t,"filterURLForDisplay",(function(){return x}))},function(e,t,n){var r;"undefined"!=typeof self&&self,r=function(e,t,n,r,i){return function(e){var t={};function __webpack_require__(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}return __webpack_require__.m=e,__webpack_require__.c=t,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get: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="",__webpack_require__(__webpack_require__.s=227)}({0:function(t,n){t.exports=e},1:function(e,n){e.exports=t},22:function(e,t){e.exports=n},227:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=n(228),d=u(n(230));t.Input=d.default;var f=u(n(231));t.Icon=f.default;var p=u(n(234));t.HelperText=p.default;var h=u(n(22)),_=u(n(23)),m=u(n(24)),g=l.MDCTextFieldFoundation.cssClasses,y=function(e){function TextField(t){var n,r=e.call(this,t)||this;return r.floatingLabelElement=s.default.createRef(),r.inputComponent_=null,t.children&&s.default.Children.only(t.children)&&(n=t.children.props.id),r.state={classList:new Set,inputId:n,isFocused:!1,dir:"ltr",disabled:!1,labelIsFloated:!1,initialLabelWidth:0,notchedLabelWidth:0,activeLineRipple:!1,lineRippleCenter:0,outlineIsNotched:!1,isValid:!0,foundation:void 0},r}return i(TextField,e),TextField.prototype.componentDidMount=function(){var e=new l.MDCTextFieldFoundation(this.adapter);this.setState({foundation:e}),e.init()},TextField.prototype.componentWillUnmount=function(){this.state.foundation.destroy()},Object.defineProperty(TextField.prototype,"classes",{get:function(){var e,t=this.state,n=t.classList,r=t.disabled,i=t.isFocused,o=t.isValid,a=this.props,u=a.className,s=a.dense,l=a.fullWidth,d=a.textarea,f=a.trailingIcon,p=a.leadingIcon;return c.default(g.ROOT,Array.from(n),u,((e={})[g.DENSE]=s,e[g.DISABLED]=r,e[g.FOCUSED]=i,e[g.INVALID]=!o,e[g.OUTLINED]=this.notchedOutlineAdapter.hasOutline()&&!l,e[g.TEXTAREA]=d,e[g.WITH_LEADING_ICON]=p,e["mdc-text-field--fullwidth"]=l,e["mdc-text-field--with-trailing-icon"]=f,e["mdc-text-field--no-label"]=!this.labelAdapter.hasLabel(),e))},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"otherProps",{get:function(){var e=this.props;return e.children,e.className,e.dense,e.floatingLabelClassName,e.fullWidth,e.helperText,e.label,e.leadingIcon,e.lineRippleClassName,e.notchedOutlineClassName,e.onLeadingIconSelect,e.onTrailingIconSelect,e.outlined,e.textarea,e.trailingIcon,a(e,["children","className","dense","floatingLabelClassName","fullWidth","helperText","label","leadingIcon","lineRippleClassName","notchedOutlineClassName","onLeadingIconSelect","onTrailingIconSelect","outlined","textarea","trailingIcon"])},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"adapter",{get:function(){var e=this,t={addClass:function(t){return e.setState({classList:e.state.classList.add(t)})},removeClass:function(t){var n=e.state.classList;n.delete(t),e.setState({classList:n})},hasClass:function(t){return e.classes.split(" ").includes(t)},registerTextFieldInteractionHandler:function(){},deregisterTextFieldInteractionHandler:function(){},registerValidationAttributeChangeHandler:function(){},deregisterValidationAttributeChangeHandler:function(){}};return Object.assign({},t,this.inputAdapter,this.labelAdapter,this.lineRippleAdapter,this.notchedOutlineAdapter)},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"inputAdapter",{get:function(){var e=this;return{isFocused:function(){return e.state.isFocused},getNativeInput:function(){var t=e.inputComponent_;if(t)return{disabled:t.isDisabled(),value:t.getValue(),maxLength:t.getMaxLength(),type:t.getInputType(),validity:{badInput:!!t.isBadInput(),valid:!!t.isValid()}};throw Error("MDCReactTextField: The input did not render properly")},registerInputInteractionHandler:function(){},deregisterInputInteractionHandler:function(){}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"labelAdapter",{get:function(){var e=this;return{shakeLabel:function(t){var n=e.floatingLabelElement;t&&n&&n.current&&n.current.shake()},floatLabel:function(t){return e.setState({labelIsFloated:t})},hasLabel:function(){return!!e.props.label&&!e.props.fullWidth},getLabelWidth:function(){return e.state.initialLabelWidth}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"lineRippleAdapter",{get:function(){var e=this;return{activateLineRipple:function(){return e.setState({activeLineRipple:!0})},deactivateLineRipple:function(){return e.setState({activeLineRipple:!1})},setLineRippleTransformOrigin:function(t){return e.setState({lineRippleCenter:t})}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"notchedOutlineAdapter",{get:function(){var e=this;return{notchOutline:function(t){return e.setState({outlineIsNotched:!0,notchedLabelWidth:t})},closeOutline:function(){return e.setState({outlineIsNotched:!1})},hasOutline:function(){return!!e.props.outlined||!!e.props.textarea}}},enumerable:!0,configurable:!0}),TextField.prototype.inputProps=function(e){var t=this,n=e.props;return Object.assign({},n,{foundation:this.state.foundation,handleFocusChange:function(e){return t.setState({isFocused:e})},setDisabled:function(e){return t.setState({disabled:e})},setInputId:function(e){return t.setState({inputId:e})},syncInput:function(e){return t.inputComponent_=e},inputType:this.props.textarea?"textarea":"input"})},TextField.prototype.render=function(){var e=this.props,t=e.fullWidth,n=e.helperText,r=e.characterCounter,i=e.onLeadingIconSelect,a=e.onTrailingIconSelect,u=e.leadingIcon,c=e.trailingIcon,l=e.textarea,d=this.state.foundation;return s.default.createElement(s.default.Fragment,null,s.default.createElement("div",o({},this.otherProps,{className:this.classes,onClick:function(){return d.handleTextFieldInteraction()},onKeyDown:function(){return d.handleTextFieldInteraction()},key:"text-field-container"}),u?this.renderIcon(u,i):null,this.renderInput(),this.notchedOutlineAdapter.hasOutline()?this.renderNotchedOutline():s.default.createElement(s.default.Fragment,null,this.labelAdapter.hasLabel()?this.renderLabel():null,l||t?null:this.renderLineRipple()),c?this.renderIcon(c,a):null),n||r?this.renderHelperLine(n,r):null)},TextField.prototype.renderInput=function(){var e=s.default.Children.only(this.props.children),t=this.inputProps(e);return s.default.cloneElement(e,t)},TextField.prototype.renderLabel=function(){var e=this,t=this.props,n=t.label,r=t.floatingLabelClassName,i=this.state.inputId;return s.default.createElement(h.default,{className:r,float:this.state.labelIsFloated,handleWidthChange:function(t){return e.setState({initialLabelWidth:t})},ref:this.floatingLabelElement,htmlFor:i},n)},TextField.prototype.renderLineRipple=function(){var e=this.props.lineRippleClassName,t=this.state,n=t.activeLineRipple,r=t.lineRippleCenter;return s.default.createElement(_.default,{rippleCenter:r,className:e,active:n})},TextField.prototype.renderNotchedOutline=function(){var e=this.props.notchedOutlineClassName,t=this.state,n=t.notchedLabelWidth,r=t.outlineIsNotched;return s.default.createElement(m.default,{className:e,notchWidth:n,notch:r},this.labelAdapter.hasLabel()?this.renderLabel():null)},TextField.prototype.renderHelperLine=function(e,t){return s.default.createElement("div",{className:g.HELPER_LINE},e&&this.renderHelperText(e),t)},TextField.prototype.renderHelperText=function(e){var t=this.state.isValid,n=Object.assign({isValid:t,key:"text-field-helper-text"},e.props);return s.default.cloneElement(e,n)},TextField.prototype.renderIcon=function(e,t){var n=this.state.disabled;return s.default.createElement(f.default,{disabled:n,onSelect:t},e)},TextField.defaultProps={className:"",dense:!1,floatingLabelClassName:"",fullWidth:!1,lineRippleClassName:"",notchedOutlineClassName:"",outlined:!1,textarea:!1},TextField}(s.default.Component);t.default=y},228:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCTextFieldFoundation",(function(){return s}));var r=n(28),i=n(29),o=n(229),a=["mousedown","touchstart"],u=["click","keydown"],s=function(e){function MDCTextFieldFoundation(t,n){void 0===n&&(n={});var i=e.call(this,r.a({},MDCTextFieldFoundation.defaultAdapter,t))||this;return i.isFocused_=!1,i.receivedUserInput_=!1,i.isValid_=!0,i.useNativeValidation_=!0,i.helperText_=n.helperText,i.characterCounter_=n.characterCounter,i.leadingIcon_=n.leadingIcon,i.trailingIcon_=n.trailingIcon,i.inputFocusHandler_=function(){return i.activateFocus()},i.inputBlurHandler_=function(){return i.deactivateFocus()},i.inputInputHandler_=function(){return i.handleInput()},i.setPointerXOffset_=function(e){return i.setTransformOrigin(e)},i.textFieldInteractionHandler_=function(){return i.handleTextFieldInteraction()},i.validationAttributeChangeHandler_=function(e){return i.handleValidationAttributeChange(e)},i}return r.b(MDCTextFieldFoundation,e),Object.defineProperty(MDCTextFieldFoundation,"cssClasses",{get:function(){return o.c},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation,"strings",{get:function(){return o.e},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation,"numbers",{get:function(){return o.d},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation.prototype,"shouldAlwaysFloat_",{get:function(){var e=this.getNativeInput_().type;return o.a.indexOf(e)>=0},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation.prototype,"shouldFloat",{get:function(){return this.shouldAlwaysFloat_||this.isFocused_||Boolean(this.getValue())||this.isBadInput_()},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation.prototype,"shouldShake",{get:function(){return!this.isFocused_&&!this.isValid()&&Boolean(this.getValue())},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!0},registerTextFieldInteractionHandler:function(){},deregisterTextFieldInteractionHandler:function(){},registerInputInteractionHandler:function(){},deregisterInputInteractionHandler:function(){},registerValidationAttributeChangeHandler:function(){return new MutationObserver((function(){}))},deregisterValidationAttributeChangeHandler:function(){},getNativeInput:function(){return null},isFocused:function(){return!1},activateLineRipple:function(){},deactivateLineRipple:function(){},setLineRippleTransformOrigin:function(){},shakeLabel:function(){},floatLabel:function(){},hasLabel:function(){return!1},getLabelWidth:function(){return 0},hasOutline:function(){return!1},notchOutline:function(){},closeOutline:function(){}}},enumerable:!0,configurable:!0}),MDCTextFieldFoundation.prototype.init=function(){var e=this;this.adapter_.isFocused()?this.inputFocusHandler_():this.adapter_.hasLabel()&&this.shouldFloat&&(this.notchOutline(!0),this.adapter_.floatLabel(!0)),this.adapter_.registerInputInteractionHandler("focus",this.inputFocusHandler_),this.adapter_.registerInputInteractionHandler("blur",this.inputBlurHandler_),this.adapter_.registerInputInteractionHandler("input",this.inputInputHandler_),a.forEach((function(t){e.adapter_.registerInputInteractionHandler(t,e.setPointerXOffset_)})),u.forEach((function(t){e.adapter_.registerTextFieldInteractionHandler(t,e.textFieldInteractionHandler_)})),this.validationObserver_=this.adapter_.registerValidationAttributeChangeHandler(this.validationAttributeChangeHandler_),this.setCharacterCounter_(this.getValue().length)},MDCTextFieldFoundation.prototype.destroy=function(){var e=this;this.adapter_.deregisterInputInteractionHandler("focus",this.inputFocusHandler_),this.adapter_.deregisterInputInteractionHandler("blur",this.inputBlurHandler_),this.adapter_.deregisterInputInteractionHandler("input",this.inputInputHandler_),a.forEach((function(t){e.adapter_.deregisterInputInteractionHandler(t,e.setPointerXOffset_)})),u.forEach((function(t){e.adapter_.deregisterTextFieldInteractionHandler(t,e.textFieldInteractionHandler_)})),this.adapter_.deregisterValidationAttributeChangeHandler(this.validationObserver_)},MDCTextFieldFoundation.prototype.handleTextFieldInteraction=function(){var e=this.adapter_.getNativeInput();e&&e.disabled||(this.receivedUserInput_=!0)},MDCTextFieldFoundation.prototype.handleValidationAttributeChange=function(e){var t=this;e.some((function(e){return o.b.indexOf(e)>-1&&(t.styleValidity_(!0),!0)})),e.indexOf("maxlength")>-1&&this.setCharacterCounter_(this.getValue().length)},MDCTextFieldFoundation.prototype.notchOutline=function(e){if(this.adapter_.hasOutline())if(e){var t=this.adapter_.hasClass(o.c.DENSE)?o.d.DENSE_LABEL_SCALE:o.d.LABEL_SCALE,n=this.adapter_.getLabelWidth()*t;this.adapter_.notchOutline(n)}else this.adapter_.closeOutline()},MDCTextFieldFoundation.prototype.activateFocus=function(){this.isFocused_=!0,this.styleFocused_(this.isFocused_),this.adapter_.activateLineRipple(),this.adapter_.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter_.floatLabel(this.shouldFloat),this.adapter_.shakeLabel(this.shouldShake)),this.helperText_&&this.helperText_.showToScreenReader()},MDCTextFieldFoundation.prototype.setTransformOrigin=function(e){var t=e.touches,n=t?t[0]:e,r=n.target.getBoundingClientRect(),i=n.clientX-r.left;this.adapter_.setLineRippleTransformOrigin(i)},MDCTextFieldFoundation.prototype.handleInput=function(){this.autoCompleteFocus(),this.setCharacterCounter_(this.getValue().length)},MDCTextFieldFoundation.prototype.autoCompleteFocus=function(){this.receivedUserInput_||this.activateFocus()},MDCTextFieldFoundation.prototype.deactivateFocus=function(){this.isFocused_=!1,this.adapter_.deactivateLineRipple();var e=this.isValid();this.styleValidity_(e),this.styleFocused_(this.isFocused_),this.adapter_.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter_.floatLabel(this.shouldFloat),this.adapter_.shakeLabel(this.shouldShake)),this.shouldFloat||(this.receivedUserInput_=!1)},MDCTextFieldFoundation.prototype.getValue=function(){return this.getNativeInput_().value},MDCTextFieldFoundation.prototype.setValue=function(e){this.getValue()!==e&&(this.getNativeInput_().value=e,this.setCharacterCounter_(e.length));var t=this.isValid();this.styleValidity_(t),this.adapter_.hasLabel()&&(this.notchOutline(this.shouldFloat),this.adapter_.floatLabel(this.shouldFloat),this.adapter_.shakeLabel(this.shouldShake))},MDCTextFieldFoundation.prototype.isValid=function(){return this.useNativeValidation_?this.isNativeInputValid_():this.isValid_},MDCTextFieldFoundation.prototype.setValid=function(e){this.isValid_=e,this.styleValidity_(e);var t=!e&&!this.isFocused_;this.adapter_.hasLabel()&&this.adapter_.shakeLabel(t)},MDCTextFieldFoundation.prototype.setUseNativeValidation=function(e){this.useNativeValidation_=e},MDCTextFieldFoundation.prototype.isDisabled=function(){return this.getNativeInput_().disabled},MDCTextFieldFoundation.prototype.setDisabled=function(e){this.getNativeInput_().disabled=e,this.styleDisabled_(e)},MDCTextFieldFoundation.prototype.setHelperTextContent=function(e){this.helperText_&&this.helperText_.setContent(e)},MDCTextFieldFoundation.prototype.setLeadingIconAriaLabel=function(e){this.leadingIcon_&&this.leadingIcon_.setAriaLabel(e)},MDCTextFieldFoundation.prototype.setLeadingIconContent=function(e){this.leadingIcon_&&this.leadingIcon_.setContent(e)},MDCTextFieldFoundation.prototype.setTrailingIconAriaLabel=function(e){this.trailingIcon_&&this.trailingIcon_.setAriaLabel(e)},MDCTextFieldFoundation.prototype.setTrailingIconContent=function(e){this.trailingIcon_&&this.trailingIcon_.setContent(e)},MDCTextFieldFoundation.prototype.setCharacterCounter_=function(e){if(this.characterCounter_){var t=this.getNativeInput_().maxLength;if(-1===t)throw new Error("MDCTextFieldFoundation: Expected maxlength html property on text input or textarea.");this.characterCounter_.setCounterValue(e,t)}},MDCTextFieldFoundation.prototype.isBadInput_=function(){return this.getNativeInput_().validity.badInput||!1},MDCTextFieldFoundation.prototype.isNativeInputValid_=function(){return this.getNativeInput_().validity.valid},MDCTextFieldFoundation.prototype.styleValidity_=function(e){var t=MDCTextFieldFoundation.cssClasses.INVALID;e?this.adapter_.removeClass(t):this.adapter_.addClass(t),this.helperText_&&this.helperText_.setValidity(e)},MDCTextFieldFoundation.prototype.styleFocused_=function(e){var t=MDCTextFieldFoundation.cssClasses.FOCUSED;e?this.adapter_.addClass(t):this.adapter_.removeClass(t)},MDCTextFieldFoundation.prototype.styleDisabled_=function(e){var t=MDCTextFieldFoundation.cssClasses,n=t.DISABLED,r=t.INVALID;e?(this.adapter_.addClass(n),this.adapter_.removeClass(r)):this.adapter_.removeClass(n),this.leadingIcon_&&this.leadingIcon_.setDisabled(e),this.trailingIcon_&&this.trailingIcon_.setDisabled(e)},MDCTextFieldFoundation.prototype.getNativeInput_=function(){return(this.adapter_?this.adapter_.getNativeInput():null)||{disabled:!1,maxLength:-1,type:"input",validity:{badInput:!1,valid:!0},value:""}},MDCTextFieldFoundation}(i.a);t.default=s},229:function(e,t,n){"use strict";n.d(t,"c",(function(){return i})),n.d(t,"e",(function(){return r})),n.d(t,"d",(function(){return o})),n.d(t,"b",(function(){return a})),n.d(t,"a",(function(){return u}));var r={ARIA_CONTROLS:"aria-controls",ICON_SELECTOR:".mdc-text-field__icon",INPUT_SELECTOR:".mdc-text-field__input",LABEL_SELECTOR:".mdc-floating-label",LINE_RIPPLE_SELECTOR:".mdc-line-ripple",OUTLINE_SELECTOR:".mdc-notched-outline"},i={DENSE:"mdc-text-field--dense",DISABLED:"mdc-text-field--disabled",FOCUSED:"mdc-text-field--focused",HELPER_LINE:"mdc-text-field-helper-line",INVALID:"mdc-text-field--invalid",OUTLINED:"mdc-text-field--outlined",ROOT:"mdc-text-field",TEXTAREA:"mdc-text-field--textarea",WITH_LEADING_ICON:"mdc-text-field--with-leading-icon"},o={DENSE_LABEL_SCALE:.923,LABEL_SCALE:.75},a=["pattern","min","max","required","step","minlength","maxlength"],u=["color","date","datetime-local","month","range","time","week"]},23:function(e,t){e.exports=r},230:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=["pattern","min","max","required","step","minlength","maxlength"],d=function(e){function Input(){var t=null!==e&&e.apply(this,arguments)||this;return t.inputElement_=s.default.createRef(),t.state={wasUserTriggeredChange:!1},t.handleFocus=function(e){var n=t.props,r=n.foundation,i=n.handleFocusChange,o=n.onFocus,a=void 0===o?function(){}:o;r&&r.activateFocus(),i&&i(!0),a(e)},t.handleBlur=function(e){var n=t.props,r=n.foundation,i=n.handleFocusChange,o=n.onBlur,a=void 0===o?function(){}:o;r&&r.deactivateFocus(),i&&i(!1),a(e)},t.handleMouseDown=function(e){var n=t.props,r=n.foundation,i=n.onMouseDown,o=void 0===i?function(){}:i;r&&r.setTransformOrigin(e.nativeEvent),o(e)},t.handleTouchStart=function(e){var n=t.props,r=n.foundation,i=n.onTouchStart,o=void 0===i?function(){}:i;r&&r.setTransformOrigin(e.nativeEvent),o(e)},t.handleChange=function(e){var n=t.props,r=n.foundation,i=n.onChange,o=void 0===i?function(){}:i;r&&r.autoCompleteFocus(),t.setState({wasUserTriggeredChange:!0}),o(e)},t.handleValidationAttributeUpdate=function(e){var n=e.foundation;l.some((function(r){var i;return i="minlength"===r?"minLength":"maxlength"===r?"maxLength":r,t.props[i]!==e[i]&&(n.handleValidationAttributeChange([r]),!0)}))},t.isBadInput=function(){var e=t.inputElement;return e&&e.validity.badInput},t.isValid=function(){return t.inputElement&&void 0===t.props.isValid?t.inputElement.validity.valid:t.props.isValid},t.isDisabled=function(){return!!t.props.disabled},t.getMaxLength=function(){return"number"==typeof t.props.maxLength?t.props.maxLength:-1},t.getInputType=function(){return String(t.props.inputType)},t.getValue=function(){return t.valueToString(t.props.value)},t}return i(Input,e),Input.prototype.componentDidMount=function(){var e=this,t=this.props,n=t.id,r=t.syncInput,i=t.disabled,o=t.value,a=t.setInputId,u=t.setDisabled,s=t.handleValueChange,c=t.foundation,l=t.isValid;r&&r(this),a&&n&&a(n),u&&i&&u(!0),s&&o&&s(o,(function(){return c&&c.setValue(e.valueToString(o))})),c&&void 0!==l&&(c.setUseNativeValidation(!1),c.setValid(!!l))},Input.prototype.componentDidUpdate=function(e){var t=this,n=this.props,r=n.id,i=n.foundation,o=n.value,a=n.disabled,u=n.isValid,s=n.handleValueChange,c=n.setInputId,l=n.setDisabled;this.handleValidationAttributeUpdate(e),a!==e.disabled&&(l&&l(a),i&&i.setDisabled(!!a)),r!==e.id&&c&&c(r),o!==e.value&&s&&s(o,(function(){t.state.wasUserTriggeredChange?t.setState({wasUserTriggeredChange:!1}):i&&i.setValue(t.valueToString(o))})),u!==e.isValid&&i&&(void 0===u?i.setUseNativeValidation(!0):(i.setUseNativeValidation(!1),i.setValid(!!u)))},Input.prototype.valueToString=function(e){return"object"==typeof e?e.join(""):"number"==typeof e?e.toString():e||""},Object.defineProperty(Input.prototype,"classes",{get:function(){return c.default("mdc-text-field__input",this.props.className)},enumerable:!0,configurable:!0}),Object.defineProperty(Input.prototype,"inputElement",{get:function(){return this.inputElement_.current},enumerable:!0,configurable:!0}),Input.prototype.render=function(){var e=this.props,t=e.inputType,n=e.disabled,r=(e.className,e.foundation,e.syncInput,e.isValid,e.value),i=(e.handleFocusChange,e.handleValueChange,e.setDisabled,e.setInputId,e.onFocus,e.onBlur,e.onMouseDown,e.onTouchStart,e.onChange,a(e,["inputType","disabled","className","foundation","syncInput","isValid","value","handleFocusChange","handleValueChange","setDisabled","setInputId","onFocus","onBlur","onMouseDown","onTouchStart","onChange"])),u=Object.assign({},{onFocus:this.handleFocus,onBlur:this.handleBlur,onMouseDown:this.handleMouseDown,onTouchStart:this.handleTouchStart,onChange:this.handleChange,disabled:n,value:r,ref:this.inputElement_,className:this.classes},i);return"input"===t?s.default.createElement("input",o({},u)):s.default.createElement("textarea",o({},u))},Input.defaultProps={className:"",inputType:"input",disabled:!1,id:"",handleValueChange:function(){},setDisabled:function(){},setInputId:function(){},handleFocusChange:function(){},value:""},Input}(s.default.Component);t.default=d},231:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var u=a(n(0)),s=a(n(1)),c=n(232),l=function(e){function Icon(t){var n=e.call(this,t)||this;n.handleClick=function(e){return n.foundation.handleInteraction(e.nativeEvent)},n.handleKeyDown=function(e){return n.foundation.handleInteraction(e.nativeEvent)},n.addIconAttrsToChildren=function(){var e=n.state,t=e.tabindex,r=e.role,i=u.default.Children.only(n.props.children),o=s.default("mdc-text-field__icon",i.props.className),a=Object.assign({},i.props,{className:o,onClick:n.handleClick,onKeyDown:n.handleKeyDown,tabIndex:t,role:r});return u.default.cloneElement(i,a)};var r=t.children.props.role;return n.state={tabindex:n.tabindex,role:r},n}return i(Icon,e),Icon.prototype.componentDidMount=function(){this.foundation=new c.MDCTextFieldIconFoundation(this.adapter),this.foundation.init(),this.props.disabled&&this.foundation.setDisabled(!0)},Icon.prototype.componentDidUpdate=function(e){this.props.disabled!==e.disabled&&this.foundation.setDisabled(!!this.props.disabled),this.props.onSelect!==e.onSelect&&this.setState({tabindex:this.tabindex})},Icon.prototype.componentWillUnmount=function(){this.foundation.destroy()},Object.defineProperty(Icon.prototype,"tabindex",{get:function(){return"number"==typeof this.props.children.props.tabIndex?this.props.children.props.tabIndex:this.props.onSelect?0:-1},enumerable:!0,configurable:!0}),Object.defineProperty(Icon.prototype,"adapter",{get:function(){var e=this;return{getAttr:function(t){var n=e.state[t];return n||"number"==typeof n&&!isNaN(n)?n.toString():""},setAttr:function(t,n){return e.setState((function(e){var r;return o({},e,((r={})[t]="tabindex"===t?Number(n):n,r))}))},removeAttr:function(t){return e.setState((function(e){var n;return o({},e,((n={})[t]=null,n))}))},notifyIconAction:function(){return e.props.onSelect&&e.props.onSelect()},setContent:function(){},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){}}},enumerable:!0,configurable:!0}),Icon.prototype.render=function(){return this.addIconAttrsToChildren()},Icon.defaultProps={disabled:!1},Icon}(u.default.Component);t.default=l},232:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCTextFieldIconFoundation",(function(){return u}));var r=n(28),i=n(29),o=n(233),a=["click","keydown"],u=function(e){function MDCTextFieldIconFoundation(t){var n=e.call(this,r.a({},MDCTextFieldIconFoundation.defaultAdapter,t))||this;return n.savedTabIndex_=null,n.interactionHandler_=function(e){return n.handleInteraction(e)},n}return r.b(MDCTextFieldIconFoundation,e),Object.defineProperty(MDCTextFieldIconFoundation,"strings",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldIconFoundation,"defaultAdapter",{get:function(){return{getAttr:function(){return null},setAttr:function(){},removeAttr:function(){},setContent:function(){},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){},notifyIconAction:function(){}}},enumerable:!0,configurable:!0}),MDCTextFieldIconFoundation.prototype.init=function(){var e=this;this.savedTabIndex_=this.adapter_.getAttr("tabindex"),a.forEach((function(t){e.adapter_.registerInteractionHandler(t,e.interactionHandler_)}))},MDCTextFieldIconFoundation.prototype.destroy=function(){var e=this;a.forEach((function(t){e.adapter_.deregisterInteractionHandler(t,e.interactionHandler_)}))},MDCTextFieldIconFoundation.prototype.setDisabled=function(e){this.savedTabIndex_&&(e?(this.adapter_.setAttr("tabindex","-1"),this.adapter_.removeAttr("role")):(this.adapter_.setAttr("tabindex",this.savedTabIndex_),this.adapter_.setAttr("role",o.a.ICON_ROLE)))},MDCTextFieldIconFoundation.prototype.setAriaLabel=function(e){this.adapter_.setAttr("aria-label",e)},MDCTextFieldIconFoundation.prototype.setContent=function(e){this.adapter_.setContent(e)},MDCTextFieldIconFoundation.prototype.handleInteraction=function(e){var t="Enter"===e.key||13===e.keyCode;("click"===e.type||t)&&this.adapter_.notifyIconAction()},MDCTextFieldIconFoundation}(i.a);t.default=u},233:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r={ICON_EVENT:"MDCTextField:icon",ICON_ROLE:"button"}},234:function(e,t,n){"use strict";var r,i,o=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),a=this&&this.__assign||function(){return(a=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=n(235),d=l.MDCTextFieldHelperTextFoundation.cssClasses,f=function(e){function HelperText(t){var n,r=e.call(this,t)||this;return r.state=((n={})["aria-hidden"]=t["aria-hidden"],n.role=t.role,n.classList=new Set,n),r}return o(HelperText,e),HelperText.prototype.componentDidMount=function(){this.foundation=new l.MDCTextFieldHelperTextFoundation(this.adapter),this.foundation.init(),this.props.showToScreenReader&&this.foundation.showToScreenReader(),this.props.isValid||this.foundation.setValidity(!1),this.props.isValidationMessage&&this.foundation.setValidation(!0)},HelperText.prototype.componentDidUpdate=function(e){this.props.showToScreenReader!==e.showToScreenReader&&this.props.showToScreenReader&&this.foundation.showToScreenReader(),this.props.isValid!==e.isValid&&this.foundation.setValidity(!!this.props.isValid),this.props.isValidationMessage!==e.isValidationMessage&&this.props.isValidationMessage&&this.foundation.setValidation(this.props.isValidationMessage)},HelperText.prototype.componentWillUnmount=function(){this.foundation.destroy()},Object.defineProperty(HelperText.prototype,"classes",{get:function(){var e,t=this.props,n=t.className,r=t.persistent,i=t.validation;return c.default(d.ROOT,n,((e={})[d.HELPER_TEXT_PERSISTENT]=r,e[d.HELPER_TEXT_VALIDATION_MSG]=i,e))},enumerable:!0,configurable:!0}),Object.defineProperty(HelperText.prototype,"adapter",{get:function(){var e=this;return{addClass:function(t){return e.setState({classList:e.state.classList.add(t)})},removeClass:function(t){var n=e.state.classList;n.delete(t),e.setState({classList:n})},hasClass:function(t){return e.classes.split(" ").includes(t)},setAttr:function(t,n){return e.setState((function(e){var r;return a({},e,((r={})[t]=n,r))}))},removeAttr:function(t){return e.setState((function(e){var n;return a({},e,((n={})[t]=null,n))}))},setContent:function(){}}},enumerable:!0,configurable:!0}),HelperText.prototype.render=function(){return s.default.createElement("p",{className:this.classes,role:this.state.role,"aria-hidden":this.state["aria-hidden"]},this.props.children)},HelperText.defaultProps=((i={})["aria-hidden"]=!1,i.className="",i.isValid=!0,i.isValidationMessage=!1,i.persistent=!1,i.showToScreenReader=!1,i.validation=!1,i),HelperText}(s.default.Component);t.default=f},235:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCTextFieldHelperTextFoundation",(function(){return a}));var r=n(28),i=n(29),o=n(236),a=function(e){function MDCTextFieldHelperTextFoundation(t){return e.call(this,r.a({},MDCTextFieldHelperTextFoundation.defaultAdapter,t))||this}return r.b(MDCTextFieldHelperTextFoundation,e),Object.defineProperty(MDCTextFieldHelperTextFoundation,"cssClasses",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldHelperTextFoundation,"strings",{get:function(){return o.b},enumerable:!0,configurable:!0}),Object.defineProperty(MDCTextFieldHelperTextFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},setAttr:function(){},removeAttr:function(){},setContent:function(){}}},enumerable:!0,configurable:!0}),MDCTextFieldHelperTextFoundation.prototype.setContent=function(e){this.adapter_.setContent(e)},MDCTextFieldHelperTextFoundation.prototype.setPersistent=function(e){e?this.adapter_.addClass(o.a.HELPER_TEXT_PERSISTENT):this.adapter_.removeClass(o.a.HELPER_TEXT_PERSISTENT)},MDCTextFieldHelperTextFoundation.prototype.setValidation=function(e){e?this.adapter_.addClass(o.a.HELPER_TEXT_VALIDATION_MSG):this.adapter_.removeClass(o.a.HELPER_TEXT_VALIDATION_MSG)},MDCTextFieldHelperTextFoundation.prototype.showToScreenReader=function(){this.adapter_.removeAttr(o.b.ARIA_HIDDEN)},MDCTextFieldHelperTextFoundation.prototype.setValidity=function(e){var t=this.adapter_.hasClass(o.a.HELPER_TEXT_PERSISTENT),n=this.adapter_.hasClass(o.a.HELPER_TEXT_VALIDATION_MSG)&&!e;n?this.adapter_.setAttr(o.b.ROLE,"alert"):this.adapter_.removeAttr(o.b.ROLE),t||n||this.hide_()},MDCTextFieldHelperTextFoundation.prototype.hide_=function(){this.adapter_.setAttr(o.b.ARIA_HIDDEN,"true")},MDCTextFieldHelperTextFoundation}(i.a);t.default=a},236:function(e,t,n){"use strict";n.d(t,"b",(function(){return i})),n.d(t,"a",(function(){return r}));var r={HELPER_TEXT_PERSISTENT:"mdc-text-field-helper-text--persistent",HELPER_TEXT_VALIDATION_MSG:"mdc-text-field-helper-text--validation-msg",ROOT:"mdc-text-field-helper-text"},i={ARIA_HIDDEN:"aria-hidden",ROLE:"role",ROOT_SELECTOR:"."+r.ROOT}},24:function(e,t){e.exports=i},28:function(e,t,n){"use strict";t.b=function __extends(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)},n.d(t,"a",(function(){return i})),"function"==typeof Symbol&&Symbol.iterator;var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},i=function __assign(){return(i=Object.assign||function __assign(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)}},29:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(){function MDCFoundation(e){void 0===e&&(e={}),this.adapter_=e}return Object.defineProperty(MDCFoundation,"cssClasses",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"strings",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"numbers",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"defaultAdapter",{get:function(){return{}},enumerable:!0,configurable:!0}),MDCFoundation.prototype.init=function(){},MDCFoundation.prototype.destroy=function(){},MDCFoundation}()}})},e.exports=r(n(1),n(14),n(114),n(115),n(116))},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(48);function i(e,t){var n=e.indexOf("?");return(-1!==n?Object(r.parse)(e.substr(n+1)):{})[t]}},function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(128),i=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return{__html:r.a.sanitize(e,t)}}},function(e,t,n){"use strict";(function(e){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(1))},,function(e,t,n){!function(){"use strict";var e={not_string:/[^s]/,not_bool:/[^t]/,not_type:/[^T]/,not_primitive:/[^v]/,number:/[diefg]/,numeric_arg:/[bcdiefguxX]/,json:/[j]/,not_json:/[^j]/,text:/^[^\x25]+/,modulo:/^\x25{2}/,placeholder:/^\x25(?:([1-9]\d*)\$|\(([^)]+)\))?(\+)?(0|'[^$])?(-)?(\d+)?(?:\.(\d+))?([b-gijostTuvxX])/,key:/^([a-z_][a-z_\d]*)/i,key_access:/^\.([a-z_][a-z_\d]*)/i,index_access:/^\[(\d+)\]/,sign:/^[+-]/};function sprintf(t){return function sprintf_format(t,n){var r,i,o,a,u,s,c,l,d,f=1,p=t.length,h="";for(i=0;i<p;i++)if("string"==typeof t[i])h+=t[i];else if("object"==typeof t[i]){if((a=t[i]).keys)for(r=n[f],o=0;o<a.keys.length;o++){if(null==r)throw new Error(sprintf('[sprintf] Cannot access property "%s" of undefined value "%s"',a.keys[o],a.keys[o-1]));r=r[a.keys[o]]}else r=a.param_no?n[a.param_no]:n[f++];if(e.not_type.test(a.type)&&e.not_primitive.test(a.type)&&r instanceof Function&&(r=r()),e.numeric_arg.test(a.type)&&"number"!=typeof r&&isNaN(r))throw new TypeError(sprintf("[sprintf] expecting number but found %T",r));switch(e.number.test(a.type)&&(l=r>=0),a.type){case"b":r=parseInt(r,10).toString(2);break;case"c":r=String.fromCharCode(parseInt(r,10));break;case"d":case"i":r=parseInt(r,10);break;case"j":r=JSON.stringify(r,null,a.width?parseInt(a.width):0);break;case"e":r=a.precision?parseFloat(r).toExponential(a.precision):parseFloat(r).toExponential();break;case"f":r=a.precision?parseFloat(r).toFixed(a.precision):parseFloat(r);break;case"g":r=a.precision?String(Number(r.toPrecision(a.precision))):parseFloat(r);break;case"o":r=(parseInt(r,10)>>>0).toString(8);break;case"s":r=String(r),r=a.precision?r.substring(0,a.precision):r;break;case"t":r=String(!!r),r=a.precision?r.substring(0,a.precision):r;break;case"T":r=Object.prototype.toString.call(r).slice(8,-1).toLowerCase(),r=a.precision?r.substring(0,a.precision):r;break;case"u":r=parseInt(r,10)>>>0;break;case"v":r=r.valueOf(),r=a.precision?r.substring(0,a.precision):r;break;case"x":r=(parseInt(r,10)>>>0).toString(16);break;case"X":r=(parseInt(r,10)>>>0).toString(16).toUpperCase()}e.json.test(a.type)?h+=r:(!e.number.test(a.type)||l&&!a.sign?d="":(d=l?"+":"-",r=r.toString().replace(e.sign,"")),s=a.pad_char?"0"===a.pad_char?"0":a.pad_char.charAt(1):" ",c=a.width-(d+r).length,u=a.width&&c>0?s.repeat(c):"",h+=a.align?d+r+u:"0"===s?d+u+r:u+d+r)}return h}(function sprintf_parse(t){if(n[t])return n[t];var r,i=t,o=[],a=0;for(;i;){if(null!==(r=e.text.exec(i)))o.push(r[0]);else if(null!==(r=e.modulo.exec(i)))o.push("%");else{if(null===(r=e.placeholder.exec(i)))throw new SyntaxError("[sprintf] unexpected placeholder");if(r[2]){a|=1;var u=[],s=r[2],c=[];if(null===(c=e.key.exec(s)))throw new SyntaxError("[sprintf] failed to parse named argument key");for(u.push(c[1]);""!==(s=s.substring(c[0].length));)if(null!==(c=e.key_access.exec(s)))u.push(c[1]);else{if(null===(c=e.index_access.exec(s)))throw new SyntaxError("[sprintf] failed to parse named argument key");u.push(c[1])}r[2]=u}else a|=2;if(3===a)throw new Error("[sprintf] mixing positional and named placeholders is not (yet) supported");o.push({placeholder:r[0],param_no:r[1],keys:r[2],sign:r[3],pad_char:r[4],align:r[5],width:r[6],precision:r[7],type:r[8]})}i=i.substring(r[0].length)}return n[t]=o}(t),arguments)}function vsprintf(e,t){return sprintf.apply(null,[e].concat(t||[]))}var n=Object.create(null);t.sprintf=sprintf,t.vsprintf=vsprintf,"undefined"!=typeof window&&(window.sprintf=sprintf,window.vsprintf=vsprintf,"function"==typeof define&&define.amd&&define((function(){return{sprintf:sprintf,vsprintf:vsprintf}})))}()},,,,function(e,t,n){"use strict";!function e(){if("undefined"!=typeof __REACT_DEVTOOLS_GLOBAL_HOOK__&&"function"==typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE){0;try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(e){console.error(e)}}}(),e.exports=n(183)},function(e,t,n){"use strict";(function(e,r){var i=n(31),o=n(0);t.a=function DashboardAuthAlert(){var t=e.googlesitekit.admin.connectURL;return r.createElement(i.a,{id:"authentication error",title:Object(o.__)("Issue accessing data","google-site-kit"),description:Object(o.__)("You need to reauthenticate your Google account.","google-site-kit"),handleDismiss:function(){},format:"small",type:"win-error",isDismissable:!0,ctaLink:t,ctaLabel:Object(o.__)("Click here","google-site-kit")})}}).call(this,n(15),n(1))},,,,function(e,t,n){"use strict";(function(e){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(1))},function(e,t,n){e.exports=function(e,t){var n,r,i,o=0;function a(){var t,a,u=r,s=arguments.length;e:for(;u;){if(u.args.length===arguments.length){for(a=0;a<s;a++)if(u.args[a]!==arguments[a]){u=u.next;continue e}return u!==r&&(u===i&&(i=u.prev),u.prev.next=u.next,u.next&&(u.next.prev=u.prev),u.next=r,u.prev=null,r.prev=u,r=u),u.val}u=u.next}for(t=new Array(s),a=0;a<s;a++)t[a]=arguments[a];return u={args:t,val:e.apply(null,t)},r?(r.prev=u,u.next=r):i=u,o===n?(i=i.prev).next=null:o++,r=u,u.val}return t&&t.maxSize&&(n=t.maxSize),a.clear=function(){r=null,i=null,o=0},a}},function(e,t,n){var r;"undefined"!=typeof self&&self,r=function(e,t,n,r,i,o){return function(e){var t={};function __webpack_require__(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}return __webpack_require__.m=e,__webpack_require__.c=t,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get: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="",__webpack_require__(__webpack_require__.s=174)}({0:function(t,n){t.exports=e},1:function(e,n){e.exports=t},174:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=n(48),d=u(n(22)),f=u(n(23)),p=u(n(24)),h=n(176),_=u(n(181));t.Option=_.default;var m=l.MDCSelectFoundation.cssClasses,g=function(e){function Select(t){var n=e.call(this,t)||this;return n.nativeControl=s.default.createRef(),n.classesBeingRemoved=new Set,n.classesBeingAdded=new Set,n.createFoundation=function(e){var t=new l.MDCSelectFoundation(n.adapter,n.foundationMap);t.init(),n.setState({foundation:t},e)},n.destroyFoundation=function(){n.state.foundation&&n.state.foundation.destroy()},n.addClass=function(e){n.classesBeingAdded.add(e),n.setState((function(t){var n=new Set(t.classList);return n.add(e),{classList:n}}),(function(){n.classesBeingAdded.delete(e)}))},n.removeClass=function(e){n.classesBeingRemoved.add(e),n.setState((function(t){var n=new Set(t.classList);return n.delete(e),{classList:n}}),(function(){n.classesBeingRemoved.delete(e)}))},n.closeMenu=function(){return n.setState({open:!1})},n.setValidClasses=function(e){e?n.removeClass(m.INVALID):n.addClass(m.INVALID)},n.setHelperTextFoundation=function(e){n.setState({helperTextFoundation:e})},n.setIconFoundation=function(e){n.setState({iconFoundation:e})},n.state={classList:new Set,disabled:t.disabled,value:t.value,labelIsFloated:!1,labelWidth:0,activeLineRipple:!1,lineRippleCenter:void 0,outlineIsNotched:!1,open:!1,selectElement:s.default.createRef(),isInvalid:!1,helperTextFoundation:void 0,iconFoundation:void 0,foundation:void 0},n}return i(Select,e),Select.prototype.componentDidMount=function(){var e=this;this.createFoundation((function(){e.state.foundation.handleChange(!1)}))},Select.prototype.componentDidUpdate=function(e,t){this.props.value!==e.value&&this.setState({value:this.props.value}),this.state.foundation&&this.state.value!==t.value&&this.state.foundation.handleChange(!0),this.state.helperTextFoundation===t.helperTextFoundation&&this.state.iconFoundation===t.iconFoundation||(this.destroyFoundation(),this.createFoundation())},Select.prototype.componentWillUnmount=function(){this.destroyFoundation()},Object.defineProperty(Select.prototype,"classes",{get:function(){var e=this.state,t=e.classList,n=e.disabled,r=this.props,i=r.className,o=r.leadingIcon,a=r.required,u=r.outlined;return c.default("mdc-select",Array.from(t),i,{"mdc-select--outlined":u,"mdc-select--disabled":n,"mdc-select--required":a,"mdc-select--with-leading-icon":o})},enumerable:!0,configurable:!0}),Object.defineProperty(Select.prototype,"adapter",{get:function(){var e=this,t=this.props.enhanced,n={addClass:this.addClass,removeClass:this.removeClass,hasClass:function(t){var n=e.classes.split(" ").includes(t),r=e.classesBeingAdded.has(t),i=e.classesBeingRemoved.has(t);return(n||r)&&!i},setRippleCenter:function(t){return e.setState({lineRippleCenter:t})},getValue:function(){return e.state.value},setValue:function(t){return e.setState({value:t})},setDisabled:function(t){return e.setState({disabled:t})},setSelectedIndex:function(){},closeMenu:this.closeMenu,openMenu:function(){return e.setState({open:!0})}},r={isMenuOpen:function(){return!1},checkValidity:function(){return!!e.nativeControl.current&&e.nativeControl.current.checkValidity()},setValid:this.setValidClasses};return o({},t?{isMenuOpen:function(){return e.state.open},checkValidity:function(){return!(!e.props.disabled&&e.props.required)||Boolean(e.state.value)},setValid:function(t){e.setState({isInvalid:!t}),e.setValidClasses(t)}}:r,n,{floatLabel:function(t){return e.setState({labelIsFloated:t})},getLabelWidth:function(){return e.state.labelWidth}},{activateBottomLine:function(){return e.setState({activeLineRipple:!0})},deactivateBottomLine:function(){return e.setState({activeLineRipple:!1})},notifyChange:function(t){return e.props.afterChange(t)}},{notchOutline:function(){return e.setState({outlineIsNotched:!0})},closeOutline:function(){return e.setState({outlineIsNotched:!1})},hasOutline:function(){return!!e.props.outlined}})},enumerable:!0,configurable:!0}),Object.defineProperty(Select.prototype,"foundationMap",{get:function(){var e=this.state;return{helperText:e.helperTextFoundation,leadingIcon:e.iconFoundation}},enumerable:!0,configurable:!0}),Select.prototype.render=function(){return s.default.createElement(s.default.Fragment,null,s.default.createElement("div",{className:this.classes,ref:this.state.selectElement},this.renderIcon(),s.default.createElement("i",{className:"mdc-select__dropdown-icon"}),this.renderSelect(),this.props.outlined?null:this.renderLabel(),this.props.outlined?this.renderNotchedOutline():this.renderLineRipple()),this.renderHelperText())},Select.prototype.renderSelect=function(){var e=this.props,t=e.selectClassName,n=(e.floatingLabelClassName,e.lineRippleClassName,e.notchedOutlineClassName,e.outlined,e.ref,e.value,e.afterChange,e.onEnhancedChange),r=(e.helperText,e.leadingIcon,e.enhanced),i=a(e,["selectClassName","floatingLabelClassName","lineRippleClassName","notchedOutlineClassName","outlined","ref","value","afterChange","onEnhancedChange","helperText","leadingIcon","enhanced"]),u=this.state,c=u.open,l=u.selectElement,d=u.isInvalid,f=u.value,p={onEnhancedChange:n,closeMenu:this.closeMenu,anchorElement:l.current,enhanced:r,isInvalid:d};return s.default.createElement(h.BaseSelect,o({open:c,value:f,innerRef:this.nativeControl,foundation:this.state.foundation,className:t},r?p:{},i),this.renderOptions())},Select.prototype.renderOptions=function(){var e=this.props,t=e.children,n=e.options;return void 0!==n&&n.length?n.map((function(e,t){if("string"==typeof e)return s.default.createElement(_.default,{key:t,value:e},e);var n=e.label,r=a(e,["label"]);return(s.default.createElement(_.default,o({key:t},r),n))})):t},Select.prototype.renderLabel=function(){var e=this,t=this.props,n=t.id,r=t.label,i=t.floatingLabelClassName;if(r)return s.default.createElement(d.default,{className:i,float:this.state.labelIsFloated,handleWidthChange:function(t){return e.setState({labelWidth:t})},htmlFor:n},r)},Select.prototype.renderLineRipple=function(){var e=this.props.lineRippleClassName,t=this.state,n=t.activeLineRipple,r=t.lineRippleCenter;return s.default.createElement(f.default,{rippleCenter:r,className:e,active:n})},Select.prototype.renderNotchedOutline=function(){var e=this.props.notchedOutlineClassName,t=this.state,n=t.outlineIsNotched,r=t.labelWidth;return s.default.createElement(p.default,{className:e,notch:n,notchWidth:r},this.renderLabel())},Select.prototype.renderHelperText=function(){var e=this.props.helperText;if(e){var t=o({},e.props,{setHelperTextFoundation:this.setHelperTextFoundation});return s.default.cloneElement(e,t)}},Select.prototype.renderIcon=function(){var e=this.props.leadingIcon;if(e){var t=o({},e.props,{setIconFoundation:this.setIconFoundation});return s.default.cloneElement(e,t)}},Select.defaultProps={enhanced:!1,className:"",disabled:!1,floatingLabelClassName:"",lineRippleClassName:"",selectClassName:"",notchedOutlineClassName:"",outlined:!1,options:[],onChange:function(){},onEnhancedChange:function(){},value:"",afterChange:function(){}},Select}(s.default.Component);t.default=g;var y=n(182);t.SelectHelperText=y.SelectHelperText;var v=n(185);t.SelectIcon=v.SelectIcon;var b=n(25);t.OptionDivider=b.MenuListDivider,t.OptionGroup=b.MenuListGroup,t.OptionGroupSubheader=b.MenuListGroupSubheader,t.OptionGraphic=b.MenuListItemGraphic,t.OptionMeta=b.MenuListItemMeta,t.OptionText=b.MenuListItemText},175:function(e,t,n){"use strict";n.d(t,"a",(function(){return r})),n.d(t,"c",(function(){return i})),n.d(t,"b",(function(){return o}));var r={DISABLED:"mdc-select--disabled",FOCUSED:"mdc-select--focused",INVALID:"mdc-select--invalid",OUTLINED:"mdc-select--outlined",REQUIRED:"mdc-select--required",ROOT:"mdc-select",SELECTED_ITEM_CLASS:"mdc-list-item--selected",WITH_LEADING_ICON:"mdc-select--with-leading-icon"},i={ARIA_CONTROLS:"aria-controls",ARIA_SELECTED_ATTR:"aria-selected",CHANGE_EVENT:"MDCSelect:change",ENHANCED_VALUE_ATTR:"data-value",HIDDEN_INPUT_SELECTOR:'input[type="hidden"]',LABEL_SELECTOR:".mdc-floating-label",LEADING_ICON_SELECTOR:".mdc-select__icon",LINE_RIPPLE_SELECTOR:".mdc-line-ripple",MENU_SELECTOR:".mdc-select__menu",NATIVE_CONTROL_SELECTOR:".mdc-select__native-control",OUTLINE_SELECTOR:".mdc-notched-outline",SELECTED_ITEM_SELECTOR:"."+r.SELECTED_ITEM_CLASS,SELECTED_TEXT_SELECTOR:".mdc-select__selected-text"},o={LABEL_SCALE:.75}},176:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var c=u(n(0)),l=s(n(177)),d=s(n(178)),f=function(e){function BaseSelect(){var t=null!==e&&e.apply(this,arguments)||this;return t.handleFocus=function(e){var n=t.props,r=n.foundation,i=n.onFocus;r&&r.handleFocus(),i&&i(e)},t.handleBlur=function(e){var n=t.props,r=n.foundation,i=n.onBlur;r&&r.handleBlur(),i&&i(e)},t.handleTouchStart=function(e){var n=t.props,r=n.foundation,i=n.onTouchStart;r&&r.handleClick(t.getNormalizedXCoordinate(e)),i&&i(e)},t.handleMouseDown=function(e){var n=t.props,r=n.foundation,i=n.onMouseDown;r&&r.handleClick(t.getNormalizedXCoordinate(e)),i&&i(e)},t.handleClick=function(e){var n=t.props,r=n.foundation,i=n.onClick;r&&r.handleClick(t.getNormalizedXCoordinate(e)),i&&i(e)},t.handleKeyDown=function(e){var n=t.props,r=n.foundation,i=n.onKeyDown;r&&r.handleKeydown(e.nativeEvent),i&&i(e)},t.isTouchEvent=function(e){return Boolean(e.touches)},t.getNormalizedXCoordinate=function(e){var n=e.currentTarget.getBoundingClientRect();return(t.isTouchEvent(e.nativeEvent)?e.nativeEvent.touches[0].clientX:e.nativeEvent.clientX)-n.left},t}return i(BaseSelect,e),BaseSelect.prototype.render=function(){var e=this.props,t=(e.onFocus,e.onBlur,e.onClick,e.onMouseDown,e.onTouchStart,e.ref,e.enhanced),n=e.children,r=e.onKeyDown,i=e.selectClassName,u=a(e,["onFocus","onBlur","onClick","onMouseDown","onTouchStart","ref","enhanced","children","onKeyDown","selectClassName"]),s=o({onFocus:this.handleFocus,onBlur:this.handleBlur,onMouseDown:this.handleMouseDown,onClick:this.handleClick,onTouchStart:this.handleTouchStart,className:i},u);return t?c.createElement(d.default,o({onKeyDown:this.handleKeyDown},s),n):c.createElement(l.default,o({onKeyDown:r},s),n)},BaseSelect.defaultProps={enhanced:!1,selectClassName:""},BaseSelect}(c.Component);t.BaseSelect=f},177:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=function(e){function NativeSelect(){var t=null!==e&&e.apply(this,arguments)||this;return t.NativeSelect=s.default.createRef(),t.attachRef=function(e){var n=t.props.innerRef;t.NativeSelect.current=e,n&&("function"!=typeof n?n.current=e:n(e))},t}return i(NativeSelect,e),Object.defineProperty(NativeSelect.prototype,"classes",{get:function(){return c.default("mdc-select__native-control",this.props.className)},enumerable:!0,configurable:!0}),NativeSelect.prototype.render=function(){var e=this.props,t=(e.className,e.children),n=(e.foundation,e.innerRef,a(e,["className","children","foundation","innerRef"]));return s.default.createElement("select",o({className:this.classes,ref:this.attachRef},n),t)},NativeSelect.defaultProps={className:"",children:null,disabled:!1,value:""},NativeSelect}(s.default.Component);t.default=l},178:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=a(n(0)),c=n(179),l=a(n(25)),d=u(n(48)),f=c.MDCMenuSurfaceFoundation.Corner,p=function(e){function EnhancedSelect(){var t=null!==e&&e.apply(this,arguments)||this;return t.nativeControl=s.createRef(),t.selectedTextEl=s.createRef(),t.menuEl=s.createRef(),t.state={"aria-expanded":void 0,selectedItem:null,selectedValue:""},t.setSelected=function(){var e=null!==t.menuEl.current&&t.menuEl.current.listElements;if(e&&e.length){var n=e[t.getIndexByValue(e)],r=n&&n.getAttribute(d.default.strings.ENHANCED_VALUE_ATTR)||"";t.setState({selectedItem:n,selectedValue:r})}},t.getIndexByValue=function(e){var n=t.props.value,r=-1;return r<0&&n&&e.some((function(e,t){return e.getAttribute(d.default.strings.ENHANCED_VALUE_ATTR)===n&&(r=t,!0)})),r},t.handleMenuClose=function(){var e=t.props,n=e.closeMenu,r=e.foundation;n(),t.setState({"aria-expanded":void 0}),r&&document.activeElement!==t.selectedTextEl.current&&r.handleBlur()},t.handleMenuOpen=function(){if(t.setState({"aria-expanded":!0}),t.listElements&&t.listElements.length>0){var e=t.getIndexByValue(t.listElements);e=e>-1?e:0,t.listElements[e].focus()}},t}return i(EnhancedSelect,e),EnhancedSelect.prototype.componentDidUpdate=function(e){this.props.value!==e.value&&this.setSelected()},Object.defineProperty(EnhancedSelect.prototype,"listElements",{get:function(){return null!==this.menuEl.current&&this.menuEl.current.listElements},enumerable:!0,configurable:!0}),EnhancedSelect.prototype.render=function(){var e=this.props,t=e.children,n=e.required,r=e.open,i=e.disabled,a=e.anchorElement,u=e.onMouseDown,c=e.onTouchStart,d=e.onKeyDown,p=e.onFocus,h=e.onClick,_=e.onBlur,m=e.onEnhancedChange,g=e.isInvalid,y=this.state,v=y["aria-expanded"],b=y.selectedValue,C=y.selectedItem,E={};return n&&(E["aria-required"]=n.toString()),v&&"false"!==v&&(E["aria-expanded"]="true"),g&&(E["aria-invalid"]="true"),E["aria-disabled"]=i?"true":"false",s.createElement(s.Fragment,null,s.createElement("input",{type:"hidden",name:"enhanced-select",disabled:i,value:b}),s.createElement("div",o({className:"mdc-select__selected-text"},E,{ref:this.selectedTextEl,tabIndex:i?-1:0,onMouseDown:u,onTouchStart:c,onKeyDown:d,onFocus:p,onClick:h,onBlur:_}),C?C.textContent.trim():""),s.createElement(l.default,{className:"mdc-select__menu",onClose:this.handleMenuClose,onOpen:this.handleMenuOpen,open:r,onSelected:m,anchorElement:a||void 0,anchorCorner:f.BOTTOM_START,ref:this.menuEl,onMount:this.setSelected},s.createElement(l.MenuList,null,s.Children.map(t,(function(e){var t=e;return s.cloneElement(t,o({},t.props,{enhanced:!0}))})))))},EnhancedSelect.defaultProps={disabled:!1,closeMenu:function(){},onEnhancedChange:function(){},value:"",anchorElement:null,isInvalid:!1},EnhancedSelect}(s.Component);t.default=p},179:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCMenuSurfaceFoundation",(function(){return a}));var r=n(7),i=n(8),o=n(180),a=function(e){function MDCMenuSurfaceFoundation(t){var n=e.call(this,r.a({},MDCMenuSurfaceFoundation.defaultAdapter,t))||this;return n.isOpen_=!1,n.isQuickOpen_=!1,n.isHoistedElement_=!1,n.isFixedPosition_=!1,n.openAnimationEndTimerId_=0,n.closeAnimationEndTimerId_=0,n.animationRequestId_=0,n.anchorCorner_=o.a.TOP_START,n.anchorMargin_={top:0,right:0,bottom:0,left:0},n.position_={x:0,y:0},n}return r.b(MDCMenuSurfaceFoundation,e),Object.defineProperty(MDCMenuSurfaceFoundation,"cssClasses",{get:function(){return o.c},enumerable:!0,configurable:!0}),Object.defineProperty(MDCMenuSurfaceFoundation,"strings",{get:function(){return o.e},enumerable:!0,configurable:!0}),Object.defineProperty(MDCMenuSurfaceFoundation,"numbers",{get:function(){return o.d},enumerable:!0,configurable:!0}),Object.defineProperty(MDCMenuSurfaceFoundation,"Corner",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCMenuSurfaceFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},hasAnchor:function(){return!1},isElementInContainer:function(){return!1},isFocused:function(){return!1},isFirstElementFocused:function(){return!1},isLastElementFocused:function(){return!1},isRtl:function(){return!1},getInnerDimensions:function(){return{height:0,width:0}},getAnchorDimensions:function(){return null},getWindowDimensions:function(){return{height:0,width:0}},getBodyDimensions:function(){return{height:0,width:0}},getWindowScroll:function(){return{x:0,y:0}},setPosition:function(){},setMaxHeight:function(){},setTransformOrigin:function(){},saveFocus:function(){},restoreFocus:function(){},focusFirstElement:function(){},focusLastElement:function(){},notifyClose:function(){},notifyOpen:function(){}}},enumerable:!0,configurable:!0}),MDCMenuSurfaceFoundation.prototype.init=function(){var e=MDCMenuSurfaceFoundation.cssClasses,t=e.ROOT,n=e.OPEN;if(!this.adapter_.hasClass(t))throw new Error(t+" class required in root element.");this.adapter_.hasClass(n)&&(this.isOpen_=!0)},MDCMenuSurfaceFoundation.prototype.destroy=function(){clearTimeout(this.openAnimationEndTimerId_),clearTimeout(this.closeAnimationEndTimerId_),cancelAnimationFrame(this.animationRequestId_)},MDCMenuSurfaceFoundation.prototype.setAnchorCorner=function(e){this.anchorCorner_=e},MDCMenuSurfaceFoundation.prototype.setAnchorMargin=function(e){this.anchorMargin_.top=e.top||0,this.anchorMargin_.right=e.right||0,this.anchorMargin_.bottom=e.bottom||0,this.anchorMargin_.left=e.left||0},MDCMenuSurfaceFoundation.prototype.setIsHoisted=function(e){this.isHoistedElement_=e},MDCMenuSurfaceFoundation.prototype.setFixedPosition=function(e){this.isFixedPosition_=e},MDCMenuSurfaceFoundation.prototype.setAbsolutePosition=function(e,t){this.position_.x=this.isFinite_(e)?e:0,this.position_.y=this.isFinite_(t)?t:0},MDCMenuSurfaceFoundation.prototype.setQuickOpen=function(e){this.isQuickOpen_=e},MDCMenuSurfaceFoundation.prototype.isOpen=function(){return this.isOpen_},MDCMenuSurfaceFoundation.prototype.open=function(){var e=this;this.adapter_.saveFocus(),this.isQuickOpen_||this.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_OPEN),this.animationRequestId_=requestAnimationFrame((function(){e.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.OPEN),e.dimensions_=e.adapter_.getInnerDimensions(),e.autoPosition_(),e.isQuickOpen_?e.adapter_.notifyOpen():e.openAnimationEndTimerId_=setTimeout((function(){e.openAnimationEndTimerId_=0,e.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_OPEN),e.adapter_.notifyOpen()}),o.d.TRANSITION_OPEN_DURATION)})),this.isOpen_=!0},MDCMenuSurfaceFoundation.prototype.close=function(){var e=this;this.isQuickOpen_||this.adapter_.addClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_CLOSED),requestAnimationFrame((function(){e.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.OPEN),e.isQuickOpen_?e.adapter_.notifyClose():e.closeAnimationEndTimerId_=setTimeout((function(){e.closeAnimationEndTimerId_=0,e.adapter_.removeClass(MDCMenuSurfaceFoundation.cssClasses.ANIMATING_CLOSED),e.adapter_.notifyClose()}),o.d.TRANSITION_CLOSE_DURATION)})),this.isOpen_=!1,this.maybeRestoreFocus_()},MDCMenuSurfaceFoundation.prototype.handleBodyClick=function(e){var t=e.target;this.adapter_.isElementInContainer(t)||this.close()},MDCMenuSurfaceFoundation.prototype.handleKeydown=function(e){var t=e.keyCode,n=e.key,r=e.shiftKey,i="Tab"===n||9===t;"Escape"===n||27===t?this.close():i&&(this.adapter_.isLastElementFocused()&&!r?(this.adapter_.focusFirstElement(),e.preventDefault()):this.adapter_.isFirstElementFocused()&&r&&(this.adapter_.focusLastElement(),e.preventDefault()))},MDCMenuSurfaceFoundation.prototype.autoPosition_=function(){var e;this.measurements_=this.getAutoLayoutMeasurements_();var t=this.getOriginCorner_(),n=this.getMenuSurfaceMaxHeight_(t),r=this.hasBit_(t,o.b.BOTTOM)?"bottom":"top",i=this.hasBit_(t,o.b.RIGHT)?"right":"left",a=this.getHorizontalOriginOffset_(t),u=this.getVerticalOriginOffset_(t),s=this.measurements_,c=s.anchorSize,l=s.surfaceSize,d=((e={})[i]=a,e[r]=u,e);c.width/l.width>o.d.ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO&&(i="center"),(this.isHoistedElement_||this.isFixedPosition_)&&this.adjustPositionForHoistedElement_(d),this.adapter_.setTransformOrigin(i+" "+r),this.adapter_.setPosition(d),this.adapter_.setMaxHeight(n?n+"px":"")},MDCMenuSurfaceFoundation.prototype.getAutoLayoutMeasurements_=function(){var e=this.adapter_.getAnchorDimensions(),t=this.adapter_.getBodyDimensions(),n=this.adapter_.getWindowDimensions(),r=this.adapter_.getWindowScroll();return e||(e={top:this.position_.y,right:this.position_.x,bottom:this.position_.y,left:this.position_.x,width:0,height:0}),{anchorSize:e,bodySize:t,surfaceSize:this.dimensions_,viewportDistance:{top:e.top,right:n.width-e.right,bottom:n.height-e.bottom,left:e.left},viewportSize:n,windowScroll:r}},MDCMenuSurfaceFoundation.prototype.getOriginCorner_=function(){var e=o.a.TOP_LEFT,t=this.measurements_,n=t.viewportDistance,r=t.anchorSize,i=t.surfaceSize,a=this.hasBit_(this.anchorCorner_,o.b.BOTTOM),u=a?n.top+r.height+this.anchorMargin_.bottom:n.top+this.anchorMargin_.top,s=a?n.bottom-this.anchorMargin_.bottom:n.bottom+r.height-this.anchorMargin_.top,c=i.height-u,l=i.height-s;l>0&&c<l&&(e=this.setBit_(e,o.b.BOTTOM));var d=this.adapter_.isRtl(),f=this.hasBit_(this.anchorCorner_,o.b.FLIP_RTL),p=this.hasBit_(this.anchorCorner_,o.b.RIGHT),h=p&&!d||!p&&f&&d,_=h?n.left+r.width+this.anchorMargin_.right:n.left+this.anchorMargin_.left,m=h?n.right-this.anchorMargin_.right:n.right+r.width-this.anchorMargin_.left,g=i.width-_,y=i.width-m;return(g<0&&h&&d||p&&!h&&g<0||y>0&&g<y)&&(e=this.setBit_(e,o.b.RIGHT)),e},MDCMenuSurfaceFoundation.prototype.getMenuSurfaceMaxHeight_=function(e){var t=this.measurements_.viewportDistance,n=0,r=this.hasBit_(e,o.b.BOTTOM),i=this.hasBit_(this.anchorCorner_,o.b.BOTTOM),a=MDCMenuSurfaceFoundation.numbers.MARGIN_TO_EDGE;return r?(n=t.top+this.anchorMargin_.top-a,i||(n+=this.measurements_.anchorSize.height)):(n=t.bottom-this.anchorMargin_.bottom+this.measurements_.anchorSize.height-a,i&&(n-=this.measurements_.anchorSize.height)),n},MDCMenuSurfaceFoundation.prototype.getHorizontalOriginOffset_=function(e){var t=this.measurements_.anchorSize,n=this.hasBit_(e,o.b.RIGHT),r=this.hasBit_(this.anchorCorner_,o.b.RIGHT);if(n){var i=r?t.width-this.anchorMargin_.left:this.anchorMargin_.right;return this.isHoistedElement_||this.isFixedPosition_?i-(this.measurements_.viewportSize.width-this.measurements_.bodySize.width):i}return r?t.width-this.anchorMargin_.right:this.anchorMargin_.left},MDCMenuSurfaceFoundation.prototype.getVerticalOriginOffset_=function(e){var t=this.measurements_.anchorSize,n=this.hasBit_(e,o.b.BOTTOM),r=this.hasBit_(this.anchorCorner_,o.b.BOTTOM);return n?r?t.height-this.anchorMargin_.top:-this.anchorMargin_.bottom:r?t.height+this.anchorMargin_.bottom:this.anchorMargin_.top},MDCMenuSurfaceFoundation.prototype.adjustPositionForHoistedElement_=function(e){var t,n,i=this.measurements_,o=i.windowScroll,a=i.viewportDistance,u=Object.keys(e);try{for(var s=r.c(u),c=s.next();!c.done;c=s.next()){var l=c.value,d=e[l]||0;d+=a[l],this.isFixedPosition_||("top"===l?d+=o.y:"bottom"===l?d-=o.y:"left"===l?d+=o.x:d-=o.x),e[l]=d}}catch(e){t={error:e}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(t)throw t.error}}},MDCMenuSurfaceFoundation.prototype.maybeRestoreFocus_=function(){var e=this.adapter_.isFocused(),t=document.activeElement&&this.adapter_.isElementInContainer(document.activeElement);(e||t)&&this.adapter_.restoreFocus()},MDCMenuSurfaceFoundation.prototype.hasBit_=function(e,t){return Boolean(e&t)},MDCMenuSurfaceFoundation.prototype.setBit_=function(e,t){return e|t},MDCMenuSurfaceFoundation.prototype.isFinite_=function(e){return"number"==typeof e&&isFinite(e)},MDCMenuSurfaceFoundation}(i.a);t.default=a},180:function(e,t,n){"use strict";n.d(t,"c",(function(){return o})),n.d(t,"e",(function(){return a})),n.d(t,"d",(function(){return u})),n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return i}));var r,i,o={ANCHOR:"mdc-menu-surface--anchor",ANIMATING_CLOSED:"mdc-menu-surface--animating-closed",ANIMATING_OPEN:"mdc-menu-surface--animating-open",FIXED:"mdc-menu-surface--fixed",OPEN:"mdc-menu-surface--open",ROOT:"mdc-menu-surface"},a={CLOSED_EVENT:"MDCMenuSurface:closed",OPENED_EVENT:"MDCMenuSurface:opened",FOCUSABLE_ELEMENTS:["button:not(:disabled)",'[href]:not([aria-disabled="true"])',"input:not(:disabled)","select:not(:disabled)","textarea:not(:disabled)",'[tabindex]:not([tabindex="-1"]):not([aria-disabled="true"])'].join(", ")},u={TRANSITION_OPEN_DURATION:120,TRANSITION_CLOSE_DURATION:75,MARGIN_TO_EDGE:32,ANCHOR_TO_MENU_SURFACE_WIDTH_RATIO:.67};!function(e){e[e.BOTTOM=1]="BOTTOM",e[e.CENTER=2]="CENTER",e[e.RIGHT=4]="RIGHT",e[e.FLIP_RTL=8]="FLIP_RTL"}(r||(r={})),function(e){e[e.TOP_LEFT=0]="TOP_LEFT",e[e.TOP_RIGHT=4]="TOP_RIGHT",e[e.BOTTOM_LEFT=1]="BOTTOM_LEFT",e[e.BOTTOM_RIGHT=5]="BOTTOM_RIGHT",e[e.TOP_START=8]="TOP_START",e[e.TOP_END=12]="TOP_END",e[e.BOTTOM_START=9]="BOTTOM_START",e[e.BOTTOM_END=13]="BOTTOM_END"}(i||(i={}))},181:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=n(25),l=function(e){function Option(){return null!==e&&e.apply(this,arguments)||this}return i(Option,e),Option.prototype.render=function(){var e=this.props,t=e.value,n=e.enhanced,r=e.children,i=a(e,["value","enhanced","children"]);return n?s.createElement(c.MenuListItem,o({"data-value":t},i),r):s.createElement("option",o({value:t},i),r)},Option.defaultProps={enhanced:!1},Option}(s.Component);t.default=l},182:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importStar||function(e){if(e&&e.__esModule)return e;var t={};if(null!=e)for(var n in e)Object.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t.default=e,t},s=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var c=u(n(0)),l=s(n(1)),d=n(183),f=function(e){function SelectHelperText(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={"aria-hidden":void 0,role:void 0,classList:new Set},t}return i(SelectHelperText,e),SelectHelperText.prototype.componentDidMount=function(){var e=this.props.setHelperTextFoundation;this.foundation=new d.MDCSelectHelperTextFoundation(this.adapter),this.foundation.init(),e&&e(this.foundation)},SelectHelperText.prototype.componentWillUnmount=function(){var e=this.props.setHelperTextFoundation;this.foundation&&(this.foundation.destroy(),e&&e(void 0))},Object.defineProperty(SelectHelperText.prototype,"classes",{get:function(){var e=this.props,t=e.className,n=e.persistent,r=this.state.classList;return l.default("mdc-select-helper-text",Array.from(r),t,{"mdc-select-helper-text--persistent":n})},enumerable:!0,configurable:!0}),Object.defineProperty(SelectHelperText.prototype,"adapter",{get:function(){var e=this;return{addClass:function(t){var n=new Set(e.state.classList);n.add(t),e.setState({classList:n})},removeClass:function(t){var n=new Set(e.state.classList);n.delete(t),e.setState({classList:n})},hasClass:function(t){return e.classes.split(" ").includes(t)},setAttr:function(t,n){e.setState((function(e){var r;return o({},e,((r={})[t]=n,r))}))},removeAttr:function(t){e.setState((function(e){var n;return o({},e,((n={})[t]=null,n))}))},setContent:function(){}}},enumerable:!0,configurable:!0}),SelectHelperText.prototype.render=function(){var e=this.props,t=e.children,n=(e.persistent,e.className,e.setHelperTextFoundation,a(e,["children","persistent","className","setHelperTextFoundation"])),r=this.state,i=r["aria-hidden"],u=r.role;return c.createElement("p",o({className:this.classes,"aria-hidden":i,role:u},n),t)},SelectHelperText}(c.Component);t.SelectHelperText=f},183:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCSelectHelperTextFoundation",(function(){return a}));var r=n(7),i=n(8),o=n(184),a=function(e){function MDCSelectHelperTextFoundation(t){return e.call(this,r.a({},MDCSelectHelperTextFoundation.defaultAdapter,t))||this}return r.b(MDCSelectHelperTextFoundation,e),Object.defineProperty(MDCSelectHelperTextFoundation,"cssClasses",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectHelperTextFoundation,"strings",{get:function(){return o.b},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectHelperTextFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},setAttr:function(){},removeAttr:function(){},setContent:function(){}}},enumerable:!0,configurable:!0}),MDCSelectHelperTextFoundation.prototype.setContent=function(e){this.adapter_.setContent(e)},MDCSelectHelperTextFoundation.prototype.setPersistent=function(e){e?this.adapter_.addClass(o.a.HELPER_TEXT_PERSISTENT):this.adapter_.removeClass(o.a.HELPER_TEXT_PERSISTENT)},MDCSelectHelperTextFoundation.prototype.setValidation=function(e){e?this.adapter_.addClass(o.a.HELPER_TEXT_VALIDATION_MSG):this.adapter_.removeClass(o.a.HELPER_TEXT_VALIDATION_MSG)},MDCSelectHelperTextFoundation.prototype.showToScreenReader=function(){this.adapter_.removeAttr(o.b.ARIA_HIDDEN)},MDCSelectHelperTextFoundation.prototype.setValidity=function(e){var t=this.adapter_.hasClass(o.a.HELPER_TEXT_PERSISTENT),n=this.adapter_.hasClass(o.a.HELPER_TEXT_VALIDATION_MSG)&&!e;n?this.adapter_.setAttr(o.b.ROLE,"alert"):this.adapter_.removeAttr(o.b.ROLE),t||n||this.hide_()},MDCSelectHelperTextFoundation.prototype.hide_=function(){this.adapter_.setAttr(o.b.ARIA_HIDDEN,"true")},MDCSelectHelperTextFoundation}(i.a);t.default=a},184:function(e,t,n){"use strict";n.d(t,"b",(function(){return r})),n.d(t,"a",(function(){return i}));var r={ARIA_HIDDEN:"aria-hidden",ROLE:"role"},i={HELPER_TEXT_PERSISTENT:"mdc-select-helper-text--persistent",HELPER_TEXT_VALIDATION_MSG:"mdc-select-helper-text--validation-msg"}},185:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=n(186),d=function(e){function SelectIcon(){var t=null!==e&&e.apply(this,arguments)||this;return t.state={tabindex:void 0,role:void 0},t}return i(SelectIcon,e),SelectIcon.prototype.componentDidMount=function(){var e=this.props.setIconFoundation;this.foundation=new l.MDCSelectIconFoundation(this.adapter),this.foundation.init(),e&&e(this.foundation)},SelectIcon.prototype.componentWillUnmount=function(){var e=this.props.setIconFoundation;this.foundation&&(this.foundation.destroy(),e&&e(void 0))},Object.defineProperty(SelectIcon.prototype,"adapter",{get:function(){var e=this;return{getAttr:function(t){if(void 0!==e.state[t])return e.state[t].toString();var n="tabindex"===t?"tabIndex":t;return void 0!==e.props[n]?e.props[n].toString():null},setAttr:function(t,n){e.setState((function(e){var r;return o({},e,((r={})[t]=n,r))}))},removeAttr:function(t){e.setState((function(e){var n;return o({},e,((n={})[t]=null,n))}))},setContent:function(){},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){},notifyIconAction:function(){}}},enumerable:!0,configurable:!0}),SelectIcon.prototype.render=function(){var e=this.props,t=e.tag,n=(e.setIconFoundation,e.children),r=e.className,i=a(e,["tag","setIconFoundation","children","className"]),u=this.state,l=u.tabindex,d=u.role;return s.default.createElement(t,o({className:c.default("mdc-select__icon",r),role:d,tabIndex:l},i),n)},SelectIcon.defaultProps={tag:"i"},SelectIcon}(s.default.Component);t.SelectIcon=d},186:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCSelectIconFoundation",(function(){return u}));var r=n(7),i=n(8),o=n(187),a=["click","keydown"],u=function(e){function MDCSelectIconFoundation(t){var n=e.call(this,r.a({},MDCSelectIconFoundation.defaultAdapter,t))||this;return n.savedTabIndex_=null,n.interactionHandler_=function(e){return n.handleInteraction(e)},n}return r.b(MDCSelectIconFoundation,e),Object.defineProperty(MDCSelectIconFoundation,"strings",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectIconFoundation,"defaultAdapter",{get:function(){return{getAttr:function(){return null},setAttr:function(){},removeAttr:function(){},setContent:function(){},registerInteractionHandler:function(){},deregisterInteractionHandler:function(){},notifyIconAction:function(){}}},enumerable:!0,configurable:!0}),MDCSelectIconFoundation.prototype.init=function(){var e=this;this.savedTabIndex_=this.adapter_.getAttr("tabindex"),a.forEach((function(t){e.adapter_.registerInteractionHandler(t,e.interactionHandler_)}))},MDCSelectIconFoundation.prototype.destroy=function(){var e=this;a.forEach((function(t){e.adapter_.deregisterInteractionHandler(t,e.interactionHandler_)}))},MDCSelectIconFoundation.prototype.setDisabled=function(e){this.savedTabIndex_&&(e?(this.adapter_.setAttr("tabindex","-1"),this.adapter_.removeAttr("role")):(this.adapter_.setAttr("tabindex",this.savedTabIndex_),this.adapter_.setAttr("role",o.a.ICON_ROLE)))},MDCSelectIconFoundation.prototype.setAriaLabel=function(e){this.adapter_.setAttr("aria-label",e)},MDCSelectIconFoundation.prototype.setContent=function(e){this.adapter_.setContent(e)},MDCSelectIconFoundation.prototype.handleInteraction=function(e){var t="Enter"===e.key||13===e.keyCode;("click"===e.type||t)&&this.adapter_.notifyIconAction()},MDCSelectIconFoundation}(i.a);t.default=u},187:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r={ICON_EVENT:"MDCSelect:icon",ICON_ROLE:"button"}},22:function(e,t){e.exports=n},23:function(e,t){e.exports=r},24:function(e,t){e.exports=i},25:function(e,t){e.exports=o},48:function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),n.d(t,"MDCSelectFoundation",(function(){return a}));var r=n(7),i=n(8),o=n(175),a=function(e){function MDCSelectFoundation(t,n){void 0===n&&(n={});var i=e.call(this,r.a({},MDCSelectFoundation.defaultAdapter,t))||this;return i.leadingIcon_=n.leadingIcon,i.helperText_=n.helperText,i}return r.b(MDCSelectFoundation,e),Object.defineProperty(MDCSelectFoundation,"cssClasses",{get:function(){return o.a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectFoundation,"numbers",{get:function(){return o.b},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectFoundation,"strings",{get:function(){return o.c},enumerable:!0,configurable:!0}),Object.defineProperty(MDCSelectFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},removeClass:function(){},hasClass:function(){return!1},activateBottomLine:function(){},deactivateBottomLine:function(){},setValue:function(){},getValue:function(){return""},floatLabel:function(){},getLabelWidth:function(){return 0},hasOutline:function(){return!1},notchOutline:function(){},closeOutline:function(){},openMenu:function(){},closeMenu:function(){},isMenuOpen:function(){return!1},setSelectedIndex:function(){},setDisabled:function(){},setRippleCenter:function(){},notifyChange:function(){},checkValidity:function(){return!1},setValid:function(){}}},enumerable:!0,configurable:!0}),MDCSelectFoundation.prototype.setSelectedIndex=function(e){this.adapter_.setSelectedIndex(e),this.adapter_.closeMenu(),this.handleChange(!0)},MDCSelectFoundation.prototype.setValue=function(e){this.adapter_.setValue(e),this.handleChange(!0)},MDCSelectFoundation.prototype.getValue=function(){return this.adapter_.getValue()},MDCSelectFoundation.prototype.setDisabled=function(e){e?this.adapter_.addClass(o.a.DISABLED):this.adapter_.removeClass(o.a.DISABLED),this.adapter_.setDisabled(e),this.adapter_.closeMenu(),this.leadingIcon_&&this.leadingIcon_.setDisabled(e)},MDCSelectFoundation.prototype.setHelperTextContent=function(e){this.helperText_&&this.helperText_.setContent(e)},MDCSelectFoundation.prototype.layout=function(){var e=this.getValue().length>0;this.notchOutline(e)},MDCSelectFoundation.prototype.handleChange=function(e){void 0===e&&(e=!0);var t=this.getValue(),n=t.length>0,r=this.adapter_.hasClass(o.a.REQUIRED);this.notchOutline(n),this.adapter_.hasClass(o.a.FOCUSED)||this.adapter_.floatLabel(n),e&&(this.adapter_.notifyChange(t),r&&(this.setValid(this.isValid()),this.helperText_&&this.helperText_.setValidity(this.isValid())))},MDCSelectFoundation.prototype.handleFocus=function(){this.adapter_.addClass(o.a.FOCUSED),this.adapter_.floatLabel(!0),this.notchOutline(!0),this.adapter_.activateBottomLine(),this.helperText_&&this.helperText_.showToScreenReader()},MDCSelectFoundation.prototype.handleBlur=function(){this.adapter_.isMenuOpen()||(this.adapter_.removeClass(o.a.FOCUSED),this.handleChange(!1),this.adapter_.deactivateBottomLine(),this.adapter_.hasClass(o.a.REQUIRED)&&(this.setValid(this.isValid()),this.helperText_&&this.helperText_.setValidity(this.isValid())))},MDCSelectFoundation.prototype.handleClick=function(e){this.adapter_.isMenuOpen()||(this.adapter_.setRippleCenter(e),this.adapter_.openMenu())},MDCSelectFoundation.prototype.handleKeydown=function(e){if(!this.adapter_.isMenuOpen()){var t="Enter"===e.key||13===e.keyCode,n="Space"===e.key||32===e.keyCode,r="ArrowUp"===e.key||38===e.keyCode,i="ArrowDown"===e.key||40===e.keyCode;this.adapter_.hasClass(o.a.FOCUSED)&&(t||n||r||i)&&(this.adapter_.openMenu(),e.preventDefault())}},MDCSelectFoundation.prototype.notchOutline=function(e){if(this.adapter_.hasOutline()){var t=this.adapter_.hasClass(o.a.FOCUSED);if(e){var n=o.b.LABEL_SCALE,r=this.adapter_.getLabelWidth()*n;this.adapter_.notchOutline(r)}else t||this.adapter_.closeOutline()}},MDCSelectFoundation.prototype.setLeadingIconAriaLabel=function(e){this.leadingIcon_&&this.leadingIcon_.setAriaLabel(e)},MDCSelectFoundation.prototype.setLeadingIconContent=function(e){this.leadingIcon_&&this.leadingIcon_.setContent(e)},MDCSelectFoundation.prototype.setValid=function(e){this.adapter_.setValid(e)},MDCSelectFoundation.prototype.isValid=function(){return this.adapter_.checkValidity()},MDCSelectFoundation}(i.a);t.default=a},7:function(e,t,n){"use strict";t.b=function __extends(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)},n.d(t,"a",(function(){return i})),t.c=__values,"function"==typeof Symbol&&Symbol.iterator;var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},i=function __assign(){return(i=Object.assign||function __assign(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __values(e){var t="function"==typeof Symbol&&e[Symbol.iterator],n=0;return t?t.call(e):{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}},8:function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(){function MDCFoundation(e){void 0===e&&(e={}),this.adapter_=e}return Object.defineProperty(MDCFoundation,"cssClasses",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"strings",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"numbers",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"defaultAdapter",{get:function(){return{}},enumerable:!0,configurable:!0}),MDCFoundation.prototype.init=function(){},MDCFoundation.prototype.destroy=function(){},MDCFoundation}()}})},e.exports=r(n(1),n(14),n(114),n(115),n(116),n(180))},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return u})),n.d(t,"c",(function(){return c}));var r=n(53),i=n.n(r),o=n(0),a=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"),i=document.querySelector("#wp-admin-bar-google-site-kit .googlesitekit-notifications-counter");if(r&&i)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 s=document.createElement("span");return s.setAttribute("class","screen-reader-text"),s.textContent=Object(o.sprintf)(
|
|
|
|
|
|
1 |
+
!function(e){var t={};function __webpack_require__(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}__webpack_require__.m=e,__webpack_require__.c=t,__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="",__webpack_require__(__webpack_require__.s=342)}([function(e,t,n){"use strict";function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(Object(n));"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){r(e,t,n[t])}))}return e}n.r(t);var o=n(91),a=n(87),u=n.n(a),s=n(76),c=n.n(s);n.d(t,"setLocaleData",(function(){return p})),n.d(t,"__",(function(){return __})),n.d(t,"_x",(function(){return _x})),n.d(t,"_n",(function(){return _n})),n.d(t,"_nx",(function(){return _nx})),n.d(t,"sprintf",(function(){return build_module_sprintf}));var l={"":{plural_forms:function(e){return 1===e?0:1}}},d=u()(console.error),f=new o.a({});function p(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"default";f.data[t]=i({},l,f.data[t],e),f.data[t][""]=i({},l[""],f.data[t][""])}function h(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"default",t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2?arguments[2]:void 0,r=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;return f.data[e]||p(void 0,e),f.dcnpgettext(e,t,n,r,i)}function __(e,t){return h(t,void 0,e)}function _x(e,t,n){return h(n,t,e)}function _n(e,t,n,r){return h(r,void 0,e,t,n)}function _nx(e,t,n,r,i){return h(i,r,e,t,n)}function build_module_sprintf(e){try{for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return c.a.sprintf.apply(c.a,[e].concat(n))}catch(t){return d("sprintf error: \n\n"+t.toString()),e}}},function(e,t,n){"use strict";e.exports=n(152)},function(e,t,n){e.exports=n(181)()},function(e,t,n){"use strict";(function(e){n.d(t,"u",(function(){return L})),n.d(t,"s",(function(){return N})),n.d(t,"p",(function(){return R})),n.d(t,"t",(function(){return j})),n.d(t,"i",(function(){return H})),n.d(t,"b",(function(){return B})),n.d(t,"e",(function(){return U})),n.d(t,"v",(function(){return z})),n.d(t,"m",(function(){return V})),n.d(t,"f",(function(){return W})),n.d(t,"n",(function(){return G})),n.d(t,"B",(function(){return q})),n.d(t,"C",(function(){return K})),n.d(t,"j",(function(){return X})),n.d(t,"a",(function(){return Y})),n.d(t,"z",(function(){return Z})),n.d(t,"x",(function(){return J})),n.d(t,"d",(function(){return ee})),n.d(t,"g",(function(){return te})),n.d(t,"h",(function(){return ne})),n.d(t,"r",(function(){return re})),n.d(t,"y",(function(){return ie})),n.d(t,"k",(function(){return oe}));var r=n(64),i=n.n(r),o=n(21),a=n.n(o),u=n(11),s=n.n(u),c=n(73),l=n.n(c),d=n(38),f=n.n(d),p=n(13),h=n(10),_=n(24),m=n(1),g=n.n(m),y=n(52),v=n(12),b=n(0),C=n(45),E=n(90),O=n(98),T=n(134),S=n(135),x=n(39),M=n(55);n.d(t,"A",(function(){return M.c}));var I=n(72);n.d(t,"w",(function(){return I.a}));var w=n(89);n.d(t,"c",(function(){return w.b})),n.d(t,"l",(function(){return w.c}));var D=n(121);n.d(t,"o",(function(){return D.a}));var k=n(122);function A(e,t){var n=Object.keys(e);return Object.getOwnPropertySymbols&&n.push.apply(n,Object.getOwnPropertySymbols(e)),t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n}function F(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?A(n,!0).forEach((function(t){a()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):A(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}n.d(t,"q",(function(){return k.a}));var L=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 N(e,{style:"currency",currency:t});var n={minimumFractionDigits:1,maximumFractionDigits:1};switch(!0){case 1e6<e:return Object(b.sprintf)(// translators: %s: an abbreviated number in millions.
|
2 |
+
Object(b.__)("%sM","google-site-kit"),N(e/1e6,n));case 99e3<e:return Object(b.sprintf)(// translators: %s: an abbreviated number in thousands.
|
3 |
+
Object(b.__)("%sK","google-site-kit"),N(Math.round(e/1e3)));case 1e3<e:return Object(b.sprintf)(// translators: %s: an abbreviated number in thousands.
|
4 |
+
Object(b.__)("%sK","google-site-kit"),N(e/1e3,n));default:return 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,i=l()(t,["locale"]);return new Intl.NumberFormat(r,i).format(e)},P=function(){var t=Object(p.get)(e,["googlesitekit","locale","","lang"]);return t?t.replace("_","-"):e.navigator.language},R=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}},j=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()},H=function(e,t){var n=1e3*R("day"),r=e.getTime(),i=t.getTime();return Math.round(Math.abs(r-i)/n)},B=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},U=function(e,t){return Object(p.map)(e,(function(e,n){return[e[0],e[t]||(0===n?"":0)]}))},z=function(){var t,n;return s.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,s.a.awrap(h.c.get(h.a,"user","authentication"));case 3:t=r.sent,n=t.grantedScopes.filter((function(e){return-1!==t.requiredScopes.indexOf(e)})),e.googlesitekit.setup=e.googlesitekit.setup||{},e.googlesitekit.setup.isAuthenticated=t.isAuthenticated,e.googlesitekit.setup.requiredScopes=t.requiredScopes,e.googlesitekit.setup.grantedScopes=t.grantedScopes,e.googlesitekit.setup.needReauthenticate=n.length<t.requiredScopes.length,r.next=14;break;case 12:r.prev=12,r.t0=r.catch(0);case 14:case"end":return r.stop()}}),null,null,[[0,12]])},V=function(t,n){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e.googlesitekit,i=r.admin,o=i.connectURL,a=i.adminRoot,u=r.setup.needReauthenticate,s=r.modules[t].screenID,c="pagespeed-insights"===t?{notification:"authentication_success",reAuth:void 0}:{},l=Object(C.a)(a,F({page:t&&n&&s?s:"googlesitekit-dashboard",slug:t,reAuth:n},c));if(!u)return l;var d=encodeURIComponent(Object(E.a)(l));return l=a+"?"+d,Object(C.a)(o,{redirect:l,status:n})},W=function(e,t){return function(n){return function InnerComponent(r){return g.a.createElement(e,i()({},r,t,{OriginalComponent:n}))}}},G=function(t,n){var r=e.googlesitekit.admin.adminRoot;return t||(t="googlesitekit-dashboard"),n=F({page:t},n),Object(C.a)(r,n)},q=function(e){try{return JSON.parse(e)&&!!e}catch(e){return!1}},K=function(e){return e.match(/^GTM-[a-zA-Z\d]{7}$/)},X=function(t){var n,r,i,o,a;return s.a.async((function(u){for(;;)switch(u.prev=u.next){case 0:return n=e.googlesitekit.admin,r=n.homeURL,i=n.ampMode,o={tagverify:1,timestamp:Date.now()},u.next=4,s.a.awrap(Q(Object(C.a)(r,o),t));case 4:if((a=u.sent)||"secondary"!==i){u.next=9;break}return u.next=8,s.a.awrap(Object(y.default)({path:"/wp/v2/posts?per_page=1"}).then((function(e){return e.slice(0,1).map((function(e){return s.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:return n.next=2,s.a.awrap(Q(Object(C.a)(e.link,F({},o,{amp:1})),t));case 2:return n.abrupt("return",n.sent);case 3:case"end":return n.stop()}}))})).pop()})));case 8:a=u.sent;case 9:return u.abrupt("return",Promise.resolve(a||null));case 10:case"end":return u.stop()}}))},Q=function(e,t){var n;return s.a.async((function(r){for(;;)switch(r.prev=r.next){case 0:return r.prev=0,r.next=3,s.a.awrap(fetch(e,{credentials:"omit"}).then((function(e){return e.text()})));case 3:return n=r.sent,r.abrupt("return",$(n,t)||null);case 7:return r.prev=7,r.t0=r.catch(0),r.abrupt("return",null);case 10:case"end":return r.stop()}}),null,null,[[0,7]])},$=function(e,t){var n=({adsense:T.a,analytics:S.a,tagmanager:x.d,setup:O.b}[t]||[]).find((function(t){return t.test(e)}));return!!n&&n.exec(e)[1]},Y=function(t,n,r){return t.setModuleActive(n,r).then((function(t){return e.googlesitekit.modules&&e.googlesitekit.modules[n]&&(e.googlesitekit.modules[n].active=t.active),Object(M.c)("".concat(n,"_setup"),t.active?"module_activate":"module_deactivate",n),new Promise((function(e){e(t)}))}))},Z=function(t,n,r){var i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:e.googlesitekit,a=o.modules[t],u=a.settings,s=a.setupComplete,c=i||document.getElementById("confirm-changes-".concat(t));if(s&&c){var l=!!Object.keys(n).find((function(e){var t=n[e];return!Object(p.isEqual)(r[e],u[t])}));return i||(c.disabled=!l),l}},J=function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};Object(v.b)("googlesitekit.ErrorNotification","googlesitekit.ErrorNotification",W(e,t),1)},ee=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 te(){var e=Object(v.c)("googlesitekit.dateRange","last-28-days").match(/last-(\d+)-days/);if(e&&e[1])return Object(b.sprintf)(Object(b._n)("%s day","%s days",parseInt(e[1],10),"google-site-kit"),e[1]);throw new Error("Unrecognized date range slug used in `googlesitekit.dateRange`.")}function ne(){return Object(v.c)("googlesitekit.dateRange","last-28-days")}function re(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.googlesitekit){var a=g.a.createElement(_.a,{id:t,width:r,height:i,className:o});return n?a=g.a.createElement(_.a,{id:"".concat(t,"-disabled"),width:r,height:i,className:o}):"pagespeed-insights"===t&&(a=g.a.createElement("img",{src:e.googlesitekit.admin.assetsRoot+"images/icon-pagespeed.png",width:r,alt:"",className:o})),a}}function ie(e){var t={};return Object.keys(e).sort().forEach((function(n){var r=e[n];r&&"object"===f()(r)&&!Array.isArray(r)&&(r=ie(r)),t[n]=r})),t}function oe(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e._googlesitekitBaseData,r=n.blogPrefix;return n.isNetworkMode?t:r+t}}).call(this,n(15))},,function(e,t){e.exports=function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}},function(e,t){function n(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}e.exports=function(e,t,r){return t&&n(e.prototype,t),r&&n(e,r),e}},function(e,t,n){var r=n(38),i=n(16);e.exports=function(e,t){return!t||"object"!==r(t)&&"function"!=typeof t?i(e):t}},function(e,t){function n(t){return e.exports=n=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)},n(t)}e.exports=n},function(e,t,n){var r=n(180);e.exports=function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&r(e,t)}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return y})),n.d(t,"b",(function(){return v}));var r=n(21),i=n.n(r),o=n(38),a=n.n(o),u=n(81),s=n(133),c=n(99),l=n.n(c),d=n(3),f=n(13),p=n(52),h=n(45),_=n(12);function m(e,t){var n=Object.keys(e);return Object.getOwnPropertySymbols&&n.push.apply(n,Object.getOwnPropertySymbols(e)),t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n}function g(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?m(n,!0).forEach((function(t){i()(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):m(n).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}var y="core",v="modules",b=function(){e.googlesitekit.admin=e.googlesitekit.admin||{},"string"==typeof e.googlesitekit.admin.datacache&&(e.googlesitekit.admin.datacache=JSON.parse(e.googlesitekit.admin.datacache)),"object"!==a()(e.googlesitekit.admin.datacache)&&(e.googlesitekit.admin.datacache={})},C=function(e,t){var n=g({data:{}},e);return n.data=g({dateRange:t},n.data),n},E={maxRequests:10,init:function(){Object(_.a)("googlesitekit.moduleLoaded","googlesitekit.collectModuleListingData",this.collectModuleData.bind(this))},combinedGetFromCache:function(e){var t=this;return new Promise((function(n,r){try{var i=[],o=Object(d.h)();Object(f.each)(e,(function(e){var n=C(e,o);n.key=t.getCacheKey(n.type,n.identifier,n.datapoint,n.data);var r=t.getCache(n.key,n.maxAge);void 0!==r&&(i[n.key]=r,t.resolve(n,r))})),n(i)}catch(e){r()}}))},combinedGet:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=[],i=25,o=Object(d.h)();Object(f.each)(e,(function(e){var n=C(e,o);n.key=t.getCacheKey(n.type,n.identifier,n.datapoint,n.data);var a=t.getCache(n.key,n.maxAge);void 0!==a?(setTimeout((function(){t.resolve(n,a)}),i),i+=25):r.push(n)})),r=Object(f.sortBy)(r,"priority");var a=[],u=[],s={},c=!!r.find((function(e){return e.priority<10}));Object(f.each)(r,(function(e,t){!n&&10<=e.priority&&c?u.push(e):s[e.key]?s[e.key].push(t):(s[e.key]=[t],a.push(e))}));var l=10,m=a.slice(0,l),g=a.slice(l);if(g=g.concat(u),0!==m.length||0!==g.length){0<g.length&&0<this.maxRequests--?setTimeout((function(){t.combinedGet(g,!0)}),50):this.maxRequests=10;var y=null!==Object(d.l)("datacache");return Object(p.default)({path:Object(h.a)("/google-site-kit/v1/data/",{datacache:y||void 0}),data:{request:m},method:"POST"}).then((function(e){Object(f.each)(e,(function(e,n){s[n]?(t.handleWPError(e),Object(f.each)(s[n],(function(n){var i=r[n];t.setCache(i.key,e),t.resolve(i,e)})),0===g.length&&Object(_.d)("googlesitekit.dataLoaded","api")):console.error("data_error","unknown response key "+n)}))})).catch((function(e){console.warn("Error caught during combinedGet",e)}))}Object(_.d)("googlesitekit.dataLoaded","cache")},handleWPError:function(e){var t=["code","data","message"],n=Object(f.intersection)(t,Object.keys(e));if(Object(f.isEqual)(t,n)){console.warn("WP Error in data response",e);var r=e.data;if(r&&r.reason){var i=0;["authError","insufficientPermissions"].includes(r.reason)&&(Object(_.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(d.f)(u.a),1),i++),"forbidden"===r.reason&&(Object(_.b)("googlesitekit.ErrorNotification","googlesitekit.AuthNotification",Object(d.f)(s.a),1),i++),i&&Object(_.b)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease",(function(e){return Object(_.f)("googlesitekit.TotalNotifications","googlesitekit.AuthCountIncrease"),e+i}))}}},resolve:function(e,t){e&&"function"==typeof e.callback&&e.callback(t,e.datapoint)},setCache:function(t,n){if(void 0!==n&&(!n||"object"!==a()(n)||!n.error&&!n.errors)){b(),e.googlesitekit.admin.datacache[t]=Object(f.cloneDeep)(n);var r={value:n,date:Date.now()/1e3};Object(d.o)().setItem("googlesitekit_"+t,JSON.stringify(r))}},getCache:function(t,n){if(!e.googlesitekit.admin.nojscache){if(b(),void 0!==e.googlesitekit.admin.datacache[t])return e.googlesitekit.admin.datacache[t];var r=JSON.parse(Object(d.o)().getItem("googlesitekit_"+t));return r&&"object"===a()(r)&&r.date&&(!n||Date.now()/1e3-r.date<n)?(e.googlesitekit.admin.datacache[t]=Object(f.cloneDeep)(r.value),Object(f.cloneDeep)(e.googlesitekit.admin.datacache[t])):void 0}},deleteCache:function(t){b(),delete e.googlesitekit.admin.datacache[t],Object(d.o)().removeItem("googlesitekit_"+t)},invalidateCacheGroup:function(t,n,r){var i=this.getCacheKey(t,n,r);b(),Object.keys(e.googlesitekit.admin.datacache).forEach((function(t){0!==t.indexOf(i+"::")&&t!==i||delete e.googlesitekit.admin.datacache[t]})),Object.keys(Object(d.o)()).forEach((function(e){0!==e.indexOf("googlesitekit_".concat(i,"::"))&&e!=="googlesitekit_".concat(i)||Object(d.o)().removeItem(e)}))},collectModuleData:function(e,t){var n=Object(_.c)("googlesitekit.module"+e+"DataRequest",[],t);0!==n.length&&this.combinedGet(n)},get:function(e,t,n){var r=this,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},o=!(arguments.length>4&&void 0!==arguments[4])||arguments[4],a=this.getCacheKey(e,t,n,i);if(!o){var u=this.getCache(a,3600);if(void 0!==u)return new Promise((function(e){e(u)}))}return Object(p.default)({path:Object(h.a)("/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),i)}).then((function(e){return o||r.setCache(a,e),Promise.resolve(e)})).catch((function(e){return r.handleWPError(e),Promise.reject(e)}))},set:function(e,t,n,r){var i={};return i.data=r,Object(p.default)({path:"/google-site-kit/v1/".concat(e,"/").concat(t,"/data/").concat(n),data:i,method:"POST"}).then((function(r){return E.invalidateCacheGroup(e,t,n),new Promise((function(e){e(r)}))}))},getCacheKey:function(e,t,n){for(var r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,i=[],o=[e,t,n],u=0,s=o;u<s.length;u++){var c=s[u];if(!c||!c.length)break;i.push(c)}return 3===i.length&&r&&"object"===a()(r)&&Object.keys(r).length&&i.push(l()(JSON.stringify(Object(d.y)(r)))),i.join("::")},setModuleActive:function(e,t){return this.set(y,"modules","activation",{slug:e,active:t})}};E.init(),t.c=E}).call(this,n(15))},function(e,t,n){e.exports=n(139)},function(e,t,n){"use strict";var r=function(e){return"string"!=typeof e||""===e?(console.error("The namespace must be a non-empty string."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.\-\/]*$/.test(e)||(console.error("The namespace can only contain numbers, letters, dashes, periods, underscores and slashes."),!1)};var i=function(e){return"string"!=typeof e||""===e?(console.error("The hook name must be a non-empty string."),!1):/^__/.test(e)?(console.error("The hook name cannot begin with `__`."),!1):!!/^[a-zA-Z][a-zA-Z0-9_.-]*$/.test(e)||(console.error("The hook name can only contain numbers, letters, dashes, periods and underscores."),!1)};var o=function(e){return function(t,n,o){var a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:10;if(i(t)&&r(n))if("function"==typeof o)if("number"==typeof a){var u={callback:o,priority:a,namespace:n};if(e[t]){var s,c=e[t].handlers;for(s=c.length;s>0&&!(a>=c[s-1].priority);s--);s===c.length?c[s]=u:c.splice(s,0,u),(e.__current||[]).forEach((function(e){e.name===t&&e.currentIndex>=s&&e.currentIndex++}))}else e[t]={handlers:[u],runs:0};"hookAdded"!==t&&y("hookAdded",t,n,o,a)}else console.error("If specified, the hook priority must be a number.");else console.error("The hook callback must be a function.")}};var a=function(e,t){return function(n,o){if(i(n)&&(t||r(o))){if(!e[n])return 0;var a=0;if(t)a=e[n].handlers.length,e[n]={runs:e[n].runs,handlers:[]};else for(var u=e[n].handlers,s=function(t){u[t].namespace===o&&(u.splice(t,1),a++,(e.__current||[]).forEach((function(e){e.name===n&&e.currentIndex>=t&&e.currentIndex--})))},c=u.length-1;c>=0;c--)s(c);return"hookRemoved"!==n&&y("hookRemoved",n,o),a}}};var u=function(e){return function(t,n){return void 0!==n?t in e&&e[t].handlers.some((function(e){return e.namespace===n})):t in e}};var s=function(e,t){return function(n){e[n]||(e[n]={handlers:[],runs:0}),e[n].runs++;var r=e[n].handlers;for(var i=arguments.length,o=new Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];if(!r||!r.length)return t?o[0]:void 0;var u={name:n,currentIndex:0};for(e.__current.push(u);u.currentIndex<r.length;){var s=r[u.currentIndex],c=s.callback.apply(null,o);t&&(o[0]=c),u.currentIndex++}return e.__current.pop(),t?o[0]:void 0}};var c=function(e){return function(){return e.__current&&e.__current.length?e.__current[e.__current.length-1].name:null}};var l=function(e){return function(t){return void 0===t?void 0!==e.__current[0]:!!e.__current[0]&&t===e.__current[0].name}};var d=function(e){return function(t){if(i(t))return e[t]&&e[t].runs?e[t].runs:0}};var f=function(){var e=Object.create(null),t=Object.create(null);return e.__current=[],t.__current=[],{addAction:o(e),addFilter:o(t),removeAction:a(e),removeFilter:a(t),hasAction:u(e),hasFilter:u(t),removeAllActions:a(e,!0),removeAllFilters:a(t,!0),doAction:s(e),applyFilters:s(t,!0),currentAction:c(e),currentFilter:c(t),doingAction:l(e),doingFilter:l(t),didAction:d(e),didFilter:d(t),actions:e,filters:t}};n.d(t,"a",(function(){return h})),n.d(t,"b",(function(){return _})),n.d(t,"e",(function(){return m})),n.d(t,"f",(function(){return g})),n.d(t,"d",(function(){return y})),n.d(t,"c",(function(){return v}));var p=f(),h=p.addAction,_=p.addFilter,m=p.removeAction,g=p.removeFilter,y=(p.hasAction,p.hasFilter,p.removeAllActions,p.removeAllFilters,p.doAction),v=p.applyFilters;p.currentAction,p.currentFilter,p.doingAction,p.doingFilter,p.didAction,p.didFilter,p.actions,p.filters},function(e,t,n){(function(e,n){(function(){var r,i=200,o="Unsupported core-js use. Try https://npms.io/search?q=ponyfill.",a="Expected a function",u="__lodash_hash_undefined__",s=500,c="__lodash_placeholder__",l=1,d=2,f=4,p=1,h=2,_=1,m=2,g=4,y=8,v=16,b=32,C=64,E=128,O=256,T=512,S=30,x="...",M=800,I=16,w=1,D=2,k=1/0,A=9007199254740991,F=17976931348623157e292,L=NaN,N=4294967295,P=N-1,R=N>>>1,j=[["ary",E],["bind",_],["bindKey",m],["curry",y],["curryRight",v],["flip",T],["partial",b],["partialRight",C],["rearg",O]],H="[object Arguments]",B="[object Array]",U="[object AsyncFunction]",z="[object Boolean]",V="[object Date]",W="[object DOMException]",G="[object Error]",q="[object Function]",K="[object GeneratorFunction]",X="[object Map]",Q="[object Number]",$="[object Null]",Y="[object Object]",Z="[object Proxy]",J="[object RegExp]",ee="[object Set]",te="[object String]",ne="[object Symbol]",re="[object Undefined]",ie="[object WeakMap]",oe="[object WeakSet]",ae="[object ArrayBuffer]",ue="[object DataView]",se="[object Float32Array]",ce="[object Float64Array]",le="[object Int8Array]",de="[object Int16Array]",fe="[object Int32Array]",pe="[object Uint8Array]",he="[object Uint8ClampedArray]",_e="[object Uint16Array]",me="[object Uint32Array]",ge=/\b__p \+= '';/g,ye=/\b(__p \+=) '' \+/g,ve=/(__e\(.*?\)|\b__t\)) \+\n'';/g,be=/&(?:amp|lt|gt|quot|#39);/g,Ce=/[&<>"']/g,Ee=RegExp(be.source),Oe=RegExp(Ce.source),Te=/<%-([\s\S]+?)%>/g,Se=/<%([\s\S]+?)%>/g,xe=/<%=([\s\S]+?)%>/g,Me=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Ie=/^\w*$/,we=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,De=/[\\^$.*+?()[\]{}|]/g,ke=RegExp(De.source),Ae=/^\s+|\s+$/g,Fe=/^\s+/,Le=/\s+$/,Ne=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Pe=/\{\n\/\* \[wrapped with (.+)\] \*/,Re=/,? & /,je=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,He=/\\(\\)?/g,Be=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ue=/\w*$/,ze=/^[-+]0x[0-9a-f]+$/i,Ve=/^0b[01]+$/i,We=/^\[object .+?Constructor\]$/,Ge=/^0o[0-7]+$/i,qe=/^(?:0|[1-9]\d*)$/,Ke=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Xe=/($^)/,Qe=/['\n\r\u2028\u2029\\]/g,$e="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",Ye="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ze="[\\ud800-\\udfff]",Je="["+Ye+"]",et="["+$e+"]",tt="\\d+",nt="[\\u2700-\\u27bf]",rt="[a-z\\xdf-\\xf6\\xf8-\\xff]",it="[^\\ud800-\\udfff"+Ye+tt+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",ot="\\ud83c[\\udffb-\\udfff]",at="[^\\ud800-\\udfff]",ut="(?:\\ud83c[\\udde6-\\uddff]){2}",st="[\\ud800-\\udbff][\\udc00-\\udfff]",ct="[A-Z\\xc0-\\xd6\\xd8-\\xde]",lt="(?:"+rt+"|"+it+")",dt="(?:"+ct+"|"+it+")",ft="(?:"+et+"|"+ot+")"+"?",pt="[\\ufe0e\\ufe0f]?"+ft+("(?:\\u200d(?:"+[at,ut,st].join("|")+")[\\ufe0e\\ufe0f]?"+ft+")*"),ht="(?:"+[nt,ut,st].join("|")+")"+pt,_t="(?:"+[at+et+"?",et,ut,st,Ze].join("|")+")",mt=RegExp("['’]","g"),gt=RegExp(et,"g"),yt=RegExp(ot+"(?="+ot+")|"+_t+pt,"g"),vt=RegExp([ct+"?"+rt+"+(?:['’](?:d|ll|m|re|s|t|ve))?(?="+[Je,ct,"$"].join("|")+")",dt+"+(?:['’](?:D|LL|M|RE|S|T|VE))?(?="+[Je,ct+lt,"$"].join("|")+")",ct+"?"+lt+"+(?:['’](?:d|ll|m|re|s|t|ve))?",ct+"+(?:['’](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",tt,ht].join("|"),"g"),bt=RegExp("[\\u200d\\ud800-\\udfff"+$e+"\\ufe0e\\ufe0f]"),Ct=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Et=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Ot=-1,Tt={};Tt[se]=Tt[ce]=Tt[le]=Tt[de]=Tt[fe]=Tt[pe]=Tt[he]=Tt[_e]=Tt[me]=!0,Tt[H]=Tt[B]=Tt[ae]=Tt[z]=Tt[ue]=Tt[V]=Tt[G]=Tt[q]=Tt[X]=Tt[Q]=Tt[Y]=Tt[J]=Tt[ee]=Tt[te]=Tt[ie]=!1;var St={};St[H]=St[B]=St[ae]=St[ue]=St[z]=St[V]=St[se]=St[ce]=St[le]=St[de]=St[fe]=St[X]=St[Q]=St[Y]=St[J]=St[ee]=St[te]=St[ne]=St[pe]=St[he]=St[_e]=St[me]=!0,St[G]=St[q]=St[ie]=!1;var xt={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Mt=parseFloat,It=parseInt,wt="object"==typeof e&&e&&e.Object===Object&&e,Dt="object"==typeof self&&self&&self.Object===Object&&self,kt=wt||Dt||Function("return this")(),At=t&&!t.nodeType&&t,Ft=At&&"object"==typeof n&&n&&!n.nodeType&&n,Lt=Ft&&Ft.exports===At,Nt=Lt&&wt.process,Pt=function(){try{var e=Ft&&Ft.require&&Ft.require("util").types;return e||Nt&&Nt.binding&&Nt.binding("util")}catch(e){}}(),Rt=Pt&&Pt.isArrayBuffer,jt=Pt&&Pt.isDate,Ht=Pt&&Pt.isMap,Bt=Pt&&Pt.isRegExp,Ut=Pt&&Pt.isSet,zt=Pt&&Pt.isTypedArray;function Vt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function Wt(e,t,n,r){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(r,a,n(a),e)}return r}function Gt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function qt(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function Kt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function Xt(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function Qt(e,t){return!!(null==e?0:e.length)&&an(e,t,0)>-1}function $t(e,t,n){for(var r=-1,i=null==e?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function Yt(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function Zt(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function Jt(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}function en(e,t,n,r){var i=null==e?0:e.length;for(r&&i&&(n=e[--i]);i--;)n=t(n,e[i],i,e);return n}function tn(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var nn=ln("length");function rn(e,t,n){var r;return n(e,(function(e,n,i){if(t(e,n,i))return r=n,!1})),r}function on(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o<i;)if(t(e[o],o,e))return o;return-1}function an(e,t,n){return t==t?function(e,t,n){var r=n-1,i=e.length;for(;++r<i;)if(e[r]===t)return r;return-1}(e,t,n):on(e,sn,n)}function un(e,t,n,r){for(var i=n-1,o=e.length;++i<o;)if(r(e[i],t))return i;return-1}function sn(e){return e!=e}function cn(e,t){var n=null==e?0:e.length;return n?pn(e,t)/n:L}function ln(e){return function(t){return null==t?r:t[e]}}function dn(e){return function(t){return null==e?r:e[t]}}function fn(e,t,n,r,i){return i(e,(function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)})),n}function pn(e,t){for(var n,i=-1,o=e.length;++i<o;){var a=t(e[i]);a!==r&&(n=n===r?a:n+a)}return n}function hn(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function _n(e){return function(t){return e(t)}}function mn(e,t){return Yt(t,(function(t){return e[t]}))}function gn(e,t){return e.has(t)}function yn(e,t){for(var n=-1,r=e.length;++n<r&&an(t,e[n],0)>-1;);return n}function vn(e,t){for(var n=e.length;n--&&an(t,e[n],0)>-1;);return n}var bn=dn({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),Cn=dn({"&":"&","<":"<",">":">",'"':""","'":"'"});function En(e){return"\\"+xt[e]}function On(e){return bt.test(e)}function Tn(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Sn(e,t){return function(n){return e(t(n))}}function xn(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n];a!==t&&a!==c||(e[n]=c,o[i++]=n)}return o}function Mn(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function In(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}function wn(e){return On(e)?function(e){var t=yt.lastIndex=0;for(;yt.test(e);)++t;return t}(e):nn(e)}function Dn(e){return On(e)?function(e){return e.match(yt)||[]}(e):function(e){return e.split("")}(e)}var kn=dn({"&":"&","<":"<",">":">",""":'"',"'":"'"});var An=function e(t){var n,$e=(t=null==t?kt:An.defaults(kt.Object(),t,An.pick(kt,Et))).Array,Ye=t.Date,Ze=t.Error,Je=t.Function,et=t.Math,tt=t.Object,nt=t.RegExp,rt=t.String,it=t.TypeError,ot=$e.prototype,at=Je.prototype,ut=tt.prototype,st=t["__core-js_shared__"],ct=at.toString,lt=ut.hasOwnProperty,dt=0,ft=(n=/[^.]+$/.exec(st&&st.keys&&st.keys.IE_PROTO||""))?"Symbol(src)_1."+n:"",pt=ut.toString,ht=ct.call(tt),_t=kt._,yt=nt("^"+ct.call(lt).replace(De,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),bt=Lt?t.Buffer:r,xt=t.Symbol,wt=t.Uint8Array,Dt=bt?bt.allocUnsafe:r,At=Sn(tt.getPrototypeOf,tt),Ft=tt.create,Nt=ut.propertyIsEnumerable,Pt=ot.splice,nn=xt?xt.isConcatSpreadable:r,dn=xt?xt.iterator:r,Fn=xt?xt.toStringTag:r,Ln=function(){try{var e=Ao(tt,"defineProperty");return e({},"",{}),e}catch(e){}}(),Nn=t.clearTimeout!==kt.clearTimeout&&t.clearTimeout,Pn=Ye&&Ye.now!==kt.Date.now&&Ye.now,Rn=t.setTimeout!==kt.setTimeout&&t.setTimeout,jn=et.ceil,Hn=et.floor,Bn=tt.getOwnPropertySymbols,Un=bt?bt.isBuffer:r,zn=t.isFinite,Vn=ot.join,Wn=Sn(tt.keys,tt),Gn=et.max,qn=et.min,Kn=Ye.now,Xn=t.parseInt,Qn=et.random,$n=ot.reverse,Yn=Ao(t,"DataView"),Zn=Ao(t,"Map"),Jn=Ao(t,"Promise"),er=Ao(t,"Set"),tr=Ao(t,"WeakMap"),nr=Ao(tt,"create"),rr=tr&&new tr,ir={},or=ia(Yn),ar=ia(Zn),ur=ia(Jn),sr=ia(er),cr=ia(tr),lr=xt?xt.prototype:r,dr=lr?lr.valueOf:r,fr=lr?lr.toString:r;function pr(e){if(Cu(e)&&!lu(e)&&!(e instanceof LazyWrapper)){if(e instanceof LodashWrapper)return e;if(lt.call(e,"__wrapped__"))return oa(e)}return new LodashWrapper(e)}var hr=function(){function e(){}return function(t){if(!bu(t))return{};if(Ft)return Ft(t);e.prototype=t;var n=new e;return e.prototype=r,n}}();function _r(){}function LodashWrapper(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=r}function LazyWrapper(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=N,this.__views__=[]}function Hash(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function ListCache(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function MapCache(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function SetCache(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new MapCache;++t<n;)this.add(e[t])}function Stack(e){var t=this.__data__=new ListCache(e);this.size=t.size}function mr(e,t){var n=lu(e),r=!n&&cu(e),i=!n&&!r&&hu(e),o=!n&&!r&&!i&&wu(e),a=n||r||i||o,u=a?hn(e.length,rt):[],s=u.length;for(var c in e)!t&&!lt.call(e,c)||a&&("length"==c||i&&("offset"==c||"parent"==c)||o&&("buffer"==c||"byteLength"==c||"byteOffset"==c)||Ho(c,s))||u.push(c);return u}function gr(e){var t=e.length;return t?e[hi(0,t-1)]:r}function yr(e,t){return ta(Qi(e),Mr(t,0,e.length))}function vr(e){return ta(Qi(e))}function br(e,t,n){(n===r||au(e[t],n))&&(n!==r||t in e)||Sr(e,t,n)}function Cr(e,t,n){var i=e[t];lt.call(e,t)&&au(i,n)&&(n!==r||t in e)||Sr(e,t,n)}function Er(e,t){for(var n=e.length;n--;)if(au(e[n][0],t))return n;return-1}function Or(e,t,n,r){return Ar(e,(function(e,i,o){t(r,e,n(e),o)})),r}function Tr(e,t){return e&&$i(t,Yu(t),e)}function Sr(e,t,n){"__proto__"==t&&Ln?Ln(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function xr(e,t){for(var n=-1,i=t.length,o=$e(i),a=null==e;++n<i;)o[n]=a?r:qu(e,t[n]);return o}function Mr(e,t,n){return e==e&&(n!==r&&(e=e<=n?e:n),t!==r&&(e=e>=t?e:t)),e}function Ir(e,t,n,i,o,a){var u,s=t&l,c=t&d,p=t&f;if(n&&(u=o?n(e,i,o,a):n(e)),u!==r)return u;if(!bu(e))return e;var h=lu(e);if(h){if(u=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&<.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!s)return Qi(e,u)}else{var _=No(e),m=_==q||_==K;if(hu(e))return Vi(e,s);if(_==Y||_==H||m&&!o){if(u=c||m?{}:Ro(e),!s)return c?function(e,t){return $i(e,Lo(e),t)}(e,function(e,t){return e&&$i(t,Zu(t),e)}(u,e)):function(e,t){return $i(e,Fo(e),t)}(e,Tr(u,e))}else{if(!St[_])return o?e:{};u=function(e,t,n){var r=e.constructor;switch(t){case ae:return Wi(e);case z:case V:return new r(+e);case ue:return function(e,t){var n=t?Wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case se:case ce:case le:case de:case fe:case pe:case he:case _e:case me:return Gi(e,n);case X:return new r;case Q:case te:return new r(e);case J:return function(e){var t=new e.constructor(e.source,Ue.exec(e));return t.lastIndex=e.lastIndex,t}(e);case ee:return new r;case ne:return i=e,dr?tt(dr.call(i)):{}}var i}(e,_,s)}}a||(a=new Stack);var g=a.get(e);if(g)return g;a.set(e,u),xu(e)?e.forEach((function(r){u.add(Ir(r,t,n,r,e,a))})):Eu(e)&&e.forEach((function(r,i){u.set(i,Ir(r,t,n,i,e,a))}));var y=h?r:(p?c?So:To:c?Zu:Yu)(e);return Gt(y||e,(function(r,i){y&&(r=e[i=r]),Cr(u,i,Ir(r,t,n,i,e,a))})),u}function wr(e,t,n){var i=n.length;if(null==e)return!i;for(e=tt(e);i--;){var o=n[i],a=t[o],u=e[o];if(u===r&&!(o in e)||!a(u))return!1}return!0}function Dr(e,t,n){if("function"!=typeof e)throw new it(a);return Yo((function(){e.apply(r,n)}),t)}function kr(e,t,n,r){var o=-1,a=Qt,u=!0,s=e.length,c=[],l=t.length;if(!s)return c;n&&(t=Yt(t,_n(n))),r?(a=$t,u=!1):t.length>=i&&(a=gn,u=!1,t=new SetCache(t));e:for(;++o<s;){var d=e[o],f=null==n?d:n(d);if(d=r||0!==d?d:0,u&&f==f){for(var p=l;p--;)if(t[p]===f)continue e;c.push(d)}else a(t,f,r)||c.push(d)}return c}pr.templateSettings={escape:Te,evaluate:Se,interpolate:xe,variable:"",imports:{_:pr}},pr.prototype=_r.prototype,pr.prototype.constructor=pr,LodashWrapper.prototype=hr(_r.prototype),LodashWrapper.prototype.constructor=LodashWrapper,LazyWrapper.prototype=hr(_r.prototype),LazyWrapper.prototype.constructor=LazyWrapper,Hash.prototype.clear=function(){this.__data__=nr?nr(null):{},this.size=0},Hash.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Hash.prototype.get=function(e){var t=this.__data__;if(nr){var n=t[e];return n===u?r:n}return lt.call(t,e)?t[e]:r},Hash.prototype.has=function(e){var t=this.__data__;return nr?t[e]!==r:lt.call(t,e)},Hash.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=nr&&t===r?u:t,this},ListCache.prototype.clear=function(){this.__data__=[],this.size=0},ListCache.prototype.delete=function(e){var t=this.__data__,n=Er(t,e);return!(n<0)&&(n==t.length-1?t.pop():Pt.call(t,n,1),--this.size,!0)},ListCache.prototype.get=function(e){var t=this.__data__,n=Er(t,e);return n<0?r:t[n][1]},ListCache.prototype.has=function(e){return Er(this.__data__,e)>-1},ListCache.prototype.set=function(e,t){var n=this.__data__,r=Er(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},MapCache.prototype.clear=function(){this.size=0,this.__data__={hash:new Hash,map:new(Zn||ListCache),string:new Hash}},MapCache.prototype.delete=function(e){var t=Do(this,e).delete(e);return this.size-=t?1:0,t},MapCache.prototype.get=function(e){return Do(this,e).get(e)},MapCache.prototype.has=function(e){return Do(this,e).has(e)},MapCache.prototype.set=function(e,t){var n=Do(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},SetCache.prototype.add=SetCache.prototype.push=function(e){return this.__data__.set(e,u),this},SetCache.prototype.has=function(e){return this.__data__.has(e)},Stack.prototype.clear=function(){this.__data__=new ListCache,this.size=0},Stack.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},Stack.prototype.get=function(e){return this.__data__.get(e)},Stack.prototype.has=function(e){return this.__data__.has(e)},Stack.prototype.set=function(e,t){var n=this.__data__;if(n instanceof ListCache){var r=n.__data__;if(!Zn||r.length<i-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new MapCache(r)}return n.set(e,t),this.size=n.size,this};var Ar=Ji(Br),Fr=Ji(Ur,!0);function Lr(e,t){var n=!0;return Ar(e,(function(e,r,i){return n=!!t(e,r,i)})),n}function Nr(e,t,n){for(var i=-1,o=e.length;++i<o;){var a=e[i],u=t(a);if(null!=u&&(s===r?u==u&&!Iu(u):n(u,s)))var s=u,c=a}return c}function Pr(e,t){var n=[];return Ar(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n}function Rr(e,t,n,r,i){var o=-1,a=e.length;for(n||(n=jo),i||(i=[]);++o<a;){var u=e[o];t>0&&n(u)?t>1?Rr(u,t-1,n,r,i):Zt(i,u):r||(i[i.length]=u)}return i}var jr=eo(),Hr=eo(!0);function Br(e,t){return e&&jr(e,t,Yu)}function Ur(e,t){return e&&Hr(e,t,Yu)}function zr(e,t){return Xt(t,(function(t){return gu(e[t])}))}function Vr(e,t){for(var n=0,i=(t=Hi(t,e)).length;null!=e&&n<i;)e=e[ra(t[n++])];return n&&n==i?e:r}function Wr(e,t,n){var r=t(e);return lu(e)?r:Zt(r,n(e))}function Gr(e){return null==e?e===r?re:$:Fn&&Fn in tt(e)?function(e){var t=lt.call(e,Fn),n=e[Fn];try{e[Fn]=r;var i=!0}catch(e){}var o=pt.call(e);i&&(t?e[Fn]=n:delete e[Fn]);return o}(e):function(e){return pt.call(e)}(e)}function qr(e,t){return e>t}function Kr(e,t){return null!=e&<.call(e,t)}function Xr(e,t){return null!=e&&t in tt(e)}function Qr(e,t,n){for(var i=n?$t:Qt,o=e[0].length,a=e.length,u=a,s=$e(a),c=1/0,l=[];u--;){var d=e[u];u&&t&&(d=Yt(d,_n(t))),c=qn(d.length,c),s[u]=!n&&(t||o>=120&&d.length>=120)?new SetCache(u&&d):r}d=e[0];var f=-1,p=s[0];e:for(;++f<o&&l.length<c;){var h=d[f],_=t?t(h):h;if(h=n||0!==h?h:0,!(p?gn(p,_):i(l,_,n))){for(u=a;--u;){var m=s[u];if(!(m?gn(m,_):i(e[u],_,n)))continue e}p&&p.push(_),l.push(h)}}return l}function $r(e,t,n){var i=null==(e=Xo(e,t=Hi(t,e)))?e:e[ra(ma(t))];return null==i?r:Vt(i,e,n)}function Yr(e){return Cu(e)&&Gr(e)==H}function Zr(e,t,n,i,o){return e===t||(null==e||null==t||!Cu(e)&&!Cu(t)?e!=e&&t!=t:function(e,t,n,i,o,a){var u=lu(e),s=lu(t),c=u?B:No(e),l=s?B:No(t),d=(c=c==H?Y:c)==Y,f=(l=l==H?Y:l)==Y,_=c==l;if(_&&hu(e)){if(!hu(t))return!1;u=!0,d=!1}if(_&&!d)return a||(a=new Stack),u||wu(e)?Eo(e,t,n,i,o,a):function(e,t,n,r,i,o,a){switch(n){case ue:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case ae:return!(e.byteLength!=t.byteLength||!o(new wt(e),new wt(t)));case z:case V:case Q:return au(+e,+t);case G:return e.name==t.name&&e.message==t.message;case J:case te:return e==t+"";case X:var u=Tn;case ee:var s=r&p;if(u||(u=Mn),e.size!=t.size&&!s)return!1;var c=a.get(e);if(c)return c==t;r|=h,a.set(e,t);var l=Eo(u(e),u(t),r,i,o,a);return a.delete(e),l;case ne:if(dr)return dr.call(e)==dr.call(t)}return!1}(e,t,c,n,i,o,a);if(!(n&p)){var m=d&<.call(e,"__wrapped__"),g=f&<.call(t,"__wrapped__");if(m||g){var y=m?e.value():e,v=g?t.value():t;return a||(a=new Stack),o(y,v,n,i,a)}}if(!_)return!1;return a||(a=new Stack),function(e,t,n,i,o,a){var u=n&p,s=To(e),c=s.length,l=To(t).length;if(c!=l&&!u)return!1;var d=c;for(;d--;){var f=s[d];if(!(u?f in t:lt.call(t,f)))return!1}var h=a.get(e);if(h&&a.get(t))return h==t;var _=!0;a.set(e,t),a.set(t,e);var m=u;for(;++d<c;){f=s[d];var g=e[f],y=t[f];if(i)var v=u?i(y,g,f,t,e,a):i(g,y,f,e,t,a);if(!(v===r?g===y||o(g,y,n,i,a):v)){_=!1;break}m||(m="constructor"==f)}if(_&&!m){var b=e.constructor,C=t.constructor;b!=C&&"constructor"in e&&"constructor"in t&&!("function"==typeof b&&b instanceof b&&"function"==typeof C&&C instanceof C)&&(_=!1)}return a.delete(e),a.delete(t),_}(e,t,n,i,o,a)}(e,t,n,i,Zr,o))}function Jr(e,t,n,i){var o=n.length,a=o,u=!i;if(null==e)return!a;for(e=tt(e);o--;){var s=n[o];if(u&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++o<a;){var c=(s=n[o])[0],l=e[c],d=s[1];if(u&&s[2]){if(l===r&&!(c in e))return!1}else{var f=new Stack;if(i)var _=i(l,d,c,e,t,f);if(!(_===r?Zr(d,l,p|h,i,f):_))return!1}}return!0}function ei(e){return!(!bu(e)||(t=e,ft&&ft in t))&&(gu(e)?yt:We).test(ia(e));var t}function ti(e){return"function"==typeof e?e:null==e?Os:"object"==typeof e?lu(e)?ui(e[0],e[1]):ai(e):As(e)}function ni(e){if(!Wo(e))return Wn(e);var t=[];for(var n in tt(e))lt.call(e,n)&&"constructor"!=n&&t.push(n);return t}function ri(e){if(!bu(e))return function(e){var t=[];if(null!=e)for(var n in tt(e))t.push(n);return t}(e);var t=Wo(e),n=[];for(var r in e)("constructor"!=r||!t&<.call(e,r))&&n.push(r);return n}function ii(e,t){return e<t}function oi(e,t){var n=-1,r=fu(e)?$e(e.length):[];return Ar(e,(function(e,i,o){r[++n]=t(e,i,o)})),r}function ai(e){var t=ko(e);return 1==t.length&&t[0][2]?qo(t[0][0],t[0][1]):function(n){return n===e||Jr(n,e,t)}}function ui(e,t){return Uo(e)&&Go(t)?qo(ra(e),t):function(n){var i=qu(n,e);return i===r&&i===t?Ku(n,e):Zr(t,i,p|h)}}function si(e,t,n,i,o){e!==t&&jr(t,(function(a,u){if(o||(o=new Stack),bu(a))!function(e,t,n,i,o,a,u){var s=Qo(e,n),c=Qo(t,n),l=u.get(c);if(l)return void br(e,n,l);var d=a?a(s,c,n+"",e,t,u):r,f=d===r;if(f){var p=lu(c),h=!p&&hu(c),_=!p&&!h&&wu(c);d=c,p||h||_?lu(s)?d=s:pu(s)?d=Qi(s):h?(f=!1,d=Vi(c,!0)):_?(f=!1,d=Gi(c,!0)):d=[]:Tu(c)||cu(c)?(d=s,cu(s)?d=Ru(s):bu(s)&&!gu(s)||(d=Ro(c))):f=!1}f&&(u.set(c,d),o(d,c,i,a,u),u.delete(c));br(e,n,d)}(e,t,u,n,si,i,o);else{var s=i?i(Qo(e,u),a,u+"",e,t,o):r;s===r&&(s=a),br(e,u,s)}}),Zu)}function ci(e,t){var n=e.length;if(n)return Ho(t+=t<0?n:0,n)?e[t]:r}function li(e,t,n){var r=-1;return t=Yt(t.length?t:[Os],_n(wo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}(oi(e,(function(e,n,i){return{criteria:Yt(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,i=e.criteria,o=t.criteria,a=i.length,u=n.length;for(;++r<a;){var s=qi(i[r],o[r]);if(s){if(r>=u)return s;var c=n[r];return s*("desc"==c?-1:1)}}return e.index-t.index}(e,t,n)}))}function di(e,t,n){for(var r=-1,i=t.length,o={};++r<i;){var a=t[r],u=Vr(e,a);n(u,a)&&vi(o,Hi(a,e),u)}return o}function fi(e,t,n,r){var i=r?un:an,o=-1,a=t.length,u=e;for(e===t&&(t=Qi(t)),n&&(u=Yt(e,_n(n)));++o<a;)for(var s=0,c=t[o],l=n?n(c):c;(s=i(u,l,s,r))>-1;)u!==e&&Pt.call(u,s,1),Pt.call(e,s,1);return e}function pi(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==o){var o=i;Ho(i)?Pt.call(e,i,1):ki(e,i)}}return e}function hi(e,t){return e+Hn(Qn()*(t-e+1))}function _i(e,t){var n="";if(!e||t<1||t>A)return n;do{t%2&&(n+=e),(t=Hn(t/2))&&(e+=e)}while(t);return n}function mi(e,t){return Zo(Ko(e,t,Os),e+"")}function gi(e){return gr(as(e))}function yi(e,t){var n=as(e);return ta(n,Mr(t,0,n.length))}function vi(e,t,n,i){if(!bu(e))return e;for(var o=-1,a=(t=Hi(t,e)).length,u=a-1,s=e;null!=s&&++o<a;){var c=ra(t[o]),l=n;if(o!=u){var d=s[c];(l=i?i(d,c,s):r)===r&&(l=bu(d)?d:Ho(t[o+1])?[]:{})}Cr(s,c,l),s=s[c]}return e}var bi=rr?function(e,t){return rr.set(e,t),e}:Os,Ci=Ln?function(e,t){return Ln(e,"toString",{configurable:!0,enumerable:!1,value:bs(t),writable:!0})}:Os;function Ei(e){return ta(as(e))}function Oi(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=$e(i);++r<i;)o[r]=e[r+t];return o}function Ti(e,t){var n;return Ar(e,(function(e,r,i){return!(n=t(e,r,i))})),!!n}function Si(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t==t&&i<=R){for(;r<i;){var o=r+i>>>1,a=e[o];null!==a&&!Iu(a)&&(n?a<=t:a<t)?r=o+1:i=o}return i}return xi(e,t,Os,n)}function xi(e,t,n,i){t=n(t);for(var o=0,a=null==e?0:e.length,u=t!=t,s=null===t,c=Iu(t),l=t===r;o<a;){var d=Hn((o+a)/2),f=n(e[d]),p=f!==r,h=null===f,_=f==f,m=Iu(f);if(u)var g=i||_;else g=l?_&&(i||p):s?_&&p&&(i||!h):c?_&&p&&!h&&(i||!m):!h&&!m&&(i?f<=t:f<t);g?o=d+1:a=d}return qn(a,P)}function Mi(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n],u=t?t(a):a;if(!n||!au(u,s)){var s=u;o[i++]=0===a?0:a}}return o}function Ii(e){return"number"==typeof e?e:Iu(e)?L:+e}function wi(e){if("string"==typeof e)return e;if(lu(e))return Yt(e,wi)+"";if(Iu(e))return fr?fr.call(e):"";var t=e+"";return"0"==t&&1/e==-k?"-0":t}function Di(e,t,n){var r=-1,o=Qt,a=e.length,u=!0,s=[],c=s;if(n)u=!1,o=$t;else if(a>=i){var l=t?null:mo(e);if(l)return Mn(l);u=!1,o=gn,c=new SetCache}else c=t?[]:s;e:for(;++r<a;){var d=e[r],f=t?t(d):d;if(d=n||0!==d?d:0,u&&f==f){for(var p=c.length;p--;)if(c[p]===f)continue e;t&&c.push(f),s.push(d)}else o(c,f,n)||(c!==s&&c.push(f),s.push(d))}return s}function ki(e,t){return null==(e=Xo(e,t=Hi(t,e)))||delete e[ra(ma(t))]}function Ai(e,t,n,r){return vi(e,t,n(Vr(e,t)),r)}function Fi(e,t,n,r){for(var i=e.length,o=r?i:-1;(r?o--:++o<i)&&t(e[o],o,e););return n?Oi(e,r?0:o,r?o+1:i):Oi(e,r?o+1:0,r?i:o)}function Li(e,t){var n=e;return n instanceof LazyWrapper&&(n=n.value()),Jt(t,(function(e,t){return t.func.apply(t.thisArg,Zt([e],t.args))}),n)}function Ni(e,t,n){var r=e.length;if(r<2)return r?Di(e[0]):[];for(var i=-1,o=$e(r);++i<r;)for(var a=e[i],u=-1;++u<r;)u!=i&&(o[i]=kr(o[i]||a,e[u],t,n));return Di(Rr(o,1),t,n)}function Pi(e,t,n){for(var i=-1,o=e.length,a=t.length,u={};++i<o;){var s=i<a?t[i]:r;n(u,e[i],s)}return u}function Ri(e){return pu(e)?e:[]}function ji(e){return"function"==typeof e?e:Os}function Hi(e,t){return lu(e)?e:Uo(e,t)?[e]:na(ju(e))}var Bi=mi;function Ui(e,t,n){var i=e.length;return n=n===r?i:n,!t&&n>=i?e:Oi(e,t,n)}var zi=Nn||function(e){return kt.clearTimeout(e)};function Vi(e,t){if(t)return e.slice();var n=e.length,r=Dt?Dt(n):new e.constructor(n);return e.copy(r),r}function Wi(e){var t=new e.constructor(e.byteLength);return new wt(t).set(new wt(e)),t}function Gi(e,t){var n=t?Wi(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function qi(e,t){if(e!==t){var n=e!==r,i=null===e,o=e==e,a=Iu(e),u=t!==r,s=null===t,c=t==t,l=Iu(t);if(!s&&!l&&!a&&e>t||a&&u&&c&&!s&&!l||i&&u&&c||!n&&c||!o)return 1;if(!i&&!a&&!l&&e<t||l&&n&&o&&!i&&!a||s&&n&&o||!u&&o||!c)return-1}return 0}function Ki(e,t,n,r){for(var i=-1,o=e.length,a=n.length,u=-1,s=t.length,c=Gn(o-a,0),l=$e(s+c),d=!r;++u<s;)l[u]=t[u];for(;++i<a;)(d||i<o)&&(l[n[i]]=e[i]);for(;c--;)l[u++]=e[i++];return l}function Xi(e,t,n,r){for(var i=-1,o=e.length,a=-1,u=n.length,s=-1,c=t.length,l=Gn(o-u,0),d=$e(l+c),f=!r;++i<l;)d[i]=e[i];for(var p=i;++s<c;)d[p+s]=t[s];for(;++a<u;)(f||i<o)&&(d[p+n[a]]=e[i++]);return d}function Qi(e,t){var n=-1,r=e.length;for(t||(t=$e(r));++n<r;)t[n]=e[n];return t}function $i(e,t,n,i){var o=!n;n||(n={});for(var a=-1,u=t.length;++a<u;){var s=t[a],c=i?i(n[s],e[s],s,n,e):r;c===r&&(c=e[s]),o?Sr(n,s,c):Cr(n,s,c)}return n}function Yi(e,t){return function(n,r){var i=lu(n)?Wt:Or,o=t?t():{};return i(n,e,wo(r,2),o)}}function Zi(e){return mi((function(t,n){var i=-1,o=n.length,a=o>1?n[o-1]:r,u=o>2?n[2]:r;for(a=e.length>3&&"function"==typeof a?(o--,a):r,u&&Bo(n[0],n[1],u)&&(a=o<3?r:a,o=1),t=tt(t);++i<o;){var s=n[i];s&&e(t,s,i,a)}return t}))}function Ji(e,t){return function(n,r){if(null==n)return n;if(!fu(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=tt(n);(t?o--:++o<i)&&!1!==r(a[o],o,a););return n}}function eo(e){return function(t,n,r){for(var i=-1,o=tt(t),a=r(t),u=a.length;u--;){var s=a[e?u:++i];if(!1===n(o[s],s,o))break}return t}}function to(e){return function(t){var n=On(t=ju(t))?Dn(t):r,i=n?n[0]:t.charAt(0),o=n?Ui(n,1).join(""):t.slice(1);return i[e]()+o}}function no(e){return function(t){return Jt(gs(cs(t).replace(mt,"")),e,"")}}function ro(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=hr(e.prototype),r=e.apply(n,t);return bu(r)?r:n}}function io(e){return function(t,n,i){var o=tt(t);if(!fu(t)){var a=wo(n,3);t=Yu(t),n=function(e){return a(o[e],e,o)}}var u=e(t,n,i);return u>-1?o[a?t[u]:u]:r}}function oo(e){return Oo((function(t){var n=t.length,i=n,o=LodashWrapper.prototype.thru;for(e&&t.reverse();i--;){var u=t[i];if("function"!=typeof u)throw new it(a);if(o&&!s&&"wrapper"==Mo(u))var s=new LodashWrapper([],!0)}for(i=s?i:n;++i<n;){var c=Mo(u=t[i]),l="wrapper"==c?xo(u):r;s=l&&zo(l[0])&&l[1]==(E|y|b|O)&&!l[4].length&&1==l[9]?s[Mo(l[0])].apply(s,l[3]):1==u.length&&zo(u)?s[c]():s.thru(u)}return function(){var e=arguments,r=e[0];if(s&&1==e.length&&lu(r))return s.plant(r).value();for(var i=0,o=n?t[i].apply(this,e):r;++i<n;)o=t[i].call(this,o);return o}}))}function ao(e,t,n,i,o,a,u,s,c,l){var d=t&E,f=t&_,p=t&m,h=t&(y|v),g=t&T,b=p?r:ro(e);return function _(){for(var m=arguments.length,y=$e(m),v=m;v--;)y[v]=arguments[v];if(h)var C=Io(_),E=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}(y,C);if(i&&(y=Ki(y,i,o,h)),a&&(y=Xi(y,a,u,h)),m-=E,h&&m<l){var O=xn(y,C);return ho(e,t,ao,_.placeholder,n,y,O,s,c,l-m)}var T=f?n:this,S=p?T[e]:e;return m=y.length,s?y=function(e,t){var n=e.length,i=qn(t.length,n),o=Qi(e);for(;i--;){var a=t[i];e[i]=Ho(a,n)?o[a]:r}return e}(y,s):g&&m>1&&y.reverse(),d&&c<m&&(y.length=c),this&&this!==kt&&this instanceof _&&(S=b||ro(S)),S.apply(T,y)}}function uo(e,t){return function(n,r){return function(e,t,n,r){return Br(e,(function(e,i,o){t(r,n(e),i,o)})),r}(n,e,t(r),{})}}function so(e,t){return function(n,i){var o;if(n===r&&i===r)return t;if(n!==r&&(o=n),i!==r){if(o===r)return i;"string"==typeof n||"string"==typeof i?(n=wi(n),i=wi(i)):(n=Ii(n),i=Ii(i)),o=e(n,i)}return o}}function co(e){return Oo((function(t){return t=Yt(t,_n(wo())),mi((function(n){var r=this;return e(t,(function(e){return Vt(e,r,n)}))}))}))}function lo(e,t){var n=(t=t===r?" ":wi(t)).length;if(n<2)return n?_i(t,e):t;var i=_i(t,jn(e/wn(t)));return On(t)?Ui(Dn(i),0,e).join(""):i.slice(0,e)}function fo(e){return function(t,n,i){return i&&"number"!=typeof i&&Bo(t,n,i)&&(n=i=r),t=Fu(t),n===r?(n=t,t=0):n=Fu(n),function(e,t,n,r){for(var i=-1,o=Gn(jn((t-e)/(n||1)),0),a=$e(o);o--;)a[r?o:++i]=e,e+=n;return a}(t,n,i=i===r?t<n?1:-1:Fu(i),e)}}function po(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=Pu(t),n=Pu(n)),e(t,n)}}function ho(e,t,n,i,o,a,u,s,c,l){var d=t&y;t|=d?b:C,(t&=~(d?C:b))&g||(t&=~(_|m));var f=[e,t,o,d?a:r,d?u:r,d?r:a,d?r:u,s,c,l],p=n.apply(r,f);return zo(e)&&$o(p,f),p.placeholder=i,Jo(p,e,t)}function _o(e){var t=et[e];return function(e,n){if(e=Pu(e),(n=null==n?0:qn(Lu(n),292))&&zn(e)){var r=(ju(e)+"e").split("e");return+((r=(ju(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var mo=er&&1/Mn(new er([,-0]))[1]==k?function(e){return new er(e)}:Is;function go(e){return function(t){var n=No(t);return n==X?Tn(t):n==ee?In(t):function(e,t){return Yt(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function yo(e,t,n,i,o,u,s,l){var d=t&m;if(!d&&"function"!=typeof e)throw new it(a);var f=i?i.length:0;if(f||(t&=~(b|C),i=o=r),s=s===r?s:Gn(Lu(s),0),l=l===r?l:Lu(l),f-=o?o.length:0,t&C){var p=i,h=o;i=o=r}var T=d?r:xo(e),S=[e,t,n,i,o,p,h,u,s,l];if(T&&function(e,t){var n=e[1],r=t[1],i=n|r,o=i<(_|m|E),a=r==E&&n==y||r==E&&n==O&&e[7].length<=t[8]||r==(E|O)&&t[7].length<=t[8]&&n==y;if(!o&&!a)return e;r&_&&(e[2]=t[2],i|=n&_?0:g);var u=t[3];if(u){var s=e[3];e[3]=s?Ki(s,u,t[4]):u,e[4]=s?xn(e[3],c):t[4]}(u=t[5])&&(s=e[5],e[5]=s?Xi(s,u,t[6]):u,e[6]=s?xn(e[5],c):t[6]);(u=t[7])&&(e[7]=u);r&E&&(e[8]=null==e[8]?t[8]:qn(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(S,T),e=S[0],t=S[1],n=S[2],i=S[3],o=S[4],!(l=S[9]=S[9]===r?d?0:e.length:Gn(S[9]-f,0))&&t&(y|v)&&(t&=~(y|v)),t&&t!=_)x=t==y||t==v?function(e,t,n){var i=ro(e);return function o(){for(var a=arguments.length,u=$e(a),s=a,c=Io(o);s--;)u[s]=arguments[s];var l=a<3&&u[0]!==c&&u[a-1]!==c?[]:xn(u,c);return(a-=l.length)<n?ho(e,t,ao,o.placeholder,r,u,l,r,r,n-a):Vt(this&&this!==kt&&this instanceof o?i:e,this,u)}}(e,t,l):t!=b&&t!=(_|b)||o.length?ao.apply(r,S):function(e,t,n,r){var i=t&_,o=ro(e);return function t(){for(var a=-1,u=arguments.length,s=-1,c=r.length,l=$e(c+u),d=this&&this!==kt&&this instanceof t?o:e;++s<c;)l[s]=r[s];for(;u--;)l[s++]=arguments[++a];return Vt(d,i?n:this,l)}}(e,t,n,i);else var x=function(e,t,n){var r=t&_,i=ro(e);return function t(){return(this&&this!==kt&&this instanceof t?i:e).apply(r?n:this,arguments)}}(e,t,n);return Jo((T?bi:$o)(x,S),e,t)}function vo(e,t,n,i){return e===r||au(e,ut[n])&&!lt.call(i,n)?t:e}function bo(e,t,n,i,o,a){return bu(e)&&bu(t)&&(a.set(t,e),si(e,t,r,bo,a),a.delete(t)),e}function Co(e){return Tu(e)?r:e}function Eo(e,t,n,i,o,a){var u=n&p,s=e.length,c=t.length;if(s!=c&&!(u&&c>s))return!1;var l=a.get(e);if(l&&a.get(t))return l==t;var d=-1,f=!0,_=n&h?new SetCache:r;for(a.set(e,t),a.set(t,e);++d<s;){var m=e[d],g=t[d];if(i)var y=u?i(g,m,d,t,e,a):i(m,g,d,e,t,a);if(y!==r){if(y)continue;f=!1;break}if(_){if(!tn(t,(function(e,t){if(!gn(_,t)&&(m===e||o(m,e,n,i,a)))return _.push(t)}))){f=!1;break}}else if(m!==g&&!o(m,g,n,i,a)){f=!1;break}}return a.delete(e),a.delete(t),f}function Oo(e){return Zo(Ko(e,r,da),e+"")}function To(e){return Wr(e,Yu,Fo)}function So(e){return Wr(e,Zu,Lo)}var xo=rr?function(e){return rr.get(e)}:Is;function Mo(e){for(var t=e.name+"",n=ir[t],r=lt.call(ir,t)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function Io(e){return(lt.call(pr,"placeholder")?pr:e).placeholder}function wo(){var e=pr.iteratee||Ts;return e=e===Ts?ti:e,arguments.length?e(arguments[0],arguments[1]):e}function Do(e,t){var n,r,i=e.__data__;return("string"==(r=typeof(n=t))||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==n:null===n)?i["string"==typeof t?"string":"hash"]:i.map}function ko(e){for(var t=Yu(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Go(i)]}return t}function Ao(e,t){var n=function(e,t){return null==e?r:e[t]}(e,t);return ei(n)?n:r}var Fo=Bn?function(e){return null==e?[]:(e=tt(e),Xt(Bn(e),(function(t){return Nt.call(e,t)})))}:Ns,Lo=Bn?function(e){for(var t=[];e;)Zt(t,Fo(e)),e=At(e);return t}:Ns,No=Gr;function Po(e,t,n){for(var r=-1,i=(t=Hi(t,e)).length,o=!1;++r<i;){var a=ra(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&vu(i)&&Ho(a,i)&&(lu(e)||cu(e))}function Ro(e){return"function"!=typeof e.constructor||Wo(e)?{}:hr(At(e))}function jo(e){return lu(e)||cu(e)||!!(nn&&e&&e[nn])}function Ho(e,t){var n=typeof e;return!!(t=null==t?A:t)&&("number"==n||"symbol"!=n&&qe.test(e))&&e>-1&&e%1==0&&e<t}function Bo(e,t,n){if(!bu(n))return!1;var r=typeof t;return!!("number"==r?fu(n)&&Ho(t,n.length):"string"==r&&t in n)&&au(n[t],e)}function Uo(e,t){if(lu(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Iu(e))||(Ie.test(e)||!Me.test(e)||null!=t&&e in tt(t))}function zo(e){var t=Mo(e),n=pr[t];if("function"!=typeof n||!(t in LazyWrapper.prototype))return!1;if(e===n)return!0;var r=xo(n);return!!r&&e===r[0]}(Yn&&No(new Yn(new ArrayBuffer(1)))!=ue||Zn&&No(new Zn)!=X||Jn&&"[object Promise]"!=No(Jn.resolve())||er&&No(new er)!=ee||tr&&No(new tr)!=ie)&&(No=function(e){var t=Gr(e),n=t==Y?e.constructor:r,i=n?ia(n):"";if(i)switch(i){case or:return ue;case ar:return X;case ur:return"[object Promise]";case sr:return ee;case cr:return ie}return t});var Vo=st?gu:Ps;function Wo(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||ut)}function Go(e){return e==e&&!bu(e)}function qo(e,t){return function(n){return null!=n&&(n[e]===t&&(t!==r||e in tt(n)))}}function Ko(e,t,n){return t=Gn(t===r?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=Gn(r.length-t,0),a=$e(o);++i<o;)a[i]=r[t+i];i=-1;for(var u=$e(t+1);++i<t;)u[i]=r[i];return u[t]=n(a),Vt(e,this,u)}}function Xo(e,t){return t.length<2?e:Vr(e,Oi(t,0,-1))}function Qo(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var $o=ea(bi),Yo=Rn||function(e,t){return kt.setTimeout(e,t)},Zo=ea(Ci);function Jo(e,t,n){var r=t+"";return Zo(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(Ne,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return Gt(j,(function(n){var r="_."+n[0];t&n[1]&&!Qt(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(Pe);return t?t[1].split(Re):[]}(r),n)))}function ea(e){var t=0,n=0;return function(){var i=Kn(),o=I-(i-n);if(n=i,o>0){if(++t>=M)return arguments[0]}else t=0;return e.apply(r,arguments)}}function ta(e,t){var n=-1,i=e.length,o=i-1;for(t=t===r?i:t;++n<t;){var a=hi(n,o),u=e[a];e[a]=e[n],e[n]=u}return e.length=t,e}var na=function(e){var t=eu(e,(function(e){return n.size===s&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(we,(function(e,n,r,i){t.push(r?i.replace(He,"$1"):n||e)})),t}));function ra(e){if("string"==typeof e||Iu(e))return e;var t=e+"";return"0"==t&&1/e==-k?"-0":t}function ia(e){if(null!=e){try{return ct.call(e)}catch(e){}try{return e+""}catch(e){}}return""}function oa(e){if(e instanceof LazyWrapper)return e.clone();var t=new LodashWrapper(e.__wrapped__,e.__chain__);return t.__actions__=Qi(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var aa=mi((function(e,t){return pu(e)?kr(e,Rr(t,1,pu,!0)):[]})),ua=mi((function(e,t){var n=ma(t);return pu(n)&&(n=r),pu(e)?kr(e,Rr(t,1,pu,!0),wo(n,2)):[]})),sa=mi((function(e,t){var n=ma(t);return pu(n)&&(n=r),pu(e)?kr(e,Rr(t,1,pu,!0),r,n):[]}));function ca(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Lu(n);return i<0&&(i=Gn(r+i,0)),on(e,wo(t,3),i)}function la(e,t,n){var i=null==e?0:e.length;if(!i)return-1;var o=i-1;return n!==r&&(o=Lu(n),o=n<0?Gn(i+o,0):qn(o,i-1)),on(e,wo(t,3),o,!0)}function da(e){return(null==e?0:e.length)?Rr(e,1):[]}function fa(e){return e&&e.length?e[0]:r}var pa=mi((function(e){var t=Yt(e,Ri);return t.length&&t[0]===e[0]?Qr(t):[]})),ha=mi((function(e){var t=ma(e),n=Yt(e,Ri);return t===ma(n)?t=r:n.pop(),n.length&&n[0]===e[0]?Qr(n,wo(t,2)):[]})),_a=mi((function(e){var t=ma(e),n=Yt(e,Ri);return(t="function"==typeof t?t:r)&&n.pop(),n.length&&n[0]===e[0]?Qr(n,r,t):[]}));function ma(e){var t=null==e?0:e.length;return t?e[t-1]:r}var ga=mi(ya);function ya(e,t){return e&&e.length&&t&&t.length?fi(e,t):e}var va=Oo((function(e,t){var n=null==e?0:e.length,r=xr(e,t);return pi(e,Yt(t,(function(e){return Ho(e,n)?+e:e})).sort(qi)),r}));function ba(e){return null==e?e:$n.call(e)}var Ca=mi((function(e){return Di(Rr(e,1,pu,!0))})),Ea=mi((function(e){var t=ma(e);return pu(t)&&(t=r),Di(Rr(e,1,pu,!0),wo(t,2))})),Oa=mi((function(e){var t=ma(e);return t="function"==typeof t?t:r,Di(Rr(e,1,pu,!0),r,t)}));function Ta(e){if(!e||!e.length)return[];var t=0;return e=Xt(e,(function(e){if(pu(e))return t=Gn(e.length,t),!0})),hn(t,(function(t){return Yt(e,ln(t))}))}function Sa(e,t){if(!e||!e.length)return[];var n=Ta(e);return null==t?n:Yt(n,(function(e){return Vt(t,r,e)}))}var xa=mi((function(e,t){return pu(e)?kr(e,t):[]})),Ma=mi((function(e){return Ni(Xt(e,pu))})),Ia=mi((function(e){var t=ma(e);return pu(t)&&(t=r),Ni(Xt(e,pu),wo(t,2))})),wa=mi((function(e){var t=ma(e);return t="function"==typeof t?t:r,Ni(Xt(e,pu),r,t)})),Da=mi(Ta);var ka=mi((function(e){var t=e.length,n=t>1?e[t-1]:r;return n="function"==typeof n?(e.pop(),n):r,Sa(e,n)}));function Aa(e){var t=pr(e);return t.__chain__=!0,t}function Fa(e,t){return t(e)}var La=Oo((function(e){var t=e.length,n=t?e[0]:0,i=this.__wrapped__,o=function(t){return xr(t,e)};return!(t>1||this.__actions__.length)&&i instanceof LazyWrapper&&Ho(n)?((i=i.slice(n,+n+(t?1:0))).__actions__.push({func:Fa,args:[o],thisArg:r}),new LodashWrapper(i,this.__chain__).thru((function(e){return t&&!e.length&&e.push(r),e}))):this.thru(o)}));var Na=Yi((function(e,t,n){lt.call(e,n)?++e[n]:Sr(e,n,1)}));var Pa=io(ca),Ra=io(la);function ja(e,t){return(lu(e)?Gt:Ar)(e,wo(t,3))}function Ha(e,t){return(lu(e)?qt:Fr)(e,wo(t,3))}var Ba=Yi((function(e,t,n){lt.call(e,n)?e[n].push(t):Sr(e,n,[t])}));var Ua=mi((function(e,t,n){var r=-1,i="function"==typeof t,o=fu(e)?$e(e.length):[];return Ar(e,(function(e){o[++r]=i?Vt(t,e,n):$r(e,t,n)})),o})),za=Yi((function(e,t,n){Sr(e,n,t)}));function Va(e,t){return(lu(e)?Yt:oi)(e,wo(t,3))}var Wa=Yi((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var Ga=mi((function(e,t){if(null==e)return[];var n=t.length;return n>1&&Bo(e,t[0],t[1])?t=[]:n>2&&Bo(t[0],t[1],t[2])&&(t=[t[0]]),li(e,Rr(t,1),[])})),qa=Pn||function(){return kt.Date.now()};function Ka(e,t,n){return t=n?r:t,t=e&&null==t?e.length:t,yo(e,E,r,r,r,r,t)}function Xa(e,t){var n;if("function"!=typeof t)throw new it(a);return e=Lu(e),function(){return--e>0&&(n=t.apply(this,arguments)),e<=1&&(t=r),n}}var Qa=mi((function(e,t,n){var r=_;if(n.length){var i=xn(n,Io(Qa));r|=b}return yo(e,r,t,n,i)})),$a=mi((function(e,t,n){var r=_|m;if(n.length){var i=xn(n,Io($a));r|=b}return yo(t,r,e,n,i)}));function Ya(e,t,n){var i,o,u,s,c,l,d=0,f=!1,p=!1,h=!0;if("function"!=typeof e)throw new it(a);function _(t){var n=i,a=o;return i=o=r,d=t,s=e.apply(a,n)}function m(e){var n=e-l;return l===r||n>=t||n<0||p&&e-d>=u}function g(){var e=qa();if(m(e))return y(e);c=Yo(g,function(e){var n=t-(e-l);return p?qn(n,u-(e-d)):n}(e))}function y(e){return c=r,h&&i?_(e):(i=o=r,s)}function v(){var e=qa(),n=m(e);if(i=arguments,o=this,l=e,n){if(c===r)return function(e){return d=e,c=Yo(g,t),f?_(e):s}(l);if(p)return zi(c),c=Yo(g,t),_(l)}return c===r&&(c=Yo(g,t)),s}return t=Pu(t)||0,bu(n)&&(f=!!n.leading,u=(p="maxWait"in n)?Gn(Pu(n.maxWait)||0,t):u,h="trailing"in n?!!n.trailing:h),v.cancel=function(){c!==r&&zi(c),d=0,i=l=o=c=r},v.flush=function(){return c===r?s:y(qa())},v}var Za=mi((function(e,t){return Dr(e,1,t)})),Ja=mi((function(e,t,n){return Dr(e,Pu(t)||0,n)}));function eu(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new it(a);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(eu.Cache||MapCache),n}function tu(e){if("function"!=typeof e)throw new it(a);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}eu.Cache=MapCache;var nu=Bi((function(e,t){var n=(t=1==t.length&&lu(t[0])?Yt(t[0],_n(wo())):Yt(Rr(t,1),_n(wo()))).length;return mi((function(r){for(var i=-1,o=qn(r.length,n);++i<o;)r[i]=t[i].call(this,r[i]);return Vt(e,this,r)}))})),ru=mi((function(e,t){var n=xn(t,Io(ru));return yo(e,b,r,t,n)})),iu=mi((function(e,t){var n=xn(t,Io(iu));return yo(e,C,r,t,n)})),ou=Oo((function(e,t){return yo(e,O,r,r,r,t)}));function au(e,t){return e===t||e!=e&&t!=t}var uu=po(qr),su=po((function(e,t){return e>=t})),cu=Yr(function(){return arguments}())?Yr:function(e){return Cu(e)&<.call(e,"callee")&&!Nt.call(e,"callee")},lu=$e.isArray,du=Rt?_n(Rt):function(e){return Cu(e)&&Gr(e)==ae};function fu(e){return null!=e&&vu(e.length)&&!gu(e)}function pu(e){return Cu(e)&&fu(e)}var hu=Un||Ps,_u=jt?_n(jt):function(e){return Cu(e)&&Gr(e)==V};function mu(e){if(!Cu(e))return!1;var t=Gr(e);return t==G||t==W||"string"==typeof e.message&&"string"==typeof e.name&&!Tu(e)}function gu(e){if(!bu(e))return!1;var t=Gr(e);return t==q||t==K||t==U||t==Z}function yu(e){return"number"==typeof e&&e==Lu(e)}function vu(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=A}function bu(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Cu(e){return null!=e&&"object"==typeof e}var Eu=Ht?_n(Ht):function(e){return Cu(e)&&No(e)==X};function Ou(e){return"number"==typeof e||Cu(e)&&Gr(e)==Q}function Tu(e){if(!Cu(e)||Gr(e)!=Y)return!1;var t=At(e);if(null===t)return!0;var n=lt.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&ct.call(n)==ht}var Su=Bt?_n(Bt):function(e){return Cu(e)&&Gr(e)==J};var xu=Ut?_n(Ut):function(e){return Cu(e)&&No(e)==ee};function Mu(e){return"string"==typeof e||!lu(e)&&Cu(e)&&Gr(e)==te}function Iu(e){return"symbol"==typeof e||Cu(e)&&Gr(e)==ne}var wu=zt?_n(zt):function(e){return Cu(e)&&vu(e.length)&&!!Tt[Gr(e)]};var Du=po(ii),ku=po((function(e,t){return e<=t}));function Au(e){if(!e)return[];if(fu(e))return Mu(e)?Dn(e):Qi(e);if(dn&&e[dn])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[dn]());var t=No(e);return(t==X?Tn:t==ee?Mn:as)(e)}function Fu(e){return e?(e=Pu(e))===k||e===-k?(e<0?-1:1)*F:e==e?e:0:0===e?e:0}function Lu(e){var t=Fu(e),n=t%1;return t==t?n?t-n:t:0}function Nu(e){return e?Mr(Lu(e),0,N):0}function Pu(e){if("number"==typeof e)return e;if(Iu(e))return L;if(bu(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=bu(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(Ae,"");var n=Ve.test(e);return n||Ge.test(e)?It(e.slice(2),n?2:8):ze.test(e)?L:+e}function Ru(e){return $i(e,Zu(e))}function ju(e){return null==e?"":wi(e)}var Hu=Zi((function(e,t){if(Wo(t)||fu(t))$i(t,Yu(t),e);else for(var n in t)lt.call(t,n)&&Cr(e,n,t[n])})),Bu=Zi((function(e,t){$i(t,Zu(t),e)})),Uu=Zi((function(e,t,n,r){$i(t,Zu(t),e,r)})),zu=Zi((function(e,t,n,r){$i(t,Yu(t),e,r)})),Vu=Oo(xr);var Wu=mi((function(e,t){e=tt(e);var n=-1,i=t.length,o=i>2?t[2]:r;for(o&&Bo(t[0],t[1],o)&&(i=1);++n<i;)for(var a=t[n],u=Zu(a),s=-1,c=u.length;++s<c;){var l=u[s],d=e[l];(d===r||au(d,ut[l])&&!lt.call(e,l))&&(e[l]=a[l])}return e})),Gu=mi((function(e){return e.push(r,bo),Vt(es,r,e)}));function qu(e,t,n){var i=null==e?r:Vr(e,t);return i===r?n:i}function Ku(e,t){return null!=e&&Po(e,t,Xr)}var Xu=uo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),e[t]=n}),bs(Os)),Qu=uo((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=pt.call(t)),lt.call(e,t)?e[t].push(n):e[t]=[n]}),wo),$u=mi($r);function Yu(e){return fu(e)?mr(e):ni(e)}function Zu(e){return fu(e)?mr(e,!0):ri(e)}var Ju=Zi((function(e,t,n){si(e,t,n)})),es=Zi((function(e,t,n,r){si(e,t,n,r)})),ts=Oo((function(e,t){var n={};if(null==e)return n;var r=!1;t=Yt(t,(function(t){return t=Hi(t,e),r||(r=t.length>1),t})),$i(e,So(e),n),r&&(n=Ir(n,l|d|f,Co));for(var i=t.length;i--;)ki(n,t[i]);return n}));var ns=Oo((function(e,t){return null==e?{}:function(e,t){return di(e,t,(function(t,n){return Ku(e,n)}))}(e,t)}));function rs(e,t){if(null==e)return{};var n=Yt(So(e),(function(e){return[e]}));return t=wo(t),di(e,n,(function(e,n){return t(e,n[0])}))}var is=go(Yu),os=go(Zu);function as(e){return null==e?[]:mn(e,Yu(e))}var us=no((function(e,t,n){return t=t.toLowerCase(),e+(n?ss(t):t)}));function ss(e){return ms(ju(e).toLowerCase())}function cs(e){return(e=ju(e))&&e.replace(Ke,bn).replace(gt,"")}var ls=no((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),ds=no((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),fs=to("toLowerCase");var ps=no((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var hs=no((function(e,t,n){return e+(n?" ":"")+ms(t)}));var _s=no((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),ms=to("toUpperCase");function gs(e,t,n){return e=ju(e),(t=n?r:t)===r?function(e){return Ct.test(e)}(e)?function(e){return e.match(vt)||[]}(e):function(e){return e.match(je)||[]}(e):e.match(t)||[]}var ys=mi((function(e,t){try{return Vt(e,r,t)}catch(e){return mu(e)?e:new Ze(e)}})),vs=Oo((function(e,t){return Gt(t,(function(t){t=ra(t),Sr(e,t,Qa(e[t],e))})),e}));function bs(e){return function(){return e}}var Cs=oo(),Es=oo(!0);function Os(e){return e}function Ts(e){return ti("function"==typeof e?e:Ir(e,l))}var Ss=mi((function(e,t){return function(n){return $r(n,e,t)}})),xs=mi((function(e,t){return function(n){return $r(e,n,t)}}));function Ms(e,t,n){var r=Yu(t),i=zr(t,r);null!=n||bu(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=zr(t,Yu(t)));var o=!(bu(n)&&"chain"in n&&!n.chain),a=gu(e);return Gt(i,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__),i=n.__actions__=Qi(this.__actions__);return i.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,Zt([this.value()],arguments))})})),e}function Is(){}var ws=co(Yt),Ds=co(Kt),ks=co(tn);function As(e){return Uo(e)?ln(ra(e)):function(e){return function(t){return Vr(t,e)}}(e)}var Fs=fo(),Ls=fo(!0);function Ns(){return[]}function Ps(){return!1}var Rs=so((function(e,t){return e+t}),0),js=_o("ceil"),Hs=so((function(e,t){return e/t}),1),Bs=_o("floor");var Us,zs=so((function(e,t){return e*t}),1),Vs=_o("round"),Ws=so((function(e,t){return e-t}),0);return pr.after=function(e,t){if("function"!=typeof t)throw new it(a);return e=Lu(e),function(){if(--e<1)return t.apply(this,arguments)}},pr.ary=Ka,pr.assign=Hu,pr.assignIn=Bu,pr.assignInWith=Uu,pr.assignWith=zu,pr.at=Vu,pr.before=Xa,pr.bind=Qa,pr.bindAll=vs,pr.bindKey=$a,pr.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return lu(e)?e:[e]},pr.chain=Aa,pr.chunk=function(e,t,n){t=(n?Bo(e,t,n):t===r)?1:Gn(Lu(t),0);var i=null==e?0:e.length;if(!i||t<1)return[];for(var o=0,a=0,u=$e(jn(i/t));o<i;)u[a++]=Oi(e,o,o+=t);return u},pr.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,i=[];++t<n;){var o=e[t];o&&(i[r++]=o)}return i},pr.concat=function(){var e=arguments.length;if(!e)return[];for(var t=$e(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return Zt(lu(n)?Qi(n):[n],Rr(t,1))},pr.cond=function(e){var t=null==e?0:e.length,n=wo();return e=t?Yt(e,(function(e){if("function"!=typeof e[1])throw new it(a);return[n(e[0]),e[1]]})):[],mi((function(n){for(var r=-1;++r<t;){var i=e[r];if(Vt(i[0],this,n))return Vt(i[1],this,n)}}))},pr.conforms=function(e){return function(e){var t=Yu(e);return function(n){return wr(n,e,t)}}(Ir(e,l))},pr.constant=bs,pr.countBy=Na,pr.create=function(e,t){var n=hr(e);return null==t?n:Tr(n,t)},pr.curry=function e(t,n,i){var o=yo(t,y,r,r,r,r,r,n=i?r:n);return o.placeholder=e.placeholder,o},pr.curryRight=function e(t,n,i){var o=yo(t,v,r,r,r,r,r,n=i?r:n);return o.placeholder=e.placeholder,o},pr.debounce=Ya,pr.defaults=Wu,pr.defaultsDeep=Gu,pr.defer=Za,pr.delay=Ja,pr.difference=aa,pr.differenceBy=ua,pr.differenceWith=sa,pr.drop=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,(t=n||t===r?1:Lu(t))<0?0:t,i):[]},pr.dropRight=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,0,(t=i-(t=n||t===r?1:Lu(t)))<0?0:t):[]},pr.dropRightWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!0,!0):[]},pr.dropWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!0):[]},pr.fill=function(e,t,n,i){var o=null==e?0:e.length;return o?(n&&"number"!=typeof n&&Bo(e,t,n)&&(n=0,i=o),function(e,t,n,i){var o=e.length;for((n=Lu(n))<0&&(n=-n>o?0:o+n),(i=i===r||i>o?o:Lu(i))<0&&(i+=o),i=n>i?0:Nu(i);n<i;)e[n++]=t;return e}(e,t,n,i)):[]},pr.filter=function(e,t){return(lu(e)?Xt:Pr)(e,wo(t,3))},pr.flatMap=function(e,t){return Rr(Va(e,t),1)},pr.flatMapDeep=function(e,t){return Rr(Va(e,t),k)},pr.flatMapDepth=function(e,t,n){return n=n===r?1:Lu(n),Rr(Va(e,t),n)},pr.flatten=da,pr.flattenDeep=function(e){return(null==e?0:e.length)?Rr(e,k):[]},pr.flattenDepth=function(e,t){return(null==e?0:e.length)?Rr(e,t=t===r?1:Lu(t)):[]},pr.flip=function(e){return yo(e,T)},pr.flow=Cs,pr.flowRight=Es,pr.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r},pr.functions=function(e){return null==e?[]:zr(e,Yu(e))},pr.functionsIn=function(e){return null==e?[]:zr(e,Zu(e))},pr.groupBy=Ba,pr.initial=function(e){return(null==e?0:e.length)?Oi(e,0,-1):[]},pr.intersection=pa,pr.intersectionBy=ha,pr.intersectionWith=_a,pr.invert=Xu,pr.invertBy=Qu,pr.invokeMap=Ua,pr.iteratee=Ts,pr.keyBy=za,pr.keys=Yu,pr.keysIn=Zu,pr.map=Va,pr.mapKeys=function(e,t){var n={};return t=wo(t,3),Br(e,(function(e,r,i){Sr(n,t(e,r,i),e)})),n},pr.mapValues=function(e,t){var n={};return t=wo(t,3),Br(e,(function(e,r,i){Sr(n,r,t(e,r,i))})),n},pr.matches=function(e){return ai(Ir(e,l))},pr.matchesProperty=function(e,t){return ui(e,Ir(t,l))},pr.memoize=eu,pr.merge=Ju,pr.mergeWith=es,pr.method=Ss,pr.methodOf=xs,pr.mixin=Ms,pr.negate=tu,pr.nthArg=function(e){return e=Lu(e),mi((function(t){return ci(t,e)}))},pr.omit=ts,pr.omitBy=function(e,t){return rs(e,tu(wo(t)))},pr.once=function(e){return Xa(2,e)},pr.orderBy=function(e,t,n,i){return null==e?[]:(lu(t)||(t=null==t?[]:[t]),lu(n=i?r:n)||(n=null==n?[]:[n]),li(e,t,n))},pr.over=ws,pr.overArgs=nu,pr.overEvery=Ds,pr.overSome=ks,pr.partial=ru,pr.partialRight=iu,pr.partition=Wa,pr.pick=ns,pr.pickBy=rs,pr.property=As,pr.propertyOf=function(e){return function(t){return null==e?r:Vr(e,t)}},pr.pull=ga,pr.pullAll=ya,pr.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?fi(e,t,wo(n,2)):e},pr.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?fi(e,t,r,n):e},pr.pullAt=va,pr.range=Fs,pr.rangeRight=Ls,pr.rearg=ou,pr.reject=function(e,t){return(lu(e)?Xt:Pr)(e,tu(wo(t,3)))},pr.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;for(t=wo(t,3);++r<o;){var a=e[r];t(a,r,e)&&(n.push(a),i.push(r))}return pi(e,i),n},pr.rest=function(e,t){if("function"!=typeof e)throw new it(a);return mi(e,t=t===r?t:Lu(t))},pr.reverse=ba,pr.sampleSize=function(e,t,n){return t=(n?Bo(e,t,n):t===r)?1:Lu(t),(lu(e)?yr:yi)(e,t)},pr.set=function(e,t,n){return null==e?e:vi(e,t,n)},pr.setWith=function(e,t,n,i){return i="function"==typeof i?i:r,null==e?e:vi(e,t,n,i)},pr.shuffle=function(e){return(lu(e)?vr:Ei)(e)},pr.slice=function(e,t,n){var i=null==e?0:e.length;return i?(n&&"number"!=typeof n&&Bo(e,t,n)?(t=0,n=i):(t=null==t?0:Lu(t),n=n===r?i:Lu(n)),Oi(e,t,n)):[]},pr.sortBy=Ga,pr.sortedUniq=function(e){return e&&e.length?Mi(e):[]},pr.sortedUniqBy=function(e,t){return e&&e.length?Mi(e,wo(t,2)):[]},pr.split=function(e,t,n){return n&&"number"!=typeof n&&Bo(e,t,n)&&(t=n=r),(n=n===r?N:n>>>0)?(e=ju(e))&&("string"==typeof t||null!=t&&!Su(t))&&!(t=wi(t))&&On(e)?Ui(Dn(e),0,n):e.split(t,n):[]},pr.spread=function(e,t){if("function"!=typeof e)throw new it(a);return t=null==t?0:Gn(Lu(t),0),mi((function(n){var r=n[t],i=Ui(n,0,t);return r&&Zt(i,r),Vt(e,this,i)}))},pr.tail=function(e){var t=null==e?0:e.length;return t?Oi(e,1,t):[]},pr.take=function(e,t,n){return e&&e.length?Oi(e,0,(t=n||t===r?1:Lu(t))<0?0:t):[]},pr.takeRight=function(e,t,n){var i=null==e?0:e.length;return i?Oi(e,(t=i-(t=n||t===r?1:Lu(t)))<0?0:t,i):[]},pr.takeRightWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3),!1,!0):[]},pr.takeWhile=function(e,t){return e&&e.length?Fi(e,wo(t,3)):[]},pr.tap=function(e,t){return t(e),e},pr.throttle=function(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new it(a);return bu(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Ya(e,t,{leading:r,maxWait:t,trailing:i})},pr.thru=Fa,pr.toArray=Au,pr.toPairs=is,pr.toPairsIn=os,pr.toPath=function(e){return lu(e)?Yt(e,ra):Iu(e)?[e]:Qi(na(ju(e)))},pr.toPlainObject=Ru,pr.transform=function(e,t,n){var r=lu(e),i=r||hu(e)||wu(e);if(t=wo(t,4),null==n){var o=e&&e.constructor;n=i?r?new o:[]:bu(e)&&gu(o)?hr(At(e)):{}}return(i?Gt:Br)(e,(function(e,r,i){return t(n,e,r,i)})),n},pr.unary=function(e){return Ka(e,1)},pr.union=Ca,pr.unionBy=Ea,pr.unionWith=Oa,pr.uniq=function(e){return e&&e.length?Di(e):[]},pr.uniqBy=function(e,t){return e&&e.length?Di(e,wo(t,2)):[]},pr.uniqWith=function(e,t){return t="function"==typeof t?t:r,e&&e.length?Di(e,r,t):[]},pr.unset=function(e,t){return null==e||ki(e,t)},pr.unzip=Ta,pr.unzipWith=Sa,pr.update=function(e,t,n){return null==e?e:Ai(e,t,ji(n))},pr.updateWith=function(e,t,n,i){return i="function"==typeof i?i:r,null==e?e:Ai(e,t,ji(n),i)},pr.values=as,pr.valuesIn=function(e){return null==e?[]:mn(e,Zu(e))},pr.without=xa,pr.words=gs,pr.wrap=function(e,t){return ru(ji(t),e)},pr.xor=Ma,pr.xorBy=Ia,pr.xorWith=wa,pr.zip=Da,pr.zipObject=function(e,t){return Pi(e||[],t||[],Cr)},pr.zipObjectDeep=function(e,t){return Pi(e||[],t||[],vi)},pr.zipWith=ka,pr.entries=is,pr.entriesIn=os,pr.extend=Bu,pr.extendWith=Uu,Ms(pr,pr),pr.add=Rs,pr.attempt=ys,pr.camelCase=us,pr.capitalize=ss,pr.ceil=js,pr.clamp=function(e,t,n){return n===r&&(n=t,t=r),n!==r&&(n=(n=Pu(n))==n?n:0),t!==r&&(t=(t=Pu(t))==t?t:0),Mr(Pu(e),t,n)},pr.clone=function(e){return Ir(e,f)},pr.cloneDeep=function(e){return Ir(e,l|f)},pr.cloneDeepWith=function(e,t){return Ir(e,l|f,t="function"==typeof t?t:r)},pr.cloneWith=function(e,t){return Ir(e,f,t="function"==typeof t?t:r)},pr.conformsTo=function(e,t){return null==t||wr(e,t,Yu(t))},pr.deburr=cs,pr.defaultTo=function(e,t){return null==e||e!=e?t:e},pr.divide=Hs,pr.endsWith=function(e,t,n){e=ju(e),t=wi(t);var i=e.length,o=n=n===r?i:Mr(Lu(n),0,i);return(n-=t.length)>=0&&e.slice(n,o)==t},pr.eq=au,pr.escape=function(e){return(e=ju(e))&&Oe.test(e)?e.replace(Ce,Cn):e},pr.escapeRegExp=function(e){return(e=ju(e))&&ke.test(e)?e.replace(De,"\\$&"):e},pr.every=function(e,t,n){var i=lu(e)?Kt:Lr;return n&&Bo(e,t,n)&&(t=r),i(e,wo(t,3))},pr.find=Pa,pr.findIndex=ca,pr.findKey=function(e,t){return rn(e,wo(t,3),Br)},pr.findLast=Ra,pr.findLastIndex=la,pr.findLastKey=function(e,t){return rn(e,wo(t,3),Ur)},pr.floor=Bs,pr.forEach=ja,pr.forEachRight=Ha,pr.forIn=function(e,t){return null==e?e:jr(e,wo(t,3),Zu)},pr.forInRight=function(e,t){return null==e?e:Hr(e,wo(t,3),Zu)},pr.forOwn=function(e,t){return e&&Br(e,wo(t,3))},pr.forOwnRight=function(e,t){return e&&Ur(e,wo(t,3))},pr.get=qu,pr.gt=uu,pr.gte=su,pr.has=function(e,t){return null!=e&&Po(e,t,Kr)},pr.hasIn=Ku,pr.head=fa,pr.identity=Os,pr.includes=function(e,t,n,r){e=fu(e)?e:as(e),n=n&&!r?Lu(n):0;var i=e.length;return n<0&&(n=Gn(i+n,0)),Mu(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&an(e,t,n)>-1},pr.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:Lu(n);return i<0&&(i=Gn(r+i,0)),an(e,t,i)},pr.inRange=function(e,t,n){return t=Fu(t),n===r?(n=t,t=0):n=Fu(n),function(e,t,n){return e>=qn(t,n)&&e<Gn(t,n)}(e=Pu(e),t,n)},pr.invoke=$u,pr.isArguments=cu,pr.isArray=lu,pr.isArrayBuffer=du,pr.isArrayLike=fu,pr.isArrayLikeObject=pu,pr.isBoolean=function(e){return!0===e||!1===e||Cu(e)&&Gr(e)==z},pr.isBuffer=hu,pr.isDate=_u,pr.isElement=function(e){return Cu(e)&&1===e.nodeType&&!Tu(e)},pr.isEmpty=function(e){if(null==e)return!0;if(fu(e)&&(lu(e)||"string"==typeof e||"function"==typeof e.splice||hu(e)||wu(e)||cu(e)))return!e.length;var t=No(e);if(t==X||t==ee)return!e.size;if(Wo(e))return!ni(e).length;for(var n in e)if(lt.call(e,n))return!1;return!0},pr.isEqual=function(e,t){return Zr(e,t)},pr.isEqualWith=function(e,t,n){var i=(n="function"==typeof n?n:r)?n(e,t):r;return i===r?Zr(e,t,r,n):!!i},pr.isError=mu,pr.isFinite=function(e){return"number"==typeof e&&zn(e)},pr.isFunction=gu,pr.isInteger=yu,pr.isLength=vu,pr.isMap=Eu,pr.isMatch=function(e,t){return e===t||Jr(e,t,ko(t))},pr.isMatchWith=function(e,t,n){return n="function"==typeof n?n:r,Jr(e,t,ko(t),n)},pr.isNaN=function(e){return Ou(e)&&e!=+e},pr.isNative=function(e){if(Vo(e))throw new Ze(o);return ei(e)},pr.isNil=function(e){return null==e},pr.isNull=function(e){return null===e},pr.isNumber=Ou,pr.isObject=bu,pr.isObjectLike=Cu,pr.isPlainObject=Tu,pr.isRegExp=Su,pr.isSafeInteger=function(e){return yu(e)&&e>=-A&&e<=A},pr.isSet=xu,pr.isString=Mu,pr.isSymbol=Iu,pr.isTypedArray=wu,pr.isUndefined=function(e){return e===r},pr.isWeakMap=function(e){return Cu(e)&&No(e)==ie},pr.isWeakSet=function(e){return Cu(e)&&Gr(e)==oe},pr.join=function(e,t){return null==e?"":Vn.call(e,t)},pr.kebabCase=ls,pr.last=ma,pr.lastIndexOf=function(e,t,n){var i=null==e?0:e.length;if(!i)return-1;var o=i;return n!==r&&(o=(o=Lu(n))<0?Gn(i+o,0):qn(o,i-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):on(e,sn,o,!0)},pr.lowerCase=ds,pr.lowerFirst=fs,pr.lt=Du,pr.lte=ku,pr.max=function(e){return e&&e.length?Nr(e,Os,qr):r},pr.maxBy=function(e,t){return e&&e.length?Nr(e,wo(t,2),qr):r},pr.mean=function(e){return cn(e,Os)},pr.meanBy=function(e,t){return cn(e,wo(t,2))},pr.min=function(e){return e&&e.length?Nr(e,Os,ii):r},pr.minBy=function(e,t){return e&&e.length?Nr(e,wo(t,2),ii):r},pr.stubArray=Ns,pr.stubFalse=Ps,pr.stubObject=function(){return{}},pr.stubString=function(){return""},pr.stubTrue=function(){return!0},pr.multiply=zs,pr.nth=function(e,t){return e&&e.length?ci(e,Lu(t)):r},pr.noConflict=function(){return kt._===this&&(kt._=_t),this},pr.noop=Is,pr.now=qa,pr.pad=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return lo(Hn(i),n)+e+lo(jn(i),n)},pr.padEnd=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;return t&&r<t?e+lo(t-r,n):e},pr.padStart=function(e,t,n){e=ju(e);var r=(t=Lu(t))?wn(e):0;return t&&r<t?lo(t-r,n)+e:e},pr.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),Xn(ju(e).replace(Fe,""),t||0)},pr.random=function(e,t,n){if(n&&"boolean"!=typeof n&&Bo(e,t,n)&&(t=n=r),n===r&&("boolean"==typeof t?(n=t,t=r):"boolean"==typeof e&&(n=e,e=r)),e===r&&t===r?(e=0,t=1):(e=Fu(e),t===r?(t=e,e=0):t=Fu(t)),e>t){var i=e;e=t,t=i}if(n||e%1||t%1){var o=Qn();return qn(e+o*(t-e+Mt("1e-"+((o+"").length-1))),t)}return hi(e,t)},pr.reduce=function(e,t,n){var r=lu(e)?Jt:fn,i=arguments.length<3;return r(e,wo(t,4),n,i,Ar)},pr.reduceRight=function(e,t,n){var r=lu(e)?en:fn,i=arguments.length<3;return r(e,wo(t,4),n,i,Fr)},pr.repeat=function(e,t,n){return t=(n?Bo(e,t,n):t===r)?1:Lu(t),_i(ju(e),t)},pr.replace=function(){var e=arguments,t=ju(e[0]);return e.length<3?t:t.replace(e[1],e[2])},pr.result=function(e,t,n){var i=-1,o=(t=Hi(t,e)).length;for(o||(o=1,e=r);++i<o;){var a=null==e?r:e[ra(t[i])];a===r&&(i=o,a=n),e=gu(a)?a.call(e):a}return e},pr.round=Vs,pr.runInContext=e,pr.sample=function(e){return(lu(e)?gr:gi)(e)},pr.size=function(e){if(null==e)return 0;if(fu(e))return Mu(e)?wn(e):e.length;var t=No(e);return t==X||t==ee?e.size:ni(e).length},pr.snakeCase=ps,pr.some=function(e,t,n){var i=lu(e)?tn:Ti;return n&&Bo(e,t,n)&&(t=r),i(e,wo(t,3))},pr.sortedIndex=function(e,t){return Si(e,t)},pr.sortedIndexBy=function(e,t,n){return xi(e,t,wo(n,2))},pr.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=Si(e,t);if(r<n&&au(e[r],t))return r}return-1},pr.sortedLastIndex=function(e,t){return Si(e,t,!0)},pr.sortedLastIndexBy=function(e,t,n){return xi(e,t,wo(n,2),!0)},pr.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=Si(e,t,!0)-1;if(au(e[n],t))return n}return-1},pr.startCase=hs,pr.startsWith=function(e,t,n){return e=ju(e),n=null==n?0:Mr(Lu(n),0,e.length),t=wi(t),e.slice(n,n+t.length)==t},pr.subtract=Ws,pr.sum=function(e){return e&&e.length?pn(e,Os):0},pr.sumBy=function(e,t){return e&&e.length?pn(e,wo(t,2)):0},pr.template=function(e,t,n){var i=pr.templateSettings;n&&Bo(e,t,n)&&(t=r),e=ju(e),t=Uu({},t,i,vo);var o,a,u=Uu({},t.imports,i.imports,vo),s=Yu(u),c=mn(u,s),l=0,d=t.interpolate||Xe,f="__p += '",p=nt((t.escape||Xe).source+"|"+d.source+"|"+(d===xe?Be:Xe).source+"|"+(t.evaluate||Xe).source+"|$","g"),h="//# sourceURL="+(lt.call(t,"sourceURL")?(t.sourceURL+"").replace(/[\r\n]/g," "):"lodash.templateSources["+ ++Ot+"]")+"\n";e.replace(p,(function(t,n,r,i,u,s){return r||(r=i),f+=e.slice(l,s).replace(Qe,En),n&&(o=!0,f+="' +\n__e("+n+") +\n'"),u&&(a=!0,f+="';\n"+u+";\n__p += '"),r&&(f+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=s+t.length,t})),f+="';\n";var _=lt.call(t,"variable")&&t.variable;_||(f="with (obj) {\n"+f+"\n}\n"),f=(a?f.replace(ge,""):f).replace(ye,"$1").replace(ve,"$1;"),f="function("+(_||"obj")+") {\n"+(_?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+f+"return __p\n}";var m=ys((function(){return Je(s,h+"return "+f).apply(r,c)}));if(m.source=f,mu(m))throw m;return m},pr.times=function(e,t){if((e=Lu(e))<1||e>A)return[];var n=N,r=qn(e,N);t=wo(t),e-=N;for(var i=hn(r,t);++n<e;)t(n);return i},pr.toFinite=Fu,pr.toInteger=Lu,pr.toLength=Nu,pr.toLower=function(e){return ju(e).toLowerCase()},pr.toNumber=Pu,pr.toSafeInteger=function(e){return e?Mr(Lu(e),-A,A):0===e?e:0},pr.toString=ju,pr.toUpper=function(e){return ju(e).toUpperCase()},pr.trim=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Ae,"");if(!e||!(t=wi(t)))return e;var i=Dn(e),o=Dn(t);return Ui(i,yn(i,o),vn(i,o)+1).join("")},pr.trimEnd=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Le,"");if(!e||!(t=wi(t)))return e;var i=Dn(e);return Ui(i,0,vn(i,Dn(t))+1).join("")},pr.trimStart=function(e,t,n){if((e=ju(e))&&(n||t===r))return e.replace(Fe,"");if(!e||!(t=wi(t)))return e;var i=Dn(e);return Ui(i,yn(i,Dn(t))).join("")},pr.truncate=function(e,t){var n=S,i=x;if(bu(t)){var o="separator"in t?t.separator:o;n="length"in t?Lu(t.length):n,i="omission"in t?wi(t.omission):i}var a=(e=ju(e)).length;if(On(e)){var u=Dn(e);a=u.length}if(n>=a)return e;var s=n-wn(i);if(s<1)return i;var c=u?Ui(u,0,s).join(""):e.slice(0,s);if(o===r)return c+i;if(u&&(s+=c.length-s),Su(o)){if(e.slice(s).search(o)){var l,d=c;for(o.global||(o=nt(o.source,ju(Ue.exec(o))+"g")),o.lastIndex=0;l=o.exec(d);)var f=l.index;c=c.slice(0,f===r?s:f)}}else if(e.indexOf(wi(o),s)!=s){var p=c.lastIndexOf(o);p>-1&&(c=c.slice(0,p))}return c+i},pr.unescape=function(e){return(e=ju(e))&&Ee.test(e)?e.replace(be,kn):e},pr.uniqueId=function(e){var t=++dt;return ju(e)+t},pr.upperCase=_s,pr.upperFirst=ms,pr.each=ja,pr.eachRight=Ha,pr.first=fa,Ms(pr,(Us={},Br(pr,(function(e,t){lt.call(pr.prototype,t)||(Us[t]=e)})),Us),{chain:!1}),pr.VERSION="4.17.15",Gt(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){pr[e].placeholder=pr})),Gt(["drop","take"],(function(e,t){LazyWrapper.prototype[e]=function(n){n=n===r?1:Gn(Lu(n),0);var i=this.__filtered__&&!t?new LazyWrapper(this):this.clone();return i.__filtered__?i.__takeCount__=qn(n,i.__takeCount__):i.__views__.push({size:qn(n,N),type:e+(i.__dir__<0?"Right":"")}),i},LazyWrapper.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),Gt(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=n==w||3==n;LazyWrapper.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:wo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),Gt(["head","last"],(function(e,t){var n="take"+(t?"Right":"");LazyWrapper.prototype[e]=function(){return this[n](1).value()[0]}})),Gt(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");LazyWrapper.prototype[e]=function(){return this.__filtered__?new LazyWrapper(this):this[n](1)}})),LazyWrapper.prototype.compact=function(){return this.filter(Os)},LazyWrapper.prototype.find=function(e){return this.filter(e).head()},LazyWrapper.prototype.findLast=function(e){return this.reverse().find(e)},LazyWrapper.prototype.invokeMap=mi((function(e,t){return"function"==typeof e?new LazyWrapper(this):this.map((function(n){return $r(n,e,t)}))})),LazyWrapper.prototype.reject=function(e){return this.filter(tu(wo(e)))},LazyWrapper.prototype.slice=function(e,t){e=Lu(e);var n=this;return n.__filtered__&&(e>0||t<0)?new LazyWrapper(n):(e<0?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==r&&(n=(t=Lu(t))<0?n.dropRight(-t):n.take(t-e)),n)},LazyWrapper.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},LazyWrapper.prototype.toArray=function(){return this.take(N)},Br(LazyWrapper.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),i=/^(?:head|last)$/.test(t),o=pr[i?"take"+("last"==t?"Right":""):t],a=i||/^find/.test(t);o&&(pr.prototype[t]=function(){var t=this.__wrapped__,u=i?[1]:arguments,s=t instanceof LazyWrapper,c=u[0],l=s||lu(t),d=function(e){var t=o.apply(pr,Zt([e],u));return i&&f?t[0]:t};l&&n&&"function"==typeof c&&1!=c.length&&(s=l=!1);var f=this.__chain__,p=!!this.__actions__.length,h=a&&!f,_=s&&!p;if(!a&&l){t=_?t:new LazyWrapper(this);var m=e.apply(t,u);return m.__actions__.push({func:Fa,args:[d],thisArg:r}),new LodashWrapper(m,f)}return h&&_?e.apply(this,u):(m=this.thru(d),h?i?m.value()[0]:m.value():m)})})),Gt(["pop","push","shift","sort","splice","unshift"],(function(e){var t=ot[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);pr.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(lu(i)?i:[],e)}return this[n]((function(n){return t.apply(lu(n)?n:[],e)}))}})),Br(LazyWrapper.prototype,(function(e,t){var n=pr[t];if(n){var r=n.name+"";lt.call(ir,r)||(ir[r]=[]),ir[r].push({name:t,func:n})}})),ir[ao(r,m).name]=[{name:"wrapper",func:r}],LazyWrapper.prototype.clone=function(){var e=new LazyWrapper(this.__wrapped__);return e.__actions__=Qi(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=Qi(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=Qi(this.__views__),e},LazyWrapper.prototype.reverse=function(){if(this.__filtered__){var e=new LazyWrapper(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},LazyWrapper.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=lu(e),r=t<0,i=n?e.length:0,o=function(e,t,n){var r=-1,i=n.length;for(;++r<i;){var o=n[r],a=o.size;switch(o.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=qn(t,e+a);break;case"takeRight":e=Gn(e,t-a)}}return{start:e,end:t}}(0,i,this.__views__),a=o.start,u=o.end,s=u-a,c=r?u:a-1,l=this.__iteratees__,d=l.length,f=0,p=qn(s,this.__takeCount__);if(!n||!r&&i==s&&p==s)return Li(e,this.__actions__);var h=[];e:for(;s--&&f<p;){for(var _=-1,m=e[c+=t];++_<d;){var g=l[_],y=g.iteratee,v=g.type,b=y(m);if(v==D)m=b;else if(!b){if(v==w)continue e;break e}}h[f++]=m}return h},pr.prototype.at=La,pr.prototype.chain=function(){return Aa(this)},pr.prototype.commit=function(){return new LodashWrapper(this.value(),this.__chain__)},pr.prototype.next=function(){this.__values__===r&&(this.__values__=Au(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?r:this.__values__[this.__index__++]}},pr.prototype.plant=function(e){for(var t,n=this;n instanceof _r;){var i=oa(n);i.__index__=0,i.__values__=r,t?o.__wrapped__=i:t=i;var o=i;n=n.__wrapped__}return o.__wrapped__=e,t},pr.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof LazyWrapper){var t=e;return this.__actions__.length&&(t=new LazyWrapper(this)),(t=t.reverse()).__actions__.push({func:Fa,args:[ba],thisArg:r}),new LodashWrapper(t,this.__chain__)}return this.thru(ba)},pr.prototype.toJSON=pr.prototype.valueOf=pr.prototype.value=function(){return Li(this.__wrapped__,this.__actions__)},pr.prototype.first=pr.prototype.head,dn&&(pr.prototype[dn]=function(){return this}),pr}();"function"==typeof define&&"object"==typeof define.amd&&define.amd?(kt._=An,define((function(){return An}))):Ft?((Ft.exports=An)._=An,At._=An):kt._=An}).call(this)}).call(this,n(15),n(96)(e))},function(e,t,n){!function(){"use strict";var t={}.hasOwnProperty;function n(){for(var e=[],r=0;r<arguments.length;r++){var i=arguments[r];if(i){var o=typeof i;if("string"===o||"number"===o)e.push(i);else if(Array.isArray(i)&&i.length){var a=n.apply(null,i);a&&e.push(a)}else if("object"===o)for(var u in i)t.call(i,u)&&i[u]&&e.push(u)}}return e.join(" ")}e.exports?(n.default=n,e.exports=n):"function"==typeof define&&"object"==typeof define.amd&&define.amd?define("classnames",[],(function(){return n})):window.classNames=n}()},function(e,t){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(e){"object"==typeof window&&(n=window)}e.exports=n},function(e,t){e.exports=function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}},function(e,t,n){"use strict";n.d(t,"b",(function(){return __extends})),n.d(t,"a",(function(){return __assign})),n.d(t,"d",(function(){return __values})),n.d(t,"c",(function(){return __spread}));var r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)};function __extends(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}var __assign=function(){return(__assign=Object.assign||function __assign(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function __values(e){var t="function"==typeof Symbol&&e[Symbol.iterator],n=0;return t?t.call(e):{next:function(){return e&&n>=e.length&&(e=void 0),{value:e&&e[n++],done:!e}}}}function __read(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(e){i={error:e}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function __spread(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(__read(arguments[t]));return e}},,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(14),m=n.n(_),g=n(1),y=function(t){function Link(){return i()(this,Link),s()(this,l()(Link).apply(this,arguments))}return f()(Link,t),a()(Link,[{key:"render",value:function(){var t=this.props,n=t.dangerouslySetInnerHTML,r=t.onClick,i=t.href,o=t.children,a=t.className,u=t.arrow,s=t.external,c=t.inverse,l=t.back,d=t.small,f=t.inherit,p=t.caps,h=t.danger,_=t.disabled,g=t.id,y=i&&!_,v=y?"a":"button";return e.createElement(v,{className:m()("googlesitekit-cta-link",a,{"googlesitekit-cta-link--arrow":u,"googlesitekit-cta-link--external":s,"googlesitekit-cta-link--inverse":c,"googlesitekit-cta-link--back":l,"googlesitekit-cta-link--small":d,"googlesitekit-cta-link--inherit":f,"googlesitekit-cta-link--caps":p,"googlesitekit-cta-link--danger":h,"googlesitekit-cta-link--disabled":_}),onClick:r,id:g,href:y?i:void 0,target:y&&s?"_blank":void 0,rel:s?"noopener noreferrer":void 0,disabled:_,dangerouslySetInnerHTML:n},o)}}]),Link}(g.Component);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(1))},,function(e,t){e.exports=function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}},,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(1),i=function(e){return function(t){return function FilteredComponent(n){return Object(r.createElement)(r.Fragment,{},"",Object(r.createElement)(t,n),e)}}}},function(e,t,n){"use strict";(function(e,r){var i=n(2),o=n.n(i),a=n(14),u=n.n(a),s=function SvgIcon(t){var n=t.id,i=t.className,o=t.height,a=t.width,s="".concat(e.googlesitekit.admin.assetsRoot,"svg/svg.svg");return r.createElement("svg",{className:u()("svg",i),height:o,width:a},r.createElement("use",{xlinkHref:"".concat(s,"#").concat(n)}))};s.propTypes={id:o.a.string.isRequired,className:o.a.string,height:o.a.string,width:o.a.string},s.defaultProps={className:"",height:20,width:20},t.a=s}).call(this,n(15),n(1))},function(e,t,n){"use strict";var r=n(70),i=n.n(r);n.d(t,"l",(function(){return i.a})),n.d(t,"a",(function(){return r.HelperText})),n.d(t,"b",(function(){return r.Input}));var o=n(120);n.d(t,"h",(function(){return o.a}));var a=n(127);n.d(t,"e",(function(){return a.a}));var u=n(128);n.d(t,"g",(function(){return u.a}));var s=n(88),c=n.n(s);n.d(t,"k",(function(){return c.a})),n.d(t,"j",(function(){return s.Option}));var l=n(126);n.d(t,"i",(function(){return l.a}));var d=n(124);n.d(t,"d",(function(){return d.a}));var f=n(125);n.d(t,"c",(function(){return f.a}));var p=n(123);n.d(t,"f",(function(){return p.a}))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(16),f=n.n(d),p=n(9),h=n.n(p),_=n(2),m=n.n(_),g=n(58),y=n(14),v=n.n(y),b=n(1),C=n(129),E=n(3),O=function(t){function DataBlock(e){var t;return i()(this,DataBlock),(t=s()(this,l()(DataBlock).call(this,e))).handleClick=t.handleClick.bind(f()(t)),t.handleKeyPress=t.handleKeyPress.bind(f()(t)),t}return h()(DataBlock,t),a()(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,i=t.datapoint,o=t.datapointUnit,a=t.change,u=t.changeDataUnit,s=t.context,c=t.period,l=t.selected,d=t.handleStatSelection,f=t.source,p=t.sparkline,h=t.invertChangeColor,_="button"===s?"button":"",m=p;return m&&h&&(m=Object(b.cloneElement)(p,{invertChangeColor:h})),e.createElement("div",{className:v()("googlesitekit-data-block",n,"googlesitekit-data-block--".concat(s),{"googlesitekit-data-block--selected":l}),tabIndex:"button"===s?"0":"-1",role:d&&_,onClick:d&&this.handleClick,onKeyPress:d&&this.handleKeyPress,"aria-label":d&&r,"aria-pressed":d&&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(i).concat(o))),m&&e.createElement("div",{className:"googlesitekit-data-block__sparkline"},m),e.createElement("div",{className:"googlesitekit-data-block__change-source-wrapper"},e.createElement("div",{className:"googlesitekit-data-block__change"},""===a&&e.createElement(b.Fragment,null," "),a&&e.createElement(b.Fragment,null,e.createElement("span",{className:"googlesitekit-data-block__arrow"},e.createElement(C.a,{direction:0<parseFloat(a)?"up":"down",invertColor:h})),e.createElement("span",{className:"googlesitekit-data-block__value"},"".concat(Object(E.s)(Math.abs(a))).concat(u," ").concat(c)))),f&&e.createElement(g.a,{className:"googlesitekit-data-block__source",name:f.name,href:f.link})))}}]),DataBlock}(b.Component);O.propTypes={stat:m.a.number,onClick:m.a.func,className:m.a.string,title:m.a.string,datapoint:m.a.oneOfType([m.a.string,m.a.number]),datapointUnit:m.a.string,change:m.a.oneOfType([m.a.string,m.a.number]),changeDataUnit:m.a.string,context:m.a.string,period:m.a.string,selected:m.a.bool,handleStatSelection:m.a.func,invertChangeColor:m.a.bool},O.defaultProps={stat:null,onClick:null,className:"",title:"",datapoint:null,datapointUnit:"",change:null,changeDataUnit:"",context:"default",period:"",selected:!1,handleStatSelection:null,invertChangeColor:!1},t.a=O}).call(this,n(1))},,function(e,t,n){"use strict";n.d(t,"a",(function(){return r}));var r=function(){function MDCFoundation(e){void 0===e&&(e={}),this.adapter_=e}return Object.defineProperty(MDCFoundation,"cssClasses",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"strings",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"numbers",{get:function(){return{}},enumerable:!0,configurable:!0}),Object.defineProperty(MDCFoundation,"defaultAdapter",{get:function(){return{}},enumerable:!0,configurable:!0}),MDCFoundation.prototype.init=function(){},MDCFoundation.prototype.destroy=function(){},MDCFoundation}()},,function(e,t,n){"use strict";n.d(t,"a",(function(){return o}));var r=n(17),i=n(28),o=function(){function MDCComponent(e,t){for(var n=[],i=2;i<arguments.length;i++)n[i-2]=arguments[i];this.root_=e,this.initialize.apply(this,r.c(n)),this.foundation_=void 0===t?this.getDefaultFoundation():t,this.foundation_.init(),this.initialSyncWithDOM()}return MDCComponent.attachTo=function(e){return new MDCComponent(e,new i.a({}))},MDCComponent.prototype.initialize=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t]},MDCComponent.prototype.getDefaultFoundation=function(){throw new Error("Subclasses must override getDefaultFoundation to return a properly configured foundation class")},MDCComponent.prototype.initialSyncWithDOM=function(){},MDCComponent.prototype.destroy=function(){this.foundation_.destroy()},MDCComponent.prototype.listen=function(e,t){this.root_.addEventListener(e,t)},MDCComponent.prototype.unlisten=function(e,t){this.root_.removeEventListener(e,t)},MDCComponent.prototype.emit=function(e,t,n){var r;void 0===n&&(n=!1),"function"==typeof CustomEvent?r=new CustomEvent(e,{bubbles:n,detail:t}):(r=document.createEvent("CustomEvent")).initCustomEvent(e,n,!1,t),this.root_.dispatchEvent(r)},MDCComponent}()},function(e,t,n){"use strict";(function(e){var r=n(21),i=n.n(r),o=n(11),a=n.n(o),u=n(5),s=n.n(u),c=n(6),l=n.n(c),d=n(7),f=n.n(d),p=n(8),h=n.n(p),_=n(16),m=n.n(_),g=n(9),y=n.n(g),v=n(2),b=n.n(v),C=n(10),E=n(26),O=n(33),T=n(74),S=n(85),x=n(19),M=n(24),I=n(14),w=n.n(I),D=n(13),k=n(1),A=n(72),F=function(t){function Notification(e){var t;return s()(this,Notification),(t=f()(this,h()(Notification).call(this,e))).state={isClosed:!1},t.cardRef=Object(k.createRef)(),t.handleDismiss=t.handleDismiss.bind(m()(t)),t.handleCTAClick=t.handleCTAClick.bind(m()(t)),0<t.props.dismissExpires&&t.expireDismiss(),t.props.showOnce&&C.c.setCache("notification::displayed::".concat(t.props.id),new Date),t}return y()(Notification,t),l()(Notification,[{key:"handleDismiss",value:function(e){var t;return a.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:if(e.persist(),e.preventDefault(),!(t=this.props.onDismiss)){n.next=6;break}return n.next=6,a.a.awrap(t(e));case 6:this.dismiss();case 7:case"end":return n.stop()}}),null,this)}},{key:"dismiss",value:function(){var e=this,t=this.cardRef.current;this.setState({isClosed:!0}),setTimeout((function(){C.c.setCache("notification::dismissed::".concat(e.props.id),new Date),t.style.display="none";var n=new Event("notificationDismissed");document.dispatchEvent(n)}),350)}},{key:"handleCTAClick",value:function(e){var t,n,r;return a.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:if(e.persist(),t=this.props,n=t.isDismissable,!(r=t.onCTAClick)){i.next=5;break}return i.next=5,a.a.awrap(r(e));case 5:n&&this.dismiss();case 6:case"end":return i.stop()}}),null,this)}},{key:"expireDismiss",value:function(){var e=this.props,t=e.id,n=e.dismissExpires,r=C.c.getCache("notification::dismissed::".concat(t));if(r){var i=new Date(r);i.setSeconds(i.getSeconds()+parseInt(n,10)),i<new Date&&C.c.deleteCache("notification::dismissed::".concat(t))}}},{key:"render",value:function(){var t,n=this.state.isClosed,r=this.props,o=r.children,a=r.id,u=r.title,s=r.description,c=r.blockData,l=r.winImage,d=r.smallImage,f=r.format,p=r.learnMoreURL,h=r.learnMoreDescription,_=r.learnMoreLabel,m=r.ctaLink,g=r.ctaLabel,y=r.ctaTarget,v=r.type,b=r.dismiss,I=r.isDismissable,F=r.logo,L=r.module,N=r.moduleName,P=r.pageIndex;if(C.c.getCache("notification::dismissed::".concat(a)))return null;var R,j=n?"is-closed":"is-open",H="large"===f&&"win-stats-increase"===v,B="mdc-layout-grid__cell--span-12";"large"===f?(B="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&&(B="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"===f&&(B="mdc-layout-grid__cell--span-11-desktop mdc-layout-grid__cell--span-7-tablet mdc-layout-grid__cell--span-3-phone"),R="win-warning"===v?e.createElement(T.a,null):"win-error"===v?e.createElement(S.a,null):"";var U=e.createElement(k.Fragment,null,c&&e.createElement("div",{className:"mdc-layout-grid__inner"},Object(D.map)(c,(function(t,n){return e.createElement("div",{key:n,className:w()("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(E.a,t)))})))),z=e.createElement(k.Fragment,null,u&&e.createElement("h3",{className:"googlesitekit-heading-2 googlesitekit-publisher-win__title"},u),s&&e.createElement("div",{className:"googlesitekit-publisher-win__desc"},e.createElement("p",null,Object(k.isValidElement)(s)?s:e.createElement("span",{dangerouslySetInnerHTML:Object(A.a)(s,{ALLOWED_TAGS:["strong","em","br","a"],ALLOWED_ATTR:["href"]})}),_&&e.createElement(k.Fragment,null," ",e.createElement(x.a,{href:p,external:!0,inherit:!0},_),h),P&&e.createElement("span",{className:"googlesitekit-publisher-win__detect"},P))),o),V=L?e.createElement(M.a,{id:L,height:"19",width:"19"}):e.createElement(M.a,{id:"logo-g",height:"34",width:"32"});return e.createElement("section",{ref:this.cardRef,className:w()("googlesitekit-publisher-win",(t={},i()(t,"googlesitekit-publisher-win--".concat(f),f),i()(t,"googlesitekit-publisher-win--".concat(v),v),i()(t,"googlesitekit-publisher-win--".concat(j),j),t))},e.createElement("div",{className:"mdc-layout-grid"},e.createElement("div",{className:"mdc-layout-grid__inner"},F&&e.createElement("div",{className:w()("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),N&&e.createElement("div",{className:"googlesitekit-publisher-win__module-name"},N)),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:w()("mdc-layout-grid__cell",B)},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"},z),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"},U)):e.createElement(k.Fragment,null,z,U),m&&e.createElement(O.a,{href:m,target:y,onClick:this.handleCTAClick},g),I&&b&&e.createElement(x.a,{onClick:this.handleDismiss},b)),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"===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"},R)))))}}]),Notification}(k.Component);F.propTypes={id:b.a.string.isRequired,title:b.a.string.isRequired,description:b.a.node,learnMoreURL:b.a.string,learnMoreDescription:b.a.string,learnMoreLabel:b.a.string,blockData:b.a.array,winImage:b.a.string,smallImage:b.a.string,format:b.a.string,ctaLink:b.a.string,ctaLabel:b.a.string,type:b.a.string,dismiss:b.a.string,isDismissable:b.a.bool,logo:b.a.bool,module:b.a.string,moduleName:b.a.string,pageIndex:b.a.string,dismissExpires:b.a.number,showOnce:b.a.bool,onCTAClick:b.a.func,onDismiss:b.a.func},F.defaultProps={isDismissable:!0,dismissExpires:0,showOnce:!1},t.a=F}).call(this,n(1))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(14),m=n.n(_),g=n(1),y=function(t){function ProgressBar(){return i()(this,ProgressBar),s()(this,l()(ProgressBar).apply(this,arguments))}return f()(ProgressBar,t),a()(ProgressBar,[{key:"render",value:function(){var t=this.props,n=t.className,r=t.small,i=t.compress,o=t.height,a=o?Math.round(o/2):null;return e.createElement("div",{role:"progressbar",style:{marginTop:a,marginBottom:a},className:m()("mdc-linear-progress","mdc-linear-progress--indeterminate",n,{"mdc-linear-progress--small":r,"mdc-linear-progress--compress":i})},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}(g.Component);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(1))},function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(25),h=n(2),_=n.n(h),m=n(14),g=n.n(m),y=n(1),v=function(t){function Button(e){var t;return i()(this,Button),(t=s()(this,l()(Button).call(this,e))).buttonRef=Object(y.createRef)(),t}return f()(Button,t),a()(Button,[{key:"componentDidMount",value:function(){new p.h(this.buttonRef.current)}},{key:"render",value:function(){var t=this.props,n=t.onClick,r=t.children,i=t.href,o=t.text,a=t.className,u=t.danger,s=t.disabled,c=t.target,l=t.id,d=t.icon,f=t.trailingIcon,p=t.ariaHaspopup,h=t.ariaExpanded,_=t.ariaControls,m=i&&!s?"a":"button";return e.createElement(m,{className:g()("mdc-button",a,{"mdc-button--raised":!o,"mdc-button--danger":u}),onClick:n,href:s?void 0:i,ref:this.buttonRef,disabled:!!s,target:c||"_self",id:l,"aria-haspopup":p,"aria-expanded":h,"aria-controls":_},d&&d,e.createElement("span",{className:"mdc-button__label"},r),f&&f)}}]),Button}(y.Component);v.propTypes={onClick:_.a.func,children:_.a.string.isRequired,href:_.a.string,text:_.a.bool,className:_.a.string,danger:_.a.bool,disabled:_.a.bool,icon:_.a.element,trailingIcon:_.a.element,ariaHaspopup:_.a.string,ariaExpanded:_.a.bool,ariaControls:_.a.string},v.defaultProps={onClick:null,href:null,text:!1,className:"",danger:!1,disabled:!1,icon:null,trailingIcon:null,ariaHaspopup:"",ariaExpanded:!1,ariaControls:""},t.a=v}).call(this,n(1))},function(e,t,n){"use strict";n.d(t,"a",(function(){return s}));var r=n(17),i=n(30),o=n(35),a=n(42),u=n(43),s=function(e){function MDCRipple(){var t=null!==e&&e.apply(this,arguments)||this;return t.disabled=!1,t}return r.b(MDCRipple,e),MDCRipple.attachTo=function(e,t){void 0===t&&(t={isUnbounded:void 0});var n=new MDCRipple(e);return void 0!==t.isUnbounded&&(n.unbounded=t.isUnbounded),n},MDCRipple.createAdapter=function(e){return{addClass:function(t){return e.root_.classList.add(t)},browserSupportsCssVars:function(){return u.c(window)},computeBoundingRect:function(){return e.root_.getBoundingClientRect()},containsEventTarget:function(t){return e.root_.contains(t)},deregisterDocumentInteractionHandler:function(e,t){return document.documentElement.removeEventListener(e,t,u.a())},deregisterInteractionHandler:function(t,n){return e.root_.removeEventListener(t,n,u.a())},deregisterResizeHandler:function(e){return window.removeEventListener("resize",e)},getWindowPageOffset:function(){return{x:window.pageXOffset,y:window.pageYOffset}},isSurfaceActive:function(){return Object(o.b)(e.root_,":active")},isSurfaceDisabled:function(){return Boolean(e.disabled)},isUnbounded:function(){return Boolean(e.unbounded)},registerDocumentInteractionHandler:function(e,t){return document.documentElement.addEventListener(e,t,u.a())},registerInteractionHandler:function(t,n){return e.root_.addEventListener(t,n,u.a())},registerResizeHandler:function(e){return window.addEventListener("resize",e)},removeClass:function(t){return e.root_.classList.remove(t)},updateCssVariable:function(t,n){return e.root_.style.setProperty(t,n)}}},Object.defineProperty(MDCRipple.prototype,"unbounded",{get:function(){return Boolean(this.unbounded_)},set:function(e){this.unbounded_=Boolean(e),this.setUnbounded_()},enumerable:!0,configurable:!0}),MDCRipple.prototype.activate=function(){this.foundation_.activate()},MDCRipple.prototype.deactivate=function(){this.foundation_.deactivate()},MDCRipple.prototype.layout=function(){this.foundation_.layout()},MDCRipple.prototype.getDefaultFoundation=function(){return new a.a(MDCRipple.createAdapter(this))},MDCRipple.prototype.initialSyncWithDOM=function(){var e=this.root_;this.unbounded="mdcRippleIsUnbounded"in e.dataset},MDCRipple.prototype.setUnbounded_=function(){this.foundation_.setUnbounded(Boolean(this.unbounded_))},MDCRipple}(i.a)},function(e,t,n){"use strict";function r(e,t){if(e.closest)return e.closest(t);for(var n=e;n;){if(i(n,t))return n;n=n.parentElement}return null}function i(e,t){return(e.matches||e.webkitMatchesSelector||e.msMatchesSelector).call(e,t)}n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i}))},function(e,t,n){"use strict";var r=n(49);Object.defineProperty(t,"__esModule",{value:!0}),t.default=void 0;var i=r(n(50)),o=r(n(112)),a=n(0),u=r(n(164)),s=r(n(165)),c=r(n(166)),l=r(n(167)),d=r(n(113)),f=r(n(173)),p=r(n(174)),h=r(n(175)),_=n(116),m={Accept:"application/json, */*;q=0.1"},g={credentials:"include"},y=[p.default,d.default,f.default,l.default];var v=function(e){if(e.status>=200&&e.status<300)return e;throw e},b=function(e){var t=e.url,n=e.path,r=e.data,u=e.parse,s=void 0===u||u,c=(0,o.default)(e,["url","path","data","parse"]),l=e.body,d=e.headers;return d=(0,i.default)({},m,d),r&&(l=JSON.stringify(r),d["Content-Type"]="application/json"),window.fetch(t||n,(0,i.default)({},g,c,{body:l,headers:d})).then((function(e){return Promise.resolve(e).then(v).catch((function(e){return(0,_.parseAndThrowError)(e,s)})).then((function(e){return(0,_.parseResponseAndNormalizeError)(e,s)}))}),(function(){throw{code:"fetch_error",message:(0,a.__)("You are probably offline.")}}))};function C(e){var t=[].concat(y,[b]);return new Promise((function(n,r){(function e(n){return function(r){var i=t[n];return n===t.length-1?i(r):i(r,e(n+1))}})(0)(e).then(n).catch((function(t){if("rest_cookie_invalid_nonce"!==t.code)return r(t);window.fetch(C.nonceEndpoint).then(v).then((function(e){return e.text()})).then((function(t){C.nonceMiddleware.nonce=t,C(e).then(n).catch(r)})).catch(r)}))}))}C.use=function(e){y.unshift(e)},C.setFetchHandler=function(e){b=e},C.createNonceMiddleware=u.default,C.createPreloadingMiddleware=c.default,C.createRootURLMiddleware=s.default,C.fetchAllMiddleware=l.default,C.mediaUploadMiddleware=h.default;var E=C;t.default=E},,function(e,t){function n(e){return(n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function r(t){return"function"==typeof Symbol&&"symbol"===n(Symbol.iterator)?e.exports=r=function(e){return n(e)}:e.exports=r=function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":n(e)},r(t)}e.exports=r},function(e,t,n){"use strict";function r(e){return{byContext:function(t){return e.filter((function(e){return e.usageContext.includes(t)}))}}}function i(e){return(parseInt(e)||0)>0}function o(e){return!!e&&e.toString().match(/^GTM-[A-Z0-9]+$/)}var 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]+)['|"]/];n.d(t,"a",(function(){return r})),n.d(t,"b",(function(){return i})),n.d(t,"c",(function(){return o})),n.d(t,"d",(function(){return a}))},,,function(e,t,n){"use strict";var r=n(17),i=n(28),o={BG_FOCUSED:"mdc-ripple-upgraded--background-focused",FG_ACTIVATION:"mdc-ripple-upgraded--foreground-activation",FG_DEACTIVATION:"mdc-ripple-upgraded--foreground-deactivation",ROOT:"mdc-ripple-upgraded",UNBOUNDED:"mdc-ripple-upgraded--unbounded"},a={VAR_FG_SCALE:"--mdc-ripple-fg-scale",VAR_FG_SIZE:"--mdc-ripple-fg-size",VAR_FG_TRANSLATE_END:"--mdc-ripple-fg-translate-end",VAR_FG_TRANSLATE_START:"--mdc-ripple-fg-translate-start",VAR_LEFT:"--mdc-ripple-left",VAR_TOP:"--mdc-ripple-top"},u={DEACTIVATION_TIMEOUT_MS:225,FG_DEACTIVATION_MS:150,INITIAL_ORIGIN_SCALE:.6,PADDING:10,TAP_DELAY_MS:300},s=n(43);n.d(t,"a",(function(){return f}));var c=["touchstart","pointerdown","mousedown","keydown"],l=["touchend","pointerup","mouseup","contextmenu"],d=[],f=function(e){function MDCRippleFoundation(t){var n=e.call(this,r.a({},MDCRippleFoundation.defaultAdapter,t))||this;return n.activationAnimationHasEnded_=!1,n.activationTimer_=0,n.fgDeactivationRemovalTimer_=0,n.fgScale_="0",n.frame_={width:0,height:0},n.initialSize_=0,n.layoutFrame_=0,n.maxRadius_=0,n.unboundedCoords_={left:0,top:0},n.activationState_=n.defaultActivationState_(),n.activationTimerCallback_=function(){n.activationAnimationHasEnded_=!0,n.runDeactivationUXLogicIfReady_()},n.activateHandler_=function(e){return n.activate_(e)},n.deactivateHandler_=function(){return n.deactivate_()},n.focusHandler_=function(){return n.handleFocus()},n.blurHandler_=function(){return n.handleBlur()},n.resizeHandler_=function(){return n.layout()},n}return r.b(MDCRippleFoundation,e),Object.defineProperty(MDCRippleFoundation,"cssClasses",{get:function(){return o},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"strings",{get:function(){return a},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"numbers",{get:function(){return u},enumerable:!0,configurable:!0}),Object.defineProperty(MDCRippleFoundation,"defaultAdapter",{get:function(){return{addClass:function(){},browserSupportsCssVars:function(){return!0},computeBoundingRect:function(){return{top:0,right:0,bottom:0,left:0,width:0,height:0}},containsEventTarget:function(){return!0},deregisterDocumentInteractionHandler:function(){},deregisterInteractionHandler:function(){},deregisterResizeHandler:function(){},getWindowPageOffset:function(){return{x:0,y:0}},isSurfaceActive:function(){return!0},isSurfaceDisabled:function(){return!0},isUnbounded:function(){return!0},registerDocumentInteractionHandler:function(){},registerInteractionHandler:function(){},registerResizeHandler:function(){},removeClass:function(){},updateCssVariable:function(){}}},enumerable:!0,configurable:!0}),MDCRippleFoundation.prototype.init=function(){var e=this,t=this.supportsPressRipple_();if(this.registerRootHandlers_(t),t){var n=MDCRippleFoundation.cssClasses,r=n.ROOT,i=n.UNBOUNDED;requestAnimationFrame((function(){e.adapter_.addClass(r),e.adapter_.isUnbounded()&&(e.adapter_.addClass(i),e.layoutInternal_())}))}},MDCRippleFoundation.prototype.destroy=function(){var e=this;if(this.supportsPressRipple_()){this.activationTimer_&&(clearTimeout(this.activationTimer_),this.activationTimer_=0,this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_ACTIVATION)),this.fgDeactivationRemovalTimer_&&(clearTimeout(this.fgDeactivationRemovalTimer_),this.fgDeactivationRemovalTimer_=0,this.adapter_.removeClass(MDCRippleFoundation.cssClasses.FG_DEACTIVATION));var t=MDCRippleFoundation.cssClasses,n=t.ROOT,r=t.UNBOUNDED;requestAnimationFrame((function(){e.adapter_.removeClass(n),e.adapter_.removeClass(r),e.removeCssVars_()}))}this.deregisterRootHandlers_(),this.deregisterDeactivationHandlers_()},MDCRippleFoundation.prototype.activate=function(e){this.activate_(e)},MDCRippleFoundation.prototype.deactivate=function(){this.deactivate_()},MDCRippleFoundation.prototype.layout=function(){var e=this;this.layoutFrame_&&cancelAnimationFrame(this.layoutFrame_),this.layoutFrame_=requestAnimationFrame((function(){e.layoutInternal_(),e.layoutFrame_=0}))},MDCRippleFoundation.prototype.setUnbounded=function(e){var t=MDCRippleFoundation.cssClasses.UNBOUNDED;e?this.adapter_.addClass(t):this.adapter_.removeClass(t)},MDCRippleFoundation.prototype.handleFocus=function(){var e=this;requestAnimationFrame((function(){return e.adapter_.addClass(MDCRippleFoundation.cssClasses.BG_FOCUSED)}))},MDCRippleFoundation.prototype.handleBlur=function(){var e=this;requestAnimationFrame((function(){return e.adapter_.removeClass(MDCRippleFoundation.cssClasses.BG_FOCUSED)}))},MDCRippleFoundation.prototype.supportsPressRipple_=function(){return this.adapter_.browserSupportsCssVars()},MDCRippleFoundation.prototype.defaultActivationState_=function(){return{activationEvent:void 0,hasDeactivationUXRun:!1,isActivated:!1,isProgrammatic:!1,wasActivatedByPointer:!1,wasElementMadeActive:!1}},MDCRippleFoundation.prototype.registerRootHandlers_=function(e){var t=this;e&&(c.forEach((function(e){t.adapter_.registerInteractionHandler(e,t.activateHandler_)})),this.adapter_.isUnbounded()&&this.adapter_.registerResizeHandler(this.resizeHandler_)),this.adapter_.registerInteractionHandler("focus",this.focusHandler_),this.adapter_.registerInteractionHandler("blur",this.blurHandler_)},MDCRippleFoundation.prototype.registerDeactivationHandlers_=function(e){var t=this;"keydown"===e.type?this.adapter_.registerInteractionHandler("keyup",this.deactivateHandler_):l.forEach((function(e){t.adapter_.registerDocumentInteractionHandler(e,t.deactivateHandler_)}))},MDCRippleFoundation.prototype.deregisterRootHandlers_=function(){var e=this;c.forEach((function(t){e.adapter_.deregisterInteractionHandler(t,e.activateHandler_)})),this.adapter_.deregisterInteractionHandler("focus",this.focusHandler_),this.adapter_.deregisterInteractionHandler("blur",this.blurHandler_),this.adapter_.isUnbounded()&&this.adapter_.deregisterResizeHandler(this.resizeHandler_)},MDCRippleFoundation.prototype.deregisterDeactivationHandlers_=function(){var e=this;this.adapter_.deregisterInteractionHandler("keyup",this.deactivateHandler_),l.forEach((function(t){e.adapter_.deregisterDocumentInteractionHandler(t,e.deactivateHandler_)}))},MDCRippleFoundation.prototype.removeCssVars_=function(){var e=this,t=MDCRippleFoundation.strings;Object.keys(t).forEach((function(n){0===n.indexOf("VAR_")&&e.adapter_.updateCssVariable(t[n],null)}))},MDCRippleFoundation.prototype.activate_=function(e){var t=this;if(!this.adapter_.isSurfaceDisabled()){var n=this.activationState_;if(!n.isActivated){var r=this.previousActivationEvent_;if(!(r&&void 0!==e&&r.type!==e.type))n.isActivated=!0,n.isProgrammatic=void 0===e,n.activationEvent=e,n.wasActivatedByPointer=!n.isProgrammatic&&(void 0!==e&&("mousedown"===e.type||"touchstart"===e.type||"pointerdown"===e.type)),void 0!==e&&d.length>0&&d.some((function(e){return t.adapter_.containsEventTarget(e)}))?this.resetActivationState_():(void 0!==e&&(d.push(e.target),this.registerDeactivationHandlers_(e)),n.wasElementMadeActive=this.checkElementMadeActive_(e),n.wasElementMadeActive&&this.animateActivation_(),requestAnimationFrame((function(){d=[],n.wasElementMadeActive||void 0===e||" "!==e.key&&32!==e.keyCode||(n.wasElementMadeActive=t.checkElementMadeActive_(e),n.wasElementMadeActive&&t.animateActivation_()),n.wasElementMadeActive||(t.activationState_=t.defaultActivationState_())})))}}},MDCRippleFoundation.prototype.checkElementMadeActive_=function(e){return void 0===e||"keydown"!==e.type||this.adapter_.isSurfaceActive()},MDCRippleFoundation.prototype.animateActivation_=function(){var e=this,t=MDCRippleFoundation.strings,n=t.VAR_FG_TRANSLATE_START,r=t.VAR_FG_TRANSLATE_END,i=MDCRippleFoundation.cssClasses,o=i.FG_DEACTIVATION,a=i.FG_ACTIVATION,u=MDCRippleFoundation.numbers.DEACTIVATION_TIMEOUT_MS;this.layoutInternal_();var s="",c="";if(!this.adapter_.isUnbounded()){var l=this.getFgTranslationCoordinates_(),d=l.startPoint,f=l.endPoint;s=d.x+"px, "+d.y+"px",c=f.x+"px, "+f.y+"px"}this.adapter_.updateCssVariable(n,s),this.adapter_.updateCssVariable(r,c),clearTimeout(this.activationTimer_),clearTimeout(this.fgDeactivationRemovalTimer_),this.rmBoundedActivationClasses_(),this.adapter_.removeClass(o),this.adapter_.computeBoundingRect(),this.adapter_.addClass(a),this.activationTimer_=setTimeout((function(){return e.activationTimerCallback_()}),u)},MDCRippleFoundation.prototype.getFgTranslationCoordinates_=function(){var e,t=this.activationState_,n=t.activationEvent;return{startPoint:e={x:(e=t.wasActivatedByPointer?Object(s.b)(n,this.adapter_.getWindowPageOffset(),this.adapter_.computeBoundingRect()):{x:this.frame_.width/2,y:this.frame_.height/2}).x-this.initialSize_/2,y:e.y-this.initialSize_/2},endPoint:{x:this.frame_.width/2-this.initialSize_/2,y:this.frame_.height/2-this.initialSize_/2}}},MDCRippleFoundation.prototype.runDeactivationUXLogicIfReady_=function(){var e=this,t=MDCRippleFoundation.cssClasses.FG_DEACTIVATION,n=this.activationState_,r=n.hasDeactivationUXRun,i=n.isActivated;(r||!i)&&this.activationAnimationHasEnded_&&(this.rmBoundedActivationClasses_(),this.adapter_.addClass(t),this.fgDeactivationRemovalTimer_=setTimeout((function(){e.adapter_.removeClass(t)}),u.FG_DEACTIVATION_MS))},MDCRippleFoundation.prototype.rmBoundedActivationClasses_=function(){var e=MDCRippleFoundation.cssClasses.FG_ACTIVATION;this.adapter_.removeClass(e),this.activationAnimationHasEnded_=!1,this.adapter_.computeBoundingRect()},MDCRippleFoundation.prototype.resetActivationState_=function(){var e=this;this.previousActivationEvent_=this.activationState_.activationEvent,this.activationState_=this.defaultActivationState_(),setTimeout((function(){return e.previousActivationEvent_=void 0}),MDCRippleFoundation.numbers.TAP_DELAY_MS)},MDCRippleFoundation.prototype.deactivate_=function(){var e=this,t=this.activationState_;if(t.isActivated){var n=r.a({},t);t.isProgrammatic?(requestAnimationFrame((function(){return e.animateDeactivation_(n)})),this.resetActivationState_()):(this.deregisterDeactivationHandlers_(),requestAnimationFrame((function(){e.activationState_.hasDeactivationUXRun=!0,e.animateDeactivation_(n),e.resetActivationState_()})))}},MDCRippleFoundation.prototype.animateDeactivation_=function(e){var t=e.wasActivatedByPointer,n=e.wasElementMadeActive;(t||n)&&this.runDeactivationUXLogicIfReady_()},MDCRippleFoundation.prototype.layoutInternal_=function(){var e=this;this.frame_=this.adapter_.computeBoundingRect();var t=Math.max(this.frame_.height,this.frame_.width);this.maxRadius_=this.adapter_.isUnbounded()?t:Math.sqrt(Math.pow(e.frame_.width,2)+Math.pow(e.frame_.height,2))+MDCRippleFoundation.numbers.PADDING,this.initialSize_=Math.floor(t*MDCRippleFoundation.numbers.INITIAL_ORIGIN_SCALE),this.fgScale_=""+this.maxRadius_/this.initialSize_,this.updateLayoutCssVars_()},MDCRippleFoundation.prototype.updateLayoutCssVars_=function(){var e=MDCRippleFoundation.strings,t=e.VAR_FG_SIZE,n=e.VAR_LEFT,r=e.VAR_TOP,i=e.VAR_FG_SCALE;this.adapter_.updateCssVariable(t,this.initialSize_+"px"),this.adapter_.updateCssVariable(i,this.fgScale_),this.adapter_.isUnbounded()&&(this.unboundedCoords_={left:Math.round(this.frame_.width/2-this.initialSize_/2),top:Math.round(this.frame_.height/2-this.initialSize_/2)},this.adapter_.updateCssVariable(n,this.unboundedCoords_.left+"px"),this.adapter_.updateCssVariable(r,this.unboundedCoords_.top+"px"))},MDCRippleFoundation}(i.a)},function(e,t,n){"use strict";var r,i;function o(e,t){void 0===t&&(t=!1);var n=e.CSS,i=r;if("boolean"==typeof r&&!t)return r;if(!(n&&"function"==typeof n.supports))return!1;var o=n.supports("--css-vars","yes"),a=n.supports("(--css-vars: yes)")&&n.supports("color","#00000000");return i=!(!o&&!a)&&!function(e){var t=e.document,n=t.createElement("div");n.className="mdc-ripple-surface--test-edge-var-bug",t.body.appendChild(n);var r=e.getComputedStyle(n),i=null!==r&&"solid"===r.borderTopStyle;return n.parentNode&&n.parentNode.removeChild(n),i}(e),t||(r=i),i}function a(e,t){if(void 0===e&&(e=window),void 0===t&&(t=!1),void 0===i||t){var n=!1;try{e.document.addEventListener("test",(function(){}),{get passive(){return n=!0}})}catch(e){}i=n}return!!i&&{passive:!0}}function u(e,t,n){if(!e)return{x:0,y:0};var r,i,o=t.x,a=t.y,u=o+n.left,s=a+n.top;if("touchstart"===e.type){var c=e;r=c.changedTouches[0].pageX-u,i=c.changedTouches[0].pageY-s}else{var l=e;r=l.pageX-u,i=l.pageY-s}return{x:r,y:i}}n.d(t,"c",(function(){return o})),n.d(t,"a",(function(){return a})),n.d(t,"b",(function(){return u}))},,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(48);function i(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",t=arguments.length>1?arguments[1]:void 0;if(!t||!Object.keys(t).length)return e;var n=e,i=e.indexOf("?");return-1!==i&&(t=Object.assign(Object(r.parse)(e.substr(i+1)),t),n=n.substr(0,i)),n+"?"+Object(r.stringify)(t)}},,,function(e,t,n){"use strict";var r=n(171),i=n(172),o=n(115);e.exports={formats:o,parse:i,stringify:r}},function(e,t){e.exports=function(e){return e&&e.__esModule?e:{default:e}}},function(e,t,n){var r=n(162);e.exports=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{},i=Object.keys(Object(n));"function"==typeof Object.getOwnPropertySymbols&&(i=i.concat(Object.getOwnPropertySymbols(n).filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable})))),i.forEach((function(t){r(e,t,n[t])}))}return e}},function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return i})),n.d(t,"b",(function(){return a}));var r=n(63),i="_googlesitekitDataLayer",o="data-googlesitekit-gtag";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,"]"))){var r=n.createElement("script");r.setAttribute(o,""),r.async=!0,r.src="https://www.googletagmanager.com/gtag/js?id=".concat(t.trackingID,"&l=").concat(i),n.head.appendChild(r),a("js",new Date),a("config",t.trackingID)}}}}).call(this,n(15))},function(e,t,n){"use strict";(function(e){var r=n(36),i=n.n(r);e._googlesitekitAPIFetchData&&(e._googlesitekitAPIFetchData.rootURL&&i.a.use(i.a.createRootURLMiddleware(e._googlesitekitAPIFetchData.rootURL)),e._googlesitekitAPIFetchData.nonceMiddleware&&(i.a.nonceMiddleware=i.a.createNonceMiddleware(),i.a.use(i.a.createNonceMiddleware(e._googlesitekitAPIFetchData.nonceMiddleware)),i.a.use(i.a.mediaUploadMiddleware),i.a.nonceEndpoint=e._googlesitekitAPIFetchData.nonceEndpoint)),t.default=i.a}).call(this,n(15))},function(e,t,n){var r=n(141),i=n(142),o=n(143);e.exports=function(e,t){return r(e)||i(e,t)||o()}},,function(e,t,n){"use strict";(function(e){n.d(t,"a",(function(){return c})),n.d(t,"b",(function(){return d})),n.d(t,"c",(function(){return l}));var r=n(94),i=e._googlesitekitBaseData||{},o={isFirstAdmin:i.isFirstAdmin,trackingEnabled:i.trackingEnabled,trackingID:i.trackingID,referenceSiteURL:i.referenceSiteURL,userIDHash:i.userIDHash},a=Object(r.a)(o),u=a.enableTracking,s=a.disableTracking,c=a.isTrackingEnabled,l=a.trackEvent;function d(e){e?u():s()}d(c())}).call(this,n(15))},,,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(2),h=n.n(p),_=n(19),m=n(14),g=n.n(m),y=n(1),v=n(0),b=function(t){function SourceLink(){return i()(this,SourceLink),s()(this,l()(SourceLink).apply(this,arguments))}return f()(SourceLink,t),a()(SourceLink,[{key:"render",value:function(){var t=this.props,n=t.name,r=t.href,i=t.className,o=t.external;return e.createElement("div",{className:g()("googlesitekit-source-link",i)},[Object(v.__)("Source:","google-site-kit")," ",e.createElement(_.a,{key:"link",href:r,external:o,inherit:!0},n)])}}]),SourceLink}(y.Component);b.propTypes={name:h.a.string,href:h.a.string,className:h.a.string,external:h.a.bool},b.defaultProps={name:"",href:"",className:"",external:!1},t.a=b}).call(this,n(1))},function(e,t,n){"use strict";(function(e){n.d(t,"g",(function(){return d})),n.d(t,"f",(function(){return f})),n.d(t,"c",(function(){return p})),n.d(t,"b",(function(){return m})),n.d(t,"d",(function(){return g})),n.d(t,"e",(function(){return y})),n.d(t,"a",(function(){return v}));var r=n(11),i=n.n(r),o=n(10),a=n(3),u=n(157),s=n(12),c=n(13),l=Object(s.c)("googlesitekit.winCallbacks",{}),d=function(){return Object(s.c)("googlesitekit.WinsNotificationsRequest",[])},f=function(){return Object(s.c)("googlesitekit.ModulesNotificationsRequest",[])};function p(){var t,n,r,o;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:if((t=e.googlesitekit.setup).isSiteKitConnected&&(t.isAuthenticated||t.isVerified)){a.next=3;break}return a.abrupt("return",0);case 3:return n=0,a.next=6,i.a.awrap(m());case 6:return(r=a.sent)&&r.total&&(n+=r.total),a.next=10,i.a.awrap(g());case 10:return(o=a.sent)&&o.total&&(n+=o.total),n=Object(s.c)("googlesitekit.TotalNotifications",n),n=Math.max(0,Math.abs(n)),e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),a.abrupt("return",n);case 16:case"end":return a.stop()}}))}var h=function(e){return e?e.length?e.filter((function(e){return!o.c.getCache("notification::dismissed::".concat(e.id))})):e:[]},_=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=o.c.getCache("notification::displayed::".concat(e[0].id));if(t){var n=new Date(t),r=new Date,i=new Date(Date.UTC(r.getUTCFullYear(),r.getUTCMonth(),r.getUTCDate()));if(n.setHours(0,0,0),i.setHours(0,0,0),n.getTime()===i.getTime())return!0;7<=Object(a.i)(n,i)&&o.c.deleteCache("notification::displayed::".concat(e[0].id))}return null===t})),r=null,i=[];return 0<Object.keys(n).length?(r=t(n),i[Object.keys(n)[0]]=r):(r=t(e),i[Object.keys(e)[0]]=r)};function m(){var e,t,n,r;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return e={},t=0,a.next=4,i.a.awrap(f());case 4:return n=a.sent,r=[],n.map((function(e){var t;return i.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:t=new Promise((function(t){var n,r;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return n=e.identifier,a.t0=h,a.next=4,i.a.awrap(o.c.get(o.b,n,"notifications",{},!1));case 4:a.t1=a.sent,r=(0,a.t0)(a.t1),t({identifier:n,notifications:r});case 7:case"end":return a.stop()}}))})),r.push(t);case 2:case"end":return n.stop()}}))})),a.next=9,i.a.awrap(Promise.all(r).then((function(n){n.forEach((function(n){n.notifications.length&&(t+=n.notifications.length,e[n.identifier]=n.notifications)}))})));case 9:return a.abrupt("return",{results:e,total:t});case 10:case"end":return a.stop()}}))}function g(){var e,t,n,r,o;return i.a.async((function(a){for(;;)switch(a.prev=a.next){case 0:return e={},t=0,a.next=4,i.a.awrap(d());case 4:return n=a.sent,a.next=7,i.a.awrap(new u.a(n).get());case 7:return r=a.sent,o=[],n.map((function(e){var t;return i.a.async((function(n){for(;;)switch(n.prev=n.next){case 0:t=new Promise((function(t){var n,o,a,u,s;return i.a.async((function(i){for(;;)switch(i.prev=i.next){case 0:n=e.identifier,o=e.callback||Object(c.camelCase)(n),a=null,u=[],e.withData?(s=r[n]||null,a=l[o](s,n)):a=l[o](n),u=h(u=a?[a]:[]),t({identifier:n,notifications:u});case 8:case"end":return i.stop()}}))})),o.push(t);case 2:case"end":return n.stop()}}))})),a.next=12,i.a.awrap(Promise.all(o).then((function(t){t.forEach((function(t){t.notifications.length&&(e[t.identifier]=t.notifications)}))})));case 12:return e=_(e),t=e.length||Object.keys(e).length||0,a.abrupt("return",{results:e,total:t});case 15:case"end":return a.stop()}}))}var y=function(t){var n=Math.abs(t.count)+1;return e.localStorage&&e.localStorage.setItem("googlesitekit::total-notifications",n),{count:n}},v=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))},function(e,t,n){"use strict";function r(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function i(e){return(i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e,t){return!t||"object"!==i(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function a(e){return(a=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}var s=n(1),c=n(13),l=n(12);var d=function(e,t){return function(n){var r=e(n),i=n.displayName,o=void 0===i?n.name||"Component":i;return r.displayName="".concat(Object(c.upperFirst)(Object(c.camelCase)(t)),"(").concat(o,")"),r}};n.d(t,"a",(function(){return p}));var f=16;function p(e){return d((function(t){var n,i="core/with-filters/"+e;var d=function(d){function FilteredComponentRenderer(){var r;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,FilteredComponentRenderer),r=o(this,a(FilteredComponentRenderer).apply(this,arguments)),void 0===n&&(n=Object(l.c)(e,t)),r}var f,p,_;return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(FilteredComponentRenderer,d),f=FilteredComponentRenderer,(p=[{key:"componentDidMount",value:function(){FilteredComponentRenderer.instances.push(this),1===FilteredComponentRenderer.instances.length&&(Object(l.a)("hookRemoved",i,h),Object(l.a)("hookAdded",i,h))}},{key:"componentWillUnmount",value:function(){FilteredComponentRenderer.instances=Object(c.without)(FilteredComponentRenderer.instances,this),0===FilteredComponentRenderer.instances.length&&(Object(l.e)("hookRemoved",i),Object(l.e)("hookAdded",i))}},{key:"render",value:function(){return Object(s.createElement)(n,this.props)}}])&&r(f.prototype,p),_&&r(f,_),FilteredComponentRenderer}(s.Component);d.instances=[];var p=Object(c.debounce)((function(){n=Object(l.c)(e,t),d.instances.forEach((function(e){e.forceUpdate()}))}),f);function h(t){t===e&&p()}return d}),"withFilters")}},,,function(e,t,n){"use strict";n.d(t,"a",(function(){return i}));var r=n(51);function i(e){return function(){e[r.a]=e[r.a]||[],e[r.a].push(arguments)}}},function(e,t){function n(){return e.exports=n=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},n.apply(this,arguments)}e.exports=n},,,function(e,t,n){"use strict";(function(e){var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(31),h=n(1),_=function(t){function GenericError(){return i()(this,GenericError),s()(this,l()(GenericError).apply(this,arguments))}return f()(GenericError,t),a()(GenericError,[{key:"render",value:function(){return e.createElement(p.a,this.props)}}]),GenericError}(h.Component);t.a=_}).call(this,n(1))},function(e,t,n){"use strict";var r=n(5),i=n.n(r),o=n(6),a=n.n(o),u=n(7),s=n.n(u),c=n(8),l=n.n(c),d=n(9),f=n.n(d),p=n(60),h=n(1),_=function(e){function ModuleSettingsWarning(){return i()(this,ModuleSettingsWarning),s()(this,l()(ModuleSettingsWarning).apply(this,arguments))}return f()(ModuleSettingsWarning,e),a()(ModuleSettingsWarning,[{key:"render",value:function(){return null}}]),ModuleSettingsWarning}(h.Component);t.a=Object(p.a)("googlesitekit.ModuleSettingsWarning")(_)},function(e,t,n){"use strict";n.r(t);var r=/^(?:https?:)?\/\/\S+$/i;function i(e){return r.test(e)}var o=/^(mailto:)?[a-z0-9._%+-]+@[a-z0-9][a-z0-9.-]*\.[a-z]{2,63}$/i;function a(e){return o.test(e)}function u(e){var t=/^([^\s:]+:)/.exec(e);if(t)return t[1]}function s(e){return!!e&&/^[a-z\-.\+]+[0-9]*:$/i.test(e)}function c(e){var t=/^[^\/\s:]+:(?:\/\/)?\/?([^\/\s#?]+)[\/#?]{0,1}\S*$/.exec(e);if(t)return t[1]}function l(e){return!!e&&/^[^\s#?]+$/.test(e)}function d(e){var t=/^[^\/\s:]+:(?:\/\/)?[^\/\s#?]+[\/]([^\s#?]+)[#?]{0,1}\S*$/.exec(e);if(t)return t[1]}function f(e){return!!e&&/^[^\s#?]+$/.test(e)}var p=n(90);function h(e){return!!e&&/^[^\s#?\/]+$/.test(e)}function _(e){var t=/^\S+?(#[^\s\?]*)/.exec(e);if(t)return t[1]}function m(e){return!!e&&/^#[^\s#?\/]*$/.test(e)}var g=n(45),y=n(71);function v(e,t){return void 0!==Object(y.a)(e,t)}var b=n(48);function C(e){for(var t=e.indexOf("?"),n=-1!==t?Object(b.parse)(e.substr(t+1)):{},r=-1!==t?e.substr(0,t):e,i=arguments.length,o=new Array(i>1?i-1:0),a=1;a<i;a++)o[a-1]=arguments[a];return o.forEach((function(e){return delete n[e]})),r+"?"+Object(b.stringify)(n)}var E=/^(?:[a-z]+:|#|\?|\.|\/)/i;function O(e){return e?(e=e.trim(),E.test(e)||a(e)?e:"http://"+e):e}function T(e){try{return decodeURI(e)}catch(t){return e}}function S(e){try{return decodeURIComponent(e)}catch(t){return e}}function x(e){var t=e.replace(/^(?:https?:)\/\/(?:www\.)?/,"");return t.match(/^[^\/]+\/$/)?t.replace("/",""):t}n.d(t,"isURL",(function(){return i})),n.d(t,"isEmail",(function(){return a})),n.d(t,"getProtocol",(function(){return u})),n.d(t,"isValidProtocol",(function(){return s})),n.d(t,"getAuthority",(function(){return c})),n.d(t,"isValidAuthority",(function(){return l})),n.d(t,"getPath",(function(){return d})),n.d(t,"isValidPath",(function(){return f})),n.d(t,"getQueryString",(function(){return p.a})),n.d(t,"isValidQueryString",(function(){return h})),n.d(t,"getFragment",(function(){return _})),n.d(t,"isValidFragment",(function(){return m})),n.d(t,"addQueryArgs",(function(){return g.a})),n.d(t,"getQueryArg",(function(){return y.a})),n.d(t,"hasQueryArg",(function(){return v})),n.d(t,"removeQueryArgs",(function(){return C})),n.d(t,"prependHTTP",(function(){return O})),n.d(t,"safeDecodeURI",(function(){return T})),n.d(t,"safeDecodeURIComponent",(function(){return S})),n.d(t,"filterURLForDisplay",(function(){return x}))},function(e,t,n){var r;"undefined"!=typeof self&&self,r=function(e,t,n,r,i){return function(e){var t={};function __webpack_require__(n){if(t[n])return t[n].exports;var r=t[n]={i:n,l:!1,exports:{}};return e[n].call(r.exports,r,r.exports,__webpack_require__),r.l=!0,r.exports}return __webpack_require__.m=e,__webpack_require__.c=t,__webpack_require__.d=function(e,t,n){__webpack_require__.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get: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="",__webpack_require__(__webpack_require__.s=227)}({0:function(t,n){t.exports=e},1:function(e,n){e.exports=t},22:function(e,t){e.exports=n},227:function(e,t,n){"use strict";var r,i=this&&this.__extends||(r=function(e,t){return(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])})(e,t)},function(e,t){function __(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(__.prototype=t.prototype,new __)}),o=this&&this.__assign||function(){return(o=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},a=this&&this.__rest||function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&(n[r[i]]=e[r[i]])}return n},u=this&&this.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(t,"__esModule",{value:!0});var s=u(n(0)),c=u(n(1)),l=n(228),d=u(n(230));t.Input=d.default;var f=u(n(231));t.Icon=f.default;var p=u(n(234));t.HelperText=p.default;var h=u(n(22)),_=u(n(23)),m=u(n(24)),g=l.MDCTextFieldFoundation.cssClasses,y=function(e){function TextField(t){var n,r=e.call(this,t)||this;return r.floatingLabelElement=s.default.createRef(),r.inputComponent_=null,t.children&&s.default.Children.only(t.children)&&(n=t.children.props.id),r.state={classList:new Set,inputId:n,isFocused:!1,dir:"ltr",disabled:!1,labelIsFloated:!1,initialLabelWidth:0,notchedLabelWidth:0,activeLineRipple:!1,lineRippleCenter:0,outlineIsNotched:!1,isValid:!0,foundation:void 0},r}return i(TextField,e),TextField.prototype.componentDidMount=function(){var e=new l.MDCTextFieldFoundation(this.adapter);this.setState({foundation:e}),e.init()},TextField.prototype.componentWillUnmount=function(){this.state.foundation.destroy()},Object.defineProperty(TextField.prototype,"classes",{get:function(){var e,t=this.state,n=t.classList,r=t.disabled,i=t.isFocused,o=t.isValid,a=this.props,u=a.className,s=a.dense,l=a.fullWidth,d=a.textarea,f=a.trailingIcon,p=a.leadingIcon;return c.default(g.ROOT,Array.from(n),u,((e={})[g.DENSE]=s,e[g.DISABLED]=r,e[g.FOCUSED]=i,e[g.INVALID]=!o,e[g.OUTLINED]=this.notchedOutlineAdapter.hasOutline()&&!l,e[g.TEXTAREA]=d,e[g.WITH_LEADING_ICON]=p,e["mdc-text-field--fullwidth"]=l,e["mdc-text-field--with-trailing-icon"]=f,e["mdc-text-field--no-label"]=!this.labelAdapter.hasLabel(),e))},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"otherProps",{get:function(){var e=this.props;return e.children,e.className,e.dense,e.floatingLabelClassName,e.fullWidth,e.helperText,e.label,e.leadingIcon,e.lineRippleClassName,e.notchedOutlineClassName,e.onLeadingIconSelect,e.onTrailingIconSelect,e.outlined,e.textarea,e.trailingIcon,a(e,["children","className","dense","floatingLabelClassName","fullWidth","helperText","label","leadingIcon","lineRippleClassName","notchedOutlineClassName","onLeadingIconSelect","onTrailingIconSelect","outlined","textarea","trailingIcon"])},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"adapter",{get:function(){var e=this,t={addClass:function(t){return e.setState({classList:e.state.classList.add(t)})},removeClass:function(t){var n=e.state.classList;n.delete(t),e.setState({classList:n})},hasClass:function(t){return e.classes.split(" ").includes(t)},registerTextFieldInteractionHandler:function(){},deregisterTextFieldInteractionHandler:function(){},registerValidationAttributeChangeHandler:function(){},deregisterValidationAttributeChangeHandler:function(){}};return Object.assign({},t,this.inputAdapter,this.labelAdapter,this.lineRippleAdapter,this.notchedOutlineAdapter)},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"inputAdapter",{get:function(){var e=this;return{isFocused:function(){return e.state.isFocused},getNativeInput:function(){var t=e.inputComponent_;if(t)return{disabled:t.isDisabled(),value:t.getValue(),maxLength:t.getMaxLength(),type:t.getInputType(),validity:{badInput:!!t.isBadInput(),valid:!!t.isValid()}};throw Error("MDCReactTextField: The input did not render properly")},registerInputInteractionHandler:function(){},deregisterInputInteractionHandler:function(){}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"labelAdapter",{get:function(){var e=this;return{shakeLabel:function(t){var n=e.floatingLabelElement;t&&n&&n.current&&n.current.shake()},floatLabel:function(t){return e.setState({labelIsFloated:t})},hasLabel:function(){return!!e.props.label&&!e.props.fullWidth},getLabelWidth:function(){return e.state.initialLabelWidth}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"lineRippleAdapter",{get:function(){var e=this;return{activateLineRipple:function(){return e.setState({activeLineRipple:!0})},deactivateLineRipple:function(){return e.setState({activeLineRipple:!1})},setLineRippleTransformOrigin:function(t){return e.setState({lineRippleCenter:t})}}},enumerable:!0,configurable:!0}),Object.defineProperty(TextField.prototype,"notchedOutlineAdapter",{get:function(){var e=this;return{notchOutline:function(t){return e.setState({outlineIsNotched:!0,notchedLabelWidth:t})},closeOutline:function(){return e.setState({outlineIsNotched:!1})},hasOutline:function(){return!!e.props.outlined||!!e.props.textarea}}},enumerable:!0,configurable:!0}),TextField.prototype.inputProps=function(e){var t=this,n=e.props;return Object.assign({},n,{foundation:this.state.foundation,handleFocusChange:function(e){return t.setState({isFocused:e})},setDisabled:function(e){return t.setState({disabled:e})},setInputId:function(e){return t.setState({inputId:e})},syncInput:function(e){return t.inputComponent_=e},inputType:this.props.textarea?"textarea":"input"})},TextField.prototype.render=function(){var e=this.props,t=e.fullWidth,n=e.helperText,r=e.characterCounter,i=e.onLeadingIconSelect,a=e.onTrailingIconSelect,u=e.leadingIcon,c=e.trailingIcon,l=e.textarea,d=this.state.foundation;return s.default.createElement(s.default.Fragment,null,s.default.createElement("div",o({},this.otherProps,{className:this.classes,onClick:function(){return d.handleTextFieldInteraction()},onKeyDown:function(){return d.handleTextFieldInteraction()},key:"text-field-container"}),u?this.renderIcon(u,i):null,this.renderInput(),this.notchedOutlineAdapter.hasOutline()?this.renderNotchedOutline():s.default.create
|