(window.webpackJsonp=window.webpackJsonp||[]).push([[57],{2977:function(t,e){t.exports=function(t,e){return t.addEventListener?function(t,e){t.addEventListener("load",(function(t,n){e(null,n)}),!1),t.addEventListener("error",(function(n){var r=new Error('script error "'+t.src+'"');r.event=n,e(r)}),!1)}(t,e):function(t,e){t.attachEvent("onreadystatechange",(function(n){/complete|loaded/.test(t.readyState)&&e(null,n)})),t.attachEvent("onerror",(function(n){var r=new Error('failed to load the script "'+t.src+'"');r.event=n||window.event,e(r)}))}(t,e)}},3029:function(t,e,n){"use strict";var r=n(2934);t.exports=function(t,e,n){if("function"!=typeof t)throw new TypeError("Expected a function but received a "+typeof t);return r((function(n,r,i){e=t(e,n,r,i)}),n),e}},3058:function(t,e){t.exports=function(t,e){return e||(e={}),t.toLowerCase().replace(e.replace||/[^a-z0-9]/g," ").replace(/^ +| +$/g,"").replace(/ +/g,e.separator||"-")}},3059:function(t,e,n){"use strict";var r=n(2934);t.exports=function(t,e){if("function"!=typeof t)throw new TypeError("`predicate` must be a function but was a "+typeof t);var n=!0;return r((function(e,r,i){if(!(n=!!t(e,r,i)))return!1}),e),n}},3060:function(t,e,n){"use strict";(function(e){var n=e.JSON&&"function"==typeof JSON.stringify?JSON.stringify:String;function r(t){var e=Array.prototype.slice.call(arguments,1),n=0;return t.replace(/%([a-z])/gi,(function(t,i){return r[i]?r[i](e[n++]):t+i}))}r.o=n,r.s=String,r.d=parseInt,t.exports=r}).call(this,n(187))},3061:function(t,e,n){var r=n(2976),i=n(2977),o=n(2955);t.exports=function(t,e){if(!t)throw new Error("Cant load nothing...");r.string(t)&&(t={src:t});var n="https:"===document.location.protocol||"chrome-extension:"===document.location.protocol;t.src&&0===t.src.indexOf("//")&&(t.src=n?"https:"+t.src:"http:"+t.src),n&&t.https?t.src=t.https:!n&&t.http&&(t.src=t.http);var s=document.createElement("iframe");return s.src=t.src,s.width=t.width||1,s.height=t.height||1,s.style.display="none",r.fn(e)&&i(s,e),o((function(){var t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(s,t)})),s}},3062:function(t,e,n){"use strict";var r=n(2977),i=n(2955),o=n(2947);t.exports=function(t,e){if(!t)throw new Error("Can't load nothing...");"string"===o(t)&&(t={src:t});var n="https:"===document.location.protocol||"chrome-extension:"===document.location.protocol;t.src&&0===t.src.indexOf("//")&&(t.src=(n?"https:":"http:")+t.src),n&&t.https?t.src=t.https:!n&&t.http&&(t.src=t.http);var s=document.createElement("script");return s.type="text/javascript",s.async=!0,s.src=t.src,"function"===o(e)&&r(s,e),i((function(){var t=document.getElementsByTagName("script")[0];t.parentNode.insertBefore(s,t)})),s}},3063:function(t,e){t.exports=function(t){return n.test(t)?t.toLowerCase():r.test(t)?(function(t){return t.replace(i,(function(t,e){return e?" "+e:""}))}(t)||t).toLowerCase():function(t){return t.replace(o,(function(t,e,n){return e+" "+n.toLowerCase().split("").join(" ")}))}(t).toLowerCase()};var n=/\s/,r=/[\W_]/;var i=/[\W_]+(.|$)/g;var o=/(.)([A-Z]+)/g},3064:function(t,e){t.exports=function(t,e){if("string"!=typeof t)throw new TypeError("String expected");e||(e=document);var n=/<([\w:]+)/.exec(t);if(!n)return e.createTextNode(t);t=t.replace(/^\s+|\s+$/g,"");var r=n[1];if("body"==r){return(o=e.createElement("html")).innerHTML=t,o.removeChild(o.lastChild)}var o,s=Object.prototype.hasOwnProperty.call(i,r)?i[r]:i._default,a=s[0],u=s[1],c=s[2];(o=e.createElement("div")).innerHTML=u+t+c;for(;a--;)o=o.lastChild;if(o.firstChild==o.lastChild)return o.removeChild(o.firstChild);var d=e.createDocumentFragment();for(;o.firstChild;)d.appendChild(o.removeChild(o.firstChild));return d};var n,r=!1;"undefined"!=typeof document&&((n=document.createElement("div")).innerHTML='
a',r=!n.getElementsByTagName("link").length,n=void 0);var i={legend:[1,""],tr:[2,""],col:[2,""],_default:r?[1,"X","
"]:[0,"",""]};i.td=i.th=[3,""],i.option=i.optgroup=[1,'"],i.thead=i.tbody=i.colgroup=i.caption=i.tfoot=[1,""],i.polyline=i.ellipse=i.polygon=i.circle=i.text=i.line=i.path=i.rect=i.g=[1,'"]},3622:function(t,e,n){"use strict";var r=n(3751),i=n(3752),o=n(3618),s=n(3056),a=n(3753),u=n(3054),c=n(2968),d=n(3762),l=n(3766),p=n(3619),h=n(3617),f=n(3767),m=n(3768).v4,g=n(3770),_={maxage:31536e6,secure:!1,path:"/"},y={maxRetryDelay:36e4,minRetryDelay:1e3,backoffFactor:2,maxAttempts:10,maxItems:100},v=(e=t.exports=a("Segment.io").option("apiKey","").option("apiHost","api.segment.io/v1").option("crossDomainIdServers",[]).option("deleteCrossDomainId",!1).option("saveCrossDomainIdInLocalStorage",!0).option("retryQueue",!0).option("addBundledMetadata",!1).option("unbundledIntegrations",[])).option("unbundledConfigIds",[]).option("maybeBundledConfigIds",{});function w(t,e,n){!function(t,e){var n=new XMLHttpRequest;n.open("GET",t,!0),n.withCredentials=!0,n.onreadystatechange=function(){n.readyState===XMLHttpRequest.DONE&&(n.status>=200&&n.status<300?e(null,n.responseText?u.parse(n.responseText):null):e(n.statusText||"Unknown Error",null))},n.send()}("https://"+t+"/v1/id/"+e,(function(e,r){e?n(e,null):n(null,{domain:t,id:r&&r.id||null})}))}function b(t,e){var n=new XMLHttpRequest;n.open("GET",t,!0),n.withCredentials=!0,n.onreadystatechange=function(){n.readyState===XMLHttpRequest.DONE&&(n.status>=200&&n.status<300?e(null,n.responseText):e(n.statusText||n.responseText||"Unknown Error",null))},n.send()}function E(t){return t.split(".").splice(-2).join(".")}e.storage=function(){return"file:"===l()||"chrome-extension:"===l()?d:o},e.global=window,e.sendJsonWithTimeout=function(t,e,n,r,i){if("xhr"===p.type){var o=new XMLHttpRequest;for(var s in o.onerror=i,o.onreadystatechange=function(){4===o.readyState&&(429===o.status||o.status>=500&&o.status<600?i(new Error("HTTP Error "+o.status+" ("+o.statusText+")")):i(null,o))},o.open("POST",t,!0),o.timeout=r,o.ontimeout=i,n)o.setRequestHeader(s,n[s]);o.send(u.stringify(e))}else p(t,e,n,i)},v.prototype.initialize=function(){var t=this;this.options.retryQueue&&(this._lsqueue=new g("segmentio",y,(function(e,n){var r=e;r.msg.sentAt=new Date,v.sendJsonWithTimeout(r.url,r.msg,r.headers,1e4,(function(e,i){if(t.debug("sent %O, received %O",r.msg,[e,i]),e)return n(e);n(null,i)}))})),this._lsqueue.start()),this.ready(),this.analytics.on("invoke",(function(e){var n=e.action(),r="on"+e.action();t.debug("%s %o",n,e),t[r]&&t[r](e),t.ready()})),this.deleteCrossDomainIdIfNeeded(),this.isCrossDomainAnalyticsEnabled()&&this.retrieveCrossDomainId()},v.prototype.loaded=function(){return!0},v.prototype.onpage=function(t){this.enqueue("/p",t.json())},v.prototype.onidentify=function(t){this.enqueue("/i",t.json())},v.prototype.ongroup=function(t){this.enqueue("/g",t.json())},v.prototype.ontrack=function(t){var e=t.json();delete e.traits,this.enqueue("/t",e)},v.prototype.onalias=function(t){var e=t.json(),n=this.analytics.user();e.previousId=e.previousId||e.from||n.id()||n.anonymousId(),e.userId=e.userId||e.to,delete e.from,delete e.to,this.enqueue("/a",e)},v.prototype.normalize=function(t){var n=t;this.debug("normalize %o",n);var r=this.analytics.user(),i=e.global.location.search,o=n.context=n.context||n.options||{};delete n.options,n.writeKey=this.options.apiKey,o.userAgent=navigator.userAgent;var s=navigator.userLanguage||navigator.language;if(void 0===o.locale&&void 0!==s&&(o.locale=s),o.library||(o.library={name:"analytics.js",version:this.analytics.VERSION}),this.isCrossDomainAnalyticsEnabled()){var a=this.getCachedCrossDomainId();a&&(o.traits?o.traits.crossDomainId||(o.traits.crossDomainId=a):o.traits={crossDomainId:a})}i&&!o.campaign&&(o.campaign=f(i)),this.referrerId(i,o),n.userId=n.userId||r.id(),n.anonymousId=r.anonymousId(),n.sentAt=new Date;var u=this.analytics.failedInitializations||[];if(u.length>0&&(n._metadata={failedInitializations:u}),this.options.addBundledMetadata){for(var d=c(this.analytics.Integrations),l=this.options.maybeBundledConfigIds,p=[],h=0;h32e3&&this.debug("message must be less than 32kb %O",o),this.debug("enqueueing %O",o);var s=this;this.options.retryQueue?this._lsqueue.addItem({url:r,headers:i,msg:o}):p(r,o,i,(function(t,e){if(s.debug("sent %O, received %O",o,[t,e]),n){if(t)return n(t);n(null,e)}}))},v.prototype.cookie=function(t,n){var r=v.storage();if(1===arguments.length)return r(t);var o=e.global,s=o.location.href,a="."+h(s);"."===a&&(a=""),this.debug("store domain %s -> %s",s,a);var u=i(_);u.domain=a,this.debug("store %s, %s, %o",t,n,u),r(t,n,u),r(t)||(delete u.domain,this.debug("fallback store %s, %s, %o",t,n,u),r(t,n,u))},v.prototype.referrerId=function(t,e){var n,i=this.cookie("s:context.referrer");i&&(i=u.parse(i)),t&&(n=r(t)),(n=n||i)&&(e.referrer=s(e.referrer||{},n),this.cookie("s:context.referrer",u.stringify(n)))},v.prototype.isCrossDomainAnalyticsEnabled=function(){return!!this.options.crossDomainIdServers&&this.options.crossDomainIdServers.length>0},v.prototype.retrieveCrossDomainId=function(t){if(this.isCrossDomainAnalyticsEnabled()){var e=this.getCachedCrossDomainId();if(e)t&&t(null,{crossDomainId:e});else{for(var n=this,r=this.options.apiKey,i=[],o=0;o=31||"undefined"!=typeof navigator&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)},e.storage="undefined"!=typeof chrome&&void 0!==chrome.storage?chrome.storage.local:function(){try{return window.localStorage}catch(t){}}(),e.colors=["lightseagreen","forestgreen","goldenrod","dodgerblue","darkorchid","crimson"],e.formatters.j=function(t){try{return JSON.stringify(t)}catch(t){return"[UnexpectedJSONParseError]: "+t.message}},e.enable(i())}).call(this,n(720))},3755:function(t,e,n){var r;function i(t){function n(){if(n.enabled){var t=n,i=+new Date,o=i-(r||i);t.diff=o,t.prev=r,t.curr=i,r=i;for(var s=new Array(arguments.length),a=0;a0)return function(t){if((t=String(t)).length>100)return;var e=/^((?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|years?|yrs?|y)?$/i.exec(t);if(!e)return;var s=parseFloat(e[1]);switch((e[2]||"ms").toLowerCase()){case"years":case"year":case"yrs":case"yr":case"y":return 315576e5*s;case"days":case"day":case"d":return s*o;case"hours":case"hour":case"hrs":case"hr":case"h":return s*i;case"minutes":case"minute":case"mins":case"min":case"m":return s*r;case"seconds":case"second":case"secs":case"sec":case"s":return s*n;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return s;default:return}}(t);if("number"===u&&!1===isNaN(t))return e.long?s(a=t,o,"day")||s(a,i,"hour")||s(a,r,"minute")||s(a,n,"second")||a+" ms":function(t){if(t>=o)return Math.round(t/o)+"d";if(t>=i)return Math.round(t/i)+"h";if(t>=r)return Math.round(t/r)+"m";if(t>=n)return Math.round(t/n)+"s";return t+"ms"}(t);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(t))}},3757:function(t,e,n){"use strict";var r=n(2967),i=n(3758),o=n(2934),s=n(3760),a=n(3059),u=n(3060),c=n(3029),d=n(2976),l=n(3061),p=n(3062),h=n(2955),f=n(3063),m=Object.prototype.hasOwnProperty,g=function(){},_=window.onerror;function y(t){return!!d.object(t)&&(!!d.string(t.key)&&!!m.call(t,"value"))}r(e),e.initialize=function(){var t=this.ready;h(t)},e.loaded=function(){return!1},e.page=function(t){},e.track=function(t){},e.map=function(t,e){var n=f(e),r=function(t){if(d.array(t))return a(y,t)?"mixed":"array";return d.object(t)?"map":"unknown"}(t);return"unknown"===r?[]:c((function(t,e,i){var o,s;return"map"===r&&(o=i,s=e),"array"===r&&(o=e,s=e),"mixed"===r&&(o=e.key,s=e.value),f(o)===n&&t.push(s),t}),[],t)},e.invoke=function(t){if(this[t]){var e=Array.prototype.slice.call(arguments,1);return this._ready?(this.debug("%s with %o",t,e),this[t].apply(this,e)):this.queue(t,e)}},e.queue=function(t,e){if("page"===t&&this._assumesPageview&&!this._initialized)return this.page.apply(this,e);this._queue.push({method:t,args:e})},e.flush=function(){this._ready=!0;var t=this;o((function(e){t[e.method].apply(t,e.args)}),this._queue),this._queue.length=0},e.reset=function(){for(var t=0;t4){var s=i.substr(4);"campaign"===s&&(s="name"),n[s]=decodeURIComponent(o.replace(/\+/g," "))}}return n}},3768:function(t,e,n){for(var r=n(3769),i=[],o={},s=0;s<256;s++)i[s]=(s+256).toString(16).substr(1),o[i[s]]=s;function a(t,e){var n=e||0,r=i;return r[t[n++]]+r[t[n++]]+r[t[n++]]+r[t[n++]]+"-"+r[t[n++]]+r[t[n++]]+"-"+r[t[n++]]+r[t[n++]]+"-"+r[t[n++]]+r[t[n++]]+"-"+r[t[n++]]+r[t[n++]]+r[t[n++]]+r[t[n++]]+r[t[n++]]+r[t[n++]]}var u=r(),c=[1|u[0],u[1],u[2],u[3],u[4],u[5]],d=16383&(u[6]<<8|u[7]),l=0,p=0;function h(t,e,n){var i=e&&n||0;"string"==typeof t&&(e="binary"==t?new Array(16):null,t=null);var o=(t=t||{}).random||(t.rng||r)();if(o[6]=15&o[6]|64,o[8]=63&o[8]|128,e)for(var s=0;s<16;s++)e[i+s]=o[s];return e||a(o)}var f=h;f.v1=function(t,e,n){var r=e&&n||0,i=e||[],o=void 0!==(t=t||{}).clockseq?t.clockseq:d,s=void 0!==t.msecs?t.msecs:(new Date).getTime(),u=void 0!==t.nsecs?t.nsecs:p+1,h=s-l+(u-p)/1e4;if(h<0&&void 0===t.clockseq&&(o=o+1&16383),(h<0||s>l)&&void 0===t.nsecs&&(u=0),u>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");l=s,p=u,d=o;var f=(1e4*(268435455&(s+=122192928e5))+u)%4294967296;i[r++]=f>>>24&255,i[r++]=f>>>16&255,i[r++]=f>>>8&255,i[r++]=255&f;var m=s/4294967296*1e4&268435455;i[r++]=m>>>8&255,i[r++]=255&m,i[r++]=m>>>24&15|16,i[r++]=m>>>16&255,i[r++]=o>>>8|128,i[r++]=255&o;for(var g=t.node||c,_=0;_<6;_++)i[r+_]=g[_];return e||a(i)},f.v4=h,f.parse=function(t,e,n){var r=e&&n||0,i=0;for(e=e||[],t.toLowerCase().replace(/[0-9a-f]{2}/g,(function(t){i<16&&(e[r+i++]=o[t])}));i<16;)e[r+i++]=0;return e},f.unparse=a,t.exports=f},3769:function(t,e,n){(function(e){var n,r=e.crypto||e.msCrypto;if(r&&r.getRandomValues){var i=new Uint8Array(16);n=function(){return r.getRandomValues(i),i}}if(!n){var o=new Array(16);n=function(){for(var t,e=0;e<16;e++)0==(3&e)&&(t=4294967296*Math.random()),o[e]=t>>>((3&e)<<3)&255;return o}}t.exports=n}).call(this,n(187))},3770:function(t,e,n){"use strict";var r=n(3771).v4,i=n(3772),o=n(2934),s=n(3773),a=n(3774)("localstorage-retry");function u(t,e){return function(){return t.apply(e,arguments)}}function c(t,e,n){"function"==typeof e&&(n=e),this.name=t,this.id=r(),this.fn=n,this.maxItems=e.maxItems||1/0,this.maxAttempts=e.maxAttempts||1/0,this.backoff={MIN_RETRY_DELAY:e.minRetryDelay||1e3,MAX_RETRY_DELAY:e.maxRetryDelay||3e4,FACTOR:e.backoffFactor||2,JITTER:e.backoffJitter||0},this.timeouts={ACK_TIMER:1e3,RECLAIM_TIMER:3e3,RECLAIM_TIMEOUT:1e4,RECLAIM_WAIT:500},this.keys={IN_PROGRESS:"inProgress",QUEUE:"queue",RECLAIM_START:"reclaimStart",RECLAIM_END:"reclaimEnd",ACK:"ack"},this._schedule=new s,this._processId=0,this._store=new i(this.name,this.id,this.keys),this._store.set(this.keys.IN_PROGRESS,{}),this._store.set(this.keys.QUEUE,[]),this._ack=u(this._ack,this),this._checkReclaim=u(this._checkReclaim,this),this._processHead=u(this._processHead,this),this._running=!1}n(2967)(c.prototype),c.prototype.start=function(){this._running&&this.stop(),this._running=!0,this._ack(),this._checkReclaim(),this._processHead()},c.prototype.stop=function(){this._schedule.cancelAll(),this._running=!1},c.prototype.shouldRetry=function(t,e){return!(e>this.maxAttempts)},c.prototype.getDelay=function(t){var e=this.backoff.MIN_RETRY_DELAY*Math.pow(this.backoff.FACTOR,t);if(this.backoff.JITTER){var n=Math.random(),r=Math.floor(n*this.backoff.JITTER*e);Math.floor(10*n)<5?e-=r:e+=r}return Number(Math.min(e,this.backoff.MAX_RETRY_DELAY).toPrecision(1))},c.prototype.addItem=function(t){this._enqueue({item:t,attemptNumber:0,time:this._schedule.now(),id:r()})},c.prototype.requeue=function(t,e,n,i){this.shouldRetry(t,e,n)?this._enqueue({item:t,attemptNumber:e,time:this._schedule.now()+this.getDelay(e),id:i||r()}):this.emit("discard",t,e)},c.prototype._enqueue=function(t){var e=this._store.get(this.keys.QUEUE)||[];(e=e.slice(-(this.maxItems-1))).push(t),e=e.sort((function(t,e){return t.time-e.time})),this._store.set(this.keys.QUEUE,e),this._running&&this._processHead()},c.prototype._processHead=function(){var t=this,e=this._store;this._schedule.cancel(this._processId);var n=e.get(this.keys.QUEUE)||[],i=e.get(this.keys.IN_PROGRESS)||{},u=this._schedule.now(),c=[];function d(n,r){c.push({item:n.item,done:function(i,o){var s=e.get(t.keys.IN_PROGRESS)||{};delete s[r],e.set(t.keys.IN_PROGRESS,s),t.emit("processed",i,o,n.item),i&&t.requeue(n.item,n.attemptNumber+1,i,n.id)}})}for(var l=Object.keys(i).length;n.length&&n[0].time<=u&&l++0&&(this._processId=this._schedule.run(this._processHead,n[0].time-u,s.Modes.ASAP))},c.prototype._ack=function(){this._store.set(this.keys.ACK,this._schedule.now()),this._store.set(this.keys.RECLAIM_START,null),this._store.set(this.keys.RECLAIM_END,null),this._schedule.run(this._ack,this.timeouts.ACK_TIMER,s.Modes.ASAP)},c.prototype._checkReclaim=function(){var t=this;o((function(e){e.id!==t.id&&(t._schedule.now()-e.get(t.keys.ACK)=0?e.emit("duplication",t.item,t.attemptNumber):(s.queue.push({item:t.item,attemptNumber:t.attemptNumber+n,time:e._schedule.now(),id:i}),u.push(i))}),t)};c(a.queue,0),c(a.inProgress,1),s.queue=s.queue.sort((function(t,e){return t.time-e.time})),this._store.set(this.keys.QUEUE,s.queue),n.remove(this.keys.IN_PROGRESS),n.remove(this.keys.QUEUE),n.remove(this.keys.RECLAIM_START),n.remove(this.keys.RECLAIM_END),n.remove(this.keys.ACK),this._processHead()},t.exports=c},3771:function(t,e,n){"use strict";n.r(e),n.d(e,"v4",(function(){return s}));for(var r,i=256,o=[];i--;)o[i]=(i+256).toString(16).substring(1);function s(){var t,e=0,n="";if(!r||i+16>256){for(r=Array(e=256);e--;)r[e]=256*Math.random()|0;e=i=0}for(;e<16;e++)t=r[i+e],n+=6==e?o[15&t|64]:8==e?o[63&t|128]:o[t],1&e&&e>1&&e<11&&(n+="-");return i++,n}},3772:function(t,e,n){"use strict";var r=n(3625).defaultEngine,i=n(3625).inMemoryEngine,o=n(2934),s=n(2968),a=JSON;function u(t,e,n,i){this.id=e,this.name=t,this.keys=n||{},this.engine=i||r,this.originalEngine=this.engine}u.prototype.set=function(t,e){var n=this._createValidKey(t);if(n)try{this.engine.setItem(n,a.stringify(e))}catch(n){(function(t){var e=!1;if(t.code)switch(t.code){case 22:e=!0;break;case 1014:"NS_ERROR_DOM_QUOTA_REACHED"===t.name&&(e=!0)}else-2147024882===t.number&&(e=!0);return e})(n)&&(this._swapEngine(),this.set(t,e))}},u.prototype.get=function(t){try{var e=this.engine.getItem(this._createValidKey(t));return null===e?null:a.parse(e)}catch(t){return null}},u.prototype.getOriginalEngine=function(){return this.originalEngine},u.prototype.remove=function(t){this.engine.removeItem(this._createValidKey(t))},u.prototype._createValidKey=function(t){var e,n=this.name,r=this.id;return s(this.keys).length?(o((function(i){i===t&&(e=[n,r,t].join("."))}),this.keys),e):[n,r,t].join(".")},u.prototype._swapEngine=function(){var t=this;o((function(e){var n=t.get(e);i.setItem([t.name,t.id,e].join("."),n),t.remove(e)}),this.keys),this.engine=i},t.exports=u},3773:function(t,e,n){"use strict";var r=n(2934),i={setTimeout:function(t,e){return window.setTimeout(t,e)},clearTimeout:function(t){return window.clearTimeout(t)},Date:window.Date},o=i,s={ASAP:1,RESCHEDULE:2,ABANDON:3};function a(){this.tasks={},this.nextId=1}a.prototype.now=function(){return+new o.Date},a.prototype.run=function(t,e,n){var r=this.nextId++;return this.tasks[r]=o.setTimeout(this._handle(r,t,e,n||s.ASAP),e),r},a.prototype.cancel=function(t){this.tasks[t]&&(o.clearTimeout(this.tasks[t]),delete this.tasks[t])},a.prototype.cancelAll=function(){r(o.clearTimeout,this.tasks),this.tasks={}},a.prototype._handle=function(t,e,n,r){var i=this,o=i.now();return function(){if(delete i.tasks[t],!(r>=s.RESCHEDULE&&o+2*n=36e5?(t/36e5).toFixed(1)+"h":t>=6e4?(t/6e4).toFixed(1)+"m":t>=1e3?(t/1e3|0)+"s":t+"ms"},n.enabled=function(t){for(var e=0,r=n.skips.length;e=this._options.size&&(clearTimeout(this._timer),this.flush())},t.prototype.flush=function(){var t=this,e={batch:this._messages.map((function(t){var e=t.payload,n=a({},e);return delete n.sentAt,n})),sentAt:new Date};this._closed=!0,this._send(e,(function(){for(var e=[],n=0;n0}));if(i)r.Authorization="Basic ".concat(window.btoa(i+":"));else if(function(t){return t.match(l)}(t)){var o=function(){if("object"!=typeof document)return null;var t=s.a.get("oauth_token");return null!=t?t:null}();o&&(r.Authorization="OAuth ".concat(o))}return r}var l=/^https:\/\/[\w-]+\.soundcloud\.(com|io)(:\d+)?\//;i.a.option("apiEndpointSuffixes",{track:"/batch",page:"/batch",identify:"/batch"}),i.a.prototype.ontrack=function(t){var e=t.json();delete e.traits,this.enqueue(this.options.apiEndpointSuffixes.track,e)},i.a.prototype.onpage=function(t){this.enqueue(this.options.apiEndpointSuffixes.page,t.json())},i.a.prototype.onidentify=function(t){this.enqueue(this.options.apiEndpointSuffixes.identify,t.json())},i.a.sendJsonWithTimeout=function(t,e){void 0===e&&(e=u);var n=new Map;return function(r,i,o,s,a){var u=n.get(r);u&&!u.isClosed()||(u=new c(e,(function(e,n){return t(r,e,d(r,o,e),s,n)})),n.set(r,u)),u.submit({payload:i,callback:a})}}(i.a.sendJsonWithTimeout)}}]);
//# sourceMappingURL=http://ent/web-sourcemaps/57-3f882ab4.js.map