(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[13260],{23960:function(t,e,n){"use strict";n.d(e,{J:function(){return eQ},v:function(){return iG}});var r,i,o,a,s,u,c,l,d,f,h,p,v,g,m,y,_,b,w,S,E,T,k,C,x,O,I,A,N={log:"log",debug:"debug",info:"info",warn:"warn",error:"error"},P=console,R={};Object.keys(N).forEach(function(t){R[t]=P[t]});var M="Datadog Browser SDK:",L={debug:R.debug.bind(P,M),log:R.log.bind(P,M),info:R.info.bind(P,M),warn:R.warn.bind(P,M),error:R.error.bind(P,M)},D="https://docs.datadoghq.com",U="".concat(D,"/real_user_monitoring/browser/troubleshooting"),j="More details:";function B(t,e){return function(){for(var n=[],r=0;r"}finally{r(),i(),o(),a()}}function tl(t){var e=t.toJSON;return e?(delete t.toJSON,function(){t.toJSON=e}):tu}function td(t){return Y({},t)}function tf(t,e){return Object.keys(t).some(function(n){return t[n]===e})}function th(t){return 0===Object.keys(t).length}function tp(t){var e=0,n=ts(function(n){e=te(tc(n)),t()},200),r=n.throttled,i=n.cancel,o=function(){i(),e=0};return{updateCustomerData:function(t){th(t)?o():r(t)},resetCustomerData:o,getBytesCount:function(){return e},stop:function(){i()}}}function tv(t){return null===t?"null":Array.isArray(t)?"array":typeof t}function tg(t,e,n){if(void 0===n&&(n=function(){if("undefined"!=typeof WeakSet){var t=new WeakSet;return{hasAlreadyBeenSeen:function(e){var n=t.has(e);return n||t.add(e),n}}}var e=[];return{hasAlreadyBeenSeen:function(t){var n=e.indexOf(t)>=0;return n||e.push(t),n}}}()),void 0===e)return t;if("object"!=typeof e||null===e)return e;if(e instanceof Date)return new Date(e.getTime());if(e instanceof RegExp){var r=e.flags||[e.global?"g":"",e.ignoreCase?"i":"",e.multiline?"m":"",e.sticky?"y":"",e.unicode?"u":""].join("");return new RegExp(e.source,r)}if(!n.hasAlreadyBeenSeen(e)){if(Array.isArray(e)){for(var i=Array.isArray(t)?t:[],o=0;oe){tw(e,"discarded",t);return}for(;i.length>0&&ue){tw(e,"truncated",t);break}c.target[d]=f}else for(var d in c.source)if(Object.prototype.hasOwnProperty.call(c.source,d)){var f=tb(c.source[d],c.path,d,i,o);if(void 0!==f&&(u+=JSON.stringify(f).length+l+d.length+3,l=1),u>e){tw(e,"truncated",t);break}c.target[d]=f}}return n(),r(),a}function tb(t,e,n,r,i){var o=function(t){if(t&&"function"==typeof t.toJSON)try{return t.toJSON()}catch(t){}return t}(t);if(!o||"object"!=typeof o)return"bigint"==typeof o?"[BigInt] ".concat(o.toString()):"function"==typeof o?"[Function] ".concat(o.name||"unknown"):"symbol"==typeof o?"[Symbol] ".concat(o.description||o.toString()):o;var a=function(t){try{if(t instanceof Event)return{isTrusted:t.isTrusted};var e=Object.prototype.toString.call(t).match(/\[object (.*)\]/);if(e&&e[1])return"[".concat(e[1],"]")}catch(t){}return"[Unserializable]"}(o);if("[Object]"!==a&&"[Array]"!==a&&"[Error]"!==a)return a;if(i.has(t))return"[Reference seen at ".concat(i.get(t),"]");var s=void 0!==n?"".concat(e,".").concat(n):e,u=Array.isArray(o)?[]:{};return i.set(t,s),r.push({source:o,target:u,path:s}),u}function tw(t,e,n){L.warn("The data provided has been ".concat(e," as it is over the limit of ").concat(t," characters:"),n)}var tS=function(){function t(t){this.onFirstSubscribe=t,this.observers=[]}return t.prototype.subscribe=function(t){var e=this;return this.observers.push(t),1===this.observers.length&&this.onFirstSubscribe&&(this.onLastUnsubscribe=this.onFirstSubscribe(this)||void 0),{unsubscribe:function(){e.observers=e.observers.filter(function(e){return t!==e}),!e.observers.length&&e.onLastUnsubscribe&&e.onLastUnsubscribe()}}},t.prototype.notify=function(t){this.observers.forEach(function(e){return e(t)})},t}();function tE(){for(var t=[],e=0;e eval")>-1,r=tB.exec(e[3]);return n&&r&&(e[3]=r[1],e[4]=r[2],e[5]=void 0),{args:e[2]?e[2].split(","):[],column:e[5]?+e[5]:void 0,func:e[1]||"?",line:e[4]?+e[4]:void 0,url:e[3]}}}(t);n&&(!n.func&&n.line&&(n.func="?"),e.push(n))}),{message:tH(t,"message"),name:tH(t,"name"),stack:e}}var tP="((?:file|https?|blob|chrome-extension|native|eval|webpack|snippet||\\w+\\.|\\/).*?)",tR="(?::(\\d+))",tM=RegExp("^\\s*at (.*?) ?\\(".concat(tP).concat(tR,"?").concat(tR,"?\\)?\\s*$"),"i"),tL=new RegExp("\\((\\S*)".concat(tR).concat(tR,"\\)")),tD=RegExp("^\\s*at ?".concat(tP).concat(tR,"?").concat(tR,"??\\s*$"),"i"),tU=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:file|ms-appx|https?|webpack|blob):.*?):(\d+)(?::(\d+))?\)?\s*$/i,tj=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)((?:file|https?|blob|chrome|webpack|resource|capacitor|\[native).*?|[^@]*bundle)(?::(\d+))?(?::(\d+))?\s*$/i,tB=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i;function tH(t,e){if("object"==typeof t&&t&&e in t){var n=t[e];return"string"==typeof n?n:void 0}}var tF=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?([\s\S]*)$/;function tG(){var t,e=Error();if(!e.stack)try{throw e}catch(t){}return V(function(){var n=tN(e);n.stack=n.stack.slice(2),t=tz(n)}),t}function tz(t){var e=tV(t);return t.stack.forEach(function(t){var n="?"===t.func?"":t.func,r=t.args&&t.args.length>0?"(".concat(t.args.join(", "),")"):"",i=t.line?":".concat(t.line):"",o=t.line&&t.column?":".concat(t.column):"";e+="\n at ".concat(n).concat(r," @ ").concat(t.url).concat(i).concat(o)}),e}function tV(t){return"".concat(t.name||"Error",": ").concat(t.message)}var tK="No stack, consider using an instance of Error";function tq(t){var e=t.stackTrace,n=t.originalError,r=t.handlingStack,i=t.startClocks,o=t.nonErrorPrefix,a=t.source,s=t.handling,u=n instanceof Error,c=(null==e?void 0:e.message)&&(null==e?void 0:e.name)?e.message:u?"Empty message":"".concat(o," ").concat(tc(t_(n))),l=void 0!==e&&(u||e.stack.length>0&&(e.stack.length>1||void 0!==e.stack[0].url))?tz(e):tK,d=u?tZ(n,a):void 0,f=e?e.name:void 0,h=tJ(n);return{startClocks:i,source:a,handling:s,handlingStack:r,originalError:n,type:f,message:c,stack:l,causes:d,fingerprint:h}}function tJ(t){return t instanceof Error&&"dd_fingerprint"in t?String(t.dd_fingerprint):void 0}function tZ(t,e){for(var n=t,r=[];(null==n?void 0:n.cause)instanceof Error&&r.length<10;){var i=tN(n.cause);r.push({message:n.cause.message,source:e,type:null==i?void 0:i.name,stack:i&&tz(i)}),n=n.cause}return r.length?r:void 0}(r=c||(c={})).WRITABLE_RESOURCE_GRAPHQL="writable_resource_graphql",r.REMOTE_CONFIGURATION="remote_configuration",r.UPDATE_VIEW_NAME="update_view_name",r.LONG_ANIMATION_FRAME="long_animation_frame";var tW=new Set;function t$(t){return tW.has(t)}var tX="datad0g.com",tY="datadoghq.com",tQ="pci.browser-intake-datadoghq.com";function t0(t){return 0!==t&&100*Math.random()<=t}function t1(t,e){return+t.toFixed(e)}function t2(t){return"number"==typeof t}function t3(t){var e;return{relative:t,timeStamp:(e=t4()-performance.now())>et()?Math.round(e+t):Math.round(et()+t)}}function t5(t){return t2(t)?t1(1e6*t,0):t}function t4(){return new Date().getTime()}function t6(){return t4()}function t8(){return performance.now()}function t9(){return{relative:t8(),timeStamp:t6()}}function t7(){return{relative:0,timeStamp:et()}}function et(){return void 0===l&&(l=performance.timing.navigationStart),l}function ee(t,e){var n=window.__ddBrowserSdkExtensionCallback;n&&n({type:t,payload:e})}function en(){var t,e=window.navigator;return{status:e.onLine?"connected":"not_connected",interfaces:e.connection&&e.connection.type?[e.connection.type]:void 0,effective_type:null===(t=e.connection)||void 0===t?void 0:t.effectiveType}}function er(t,e){var n=t.indexOf(e);n>=0&&t.splice(n,1)}function ei(){var t=[];return{add:function(e){t.push(e)>500&&t.splice(0,1)},remove:function(e){er(t,e)},drain:function(e){t.forEach(function(t){return t(e)}),t.length=0}}}var eo="configuration",ea="usage",es=["https://www.datadoghq-browser-agent.com","https://www.datad0g-browser-agent.com","https://d3uc069fcn7uxw.cloudfront.net","https://d20xtzwzcl0ceb.cloudfront.net","http://localhost",""],eu=["ddog-gov.com"],ec=ei(),el=function(t){ec.add(function(){return el(t)})};function ed(t,e){K(N.debug,t,e),el(Y({type:"log",message:t,status:"debug"},e))}function ef(t,e){el(Y({type:"log",status:"error"},function(t){if(t instanceof Error){var e=tN(t);return{error:{kind:e.name,stack:tz((e.stack=e.stack.filter(function(t){return!t.url||es.some(function(e){return X(t.url,e)})}),e))},message:e.message}}return{error:{stack:tK},message:"".concat("Uncaught"," ").concat(tc(t))}}(t),e))}function eh(t){el({type:ea,usage:t})}function ep(t){var e=Y({},t);return["id","name","email"].forEach(function(t){t in e&&(e[t]=String(e[t]))}),e}function ev(t,e){e.silentMultipleInit||L.error("".concat(t," is already initialized."))}function eg(t){return t?(parseInt(t,10)^16*Math.random()>>parseInt(t,10)/4).toString(16):"".concat(1e7,"-").concat(1e3,"-").concat(4e3,"-").concat(8e3,"-").concat(1e11).replace(/[018]/g,eg)}var em=/([\w-]+)\s*=\s*([^;]+)/g;function ey(t,e){for(em.lastIndex=0;;){var n=em.exec(t);if(n){if(n[1]===e)return n[2]}else break}}function e_(t,e,n){void 0===n&&(n="");var r=t.charCodeAt(e-1),i=r>=55296&&r<=56319?e+1:e;return t.length<=i?t:"".concat(t.slice(0,i)).concat(n)}function eb(t,e,n){var r=t.vitalsByName,i=t.vitalsByReference;void 0===n&&(n={});var o={name:e,startClocks:t9(),context:n.context,description:n.description},a={__dd_vital_reference:!0};return r.set(e,o),i.set(a,o),a}function ew(t,e,n,r){var i,o,a,s,u,c=e.vitalsByName,l=e.vitalsByReference;void 0===r&&(r={});var d="string"==typeof n?c.get(n):l.get(n);d&&(t((i=d.startClocks,o=r,a=t9(),{name:d.name,type:"duration",startClocks:i,duration:(u=i.timeStamp,a.timeStamp-u),context:ty(d.context,o.context),description:null!==(s=o.description)&&void 0!==s?s:d.description})),"string"==typeof n?c.delete(n):l.delete(n))}function eS(){var t=Q().DatadogEventBridge;if(t)return{getCapabilities:function(){var e;return JSON.parse((null===(e=t.getCapabilities)||void 0===e?void 0:e.call(t))||"[]")},getPrivacyLevel:function(){var e;return null===(e=t.getPrivacyLevel)||void 0===e?void 0:e.call(t)},getAllowedWebViewHosts:function(){return JSON.parse(t.getAllowedWebViewHosts())},send:function(e,n,r){t.send(JSON.stringify({eventType:e,event:n,view:r?{id:r}:void 0}))}}}function eE(t){var e=eS();return!!e&&q(e.getCapabilities(),t)}function eT(t){void 0===t&&(t=null===(e=Q().location)||void 0===e?void 0:e.hostname);var e,n=eS();return!!n&&n.getAllowedWebViewHosts().some(function(e){var n,r;return t===e||(n=t,r=".".concat(e),n.slice(-r.length)===r)})}function ek(t,e,n,r){var i=(void 0===r?{}:r).computeHandlingStack,o=t[e];if("function"!=typeof o){if(!(e in t&&X(e,"on")))return{stop:tu};o=tu}var a=!1,s=function(){if(a)return o.apply(this,arguments);var t,e=J(arguments);V(n,null,[{target:this,parameters:e,onPostCall:function(e){t=e},handlingStack:i?tG():void 0}]);var r=o.apply(this,e);return t&&V(t,null,[r]),r};return t[e]=s,{stop:function(){a=!0,t[e]===s&&(t[e]=o)}}}function eC(t,e,n){var r=Object.getOwnPropertyDescriptor(t,e);if(!r||!r.set||!r.configurable)return{stop:tu};var i=function(t,e){tr(function(){i!==tu&&n(t,e)},0)},o=function(t){r.set.call(this,t),i(this,t)};return Object.defineProperty(t,e,{set:o}),{stop:function(){var n;(null===(n=Object.getOwnPropertyDescriptor(t,e))||void 0===n?void 0:n.set)===o&&Object.defineProperty(t,e,r),i=tu}}}function ex(t){return eO(t,location.href).href}function eO(t,e){var n=function(){if(void 0===d)try{var t=new eI("http://test/path");d="http://test/path"===t.href}catch(t){d=!1}return d?eI:void 0}();if(n)try{return void 0!==e?new n(t,e):new n(t)}catch(n){throw Error("Failed to construct URL: ".concat(String(n)," ").concat(tc({url:t,base:e})))}if(void 0===e&&!/:/.test(t))throw Error("Invalid URL: '".concat(t,"'"));var r=document,i=r.createElement("a");if(void 0!==e){var o=(r=document.implementation.createHTMLDocument("")).createElement("base");o.href=e,r.head.appendChild(o),r.body.appendChild(i)}return i.href=t,i}var eI=URL;function eA(){return f||(f=new tS(function(t){if(window.fetch)return ek(window,"fetch",function(e){var n,r,i,o,a,s,u,c,l;return n=e.parameters,r=e.onPostCall,i=e.handlingStack,o=n[0],void 0===(s=(a=n[1])&&a.method)&&o instanceof Request&&(s=o.method),u=void 0!==s?String(s).toUpperCase():"GET",c=o instanceof Request?o.url:ex(String(o)),l={state:"start",init:a,input:o,method:u,startClocks:t9(),url:c,handlingStack:i},void(t.notify(l),n[0]=l.input,n[1]=l.init,r(function(e){return function(t,e,n){function r(e){n.state="resolve",Y(n,e),t.notify(n)}e.then(z(function(t){r({response:t,responseType:t.type,status:t.status,isAborted:!1})}),z(function(t){var e,i;r({status:0,isAborted:(null===(i=null===(e=n.init)||void 0===e?void 0:e.signal)||void 0===i?void 0:i.aborted)||t instanceof DOMException&&t.code===DOMException.ABORT_ERR,error:t})}))}(t,e,l)}))},{computeHandlingStack:!0}).stop})),f}function eN(t,e,n,r){var i=new Date;i.setTime(i.getTime()+n);var o="expires=".concat(i.toUTCString()),a=r&&r.crossSite?"none":"strict",s=r&&r.domain?";domain=".concat(r.domain):"",u=r&&r.secure?";secure":"",c=r&&r.partitioned?";partitioned":"";document.cookie="".concat(t,"=").concat(e,";").concat(o,";path=/;samesite=").concat(a).concat(s).concat(u).concat(c)}function eP(t){return ey(document.cookie,t)}function eR(t){return h||(h=function(t){var e=new Map;for(em.lastIndex=0;;){var n=em.exec(t);if(n)e.set(n[1],n[2]);else break}return e}(document.cookie)),h.get(t)}function eM(){return!!(window._DATADOG_SYNTHETICS_INJECTS_RUM||eR("datadog-synthetics-injects-rum"))}function eL(){var t,e,n;return null!=v?v:(void 0===t&&(t=window),n=t.navigator.userAgent,v=t.chrome||/HeadlessChrome/.test(n)?1:(null===(e=t.navigator.vendor)||void 0===e?void 0:e.indexOf("Apple"))===0||/safari/i.test(n)&&!/chrome|android/i.test(n)?2:t.document.documentMode?0:3)}var eD="_dd_s",eU=/^([a-zA-Z]+)=([a-z0-9-]+)$/;function ej(){return{isExpired:"1"}}function eB(t){return void 0!==t.isExpired||!((void 0===t.created||t4()-Number(t.created)<144e5)&&(void 0===t.expire||t4()=100){e$(e);return}var l=c();if(o&&(l.lock||(i=eg(),u(l.session),(l=c()).lock!==i))){eW(t,e,n);return}var d=t.process(l.session);if(o&&(l=c()).lock!==i){eW(t,e,n);return}if(d&&(eB(d)?s():(eH(d),o?u(d):a(d))),o&&!(d&&eB(d))){if((l=c()).lock!==i){eW(t,e,n);return}a(l.session),d=l.session}null===(r=t.after)||void 0===r||r.call(t,d||l.session),e$(e)}function eW(t,e,n){tr(function(){eZ(t,e,n+1)},10)}function e$(t){g=void 0;var e=eJ.shift();e&&eZ(e,t)}function eX(t,e,n){var r=function(t,e){var n="/api/v2/".concat(e),r=t.proxy;if("string"==typeof r){var i=ex(r);return function(t){return"".concat(i,"?ddforward=").concat(encodeURIComponent("".concat(n,"?").concat(t)))}}if("function"==typeof r)return function(t){return r({path:n,parameters:t})};var o=function(t,e){var n=e.site,r=void 0===n?tY:n,i=e.internalAnalyticsSubdomain;if("logs"===t&&e.usePciIntake&&r===tY)return tQ;if(i&&r===tY)return"".concat(i,".").concat(tY);if("dd0g-gov.com"===r)return"http-intake.logs.".concat(r);var o=r.split("."),a=o.pop();return"browser-intake-".concat(o.join("-"),".").concat(a)}(e,t);return function(t){return"https://".concat(o).concat(n,"?").concat(t)}}(t,e);return{build:function(i,o){var a,s,u,c,l,d;return r((a=t.clientToken,s=t.internalAnalyticsSubdomain,u=o.retry,c=o.encoding,l=["sdk_version:".concat("5.29.1"),"api:".concat(i)].concat(n),u&&l.push("retry_count:".concat(u.count),"retry_after:".concat(u.lastFailureStatus)),d=["ddsource=browser","ddtags=".concat(encodeURIComponent(l.join(","))),"dd-api-key=".concat(a),"dd-evp-origin-version=".concat(encodeURIComponent("5.29.1")),"dd-evp-origin=browser","dd-request-id=".concat(eg())],c&&d.push("dd-evp-encoding=".concat(c)),"rum"===e&&d.push("batch_time=".concat(t6())),s&&d.reverse(),d.join("&")))},urlPrefix:r(""),trackType:e}}function eY(t,e){var n=200-t.length-1;(e.length>n||function(){try{return RegExp("[\\p{Ll}]","u"),!0}catch(t){return!1}}()&&RegExp("[^\\p{Ll}\\p{Lo}0-9_:./-]","u").test(e))&&L.warn("".concat(t," value doesn't meet tag requirements and will be sanitized. ").concat(j," ").concat(D,"/getting_started/tagging/#defining-tags"));var r=e.replace(/,/g,"_");return"".concat(t,":").concat(r)}var eQ={ALLOW:"allow",MASK:"mask",MASK_USER_INPUT:"mask-user-input"},e0={ALL:"all",SAMPLED:"sampled"};function e1(t,e){return null==t||"string"==typeof t||(L.error("".concat(e," must be defined as a string")),!1)}function e2(t,e){return!!(void 0===t||t2(t)&&t>=0&&t<=100)||(L.error("".concat(e," Sample Rate should be a number between 0 and 100")),!1)}function e3(t){var e=tv(t);return"string"===e||"function"===e||t instanceof RegExp}function e5(t,e,n){return void 0===n&&(n=!1),t.some(function(t){try{if("function"==typeof t)return t(e);if(t instanceof RegExp)return t.test(e);if("string"==typeof t)return n?X(e,t):t===e}catch(t){L.error(t)}return!1})}function e4(t){0!==t.status||t.isAborted||(t.traceId=void 0,t.spanId=void 0,t.traceSampled=void 0)}function e6(t,e,n,r){if(void 0!==e8()&&n.findTrackedSession()){var i,o,a,s,u,c=Z(t.allowedTracingUrls,function(t){return e5([t.match],e.url,!0)});c&&(e.traceSampled=!t2(t.traceSampleRate)||t0(t.traceSampleRate),(e.traceSampled||t.traceContextInjection===e0.ALL)&&(e.traceId=e9(),e.spanId=e9(),r((i=e.traceId,o=e.spanId,a=e.traceSampled,s=c.propagatorTypes,u={},s.forEach(function(t){switch(t){case"datadog":Y(u,{"x-datadog-origin":"rum","x-datadog-parent-id":o.toDecimalString(),"x-datadog-sampling-priority":a?"1":"0","x-datadog-trace-id":i.toDecimalString()});break;case"tracecontext":Y(u,{traceparent:"00-0000000000000000".concat(i.toPaddedHexadecimalString(),"-").concat(o.toPaddedHexadecimalString(),"-0").concat(a?"1":"0")});break;case"b3":Y(u,{b3:"".concat(i.toPaddedHexadecimalString(),"-").concat(o.toPaddedHexadecimalString(),"-").concat(a?"1":"0")});break;case"b3multi":Y(u,{"X-B3-TraceId":i.toPaddedHexadecimalString(),"X-B3-SpanId":o.toPaddedHexadecimalString(),"X-B3-Sampled":a?"1":"0"})}}),u))))}}function e8(){return window.crypto||window.msCrypto}function e9(){var t=new Uint8Array(8);function e(e){return 16777216*t[e]+(t[e+1]<<16)+(t[e+2]<<8)+t[e+3]}function n(t){var n=e(0),r=e(4),i="";do{var o=n%t*4294967296+r;n=Math.floor(n/t),r=Math.floor(o/t),i=(o%t).toString(t)+i}while(n||r);return i}return e8().getRandomValues(t),t[0]=127&t[0],{toDecimalString:function(){return n(10)},toPaddedHexadecimalString:function(){var t=n(16);return Array(17-t.length).join("0")+t}}}var e7=["tracecontext","datadog"];function nt(){L.error("Error fetching the remote configuration.")}var ne={HIDDEN:"visibility_hidden",UNLOADING:"before_unload",PAGEHIDE:"page_hide",FROZEN:"page_frozen"};function nn(){var t,e=window;if(e.Zone&&(t=tn(e,"MutationObserver"),e.MutationObserver&&t===e.MutationObserver)){var n=tn(new e.MutationObserver(tu),"originalInstance");t=n&&n.constructor}return t||(t=e.MutationObserver),t}var nr={AGENT:"agent",CONSOLE:"console",CUSTOM:"custom",SOURCE:"source",REPORT:"report"};function ni(t,e,n){var r=0,i=!1;return{isLimitReached:function(){if(0===r&&tr(function(){r=0},6e4),(r+=1)<=e||i)return i=!1,!1;if(r===e+1){i=!0;try{n({message:"Reached max number of ".concat(t,"s by minute: ").concat(e),source:nr.AGENT,startClocks:t9()})}finally{i=!1}}return!0}}}function no(t,e,n){for(var r=t,i=e.split("."),o=0;o0&&r[r.length-1].endTime=n&&r.pop(),r.unshift(i),i},find:function(t,e){void 0===t&&(t=nd),void 0===e&&(e={returnInactive:!1});for(var n=0,i=r;nt[n])return!1;return!0}function n_(t){return t.duration>=0}function nb(t){var e=ny(t.startTime,t.fetchStart,t.domainLookupStart,t.domainLookupEnd,t.connectStart,t.connectEnd,t.requestStart,t.responseStart,t.responseEnd),n=!(t.redirectEnd>t.startTime)||ny(t.startTime,t.redirectStart,t.redirectEnd,t.fetchStart);return e&&n}function nw(t,e,n){if(t<=e&&e<=n)return{duration:t5(n-e),start:t5(e-t)}}function nS(t,e){return e&&!t.isIntakeUrl(e)}var nE=/data:(.+)?(;base64)?,/g;function nT(t){if(t.length<=24e3);else if("data:"===t.substring(0,5))return t=t.substring(0,24e3),!0;return!1}function nk(t){return"".concat(t.match(nE)[0],"[...]")}var nC=1;function nx(){var t=nC;return nC+=1,t}function nO(t){return t2(t)&&t<0?void 0:t}function nI(t){var e=t.lifeCycle,n=t.isChildEvent,r=t.onChange,i=void 0===r?tu:r,o={errorCount:0,longTaskCount:0,resourceCount:0,actionCount:0,frustrationCount:0},a=e.subscribe(12,function(t){var e;if("view"!==t.type&&"vital"!==t.type&&n(t))switch(t.type){case"error":o.errorCount+=1,i();break;case"action":o.actionCount+=1,t.action.frustration&&(o.frustrationCount+=t.action.frustration.type.length),i();break;case"long_task":o.longTaskCount+=1,i();break;case"resource":(null===(e=t._dd)||void 0===e?void 0:e.discarded)||(o.resourceCount+=1,i())}});return{stop:function(){a.unsubscribe()},eventCounts:o}}function nA(t,e){return new tS(function(n){if(window.PerformanceObserver){var r,i,o=function(e){var r=e.filter(function(e){return e.entryType!==_.RESOURCE||!!nS(t,e.name)&&!!n_(e)});r.length>0&&n.notify(r)},a=!0,s=new PerformanceObserver(z(function(t){a?r=tr(function(){return o(t.getEntries())}):o(t.getEntries())}));try{s.observe(e)}catch(t){if(q([_.RESOURCE,_.NAVIGATION,_.LONG_TASK,_.PAINT],e.type)){e.buffered&&(r=tr(function(){return o(performance.getEntriesByType(e.type))}));try{s.observe({entryTypes:[e.type]})}catch(t){return}}}return a=!1,!b&&void 0!==window.performance&&"getEntries"in performance&&"addEventListener"in performance&&(b=tC(t,performance,"resourcetimingbufferfull",function(){performance.clearResourceTimings()})),nN(_.FIRST_INPUT)||e.type!==_.FIRST_INPUT||(i=function(t,e){var n=t4(),r=!1,i=tx(t,window,["click","mousedown","keydown","touchstart","pointerdown"],function(e){if(e.cancelable){var n={entryType:"first-input",processingStart:t8(),processingEnd:t8(),startTime:e.timeStamp,duration:0,name:"",cancelable:!1,target:null,toJSON:function(){return{}}};"pointerdown"===e.type?tx(t,window,["pointerup","pointercancel"],function(t){"pointerup"===t.type&&o(n)},{once:!0}):o(n)}},{passive:!0,capture:!0}).stop;return{stop:i};function o(t){if(!r){r=!0,i();var o=t.processingStart-t.startTime;o>=0&&o0})}})}function nM(t,e){return e5(t.excludedActivityUrls,e)}function nL(t){return window.CSS&&window.CSS.escape?window.CSS.escape(t):t.replace(/([\0-\x1f\x7f]|^-?\d)|^-$|[^\x80-\uFFFF\w-]/g,function(t,e){return e?"\0"===t?"�":"".concat(t.slice(0,-1),"\\").concat(t.charCodeAt(t.length-1).toString(16)," "):"\\".concat(t)})}function nD(t,e){return t.matches?t.matches(e):!!t.msMatchesSelector&&t.msMatchesSelector(e)}function nU(t){if(t.parentElement)return t.parentElement;for(;t.parentNode;){if(t.parentNode.nodeType===Node.ELEMENT_NODE)return t.parentNode;t=t.parentNode}return null}(i=_||(_={})).EVENT="event",i.FIRST_INPUT="first-input",i.LARGEST_CONTENTFUL_PAINT="largest-contentful-paint",i.LAYOUT_SHIFT="layout-shift",i.LONG_TASK="longtask",i.LONG_ANIMATION_FRAME="long-animation-frame",i.NAVIGATION="navigation",i.PAINT="paint",i.RESOURCE="resource";var nj=function(){function t(t){var e=this;this.map=new WeakMap,t&&t.forEach(function(t){return e.map.set(t,1)})}return t.prototype.add=function(t){return this.map.set(t,1),this},t.prototype.delete=function(t){return this.map.delete(t)},t.prototype.has=function(t){return this.map.has(t)},t}();function nB(t){return t.nodeType===Node.TEXT_NODE}function nH(t){return t.nodeType===Node.ELEMENT_NODE}function nF(t){return nH(t)&&!!t.shadowRoot}function nG(t){return!!t.host&&t.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&nH(t.host)}function nz(t,e){for(var n=t.firstChild;n;)e(n),n=n.nextSibling;nF(t)&&e(t.shadowRoot)}function nV(t){return nG(t)?t.host:t.parentNode}var nK={IGNORE:"ignore",HIDDEN:"hidden",ALLOW:eQ.ALLOW,MASK:eQ.MASK,MASK_USER_INPUT:eQ.MASK_USER_INPUT},nq="data-dd-privacy",nJ="data:image/gif;base64,R0lGODlhAQABAIAAAMLCwgAAACH5BAAAAAAALAAAAAABAAEAAAICRAEAOw==",nZ={INPUT:!0,OUTPUT:!0,TEXTAREA:!0,SELECT:!0,OPTION:!0,DATALIST:!0,OPTGROUP:!0};function nW(t,e,n){if(n&&n.has(t))return n.get(t);var r=nV(t),i=r?nW(r,e,n):e,o=n$(nX(t),i);return n&&n.set(t,o),o}function n$(t,e){switch(e){case nK.HIDDEN:case nK.IGNORE:return e}switch(t){case nK.ALLOW:case nK.MASK:case nK.MASK_USER_INPUT:case nK.HIDDEN:case nK.IGNORE:return t;default:return e}}function nX(t){if(nH(t)){if("BASE"===t.tagName)return nK.ALLOW;if("INPUT"===t.tagName){if("password"===t.type||"email"===t.type||"tel"===t.type||"hidden"===t.type)return nK.MASK;var e=t.getAttribute("autocomplete");if(e&&0===e.indexOf("cc-"))return nK.MASK}return nD(t,n1(nK.HIDDEN))?nK.HIDDEN:nD(t,n1(nK.MASK))?nK.MASK:nD(t,n1(nK.MASK_USER_INPUT))?nK.MASK_USER_INPUT:nD(t,n1(nK.ALLOW))?nK.ALLOW:!function(t){if("SCRIPT"===t.nodeName)return!0;if("LINK"===t.nodeName){var e=i("rel");return/preload|prefetch/i.test(e)&&"script"===i("as")||"shortcut icon"===e||"icon"===e}if("META"===t.nodeName){var n=i("name"),e=i("rel"),r=i("property");return/^msapplication-tile(image|color)$/.test(n)||"application-name"===n||"icon"===e||"apple-touch-icon"===e||"shortcut icon"===e||"keywords"===n||"description"===n||/^(og|twitter|fb):/.test(r)||/^(og|twitter):/.test(n)||"pinterest"===n||"robots"===n||"googlebot"===n||"bingbot"===n||t.hasAttribute("http-equiv")||"author"===n||"generator"===n||"framework"===n||"publisher"===n||"progid"===n||/^article:/.test(r)||/^product:/.test(r)||"google-site-verification"===n||"yandex-verification"===n||"csrf-token"===n||"p:domain_verify"===n||"verify-v1"===n||"verification"===n||"shopify-checkout-api-token"===n}function i(e){return(t.getAttribute(e)||"").toLowerCase()}return!1}(t)?void 0:nK.IGNORE}}function nY(t,e){switch(e){case nK.MASK:case nK.HIDDEN:case nK.IGNORE:return!0;case nK.MASK_USER_INPUT:return nB(t)?nQ(t.parentNode):nQ(t);default:return!1}}function nQ(t){if(!t||t.nodeType!==t.ELEMENT_NODE)return!1;if("INPUT"===t.tagName)switch(t.type){case"button":case"color":case"reset":case"submit":return!1}return!!nZ[t.tagName]}function n0(t,e,n){var r,i=null===(r=t.parentElement)||void 0===r?void 0:r.tagName,o=t.textContent||"";if(!e||o.trim()){if("SCRIPT"===i)o="***";else if(n===nK.HIDDEN)o="***";else if(nY(t,n)){if("DATALIST"===i||"SELECT"===i||"OPTGROUP"===i){if(!o.trim())return}else o="OPTION"===i?"***":o.replace(/\S/g,"x")}return o}}function n1(t){return"[".concat(nq,'="').concat(t,'"], .').concat("dd-privacy-").concat(t)}var n2="data-dd-action-name";function n3(t,e){if(void 0===S&&(S="closest"in HTMLElement.prototype),S)n=t.closest("[".concat(e,"]"));else for(var n,r=t;r;){if(r.hasAttribute(e)){n=r;break}r=nU(r)}if(n)return n9(n8(n.getAttribute(e).trim()))}var n5=[function(t,e,n){if(void 0===w&&(w="labels"in HTMLInputElement.prototype),w){if("labels"in t&&t.labels&&t.labels.length>0)return n7(t.labels[0],e)}else if(t.id){var r=t.ownerDocument&&Z(t.ownerDocument.querySelectorAll("label"),function(e){return e.htmlFor===t.id});return r&&n7(r,e,n)}},function(t){if("INPUT"===t.nodeName){var e=t.getAttribute("type");if("button"===e||"submit"===e||"reset"===e)return t.value}},function(t,e,n){if("BUTTON"===t.nodeName||"LABEL"===t.nodeName||"button"===t.getAttribute("role"))return n7(t,e,n)},function(t){return t.getAttribute("aria-label")},function(t,e,n){var r=t.getAttribute("aria-labelledby");if(r)return r.split(/\s+/).map(function(e){return t.ownerDocument?t.ownerDocument.getElementById(e):null}).filter(function(t){return!!t}).map(function(t){return n7(t,e,n)}).join(" ")},function(t){return t.getAttribute("alt")},function(t){return t.getAttribute("name")},function(t){return t.getAttribute("title")},function(t){return t.getAttribute("placeholder")},function(t,e){if("options"in t&&t.options.length>0)return n7(t.options[0],e)}],n4=[function(t,e,n){return n7(t,e,n)}];function n6(t,e,n,r){for(var i=t,o=0;o<=10&&i&&"BODY"!==i.nodeName&&"HTML"!==i.nodeName&&"HEAD"!==i.nodeName;){for(var a=0;a100?"".concat(e_(t,100)," [...]"):t}function n7(t,e,n){if(!t.isContentEditable){if("innerText"in t){var r=t.innerText,i=function(e){for(var n=t.querySelectorAll(e),i=0;i0&&(r=r.replace(a,""))}}};return 0!==eL()||i("script, style"),i("[".concat(n2,"]")),e&&i("[".concat(e,"]")),n&&i("".concat(n1(nK.HIDDEN),", ").concat(n1(nK.MASK))),r}return t.textContent}}var rt=[n2,"data-testid","data-test","data-qa","data-cy","data-test-id","data-qa-id","data-testing","data-component","data-element","data-source-file"],re=[ro,function(t){if(t.id&&!ri(t.id))return"#".concat(nL(t.id))}],rn=[ro,function(t){if("BODY"!==t.tagName)for(var e=function(t){if(t.classList)return t.classList;var e=(t.getAttribute("class")||"").trim();return e?e.split(/\s+/):[]}(t),n=0;n").concat(e):t}function rl(){var t=window.getSelection();return!t||t.isCollapsed}function rd(t){return t.target instanceof Element&&!1!==t.isPrimary}function rf(t){return!t.hasPageActivity&&!t.getUserActivity().input&&!t.getUserActivity().scroll&&!nD(t.event.target,'input:not([type="checkbox"]):not([type="radio"]):not([type="button"]):not([type="submit"]):not([type="reset"]):not([type="range"]),textarea,select,[contenteditable],[contenteditable] *,canvas,a[href],a[href] *')}var rh=new Map;function rp(t,e){rh.set(t,e),rh.forEach(function(t,e){t8()-e>1e4&&rh.delete(e)})}function rv(t,e){var n=rg(t)?{action:{id:t.id,loading_time:nO(t5(t.duration)),frustration:{type:t.frustrationTypes},error:{count:t.counts.errorCount},long_task:{count:t.counts.longTaskCount},resource:{count:t.counts.resourceCount}},_dd:{action:{target:t.target,position:t.position}}}:void 0,r=rg(t)?void 0:t.context,i=ty({action:{id:eg(),target:{name:t.name},type:t.type},date:t.startClocks.timeStamp,type:"action",view:{in_foreground:e.wasInPageStateAt("active",t.startClocks.relative)}},n),o=rg(t)?{events:t.events}:{};return!rg(t)&&t.handlingStack&&(o.handlingStack=t.handlingStack),{customerContext:r,rawRumEvent:i,startTime:t.startClocks.relative,domainContext:o}}function rg(t){return"custom"!==t.type}var rm={},ry="csp_violation";function r_(t){return Y({startClocks:t9(),source:nr.REPORT,handling:"unhandled"},t)}function rb(t,e,n,r,i){return n?tz({name:t,message:e,stack:[{func:"?",url:n,line:null!=r?r:void 0,column:null!=i?i:void 0}]}):void 0}var rw=new nj;function rS(t){return t.startTime+t.duration}function rE(t,e,n){return document.readyState===e||"complete"===document.readyState?(n(),{stop:tu}):tC(t,window,"complete"===e?"load":"DOMContentLoaded",n,{once:!0})}function rT(t,e){var n=e&&Number(e);if(t&&n)return{traceId:t,traceTime:n}}function rk(t){if(t&&t.nodeType===Node.COMMENT_NODE){var e=/^\s*DATADOG;(.*?)\s*$/.exec(t.data);if(e)return e[1]}}function rC(){if(nN(_.NAVIGATION)){var t=performance.getEntriesByType(_.NAVIGATION)[0];if(t)return t}var e=function(){var t={},e=performance.timing;for(var n in e)if(t2(e[n])){var r=e[n];t[n]=0===r?0:r-et()}return t}(),n=Y({entryType:_.NAVIGATION,initiatorType:"navigation",name:window.location.href,startTime:0,duration:e.responseEnd,decodedBodySize:0,encodedBodySize:0,transferSize:0,toJSON:function(){return Y({},n,{toJSON:void 0})}},e);return n}function rx(t,e){rE(t,"interactive",function(){var t=Y(rC().toJSON(),{entryType:_.RESOURCE,initiatorType:ng,traceId:function(t){var e,n,r=(e=t.querySelector("meta[name=dd-trace-id]"),n=t.querySelector("meta[name=dd-trace-time]"),rT(e&&e.content,n&&n.content)||function(t){var e=function(t){for(var e=0;e=0;e-=1){var r=t.body.childNodes[e],n=rk(r);if(n)return n;if(!nB(r))break}}(t);if(e)return rT(ey(e,"trace-id"),ey(e,"trace-time"))}(t));if(!(!r||r.traceTime<=t4()-12e4))return r.traceId}(document),toJSON:function(){return Y({},t,{toJSON:void 0})}});e(t)})}function rO(t,e){var n=t3(t.startTime),r=function(t,e){if(t.traceId)return{_dd:{trace_id:t.traceId,span_id:e9().toDecimalString(),rule_psr:rA(e)}}}(t,e);if(e.trackResources||r){var i,o=function(t){var e,n=t.name;if(!function(t){try{return!!eO(t)}catch(t){return!1}}(n))return ed('Failed to construct URL for "'.concat(t.name,'"')),"other";for(var r="/"===(e=eO(n).pathname)[0]?e:"/".concat(e),i=0;i=i){L.warn("Discarded a message whose size was bigger than the maximum allowed size ".concat(i,"KB. ").concat(j," ").concat(U,"/#technical-limitations"));return}void 0!==n&&void 0!==o[n]&&(a=o[n],delete o[n],s=e.estimateEncodedBytesCount(a),r.notifyAfterRemoveMessage(s)),r.notifyBeforeAddMessage(c),void 0!==n?(o[n]=u,r.notifyAfterAddMessage()):e.write(e.isEmpty?u:"\n".concat(u),function(t){r.notifyAfterAddMessage(t-c)})}return{flushController:r,add:s,upsert:s,stop:a.unsubscribe}}function rV(t){return{data:"string"==typeof t.output?t.output:new Blob([t.output],{type:"text/plain"}),bytesCount:t.outputBytesCount,encoding:t.encoding}}function rK(t,e,n,r,i){0===e.transportStatus&&0===e.queuedPayloads.size()&&e.bandwidthMonitor.canHandle(t)?rq(t,e,n,{onSuccess:function(){return rJ(0,e,n,r,i)},onFailure:function(){e.queuedPayloads.enqueue(t),function t(e,n,r,i){2===e.transportStatus&&tr(function(){rq(e.queuedPayloads.first(),e,n,{onSuccess:function(){e.queuedPayloads.dequeue(),e.currentBackoffTime=1e3,rJ(1,e,n,r,i)},onFailure:function(){e.currentBackoffTime=Math.min(6e4,2*e.currentBackoffTime),t(e,n,r,i)}})},e.currentBackoffTime)}(e,n,r,i)}}):e.queuedPayloads.enqueue(t)}function rq(t,e,n,r){var i=r.onSuccess,o=r.onFailure;e.bandwidthMonitor.add(t),n(t,function(n){e.bandwidthMonitor.remove(t),"opaque"!==n.type&&(0===n.status&&!navigator.onLine||408===n.status||429===n.status||n.status>=500)?(e.transportStatus=e.bandwidthMonitor.ongoingRequestCount>0?1:2,t.retry={count:t.retry?t.retry.count+1:1,lastFailureStatus:n.status},o()):(e.transportStatus=0,i())})}function rJ(t,e,n,r,i){0===t&&e.queuedPayloads.isFull()&&!e.queueFullReported&&(i({message:"Reached max ".concat(r," events size queued for upload: ").concat(3,"MiB"),source:nr.AGENT,startClocks:t9()}),e.queueFullReported=!0);var o=e.queuedPayloads;for(e.queuedPayloads=rZ();o.size()>0;)rK(o.dequeue(),e,n,r,i)}function rZ(){var t=[];return{bytesCount:0,enqueue:function(e){this.isFull()||(t.push(e),this.bytesCount+=e.bytesCount)},first:function(){return t[0]},dequeue:function(){var e=t.shift();return e&&(this.bytesCount-=e.bytesCount),e},size:function(){return t.length},isFull:function(){return this.bytesCount>=3145728}}}function rW(t,e,n,r){var i={transportStatus:0,currentBackoffTime:1e3,bandwidthMonitor:{ongoingRequestCount:0,ongoingByteCount:0,canHandle:function(t){return 0===this.ongoingRequestCount||this.ongoingByteCount+t.bytesCount<=81920&&this.ongoingRequestCount<32},add:function(t){this.ongoingRequestCount+=1,this.ongoingByteCount+=t.bytesCount},remove:function(t){this.ongoingRequestCount-=1,this.ongoingByteCount-=t.bytesCount}},queuedPayloads:rZ(),queueFullReported:!1},o=function(r,i){(function(){try{return window.Request&&"keepalive"in new Request("http://a")}catch(t){return!1}})()&&r.bytesCount10&&function(){if(I){if(I.keys){var t=I.keys().next().value;t&&I.delete(t)}else{var e=!0;I.forEach(function(t,n){e&&(I.delete(n),e=!1)})}}}()),e}var r7=new WeakMap;function it(t){return r7.has(t)}function ie(t){return r7.get(t)}function ir(t,e){var n=t.tagName,r=t.value;if(nY(t,e)){var i=t.type;if("INPUT"===n&&("button"===i||"submit"===i||"reset"===i))return r;if(!r||"OPTION"===n)return;return"***"}return"OPTION"===n||"SELECT"===n?t.value:"INPUT"===n||"TEXTAREA"===n?r:void 0}var ii=/url\((?:(')([^']*)'|(")([^"]*)"|([^)]*))\)/gm,io=/^[A-Za-z]+:|^\/\//,ia=/^data:.*,/i,is=/[^a-z1-6-_]/;function iu(t){var e=t.toLowerCase().trim();return is.test(e)?"div":e}function ic(t,e){return"data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='".concat(t,"' height='").concat(e,"' style='background-color:silver'%3E%3C/svg%3E")}var il={FullSnapshot:2,IncrementalSnapshot:3,Meta:4,Focus:6,ViewEnd:7,VisualViewport:8,FrustrationRecord:9},id={Document:0,DocumentType:1,Element:2,Text:3,CDATA:4,DocumentFragment:11},ih={Mutation:0,MouseMove:1,MouseInteraction:2,Scroll:3,ViewportResize:4,Input:5,TouchMove:6,MediaInteraction:7,StyleSheetRule:8},ip={MouseUp:0,MouseDown:1,Click:2,ContextMenu:3,DblClick:4,Focus:5,Blur:6,TouchStart:7,TouchEnd:9},iv={Play:0,Pause:1};function ig(t){if(void 0!==t&&0!==t.length)return t.map(function(t){return{cssRules:Array.from(t.cssRules||t.rules,function(t){return t.cssText}),disabled:t.disabled||void 0,media:t.media.length>0?Array.from(t.media):void 0}})}function im(t,e,n,r){if(e===nK.HIDDEN)return null;var i=t.getAttribute(n);if(e===nK.MASK&&n!==nq&&!rt.includes(n)&&n!==r.actionNameAttribute){var o=t.tagName;switch(n){case"title":case"alt":case"placeholder":return"***"}if("IMG"===o&&("src"===n||"srcset"===n)){if(t.naturalWidth>0)return ic(t.naturalWidth,t.naturalHeight);var a=t.getBoundingClientRect(),s=a.width,u=a.height;return s>0||u>0?ic(s,u):nJ}if("SOURCE"===o&&("src"===n||"srcset"===n))return nJ;if("A"===o&&"href"===n||i&&X(n,"data-")||"IFRAME"===o&&"srcdoc"===n)return"***"}return i&&"string"==typeof i&&nT(i)?nk(i):i}function iy(t){var e,n,r;if(!t)return null;try{e=t.rules||t.cssRules}catch(t){}return e?(n=Array.from(e,2===eL()?i_:ib).join(""),r=t.href,n.replace(ii,function(t,e,n,i,o,a){var s=n||o||a;if(!r||!s||io.test(s)||ia.test(s))return t;var u=e||i||"";return"url(".concat(u).concat(function(t,e){try{return eO(t,e).href}catch(e){return t}}(s,r)).concat(u,")")})):null}function i_(t){return"selectorText"in t&&t.selectorText.includes(":")?t.cssText.replace(/(\[[\w-]+[^\\])(:[^\]]+\])/g,"$1\\$2"):ib(t)}function ib(t){return"styleSheet"in t&&iy(t.styleSheet)||t.cssText}function iw(t,e){var n=function(t,e){var n;switch(t.nodeType){case t.DOCUMENT_NODE:return{type:id.Document,childNodes:iE(t,e),adoptedStyleSheets:ig(t.adoptedStyleSheets)};case t.DOCUMENT_FRAGMENT_NODE:return(n=nG(t))&&e.serializationContext.shadowRootsController.addShadowRoot(t),{type:id.DocumentFragment,childNodes:iE(t,e),isShadowRoot:n,adoptedStyleSheets:n?ig(t.adoptedStyleSheets):void 0};case t.DOCUMENT_TYPE_NODE:return{type:id.DocumentType,name:t.name,publicId:t.publicId,systemId:t.systemId};case t.ELEMENT_NODE:return function(t,e){var n,r=iu(t.tagName),i="svg"===t.tagName||t instanceof SVGElement||void 0,o=n$(nX(t),e.parentNodePrivacyLevel);if(o===nK.HIDDEN){var a=t.getBoundingClientRect(),s=a.width,u=a.height;return{type:id.Element,tagName:r,attributes:((n={rr_width:"".concat(s,"px"),rr_height:"".concat(u,"px")})[nq]="hidden",n),childNodes:[],isSVG:i}}if(o!==nK.IGNORE){var c=function(t,e,n){if(e===nK.HIDDEN)return{};for(var r,i,o,a={},s=iu(t.tagName),u=t.ownerDocument,c=0;c0||nF(t))&&"style"!==r&&(l=iE(t,e.parentNodePrivacyLevel===o&&e.ignoreWhiteSpace===("head"===r)?e:Y({},e,{parentNodePrivacyLevel:o,ignoreWhiteSpace:"head"===r}))),{type:id.Element,tagName:r,attributes:c,childNodes:l,isSVG:i}}}(t,e);case t.TEXT_NODE:return function(t,e){var n=n0(t,e.ignoreWhiteSpace||!1,e.parentNodePrivacyLevel);if(void 0!==n)return{type:id.Text,textContent:n}}(t,e);case t.CDATA_SECTION_NODE:return{type:id.CDATA,textContent:""}}}(t,e);if(!n)return null;var r=ie(t)||iS++;return n.id=r,r7.set(t,r),e.serializedNodeIds&&e.serializedNodeIds.add(r),n}var iS=1;function iE(t,e){var n=[];return nz(t,function(t){var r=iw(t,e);r&&n.push(r)}),n}function iT(t){return!!t.changedTouches}function ik(t){return!0===t.composed&&nF(t.target)?t.composedPath()[0]:t.target}var iC=function(t,e){var n=window.visualViewport,r={layoutViewportX:t,layoutViewportY:e,visualViewportX:t,visualViewportY:e};return n&&(Math.abs(n.pageTop-n.offsetTop-window.scrollY)>25||Math.abs(n.pageLeft-n.offsetLeft-window.scrollX)>25?(r.layoutViewportX=Math.round(t+n.offsetLeft),r.layoutViewportY=Math.round(e+n.offsetTop)):(r.visualViewportX=Math.round(t-n.offsetLeft),r.visualViewportY=Math.round(e-n.offsetTop))),r},ix=function(t){return{scale:t.scale,offsetLeft:t.offsetLeft,offsetTop:t.offsetTop,pageLeft:t.pageLeft,pageTop:t.pageTop,height:t.height,width:t.width}};function iO(t,e){return{data:Y({source:t},e),type:il.IncrementalSnapshot,timestamp:t6()}}function iI(t){var e=iT(t)?t.changedTouches[0]:t,n=e.clientX,r=e.clientY;if(window.visualViewport){var i=iC(n,r),o=i.visualViewportX,a=i.visualViewportY;n=o,r=a}if(!Number.isFinite(n)||!Number.isFinite(r)){t.isTrusted&&ed("mouse/touch event without x/y");return}return{x:n,y:r}}var iA=((A={}).pointerup=ip.MouseUp,A.mousedown=ip.MouseDown,A.click=ip.Click,A.contextmenu=ip.ContextMenu,A.dblclick=ip.DblClick,A.focus=ip.Focus,A.blur=ip.Blur,A.touchstart=ip.TouchStart,A.touchend=ip.TouchEnd,A);function iN(t,e,n,r){void 0===r&&(r=document);var i=ts(function(r){var i=ik(r);if(i&&nW(i,t.defaultPrivacyLevel)!==nK.HIDDEN&&it(i)){var o=ie(i),a=i===document?{scrollTop:rU(),scrollLeft:rD()}:{scrollTop:Math.round(i.scrollTop),scrollLeft:Math.round(i.scrollLeft)};n.set(i,a),e(iO(ih.Scroll,{id:o,x:a.scrollLeft,y:a.scrollTop}))}},100),o=i.throttled,a=i.cancel,s=tC(t,r,"scroll",o,{capture:!0,passive:!0}).stop;return{stop:function(){s(),a()}}}function iP(t){for(var e=[],n=t;n.parentRule;){var r=Array.from(n.parentRule.cssRules).indexOf(n);e.unshift(r),n=n.parentRule}if(n.parentStyleSheet){var i=Array.from(n.parentStyleSheet.cssRules).indexOf(n);return e.unshift(i),e}}function iR(t,e,n){void 0===n&&(n=document);var r,i=t.defaultPrivacyLevel,o=new WeakMap,a=n!==document,s=tx(t,n,a?["change"]:["input","change"],function(t){var e=ik(t);(e instanceof HTMLInputElement||e instanceof HTMLTextAreaElement||e instanceof HTMLSelectElement)&&c(e)},{capture:!0,passive:!0}).stop;if(a)r=tu;else{var u=[eC(HTMLInputElement.prototype,"value",c),eC(HTMLInputElement.prototype,"checked",c),eC(HTMLSelectElement.prototype,"value",c),eC(HTMLTextAreaElement.prototype,"value",c),eC(HTMLSelectElement.prototype,"selectedIndex",c)];r=function(){u.forEach(function(t){return t.stop()})}}return{stop:function(){r(),s()}};function c(t){var e,n,r,o=nW(t,i);if(o!==nK.HIDDEN){var a=t.type;if("radio"===a||"checkbox"===a){if(nY(t,o))return;r={isChecked:t.checked}}else{var s=ir(t,o);if(void 0===s)return;r={text:s}}l(t,r);var u=t.name;"radio"===a&&u&&t.checked&&(e=document.querySelectorAll('input[type="radio"][name="'.concat(nL(u),'"]')),n=function(e){e!==t&&l(e,{isChecked:!1})},Array.prototype.forEach.call(e,n))}}function l(t,n){if(it(t)){var r=o.get(t);r&&r.text===n.text&&r.isChecked===n.isChecked||(o.set(t,n),e(iO(ih.Input,Y({id:ie(t)},n))))}}}function iM(t,e,n,r){var i=nn();if(!i)return{stop:tu,flush:tu};var o=function(t){var e=tu,n=[];function r(){e(),t(n),n=[]}var i=ts(r,16,{leading:!1}),o=i.throttled,a=i.cancel;return{addMutations:function(t){0===n.length&&(e=function(t,e){if(window.requestIdleCallback&&window.cancelIdleCallback){var n=window.requestIdleCallback(z(t),e);return function(){return window.cancelIdleCallback(n)}}var r=window.requestAnimationFrame(z(t));return function(){return window.cancelAnimationFrame(r)}}(o,{timeout:100})),n.push.apply(n,t)},flush:r,stop:function(){e(),a()}}}(function(r){!function(t,e,n,r){var i=new Map;t.filter(function(t){return"childList"===t.type}).forEach(function(t){t.removedNodes.forEach(function(t){!function t(e,n){nF(e)&&n(e.shadowRoot),nz(e,function(e){return t(e,n)})}(t,r.removeShadowRoot)})});var o=t.filter(function(t){return t.target.isConnected&&function(t){for(var e=t;e;){if(!it(e)&&!nG(e))return!1;e=nV(e)}return!0}(t.target)&&nW(t.target,n.defaultPrivacyLevel,i)!==nK.HIDDEN}),a=function(t,e,n,r){for(var i=new Set,o=new Map,a=function(t){t.addedNodes.forEach(function(t){i.add(t)}),t.removedNodes.forEach(function(e){i.has(e)||o.set(e,t.target),i.delete(e)})},s=0;s0&&(e.postMessage({action:"reset",streamId:n}),a=0)}return{isAsync:!0,get isEmpty(){return 0===a},write:function(t,r){e.postMessage({action:"write",id:a,data:t,streamId:n}),s.push({id:a,writeCallback:r,data:t}),a+=1},finish:function(t){l(),s.length?(s.forEach(function(t){delete t.writeCallback}),s[s.length-1].finishCallback=function(){return t(c())}):t(c())},finishSync:function(){l();var t=s.map(function(t){return delete t.writeCallback,delete t.finishCallback,t.data}).join("");return Y(c(),{pendingData:t})},estimateEncodedBytesCount:function(t){return t.length/8},stop:function(){u()}}}function ij(t){return new Worker(t.workerUrl||URL.createObjectURL(new Blob(['!function(){"use strict";function t(t){for(var e=t.reduce((function(t,e){return t+e.length}),0),a=new Uint8Array(e),n=0,r=0,i=t;r=0;)t[e]=0}var a=256,n=286,r=30,i=15,s=new Uint8Array([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0]),_=new Uint8Array([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13]),h=new Uint8Array([0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7]),l=new Uint8Array([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),o=new Array(576);e(o);var d=new Array(60);e(d);var u=new Array(512);e(u);var f=new Array(256);e(f);var c=new Array(29);e(c);var p,g,w,v=new Array(r);function b(t,e,a,n,r){this.static_tree=t,this.extra_bits=e,this.extra_base=a,this.elems=n,this.max_length=r,this.has_stree=t&&t.length}function m(t,e){this.dyn_tree=t,this.max_code=0,this.stat_desc=e}e(v);var y=function(t){return t<256?u[t]:u[256+(t>>>7)]},k=function(t,e){t.pending_buf[t.pending++]=255&e,t.pending_buf[t.pending++]=e>>>8&255},z=function(t,e,a){t.bi_valid>16-a?(t.bi_buf|=e<>16-t.bi_valid,t.bi_valid+=a-16):(t.bi_buf|=e<>>=1,a<<=1}while(--e>0);return a>>>1},E=function(t,e,a){var n,r,s=new Array(16),_=0;for(n=1;n<=i;n++)s[n]=_=_+a[n-1]<<1;for(r=0;r<=e;r++){var h=t[2*r+1];0!==h&&(t[2*r]=A(s[h]++,h))}},Z=function(t){var e;for(e=0;e8?k(t,t.bi_buf):t.bi_valid>0&&(t.pending_buf[t.pending++]=t.bi_buf),t.bi_buf=0,t.bi_valid=0},S=function(t,e,a,n){var r=2*e,i=2*a;return t[r]>1;a>=1;a--)R(t,s,a);r=l;do{a=t.heap[1],t.heap[1]=t.heap[t.heap_len--],R(t,s,1),n=t.heap[1],t.heap[--t.heap_max]=a,t.heap[--t.heap_max]=n,s[2*r]=s[2*a]+s[2*n],t.depth[r]=(t.depth[a]>=t.depth[n]?t.depth[a]:t.depth[n])+1,s[2*a+1]=s[2*n+1]=r,t.heap[1]=r++,R(t,s,1)}while(t.heap_len>=2);t.heap[--t.heap_max]=t.heap[1],function(t,e){var a,n,r,s,_,h,l=e.dyn_tree,o=e.max_code,d=e.stat_desc.static_tree,u=e.stat_desc.has_stree,f=e.stat_desc.extra_bits,c=e.stat_desc.extra_base,p=e.stat_desc.max_length,g=0;for(s=0;s<=i;s++)t.bl_count[s]=0;for(l[2*t.heap[t.heap_max]+1]=0,a=t.heap_max+1;a<573;a++)(s=l[2*l[2*(n=t.heap[a])+1]+1]+1)>p&&(s=p,g++),l[2*n+1]=s,n>o||(t.bl_count[s]++,_=0,n>=c&&(_=f[n-c]),h=l[2*n],t.opt_len+=h*(s+_),u&&(t.static_len+=h*(d[2*n+1]+_)));if(0!==g){do{for(s=p-1;0===t.bl_count[s];)s--;t.bl_count[s]--,t.bl_count[s+1]+=2,t.bl_count[p]--,g-=2}while(g>0);for(s=p;0!==s;s--)for(n=t.bl_count[s];0!==n;)(r=t.heap[--a])>o||(l[2*r+1]!==s&&(t.opt_len+=(s-l[2*r+1])*l[2*r],l[2*r+1]=s),n--)}}(t,e),E(s,o,t.bl_count)},T=function(t,e,a){var n,r,i=-1,s=e[1],_=0,h=7,l=4;for(0===s&&(h=138,l=3),e[2*(a+1)+1]=65535,n=0;n<=a;n++)r=s,s=e[2*(n+1)+1],++_0?(2===t.strm.data_type&&(t.strm.data_type=function(t){var e,n=4093624447;for(e=0;e<=31;e++,n>>>=1)if(1&n&&0!==t.dyn_ltree[2*e])return 0;if(0!==t.dyn_ltree[18]||0!==t.dyn_ltree[20]||0!==t.dyn_ltree[26])return 1;for(e=32;e=3&&0===t.bl_tree[2*l[e]+1];e--);return t.opt_len+=3*(e+1)+5+5+4,e}(t),i=t.opt_len+3+7>>>3,(s=t.static_len+3+7>>>3)<=i&&(i=s)):i=s=n+5,n+4<=i&&-1!==e?O(t,e,n,r):4===t.strategy||s===i?(z(t,2+(r?1:0),3),L(t,o,d)):(z(t,4+(r?1:0),3),function(t,e,a,n){var r;for(z(t,e-257,5),z(t,a-1,5),z(t,n-4,4),r=0;r>=7;l>>8&255,t.pending_buf[t.d_buf+2*t.last_lit+1]=255&e,t.pending_buf[t.l_buf+t.last_lit]=255&n,t.last_lit++,0===e?t.dyn_ltree[2*n]++:(t.matches++,e--,t.dyn_ltree[2*(f[n]+a+1)]++,t.dyn_dtree[2*y(e)]++),t.last_lit===t.lit_bufsize-1},_tr_align:function(t){z(t,2,3),x(t,256,o),function(t){16===t.bi_valid?(k(t,t.bi_buf),t.bi_buf=0,t.bi_valid=0):t.bi_valid>=8&&(t.pending_buf[t.pending++]=255&t.bi_buf,t.bi_buf>>=8,t.bi_valid-=8)}(t)}},C=function(t,e,a,n){for(var r=65535&t|0,i=t>>>16&65535|0,s=0;0!==a;){a-=s=a>2e3?2e3:a;do{i=i+(r=r+e[n++]|0)|0}while(--s);r%=65521,i%=65521}return r|i<<16|0},H=new Uint32Array(function(){for(var t,e=[],a=0;a<256;a++){t=a;for(var n=0;n<8;n++)t=1&t?3988292384^t>>>1:t>>>1;e[a]=t}return e}()),M=function(t,e,a,n){var r=H,i=n+a;t^=-1;for(var s=n;s>>8^r[255&(t^e[s])];return-1^t},Y={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"},K={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_MEM_ERROR:-4,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8},P=B._tr_init,j=B._tr_stored_block,G=B._tr_flush_block,X=B._tr_tally,W=B._tr_align,q=K.Z_NO_FLUSH,J=K.Z_PARTIAL_FLUSH,Q=K.Z_FULL_FLUSH,V=K.Z_FINISH,$=K.Z_BLOCK,tt=K.Z_OK,et=K.Z_STREAM_END,at=K.Z_STREAM_ERROR,nt=K.Z_DATA_ERROR,rt=K.Z_BUF_ERROR,it=K.Z_DEFAULT_COMPRESSION,st=K.Z_FILTERED,_t=K.Z_HUFFMAN_ONLY,ht=K.Z_RLE,lt=K.Z_FIXED,ot=K.Z_DEFAULT_STRATEGY,dt=K.Z_UNKNOWN,ut=K.Z_DEFLATED,ft=258,ct=262,pt=103,gt=113,wt=666,vt=function(t,e){return t.msg=Y[e],e},bt=function(t){return(t<<1)-(t>4?9:0)},mt=function(t){for(var e=t.length;--e>=0;)t[e]=0},yt=function(t,e,a){return(e<t.avail_out&&(a=t.avail_out),0!==a&&(t.output.set(e.pending_buf.subarray(e.pending_out,e.pending_out+a),t.next_out),t.next_out+=a,e.pending_out+=a,t.total_out+=a,t.avail_out-=a,e.pending-=a,0===e.pending&&(e.pending_out=0))},zt=function(t,e){G(t,t.block_start>=0?t.block_start:-1,t.strstart-t.block_start,e),t.block_start=t.strstart,kt(t.strm)},xt=function(t,e){t.pending_buf[t.pending++]=e},At=function(t,e){t.pending_buf[t.pending++]=e>>>8&255,t.pending_buf[t.pending++]=255&e},Et=function(t,e){var a,n,r=t.max_chain_length,i=t.strstart,s=t.prev_length,_=t.nice_match,h=t.strstart>t.w_size-ct?t.strstart-(t.w_size-ct):0,l=t.window,o=t.w_mask,d=t.prev,u=t.strstart+ft,f=l[i+s-1],c=l[i+s];t.prev_length>=t.good_match&&(r>>=2),_>t.lookahead&&(_=t.lookahead);do{if(l[(a=e)+s]===c&&l[a+s-1]===f&&l[a]===l[i]&&l[++a]===l[i+1]){i+=2,a++;do{}while(l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&l[++i]===l[++a]&&is){if(t.match_start=e,s=n,n>=_)break;f=l[i+s-1],c=l[i+s]}}}while((e=d[e&o])>h&&0!=--r);return s<=t.lookahead?s:t.lookahead},Zt=function(t){var e,a,n,r,i,s,_,h,l,o,d=t.w_size;do{if(r=t.window_size-t.lookahead-t.strstart,t.strstart>=d+(d-ct)){t.window.set(t.window.subarray(d,d+d),0),t.match_start-=d,t.strstart-=d,t.block_start-=d,e=a=t.hash_size;do{n=t.head[--e],t.head[e]=n>=d?n-d:0}while(--a);e=a=d;do{n=t.prev[--e],t.prev[e]=n>=d?n-d:0}while(--a);r+=d}if(0===t.strm.avail_in)break;if(s=t.strm,_=t.window,h=t.strstart+t.lookahead,l=r,o=void 0,(o=s.avail_in)>l&&(o=l),a=0===o?0:(s.avail_in-=o,_.set(s.input.subarray(s.next_in,s.next_in+o),h),1===s.state.wrap?s.adler=C(s.adler,_,o,h):2===s.state.wrap&&(s.adler=M(s.adler,_,o,h)),s.next_in+=o,s.total_in+=o,o),t.lookahead+=a,t.lookahead+t.insert>=3)for(i=t.strstart-t.insert,t.ins_h=t.window[i],t.ins_h=yt(t,t.ins_h,t.window[i+1]);t.insert&&(t.ins_h=yt(t,t.ins_h,t.window[i+3-1]),t.prev[i&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=i,i++,t.insert--,!(t.lookahead+t.insert<3)););}while(t.lookahead=3&&(t.ins_h=yt(t,t.ins_h,t.window[t.strstart+3-1]),a=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),0!==a&&t.strstart-a<=t.w_size-ct&&(t.match_length=Et(t,a)),t.match_length>=3)if(n=X(t,t.strstart-t.match_start,t.match_length-3),t.lookahead-=t.match_length,t.match_length<=t.max_lazy_match&&t.lookahead>=3){t.match_length--;do{t.strstart++,t.ins_h=yt(t,t.ins_h,t.window[t.strstart+3-1]),a=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart}while(0!=--t.match_length);t.strstart++}else t.strstart+=t.match_length,t.match_length=0,t.ins_h=t.window[t.strstart],t.ins_h=yt(t,t.ins_h,t.window[t.strstart+1]);else n=X(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++;if(n&&(zt(t,!1),0===t.strm.avail_out))return 1}return t.insert=t.strstart<2?t.strstart:2,e===V?(zt(t,!0),0===t.strm.avail_out?3:4):t.last_lit&&(zt(t,!1),0===t.strm.avail_out)?1:2},St=function(t,e){for(var a,n,r;;){if(t.lookahead=3&&(t.ins_h=yt(t,t.ins_h,t.window[t.strstart+3-1]),a=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart),t.prev_length=t.match_length,t.prev_match=t.match_start,t.match_length=2,0!==a&&t.prev_length4096)&&(t.match_length=2)),t.prev_length>=3&&t.match_length<=t.prev_length){r=t.strstart+t.lookahead-3,n=X(t,t.strstart-1-t.prev_match,t.prev_length-3),t.lookahead-=t.prev_length-1,t.prev_length-=2;do{++t.strstart<=r&&(t.ins_h=yt(t,t.ins_h,t.window[t.strstart+3-1]),a=t.prev[t.strstart&t.w_mask]=t.head[t.ins_h],t.head[t.ins_h]=t.strstart)}while(0!=--t.prev_length);if(t.match_available=0,t.match_length=2,t.strstart++,n&&(zt(t,!1),0===t.strm.avail_out))return 1}else if(t.match_available){if((n=X(t,0,t.window[t.strstart-1]))&&zt(t,!1),t.strstart++,t.lookahead--,0===t.strm.avail_out)return 1}else t.match_available=1,t.strstart++,t.lookahead--}return t.match_available&&(n=X(t,0,t.window[t.strstart-1]),t.match_available=0),t.insert=t.strstart<2?t.strstart:2,e===V?(zt(t,!0),0===t.strm.avail_out?3:4):t.last_lit&&(zt(t,!1),0===t.strm.avail_out)?1:2};function Rt(t,e,a,n,r){this.good_length=t,this.max_lazy=e,this.nice_length=a,this.max_chain=n,this.func=r}var Lt=[new Rt(0,0,0,0,(function(t,e){var a=65535;for(a>t.pending_buf_size-5&&(a=t.pending_buf_size-5);;){if(t.lookahead<=1){if(Zt(t),0===t.lookahead&&e===q)return 1;if(0===t.lookahead)break}t.strstart+=t.lookahead,t.lookahead=0;var n=t.block_start+a;if((0===t.strstart||t.strstart>=n)&&(t.lookahead=t.strstart-n,t.strstart=n,zt(t,!1),0===t.strm.avail_out))return 1;if(t.strstart-t.block_start>=t.w_size-ct&&(zt(t,!1),0===t.strm.avail_out))return 1}return t.insert=0,e===V?(zt(t,!0),0===t.strm.avail_out?3:4):(t.strstart>t.block_start&&(zt(t,!1),t.strm.avail_out),1)})),new Rt(4,4,8,4,Ut),new Rt(4,5,16,8,Ut),new Rt(4,6,32,32,Ut),new Rt(4,4,16,16,St),new Rt(8,16,32,32,St),new Rt(8,16,128,128,St),new Rt(8,32,128,256,St),new Rt(32,128,258,1024,St),new Rt(32,258,258,4096,St)];function Ft(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=ut,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new Uint16Array(1146),this.dyn_dtree=new Uint16Array(122),this.bl_tree=new Uint16Array(78),mt(this.dyn_ltree),mt(this.dyn_dtree),mt(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new Uint16Array(16),this.heap=new Uint16Array(573),mt(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new Uint16Array(573),mt(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}var Tt=function(t){if(!t||!t.state)return vt(t,at);t.total_in=t.total_out=0,t.data_type=dt;var e=t.state;return e.pending=0,e.pending_out=0,e.wrap<0&&(e.wrap=-e.wrap),e.status=e.wrap?42:gt,t.adler=2===e.wrap?0:1,e.last_flush=q,P(e),tt},It=function(t){var e,a=Tt(t);return a===tt&&((e=t.state).window_size=2*e.w_size,mt(e.head),e.max_lazy_match=Lt[e.level].max_lazy,e.good_match=Lt[e.level].good_length,e.nice_match=Lt[e.level].nice_length,e.max_chain_length=Lt[e.level].max_chain,e.strstart=0,e.block_start=0,e.lookahead=0,e.insert=0,e.match_length=e.prev_length=2,e.match_available=0,e.ins_h=0),a},Nt=function(t,e,a,n,r,i){if(!t)return at;var s=1;if(e===it&&(e=6),n<0?(s=0,n=-n):n>15&&(s=2,n-=16),r<1||r>9||a!==ut||n<8||n>15||e<0||e>9||i<0||i>lt)return vt(t,at);8===n&&(n=9);var _=new Ft;return t.state=_,_.strm=t,_.wrap=s,_.gzhead=null,_.w_bits=n,_.w_size=1<<_.w_bits,_.w_mask=_.w_size-1,_.hash_bits=r+7,_.hash_size=1<<_.hash_bits,_.hash_mask=_.hash_size-1,_.hash_shift=~~((_.hash_bits+3-1)/3),_.window=new Uint8Array(2*_.w_size),_.head=new Uint16Array(_.hash_size),_.prev=new Uint16Array(_.w_size),_.lit_bufsize=1<$||e<0)return t?vt(t,at):at;var r=t.state;if(!t.output||!t.input&&0!==t.avail_in||r.status===wt&&e!==V)return vt(t,0===t.avail_out?rt:at);r.strm=t;var i=r.last_flush;if(r.last_flush=e,42===r.status)if(2===r.wrap)t.adler=0,xt(r,31),xt(r,139),xt(r,8),r.gzhead?(xt(r,(r.gzhead.text?1:0)+(r.gzhead.hcrc?2:0)+(r.gzhead.extra?4:0)+(r.gzhead.name?8:0)+(r.gzhead.comment?16:0)),xt(r,255&r.gzhead.time),xt(r,r.gzhead.time>>8&255),xt(r,r.gzhead.time>>16&255),xt(r,r.gzhead.time>>24&255),xt(r,9===r.level?2:r.strategy>=_t||r.level<2?4:0),xt(r,255&r.gzhead.os),r.gzhead.extra&&r.gzhead.extra.length&&(xt(r,255&r.gzhead.extra.length),xt(r,r.gzhead.extra.length>>8&255)),r.gzhead.hcrc&&(t.adler=M(t.adler,r.pending_buf,r.pending,0)),r.gzindex=0,r.status=69):(xt(r,0),xt(r,0),xt(r,0),xt(r,0),xt(r,0),xt(r,9===r.level?2:r.strategy>=_t||r.level<2?4:0),xt(r,3),r.status=gt);else{var s=ut+(r.w_bits-8<<4)<<8;s|=(r.strategy>=_t||r.level<2?0:r.level<6?1:6===r.level?2:3)<<6,0!==r.strstart&&(s|=32),s+=31-s%31,r.status=gt,At(r,s),0!==r.strstart&&(At(r,t.adler>>>16),At(r,65535&t.adler)),t.adler=1}if(69===r.status)if(r.gzhead.extra){for(a=r.pending;r.gzindex<(65535&r.gzhead.extra.length)&&(r.pending!==r.pending_buf_size||(r.gzhead.hcrc&&r.pending>a&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),kt(t),a=r.pending,r.pending!==r.pending_buf_size));)xt(r,255&r.gzhead.extra[r.gzindex]),r.gzindex++;r.gzhead.hcrc&&r.pending>a&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),r.gzindex===r.gzhead.extra.length&&(r.gzindex=0,r.status=73)}else r.status=73;if(73===r.status)if(r.gzhead.name){a=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>a&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),kt(t),a=r.pending,r.pending===r.pending_buf_size)){n=1;break}n=r.gzindexa&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),0===n&&(r.gzindex=0,r.status=91)}else r.status=91;if(91===r.status)if(r.gzhead.comment){a=r.pending;do{if(r.pending===r.pending_buf_size&&(r.gzhead.hcrc&&r.pending>a&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),kt(t),a=r.pending,r.pending===r.pending_buf_size)){n=1;break}n=r.gzindexa&&(t.adler=M(t.adler,r.pending_buf,r.pending-a,a)),0===n&&(r.status=pt)}else r.status=pt;if(r.status===pt&&(r.gzhead.hcrc?(r.pending+2>r.pending_buf_size&&kt(t),r.pending+2<=r.pending_buf_size&&(xt(r,255&t.adler),xt(r,t.adler>>8&255),t.adler=0,r.status=gt)):r.status=gt),0!==r.pending){if(kt(t),0===t.avail_out)return r.last_flush=-1,tt}else if(0===t.avail_in&&bt(e)<=bt(i)&&e!==V)return vt(t,rt);if(r.status===wt&&0!==t.avail_in)return vt(t,rt);if(0!==t.avail_in||0!==r.lookahead||e!==q&&r.status!==wt){var _=r.strategy===_t?function(t,e){for(var a;;){if(0===t.lookahead&&(Zt(t),0===t.lookahead)){if(e===q)return 1;break}if(t.match_length=0,a=X(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++,a&&(zt(t,!1),0===t.strm.avail_out))return 1}return t.insert=0,e===V?(zt(t,!0),0===t.strm.avail_out?3:4):t.last_lit&&(zt(t,!1),0===t.strm.avail_out)?1:2}(r,e):r.strategy===ht?function(t,e){for(var a,n,r,i,s=t.window;;){if(t.lookahead<=ft){if(Zt(t),t.lookahead<=ft&&e===q)return 1;if(0===t.lookahead)break}if(t.match_length=0,t.lookahead>=3&&t.strstart>0&&(n=s[r=t.strstart-1])===s[++r]&&n===s[++r]&&n===s[++r]){i=t.strstart+ft;do{}while(n===s[++r]&&n===s[++r]&&n===s[++r]&&n===s[++r]&&n===s[++r]&&n===s[++r]&&n===s[++r]&&n===s[++r]&&rt.lookahead&&(t.match_length=t.lookahead)}if(t.match_length>=3?(a=X(t,1,t.match_length-3),t.lookahead-=t.match_length,t.strstart+=t.match_length,t.match_length=0):(a=X(t,0,t.window[t.strstart]),t.lookahead--,t.strstart++),a&&(zt(t,!1),0===t.strm.avail_out))return 1}return t.insert=0,e===V?(zt(t,!0),0===t.strm.avail_out?3:4):t.last_lit&&(zt(t,!1),0===t.strm.avail_out)?1:2}(r,e):Lt[r.level].func(r,e);if(3!==_&&4!==_||(r.status=wt),1===_||3===_)return 0===t.avail_out&&(r.last_flush=-1),tt;if(2===_&&(e===J?W(r):e!==$&&(j(r,0,0,!1),e===Q&&(mt(r.head),0===r.lookahead&&(r.strstart=0,r.block_start=0,r.insert=0))),kt(t),0===t.avail_out))return r.last_flush=-1,tt}return e!==V?tt:r.wrap<=0?et:(2===r.wrap?(xt(r,255&t.adler),xt(r,t.adler>>8&255),xt(r,t.adler>>16&255),xt(r,t.adler>>24&255),xt(r,255&t.total_in),xt(r,t.total_in>>8&255),xt(r,t.total_in>>16&255),xt(r,t.total_in>>24&255)):(At(r,t.adler>>>16),At(r,65535&t.adler)),kt(t),r.wrap>0&&(r.wrap=-r.wrap),0!==r.pending?tt:et)},deflateEnd:function(t){if(!t||!t.state)return at;var e=t.state.status;return 42!==e&&69!==e&&73!==e&&91!==e&&e!==pt&&e!==gt&&e!==wt?vt(t,at):(t.state=null,e===gt?vt(t,nt):tt)},deflateSetDictionary:function(t,e){var a=e.length;if(!t||!t.state)return at;var n=t.state,r=n.wrap;if(2===r||1===r&&42!==n.status||n.lookahead)return at;if(1===r&&(t.adler=C(t.adler,e,a,0)),n.wrap=0,a>=n.w_size){0===r&&(mt(n.head),n.strstart=0,n.block_start=0,n.insert=0);var i=new Uint8Array(n.w_size);i.set(e.subarray(a-n.w_size,a),0),e=i,a=n.w_size}var s=t.avail_in,_=t.next_in,h=t.input;for(t.avail_in=a,t.next_in=0,t.input=e,Zt(n);n.lookahead>=3;){var l=n.strstart,o=n.lookahead-2;do{n.ins_h=yt(n,n.ins_h,n.window[l+3-1]),n.prev[l&n.w_mask]=n.head[n.ins_h],n.head[n.ins_h]=l,l++}while(--o);n.strstart=l,n.lookahead=2,Zt(n)}return n.strstart+=n.lookahead,n.block_start=n.strstart,n.insert=n.lookahead,n.lookahead=0,n.match_length=n.prev_length=2,n.match_available=0,t.next_in=_,t.input=h,t.avail_in=s,n.wrap=r,tt},deflateInfo:"pako deflate (from Nodeca project)"};for(var Dt=new Uint8Array(256),Bt=0;Bt<256;Bt++)Dt[Bt]=Bt>=252?6:Bt>=248?5:Bt>=240?4:Bt>=224?3:Bt>=192?2:1;Dt[254]=Dt[254]=1;var Ct=function(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0},Ht=Object.prototype.toString,Mt=K.Z_NO_FLUSH,Yt=K.Z_SYNC_FLUSH,Kt=K.Z_FULL_FLUSH,Pt=K.Z_FINISH,jt=K.Z_OK,Gt=K.Z_STREAM_END,Xt=K.Z_DEFAULT_COMPRESSION,Wt=K.Z_DEFAULT_STRATEGY,qt=K.Z_DEFLATED;function Jt(){this.options={level:Xt,method:qt,chunkSize:16384,windowBits:15,memLevel:8,strategy:Wt};var t=this.options;t.raw&&t.windowBits>0?t.windowBits=-t.windowBits:t.gzip&&t.windowBits>0&&t.windowBits<16&&(t.windowBits+=16),this.err=0,this.msg="",this.ended=!1,this.chunks=[],this.strm=new Ct,this.strm.avail_out=0;var e=Ot.deflateInit2(this.strm,t.level,t.method,t.windowBits,t.memLevel,t.strategy);if(e!==jt)throw new Error(Y[e]);if(t.header&&Ot.deflateSetHeader(this.strm,t.header),t.dictionary){var a;if(a="[object ArrayBuffer]"===Ht.call(t.dictionary)?new Uint8Array(t.dictionary):t.dictionary,(e=Ot.deflateSetDictionary(this.strm,a))!==jt)throw new Error(Y[e]);this._dict_set=!0}}function Qt(t,e,a){try{t.postMessage({type:"errored",error:e,streamId:a})}catch(n){t.postMessage({type:"errored",error:String(e),streamId:a})}}function Vt(t){var e=t.strm.adler;return new Uint8Array([3,0,e>>>24&255,e>>>16&255,e>>>8&255,255&e])}Jt.prototype.push=function(t,e){var a,n,r=this.strm,i=this.options.chunkSize;if(this.ended)return!1;for(n=e===~~e?e:!0===e?Pt:Mt,"[object ArrayBuffer]"===Ht.call(t)?r.input=new Uint8Array(t):r.input=t,r.next_in=0,r.avail_in=r.input.length;;)if(0===r.avail_out&&(r.output=new Uint8Array(i),r.next_out=0,r.avail_out=i),(n===Yt||n===Kt)&&r.avail_out<=6)this.onData(r.output.subarray(0,r.next_out)),r.avail_out=0;else{if((a=Ot.deflate(r,n))===Gt)return r.next_out>0&&this.onData(r.output.subarray(0,r.next_out)),a=Ot.deflateEnd(this.strm),this.onEnd(a),this.ended=!0,a===jt;if(0!==r.avail_out){if(n>0&&r.next_out>0)this.onData(r.output.subarray(0,r.next_out)),r.avail_out=0;else if(0===r.avail_in)break}else this.onData(r.output)}return!0},Jt.prototype.onData=function(t){this.chunks.push(t)},Jt.prototype.onEnd=function(t){t===jt&&(this.result=function(t){for(var e=0,a=0,n=t.length;a>>6,e[i++]=128|63&a):a<65536?(e[i++]=224|a>>>12,e[i++]=128|a>>>6&63,e[i++]=128|63&a):(e[i++]=240|a>>>18,e[i++]=128|a>>>12&63,e[i++]=128|a>>>6&63,e[i++]=128|63&a);return e}(a.data);return n.push(i,K.Z_SYNC_FLUSH),{type:"wrote",id:a.id,streamId:a.streamId,result:t(n.chunks.slice(r)),trailer:Vt(n),additionalBytesCount:i.length};case"reset":e.delete(a.streamId)}}(a,n.data);r&&e.postMessage(r)}catch(t){Qt(e,t,n.data&&"streamId"in n.data?n.data.streamId:void 0)}}))}catch(t){Qt(e,t)}}()}();'])))}var iB={status:0};function iH(t,e,n,r){switch(void 0===r&&(r=ij),0===iB.status&&function(t,e,n){void 0===n&&(n=ij);try{var r=n(t),i=tC(t,r,"error",function(n){iF(t,e,n)}).stop,o=tC(t,r,"message",function(n){var r,i=n.data;"errored"===i.type?iF(t,e,i.error,i.streamId):"initialized"===i.type&&(r=i.version,1===iB.status&&(iB={status:3,worker:iB.worker,stop:iB.stop,version:r}))}).stop;r.postMessage({action:"init"}),tr(function(){1===iB.status&&(L.error("".concat(e," failed to start: a timeout occurred while initializing the Worker")),iB.initializationFailureCallbacks.forEach(function(t){return t()}),iB={status:2})},3e4),iB={status:1,worker:r,stop:function(){i(),o()},initializationFailureCallbacks:[]}}catch(n){iF(t,e,n)}}(t,e,r),iB.status){case 1:return iB.initializationFailureCallbacks.push(n),iB.worker;case 3:return iB.worker}}function iF(t,e,n,r){if(1===iB.status||0===iB.status){var i;if(L.error("".concat(e," failed to start: an error occurred while creating the Worker:"),n),n instanceof Event||n instanceof Error&&(q(i=n.message,"Content Security Policy")||q(i,"requires 'TrustedScriptURL'"))){var o=void 0;o=t.workerUrl?"Please make sure the Worker URL ".concat(t.workerUrl," is correct and CSP is correctly configured."):"Please make sure CSP is correctly configured.",L.error("".concat(o," See documentation at ").concat(D,"/integrations/content_security_policy_logs/#use-csp-with-real-user-monitoring-and-session-replay"))}else ef(n);1===iB.status&&iB.initializationFailureCallbacks.forEach(function(t){return t()}),iB={status:2}}else ef(n,{worker_version:3===iB.status&&iB.version,stream_id:r})}var iG=function(t,e,n){void 0===n&&(n={});var r,i,o,a=function(t){void 0===t&&(t=2);var e=new Map,n=!1;function r(r){if(void 0===r&&(r=0),!n&&0!==t){var i=2===t?3072:16384,o=r;e.forEach(function(t){o+=t.getBytesCount()}),o>i&&(L.warn("Customer data exceeds the recommended ".concat(i/1024,"KiB threshold. ").concat(j," ").concat(U,"/#customer-data-exceeds-the-recommended-threshold-warning")),n=!0)}}return{createDetachedTracker:function(){var t=tp(function(){return r(t.getBytesCount())});return t},getOrCreateTracker:function(t){return e.has(t)||e.set(t,tp(r)),e.get(t)},setCompressionStatus:function(e){0===t&&(t=e,r())},getCompressionStatus:function(){return t},stop:function(){e.forEach(function(t){return t.stop()}),e.clear()}}}(0),s=tT(a.getOrCreateTracker(2)),u=tT(a.getOrCreateTracker(1)),l={tryToInit:function(t){r||(r=t)},update:function(t){r=t,i.notify()},isGranted:function(){return r===tk.GRANTED},observable:i=new tS},d={vitalsByName:new Map,vitalsByReference:new WeakMap};function f(){return{context:s.getContext(),user:u.getContext(),hasReplay:!!e.isRecording()||void 0}}var h=function(t,e,n,r,i){var o,a,s,u,l=t.ignoreInitIfSyntheticsWillInjectRum,d=t.startDeflateWorker,f=ei(),h=n.observable.subscribe(v);function v(){if(s&&u&&n.isGranted()){if(h.unsubscribe(),u.trackViewsManually){if(!o)return;f.remove(o.callback),t=o.options}var t,e=i(u,a,t);f.drain(e)}}function g(t){var e,r,i,o,c,l,f,h,g,m=eT();if(m&&(t=Y({},e=t,{applicationId:"00000000-aaaa-0000-aaaa-000000000000",clientToken:"empty",sessionSampleRate:100,defaultPrivacyLevel:null!==(r=e.defaultPrivacyLevel)&&void 0!==r?r:null===(i=eS())||void 0===i?void 0:i.getPrivacyLevel()})),s=t,f={session_sample_rate:(c=o=t).sessionSampleRate,telemetry_sample_rate:c.telemetrySampleRate,telemetry_configuration_sample_rate:c.telemetryConfigurationSampleRate,telemetry_usage_sample_rate:c.telemetryUsageSampleRate,use_before_send:!!c.beforeSend,use_cross_site_session_cookie:c.useCrossSiteSessionCookie,use_partitioned_cross_site_session_cookie:c.usePartitionedCrossSiteSessionCookie,use_secure_session_cookie:c.useSecureSessionCookie,use_proxy:!!c.proxy,silent_multiple_init:c.silentMultipleInit,track_session_across_subdomains:c.trackSessionAcrossSubdomains,allow_fallback_to_local_storage:!!c.allowFallbackToLocalStorage,store_contexts_across_pages:!!c.storeContextsAcrossPages,allow_untrusted_events:!!c.allowUntrustedEvents,tracking_consent:c.trackingConsent},g=Y({session_replay_sample_rate:o.sessionReplaySampleRate,start_session_replay_recording_manually:o.startSessionReplayRecordingManually,trace_sample_rate:o.traceSampleRate,trace_context_injection:o.traceContextInjection,action_name_attribute:o.actionNameAttribute,use_allowed_tracing_urls:Array.isArray(o.allowedTracingUrls)&&o.allowedTracingUrls.length>0,selected_tracing_propagators:(h=new Set,Array.isArray(o.allowedTracingUrls)&&o.allowedTracingUrls.length>0&&o.allowedTracingUrls.forEach(function(t){e3(t)?e7.forEach(function(t){return h.add(t)}):"object"===tv(t)&&Array.isArray(t.propagatorTypes)&&t.propagatorTypes.forEach(function(t){return h.add(t)})}),J(h)),default_privacy_level:o.defaultPrivacyLevel,enable_privacy_for_action_name:o.enablePrivacyForActionName,use_excluded_activity_urls:Array.isArray(o.excludedActivityUrls)&&o.excludedActivityUrls.length>0,use_worker_url:!!o.workerUrl,compress_intake_requests:o.compressIntakeRequests,track_views_manually:o.trackViewsManually,track_user_interactions:o.trackUserInteractions,track_resources:o.trackResources,track_long_task:o.trackLongTasks,plugins:null===(l=o.betaPlugins)||void 0===l?void 0:l.map(function(t){var e;return Y({name:t.name},null===(e=t.getConfigurationTelemetry)||void 0===e?void 0:e.call(t))})},f),el({type:eo,configuration:g}),u){ev("DD_RUM",t);return}var y=function(t){if(!t.applicationId){L.error("Application ID is not configured, no RUM data will be collected.");return}if(e2(t.sessionReplaySampleRate,"Session Replay")&&e2(t.traceSampleRate,"Trace")){if(void 0!==t.excludedActivityUrls&&!Array.isArray(t.excludedActivityUrls)){L.error("Excluded Activity Urls should be an array");return}var e,n,r=function(t){if(void 0===t.allowedTracingUrls)return[];if(!Array.isArray(t.allowedTracingUrls)){L.error("Allowed Tracing URLs should be an array");return}if(0!==t.allowedTracingUrls.length&&void 0===t.service){L.error("Service needs to be configured when tracing is enabled");return}var e=[];return t.allowedTracingUrls.forEach(function(t){e3(t)?e.push({match:t,propagatorTypes:e7}):"object"===tv(t)&&e3(t.match)&&Array.isArray(t.propagatorTypes)?e.push(t):L.warn("Allowed Tracing Urls parameters should be a string, RegExp, function, or an object. Ignoring parameter",t)}),e}(t);if(r){var i=function(t){var e,n,r,i,o,a,s,u,c,l,d,f,h,v,g,m,y;if(!t||!t.clientToken){L.error("Client Token is not configured, we will not send any data.");return}if((!(a=t.site)||"string"!=typeof a||/(datadog|ddog|datad0g|dd0g)/.test(a)||(L.error("Site should be a valid Datadog site. ".concat(j," ").concat(D,"/getting_started/site/.")),0))&&e2(t.sessionSampleRate,"Session")&&e2(t.telemetrySampleRate,"Telemetry")&&e2(t.telemetryConfigurationSampleRate,"Telemetry Configuration")&&e2(t.telemetryUsageSampleRate,"Telemetry Usage")&&e1(t.version,"Version")&&e1(t.env,"Env")&&e1(t.service,"Service")){if(void 0!==t.trackingConsent&&!tf(tk,t.trackingConsent)){L.error('Tracking Consent should be either "granted" or "not-granted"');return}return Y({beforeSend:t.beforeSend&&B(t.beforeSend,"beforeSend threw an error:"),sessionStoreStrategyType:((m=!function(t){if(void 0===document.cookie||null===document.cookie)return!1;try{var e="dd_cookie_test_".concat(eg()),n="test";eN(e,n,6e4,t);var r=eP(e)===n;return eN(e,"",0,t),r}catch(t){return L.error(t),!1}}(((g={}).secure=!!t.useSecureSessionCookie||!!t.usePartitionedCrossSiteSessionCookie||!!t.useCrossSiteSessionCookie,g.crossSite=!!t.usePartitionedCrossSiteSessionCookie||!!t.useCrossSiteSessionCookie,g.partitioned=!!t.usePartitionedCrossSiteSessionCookie,t.trackSessionAcrossSubdomains&&(g.domain=function(){if(void 0===p){for(var t="dd_site_test_".concat(eg()),e=window.location.hostname.split("."),n=e.pop();e.length&&!eP(t);)eN(t,"test",1e3,{domain:n="".concat(e.pop(),".").concat(n)});eN(t,"",0,{domain:n}),p=n}return p}()),g))?void 0:{type:"Cookie",cookieOptions:g})||!t.allowFallbackToLocalStorage||(m=function(){try{var t=eg(),e="".concat("_dd_test_").concat(t);localStorage.setItem(e,t);var n=localStorage.getItem(e);return localStorage.removeItem(e),t===n?{type:"LocalStorage"}:void 0}catch(t){return}}()),m),sessionSampleRate:null!==(e=t.sessionSampleRate)&&void 0!==e?e:100,telemetrySampleRate:null!==(n=t.telemetrySampleRate)&&void 0!==n?n:20,telemetryConfigurationSampleRate:null!==(r=t.telemetryConfigurationSampleRate)&&void 0!==r?r:5,telemetryUsageSampleRate:null!==(i=t.telemetryUsageSampleRate)&&void 0!==i?i:5,service:t.service||void 0,silentMultipleInit:!!t.silentMultipleInit,allowUntrustedEvents:!!t.allowUntrustedEvents,trackingConsent:null!==(o=t.trackingConsent)&&void 0!==o?o:tk.GRANTED,storeContextsAcrossPages:!!t.storeContextsAcrossPages,batchBytesLimit:16384,eventRateLimiterThreshold:3e3,maxTelemetryEventsPerPage:15,flushTimeout:3e4,batchMessagesLimit:50,messageBytesLimit:262144},(s=t.site||tY,u=t.env,c=t.service,l=t.version,d=t.datacenter,f=[],u&&f.push(eY("env",u)),c&&f.push(eY("service",c)),l&&f.push(eY("version",l)),d&&f.push(eY("datacenter",d)),y=W(h={logsEndpointBuilder:eX(t,"logs",f),rumEndpointBuilder:eX(t,"rum",f),sessionReplayEndpointBuilder:eX(t,"replay",f)}).map(function(t){return t.urlPrefix}),s===tY&&y.push("https://".concat(tQ,"/")),Y({isIntakeUrl:function(t){return v.some(function(e){return 0===t.indexOf(e)})},replica:function(t,e,n){if(t.replica){var r=Y({},t,{site:tY,clientToken:t.replica.clientToken}),i={logsEndpointBuilder:eX(r,"logs",n),rumEndpointBuilder:eX(r,"rum",n)};return e.push.apply(e,W(i).map(function(t){return t.urlPrefix})),Y({applicationId:t.replica.applicationId},i)}}(t,v=y,f),site:s},h)))}}(t);if(i)return Y({applicationId:t.applicationId,version:t.version||void 0,actionNameAttribute:t.actionNameAttribute,sessionReplaySampleRate:null!==(e=t.sessionReplaySampleRate)&&void 0!==e?e:0,startSessionReplayRecordingManually:!!t.startSessionReplayRecordingManually,traceSampleRate:t.traceSampleRate,allowedTracingUrls:r,excludedActivityUrls:null!==(n=t.excludedActivityUrls)&&void 0!==n?n:[],workerUrl:t.workerUrl,compressIntakeRequests:!!t.compressIntakeRequests,trackUserInteractions:!!t.trackUserInteractions,trackViewsManually:!!t.trackViewsManually,trackResources:!!t.trackResources,trackLongTasks:!!t.trackLongTasks,subdomain:t.subdomain,defaultPrivacyLevel:tf(eQ,t.defaultPrivacyLevel)?t.defaultPrivacyLevel:eQ.MASK,enablePrivacyForActionName:!!t.enablePrivacyForActionName,customerDataTelemetrySampleRate:1,traceContextInjection:tf(e0,t.traceContextInjection)?t.traceContextInjection:e0.ALL,plugins:t.betaPlugins||[]},i)}}}(t);if(y){if(!m&&!y.sessionStoreStrategyType){L.warn("No storage available for session. We will not send any data.");return}(!y.compressIntakeRequests||m||!d||(a=d(y,"Datadog RUM",tu)))&&(u=y,eA().subscribe(tu),n.tryToInit(y.trackingConsent),v())}}var m=function(t){f.add(function(e){return e.addDurationVital(t)})};return{init:function(t,e){var n,r,i;if(!t){L.error("Missing configuration");return}Array.isArray(n=t.enableExperimentalFeatures)&&function(t){t.forEach(function(t){tW.add(t)})}(n.filter(function(t){return tf(c,t)})),s=t,!(l&&eM())&&((!function(t,e,n){if(t)for(var r=0;r=r&&f("bytes_limit"),d+=1,l+=t,void 0===e&&(e=tr(function(){f("duration_limit")},i))},notifyAfterAddMessage:function(t){void 0===t&&(t=0),l+=t,d>=n?f("messages_limit"):l>=r&&f("bytes_limit")},notifyAfterRemoveMessage:function(t){l-=t,0==(d-=1)&&h()}}}({messagesLimit:t.batchMessagesLimit,bytesLimit:t.batchBytesLimit,durationLimit:t.flushTimeout,pageExitObservable:i,sessionExpireObservable:o}),messageBytesLimit:t.messageBytesLimit})}return{flushObservable:s.flushController.flushObservable,add:function(t,e){void 0===e&&(e=!0),s.add(t),u&&e&&u.add(n.transformMessage?n.transformMessage(t):t)},upsert:function(t,e){s.upsert(t,e),u&&u.upsert(n.transformMessage?n.transformMessage(t):t,e)},stop:function(){s.stop(),u&&u.stop()}}}(t,{endpoint:t.rumEndpointBuilder,encoder:o(2)},X&&{endpoint:X.rumEndpointBuilder,transformMessage:function(t){return ty(t,{application:{id:X.applicationId}})},encoder:o(3)},A,M,W),k.subscribe(12,function(t){"view"===t.type?Q.upsert(t,t.view.id):Q.add(t)}),K.subscribe(function(e){return Q.add(e,t.site===tX)}),Q);E.push(function(){return tt.stop()}),j=tt.flushObservable,I.enabled&&t0(t.customerDataTelemetrySampleRate)&&(r3(),r5(),k.subscribe(12,function(t){O=!0,r1(x.globalContextBytes,n.getOrCreateTracker(2).getBytesCount()),r1(x.userContextBytes,n.getOrCreateTracker(1).getBytesCount()),r1(x.featureFlagBytes,q(["view","error"],t.type)?n.getOrCreateTracker(0).getBytesCount():0)}),j.subscribe(function(t){var e=t.bytesCount,n=t.messagesCount;O&&(C.batchCount+=1,r1(C.batchBytesCount,e),r1(C.batchMessagesCount,n),r2(C.globalContextBytes,x.globalContextBytes),r2(C.userContextBytes,x.userContextBytes),r2(C.featureFlagBytes,x.featureFlagBytes),r5())}),to(rQ,1e4))}var te=(eO=nn(),new tS(function(t){if(eO){var e=new eO(z(function(){return t.notify()}));return e.observe(document,{attributes:!0,characterData:!0,childList:!0,subtree:!0}),function(){return e.disconnect()}}})),tn=(eP=td(eI=location),new tS(function(e){var n,r,i,o=(n=ek(rY("pushState"),"pushState",function(t){(0,t.onPostCall)(s)}).stop,r=ek(rY("replaceState"),"replaceState",function(t){(0,t.onPostCall)(s)}).stop,i=tC(t,window,"popstate",s).stop,{stop:function(){n(),r(),i()}}).stop,a=tC(t,window,"hashchange",s).stop;function s(){if(eP.href!==eI.href){var t=td(eI);e.notify({newLocation:t,oldLocation:eP}),eP=t}}return function(){o(),a()}})),tl=function(t,e){void 0===e&&(e=500);var n,r=nf({expireDelay:144e5,maxEntries:4e3});o(r4(),t8());var i=tx(t,window,["pageshow","focus","blur","visibilitychange","resume","freeze","pagehide"],function(t){o("freeze"===t.type?"frozen":"pagehide"===t.type?t.persisted?"frozen":"terminated":r4(),t.timeStamp)},{capture:!0}).stop;function o(t,e){void 0===e&&(e=t8()),t!==n&&(n=t,r.closeActive(e),r.add({state:n,startTime:e},e))}var a={findAll:function(t,n){var i=r.findAll(t,n);if(0!==i.length){for(var o=[],a=Math.max(0,i.length-e),s=i.length-1;s>=a;s--){var u=i[s],c=u.startTime-t;o.push({state:u.state,start:t5(c)})}return o}},wasInPageStateAt:function(t,e){return a.wasInPageStateDuringPeriod(t,e,0)},wasInPageStateDuringPeriod:function(t,e,n){return r.findAll(e,n).some(function(e){return e.state===t})},addPageState:o,stop:function(){i(),r.stop()}};return a}(t),tf=(tU=k,tj=t,tB=location,tH=U,tK=tl,tY=tn,tQ=te,t2=r,er=A,eh=(ei=nf({expireDelay:144e5}),tU.subscribe(1,function(t){ei.add({service:t.service,version:t.version,context:t.context,id:t.id,name:t.name,startClocks:t.startClocks},t.startClocks.relative)}),tU.subscribe(5,function(t){var e=t.endClocks;ei.closeActive(e.relative)}),tU.subscribe(3,function(t){var e=ei.find(t.startClocks.relative);e&&t.name&&(e.name=t.name),e&&t.context&&(e.context=t.context)}),tU.subscribe(9,function(){ei.reset()}),{findView:function(t){return ei.find(t)},stop:function(){ei.stop()}}),ep=function(t,e,n){var r,i=nf({expireDelay:144e5});t.subscribe(1,function(t){var e=t.startClocks,o=n.href;i.add(a({url:o,referrer:r||document.referrer}),e.relative),r=o}),t.subscribe(5,function(t){var e=t.endClocks;i.closeActive(e.relative)});var o=e.subscribe(function(t){var e=t.newLocation,n=i.find();if(n){var r=t8();i.closeActive(r),i.add(a({url:e.href,referrer:n.referrer}),r)}});function a(t){return{url:t.url,referrer:t.referrer}}return{findUrl:function(t){return i.find(t)},stop:function(){o.unsubscribe(),i.stop()}}}(tU,tY,tB),em=(ev=function(t,e,n,r){t.subscribe(0,function(e){return t.notify(11,rv(e,r))});var i={findActionId:tu};return n.trackUserInteractions&&(i=function(t,e,n){var r,i,o,a,s,u,c,l,d=nf({expireDelay:3e5}),f=new tS;t.subscribe(9,function(){d.reset()}),t.subscribe(4,v);var h=(a=(r={onPointerDown:function(r){return function(t,e,n,r){var i,o=t.enablePrivacyForActionName?nW(r.target,t.defaultPrivacyLevel):nK.ALLOW;if(o!==nK.HIDDEN){var a,s,u,c,l,d,f,h,p,v=(a=r,s=o,u=t,h=a.target.getBoundingClientRect(),(p=rr(a.target,u.actionNameAttribute))&&rp(a.timeStamp,p),{type:"click",target:{width:Math.round(h.width),height:Math.round(h.height),selector:p},position:{x:Math.round(a.clientX-h.left),y:Math.round(a.clientY-h.top)},name:(c=a.target,l=u.enablePrivacyForActionName,d=u.actionNameAttribute,f=n3(c,n2)||d&&n3(c,d),s===nK.MASK?f||"Masked Element":f||n6(c,d,n5,l)||n6(c,d,n4,l)||"")}),g=!1;return i=function(t){g=t.hadActivity},nP(nR(e,n,t),i,100),{clickActionBase:v,hadActivityOnPointerDown:function(){return g}}}}(n,t,e,r)},onPointerUp:function(r,i,o){var a,s,u,c,l,h,v,g,m,y,_,b,w,S,E,T,k;a=n,s=t,u=e,c=d,l=f,h=p,v=r.clickActionBase,g=i,m=o,y=r.hadActivityOnPointerDown,h(w=function t(e,n,r,i,o){var a,s=eg(),u=t9(),c=n.add(s,u.relative),l=nI({lifeCycle:e,isChildEvent:function(t){return void 0!==t.action&&(Array.isArray(t.action.id)?q(t.action.id,s):t.action.id===s)}}),d=0,f=[],h=new tS;function p(t){0===d&&((d=1,a=t)?c.close(a-et()):c.remove(),l.stop(),h.notify())}return{event:o,stop:p,stopObservable:h,get hasError(){return l.eventCounts.errorCount>0},get hasPageActivity(){return void 0!==a},getUserActivity:r,addFrustration:function(t){f.push(t)},startClocks:u,isStopped:function(){return 1===d||2===d},clone:function(){return t(e,n,r,i,o)},validate:function(t){if(p(),1===d){var n,r=l.eventCounts,c=r.resourceCount,h=r.errorCount,v=r.longTaskCount,g=Y({type:"click",duration:a&&(n=u.timeStamp,a-n),startClocks:u,id:s,frustrationTypes:f,counts:{resourceCount:c,errorCount:h,longTaskCount:v},events:null!=t?t:[o],event:o},i);e.notify(0,g),d=2}},discard:function(){p(),d=2}}}(s,c,m,v,g)),(S=null===(b=null==v?void 0:v.target)||void 0===b?void 0:b.selector)&&rp(g.timeStamp,S),E=(_=function(t){t.hadActivity&&t.end0)||(e=r[r.length-1].event,n=t.event,e.target===n.target&&100>=Math.sqrt(Math.pow(e.clientX-n.clientX,2)+Math.pow(e.clientY-n.clientY,2))&&e.timeStamp-n.timeStamp<=1e3)?(o(t),!0):(s(),!1))},stop:function(){s()}}}(t,function(t){(function(t,e){if(function(t){if(t.some(function(t){return t.getUserActivity().selection||t.getUserActivity().scroll}))return!1;for(var e=0;e0){var t=Math.max.apply(Math,c);tb&&(b=e,i=!0),r>w&&(w=r,S=t8()-f.relative,i=!0),i&&m({maxDepth:Math.min(b,w),maxDepthScrollTop:n,maxScrollHeight:w,maxScrollHeightTime:S})}),{stop:function(){return E.unsubscribe()}}).stop,C=function(t,e,n){if(!(nN(_.LAYOUT_SHIFT)&&"WeakRef"in window))return{stop:tu};var r,i,o,a,s,u,c=0;n({value:0});var l=(o=0,a=0,{update:function(t){var e;return void 0===r||t.startTime-i>=1e3||t.startTime-r>=5e3?(r=i=t.startTime,a=o=t.value,e=!0):(o+=t.value,i=t.startTime,(e=t.value>a)&&(a=t.value)),{cumulatedValue:o,isMaxValue:e}}}),d=nA(t,{type:_.LAYOUT_SHIFT,buffered:!0}).subscribe(function(r){for(var i=0;ic){c=d;var f=null==s?void 0:s.deref();n({value:t1(c,4),targetSelector:f&&rr(f,t.actionNameAttribute),time:u})}}}});return{stop:function(){d.unsubscribe()}}}(n,f.relative,function(t){h.cumulativeLayoutShift=t,ty()}).stop,O=(x=function(t,e,n){if(!(nN(_.EVENT)&&window.PerformanceEventTiming&&"interactionId"in PerformanceEventTiming.prototype))return{getInteractionToNextPaint:function(){},setViewEnd:tu,stop:tu};var r,i,o,a,s=("interactionCount"in performance||T||(T=new window.PerformanceObserver(z(function(t){t.getEntries().forEach(function(t){t.interactionId&&(rR=Math.min(rR,t.interactionId),rP=((rM=Math.max(rM,t.interactionId))-rR)/7+1)})}))).observe({type:"event",buffered:!0,durationThreshold:0}),r="initial_load"===n?0:rL(),i={stopped:!1},{getViewInteractionCount:function(){return i.stopped?i.interactionCount:rL()-r},stopViewInteractionCount:function(){i={stopped:!0,interactionCount:rL()-r}}}),u=s.getViewInteractionCount,c=s.stopViewInteractionCount,l=1/0,d=function(t){var e=[];function n(){e.sort(function(t,e){return e.duration-t.duration}).splice(10)}return{process:function(t){var r=e.findIndex(function(e){return t.interactionId===e.interactionId}),i=e[e.length-1];-1!==r?t.duration>e[r].duration&&(e[r]=t,n()):(e.length<10||t.duration>i.duration)&&(e.push(t),n())},estimateP98Interaction:function(){var n=Math.min(e.length-1,Math.floor(t()/50));return e[n]}}}(u),f=-1;function h(n){for(var r,i,s=0;s=e&&u.startTime<=l&&d.process(u)}var c=d.estimateP98Interaction();c&&c.duration!==f&&(f=c.duration,a=c.startTime-e,r=c.startTime,i=rh.get(r),rh.delete(r),!(o=i)&&c.target&&nH(c.target)&&(o=rr(c.target,t.actionNameAttribute)))}var p=nA(t,{type:_.FIRST_INPUT,buffered:!0}).subscribe(h),v=nA(t,{type:_.EVENT,durationThreshold:40,buffered:!0}).subscribe(h);return{getInteractionToNextPaint:function(){return f>=0?{value:Math.min(f,6e4),targetSelector:o,time:a}:u()?{value:0}:void 0},setViewEnd:function(t){l=t,c()},stop:function(){v.unsubscribe(),p.unsubscribe()}}}(n,f.relative,i)).stop,I=x.getInteractionToNextPaint,{stop:function(){v(),C(),k()},stopINPTracking:O,setLoadEvent:g,setViewEnd:x.setViewEnd,getCommonViewMetrics:function(){return h.interactionToNextPaint=I(),h}}),tw=tb.setLoadEvent,tE=tb.setViewEnd,tk=tb.stop,tO=tb.stopINPTracking,tI=tb.getCommonViewMetrics,tA="initial_load"===i?(A={},R=(N=function(t){tw(t.loadEvent),A.navigationTimings=t,ty()},void 0===P&&(P=rC),u=function(){var t=P();t.loadEventEnd<=0||N({domComplete:t.domComplete,domContentLoaded:t.domContentLoadedEventEnd,domInteractive:t.domInteractive,loadEvent:t.loadEventEnd,firstByte:t.responseStart>=0&&t.responseStart<=t8()?t.responseStart:void 0})},d=rE(n,"complete",function(){l=tr(function(){return u()})}).stop,{stop:function(){d(),ti(l)}}).stop,M=rN(n),U=(D=function(t){A.firstContentfulPaint=t,ty()},{stop:nA(n,{type:_.PAINT,buffered:!0}).subscribe(function(t){var e=Z(t,function(t){return"first-contentful-paint"===t.name&&t.startTime=0;n-=1){var r=t[n];if(e(r,n,t))return r}}(t,function(t){return t.entryType===_.LARGEST_CONTENTFUL_PAINT&&t.startTimeG});if(e){var r=void 0;e.element&&(r=rr(e.element,n.actionNameAttribute)),B({value:e.startTime,targetSelector:r}),G=e.size}}),{stop:function(){F(),V.unsubscribe()}}).stop,W=(q=function(t){A.firstInput=t,ty()},J=nA(n,{type:_.FIRST_INPUT,buffered:!0}).subscribe(function(t){var e=Z(t,function(t){return t.startTime=0?i:0,time:e.startTime,targetSelector:o})}}),{stop:function(){J.unsubscribe()}}).stop,{stop:function(){R(),U(),K(),W(),M.stop()},initialViewMetrics:A}):{stop:tu,initialViewMetrics:{}},tN=tA.stop,tP=tA.initialViewMetrics,tR={stop:($=nI({lifeCycle:t,isChildEvent:function(t){return t.view.id===tn},onChange:ty})).stop,eventCounts:$.eventCounts},tM=tR.stop,tL=tR.eventCounts,tD=to(tU,3e5);function tU(){t_(),tf+=1;var e=void 0===X?t6():X.timeStamp;t.notify(3,{customTimings:tl,documentVersion:tf,id:tn,name:Y,service:Q,version:tt,context:tp.getContext(),loadingType:i,location:th,startClocks:o,commonViewMetrics:tI(),initialViewMetrics:tP,duration:e-o.timeStamp,isActive:void 0===X,sessionIsActive:tv,eventCounts:tL})}return tU(),tp.changeObservable.subscribe(tU),{get name(){return Y},service:Q,version:tt,contextManager:tp,stopObservable:tc,end:function(e){var n,r,i=this;void 0===e&&(e={}),X||(X=null!==(n=e.endClocks)&&void 0!==n?n:t9(),tv=null===(r=e.sessionIsActive)||void 0===r||r,t.notify(4,{endClocks:X}),t.notify(5,{endClocks:X}),ta(tD),tE(X.relative),tk(),tU(),tr(function(){i.stop()},3e5))},stop:function(){tN(),tM(),tO(),tc.notify()},addTiming:function(t,e){if(!X){var n,r=e<31536e6?e:e-o.timeStamp;tl[(n=t.replace(/[^a-zA-Z0-9-_.@$]/g,"_"))!==t&&L.warn("Invalid timing name: ".concat(t,", sanitized to: ").concat(n)),n]=r,ty()}},updateViewName:function(t){t$(c.UPDATE_VIEW_NAME)&&(Y=t,tU())}}}(e,n,r,t,i,o,a);return u.add(s),s.stopObservable.subscribe(function(){u.delete(s)}),s}return e.subscribe(9,function(){l=d("route_change",void 0,{name:l.name,service:l.service,version:l.version,context:l.contextManager.getContext()})}),e.subscribe(8,function(){l.end({sessionIsActive:!1})}),e.subscribe(10,function(t){t.reason===ne.UNLOADING&&l.end()}),o&&(s=i.subscribe(function(t){var e,n,r;e=t.oldLocation,n=t.newLocation,e.pathname===n.pathname&&(""!==(r=n.hash.substring(1))&&document.getElementById(r)||rH(n.hash)===rH(e.hash))||(l.end(),l=d("route_change"))})),{addTiming:function(t,e){void 0===e&&(e=t6()),l.addTiming(t,e)},startView:function(t,e){l.end({endClocks:e}),l=d("route_change",e,t)},setViewContext:function(t){l.contextManager.setContext(t)},setViewContextProperty:function(t,e){l.contextManager.setContextProperty(t,e)},updateViewName:function(t){l.updateViewName(t)},stop:function(){s&&s.unsubscribe(),l.end(),u.forEach(function(t){return t.stop()})}}}(eU,k,te,t,tn,!t.trackViewsManually,i)),tI=tO.addTiming,tA=tO.startView,tP=tO.updateViewName,tR=tO.setViewContext,tM=tO.setViewContextProperty,tL=tO.stop;E.push(tL);var tD=(void 0===eG&&(eG=rx),k.subscribe(7,function(e){var n=function(t,e,n){var r=function(t){if(performance&&"getEntriesByName"in performance){var e=performance.getEntriesByName(t.url,"resource");if(e.length&&"toJSON"in e[0]){var n=e.filter(function(t){return!rw.has(t)}).filter(function(t){return n_(t)&&nb(t)}).filter(function(e){var n,r;return n=t.startClocks.relative,r=rS({startTime:t.startClocks.relative,duration:t.duration}),e.startTime>=n-1&&rS(e)<=r+1});if(1===n.length)return rw.add(n[0]),n[0].toJSON()}}}(t),i=r?t3(r.startTime):t.startClocks,o=function(t,e){if(t.traceSampled&&t.traceId&&t.spanId)return{_dd:{span_id:t.spanId.toDecimalString(),trace_id:t.traceId.toDecimalString(),rule_psr:rA(e)}}}(t,e);if(e.trackResources||o){var a,s="xhr"===t.type?"xhr":"fetch",u=r?rI(r):void 0,c=(a=t.duration,n.wasInPageStateDuringPeriod("frozen",i.relative,a)?void 0:t5(a)),l=ty({date:i.timeStamp,resource:{id:eg(),type:s,duration:c,method:t.method,status_code:t.status,url:nT(t.url)?nk(t.url):t.url},type:"resource",_dd:{discarded:!e.trackResources}},o,u);return{startTime:i.relative,rawRumEvent:l,domainContext:{performanceEntry:r,xhr:t.xhr,response:t.response,requestInput:t.input,requestInit:t.init,error:t.error,isAborted:t.isAborted,handlingStack:t.handlingStack}}}}(e,t,tl);n&&k.notify(11,n)}),eJ=nA(t,{type:_.RESOURCE,buffered:!0}).subscribe(function(e){for(var n=0;nn.bytesLimit}e(void 0,t,a)}(function t(){r.read().then(z(function(e){if(e.done){a();return}n.collectStreamBody&&i.push(e.value),(o+=e.value.length)>n.bytesLimit?a():t()}),z(function(t){return e(t)}))})()}(i.body,function(){var t;n((t=e.startClocks.timeStamp,t6()-t))},{bytesLimit:Number.POSITIVE_INFINITY,collectStreamBody:!1}):n((r=e.startClocks.timeStamp,t6()-r))}});var eY=function(t,e,n){function r(n){if(!e.wasInPageStateDuringPeriod("frozen",n.startClocks.relative,n.duration)){var r;t.notify(11,(r={date:n.startClocks.timeStamp,vital:{id:eg(),type:n.type,name:n.name,duration:t5(n.duration),description:n.description},type:"vital"},r._dd={vital:{computed_value:!0}},{rawRumEvent:r,startTime:n.startClocks.relative,customerContext:n.context,domainContext:{}}))}}return{addDurationVital:r,startDurationVital:function(t,e){return void 0===e&&(e={}),eb(n,t,e)},stopDurationVital:function(t,e){void 0===e&&(e={}),ew(r,n,t,e)}}}(k,tl,s),eQ=(S=t.applicationId,{get:function(t){var e=tp.findView(t),n=tg.findUrl(t),r=U.findTrackedSession(t);if(r&&e&&n){var i=tb.findActionId(t);return{application_id:S,session_id:r.id,user_action:i?{id:i}:void 0,view:{id:e.id,name:e.name,referrer:n.referrer,url:n.url}}}}});return{addAction:tw,addError:eX,addTiming:tI,addFeatureFlagEvaluation:R.addFeatureFlagEvaluation,startView:tA,setViewContext:tR,setViewContextProperty:tM,updateViewName:tP,lifeCycle:k,viewHistory:tp,session:U,stopSession:function(){return U.expire()},getInternalContext:eQ.get,startDurationVital:eY.startDurationVital,stopDurationVital:eY.stopDurationVital,addDurationVital:eY.addDurationVital,stop:function(){E.forEach(function(t){return t()})}}},function(t,e){if(eT()&&!eE("records")||!iD())return{start:tu,stop:tu,getReplayStats:function(){},onRumStart:tu,isRecording:function(){return!1},getSessionReplayLink:function(){}};var n={status:1},r=function(){n={status:1}},i=function(){n={status:0}},o=tu;return{start:function(t){return r(t)},stop:function(){return i()},getSessionReplayLink:function(){return o()},onRumStart:function(e,a,s,u,c){var l;a.startSessionReplayRecordingManually&&(n={status:0}),e.subscribe(8,function(){(2===n.status||3===n.status)&&(i(),n={status:1})}),e.subscribe(10,function(t){t.reason===ne.UNLOADING&&i()}),e.subscribe(9,function(){1===n.status&&r()}),r=function(r){var o=s.findTrackedSession();if(!o||0===o.sessionReplay&&(!r||!r.force)){n={status:1};return}2!==n.status&&3!==n.status&&(n={status:2},rE(a,"interactive",function(){if(2===n.status){var r=(!l&&(c||(c=iH(a,"Datadog Session Replay",function(){i()},void 0)),c&&(l=iU(a,c,1))),l);if(!r){n={status:0};return}n={status:3,stopRecording:t(e,a,s,u,r).stop}}}),r&&r.force&&0===o.sessionReplay&&s.setForcedReplay())},i=function(){0!==n.status&&(3===n.status&&n.stopRecording(),n={status:0})},o=function(){var t,e,r,i,o,c,l,d,f,h,p,v,g;return t=0!==n.status,p=e=s.findTrackedSession(),r=iD()?p?0===p.sessionReplay?"incorrect-session-plan":t?void 0:"replay-not-started":"rum-not-tracked":"browser-not-supported",o=(i={viewContext:u.findView(),errorType:r,session:e}).session,c=i.viewContext,l=i.errorType,d=o?o.id:"no-session-id",f=[],void 0!==l&&f.push("error-type=".concat(l)),c&&(f.push("seed=".concat(c.id)),f.push("from=".concat(c.startClocks.timeStamp))),v=a.site,g=a.subdomain||function(t){switch(t.site){case tY:case"datadoghq.eu":return"app";case tX:return"dd";default:return}}(a),h="https://".concat(g?"".concat(g,"."):"").concat(v),"".concat(h).concat("/rum/replay/sessions/".concat(d),"?").concat(f.join("&"))},1===n.status&&r()},isRecording:function(){return 3===iB.status&&3===n.status},getReplayStats:function(t){return 3===iB.status?null==I?void 0:I.get(t):void 0}}}(function(t,e,n,r,i,o){var a,s=[],u=o||rW(e,e.sessionReplayEndpointBuilder,6e4,function(e){t.notify(13,{error:e}),ed("Error reported to customer",{"error.message":e.message})});if(eT())a=(c=eS(),{addRecord:function(t){var e=r.findView();c.send("record",t,e.id)}}).addRecord;else{var c,l=function(t,e,n,r){var i={status:0,nextSegmentCreationReason:"init"},o=t.subscribe(2,function(){s("view_change")}).unsubscribe,a=t.subscribe(10,function(t){s(t.reason)}).unsubscribe;function s(t){1===i.status&&(i.segment.flush(function(e,r){var i,o,a,s,u=(i=r.output,o=r.rawBytesCount,(a=new FormData).append("segment",new Blob([i],{type:"application/octet-stream"}),"".concat(e.session.id,"-").concat(e.start)),s=JSON.stringify(Y({raw_segment_size:o,compressed_segment_size:i.byteLength},e)),a.append("event",new Blob([s],{type:"application/json"})),{data:a,bytesCount:i.byteLength});q(W(ne),t)?n.sendOnExit(u):n.send(u)}),ti(i.expirationTimeoutId)),i="stop"!==t?{status:0,nextSegmentCreationReason:t}:{status:2}}return{addRecord:function(t){if(2!==i.status){if(0===i.status){var n,o,a,u,c,l,d,f=e();if(!f)return;i={status:1,segment:(o=(n={encoder:r,context:f,creationReason:i.nextSegmentCreationReason}).context,a=n.creationReason,u=n.encoder,c=0,d=Y({start:1/0,end:-1/0,creation_reason:a,records_count:0,has_full_snapshot:!1,index_in_view:r9(l=o.view.id).segments_count,source:"browser"},o),r9(l).segments_count+=1,{addRecord:function(t,e){d.start=Math.min(d.start,t.timestamp),d.end=Math.max(d.end,t.timestamp),d.records_count+=1,d.has_full_snapshot||(d.has_full_snapshot=t.type===il.FullSnapshot);var n=u.isEmpty?'{"records":[':",";u.write(n+JSON.stringify(t),function(t){e(c+=t)})},flush:function(t){if(u.isEmpty)throw Error("Empty segment flushed");u.write("],".concat(JSON.stringify(d).slice(1),"\n")),u.finish(function(e){var n,r;n=d.view.id,r=e.rawBytesCount,r9(n).segments_total_raw_size+=r,t(d,e)})}}),expirationTimeoutId:tr(function(){s("segment_duration_limit")},5e3)}}i.segment.addRecord(t,function(t){t>6e4&&s("segment_bytes_limit")})}},stop:function(){s("stop"),o(),a()}}}(t,function(){return function(t,e,n){var r=e.findTrackedSession(),i=n.findView();if(r&&i)return{application:{id:t},session:{id:r.id},view:{id:i.id}}}(e.applicationId,n,r)},u,i);a=l.addRecord,s.push(l.stop)}var d=function(t){var e,n,r,i,o,a,s,u,c,l,d,f,h,p,v=t.emit,g=t.configuration,m=t.lifeCycle;if(!v)throw Error("emit function is required");var y=function(e){var n;v(e),ee("record",{record:e}),n=t.viewHistory.findView().id,r9(n).records_count+=1},_=(e=new WeakMap,{set:function(t,n){(t!==document||document.scrollingElement)&&e.set(t===document?document.scrollingElement:t,n)},get:function(t){return e.get(t)},has:function(t){return e.has(t)}}),b=iL(g,y,_),w=(n=S,(r=function(t){return t.forEach(function(t){return y(t)})})((i=function(t,e){void 0===t&&(t=t6()),void 0===e&&(e={status:0,elementsScrollPositions:_,shadowRootsController:b});var n=rB(),r=n.width,i=[{data:{height:n.height,href:window.location.href,width:r},type:il.Meta,timestamp:t},{data:{has_focus:document.hasFocus()},type:il.Focus,timestamp:t},{data:{node:iw(document,{serializationContext:e,parentNodePrivacyLevel:g.defaultPrivacyLevel,configuration:g}),initialOffset:{left:rD(),top:rU()}},type:il.FullSnapshot,timestamp:t}];return window.visualViewport&&i.push({data:ix(window.visualViewport),type:il.VisualViewport,timestamp:t}),i})()),{stop:m.subscribe(2,function(t){n(),r(i(t.startClocks.timeStamp,{shadowRootsController:b,status:1,elementsScrollPositions:_}))}).unsubscribe}).stop;function S(){b.flush(),T.flush()}var E=(o=new WeakMap,a=1,{getIdForEvent:function(t){return o.has(t)||o.set(t,a++),o.get(t)}}),T=iM(y,g,b,document),k=[T,(u=(s=ts(function(t){var e=ik(t);if(it(e)){var n=iI(t);if(!n)return;var r={id:ie(e),timeOffset:0,x:n.x,y:n.y};y(iO(iT(t)?ih.TouchMove:ih.MouseMove,{positions:[r]}))}},50,{trailing:!1})).throttled,c=s.cancel,l=tx(g,document,["mousemove","touchmove"],u,{capture:!0,passive:!0}).stop,{stop:function(){l(),c()}}),tx(g,document,Object.keys(iA),function(t){var e,n=ik(t);if(nW(n,g.defaultPrivacyLevel)!==nK.HIDDEN&&it(n)){var r=ie(n),i=iA[t.type];if(i!==ip.Blur&&i!==ip.Focus){var o=iI(t);if(!o)return;e={id:r,type:i,x:o.x,y:o.y}}else e={id:r,type:i};y(Y({id:E.getIdForEvent(t)},iO(ih.MouseInteraction,e)))}},{capture:!0,passive:!0}),iN(g,y,_,document),(d=rj(g).subscribe(function(t){y(iO(ih.ViewportResize,t))}),{stop:function(){d.unsubscribe()}}),iR(g,y),tx(g,document,["play","pause"],function(t){var e=ik(t);e&&nW(e,g.defaultPrivacyLevel)!==nK.HIDDEN&&it(e)&&y(iO(ih.MediaInteraction,{id:ie(e),type:"play"===t.type?iv.Play:iv.Pause}))},{capture:!0,passive:!0}),function(t){function e(t,e){t&&it(t.ownerNode)&&e(ie(t.ownerNode))}var n=[ek(CSSStyleSheet.prototype,"insertRule",function(n){var r=n.target,i=n.parameters,o=i[0],a=i[1];e(r,function(e){return t(iO(ih.StyleSheetRule,{id:e,adds:[{rule:o,index:a}]}))})}),ek(CSSStyleSheet.prototype,"deleteRule",function(n){var r=n.target,i=n.parameters[0];e(r,function(e){return t(iO(ih.StyleSheetRule,{id:e,removes:[{index:i}]}))})})];function r(r){n.push(ek(r.prototype,"insertRule",function(n){var r=n.target,i=n.parameters,o=i[0],a=i[1];e(r.parentStyleSheet,function(e){var n=iP(r);n&&(n.push(a||0),t(iO(ih.StyleSheetRule,{id:e,adds:[{rule:o,index:n}]})))})}),ek(r.prototype,"deleteRule",function(n){var r=n.target,i=n.parameters[0];e(r.parentStyleSheet,function(e){var n=iP(r);n&&(n.push(i),t(iO(ih.StyleSheetRule,{id:e,removes:[{index:n}]})))})}))}return"undefined"!=typeof CSSGroupingRule?r(CSSGroupingRule):(r(CSSMediaRule),r(CSSSupportsRule)),{stop:function(){n.forEach(function(t){return t.stop()})}}}(y),tx(g,window,["focus","blur"],function(){y({data:{has_focus:document.hasFocus()},type:il.Focus,timestamp:t6()})}),function(t,e){var n=window.visualViewport;if(!n)return{stop:tu};var r=ts(function(){e({data:ix(n),type:il.VisualViewport,timestamp:t6()})},200,{trailing:!1}),i=r.throttled,o=r.cancel,a=tx(t,n,["resize","scroll"],i,{capture:!0,passive:!0}).stop;return{stop:function(){a(),o()}}}(g,y),(f=m.subscribe(11,function(t){var e,n;"action"===t.rawRumEvent.type&&"click"===t.rawRumEvent.action.type&&(null===(n=null===(e=t.rawRumEvent.action.frustration)||void 0===e?void 0:e.type)||void 0===n?void 0:n.length)&&"events"in t.domainContext&&t.domainContext.events&&t.domainContext.events.length&&y({timestamp:t.rawRumEvent.date,type:il.FrustrationRecord,data:{frustrationTypes:t.rawRumEvent.action.frustration.type,recordIds:t.domainContext.events.map(function(t){return E.getIdForEvent(t)})}})}),{stop:function(){f.unsubscribe()}}),(h=function(t){S(),y(t)},p=m.subscribe(4,function(){h({timestamp:t6(),type:il.ViewEnd})}),{stop:function(){p.unsubscribe()}})];return{stop:function(){b.stop(),k.forEach(function(t){return t.stop()}),w()},flushMutations:S,shadowRootsController:b}}({emit:a,configuration:e,lifeCycle:t,viewHistory:r}).stop;return s.push(d),{stop:function(){s.forEach(function(t){return t()})}}}),{startDeflateWorker:iH,createDeflateEncoder:iU});(s=(o=Q())[a="DD_RUM"])&&!s.q&&s.version&&L.warn("SDK is loaded more than once. This is unsupported and might have unexpected behavior."),o[a]=iG,s&&s.q&&s.q.forEach(function(t){return B(t,"onReady callback threw an error:")()})},88949:function(t,e,n){"use strict";function r(t,e,n){if(void 0===n&&(n=Error),!t)throw new n(e)}n.d(e,{kG:function(){return r}})},29583:function(t,e,n){"use strict";function r(t,e){var n=e&&e.cache?e.cache:u,r=e&&e.serializer?e.serializer:a;return(e&&e.strategy?e.strategy:function(t,e){var n,r,a=1===t.length?i:o;return n=e.cache.create(),r=e.serializer,a.bind(this,t,n,r)})(t,{cache:n,serializer:r})}function i(t,e,n,r){var i=null==r||"number"==typeof r||"boolean"==typeof r?r:n(r),o=e.get(i);return void 0===o&&(o=t.call(this,r),e.set(i,o)),o}function o(t,e,n){var r=Array.prototype.slice.call(arguments,3),i=n(r),o=e.get(i);return void 0===o&&(o=t.apply(this,r),e.set(i,o)),o}n.d(e,{A:function(){return c},H:function(){return r}});var a=function(){return JSON.stringify(arguments)};function s(){this.cache=Object.create(null)}s.prototype.get=function(t){return this.cache[t]},s.prototype.set=function(t,e){this.cache[t]=e};var u={create:function(){return new s}},c={variadic:function(t,e){var n,r;return n=e.cache.create(),r=e.serializer,o.bind(this,t,n,r)},monadic:function(t,e){var n,r;return n=e.cache.create(),r=e.serializer,i.bind(this,t,n,r)}}},67679:function(t,e,n){"use strict";n.d(e,{wD:function(){return s},VG:function(){return h},rp:function(){return v},Ii:function(){return S},O4:function(){return f},uf:function(){return p},Wh:function(){return w},Jo:function(){return y},yx:function(){return _},Wi:function(){return m},HI:function(){return b},pe:function(){return g},Qc:function(){return tr}});var r,i,o,a,s,u,c,l,d=n(11735);function f(t){return t.type===s.literal}function h(t){return t.type===s.argument}function p(t){return t.type===s.number}function v(t){return t.type===s.date}function g(t){return t.type===s.time}function m(t){return t.type===s.select}function y(t){return t.type===s.plural}function _(t){return t.type===s.pound}function b(t){return t.type===s.tag}function w(t){return!!(t&&"object"==typeof t&&t.type===u.number)}function S(t){return!!(t&&"object"==typeof t&&t.type===u.dateTime)}(r=a||(a={}))[r.EXPECT_ARGUMENT_CLOSING_BRACE=1]="EXPECT_ARGUMENT_CLOSING_BRACE",r[r.EMPTY_ARGUMENT=2]="EMPTY_ARGUMENT",r[r.MALFORMED_ARGUMENT=3]="MALFORMED_ARGUMENT",r[r.EXPECT_ARGUMENT_TYPE=4]="EXPECT_ARGUMENT_TYPE",r[r.INVALID_ARGUMENT_TYPE=5]="INVALID_ARGUMENT_TYPE",r[r.EXPECT_ARGUMENT_STYLE=6]="EXPECT_ARGUMENT_STYLE",r[r.INVALID_NUMBER_SKELETON=7]="INVALID_NUMBER_SKELETON",r[r.INVALID_DATE_TIME_SKELETON=8]="INVALID_DATE_TIME_SKELETON",r[r.EXPECT_NUMBER_SKELETON=9]="EXPECT_NUMBER_SKELETON",r[r.EXPECT_DATE_TIME_SKELETON=10]="EXPECT_DATE_TIME_SKELETON",r[r.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE=11]="UNCLOSED_QUOTE_IN_ARGUMENT_STYLE",r[r.EXPECT_SELECT_ARGUMENT_OPTIONS=12]="EXPECT_SELECT_ARGUMENT_OPTIONS",r[r.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE=13]="EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE=14]="INVALID_PLURAL_ARGUMENT_OFFSET_VALUE",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR=15]="EXPECT_SELECT_ARGUMENT_SELECTOR",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR=16]="EXPECT_PLURAL_ARGUMENT_SELECTOR",r[r.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT=17]="EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT",r[r.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT=18]="EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT",r[r.INVALID_PLURAL_ARGUMENT_SELECTOR=19]="INVALID_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_PLURAL_ARGUMENT_SELECTOR=20]="DUPLICATE_PLURAL_ARGUMENT_SELECTOR",r[r.DUPLICATE_SELECT_ARGUMENT_SELECTOR=21]="DUPLICATE_SELECT_ARGUMENT_SELECTOR",r[r.MISSING_OTHER_CLAUSE=22]="MISSING_OTHER_CLAUSE",r[r.INVALID_TAG=23]="INVALID_TAG",r[r.INVALID_TAG_NAME=25]="INVALID_TAG_NAME",r[r.UNMATCHED_CLOSING_TAG=26]="UNMATCHED_CLOSING_TAG",r[r.UNCLOSED_TAG=27]="UNCLOSED_TAG",(i=s||(s={}))[i.literal=0]="literal",i[i.argument=1]="argument",i[i.number=2]="number",i[i.date=3]="date",i[i.time=4]="time",i[i.select=5]="select",i[i.plural=6]="plural",i[i.pound=7]="pound",i[i.tag=8]="tag",(o=u||(u={}))[o.number=0]="number",o[o.dateTime=1]="dateTime";var E=/[ \xA0\u1680\u2000-\u200A\u202F\u205F\u3000]/,T=/(?:[Eec]{1,6}|G{1,5}|[Qq]{1,5}|(?:[yYur]+|U{1,5})|[ML]{1,5}|d{1,2}|D{1,3}|F{1}|[abB]{1,5}|[hkHK]{1,2}|w{1,2}|W{1}|m{1,2}|s{1,2}|[zZOvVxX]{1,4})(?=([^']*'[^']*')*[^']*$)/g,k=/[\t-\r \x85\u200E\u200F\u2028\u2029]/i,C=/^\.(?:(0+)(\*)?|(#+)|(0+)(#+))$/g,x=/^(@+)?(\+|#+)?[rs]?$/g,O=/(\*)(0+)|(#+)(0+)|(0+)/g,I=/^(0+)$/;function A(t){var e={};return"r"===t[t.length-1]?e.roundingPriority="morePrecision":"s"===t[t.length-1]&&(e.roundingPriority="lessPrecision"),t.replace(x,function(t,n,r){return"string"!=typeof r?(e.minimumSignificantDigits=n.length,e.maximumSignificantDigits=n.length):"+"===r?e.minimumSignificantDigits=n.length:"#"===n[0]?e.maximumSignificantDigits=n.length:(e.minimumSignificantDigits=n.length,e.maximumSignificantDigits=n.length+("string"==typeof r?r.length:0)),""}),e}function N(t){switch(t){case"sign-auto":return{signDisplay:"auto"};case"sign-accounting":case"()":return{currencySign:"accounting"};case"sign-always":case"+!":return{signDisplay:"always"};case"sign-accounting-always":case"()!":return{signDisplay:"always",currencySign:"accounting"};case"sign-except-zero":case"+?":return{signDisplay:"exceptZero"};case"sign-accounting-except-zero":case"()?":return{signDisplay:"exceptZero",currencySign:"accounting"};case"sign-never":case"+_":return{signDisplay:"never"}}}function P(t){return N(t)||{}}var R={"001":["H","h"],AC:["H","h","hb","hB"],AD:["H","hB"],AE:["h","hB","hb","H"],AF:["H","hb","hB","h"],AG:["h","hb","H","hB"],AI:["H","h","hb","hB"],AL:["h","H","hB"],AM:["H","hB"],AO:["H","hB"],AR:["H","h","hB","hb"],AS:["h","H"],AT:["H","hB"],AU:["h","hb","H","hB"],AW:["H","hB"],AX:["H"],AZ:["H","hB","h"],BA:["H","hB","h"],BB:["h","hb","H","hB"],BD:["h","hB","H"],BE:["H","hB"],BF:["H","hB"],BG:["H","hB","h"],BH:["h","hB","hb","H"],BI:["H","h"],BJ:["H","hB"],BL:["H","hB"],BM:["h","hb","H","hB"],BN:["hb","hB","h","H"],BO:["H","hB","h","hb"],BQ:["H"],BR:["H","hB"],BS:["h","hb","H","hB"],BT:["h","H"],BW:["H","h","hb","hB"],BY:["H","h"],BZ:["H","h","hb","hB"],CA:["h","hb","H","hB"],CC:["H","h","hb","hB"],CD:["hB","H"],CF:["H","h","hB"],CG:["H","hB"],CH:["H","hB","h"],CI:["H","hB"],CK:["H","h","hb","hB"],CL:["H","h","hB","hb"],CM:["H","h","hB"],CN:["H","hB","hb","h"],CO:["h","H","hB","hb"],CP:["H"],CR:["H","h","hB","hb"],CU:["H","h","hB","hb"],CV:["H","hB"],CW:["H","hB"],CX:["H","h","hb","hB"],CY:["h","H","hb","hB"],CZ:["H"],DE:["H","hB"],DG:["H","h","hb","hB"],DJ:["h","H"],DK:["H"],DM:["h","hb","H","hB"],DO:["h","H","hB","hb"],DZ:["h","hB","hb","H"],EA:["H","h","hB","hb"],EC:["H","hB","h","hb"],EE:["H","hB"],EG:["h","hB","hb","H"],EH:["h","hB","hb","H"],ER:["h","H"],ES:["H","hB","h","hb"],ET:["hB","hb","h","H"],FI:["H"],FJ:["h","hb","H","hB"],FK:["H","h","hb","hB"],FM:["h","hb","H","hB"],FO:["H","h"],FR:["H","hB"],GA:["H","hB"],GB:["H","h","hb","hB"],GD:["h","hb","H","hB"],GE:["H","hB","h"],GF:["H","hB"],GG:["H","h","hb","hB"],GH:["h","H"],GI:["H","h","hb","hB"],GL:["H","h"],GM:["h","hb","H","hB"],GN:["H","hB"],GP:["H","hB"],GQ:["H","hB","h","hb"],GR:["h","H","hb","hB"],GT:["H","h","hB","hb"],GU:["h","hb","H","hB"],GW:["H","hB"],GY:["h","hb","H","hB"],HK:["h","hB","hb","H"],HN:["H","h","hB","hb"],HR:["H","hB"],HU:["H","h"],IC:["H","h","hB","hb"],ID:["H"],IE:["H","h","hb","hB"],IL:["H","hB"],IM:["H","h","hb","hB"],IN:["h","H"],IO:["H","h","hb","hB"],IQ:["h","hB","hb","H"],IR:["hB","H"],IS:["H"],IT:["H","hB"],JE:["H","h","hb","hB"],JM:["h","hb","H","hB"],JO:["h","hB","hb","H"],JP:["H","K","h"],KE:["hB","hb","H","h"],KG:["H","h","hB","hb"],KH:["hB","h","H","hb"],KI:["h","hb","H","hB"],KM:["H","h","hB","hb"],KN:["h","hb","H","hB"],KP:["h","H","hB","hb"],KR:["h","H","hB","hb"],KW:["h","hB","hb","H"],KY:["h","hb","H","hB"],KZ:["H","hB"],LA:["H","hb","hB","h"],LB:["h","hB","hb","H"],LC:["h","hb","H","hB"],LI:["H","hB","h"],LK:["H","h","hB","hb"],LR:["h","hb","H","hB"],LS:["h","H"],LT:["H","h","hb","hB"],LU:["H","h","hB"],LV:["H","hB","hb","h"],LY:["h","hB","hb","H"],MA:["H","h","hB","hb"],MC:["H","hB"],MD:["H","hB"],ME:["H","hB","h"],MF:["H","hB"],MG:["H","h"],MH:["h","hb","H","hB"],MK:["H","h","hb","hB"],ML:["H"],MM:["hB","hb","H","h"],MN:["H","h","hb","hB"],MO:["h","hB","hb","H"],MP:["h","hb","H","hB"],MQ:["H","hB"],MR:["h","hB","hb","H"],MS:["H","h","hb","hB"],MT:["H","h"],MU:["H","h"],MV:["H","h"],MW:["h","hb","H","hB"],MX:["H","h","hB","hb"],MY:["hb","hB","h","H"],MZ:["H","hB"],NA:["h","H","hB","hb"],NC:["H","hB"],NE:["H"],NF:["H","h","hb","hB"],NG:["H","h","hb","hB"],NI:["H","h","hB","hb"],NL:["H","hB"],NO:["H","h"],NP:["H","h","hB"],NR:["H","h","hb","hB"],NU:["H","h","hb","hB"],NZ:["h","hb","H","hB"],OM:["h","hB","hb","H"],PA:["h","H","hB","hb"],PE:["H","hB","h","hb"],PF:["H","h","hB"],PG:["h","H"],PH:["h","hB","hb","H"],PK:["h","hB","H"],PL:["H","h"],PM:["H","hB"],PN:["H","h","hb","hB"],PR:["h","H","hB","hb"],PS:["h","hB","hb","H"],PT:["H","hB"],PW:["h","H"],PY:["H","h","hB","hb"],QA:["h","hB","hb","H"],RE:["H","hB"],RO:["H","hB"],RS:["H","hB","h"],RU:["H"],RW:["H","h"],SA:["h","hB","hb","H"],SB:["h","hb","H","hB"],SC:["H","h","hB"],SD:["h","hB","hb","H"],SE:["H"],SG:["h","hb","H","hB"],SH:["H","h","hb","hB"],SI:["H","hB"],SJ:["H"],SK:["H"],SL:["h","hb","H","hB"],SM:["H","h","hB"],SN:["H","h","hB"],SO:["h","H"],SR:["H","hB"],SS:["h","hb","H","hB"],ST:["H","hB"],SV:["H","h","hB","hb"],SX:["H","h","hb","hB"],SY:["h","hB","hb","H"],SZ:["h","hb","H","hB"],TA:["H","h","hb","hB"],TC:["h","hb","H","hB"],TD:["h","H","hB"],TF:["H","h","hB"],TG:["H","hB"],TH:["H","h"],TJ:["H","h"],TL:["H","hB","hb","h"],TM:["H","h"],TN:["h","hB","hb","H"],TO:["h","H"],TR:["H","hB"],TT:["h","hb","H","hB"],TW:["hB","hb","h","H"],TZ:["hB","hb","H","h"],UA:["H","hB","h"],UG:["hB","hb","H","h"],UM:["h","hb","H","hB"],US:["h","hb","H","hB"],UY:["H","h","hB","hb"],UZ:["H","hB","h"],VA:["H","h","hB"],VC:["h","hb","H","hB"],VE:["h","H","hB","hb"],VG:["h","hb","H","hB"],VI:["h","hb","H","hB"],VN:["H","h"],VU:["h","H"],WF:["H","hB"],WS:["h","H"],XK:["H","hB","h"],YE:["h","hB","hb","H"],YT:["H","hB"],ZA:["H","h","hb","hB"],ZM:["h","hb","H","hB"],ZW:["H","h"],"af-ZA":["H","h","hB","hb"],"ar-001":["h","hB","hb","H"],"ca-ES":["H","h","hB"],"en-001":["h","hb","H","hB"],"es-BO":["H","h","hB","hb"],"es-BR":["H","h","hB","hb"],"es-EC":["H","h","hB","hb"],"es-ES":["H","h","hB","hb"],"es-GQ":["H","h","hB","hb"],"es-PE":["H","h","hB","hb"],"fr-CA":["H","h","hB"],"gl-ES":["H","h","hB"],"gu-IN":["hB","hb","h","H"],"hi-IN":["hB","h","H"],"it-CH":["H","h","hB"],"it-IT":["H","h","hB"],"kn-IN":["hB","h","H"],"ml-IN":["hB","h","H"],"mr-IN":["hB","hb","h","H"],"pa-IN":["hB","hb","h","H"],"ta-IN":["hB","h","hb","H"],"te-IN":["hB","h","H"],"zu-ZA":["H","hB","hb","h"]},M=new RegExp("^".concat(E.source,"*")),L=new RegExp("".concat(E.source,"*$"));function D(t,e){return{start:t,end:e}}var U=!!String.prototype.startsWith&&"_a".startsWith("a",1),j=!!String.fromCodePoint,B=!!Object.fromEntries,H=!!String.prototype.codePointAt,F=!!String.prototype.trimStart,G=!!String.prototype.trimEnd,z=Number.isSafeInteger?Number.isSafeInteger:function(t){return"number"==typeof t&&isFinite(t)&&Math.floor(t)===t&&9007199254740991>=Math.abs(t)},V=!0;try{var K=Y("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");V=(null===(c=K.exec("a"))||void 0===c?void 0:c[0])==="a"}catch(t){V=!1}var q=U?function(t,e,n){return t.startsWith(e,n)}:function(t,e,n){return t.slice(n,n+e.length)===e},J=j?String.fromCodePoint:function(){for(var t,e=[],n=0;no;){if((t=e[o++])>1114111)throw RangeError(t+" is not a valid code point");r+=t<65536?String.fromCharCode(t):String.fromCharCode(((t-=65536)>>10)+55296,t%1024+56320)}return r},Z=B?Object.fromEntries:function(t){for(var e={},n=0;n=r)){var i=t.charCodeAt(e);return i<55296||i>56319||e+1===r||(n=t.charCodeAt(e+1))<56320||n>57343?i:(i-55296<<10)+(n-56320)+65536}},$=F?function(t){return t.trimStart()}:function(t){return t.replace(M,"")},X=G?function(t){return t.trimEnd()}:function(t){return t.replace(L,"")};function Y(t,e){return new RegExp(t,e)}if(V){var Q=Y("([^\\p{White_Space}\\p{Pattern_Syntax}]*)","yu");l=function(t,e){var n;return Q.lastIndex=e,null!==(n=Q.exec(t)[1])&&void 0!==n?n:""}}else l=function(t,e){for(var n=[];;){var r,i=W(t,e);if(void 0===i||tn(i)||(r=i)>=33&&r<=35||36===r||r>=37&&r<=39||40===r||41===r||42===r||43===r||44===r||45===r||r>=46&&r<=47||r>=58&&r<=59||r>=60&&r<=62||r>=63&&r<=64||91===r||92===r||93===r||94===r||96===r||123===r||124===r||125===r||126===r||161===r||r>=162&&r<=165||166===r||167===r||169===r||171===r||172===r||174===r||176===r||177===r||182===r||187===r||191===r||215===r||247===r||r>=8208&&r<=8213||r>=8214&&r<=8215||8216===r||8217===r||8218===r||r>=8219&&r<=8220||8221===r||8222===r||8223===r||r>=8224&&r<=8231||r>=8240&&r<=8248||8249===r||8250===r||r>=8251&&r<=8254||r>=8257&&r<=8259||8260===r||8261===r||8262===r||r>=8263&&r<=8273||8274===r||8275===r||r>=8277&&r<=8286||r>=8592&&r<=8596||r>=8597&&r<=8601||r>=8602&&r<=8603||r>=8604&&r<=8607||8608===r||r>=8609&&r<=8610||8611===r||r>=8612&&r<=8613||8614===r||r>=8615&&r<=8621||8622===r||r>=8623&&r<=8653||r>=8654&&r<=8655||r>=8656&&r<=8657||8658===r||8659===r||8660===r||r>=8661&&r<=8691||r>=8692&&r<=8959||r>=8960&&r<=8967||8968===r||8969===r||8970===r||8971===r||r>=8972&&r<=8991||r>=8992&&r<=8993||r>=8994&&r<=9e3||9001===r||9002===r||r>=9003&&r<=9083||9084===r||r>=9085&&r<=9114||r>=9115&&r<=9139||r>=9140&&r<=9179||r>=9180&&r<=9185||r>=9186&&r<=9254||r>=9255&&r<=9279||r>=9280&&r<=9290||r>=9291&&r<=9311||r>=9472&&r<=9654||9655===r||r>=9656&&r<=9664||9665===r||r>=9666&&r<=9719||r>=9720&&r<=9727||r>=9728&&r<=9838||9839===r||r>=9840&&r<=10087||10088===r||10089===r||10090===r||10091===r||10092===r||10093===r||10094===r||10095===r||10096===r||10097===r||10098===r||10099===r||10100===r||10101===r||r>=10132&&r<=10175||r>=10176&&r<=10180||10181===r||10182===r||r>=10183&&r<=10213||10214===r||10215===r||10216===r||10217===r||10218===r||10219===r||10220===r||10221===r||10222===r||10223===r||r>=10224&&r<=10239||r>=10240&&r<=10495||r>=10496&&r<=10626||10627===r||10628===r||10629===r||10630===r||10631===r||10632===r||10633===r||10634===r||10635===r||10636===r||10637===r||10638===r||10639===r||10640===r||10641===r||10642===r||10643===r||10644===r||10645===r||10646===r||10647===r||10648===r||r>=10649&&r<=10711||10712===r||10713===r||10714===r||10715===r||r>=10716&&r<=10747||10748===r||10749===r||r>=10750&&r<=11007||r>=11008&&r<=11055||r>=11056&&r<=11076||r>=11077&&r<=11078||r>=11079&&r<=11084||r>=11085&&r<=11123||r>=11124&&r<=11125||r>=11126&&r<=11157||11158===r||r>=11159&&r<=11263||r>=11776&&r<=11777||11778===r||11779===r||11780===r||11781===r||r>=11782&&r<=11784||11785===r||11786===r||11787===r||11788===r||11789===r||r>=11790&&r<=11798||11799===r||r>=11800&&r<=11801||11802===r||11803===r||11804===r||11805===r||r>=11806&&r<=11807||11808===r||11809===r||11810===r||11811===r||11812===r||11813===r||11814===r||11815===r||11816===r||11817===r||r>=11818&&r<=11822||11823===r||r>=11824&&r<=11833||r>=11834&&r<=11835||r>=11836&&r<=11839||11840===r||11841===r||11842===r||r>=11843&&r<=11855||r>=11856&&r<=11857||11858===r||r>=11859&&r<=11903||r>=12289&&r<=12291||12296===r||12297===r||12298===r||12299===r||12300===r||12301===r||12302===r||12303===r||12304===r||12305===r||r>=12306&&r<=12307||12308===r||12309===r||12310===r||12311===r||12312===r||12313===r||12314===r||12315===r||12316===r||12317===r||r>=12318&&r<=12319||12320===r||12336===r||64830===r||64831===r||r>=65093&&r<=65094)break;n.push(i),e+=i>=65536?2:1}return J.apply(void 0,n)};var tt=function(){function t(t,e){void 0===e&&(e={}),this.message=t,this.position={offset:0,line:1,column:1},this.ignoreTag=!!e.ignoreTag,this.locale=e.locale,this.requiresOtherClause=!!e.requiresOtherClause,this.shouldParseSkeletons=!!e.shouldParseSkeletons}return t.prototype.parse=function(){if(0!==this.offset())throw Error("parser can only be used once");return this.parseMessage(0,"",!1)},t.prototype.parseMessage=function(t,e,n){for(var r=[];!this.isEOF();){var i=this.char();if(123===i){var o=this.parseArgument(t,n);if(o.err)return o;r.push(o.val)}else if(125===i&&t>0)break;else if(35===i&&("plural"===e||"selectordinal"===e)){var u=this.clonePosition();this.bump(),r.push({type:s.pound,location:D(u,this.clonePosition())})}else if(60!==i||this.ignoreTag||47!==this.peek()){if(60===i&&!this.ignoreTag&&te(this.peek()||0)){var o=this.parseTag(t,e);if(o.err)return o;r.push(o.val)}else{var o=this.parseLiteral(t,e);if(o.err)return o;r.push(o.val)}}else{if(!n)return this.error(a.UNMATCHED_CLOSING_TAG,D(this.clonePosition(),this.clonePosition()));break}}return{val:r,err:null}},t.prototype.parseTag=function(t,e){var n=this.clonePosition();this.bump();var r=this.parseTagName();if(this.bumpSpace(),this.bumpIf("/>"))return{val:{type:s.literal,value:"<".concat(r,"/>"),location:D(n,this.clonePosition())},err:null};if(!this.bumpIf(">"))return this.error(a.INVALID_TAG,D(n,this.clonePosition()));var i=this.parseMessage(t+1,e,!0);if(i.err)return i;var o=i.val,u=this.clonePosition();if(!this.bumpIf(""))?{val:{type:s.tag,value:r,children:o,location:D(n,this.clonePosition())},err:null}:this.error(a.INVALID_TAG,D(u,this.clonePosition()))},t.prototype.parseTagName=function(){var t,e=this.offset();for(this.bump();!this.isEOF()&&(45===(t=this.char())||46===t||t>=48&&t<=57||95===t||t>=97&&t<=122||t>=65&&t<=90||183==t||t>=192&&t<=214||t>=216&&t<=246||t>=248&&t<=893||t>=895&&t<=8191||t>=8204&&t<=8205||t>=8255&&t<=8256||t>=8304&&t<=8591||t>=11264&&t<=12271||t>=12289&&t<=55295||t>=63744&&t<=64975||t>=65008&&t<=65533||t>=65536&&t<=983039);)this.bump();return this.message.slice(e,this.offset())},t.prototype.parseLiteral=function(t,e){for(var n=this.clonePosition(),r="";;){var i=this.tryParseQuote(e);if(i){r+=i;continue}var o=this.tryParseUnquoted(t,e);if(o){r+=o;continue}var a=this.tryParseLeftAngleBracket();if(a){r+=a;continue}break}var u=D(n,this.clonePosition());return{val:{type:s.literal,value:r,location:u},err:null}},t.prototype.tryParseLeftAngleBracket=function(){var t;return this.isEOF()||60!==this.char()||!this.ignoreTag&&(te(t=this.peek()||0)||47===t)?null:(this.bump(),"<")},t.prototype.tryParseQuote=function(t){if(this.isEOF()||39!==this.char())return null;switch(this.peek()){case 39:return this.bump(),this.bump(),"'";case 123:case 60:case 62:case 125:break;case 35:if("plural"===t||"selectordinal"===t)break;return null;default:return null}this.bump();var e=[this.char()];for(this.bump();!this.isEOF();){var n=this.char();if(39===n){if(39===this.peek())e.push(39),this.bump();else{this.bump();break}}else e.push(n);this.bump()}return J.apply(void 0,e)},t.prototype.tryParseUnquoted=function(t,e){if(this.isEOF())return null;var n=this.char();return 60===n||123===n||35===n&&("plural"===e||"selectordinal"===e)||125===n&&t>0?null:(this.bump(),J(n))},t.prototype.parseArgument=function(t,e){var n=this.clonePosition();if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(a.EXPECT_ARGUMENT_CLOSING_BRACE,D(n,this.clonePosition()));if(125===this.char())return this.bump(),this.error(a.EMPTY_ARGUMENT,D(n,this.clonePosition()));var r=this.parseIdentifierIfPossible().value;if(!r)return this.error(a.MALFORMED_ARGUMENT,D(n,this.clonePosition()));if(this.bumpSpace(),this.isEOF())return this.error(a.EXPECT_ARGUMENT_CLOSING_BRACE,D(n,this.clonePosition()));switch(this.char()){case 125:return this.bump(),{val:{type:s.argument,value:r,location:D(n,this.clonePosition())},err:null};case 44:if(this.bump(),this.bumpSpace(),this.isEOF())return this.error(a.EXPECT_ARGUMENT_CLOSING_BRACE,D(n,this.clonePosition()));return this.parseArgumentOptions(t,e,r,n);default:return this.error(a.MALFORMED_ARGUMENT,D(n,this.clonePosition()))}},t.prototype.parseIdentifierIfPossible=function(){var t=this.clonePosition(),e=this.offset(),n=l(this.message,e),r=e+n.length;return this.bumpTo(r),{value:n,location:D(t,this.clonePosition())}},t.prototype.parseArgumentOptions=function(t,e,n,r){var i,o=this.clonePosition(),c=this.parseIdentifierIfPossible().value,l=this.clonePosition();switch(c){case"":return this.error(a.EXPECT_ARGUMENT_TYPE,D(o,l));case"number":case"date":case"time":this.bumpSpace();var f=null;if(this.bumpIf(",")){this.bumpSpace();var h=this.clonePosition(),p=this.parseSimpleArgStyleIfPossible();if(p.err)return p;var v=X(p.val);if(0===v.length)return this.error(a.EXPECT_ARGUMENT_STYLE,D(this.clonePosition(),this.clonePosition()));f={style:v,styleLocation:D(h,this.clonePosition())}}var g=this.tryParseArgumentClose(r);if(g.err)return g;var m=D(r,this.clonePosition());if(f&&q(null==f?void 0:f.style,"::",0)){var y,_=$(f.style.slice(2));if("number"===c){var p=this.parseNumberSkeletonFromString(_,f.styleLocation);if(p.err)return p;return{val:{type:s.number,value:n,location:m,style:p.val},err:null}}if(0===_.length)return this.error(a.EXPECT_DATE_TIME_SKELETON,m);var b=_;this.locale&&(b=function(t,e){for(var n="",r=0;r>1),u=function(t){var e,n=t.hourCycle;if(void 0===n&&t.hourCycles&&t.hourCycles.length&&(n=t.hourCycles[0]),n)switch(n){case"h24":return"k";case"h23":return"H";case"h12":return"h";case"h11":return"K";default:throw Error("Invalid hourCycle")}var r=t.language;return"root"!==r&&(e=t.maximize().region),(R[e||""]||R[r||""]||R["".concat(r,"-001")]||R["001"])[0]}(e);for(("H"==u||"k"==u)&&(s=0);s-- >0;)n+="a";for(;a-- >0;)n=u+n}else"J"===i?n+="H":n+=i}return n}(_,this.locale));var v={type:u.dateTime,pattern:b,location:f.styleLocation,parsedOptions:this.shouldParseSkeletons?(y={},b.replace(T,function(t){var e=t.length;switch(t[0]){case"G":y.era=4===e?"long":5===e?"narrow":"short";break;case"y":y.year=2===e?"2-digit":"numeric";break;case"Y":case"u":case"U":case"r":throw RangeError("`Y/u/U/r` (year) patterns are not supported, use `y` instead");case"q":case"Q":throw RangeError("`q/Q` (quarter) patterns are not supported");case"M":case"L":y.month=["numeric","2-digit","short","long","narrow"][e-1];break;case"w":case"W":throw RangeError("`w/W` (week) patterns are not supported");case"d":y.day=["numeric","2-digit"][e-1];break;case"D":case"F":case"g":throw RangeError("`D/F/g` (day) patterns are not supported, use `d` instead");case"E":y.weekday=4===e?"long":5===e?"narrow":"short";break;case"e":if(e<4)throw RangeError("`e..eee` (weekday) patterns are not supported");y.weekday=["short","long","narrow","short"][e-4];break;case"c":if(e<4)throw RangeError("`c..ccc` (weekday) patterns are not supported");y.weekday=["short","long","narrow","short"][e-4];break;case"a":y.hour12=!0;break;case"b":case"B":throw RangeError("`b/B` (period) patterns are not supported, use `a` instead");case"h":y.hourCycle="h12",y.hour=["numeric","2-digit"][e-1];break;case"H":y.hourCycle="h23",y.hour=["numeric","2-digit"][e-1];break;case"K":y.hourCycle="h11",y.hour=["numeric","2-digit"][e-1];break;case"k":y.hourCycle="h24",y.hour=["numeric","2-digit"][e-1];break;case"j":case"J":case"C":throw RangeError("`j/J/C` (hour) patterns are not supported, use `h/H/K/k` instead");case"m":y.minute=["numeric","2-digit"][e-1];break;case"s":y.second=["numeric","2-digit"][e-1];break;case"S":case"A":throw RangeError("`S/A` (second) patterns are not supported, use `s` instead");case"z":y.timeZoneName=e<4?"short":"long";break;case"Z":case"O":case"v":case"V":case"X":case"x":throw RangeError("`Z/O/v/V/X/x` (timeZone) patterns are not supported, use `z` instead")}return""}),y):{}};return{val:{type:"date"===c?s.date:s.time,value:n,location:m,style:v},err:null}}return{val:{type:"number"===c?s.number:"date"===c?s.date:s.time,value:n,location:m,style:null!==(i=null==f?void 0:f.style)&&void 0!==i?i:null},err:null};case"plural":case"selectordinal":case"select":var w=this.clonePosition();if(this.bumpSpace(),!this.bumpIf(","))return this.error(a.EXPECT_SELECT_ARGUMENT_OPTIONS,D(w,(0,d.pi)({},w)));this.bumpSpace();var S=this.parseIdentifierIfPossible(),E=0;if("select"!==c&&"offset"===S.value){if(!this.bumpIf(":"))return this.error(a.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,D(this.clonePosition(),this.clonePosition()));this.bumpSpace();var p=this.tryParseDecimalInteger(a.EXPECT_PLURAL_ARGUMENT_OFFSET_VALUE,a.INVALID_PLURAL_ARGUMENT_OFFSET_VALUE);if(p.err)return p;this.bumpSpace(),S=this.parseIdentifierIfPossible(),E=p.val}var k=this.tryParsePluralOrSelectOptions(t,c,e,S);if(k.err)return k;var g=this.tryParseArgumentClose(r);if(g.err)return g;var C=D(r,this.clonePosition());if("select"===c)return{val:{type:s.select,value:n,options:Z(k.val),location:C},err:null};return{val:{type:s.plural,value:n,options:Z(k.val),offset:E,pluralType:"plural"===c?"cardinal":"ordinal",location:C},err:null};default:return this.error(a.INVALID_ARGUMENT_TYPE,D(o,l))}},t.prototype.tryParseArgumentClose=function(t){return this.isEOF()||125!==this.char()?this.error(a.EXPECT_ARGUMENT_CLOSING_BRACE,D(t,this.clonePosition())):(this.bump(),{val:!0,err:null})},t.prototype.parseSimpleArgStyleIfPossible=function(){for(var t=0,e=this.clonePosition();!this.isEOF();)switch(this.char()){case 39:this.bump();var n=this.clonePosition();if(!this.bumpUntil("'"))return this.error(a.UNCLOSED_QUOTE_IN_ARGUMENT_STYLE,D(n,this.clonePosition()));this.bump();break;case 123:t+=1,this.bump();break;case 125:if(!(t>0))return{val:this.message.slice(e.offset,this.offset()),err:null};t-=1;break;default:this.bump()}return{val:this.message.slice(e.offset,this.offset()),err:null}},t.prototype.parseNumberSkeletonFromString=function(t,e){var n=[];try{n=function(t){if(0===t.length)throw Error("Number skeleton cannot be empty");for(var e=t.split(k).filter(function(t){return t.length>0}),n=[],r=0;r1)throw RangeError("integer-width stems only accept a single optional option");r.options[0].replace(O,function(t,n,r,i,o,a){if(n)e.minimumIntegerDigits=r.length;else if(i&&o)throw Error("We currently do not support maximum integer digits");else if(a)throw Error("We currently do not support exact integer digits");return""});continue}if(I.test(r.stem)){e.minimumIntegerDigits=r.stem.length;continue}if(C.test(r.stem)){if(r.options.length>1)throw RangeError("Fraction-precision stems only accept a single optional option");r.stem.replace(C,function(t,n,r,i,o,a){return"*"===r?e.minimumFractionDigits=n.length:i&&"#"===i[0]?e.maximumFractionDigits=i.length:o&&a?(e.minimumFractionDigits=o.length,e.maximumFractionDigits=o.length+a.length):(e.minimumFractionDigits=n.length,e.maximumFractionDigits=n.length),""});var i=r.options[0];"w"===i?e=(0,d.pi)((0,d.pi)({},e),{trailingZeroDisplay:"stripIfInteger"}):i&&(e=(0,d.pi)((0,d.pi)({},e),A(i)));continue}if(x.test(r.stem)){e=(0,d.pi)((0,d.pi)({},e),A(r.stem));continue}var o=N(r.stem);o&&(e=(0,d.pi)((0,d.pi)({},e),o));var a=function(t){var e;if("E"===t[0]&&"E"===t[1]?(e={notation:"engineering"},t=t.slice(2)):"E"===t[0]&&(e={notation:"scientific"},t=t.slice(1)),e){var n=t.slice(0,2);if("+!"===n?(e.signDisplay="always",t=t.slice(2)):"+?"===n&&(e.signDisplay="exceptZero",t=t.slice(2)),!I.test(t))throw Error("Malformed concise eng/scientific notation");e.minimumIntegerDigits=t.length}return e}(r.stem);a&&(e=(0,d.pi)((0,d.pi)({},e),a))}return e}(n):{}},err:null}},t.prototype.tryParsePluralOrSelectOptions=function(t,e,n,r){for(var i,o=!1,s=[],u=new Set,c=r.value,l=r.location;;){if(0===c.length){var d=this.clonePosition();if("select"!==e&&this.bumpIf("=")){var f=this.tryParseDecimalInteger(a.EXPECT_PLURAL_ARGUMENT_SELECTOR,a.INVALID_PLURAL_ARGUMENT_SELECTOR);if(f.err)return f;l=D(d,this.clonePosition()),c=this.message.slice(d.offset,this.offset())}else break}if(u.has(c))return this.error("select"===e?a.DUPLICATE_SELECT_ARGUMENT_SELECTOR:a.DUPLICATE_PLURAL_ARGUMENT_SELECTOR,l);"other"===c&&(o=!0),this.bumpSpace();var h=this.clonePosition();if(!this.bumpIf("{"))return this.error("select"===e?a.EXPECT_SELECT_ARGUMENT_SELECTOR_FRAGMENT:a.EXPECT_PLURAL_ARGUMENT_SELECTOR_FRAGMENT,D(this.clonePosition(),this.clonePosition()));var p=this.parseMessage(t+1,e,n);if(p.err)return p;var v=this.tryParseArgumentClose(h);if(v.err)return v;s.push([c,{value:p.val,location:D(h,this.clonePosition())}]),u.add(c),this.bumpSpace(),c=(i=this.parseIdentifierIfPossible()).value,l=i.location}return 0===s.length?this.error("select"===e?a.EXPECT_SELECT_ARGUMENT_SELECTOR:a.EXPECT_PLURAL_ARGUMENT_SELECTOR,D(this.clonePosition(),this.clonePosition())):this.requiresOtherClause&&!o?this.error(a.MISSING_OTHER_CLAUSE,D(this.clonePosition(),this.clonePosition())):{val:s,err:null}},t.prototype.tryParseDecimalInteger=function(t,e){var n=1,r=this.clonePosition();this.bumpIf("+")||this.bumpIf("-")&&(n=-1);for(var i=!1,o=0;!this.isEOF();){var a=this.char();if(a>=48&&a<=57)i=!0,o=10*o+(a-48),this.bump();else break}var s=D(r,this.clonePosition());return i?z(o*=n)?{val:o,err:null}:this.error(e,s):this.error(t,s)},t.prototype.offset=function(){return this.position.offset},t.prototype.isEOF=function(){return this.offset()===this.message.length},t.prototype.clonePosition=function(){return{offset:this.position.offset,line:this.position.line,column:this.position.column}},t.prototype.char=function(){var t=this.position.offset;if(t>=this.message.length)throw Error("out of bound");var e=W(this.message,t);if(void 0===e)throw Error("Offset ".concat(t," is at invalid UTF-16 code unit boundary"));return e},t.prototype.error=function(t,e){return{val:null,err:{kind:t,message:this.message,location:e}}},t.prototype.bump=function(){if(!this.isEOF()){var t=this.char();10===t?(this.position.line+=1,this.position.column=1,this.position.offset+=1):(this.position.column+=1,this.position.offset+=t<65536?1:2)}},t.prototype.bumpIf=function(t){if(q(this.message,t,this.offset())){for(var e=0;e=0?(this.bumpTo(n),!0):(this.bumpTo(this.message.length),!1)},t.prototype.bumpTo=function(t){if(this.offset()>t)throw Error("targetOffset ".concat(t," must be greater than or equal to the current offset ").concat(this.offset()));for(t=Math.min(t,this.message.length);;){var e=this.offset();if(e===t)break;if(e>t)throw Error("targetOffset ".concat(t," is at invalid UTF-16 code unit boundary"));if(this.bump(),this.isEOF())break}},t.prototype.bumpSpace=function(){for(;!this.isEOF()&&tn(this.char());)this.bump()},t.prototype.peek=function(){if(this.isEOF())return null;var t=this.char(),e=this.offset(),n=this.message.charCodeAt(e+(t>=65536?2:1));return null!=n?n:null},t}();function te(t){return t>=97&&t<=122||t>=65&&t<=90}function tn(t){return t>=9&&t<=13||32===t||133===t||t>=8206&&t<=8207||8232===t||8233===t}function tr(t,e){void 0===e&&(e={});var n=new tt(t,e=(0,d.pi)({shouldParseSkeletons:!0,requiresOtherClause:!0},e)).parse();if(n.err){var r=SyntaxError(a[n.err.kind]);throw r.location=n.err.location,r.originalMessage=n.err.message,r}return(null==e?void 0:e.captureLocation)||function t(e){e.forEach(function(e){if(delete e.location,m(e)||y(e))for(var n in e.options)delete e.options[n].location,t(e.options[n].value);else p(e)&&w(e.style)?delete e.style.location:(v(e)||g(e))&&S(e.style)?delete e.style.location:b(e)&&t(e.children)})}(n.val),n.val}},36837:function(t,e,n){"use strict";n.d(e,{$6:function(){return f},OV:function(){return u},Qe:function(){return l},X9:function(){return d},gb:function(){return c},wI:function(){return s}});var r,i,o=n(11735);(r=i||(i={})).FORMAT_ERROR="FORMAT_ERROR",r.UNSUPPORTED_FORMATTER="UNSUPPORTED_FORMATTER",r.INVALID_CONFIG="INVALID_CONFIG",r.MISSING_DATA="MISSING_DATA",r.MISSING_TRANSLATION="MISSING_TRANSLATION";var a=function(t){function e(n,r,i){var o=this,a=i?i instanceof Error?i:Error(String(i)):void 0;return(o=t.call(this,"[@formatjs/intl Error ".concat(n,"] ").concat(r,"\n").concat(a?"\n".concat(a.message,"\n").concat(a.stack):""))||this).code=n,"function"==typeof Error.captureStackTrace&&Error.captureStackTrace(o,e),o}return(0,o.ZT)(e,t),e}(Error),s=function(t){function e(e,n){return t.call(this,i.UNSUPPORTED_FORMATTER,e,n)||this}return(0,o.ZT)(e,t),e}(a),u=function(t){function e(e,n){return t.call(this,i.INVALID_CONFIG,e,n)||this}return(0,o.ZT)(e,t),e}(a),c=function(t){function e(e,n){return t.call(this,i.MISSING_DATA,e,n)||this}return(0,o.ZT)(e,t),e}(a),l=function(t){function e(e,n,r){var o=t.call(this,i.FORMAT_ERROR,"".concat(e,"\nLocale: ").concat(n,"\n"),r)||this;return o.locale=n,o}return(0,o.ZT)(e,t),e}(a),d=function(t){function e(e,n,r,i){var o=t.call(this,"".concat(e,"\nMessageID: ").concat(null==r?void 0:r.id,"\nDefault Message: ").concat(null==r?void 0:r.defaultMessage,"\nDescription: ").concat(null==r?void 0:r.description,"\n"),n,i)||this;return o.descriptor=r,o.locale=n,o}return(0,o.ZT)(e,t),e}(l),f=function(t){function e(e,n){var r=t.call(this,i.MISSING_TRANSLATION,'Missing message: "'.concat(e.id,'" for locale "').concat(n,'", using ').concat(e.defaultMessage?"default message (".concat("string"==typeof e.defaultMessage?e.defaultMessage:e.defaultMessage.map(function(t){var e;return null!==(e=t.value)&&void 0!==e?e:JSON.stringify(t)}).join(),")"):"id"," as fallback."))||this;return r.descriptor=e,r}return(0,o.ZT)(e,t),e}(a)},23426:function(t,e,n){"use strict";n.d(e,{L6:function(){return s},Sn:function(){return c},TB:function(){return f},Z0:function(){return u},ax:function(){return d}});var r=n(11735),i=n(25015),o=n(29583),a=n(36837);function s(t,e,n){return void 0===n&&(n={}),e.reduce(function(e,r){return r in t?e[r]=t[r]:r in n&&(e[r]=n[r]),e},{})}var u={formats:{},messages:{},timeZone:void 0,defaultLocale:"en",defaultFormats:{},fallbackOnEmptyString:!0,onError:function(t){},onWarn:function(t){}};function c(){return{dateTime:{},number:{},message:{},relativeTime:{},pluralRules:{},list:{},displayNames:{}}}function l(t){return{create:function(){return{get:function(e){return t[e]},set:function(e,n){t[e]=n}}}}}function d(t){void 0===t&&(t=c());var e=Intl.RelativeTimeFormat,n=Intl.ListFormat,a=Intl.DisplayNames,s=(0,o.H)(function(){for(var t,e=[],n=0;n1){var t=this._logs.reduce(function(t,e){var n,r,i,a=(0,o.pi)((0,o.pi)({},e),{json:JSON.stringify(e.extras,null," "),extras:e.extras});delete a.time;var s=null!==(i=null===(r=e.time)||void 0===r?void 0:r.toISOString())&&void 0!==i?i:"";return t[s]&&(s="".concat(s,"-").concat(Math.random())),(0,o.pi)((0,o.pi)({},t),((n={})[s]=a,n))},{});console.table?console.table(t):console.log(t)}else this.logs.forEach(function(t){var e=t.level,n=t.message,r=t.extras;"info"===e||"debug"===e?console.log(n,null!=r?r:""):console[e](n,null!=r?r:"")});this._logs=[]},t}(),s=n(48710),u=function(t){var e,n,r;this.retry=null===(e=t.retry)||void 0===e||e,this.type=null!==(n=t.type)&&void 0!==n?n:"plugin Error",this.reason=null!==(r=t.reason)&&void 0!==r?r:""},c=function(){function t(t,e,n,i){void 0===e&&(e=(0,r.v4)()),void 0===n&&(n=new s.i),void 0===i&&(i=new a),this.attempts=0,this.event=t,this._id=e,this.logger=i,this.stats=n}return t.system=function(){},t.prototype.isSame=function(t){return t.id===this.id},t.prototype.cancel=function(t){if(t)throw t;throw new u({reason:"Context Cancel"})},t.prototype.log=function(t,e,n){this.logger.log(t,e,n)},Object.defineProperty(t.prototype,"id",{get:function(){return this._id},enumerable:!1,configurable:!0}),t.prototype.updateEvent=function(t,e){var n;if("integrations"===t.split(".")[0]){var r=t.split(".")[1];if((null===(n=this.event.integrations)||void 0===n?void 0:n[r])===!1)return this.event}return(0,i.N)(this.event,t,e),this.event},t.prototype.failedDelivery=function(){return this._failedDelivery},t.prototype.setFailedDelivery=function(t){this._failedDelivery=t},t.prototype.logs=function(){return this.logger.logs},t.prototype.flush=function(){this.logger.flush(),this.stats.flush()},t.prototype.toJSON=function(){return{id:this._id,event:this.event,logs:this.logger.logs,metrics:this.stats.metrics}},t}()},3518:function(t,e,n){"use strict";n.d(e,{M:function(){return o},Z:function(){return a}});var r=n(11735),i=n(52823),o="onRemoveFromFuture",a=function(t){function e(e,n,r){var i=t.call(this)||this;return i.future=[],i.maxAttempts=e,i.queue=n,i.seen=null!=r?r:{},i}return(0,r.ZT)(e,t),e.prototype.push=function(){for(var t=this,e=[],n=0;nt.maxAttempts||t.includes(e))&&(t.queue.push(e),!0)});return this.queue=this.queue.sort(function(e,n){return t.getAttempts(e)-t.getAttempts(n)}),r},e.prototype.pushWithBackoff=function(t,e){var n,r,i,a,s,u=this;if(void 0===e&&(e=0),0==e&&0===this.getAttempts(t))return this.push(t)[0];var c=this.updateAttempts(t);if(c>this.maxAttempts||this.includes(t))return!1;var l=(n={attempt:c-1},r=Math.random()+1,i=n.minTimeout,Math.min(r*(void 0===i?500:i)*Math.pow(void 0===(a=n.factor)?2:a,n.attempt),void 0===(s=n.maxTimeout)?1/0:s));return e>0&&lthis.maxListeners&&(console.warn("Event Emitter: Possible memory leak detected; ".concat(String(t)," has exceeded ").concat(this.maxListeners," listeners.")),this.warned=!0)},t.prototype.on=function(t,e){return this.callbacks[t]?(this.callbacks[t].push(e),this.warnIfPossibleMemoryLeak(t)):this.callbacks[t]=[e],this},t.prototype.once=function(t,e){var n=this,r=function(){for(var i=[],o=0;o-1?e:e+r:S(i);return{path:s,referrer:o,search:r,title:a,url:u}},k=function(){var t=document.querySelector("link[rel='canonical']");return b(location.href,t&&t.getAttribute("href")||void 0,location.search,location.pathname,document.title,document.referrer)},C=function(t,e){void 0===e&&(e=T(k()));var n,r,i,a=t.context;"page"===t.type&&(i=t.properties&&(n=t.properties,r=Object.keys(e),Object.assign.apply(Object,(0,o.ev)([{}],r.map(function(t){var e;if(n&&Object.prototype.hasOwnProperty.call(n,t))return(e={})[t]=n[t],e}),!1))),t.properties=(0,o.pi)((0,o.pi)((0,o.pi)({},e),t.properties),t.name?{name:t.name}:{})),a.page=(0,o.pi)((0,o.pi)((0,o.pi)({},e),i),a.page)},x=n(91472),O=function(t){function e(e,n){var r=t.call(this,"".concat(e," ").concat(n))||this;return r.field=e,r}return(0,o.ZT)(e,t),e}(Error),I="is not a string",A="is not an object",N=function(t){var e,n;this.settings=t,this.createMessageId=t.createMessageId,this.onEventMethodCall=null!==(e=t.onEventMethodCall)&&void 0!==e?e:function(){},this.onFinishedEvent=null!==(n=t.onFinishedEvent)&&void 0!==n?n:function(){}},P=function(t){function e(e){var n=t.call(this,{createMessageId:function(){return"ajs-next-".concat(Date.now(),"-").concat((0,_.v4)())},onEventMethodCall:function(t){var e=t.options;n.maybeUpdateAnonId(e)},onFinishedEvent:function(t){return n.addIdentity(t),t}})||this;return n.user=e,n}return(0,o.ZT)(e,t),e.prototype.maybeUpdateAnonId=function(t){(null==t?void 0:t.anonymousId)&&this.user.anonymousId(t.anonymousId)},e.prototype.addIdentity=function(t){this.user.id()&&(t.userId=this.user.id()),this.user.anonymousId()&&(t.anonymousId=this.user.anonymousId())},e.prototype.track=function(e,n,r,i,o){var a=t.prototype.track.call(this,e,n,r,i);return C(a,o),a},e.prototype.page=function(e,n,r,i,o,a){var s=t.prototype.page.call(this,e,n,r,i,o);return C(s,a),s},e.prototype.screen=function(e,n,r,i,o,a){var s=t.prototype.screen.call(this,e,n,r,i,o);return C(s,a),s},e.prototype.identify=function(e,n,r,i,o){var a=t.prototype.identify.call(this,e,n,r,i);return C(a,o),a},e.prototype.group=function(e,n,r,i,o){var a=t.prototype.group.call(this,e,n,r,i);return C(a,o),a},e.prototype.alias=function(e,n,r,i,o){var a=t.prototype.alias.call(this,e,n,r,i);return C(a,o),a},e}(function(){function t(t){this.settings=new N(t)}return t.prototype.track=function(t,e,n,r){return this.settings.onEventMethodCall({type:"track",options:n}),this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),{event:t,type:"track",properties:null!=e?e:{},options:(0,o.pi)({},n),integrations:(0,o.pi)({},r)}))},t.prototype.page=function(t,e,n,r,i){this.settings.onEventMethodCall({type:"page",options:r});var a,s={type:"page",properties:(0,o.pi)({},n),options:(0,o.pi)({},r),integrations:(0,o.pi)({},i)};return null!==t&&(s.category=t,s.properties=null!==(a=s.properties)&&void 0!==a?a:{},s.properties.category=t),null!==e&&(s.name=e),this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),s))},t.prototype.screen=function(t,e,n,r,i){this.settings.onEventMethodCall({type:"screen",options:r});var a={type:"screen",properties:(0,o.pi)({},n),options:(0,o.pi)({},r),integrations:(0,o.pi)({},i)};return null!==t&&(a.category=t),null!==e&&(a.name=e),this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),a))},t.prototype.identify=function(t,e,n,r){return this.settings.onEventMethodCall({type:"identify",options:n}),this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),{type:"identify",userId:t,traits:null!=e?e:{},options:(0,o.pi)({},n),integrations:r}))},t.prototype.group=function(t,e,n,r){return this.settings.onEventMethodCall({type:"group",options:n}),this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),{type:"group",traits:null!=e?e:{},options:(0,o.pi)({},n),integrations:(0,o.pi)({},r),groupId:t}))},t.prototype.alias=function(t,e,n,r){this.settings.onEventMethodCall({type:"alias",options:n});var i={userId:t,type:"alias",options:(0,o.pi)({},n),integrations:(0,o.pi)({},r)};return(null!==e&&(i.previousId=e),void 0===t)?this.normalize((0,o.pi)((0,o.pi)({},i),this.baseEvent())):this.normalize((0,o.pi)((0,o.pi)({},this.baseEvent()),i))},t.prototype.baseEvent=function(){return{integrations:{},options:{}}},t.prototype.context=function(t){var e,n=["userId","anonymousId","timestamp","messageId"];delete t.integrations;var r=Object.keys(t),i=null!==(e=t.context)&&void 0!==e?e:{},o={};return r.forEach(function(e){"context"!==e&&(n.includes(e)?(0,x.N)(o,e,t[e]):(0,x.N)(i,e,t[e]))}),[i,o]},t.prototype.normalize=function(t){var e,n,r,i,a=Object.keys(null!==(r=t.integrations)&&void 0!==r?r:{}).reduce(function(e,n){var r,i;return(0,o.pi)((0,o.pi)({},e),((r={})[n]=!!(null===(i=t.integrations)||void 0===i?void 0:i[n]),r))},{});t.options=(e=t.options||{},n=function(t,e){return void 0!==e},Object.keys(e).filter(function(t){return n(t,e[t])}).reduce(function(t,n){return t[n]=e[n],t},{}));var s=(0,o.pi)((0,o.pi)({},a),null===(i=t.options)||void 0===i?void 0:i.integrations),u=t.options?this.context(t.options):[],c=u[0],d=u[1],f=t.options,h=(0,o._T)(t,["options"]),p=(0,o.pi)((0,o.pi)((0,o.pi)((0,o.pi)({timestamp:new Date},h),{context:c,integrations:s}),d),{messageId:f.messageId||this.settings.createMessageId()});return this.settings.onFinishedEvent(p),function(t){if(!(0,l.Gg)(t))throw new O("Event","is nil");if("object"!=typeof t)throw new O("Event",A)}(p),function(t){if(!(0,l.HD)(t.type))throw new O(".type",I)}(p),function(t){if(!(0,l.HD)(t.messageId))throw new O(".messageId",I)}(p),"track"===p.type&&(function(t){if(!(0,l.HD)(t.event))throw new O(".event",I)}(p),function(t){if(!(0,l.PO)(t.properties))throw new O(".properties",A)}(p)),["group","identify"].includes(p.type)&&function(t){if(!(0,l.PO)(t.traits))throw new O(".traits",A)}(p),p},t}()),R=function(t){return"addMiddleware"in t&&"destination"===t.type},M=n(73380),L=n(3518),D=n(63882),U=function(){var t,e,n=0;return{done:function(){return t},run:function(r){var i=r();return"object"==typeof i&&null!==i&&"then"in i&&"function"==typeof i.then&&(1==++n&&(t=new Promise(function(t){return e=t})),i.finally(function(){return 0==--n&&e()})),i}}},j=n(54314),B=function(t){function e(e){return t.call(this,"string"==typeof e?new M.$(4,e):e)||this}return(0,o.ZT)(e,t),e.prototype.flush=function(){return(0,o.mG)(this,void 0,void 0,function(){return(0,o.Jh)(this,function(e){return(0,v.s)()?[2,[]]:[2,t.prototype.flush.call(this)]})})},e}(function(t){function e(e){var n=t.call(this)||this;return n.criticalTasks=U(),n.plugins=[],n.failedInitializations=[],n.flushing=!1,n.queue=e,n.queue.on(L.M,function(){n.scheduleFlush(0)}),n}return(0,o.ZT)(e,t),e.prototype.register=function(t,e,n){return(0,o.mG)(this,void 0,void 0,function(){var r,i,a=this;return(0,o.Jh)(this,function(o){switch(o.label){case 0:if(this.plugins.push(e),r=function(n){a.failedInitializations.push(e.name),a.emit("initialization_failure",e),console.warn(e.name,n),t.log("warn","Failed to load destination",{plugin:e.name,error:n}),a.plugins=a.plugins.filter(function(t){return t!==e})},!("destination"===e.type&&"Segment.io"!==e.name))return[3,1];return e.load(t,n).catch(r),[3,4];case 1:return o.trys.push([1,3,,4]),[4,e.load(t,n)];case 2:return o.sent(),[3,4];case 3:return i=o.sent(),r(i),[3,4];case 4:return[2]}})})},e.prototype.deregister=function(t,e,n){return(0,o.mG)(this,void 0,void 0,function(){var r;return(0,o.Jh)(this,function(i){switch(i.label){case 0:if(i.trys.push([0,3,,4]),!e.unload)return[3,2];return[4,Promise.resolve(e.unload(t,n))];case 1:i.sent(),i.label=2;case 2:return this.plugins=this.plugins.filter(function(t){return t.name!==e.name}),[3,4];case 3:return r=i.sent(),t.log("warn","Failed to unload destination",{plugin:e.name,error:r}),[3,4];case 4:return[2]}})})},e.prototype.dispatch=function(t){return(0,o.mG)(this,void 0,void 0,function(){var e;return(0,o.Jh)(this,function(n){return t.log("debug","Dispatching"),t.stats.increment("message_dispatched"),this.queue.push(t),e=this.subscribeToDelivery(t),this.scheduleFlush(0),[2,e]})})},e.prototype.subscribeToDelivery=function(t){return(0,o.mG)(this,void 0,void 0,function(){var e=this;return(0,o.Jh)(this,function(n){return[2,new Promise(function(n){var r=function(i,o){i.isSame(t)&&(e.off("flush",r),n(i))};e.on("flush",r)})]})})},e.prototype.dispatchSingle=function(t){return(0,o.mG)(this,void 0,void 0,function(){var e=this;return(0,o.Jh)(this,function(n){return t.log("debug","Dispatching"),t.stats.increment("message_dispatched"),this.queue.updateAttempts(t),t.attempts=1,[2,this.deliver(t).catch(function(n){return e.enqueuRetry(n,t)?e.subscribeToDelivery(t):(t.setFailedDelivery({reason:n}),t)})]})})},e.prototype.isEmpty=function(){return 0===this.queue.length},e.prototype.scheduleFlush=function(t){var e=this;void 0===t&&(t=500),this.flushing||(this.flushing=!0,setTimeout(function(){e.flush().then(function(){setTimeout(function(){e.flushing=!1,e.queue.length&&e.scheduleFlush(0)},0)})},t))},e.prototype.deliver=function(t){return(0,o.mG)(this,void 0,void 0,function(){var e,n,r,i;return(0,o.Jh)(this,function(o){switch(o.label){case 0:return[4,this.criticalTasks.done()];case 1:o.sent(),e=Date.now(),o.label=2;case 2:return o.trys.push([2,4,,5]),[4,this.flushOne(t)];case 3:return t=o.sent(),n=Date.now()-e,this.emit("delivery_success",t),t.stats.gauge("delivered",n),t.log("debug","Delivered",t.event),[2,t];case 4:throw i=r=o.sent(),t.log("error","Failed to deliver",i),this.emit("delivery_failure",t,i),t.stats.increment("delivery_failed"),r;case 5:return[2]}})})},e.prototype.enqueuRetry=function(t,e){return(!(t instanceof D.Y)||!!t.retry)&&this.queue.pushWithBackoff(e)},e.prototype.flush=function(){return(0,o.mG)(this,void 0,void 0,function(){var t,e;return(0,o.Jh)(this,function(n){switch(n.label){case 0:if(0===this.queue.length||!(t=this.queue.pop()))return[2,[]];t.attempts=this.queue.getAttempts(t),n.label=1;case 1:return n.trys.push([1,3,,4]),[4,this.deliver(t)];case 2:return t=n.sent(),this.emit("flush",t,!0),[3,4];case 3:return e=n.sent(),this.enqueuRetry(e,t)||(t.setFailedDelivery({reason:e}),this.emit("flush",t,!1)),[2,[]];case 4:return[2,[t]]}})})},e.prototype.isReady=function(){return!0},e.prototype.availableExtensions=function(t){var e,n,r=(e="type",n={},this.plugins.filter(function(e){if("destination"!==e.type&&"Segment.io"!==e.name)return!0;var n,r,i,o=void 0;return null===(n=e.alternativeNames)||void 0===n||n.forEach(function(e){void 0!==t[e]&&(o=t[e])}),null!==(i=null!==(r=t[e.name])&&void 0!==r?r:o)&&void 0!==i?i:!1!==("Segment.io"===e.name||t.All)}).forEach(function(t){var r,i=void 0;if("string"==typeof e){var a=t[e];i="string"!=typeof a?JSON.stringify(a):a}else e instanceof Function&&(i=e(t));void 0!==i&&(n[i]=(0,o.ev)((0,o.ev)([],null!==(r=n[i])&&void 0!==r?r:[],!0),[t],!1))}),n),i=r.before,a=r.enrichment,s=r.destination,u=r.after;return{before:void 0===i?[]:i,enrichment:void 0===a?[]:a,destinations:void 0===s?[]:s,after:void 0===u?[]:u}},e.prototype.flushOne=function(t){var e,n;return(0,o.mG)(this,void 0,void 0,function(){var r,i,a,s,u,c,l,d,f,h,p,v,g;return(0,o.Jh)(this,function(o){switch(o.label){case 0:if(!this.isReady())throw Error("Not ready");t.attempts>1&&this.emit("delivery_retry",t),i=(r=this.availableExtensions(null!==(e=t.event.integrations)&&void 0!==e?e:{})).before,a=r.enrichment,s=0,u=i,o.label=1;case 1:if(!(s0||e.length<=1)return r;for(var i=e.length-2;i>=0;--i)r.push(e.slice(i).join("."));return r}(e),r=0;r4){var o=r.slice(4);"campaign"===o&&(o="name"),t[o]=(0,tC.a)(void 0===i?"":i)}return t},{})));var v=function(){var t=J.get("_ga");if(t&&t.startsWith("amp"))return t}();v&&(d.amp={id:v}),a=(i=new z(null!==(l=t.instance.options.disableClientPersistence)&&void 0!==l&&l?[]:[new W(function(){if(r)return r;var t=Z(window.location.href);return r={expires:31536e6,secure:!1,path:"/"},t&&(r.domain=t),r}())])).get("s:context.referrer"),(s=null!==(n=function(t){var e={btid:"dataxu",urid:"millennial-media"};t.startsWith("?")&&(t=t.substring(1));for(var n=(t=t.replace(/\?/g,"&")).split("&"),r=0;r0&&!(0,v.s)()},function(){return(0,o.mG)(r,void 0,void 0,function(){var r;return(0,o.Jh)(this,function(i){switch(i.label){case 0:if(!(r=e.pop()))return[2];return[4,(0,j.a)(r,t)];case 1:return i.sent() instanceof g._||n.push(r),[2]}})})})];case 1:return i.sent(),n.map(function(t){return e.pushWithBackoff(t)}),[2,e]}})})}(n,e)];case 1:return i=a.sent(),t=!1,e.todo>0&&r(t,i,n,r),[2]}})})},5e3*Math.random())}var tB=n(21713),tH=(0,ti.R)(),tF=null!==(i=tH.__SEGMENT_INSPECTOR__)&&void 0!==i?i:tH.__SEGMENT_INSPECTOR__={},tG=function(t){var e;return null===(e=tF.attach)||void 0===e?void 0:e.call(tF,t)},tz=n(95453),tV=function(t){function e(){var e=this,r=(0,tk.d)(),i=r.promise,a=r.resolve;return(e=t.call(this,function(t){return i.then(function(e){return function(t,e,r){var i,a,l,d,f,h,p,m,y,_;return void 0===e&&(e={}),(0,o.mG)(this,void 0,void 0,function(){var b,w,S,E,T,k,C,x,O,I,A;return(0,o.Jh)(this,function(N){switch(N.label){case 0:if(!0===e.disable)return[2,[new tE,g._.system()]];if(e.globalAnalyticsKey&&(0,to.jV)(e.globalAnalyticsKey),t.cdnURL&&(0,u.UH)(t.cdnURL),e.initialPageview&&r.add(new th("page",[])),!(null!==(i=t.cdnSettings)&&void 0!==i))return[3,1];return w=i,[3,3];case 1:var P,R,D;return[4,(P=t.writeKey,D=null!=(R=t.cdnURL)?R:(0,u.Vl)(),(0,c.h)("".concat(D,"/v1/projects/").concat(P,"/settings")).then(function(t){return t.ok?t.json():t.text().then(function(t){throw Error(t)})}).catch(function(t){throw console.error(t.message),t}))];case 2:w=N.sent(),N.label=3;case 3:if(b=w,e.updateCDNSettings&&(b=e.updateCDNSettings(b)),"function"!=typeof e.disable)return[3,5];return[4,e.disable(b)];case 4:if(N.sent())return[2,[new tE,g._.system()]];N.label=5;case 5:return S=null===(l=null===(a=b.integrations["Segment.io"])||void 0===a?void 0:a.retryQueue)||void 0===l||l,e=(0,o.pi)({retryQueue:S},e),tG(E=new tS((0,o.pi)((0,o.pi)({},t),{cdnSettings:b}),e)),T=null!==(d=t.plugins)&&void 0!==d?d:[],k=null!==(f=t.classicIntegrations)&&void 0!==f?f:[],C=null===(h=e.integrations)||void 0===h?void 0:h["Segment.io"],tz.j.initRemoteMetrics((0,o.pi)((0,o.pi)({},b.metrics),{host:null!==(p=null==C?void 0:C.apiHost)&&void 0!==p?p:null===(m=b.metrics)||void 0===m?void 0:m.host,protocol:null==C?void 0:C.protocol})),[4,function(t,e,r,i,a,l,d){var f,h,p;return void 0===a&&(a=[]),(0,o.mG)(this,void 0,void 0,function(){var m,y,_,b,w,S,E,T,k,C,x,O,I,A,N=this;return(0,o.Jh)(this,function(P){var R,D,U;switch(P.label){case 0:if(tc(r,d),tu(r,d),m=null==a?void 0:a.filter(function(t){return"object"==typeof t}),y=null==a?void 0:a.filter(function(t){return"function"==typeof t&&"string"==typeof t.pluginName}),"test"===s().NODE_ENV||!((null!==(U=null===(D=null===(R=e.middlewareSettings)||void 0===R?void 0:R.routingRules)||void 0===D?void 0:D.length)&&void 0!==U?U:0)>0))return[3,2];return[4,n.e(4604).then(n.bind(n,6463)).then(function(t){return t.tsubMiddleware(e.middlewareSettings.routingRules)})];case 1:return b=P.sent(),[3,3];case 2:b=void 0,P.label=3;case 3:if(_=b,("test"===s().NODE_ENV||!(Object.keys(e.integrations).length>1))&&!(l.length>0))return[3,5];return[4,n.e(39464).then(n.bind(n,70965)).then(function(n){return n.ajsDestinations(t,e,r.integrations,i,_,l)})];case 4:return S=P.sent(),[3,6];case 5:S=[],P.label=6;case 6:if(w=S,!e.legacyVideoPluginsEnabled)return[3,8];return[4,n.e(48150).then(n.bind(n,77625)).then(function(t){return t.loadLegacyVideoPlugins(r)})];case 7:P.sent(),P.label=8;case 8:if(!(null===(f=i.plan)||void 0===f?void 0:f.track))return[3,10];return[4,n.e(37493).then(n.bind(n,69414)).then(function(t){var n;return t.schemaFilter(null===(n=i.plan)||void 0===n?void 0:n.track,e)})];case 9:return T=P.sent(),[3,11];case 10:T=void 0,P.label=11;case 11:return E=T,k=(0,tT.o)(e,i),[4,(function(t,e,n,r,i,a){var s,c,l;return(0,o.mG)(this,void 0,void 0,function(){var d,f,h=this;return(0,o.Jh)(this,function(p){switch(p.label){case 0:return d=[],f=null!==(c=null===(s=t.middlewareSettings)||void 0===s?void 0:s.routingRules)&&void 0!==c?c:[],[4,Promise.all((null!==(l=t.remotePlugins)&&void 0!==l?l:[]).map(function(t){return(0,o.mG)(h,void 0,void 0,function(){var s,c,l,h,p;return(0,o.Jh)(this,function(v){switch(v.label){case 0:var g,m;if(g=e[t.creationName],m=e[t.name],!1===e.All&&!g&&!m||!1===g||!1===m)return[2];v.label=1;case 1:if(v.trys.push([1,6,,7]),c=null==a?void 0:a.find(function(e){return e.pluginName===t.name}))return[3,3];return[4,function(t,e){return(0,o.mG)(this,void 0,void 0,function(){var n,r,i,a,s,c;return(0,o.Jh)(this,function(o){switch(o.label){case 0:if(o.trys.push([0,9,,10]),n=RegExp("https://cdn.segment.(com|build)"),r=(0,u.Vl)(),!e)return[3,6];a=(i=t.url.split("/"))[i.length-2],s=t.url.replace(a,btoa(a).replace(/=/g,"")),o.label=1;case 1:return o.trys.push([1,3,,5]),[4,(0,tI.v)(s.replace(n,r))];case 2:case 4:return o.sent(),[3,5];case 3:return o.sent(),[4,(0,tI.v)(t.url.replace(n,r))];case 5:return[3,8];case 6:return[4,(0,tI.v)(t.url.replace(n,r))];case 7:o.sent(),o.label=8;case 8:if("function"==typeof window[t.libraryName])return[2,window[t.libraryName]];return[3,10];case 9:throw c=o.sent(),console.error("Failed to create PluginFactory",t),c;case 10:return[2]}})})}(t,null==r?void 0:r.obfuscate)];case 2:c=v.sent(),v.label=3;case 3:if(!(s=c))return[3,5];return[4,s((0,o.pi)((0,o.pi)({},t.settings),n[t.name]))];case 4:(function(t){if(!Array.isArray(t))throw Error("Not a valid list of plugins");var e=["load","isLoaded","name","version","type"];t.forEach(function(t){e.forEach(function(e){var n;if(void 0===t[e])throw Error("Plugin: ".concat(null!==(n=t.name)&&void 0!==n?n:"unknown"," missing required function ").concat(e))})})})(h=Array.isArray(l=v.sent())?l:[l]),p=f.filter(function(e){return e.destinationName===t.creationName}),h.forEach(function(e){var n=new tP(t.creationName,e);p.length&&i&&n.addMiddleware(i),d.push(n)}),v.label=5;case 5:return[3,7];case 6:return console.warn("Failed to load Remote Plugin",v.sent()),[3,7];case 7:return[2]}})})}))];case 1:return p.sent(),[2,d.filter(Boolean)]}})})})(e,r.integrations,k,i,_,y).catch(function(){return[]})];case 12:if(C=P.sent(),x=(0,o.ev)((0,o.ev)([tO],w,!0),C,!0),E&&x.push(E),(null===(h=i.integrations)||void 0===h?void 0:h.All)===!1&&!i.integrations["Segment.io"]||i.integrations&&!1===i.integrations["Segment.io"])return[3,14];return I=(O=x).push,[4,function(t,e,n){window.addEventListener("pagehide",function(){l.push.apply(l,Array.from(d)),d.clear()});var r,i,a,s,u=null!==(i=null==e?void 0:e.apiKey)&&void 0!==i?i:"",l=t.options.disableClientPersistence?new L.Z(t.queue.queue.maxAttempts,[]):new M.$(t.queue.queue.maxAttempts,"".concat(u,":dest-Segment.io")),d=new Set,f=null!==(a=null==e?void 0:e.apiHost)&&void 0!==a?a:tB.U,h=null!==(s=null==e?void 0:e.protocol)&&void 0!==s?s:"https",p="".concat(h,"://").concat(f),m=null==e?void 0:e.deliveryStrategy,y=(null==m?void 0:m.strategy)==="batching"?function(t,e){var n,r,i,a=[],s=!1,u=null!==(n=null==e?void 0:e.size)&&void 0!==n?n:10,l=null!==(r=null==e?void 0:e.timeout)&&void 0!==r?r:5e3,d=0;function f(n){if(0!==n.length){var r,i=null===(r=n[0])||void 0===r?void 0:r.writeKey,a=n.map(function(t){return t.sentAt,(0,o._T)(t,["sentAt"])});return(0,c.h)("https://".concat(t,"/b"),{keepalive:(null==e?void 0:e.keepalive)||s,headers:{"Content-Type":"text/plain"},method:"post",body:JSON.stringify({writeKey:i,batch:a,sentAt:new Date().toISOString()})}).then(function(t){var e;if(t.status>=500)throw Error("Bad response from server: ".concat(t.status));if(429===t.status){var n=null===(e=t.headers)||void 0===e?void 0:e.get("x-ratelimit-reset"),r="string"==typeof n?1e3*parseInt(n):l;throw new tL("Rate limit exceeded: ".concat(t.status),r)}})}}function h(t){var n;return void 0===t&&(t=1),(0,o.mG)(this,void 0,void 0,function(){var r;return(0,o.Jh)(this,function(i){return a.length?(r=a,a=[],[2,null===(n=f(r))||void 0===n?void 0:n.catch(function(n){var i;g._.system().log("error","Error sending batch",n),t<=(null!==(i=null==e?void 0:e.maxRetries)&&void 0!==i?i:10)&&("RateLimitError"===n.name&&(d=n.retryTimeout),a.push.apply(a,r),a.map(function(e){"_metadata"in e&&(e._metadata=(0,o.pi)((0,o.pi)({},e._metadata),{retryCount:t}))}),p(t+1))})]):[2]})})}function p(t){void 0===t&&(t=1),i||(i=setTimeout(function(){i=void 0,h(t).catch(console.error)},d||l),d=0)}return tM(function(t){if((s=t)&&a.length){var e,n;Promise.all((e=[],n=0,a.forEach(function(t){tD(e[n])>=64&&n++,e[n]?e[n].push(t):e[n]=[t]}),e).map(f)).catch(console.error)}}),{dispatch:function(t,n){return(0,o.mG)(this,void 0,void 0,function(){return(0,o.Jh)(this,function(t){return a.push(n),[2,a.length>=u||tD(a)>=450||(null==e?void 0:e.keepalive)&&tD(a)>=54||s?h():p()]})})}}}(f,m.config):(r=null==m?void 0:m.config,{dispatch:function(t,e){return(0,c.h)(t,{keepalive:null==r?void 0:r.keepalive,headers:{"Content-Type":"text/plain"},method:"post",body:JSON.stringify(e)}).then(function(t){var e;if(t.status>=500)throw Error("Bad response from server: ".concat(t.status));if(429===t.status){var n=null===(e=t.headers)||void 0===e?void 0:e.get("x-ratelimit-reset"),r=n?1e3*parseInt(n):5e3;throw new tL("Rate limit exceeded: ".concat(t.status),r)}})}});function _(r){return(0,o.mG)(this,void 0,void 0,function(){var i,a;return(0,o.Jh)(this,function(s){if((0,v.s)())return l.push(r),tj(!1,l,b,tj),[2,r];if(d.add(r),i=r.event.type.charAt(0),a=(0,tR.D)(r.event).json(),"track"===r.event.type&&delete a.traits,"alias"===r.event.type){var u,c,f,h,g,m;u=a,m=t.user(),u.previousId=null!==(h=null!==(f=null!==(c=u.previousId)&&void 0!==c?c:u.from)&&void 0!==f?f:m.id())&&void 0!==h?h:m.anonymousId(),u.userId=null!==(g=u.userId)&&void 0!==g?g:u.to,delete u.from,delete u.to,a=u}return[2,y.dispatch("".concat(p,"/").concat(i),function(t,e,n,r,i){var a,s=t.user();delete e.options,e.writeKey=null==n?void 0:n.apiKey,e.userId=e.userId||s.id(),e.anonymousId=e.anonymousId||s.anonymousId(),e.sentAt=new Date;var u=t.queue.failedInitializations||[];u.length>0&&(e._metadata={failedInitializations:u}),null!=i&&(i.attempts>1&&(e._metadata=(0,o.pi)((0,o.pi)({},e._metadata),{retryCount:i.attempts})),i.attempts++);var c=[],l=[];for(var d in r){var f=r[d];"Segment.io"===d&&c.push(d),"bundled"===f.bundlingStatus&&c.push(d),"unbundled"===f.bundlingStatus&&l.push(d)}for(var h=0,p=(null==n?void 0:n.unbundledIntegrations)||[];h0){var s=!1,u=function(){s||(s=!0,a.flush().catch(d),s=!1,setTimeout(u,a.flushTimer))};u()}}return t.prototype.increment=function(t,e){if(!(!t.includes("analytics_js.")||0===e.length||Math.random()>this.sampleRate)&&!(this.queue.length>=this.maxQueueSize)){var n=l(t,e,(0,u.B)());this.queue.push(n),t.includes("error")&&this.flush().catch(d)}},t.prototype.flush=function(){return(0,i.mG)(this,void 0,void 0,function(){var t=this;return(0,i.Jh)(this,function(e){switch(e.label){case 0:if(this.queue.length<=0)return[2];return[4,this.send().catch(function(e){d(e),t.sampleRate=0})];case 1:return e.sent(),[2]}})})},t.prototype.send=function(){return(0,i.mG)(this,void 0,void 0,function(){var t,e,n;return(0,i.Jh)(this,function(r){return t={series:this.queue},this.queue=[],e={"Content-Type":"text/plain"},n="".concat(this.protocol,"://").concat(this.host,"/m"),[2,(0,a.h)(n,{headers:e,body:JSON.stringify(t),method:"POST"})]})})},t}(),h=function(t){function e(){return null!==t&&t.apply(this,arguments)||this}return(0,i.ZT)(e,t),e.initRemoteMetrics=function(t){r=new f(t)},e.prototype.increment=function(e,n,i){t.prototype.increment.call(this,e,n,i),null==r||r.increment(e,null!=i?i:[])},e}(o.s)},10518:function(t,e,n){"use strict";function r(t,e){var n=e.methodName,r=e.integrationName,i=e.type,o=e.didError;t.stats.increment("analytics_js.integration.invoke".concat(void 0!==o&&o?".error":""),1,["method:".concat(n),"integration_name:".concat(r),"type:".concat(i)])}n.d(e,{z:function(){return r}})},86461:function(t,e,n){"use strict";n.d(e,{i:function(){return r}});var r="1.73.0"},47550:function(t,e,n){"use strict";n.d(e,{h:function(){return a}});var r=n(37185),i=n.n(r),o=n(83066),a=function(){for(var t=[],e=0;eo;if(a){s.setItem(r,JSON.stringify(new Date().getTime()+50)),e(),s.removeItem(r);return}!a&&n<3?setTimeout(function(){d(t,e,n+1)},50):console.error("Unable to retrieve lock")}var f=function(t){function e(e,n){var i=t.call(this,e,[])||this,o="persisted-queue:v1:".concat(n,":items"),a="persisted-queue:v1:".concat(n,":seen"),f=[],h={};return d(n,function(){try{f=u(o),h=c(a),l(o),l(a),i.queue=(0,r.ev)((0,r.ev)([],f,!0),i.queue,!0),i.seen=(0,r.pi)((0,r.pi)({},h),i.seen)}catch(t){console.error(t)}}),window.addEventListener("pagehide",function(){if(i.todo>0){var t=(0,r.ev)((0,r.ev)([],i.queue,!0),i.future,!0);try{d(n,function(){var e,n,l,d;e=u(o),n=(0,r.ev)((0,r.ev)([],t,!0),e,!0).reduce(function(t,e){var n;return(0,r.pi)((0,r.pi)({},t),((n={})[e.id]=e,n))},{}),s.setItem(o,JSON.stringify(Object.values(n))),l=i.seen,d=c(a),s.setItem(a,JSON.stringify((0,r.pi)((0,r.pi)({},d),l)))})}catch(t){console.error(t)}}}),i}return(0,r.ZT)(e,t),e}(i.Z)},33971:function(t,e,n){"use strict";n.d(e,{D:function(){return i}});var r=n(12995);function i(t,e){var n=new r.Facade(t,e);return"track"===t.type&&(n=new r.Track(t,e)),"identify"===t.type&&(n=new r.Identify(t,e)),"page"===t.type&&(n=new r.Page(t,e)),"alias"===t.type&&(n=new r.Alias(t,e)),"group"===t.type&&(n=new r.Group(t,e)),"screen"===t.type&&(n=new r.Screen(t,e)),Object.defineProperty(n,"obj",{value:t,writable:!0}),n}},41706:function(t,e,n){"use strict";function r(){return"npm"}n.d(e,{B:function(){return r}})},10113:function(t,e,n){"use strict";n.r(e),n.d(e,{applyDestinationMiddleware:function(){return a},sourceMiddlewarePlugin:function(){return s}});var r=n(11735),i=n(63882),o=n(33971);function a(t,e,n){return(0,r.mG)(this,void 0,void 0,function(){var i,a,s,u,c;return(0,r.Jh)(this,function(l){switch(l.label){case 0:i=(0,o.D)(e,{clone:!0,traverse:!1}).rawEvent(),a=0,s=n,l.label=1;case 1:if(!(a-1&&(t.type="ios"),e.indexOf("android")>-1&&(t.type="android")),t},d.userAgent=l.proxy("context.userAgent"),d.timezone=l.proxy("context.timezone"),d.timestamp=l.field("timestamp"),d.channel=l.field("channel"),d.ip=l.proxy("context.ip"),d.userId=l.field("userId"),i.default(d)},36491:function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Group=void 0;var i=r(n(87398)),o=r(n(57791)),a=r(n(8802)),s=n(33434);function u(t,e){s.Facade.call(this,t,e)}e.Group=u,i.default(u,s.Facade);var c=u.prototype;c.action=function(){return"group"},c.type=c.action,c.groupId=s.Facade.field("groupId"),c.created=function(){var t=this.proxy("traits.createdAt")||this.proxy("traits.created")||this.proxy("properties.createdAt")||this.proxy("properties.created");if(t)return a.default(t)},c.email=function(){var t=this.proxy("traits.email");if(t)return t;var e=this.groupId();if(o.default(e))return e},c.traits=function(t){var e=this.properties(),n=this.groupId();for(var r in t=t||{},n&&(e.id=n),t)if(Object.prototype.hasOwnProperty.call(t,r)){var i=null==this[r]?this.proxy("traits."+r):this[r]();if(null==i)continue;e[t[r]]=i,delete e[r]}return e},c.name=s.Facade.proxy("traits.name"),c.industry=s.Facade.proxy("traits.industry"),c.employees=s.Facade.proxy("traits.employees"),c.properties=function(){return this.field("traits")||this.field("properties")||{}}},41173:function(t,e,n){"use strict";var r=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(e,"__esModule",{value:!0}),e.Identify=void 0;var i=n(33434),o=r(n(50154)),a=r(n(87398)),s=r(n(57791)),u=r(n(8802)),c=function(t){return t.trim()};function l(t,e){i.Facade.call(this,t,e)}e.Identify=l,a.default(l,i.Facade);var d=l.prototype;d.action=function(){return"identify"},d.type=d.action,d.traits=function(t){var e=this.field("traits")||{},n=this.userId();for(var r in t=t||{},n&&(e.id=n),t){var i=null==this[r]?this.proxy("traits."+r):this[r]();null!=i&&(e[t[r]]=i,r!==t[r]&&delete e[r])}return e},d.email=function(){var t=this.proxy("traits.email");if(t)return t;var e=this.userId();if(s.default(e))return e},d.created=function(){var t=this.proxy("traits.created")||this.proxy("traits.createdAt");if(t)return u.default(t)},d.companyCreated=function(){var t=this.proxy("traits.company.created")||this.proxy("traits.company.createdAt");if(t)return u.default(t)},d.companyName=function(){return this.proxy("traits.company.name")},d.name=function(){var t=this.proxy("traits.name");if("string"==typeof t)return c(t);var e=this.firstName(),n=this.lastName();if(e&&n)return c(e+" "+n)},d.firstName=function(){var t=this.proxy("traits.firstName");if("string"==typeof t)return c(t);var e=this.proxy("traits.name");if("string"==typeof e)return c(e).split(" ")[0]},d.lastName=function(){var t=this.proxy("traits.lastName");if("string"==typeof t)return c(t);var e=this.proxy("traits.name");if("string"==typeof e){var n=c(e).indexOf(" ");if(-1!==n)return c(e.substr(n+1))}},d.uid=function(){return this.userId()||this.username()||this.email()},d.description=function(){return this.proxy("traits.description")||this.proxy("traits.background")},d.age=function(){var t=this.birthday(),e=o.default(this.traits(),"age");return null!=e?e:t instanceof Date?new Date().getFullYear()-t.getFullYear():void 0},d.avatar=function(){var t=this.traits();return o.default(t,"avatar")||o.default(t,"photoUrl")||o.default(t,"avatarUrl")},d.position=function(){var t=this.traits();return o.default(t,"position")||o.default(t,"jobTitle")},d.username=i.Facade.proxy("traits.username"),d.website=i.Facade.one("traits.website"),d.websites=i.Facade.multi("traits.website"),d.phone=i.Facade.one("traits.phone"),d.phones=i.Facade.multi("traits.phone"),d.address=i.Facade.proxy("traits.address"),d.gender=i.Facade.proxy("traits.gender"),d.birthday=i.Facade.proxy("traits.birthday")},12995:function(t,e,n){"use strict";var r=this&&this.__assign||function(){return(r=Object.assign||function(t){for(var e,n=1,r=arguments.length;n0?e[0]:"string"==typeof t?t:t[0])}},t.__parse=i.Qc,t.formats={number:{integer:{maximumFractionDigits:0},currency:{style:"currency"},percent:{style:"percent"}},date:{short:{month:"numeric",day:"numeric",year:"2-digit"},medium:{month:"short",day:"numeric",year:"numeric"},long:{month:"long",day:"numeric",year:"numeric"},full:{weekday:"long",month:"long",day:"numeric",year:"numeric"}},time:{short:{hour:"numeric",minute:"numeric"},medium:{hour:"numeric",minute:"numeric",second:"numeric"},long:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"},full:{hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short"}}},t}()},26613:function(t,e,n){"use strict";n.d(e,{C8:function(){return s},HR:function(){return c},YR:function(){return u},jK:function(){return i},u_:function(){return a}});var r,i,o=n(11735);(r=i||(i={})).MISSING_VALUE="MISSING_VALUE",r.INVALID_VALUE="INVALID_VALUE",r.MISSING_INTL_API="MISSING_INTL_API";var a=function(t){function e(e,n,r){var i=t.call(this,e)||this;return i.code=n,i.originalMessage=r,i}return(0,o.ZT)(e,t),e.prototype.toString=function(){return"[formatjs Error: ".concat(this.code,"] ").concat(this.message)},e}(Error),s=function(t){function e(e,n,r,o){return t.call(this,'Invalid values for "'.concat(e,'": "').concat(n,'". Options are "').concat(Object.keys(r).join('", "'),'"'),i.INVALID_VALUE,o)||this}return(0,o.ZT)(e,t),e}(a),u=function(t){function e(e,n,r){return t.call(this,'Value for "'.concat(e,'" must be of type ').concat(n),i.INVALID_VALUE,r)||this}return(0,o.ZT)(e,t),e}(a),c=function(t){function e(e,n){return t.call(this,'The intl string context variable "'.concat(e,'" was not provided to the string "').concat(n,'"'),i.MISSING_VALUE,n)||this}return(0,o.ZT)(e,t),e}(a)},4167:function(t,e,n){"use strict";n.d(e,{FK:function(){return function t(e,n,r,u,c,l,d){if(1===e.length&&(0,o.O4)(e[0]))return[{type:i.literal,value:e[0].value}];for(var f=[],h=0;h1?e-1:0),r=1;r{let e={};t.forEach(t=>{if("link"===t.type&&t.props["data-optimized-fonts"]){if(document.querySelector('style[data-href="'+t.props["data-href"]+'"]'))return;t.props.href=t.props["data-href"],t.props["data-href"]=void 0}let n=e[t.type]||[];n.push(t),e[t.type]=n});let r=e.title?e.title[0]:null,i="";if(r){let{children:t}=r.props;i="string"==typeof t?t:Array.isArray(t)?t.join(""):""}i!==document.title&&(document.title=i),["meta","base","link","style","script"].forEach(t=>{n(t,e[t]||[])})}}}n=(t,e)=>{let n=document.getElementsByTagName("head")[0],r=n.querySelector("meta[name=next-head-count]"),a=Number(r.content),s=[];for(let e=0,n=r.previousElementSibling;e{for(let e=0,n=s.length;e{var e;return null==(e=t.parentNode)?void 0:e.removeChild(t)}),c.forEach(t=>n.insertBefore(t,r)),r.content=(a-s.length+c.length).toString()},("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},231:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return b}});let r=n(99920),i=n(57437),o=r._(n(2265)),a=n(98016),s=n(18029),u=n(41142),c=n(43461),l=n(844),d=n(60291),f=n(44467),h=n(53106),p=n(25944),v=n(4897),g=n(51507),m=new Set;function y(t,e,n,r,i,o){if("undefined"!=typeof window&&(o||(0,s.isLocalURL)(e))){if(!r.bypassPrefetchedCheck){let i=e+"%"+n+"%"+(void 0!==r.locale?r.locale:"locale"in t?t.locale:void 0);if(m.has(i))return;m.add(i)}(async()=>o?t.prefetch(e,i):t.prefetch(e,n,r))().catch(t=>{})}}function _(t){return"string"==typeof t?t:(0,u.formatUrl)(t)}let b=o.default.forwardRef(function(t,e){let n,r;let{href:u,as:m,children:b,prefetch:w=null,passHref:S,replace:E,shallow:T,scroll:k,locale:C,onClick:x,onMouseEnter:O,onTouchStart:I,legacyBehavior:A=!1,...N}=t;n=b,A&&("string"==typeof n||"number"==typeof n)&&(n=(0,i.jsx)("a",{children:n}));let P=o.default.useContext(d.RouterContext),R=o.default.useContext(f.AppRouterContext),M=null!=P?P:R,L=!P,D=!1!==w,U=null===w?g.PrefetchKind.AUTO:g.PrefetchKind.FULL,{href:j,as:B}=o.default.useMemo(()=>{if(!P){let t=_(u);return{href:t,as:m?_(m):t}}let[t,e]=(0,a.resolveHref)(P,u,!0);return{href:t,as:m?(0,a.resolveHref)(P,m):e||t}},[P,u,m]),H=o.default.useRef(j),F=o.default.useRef(B);A&&(r=o.default.Children.only(n));let G=A?r&&"object"==typeof r&&r.ref:e,[z,V,K]=(0,h.useIntersection)({rootMargin:"200px"}),q=o.default.useCallback(t=>{(F.current!==B||H.current!==j)&&(K(),F.current=B,H.current=j),z(t),G&&("function"==typeof G?G(t):"object"==typeof G&&(G.current=t))},[B,G,j,K,z]);o.default.useEffect(()=>{M&&V&&D&&y(M,j,B,{locale:C},{kind:U},L)},[B,j,V,C,D,null==P?void 0:P.locale,M,L,U]);let J={ref:q,onClick(t){A||"function"!=typeof x||x(t),A&&r.props&&"function"==typeof r.props.onClick&&r.props.onClick(t),M&&!t.defaultPrevented&&function(t,e,n,r,i,a,u,c,l){let{nodeName:d}=t.currentTarget;if("A"===d.toUpperCase()&&(function(t){let e=t.currentTarget.getAttribute("target");return e&&"_self"!==e||t.metaKey||t.ctrlKey||t.shiftKey||t.altKey||t.nativeEvent&&2===t.nativeEvent.which}(t)||!l&&!(0,s.isLocalURL)(n)))return;t.preventDefault();let f=()=>{let t=null==u||u;"beforePopState"in e?e[i?"replace":"push"](n,r,{shallow:a,locale:c,scroll:t}):e[i?"replace":"push"](r||n,{scroll:t})};l?o.default.startTransition(f):f()}(t,M,j,B,E,T,k,C,L)},onMouseEnter(t){A||"function"!=typeof O||O(t),A&&r.props&&"function"==typeof r.props.onMouseEnter&&r.props.onMouseEnter(t),M&&(D||!L)&&y(M,j,B,{locale:C,priority:!0,bypassPrefetchedCheck:!0},{kind:U},L)},onTouchStart:function(t){A||"function"!=typeof I||I(t),A&&r.props&&"function"==typeof r.props.onTouchStart&&r.props.onTouchStart(t),M&&(D||!L)&&y(M,j,B,{locale:C,priority:!0,bypassPrefetchedCheck:!0},{kind:U},L)}};if((0,c.isAbsoluteUrl)(B))J.href=B;else if(!A||S||"a"===r.type&&!("href"in r.props)){let t=void 0!==C?C:null==P?void 0:P.locale,e=(null==P?void 0:P.isLocaleDomain)&&(0,p.getDomainLocale)(B,t,null==P?void 0:P.locales,null==P?void 0:P.domainLocales);J.href=e||(0,v.addBasePath)((0,l.addLocale)(B,t,null==P?void 0:P.defaultLocale))}return A?o.default.cloneElement(r,J):(0,i.jsx)("a",{...N,...J,children:n})});("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},49189:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{cancelIdleCallback:function(){return r},requestIdleCallback:function(){return n}});let n="undefined"!=typeof self&&self.requestIdleCallback&&self.requestIdleCallback.bind(window)||function(t){let e=Date.now();return self.setTimeout(function(){t({didTimeout:!1,timeRemaining:function(){return Math.max(0,50-(Date.now()-e))}})},1)},r="undefined"!=typeof self&&self.cancelIdleCallback&&self.cancelIdleCallback.bind(window)||function(t){return clearTimeout(t)};("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},98016:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"resolveHref",{enumerable:!0,get:function(){return d}});let r=n(18323),i=n(41142),o=n(45519),a=n(43461),s=n(18157),u=n(18029),c=n(59195),l=n(80020);function d(t,e,n){let d;let f="string"==typeof e?e:(0,i.formatWithValidation)(e),h=f.match(/^[a-zA-Z]{1,}:\/\//),p=h?f.slice(h[0].length):f;if((p.split("?",1)[0]||"").match(/(\/\/|\\)/)){console.error("Invalid href '"+f+"' passed to next/router in page: '"+t.pathname+"'. Repeated forward-slashes (//) or backslashes \\ are not valid in the href.");let e=(0,a.normalizeRepeatedSlashes)(p);f=(h?h[0]:"")+e}if(!(0,u.isLocalURL)(f))return n?[f]:f;try{d=new URL(f.startsWith("#")?t.asPath:t.pathname,"http://n")}catch(t){d=new URL("/","http://n")}try{let t=new URL(f,d);t.pathname=(0,s.normalizePathTrailingSlash)(t.pathname);let e="";if((0,c.isDynamicRoute)(t.pathname)&&t.searchParams&&n){let n=(0,r.searchParamsToUrlQuery)(t.searchParams),{result:a,params:s}=(0,l.interpolateAs)(t.pathname,t.pathname,n);a&&(e=(0,i.formatWithValidation)({pathname:a,hash:t.hash,query:(0,o.omit)(n,s)}))}let a=t.origin===d.origin?t.href.slice(t.origin.length):t.href;return n?[a,e||a]:a}catch(t){return n?[f]:f}}("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},84080:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{default:function(){return _},handleClientScriptLoad:function(){return g},initScriptLoader:function(){return m}});let r=n(99920),i=n(41452),o=n(57437),a=r._(n(54887)),s=i._(n(2265)),u=n(36590),c=n(40905),l=n(49189),d=new Map,f=new Set,h=["onLoad","onReady","dangerouslySetInnerHTML","children","onError","strategy","stylesheets"],p=t=>{if(a.default.preinit){t.forEach(t=>{a.default.preinit(t,{as:"style"})});return}if("undefined"!=typeof window){let e=document.head;t.forEach(t=>{let n=document.createElement("link");n.type="text/css",n.rel="stylesheet",n.href=t,e.appendChild(n)})}},v=t=>{let{src:e,id:n,onLoad:r=()=>{},onReady:i=null,dangerouslySetInnerHTML:o,children:a="",strategy:s="afterInteractive",onError:u,stylesheets:l}=t,v=n||e;if(v&&f.has(v))return;if(d.has(e)){f.add(v),d.get(e).then(r,u);return}let g=()=>{i&&i(),f.add(v)},m=document.createElement("script"),y=new Promise((t,e)=>{m.addEventListener("load",function(e){t(),r&&r.call(this,e),g()}),m.addEventListener("error",function(t){e(t)})}).catch(function(t){u&&u(t)});for(let[n,r]of(o?(m.innerHTML=o.__html||"",g()):a?(m.textContent="string"==typeof a?a:Array.isArray(a)?a.join(""):"",g()):e&&(m.src=e,d.set(e,y)),Object.entries(t))){if(void 0===r||h.includes(n))continue;let t=c.DOMAttributeNames[n]||n.toLowerCase();m.setAttribute(t,r)}"worker"===s&&m.setAttribute("type","text/partytown"),m.setAttribute("data-nscript",s),l&&p(l),document.body.appendChild(m)};function g(t){let{strategy:e="afterInteractive"}=t;"lazyOnload"===e?window.addEventListener("load",()=>{(0,l.requestIdleCallback)(()=>v(t))}):v(t)}function m(t){t.forEach(g),[...document.querySelectorAll('[data-nscript="beforeInteractive"]'),...document.querySelectorAll('[data-nscript="beforePageRender"]')].forEach(t=>{let e=t.id||t.getAttribute("src");f.add(e)})}function y(t){let{id:e,src:n="",onLoad:r=()=>{},onReady:i=null,strategy:c="afterInteractive",onError:d,stylesheets:h,...p}=t,{updateScripts:g,scripts:m,getIsSsr:y,appDir:_,nonce:b}=(0,s.useContext)(u.HeadManagerContext),w=(0,s.useRef)(!1);(0,s.useEffect)(()=>{let t=e||n;w.current||(i&&t&&f.has(t)&&i(),w.current=!0)},[i,e,n]);let S=(0,s.useRef)(!1);if((0,s.useEffect)(()=>{!S.current&&("afterInteractive"===c?v(t):"lazyOnload"===c&&("complete"===document.readyState?(0,l.requestIdleCallback)(()=>v(t)):window.addEventListener("load",()=>{(0,l.requestIdleCallback)(()=>v(t))})),S.current=!0)},[t,c]),("beforeInteractive"===c||"worker"===c)&&(g?(m[c]=(m[c]||[]).concat([{id:e,src:n,onLoad:r,onReady:i,onError:d,...p}]),g(m)):y&&y()?f.add(e||n):y&&!y()&&v(t)),_){if(h&&h.forEach(t=>{a.default.preinit(t,{as:"style"})}),"beforeInteractive"===c)return n?(a.default.preload(n,p.integrity?{as:"script",integrity:p.integrity,nonce:b,crossOrigin:p.crossOrigin}:{as:"script",nonce:b,crossOrigin:p.crossOrigin}),(0,o.jsx)("script",{nonce:b,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([n,{...p,id:e}])+")"}})):(p.dangerouslySetInnerHTML&&(p.children=p.dangerouslySetInnerHTML.__html,delete p.dangerouslySetInnerHTML),(0,o.jsx)("script",{nonce:b,dangerouslySetInnerHTML:{__html:"(self.__next_s=self.__next_s||[]).push("+JSON.stringify([0,{...p,id:e}])+")"}}));"afterInteractive"===c&&n&&a.default.preload(n,p.integrity?{as:"script",integrity:p.integrity,nonce:b,crossOrigin:p.crossOrigin}:{as:"script",nonce:b,crossOrigin:p.crossOrigin})}return null}Object.defineProperty(y,"__nextScript",{value:!0});let _=y;("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},53106:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"useIntersection",{enumerable:!0,get:function(){return u}});let r=n(2265),i=n(49189),o="function"==typeof IntersectionObserver,a=new Map,s=[];function u(t){let{rootRef:e,rootMargin:n,disabled:u}=t,c=u||!o,[l,d]=(0,r.useState)(!1),f=(0,r.useRef)(null),h=(0,r.useCallback)(t=>{f.current=t},[]);return(0,r.useEffect)(()=>{if(o){if(c||l)return;let t=f.current;if(t&&t.tagName)return function(t,e,n){let{id:r,observer:i,elements:o}=function(t){let e;let n={root:t.root||null,margin:t.rootMargin||""},r=s.find(t=>t.root===n.root&&t.margin===n.margin);if(r&&(e=a.get(r)))return e;let i=new Map;return e={id:n,observer:new IntersectionObserver(t=>{t.forEach(t=>{let e=i.get(t.target),n=t.isIntersecting||t.intersectionRatio>0;e&&n&&e(n)})},t),elements:i},s.push(n),a.set(n,e),e}(n);return o.set(t,e),i.observe(t),function(){if(o.delete(t),i.unobserve(t),0===o.size){i.disconnect(),a.delete(r);let t=s.findIndex(t=>t.root===r.root&&t.margin===r.margin);t>-1&&s.splice(t,1)}}}(t,t=>t&&d(t),{root:null==e?void 0:e.current,rootMargin:n})}else if(!l){let t=(0,i.requestIdleCallback)(()=>d(!0));return()=>(0,i.cancelIdleCallback)(t)}},[c,n,e,l,f.current]),[h,l,(0,r.useCallback)(()=>{d(!1)},[])]}("function"==typeof e.default||"object"==typeof e.default&&null!==e.default)&&void 0===e.default.__esModule&&(Object.defineProperty(e.default,"__esModule",{value:!0}),Object.assign(e.default,e),t.exports=e.default)},81943:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"escapeStringRegexp",{enumerable:!0,get:function(){return i}});let n=/[|\\{}()[\]^$+*?.-]/,r=/[|\\{}()[\]^$+*?.-]/g;function i(t){return n.test(t)?t.replace(r,"\\$&"):t}},60291:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"RouterContext",{enumerable:!0,get:function(){return r}});let r=n(99920)._(n(2265)).default.createContext(null)},41142:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{formatUrl:function(){return o},formatWithValidation:function(){return s},urlObjectKeys:function(){return a}});let r=n(41452)._(n(18323)),i=/https?|ftp|gopher|file/;function o(t){let{auth:e,hostname:n}=t,o=t.protocol||"",a=t.pathname||"",s=t.hash||"",u=t.query||"",c=!1;e=e?encodeURIComponent(e).replace(/%3A/i,":")+"@":"",t.host?c=e+t.host:n&&(c=e+(~n.indexOf(":")?"["+n+"]":n),t.port&&(c+=":"+t.port)),u&&"object"==typeof u&&(u=String(r.urlQueryToSearchParams(u)));let l=t.search||u&&"?"+u||"";return o&&!o.endsWith(":")&&(o+=":"),t.slashes||(!o||i.test(o))&&!1!==c?(c="//"+(c||""),a&&"/"!==a[0]&&(a="/"+a)):c||(c=""),s&&"#"!==s[0]&&(s="#"+s),l&&"?"!==l[0]&&(l="?"+l),""+o+c+(a=a.replace(/[?#]/g,encodeURIComponent))+(l=l.replace("#","%23"))+s}let a=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function s(t){return o(t)}},59195:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{getSortedRoutes:function(){return r.getSortedRoutes},isDynamicRoute:function(){return i.isDynamicRoute}});let r=n(49089),i=n(28083)},80020:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"interpolateAs",{enumerable:!0,get:function(){return o}});let r=n(41533),i=n(63169);function o(t,e,n){let o="",a=(0,i.getRouteRegex)(t),s=a.groups,u=(e!==t?(0,r.getRouteMatcher)(a)(e):"")||n;o=t;let c=Object.keys(s);return c.every(t=>{let e=u[t]||"",{repeat:n,optional:r}=s[t],i="["+(n?"...":"")+t+"]";return r&&(i=(e?"":"/")+"["+i+"]"),n&&!Array.isArray(e)&&(e=[e]),(r||t in u)&&(o=o.replace(i,n?e.map(t=>encodeURIComponent(t)).join("/"):encodeURIComponent(e))||"/")})||(o=""),{params:c,result:o}}},28083:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isDynamicRoute",{enumerable:!0,get:function(){return o}});let r=n(82269),i=/\/\[[^/]+?\](?=\/|$)/;function o(t){return(0,r.isInterceptionRouteAppPath)(t)&&(t=(0,r.extractInterceptionRouteInformation)(t).interceptedRoute),i.test(t)}},18029:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"isLocalURL",{enumerable:!0,get:function(){return o}});let r=n(43461),i=n(49404);function o(t){if(!(0,r.isAbsoluteUrl)(t))return!0;try{let e=(0,r.getLocationOrigin)(),n=new URL(t,e);return n.origin===e&&(0,i.hasBasePath)(n.pathname)}catch(t){return!1}}},45519:function(t,e){"use strict";function n(t,e){let n={};return Object.keys(t).forEach(r=>{e.includes(r)||(n[r]=t[r])}),n}Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"omit",{enumerable:!0,get:function(){return n}})},18323:function(t,e){"use strict";function n(t){let e={};return t.forEach((t,n)=>{void 0===e[n]?e[n]=t:Array.isArray(e[n])?e[n].push(t):e[n]=[e[n],t]}),e}function r(t){return"string"!=typeof t&&("number"!=typeof t||isNaN(t))&&"boolean"!=typeof t?"":String(t)}function i(t){let e=new URLSearchParams;return Object.entries(t).forEach(t=>{let[n,i]=t;Array.isArray(i)?i.forEach(t=>e.append(n,r(t))):e.set(n,r(i))}),e}function o(t){for(var e=arguments.length,n=Array(e>1?e-1:0),r=1;r{Array.from(e.keys()).forEach(e=>t.delete(e)),e.forEach((e,n)=>t.append(n,e))}),t}Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{assign:function(){return o},searchParamsToUrlQuery:function(){return n},urlQueryToSearchParams:function(){return i}})},41533:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getRouteMatcher",{enumerable:!0,get:function(){return i}});let r=n(43461);function i(t){let{re:e,groups:n}=t;return t=>{let i=e.exec(t);if(!i)return!1;let o=t=>{try{return decodeURIComponent(t)}catch(t){throw new r.DecodeError("failed to decode param")}},a={};return Object.keys(n).forEach(t=>{let e=n[t],r=i[e.pos];void 0!==r&&(a[t]=~r.indexOf("/")?r.split("/").map(t=>o(t)):e.repeat?[o(r)]:o(r))}),a}}},63169:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{getNamedMiddlewareRegex:function(){return f},getNamedRouteRegex:function(){return d},getRouteRegex:function(){return u}});let r=n(82269),i=n(81943),o=n(67741);function a(t){let e=t.startsWith("[")&&t.endsWith("]");e&&(t=t.slice(1,-1));let n=t.startsWith("...");return n&&(t=t.slice(3)),{key:t,repeat:n,optional:e}}function s(t){let e=(0,o.removeTrailingSlash)(t).slice(1).split("/"),n={},s=1;return{parameterizedRoute:e.map(t=>{let e=r.INTERCEPTION_ROUTE_MARKERS.find(e=>t.startsWith(e)),o=t.match(/\[((?:\[.*\])|.+)\]/);if(e&&o){let{key:t,optional:r,repeat:u}=a(o[1]);return n[t]={pos:s++,repeat:u,optional:r},"/"+(0,i.escapeStringRegexp)(e)+"([^/]+?)"}if(!o)return"/"+(0,i.escapeStringRegexp)(t);{let{key:t,repeat:e,optional:r}=a(o[1]);return n[t]={pos:s++,repeat:e,optional:r},e?r?"(?:/(.+?))?":"/(.+?)":"/([^/]+?)"}}).join(""),groups:n}}function u(t){let{parameterizedRoute:e,groups:n}=s(t);return{re:RegExp("^"+e+"(?:/)?$"),groups:n}}function c(t){let{interceptionMarker:e,getSafeRouteKey:n,segment:r,routeKeys:o,keyPrefix:s}=t,{key:u,optional:c,repeat:l}=a(r),d=u.replace(/\W/g,"");s&&(d=""+s+d);let f=!1;(0===d.length||d.length>30)&&(f=!0),isNaN(parseInt(d.slice(0,1)))||(f=!0),f&&(d=n()),s?o[d]=""+s+u:o[d]=u;let h=e?(0,i.escapeStringRegexp)(e):"";return l?c?"(?:/"+h+"(?<"+d+">.+?))?":"/"+h+"(?<"+d+">.+?)":"/"+h+"(?<"+d+">[^/]+?)"}function l(t,e){let n;let a=(0,o.removeTrailingSlash)(t).slice(1).split("/"),s=(n=0,()=>{let t="",e=++n;for(;e>0;)t+=String.fromCharCode(97+(e-1)%26),e=Math.floor((e-1)/26);return t}),u={};return{namedParameterizedRoute:a.map(t=>{let n=r.INTERCEPTION_ROUTE_MARKERS.some(e=>t.startsWith(e)),o=t.match(/\[((?:\[.*\])|.+)\]/);if(n&&o){let[n]=t.split(o[0]);return c({getSafeRouteKey:s,interceptionMarker:n,segment:o[1],routeKeys:u,keyPrefix:e?"nxtI":void 0})}return o?c({getSafeRouteKey:s,segment:o[1],routeKeys:u,keyPrefix:e?"nxtP":void 0}):"/"+(0,i.escapeStringRegexp)(t)}).join(""),routeKeys:u}}function d(t,e){let n=l(t,e);return{...u(t),namedRegex:"^"+n.namedParameterizedRoute+"(?:/)?$",routeKeys:n.routeKeys}}function f(t,e){let{parameterizedRoute:n}=s(t),{catchAll:r=!0}=e;if("/"===n)return{namedRegex:"^/"+(r?".*":"")+"$"};let{namedParameterizedRoute:i}=l(t,!1);return{namedRegex:"^"+i+(r?"(?:(/.*)?)":"")+"$"}}},49089:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"getSortedRoutes",{enumerable:!0,get:function(){return r}});class n{insert(t){this._insert(t.split("/").filter(Boolean),[],!1)}smoosh(){return this._smoosh()}_smoosh(t){void 0===t&&(t="/");let e=[...this.children.keys()].sort();null!==this.slugName&&e.splice(e.indexOf("[]"),1),null!==this.restSlugName&&e.splice(e.indexOf("[...]"),1),null!==this.optionalRestSlugName&&e.splice(e.indexOf("[[...]]"),1);let n=e.map(e=>this.children.get(e)._smoosh(""+t+e+"/")).reduce((t,e)=>[...t,...e],[]);if(null!==this.slugName&&n.push(...this.children.get("[]")._smoosh(t+"["+this.slugName+"]/")),!this.placeholder){let e="/"===t?"/":t.slice(0,-1);if(null!=this.optionalRestSlugName)throw Error('You cannot define a route with the same specificity as a optional catch-all route ("'+e+'" and "'+e+"[[..."+this.optionalRestSlugName+']]").');n.unshift(e)}return null!==this.restSlugName&&n.push(...this.children.get("[...]")._smoosh(t+"[..."+this.restSlugName+"]/")),null!==this.optionalRestSlugName&&n.push(...this.children.get("[[...]]")._smoosh(t+"[[..."+this.optionalRestSlugName+"]]/")),n}_insert(t,e,r){if(0===t.length){this.placeholder=!1;return}if(r)throw Error("Catch-all must be the last part of the URL.");let i=t[0];if(i.startsWith("[")&&i.endsWith("]")){let n=i.slice(1,-1),a=!1;if(n.startsWith("[")&&n.endsWith("]")&&(n=n.slice(1,-1),a=!0),n.startsWith("...")&&(n=n.substring(3),r=!0),n.startsWith("[")||n.endsWith("]"))throw Error("Segment names may not start or end with extra brackets ('"+n+"').");if(n.startsWith("."))throw Error("Segment names may not start with erroneous periods ('"+n+"').");function o(t,n){if(null!==t&&t!==n)throw Error("You cannot use different slug names for the same dynamic path ('"+t+"' !== '"+n+"').");e.forEach(t=>{if(t===n)throw Error('You cannot have the same slug name "'+n+'" repeat within a single dynamic path');if(t.replace(/\W/g,"")===i.replace(/\W/g,""))throw Error('You cannot have the slug names "'+t+'" and "'+n+'" differ only by non-word symbols within a single dynamic path')}),e.push(n)}if(r){if(a){if(null!=this.restSlugName)throw Error('You cannot use both an required and optional catch-all route at the same level ("[...'+this.restSlugName+']" and "'+t[0]+'" ).');o(this.optionalRestSlugName,n),this.optionalRestSlugName=n,i="[[...]]"}else{if(null!=this.optionalRestSlugName)throw Error('You cannot use both an optional and required catch-all route at the same level ("[[...'+this.optionalRestSlugName+']]" and "'+t[0]+'").');o(this.restSlugName,n),this.restSlugName=n,i="[...]"}}else{if(a)throw Error('Optional route parameters are not yet supported ("'+t[0]+'").');o(this.slugName,n),this.slugName=n,i="[]"}}this.children.has(i)||this.children.set(i,new n),this.children.get(i)._insert(t.slice(1),e,r)}constructor(){this.placeholder=!0,this.children=new Map,this.slugName=null,this.restSlugName=null,this.optionalRestSlugName=null}}function r(t){let e=new n;return t.forEach(t=>e.insert(t)),e.smoosh()}},43461:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),function(t,e){for(var n in e)Object.defineProperty(t,n,{enumerable:!0,get:e[n]})}(e,{DecodeError:function(){return p},MiddlewareNotFoundError:function(){return y},MissingStaticPage:function(){return m},NormalizeError:function(){return v},PageNotFoundError:function(){return g},SP:function(){return f},ST:function(){return h},WEB_VITALS:function(){return n},execOnce:function(){return r},getDisplayName:function(){return u},getLocationOrigin:function(){return a},getURL:function(){return s},isAbsoluteUrl:function(){return o},isResSent:function(){return c},loadGetInitialProps:function(){return d},normalizeRepeatedSlashes:function(){return l},stringifyError:function(){return _}});let n=["CLS","FCP","FID","INP","LCP","TTFB"];function r(t){let e,n=!1;return function(){for(var r=arguments.length,i=Array(r),o=0;oi.test(t);function a(){let{protocol:t,hostname:e,port:n}=window.location;return t+"//"+e+(n?":"+n:"")}function s(){let{href:t}=window.location,e=a();return t.substring(e.length)}function u(t){return"string"==typeof t?t:t.displayName||t.name||"Unknown"}function c(t){return t.finished||t.headersSent}function l(t){let e=t.split("?");return e[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(e[1]?"?"+e.slice(1).join("?"):"")}async function d(t,e){let n=e.res||e.ctx&&e.ctx.res;if(!t.getInitialProps)return e.ctx&&e.Component?{pageProps:await d(e.Component,e.ctx)}:{};let r=await t.getInitialProps(e);if(n&&c(n))return r;if(!r)throw Error('"'+u(t)+'.getInitialProps()" should resolve to an object. But found "'+r+'" instead.');return r}let f="undefined"!=typeof performance,h=f&&["mark","measure","getEntriesByName"].every(t=>"function"==typeof performance[t]);class p extends Error{}class v extends Error{}class g extends Error{constructor(t){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message="Cannot find module for page: "+t}}class m extends Error{constructor(t,e){super(),this.message="Failed to load static file for page: "+t+" "+e}}class y extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function _(t){return JSON.stringify({message:t.message,stack:t.stack})}},50154:function(t){function e(t){return function(e,n,r,o){var a,s=o&&"function"==typeof o.normalizer?o.normalizer:i;n=s(n);for(var u=!1;!u;)!function(){for(a in e){var t=s(a);if(0===n.indexOf(t)){var r=n.substr(t.length);if("."===r.charAt(0)||0===r.length){n=r.substr(1);var i=e[a];if(null==i||!n.length){u=!0;return}e=i;return}}}a=void 0,u=!0}();if(a)return null==e?e:t(e,a,r)}}function n(t,e){return t.hasOwnProperty(e)&&delete t[e],t}function r(t,e,n){return t.hasOwnProperty(e)&&(t[e]=n),t}function i(t){return t.replace(/[^a-zA-Z0-9\.]+/g,"").toLowerCase()}t.exports=e(function(t,e){if(t.hasOwnProperty(e))return t[e]}),t.exports.find=t.exports,t.exports.replace=function(t,n,i,o){return e(r).call(this,t,n,i,o),t},t.exports.del=function(t,r,i){return e(n).call(this,t,r,null,i),t}},14186:function(t,e,n){"use strict";n.d(e,{ag:function(){return m},yX:function(){return g},BK:function(){return v},Em:function(){return p},vU:function(){return h}});var r,i,o,a,s=n(11735),u=n(2265),c=n(97496);(r=o||(o={})).formatDate="FormattedDate",r.formatTime="FormattedTime",r.formatNumber="FormattedNumber",r.formatList="FormattedList",r.formatDisplayName="FormattedDisplayName",(i=a||(a={})).formatDate="FormattedDateParts",i.formatTime="FormattedTimeParts",i.formatNumber="FormattedNumberParts",i.formatList="FormattedListParts";var l=function(t){var e=(0,c.Z)(),n=t.value,r=t.children,i=(0,s._T)(t,["value","children"]);return r(e.formatNumberToParts(n,i))};function d(t){var e=function(e){var n=(0,c.Z)(),r=e.value,i=e.children,o=(0,s._T)(e,["value","children"]),a="string"==typeof r?new Date(r||0):r;return i("formatDate"===t?n.formatDateToParts(a,o):n.formatTimeToParts(a,o))};return e.displayName=a[t],e}function f(t){var e=function(e){var n=(0,c.Z)(),r=e.value,i=e.children,o=(0,s._T)(e,["value","children"]),a=n[t](r,o);if("function"==typeof i)return i(a);var l=n.textComponent||u.Fragment;return u.createElement(l,null,a)};return e.displayName=o[t],e}function h(t){return t}function p(t){return t}l.displayName="FormattedNumberParts",l.displayName="FormattedNumberParts",f("formatDate"),f("formatTime");var v=f("formatNumber"),g=f("formatList"),m=f("formatDisplayName");d("formatDate"),d("formatTime")},22001:function(t,e,n){"use strict";n.d(e,{_y:function(){return a},zt:function(){return o}});var r=n(2265);n(46451);var i="undefined"==typeof window||window.__REACT_INTL_BYPASS_GLOBAL_CONTEXT__?r.createContext(null):window.__REACT_INTL_CONTEXT__||(window.__REACT_INTL_CONTEXT__=r.createContext(null));i.Consumer;var o=i.Provider,a=i},106:function(t,e,n){"use strict";var r=n(11735),i=n(2265),o=n(97496),a=n(17664);function s(t){var e=(0,o.Z)(),n=e.formatMessage,r=e.textComponent,a=void 0===r?i.Fragment:r,s=t.id,u=t.description,c=t.defaultMessage,l=t.values,d=t.children,f=t.tagName,h=void 0===f?a:f,p=n({id:s,description:u,defaultMessage:c},l,{ignoreTag:t.ignoreTag});return"function"==typeof d?d(Array.isArray(p)?p:[p]):h?i.createElement(h,null,i.Children.toArray(p)):i.createElement(i.Fragment,null,p)}s.displayName="FormattedMessage";var u=i.memo(s,function(t,e){var n=t.values,i=(0,r._T)(t,["values"]),o=e.values,s=(0,r._T)(e,["values"]);return(0,a.wU)(o,n)&&(0,a.wU)(i,s)});u.displayName="MemoizedFormattedMessage",e.Z=u},97496:function(t,e,n){"use strict";n.d(e,{Z:function(){return a}});var r=n(2265),i=n(17664),o=n(22001);function a(){var t=r.useContext(o._y);return(0,i.lq)(t),t}},17664:function(t,e,n){"use strict";n.d(e,{Z0:function(){return u},dt:function(){return c},lq:function(){return s},wU:function(){return l}});var r=n(11735),i=n(2265),o=n(88949),a=n(23426);function s(t){(0,o.kG)(t,"[React Intl] Could not find required `intl` object. needs to exist in the component ancestry.")}var u=(0,r.pi)((0,r.pi)({},a.Z0),{textComponent:i.Fragment});function c(t){return function(e){return t(i.Children.toArray(e))}}function l(t,e){if(t===e)return!0;if(!t||!e)return!1;var n=Object.keys(t),r=Object.keys(e),i=n.length;if(r.length!==i)return!1;for(var o=0;o1)for(var n=1;n__STATSIG__||l,e._getStatsigGlobalFlag=t=>(0,e._getStatsigGlobal)()[t],e._getInstance=t=>{let n=(0,e._getStatsigGlobal)();return t?n.instances&&n.instances[t]:n.lastInstance};let a="__STATSIG__",s="undefined"!=typeof window?window:{},u=void 0!==n.g?n.g:{},c="undefined"!=typeof globalThis?globalThis:{},l=null!==(o=null!==(i=null!==(r=s[a])&&void 0!==r?r:u[a])&&void 0!==i?i:c[a])&&void 0!==o?o:{instance:e._getInstance};s[a]=l,u[a]=l,c[a]=l},90855:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._getStorageKey=e._getUserStorageKey=void 0;let r=n(22035);function i(t,e,n){var i;if(n)return n(t,e);let o=e&&e.customIDs?e.customIDs:{},a=[`uid:${null!==(i=null==e?void 0:e.userID)&&void 0!==i?i:""}`,`cids:${Object.keys(o).sort((t,e)=>t.localeCompare(e)).map(t=>`${t}-${o[t]}`).join(",")}`,`k:${t}`];return(0,r._DJB2)(a.join("|"))}e._getUserStorageKey=i,e._getStorageKey=function(t,e,n){return e?i(t,e,n):(0,r._DJB2)(`k:${t}`)}},12656:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},92488:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.DataAdapterCore=void 0;let i=n(71588),o=n(20399),a=n(22171),s=n(30960),u=n(64007);class c{constructor(t,e){this._adapterName=t,this._cacheSuffix=e,this._options=null,this._sdkKey=null,this._lastModifiedStoreKey=`statsig.last_modified_time.${e}`,this._inMemoryCache=new d}attach(t,e){this._sdkKey=t,this._options=e}getDataSync(t){let e=t&&(0,a._normalizeUser)(t,this._options),n=this._getCacheKey(e),r=this._inMemoryCache.get(n,e);if(r)return r;let i=this._loadFromCache(n);return i?(this._inMemoryCache.add(n,i),this._inMemoryCache.get(n,e)):null}setData(t,e){let n=e&&(0,a._normalizeUser)(e,this._options),r=this._getCacheKey(n);this._inMemoryCache.add(r,l("Bootstrap",t,null,n))}_getDataAsyncImpl(t,e,n){return r(this,void 0,void 0,function*(){s.Storage.isReady()||(yield s.Storage.isReadyResolver());let r=null!=t?t:this.getDataSync(e),o=[this._fetchAndPrepFromNetwork(r,e,n)];return(null==n?void 0:n.timeoutMs)&&o.push(new Promise(t=>setTimeout(t,n.timeoutMs)).then(()=>(i.Log.debug("Fetching latest value timed out"),null))),yield Promise.race(o)})}_prefetchDataImpl(t,e){return r(this,void 0,void 0,function*(){let n=t&&(0,a._normalizeUser)(t,this._options),r=this._getCacheKey(n),i=yield this._getDataAsyncImpl(null,n,e);i&&this._inMemoryCache.add(r,Object.assign(Object.assign({},i),{source:"Prefetch"}))})}_fetchAndPrepFromNetwork(t,e,n){return r(this,void 0,void 0,function*(){let r=null;t&&this._isCachedResultValidFor204(t,e)&&(r=t.data);let a=yield this._fetchFromNetwork(r,e,n);if(!a)return i.Log.debug("No response returned for latest value"),null;let s=(0,u._typedJsonParse)(a,"has_updates","Response"),c=this._getSdkKey(),d=o.StableID.get(c),f=null;if((null==s?void 0:s.has_updates)===!0)f=l("Network",a,d,e);else{if(!r||(null==s?void 0:s.has_updates)!==!1)return null;f=l("NetworkNotModified",r,d,e)}let h=this._getCacheKey(e);return this._inMemoryCache.add(h,f),this._writeToCache(h,f),f})}_getSdkKey(){return null!=this._sdkKey?this._sdkKey:(i.Log.error(`${this._adapterName} is not attached to a Client`),"")}_loadFromCache(t){var e;let n=null===(e=s.Storage.getItem)||void 0===e?void 0:e.call(s.Storage,t);if(null==n)return null;let r=(0,u._typedJsonParse)(n,"source","Cached Result");return r?Object.assign(Object.assign({},r),{source:"Cache"}):null}_writeToCache(t,e){s.Storage.setItem(t,JSON.stringify(e)),this._runLocalStorageCacheEviction(t)}_runLocalStorageCacheEviction(t){var e;let n=null!==(e=(0,s._getObjectFromStorage)(this._lastModifiedStoreKey))&&void 0!==e?e:{};n[t]=Date.now();let r=f(n,10);r&&(delete n[r],s.Storage.removeItem(r)),(0,s._setObjectInStorage)(this._lastModifiedStoreKey,n)}}function l(t,e,n,r){return{source:t,data:e,receivedAt:Date.now(),stableID:n,fullUserHash:(0,a._getFullUserHash)(r)}}e.DataAdapterCore=c;class d{constructor(){this._data={}}get(t,e){var n;let r=this._data[t],o=null==r?void 0:r.stableID,a=null===(n=null==e?void 0:e.customIDs)||void 0===n?void 0:n.stableID;return a&&o&&a!==o?(i.Log.warn("'StatsigUser.customIDs.stableID' mismatch"),null):r}add(t,e){let n=f(this._data,9);n&&delete this._data[n],this._data[t]=e}merge(t){this._data=Object.assign(Object.assign({},this._data),t)}}function f(t,e){let n=Object.keys(t);return n.length<=e?null:n.reduce((e,n)=>{let r=t[e],i=t[n];return"object"==typeof r&&"object"==typeof i?i.receivedAtn.get(t),_markInitOverallStart:t=>{o(t,i({},r,"overall"))},_markInitOverallEnd:(t,e,n)=>{o(t,i({success:e,error:e?void 0:{name:"InitializeError",message:"Failed to initialize"},evaluationDetails:n},"end","overall"))},_markInitNetworkReqStart:(t,e)=>{o(t,i(e,r,"initialize","network_request"))},_markInitNetworkReqEnd:(t,e)=>{o(t,i(e,"end","initialize","network_request"))},_markInitProcessStart:t=>{o(t,i({},r,"initialize","process"))},_markInitProcessEnd:(t,e)=>{o(t,i(e,"end","initialize","process"))},_clearMarkers:t=>{n.delete(t)},_formatError(t){if(t&&"object"==typeof t)return{code:a(t,"code"),name:a(t,"name"),message:a(t,"message")}},_getDiagnosticsData(t,n,r,i){var o;return{success:(null==t?void 0:t.ok)===!0,statusCode:null==t?void 0:t.status,sdkRegion:null===(o=null==t?void 0:t.headers)||void 0===o?void 0:o.get("x-statsig-region"),isDelta:!0===r.includes('"is_delta":true')||void 0,attempt:n,error:e.Diagnostics._formatError(i)}},_enqueueDiagnosticsEvent(t,n,r,i){let o=e.Diagnostics._getMarkers(r);if(null==o||o.length<=0)return;e.Diagnostics._clearMarkers(r);let a={eventName:"statsig::diagnostics",user:t,value:null,metadata:{context:"initialize",markers:o.slice(),statsigOptions:i},time:Date.now()};n.enqueue(a)}}},69893:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},6721:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.ErrorBoundary=e.EXCEPTION_ENDPOINT=void 0;let i=n(71588),o=n(54274),a=n(6255);e.EXCEPTION_ENDPOINT="https://statsigapi.net/v1/sdk_exception";let s="[Statsig] UnknownError";class u{constructor(t,e,n){this._sdkKey=t,this._options=e,this._emitter=n,this._seen=new Set}wrap(t){try{(function(t){let e=new Set,n=Object.getPrototypeOf(t);for(;n&&n!==Object.prototype;)Object.getOwnPropertyNames(n).filter(t=>"function"==typeof(null==n?void 0:n[t])).forEach(t=>e.add(t)),n=Object.getPrototypeOf(n);return Array.from(e)})(t).forEach(e=>{let n=t[e];"$EB"in n||(t[e]=(...r)=>this._capture(e,()=>n.apply(t,r)),t[e].$EB=!0)})}catch(t){this._onError("eb:wrap",t)}}logError(t,e){this._onError(t,e)}_capture(t,e){try{let n=e();if(n&&n instanceof Promise)return n.catch(e=>this._onError(t,e));return n}catch(e){return this._onError(t,e),null}}_onError(t,n){try{i.Log.warn(`Caught error in ${t}`,{error:n}),r(this,void 0,void 0,function*(){var r,i,u,c,l,d,f;let h=n||Error(s),p=h instanceof Error,v=p?h.name:"No Name";if(this._seen.has(v))return;if(this._seen.add(v),null===(i=null===(r=this._options)||void 0===r?void 0:r.networkConfig)||void 0===i?void 0:i.preventAllNetworkTraffic){null===(u=this._emitter)||void 0===u||u.call(this,{name:"error",error:n});return}let g=o.SDKType._get(this._sdkKey),m=a.StatsigMetadataProvider.get(),y=p?h.stack:function(t){try{return JSON.stringify(t)}catch(t){return s}}(h),_=JSON.stringify(Object.assign({tag:t,exception:v,info:y},Object.assign(Object.assign({},m),{sdkType:g}))),b=null!==(d=null===(l=null===(c=this._options)||void 0===c?void 0:c.networkConfig)||void 0===l?void 0:l.networkOverrideFunc)&&void 0!==d?d:fetch;yield b(e.EXCEPTION_ENDPOINT,{method:"POST",headers:{"STATSIG-API-KEY":this._sdkKey,"STATSIG-SDK-TYPE":String(g),"STATSIG-SDK-VERSION":String(m.sdkVersion),"Content-Type":"application/json"},body:_}),null===(f=this._emitter)||void 0===f||f.call(this,{name:"error",error:n})}).then(()=>{}).catch(()=>{})}catch(t){}}}e.ErrorBoundary=u},13079:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},25139:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},12256:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.EventLogger=void 0;let i=n(90855),o=n(22035),a=n(71588),s=n(47234),u=n(58234),c=n(94888),l=n(30960),d=n(47419),f=n(24457),h={},p=t=>{var e;null===(e=h[t])||void 0===e||e.flush().catch(()=>{})};class v{constructor(t,e,n,r){var i;this._sdkKey=t,this._emitter=e,this._network=n,this._options=r,this._queue=[],this._lastExposureTimeMap={},this._nonExposedChecks={},this._hasRunQuickFlush=!1,this._creationTime=Date.now(),this._isLoggingDisabled=(null==r?void 0:r.disableLogging)===!0,this._maxQueueSize=null!==(i=null==r?void 0:r.loggingBufferMaxSize)&&void 0!==i?i:50;let o=null==r?void 0:r.networkConfig;this._logEventUrl=(0,d._getOverridableUrl)(null==o?void 0:o.logEventUrl,null==o?void 0:o.api,"/rgstr",s.NetworkDefault.eventsApi)}setLoggingDisabled(t){this._isLoggingDisabled=t}enqueue(t){this._shouldLogEvent(t)&&(this._normalizeAndAppendEvent(t),this._quickFlushIfNeeded(),this._queue.length>this._maxQueueSize&&p(this._sdkKey))}incrementNonExposureCount(t){var e;let n=null!==(e=this._nonExposedChecks[t])&&void 0!==e?e:0;this._nonExposedChecks[t]=n+1}reset(){this._lastExposureTimeMap={}}start(){(0,u._isServerEnv)()||(h[this._sdkKey]=this,(0,f._subscribeToVisiblityChanged)(t=>{"background"===t&&p(this._sdkKey)}),this._retryFailedLogs(),this._startBackgroundFlushInterval())}stop(){return r(this,void 0,void 0,function*(){this._flushIntervalId&&(clearInterval(this._flushIntervalId),this._flushIntervalId=null),yield this.flush()})}flush(){return r(this,void 0,void 0,function*(){if(this._appendAndResetNonExposedChecks(),0===this._queue.length)return;let t=this._queue;return this._queue=[],this._sendEvents(t)})}_quickFlushIfNeeded(){!this._hasRunQuickFlush&&(this._hasRunQuickFlush=!0,Date.now()-this._creationTime>200||setTimeout(()=>p(this._sdkKey),200))}_shouldLogEvent(t){if((0,u._isServerEnv)())return!1;if(!(0,c._isExposureEvent)(t))return!0;let e=t.user?t.user:{statsigEnvironment:void 0},n=(0,i._getUserStorageKey)(this._sdkKey,e),r=t.metadata?t.metadata:{},o=[t.eventName,n,r.gate,r.config,r.ruleID].join("|"),a=this._lastExposureTimeMap[o],s=Date.now();return(!a||!(s-a<6e4))&&(Object.keys(this._lastExposureTimeMap).length>1e3&&(this._lastExposureTimeMap={}),this._lastExposureTimeMap[o]=s,!0)}_sendEvents(t){var e,n;return r(this,void 0,void 0,function*(){if(this._isLoggingDisabled){this._saveFailedLogsToStorage(t);return}try{(!(0,f._isCurrentlyVisible)()&&this._network.isBeaconSupported()&&(null===(n=null===(e=this._options)||void 0===e?void 0:e.networkConfig)||void 0===n?void 0:n.networkOverrideFunc)==null?yield this._sendEventsViaBeacon(t):yield this._sendEventsViaPost(t)).success?this._emitter({name:"logs_flushed",events:t}):this._saveFailedLogsToStorage(t)}catch(t){a.Log.warn("Failed to flush events.")}})}_sendEventsViaPost(t){var e;return r(this,void 0,void 0,function*(){let n=yield this._network.post(this._getRequestData(t)),r=null!==(e=null==n?void 0:n.code)&&void 0!==e?e:-1;return{success:r>=200&&r<300}})}_sendEventsViaBeacon(t){return r(this,void 0,void 0,function*(){return{success:yield this._network.beacon(this._getRequestData(t))}})}_getRequestData(t){return{sdkKey:this._sdkKey,data:{events:t},url:this._logEventUrl,retries:3,isCompressable:!0,params:{[s.NetworkParam.EventCount]:String(t.length)}}}_saveFailedLogsToStorage(t){for(;t.length>500;)t.shift();let e=this._getStorageKey();try{(0,l._setObjectInStorage)(e,t)}catch(t){a.Log.warn("Unable to save failed logs to storage")}}_retryFailedLogs(){let t=this._getStorageKey();r(this,void 0,void 0,function*(){l.Storage.isReady()||(yield l.Storage.isReadyResolver());let e=(0,l._getObjectFromStorage)(t);e&&(l.Storage.removeItem(t),yield this._sendEvents(e))}).catch(()=>{a.Log.warn("Failed to flush stored logs")})}_getStorageKey(){return`statsig.failed_logs.${(0,o._DJB2)(this._sdkKey)}`}_normalizeAndAppendEvent(t){t.user&&(t.user=Object.assign({},t.user),delete t.user.privateAttributes);let e={},n=this._getCurrentPageUrl();n&&(e.statsigMetadata={currentPage:n});let r=Object.assign(Object.assign({},t),e);a.Log.debug("Enqueued Event:",r),this._queue.push(r)}_appendAndResetNonExposedChecks(){0!==Object.keys(this._nonExposedChecks).length&&(this._normalizeAndAppendEvent({eventName:"statsig::non_exposed_checks",user:null,time:Date.now(),metadata:{checks:Object.assign({},this._nonExposedChecks)}}),this._nonExposedChecks={})}_getCurrentPageUrl(){var t;if((null===(t=this._options)||void 0===t?void 0:t.includeCurrentPageUrlWithEvents)!==!1)return(0,u._getCurrentPageUrlSafe)()}_startBackgroundFlushInterval(){var t,e;let n=setInterval(()=>{h[this._sdkKey]._flushIntervalId!==n?clearInterval(n):p(this._sdkKey)},null!==(e=null===(t=this._options)||void 0===t?void 0:t.loggingIntervalMs)&&void 0!==e?e:1e4);this._flushIntervalId=n}}e.EventLogger=v},22035:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._getSortedObject=e._DJB2Object=e._DJB2=void 0;let r=n(23015);e._DJB2=t=>{let e=0;for(let n=0;n>>0)},e._DJB2Object=(t,n)=>(0,e._DJB2)(JSON.stringify((0,e._getSortedObject)(t,n))),e._getSortedObject=(t,n)=>{if(null==t)return null;let i=Object.keys(t).sort(),o={};return i.forEach(i=>{let a=t[i];if(0===n||"object"!==(0,r._typeOf)(a)){o[i]=a;return}o[i]=(0,e._getSortedObject)(a,null!=n?n-1:n)}),o}},18782:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},71588:function(t,e){"use strict";var n,r;function i(t){return t.unshift("[Statsig]"),t}Object.defineProperty(e,"__esModule",{value:!0}),e.Log=e.LogLevel=void 0,(r=n||(e.LogLevel=n={}))[r.None=0]="None",r[r.Error=1]="Error",r[r.Warn=2]="Warn",r[r.Info=3]="Info",r[r.Debug=4]="Debug";class o{static info(...t){this.level>=n.Info&&console.info("\x1b[34m%s\x1b[0m"," INFO ",...i(t))}static debug(...t){this.level>=n.Debug&&console.debug("\x1b[32m%s\x1b[0m"," DEBUG ",...i(t))}static warn(...t){this.level>=n.Warn&&console.warn("\x1b[33m%s\x1b[0m"," WARN ",...i(t))}static error(...t){this.level>=n.Error&&console.error("\x1b[31m%s\x1b[0m"," ERROR ",...i(t))}}e.Log=o,o.level=n.Warn},47234:function(t,e){"use strict";var n,r;Object.defineProperty(e,"__esModule",{value:!0}),e.NetworkParam=e.NetworkDefault=void 0,e.NetworkDefault={eventsApi:"https://prodregistryv2.org/v1",initializeApi:"https://featureassets.org/v1",specsApi:"https://assetsconfigcdn.org/v1"},(r=n||(e.NetworkParam=n={})).EventCount="ec",r.SdkKey="k",r.SdkType="st",r.SdkVersion="sv",r.Time="t",r.SessionID="sid",r.StatsigEncoded="se",r.IsGzipped="gz"},28392:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.NetworkCore=void 0,n(4091);let i=n(4091),o=n(27523),a=n(71588),s=n(47234),u=n(54274),c=n(58234),l=n(84425),d=n(20399),f=n(6255),h=n(24457),p=new Set([408,500,502,503,504,522,524,599]);class v{constructor(t,e){this._emitter=e,this._timeout=1e4,this._netConfig={},this._options={},t&&(this._options=t),this._options.networkConfig&&(this._netConfig=this._options.networkConfig),this._netConfig.networkTimeoutMs&&(this._timeout=this._netConfig.networkTimeoutMs)}post(t){return r(this,void 0,void 0,function*(){let e=yield this._getPopulatedBody(t);return t.isStatsigEncodable&&(e=this._attemptToEncodeString(t,e)),this._sendRequest(Object.assign({method:"POST",body:e},t))})}get(t){return this._sendRequest(Object.assign({method:"GET"},t))}isBeaconSupported(){return"undefined"!=typeof navigator&&"function"==typeof navigator.sendBeacon}beacon(t){return r(this,void 0,void 0,function*(){if(!g(t))return!1;let e=yield this._getPopulatedBody(t),n=yield this._getPopulatedURL(t),r=navigator;return r.sendBeacon.bind(r)(n,e)})}_sendRequest(t){var e,n,i;return r(this,void 0,void 0,function*(){if(!g(t)||this._netConfig.preventAllNetworkTraffic)return null;let{method:r,body:s,retries:u,attempt:c}=t,l=null!=c?c:1,d="undefined"!=typeof AbortController?new AbortController:null,f=setTimeout(()=>null==d?void 0:d.abort(`Timeout of ${this._timeout}ms expired.`),this._timeout),v=yield this._getPopulatedURL(t),m=null,y=(0,h._isUnloading)();try{let n={method:r,body:s,headers:Object.assign({},t.headers),signal:null==d?void 0:d.signal,priority:t.priority,keepalive:y};t.isInitialize&&o.Diagnostics._markInitNetworkReqStart(t.sdkKey,{attempt:l});let i=null!==(e=this._netConfig.networkOverrideFunc)&&void 0!==e?e:fetch;if(m=yield i(v,n),clearTimeout(f),!m.ok){let t=yield m.text().catch(()=>"No Text"),e=Error(`NetworkError: ${v} ${t}`);throw e.name="NetworkError",e}let a=yield m.text();return t.isInitialize&&o.Diagnostics._markInitNetworkReqEnd(t.sdkKey,o.Diagnostics._getDiagnosticsData(m,l,a)),{body:a,code:m.status}}catch(s){let e=(null==d?void 0:d.signal.aborted)&&"string"==typeof d.signal.reason?d.signal.reason:"string"==typeof s?s:s instanceof Error?`${s.name}: ${s.message}`:"Unknown Error";if(t.isInitialize&&o.Diagnostics._markInitNetworkReqEnd(t.sdkKey,o.Diagnostics._getDiagnosticsData(m,l,"",s)),!u||l>u||!p.has(null!==(n=null==m?void 0:m.status)&&void 0!==n?n:500))return null===(i=this._emitter)||void 0===i||i.call(this,{name:"error",error:s}),a.Log.error(`A networking error occured during ${r} request to ${v}.`,e,s),null;return this._sendRequest(Object.assign(Object.assign({},t),{retries:u,attempt:l+1}))}})}_getPopulatedURL(t){return r(this,void 0,void 0,function*(){let e=Object.assign({[s.NetworkParam.SdkKey]:t.sdkKey,[s.NetworkParam.SdkType]:u.SDKType._get(t.sdkKey),[s.NetworkParam.SdkVersion]:f.SDK_VERSION,[s.NetworkParam.Time]:String(Date.now()),[s.NetworkParam.SessionID]:yield l.SessionID.get(t.sdkKey)},t.params),n=Object.keys(e).map(t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`).join("&");return`${t.url}${n?`?${n}`:""}`})}_getPopulatedBody(t){return r(this,void 0,void 0,function*(){let{data:e,sdkKey:n}=t,r=d.StableID.get(n),i=l.SessionID.get(n),o=u.SDKType._get(n);return JSON.stringify(Object.assign(Object.assign({},e),{statsigMetadata:Object.assign(Object.assign({},f.StatsigMetadataProvider.get()),{stableID:r,sessionID:i,sdkType:o})}))})}_attemptToEncodeString(t,e){var n,r;let o=(0,c._getWindowSafe)();if(!t.isStatsigEncodable||this._options.disableStatsigEncoding||null!=(0,i._getStatsigGlobalFlag)("no-encode")||!(null==o?void 0:o.btoa))return e;try{let i=null!==(n=o.btoa(e).split("").reverse().join(""))&&void 0!==n?n:e;return t.params=Object.assign(Object.assign({},null!==(r=t.params)&&void 0!==r?r:{}),{[s.NetworkParam.StatsigEncoded]:"1"}),i}catch(t){return a.Log.warn("/initialize request encoding failed"),e}}}e.NetworkCore=v;let g=t=>!!t.sdkKey||(a.Log.warn("Unable to make request without an SDK key"),!1)},18774:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},57505:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},54274:function(t,e){"use strict";let n;Object.defineProperty(e,"__esModule",{value:!0}),e.SDKType=void 0;let r={};e.SDKType={_get:t=>{var e;return(null!==(e=r[t])&&void 0!==e?e:"js-mono")+(null!=n?n:"")},_setClientType(t,e){r[t]=e},_setBindingType(t){n&&"-react"!==n||(n="-"+t)}}},58234:function(t,e,n){"use strict";var r=n(25566);Object.defineProperty(e,"__esModule",{value:!0}),e._getCurrentPageUrlSafe=e._addDocumentEventListenerSafe=e._addWindowEventListenerSafe=e._isServerEnv=e._getDocumentSafe=e._getWindowSafe=void 0,e._getWindowSafe=()=>"undefined"!=typeof window?window:null,e._getDocumentSafe=()=>{var t;let n=(0,e._getWindowSafe)();return null!==(t=null==n?void 0:n.document)&&void 0!==t?t:null},e._isServerEnv=()=>{if(null!==(0,e._getDocumentSafe)())return!1;let t=void 0!==r&&null!=r.versions&&null!=r.versions.node;return"string"==typeof EdgeRuntime||t},e._addWindowEventListenerSafe=(t,n)=>{let r=(0,e._getWindowSafe)();"function"==typeof(null==r?void 0:r.addEventListener)&&r.addEventListener(t,n)},e._addDocumentEventListenerSafe=(t,n)=>{let r=(0,e._getDocumentSafe)();"function"==typeof(null==r?void 0:r.addEventListener)&&r.addEventListener(t,n)},e._getCurrentPageUrlSafe=()=>{var t;try{return null===(t=(0,e._getWindowSafe)())||void 0===t?void 0:t.location.href.split(/[?#]/)[0]}catch(t){return}}},84425:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.StatsigSession=e.SessionID=void 0;let r=n(90855),i=n(71588),o=n(30960),a=n(75336),s={};function u(t,e){return setTimeout(()=>{let e=null==__STATSIG__?void 0:__STATSIG__.instance(t);e&&e.$emt({name:"session_expired"})},e)}function c(t){return`statsig.session_id.${(0,r._getStorageKey)(t)}`}e.SessionID={get:t=>e.StatsigSession.get(t).data.sessionID},e.StatsigSession={get:t=>(null==s[t]&&(s[t]=function(t){let e=function(t){let e=c(t);return(0,o._getObjectFromStorage)(e)}(t),n=Date.now();return e||(e={sessionID:(0,a.getUUID)(),startTime:n,lastUpdate:n}),{data:e,sdkKey:t}}(t)),function(t){let e=Date.now(),n=t.data;((function({lastUpdate:t}){return Date.now()-t>18e5})(n)||function({startTime:t}){return Date.now()-t>144e5}(n))&&(n.sessionID=(0,a.getUUID)(),n.startTime=e),n.lastUpdate=e,function(t,e){let n=c(e);try{(0,o._setObjectInStorage)(n,t)}catch(t){i.Log.warn("Failed to save SessionID")}}(n,t.sdkKey),clearTimeout(t.idleTimeoutID),clearTimeout(t.ageTimeoutID);let r=e-n.startTime,s=t.sdkKey;return t.idleTimeoutID=u(s,18e5),t.ageTimeoutID=u(s,144e5-r),t}(s[t])),overrideInitialSessionID:(t,e)=>{s[e]=function(t,e){let n=Date.now();return{data:{sessionID:t,startTime:n,lastUpdate:n},sdkKey:e}}(t,e)}}},20399:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.StableID=void 0;let r=n(90855),i=n(71588),o=n(30960),a=n(75336),s={};function u(t){return`statsig.stable_id.${(0,r._getStorageKey)(t)}`}function c(t,e){let n=u(e);try{(0,o._setObjectInStorage)(n,t)}catch(t){i.Log.warn("Failed to save StableID")}}e.StableID={get:t=>{if(null==s[t]){let e=function(t){let e=u(t);return(0,o._getObjectFromStorage)(e)}(t);null==e&&c(e=(0,a.getUUID)(),t),s[t]=e}return s[t]},setOverride:(t,e)=>{s[e]=t,c(t,e)}}},81438:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.StatsigClientBase=void 0,n(4091);let i=n(4091),o=n(6721),a=n(12256),s=n(71588),u=n(58234),c=n(84425),l=n(30960);class d{constructor(t,e,n,r){var d,f;this.loadingStatus="Uninitialized",this._listeners={};let h=this.$emt.bind(this);if((null==r?void 0:r.logLevel)!=null&&(s.Log.level=r.logLevel),(null==r?void 0:r.disableStorage)&&l.Storage._setDisabled(!0),(null==r?void 0:r.initialSessionID)&&c.StatsigSession.overrideInitialSessionID(r.initialSessionID,t),(null==r?void 0:r.storageProvider)&&l.Storage._setProvider(r.storageProvider),this._sdkKey=t,this._options=null!=r?r:{},this.overrideAdapter=null!==(d=null==r?void 0:r.overrideAdapter)&&void 0!==d?d:null,this._logger=new a.EventLogger(t,h,n,r),this._errorBoundary=new o.ErrorBoundary(t,r,h),this._errorBoundary.wrap(this),this._errorBoundary.wrap(n),this._errorBoundary.wrap(e),this._errorBoundary.wrap(this._logger),!(0,u._isServerEnv)()){let e=(0,i._getStatsigGlobal)(),n=null!==(f=e.instances)&&void 0!==f?f:{};null!=n[t]&&s.Log.warn("Creating multiple Statsig clients with the same SDK key can lead to unexpected behavior. Multi-instance support requires different SDK keys."),n[t]=this,e.lastInstance=this,e.instances=n,__STATSIG__=e}this.dataAdapter=e,this.dataAdapter.attach(t,r),this.storageProvider=l.Storage,this._primeReadyRipcord()}updateRuntimeOptions(t){null!=t.disableLogging&&(this._options.disableLogging=t.disableLogging,this._logger.setLoggingDisabled(t.disableLogging)),null!=t.disableStorage&&(this._options.disableStorage=t.disableStorage,l.Storage._setDisabled(t.disableStorage))}flush(){return this._logger.flush()}shutdown(){return r(this,void 0,void 0,function*(){this.$emt({name:"pre_shutdown"}),yield this._logger.stop()})}on(t,e){this._listeners[t]||(this._listeners[t]=[]),this._listeners[t].push(e)}off(t,e){if(this._listeners[t]){let n=this._listeners[t].indexOf(e);-1!==n&&this._listeners[t].splice(n,1)}}$on(t,e){e.__isInternal=!0,this.on(t,e)}$emt(t){var e;let n=e=>{try{e(t)}catch(n){if(!0===e.__isInternal){this._errorBoundary.logError(`__emit:${t.name}`,n);return}s.Log.error("An error occurred in a StatsigClientEvent listener. This is not an issue with Statsig.",t)}};this._listeners[t.name]&&this._listeners[t.name].forEach(t=>n(t)),null===(e=this._listeners["*"])||void 0===e||e.forEach(n)}_setStatus(t,e){this.loadingStatus=t,this.$emt({name:"values_updated",status:t,values:e})}_enqueueExposure(t,e,n){if((null==n?void 0:n.disableExposureLog)===!0){this._logger.incrementNonExposureCount(t);return}this._logger.enqueue(e)}}e.StatsigClientBase=d},68097:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},22134:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.DataAdapterCachePrefix=void 0,e.DataAdapterCachePrefix="statsig.cached"},94888:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._createLayerParameterExposure=e._createConfigExposure=e._createGateExposure=e._isExposureEvent=void 0;let n="statsig::config_exposure",r="statsig::gate_exposure",i=(t,e,n,r,i)=>({eventName:t,user:e,value:null,metadata:o(n,r),secondaryExposures:i,time:Date.now()});e._isExposureEvent=({eventName:t})=>t===r||t===n,e._createGateExposure=(t,e)=>{var n,o;return i(r,t,e.details,{gate:e.name,gateValue:String(e.value),ruleID:e.ruleID},null!==(o=null===(n=e.__evaluation)||void 0===n?void 0:n.secondary_exposures)&&void 0!==o?o:[])},e._createConfigExposure=(t,e)=>{var r,o;return i(n,t,e.details,{config:e.name,ruleID:e.ruleID},null!==(o=null===(r=e.__evaluation)||void 0===r?void 0:r.secondary_exposures)&&void 0!==o?o:[])},e._createLayerParameterExposure=(t,e,n)=>{var r,o,a;let s=e.__evaluation,u=(null===(r=null==s?void 0:s.explicit_parameters)||void 0===r?void 0:r.includes(n))===!0,c="",l=null!==(o=null==s?void 0:s.undelegated_secondary_exposures)&&void 0!==o?o:[];return u&&(c=null!==(a=s.allocated_experiment_name)&&void 0!==a?a:"",l=s.secondary_exposures),i("statsig::layer_exposure",t,e.details,{config:e.name,parameterName:n,ruleID:e.ruleID,allocatedExperiment:c,isExplicitParameter:String(u)},l)};let o=(t,e)=>(e.reason=t.reason,t.lcut&&(e.lcut=String(t.lcut)),t.receivedAt&&(e.receivedAt=String(t.receivedAt)),e)},6255:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.StatsigMetadataProvider=e.SDK_VERSION=void 0,e.SDK_VERSION="3.0.0";let n={sdkVersion:e.SDK_VERSION,sdkType:"js-mono"};e.StatsigMetadataProvider={get:()=>n,add:t=>{n=Object.assign(Object.assign({},n),t)}}},4932:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},35917:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._makeTypedGet=e._mergeOverride=e._makeLayer=e._makeExperiment=e._makeDynamicConfig=e._makeFeatureGate=void 0;let r=n(23015);function i(t,e,n,r){var i;return{name:t,details:e,ruleID:null!==(i=null==n?void 0:n.rule_id)&&void 0!==i?i:"default",__evaluation:n,value:r}}function o(t,e,n){var r;let o=null!==(r=null==n?void 0:n.value)&&void 0!==r?r:{};return Object.assign(Object.assign({},i(t,e,n,o)),{get:a(null==n?void 0:n.value)})}function a(t,e){return(n,i)=>{var o;let a=null!==(o=null==t?void 0:t[n])&&void 0!==o?o:null;return null!=a&&(null==i||(0,r._isTypeMatch)(a,i))?(null==e||e(n),a):null!=i?i:null}}e._makeFeatureGate=function(t,e,n){return i(t,e,n,(null==n?void 0:n.value)===!0)},e._makeDynamicConfig=o,e._makeExperiment=function(t,e,n){var r;return Object.assign(Object.assign({},o(t,e,n)),{groupName:null!==(r=null==n?void 0:n.group_name)&&void 0!==r?r:null})},e._makeLayer=function(t,e,n,r){var o,s;return Object.assign(Object.assign({},i(t,e,n,void 0)),{get:a(null==n?void 0:n.value,r),groupName:null!==(o=null==n?void 0:n.group_name)&&void 0!==o?o:null,__value:null!==(s=null==n?void 0:n.value)&&void 0!==s?s:{}})},e._mergeOverride=function(t,e,n,r){return Object.assign(Object.assign(Object.assign({},t),e),{get:a(n,r)})},e._makeTypedGet=a},67541:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0})},22171:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._getFullUserHash=e._normalizeUser=void 0;let r=n(22035),i=n(71588);e._normalizeUser=function(t,e){try{let n=JSON.parse(JSON.stringify(t));return null!=e&&null!=e.environment&&(n.statsigEnvironment=e.environment),n}catch(t){return i.Log.error("Failed to JSON.stringify user"),{statsigEnvironment:void 0}}},e._getFullUserHash=function(t){return t?(0,r._DJB2Object)(t):null}},30960:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._setObjectInStorage=e._getObjectFromStorage=e.Storage=void 0;let r=n(71588),i=n(58234),o={},a={isReady:()=>!0,isReadyResolver:()=>null,getProviderName:()=>"InMemory",getItem:t=>o[t]?o[t]:null,setItem:(t,e)=>{o[t]=e},removeItem:t=>{delete o[t]},getAllKeys:()=>Object.keys(o)},s=null;try{let t=(0,i._getWindowSafe)();t&&t.localStorage&&"function"==typeof t.localStorage.getItem&&(s={isReady:()=>!0,isReadyResolver:()=>null,getProviderName:()=>"LocalStorage",getItem:e=>t.localStorage.getItem(e),setItem:(e,n)=>t.localStorage.setItem(e,n),removeItem:e=>t.localStorage.removeItem(e),getAllKeys:()=>Object.keys(t.localStorage)})}catch(t){r.Log.warn("Failed to setup localStorageProvider.")}let u=null!=s?s:a,c=u;e.Storage={isReady:()=>c.isReady(),isReadyResolver:()=>c.isReadyResolver(),getProviderName:()=>c.getProviderName(),getItem:t=>(function(t){try{return t()}catch(t){if(t instanceof Error&&"SecurityError"===t.name)return e.Storage._setProvider(a),null;throw t}})(()=>c.getItem(t)),setItem:(t,e)=>c.setItem(t,e),removeItem:t=>c.removeItem(t),getAllKeys:()=>c.getAllKeys(),_setProvider:t=>{u=t,c=t},_setDisabled:t=>{c=t?a:u}},e._getObjectFromStorage=function(t){let n=e.Storage.getItem(t);return JSON.parse(null!=n?n:"null")},e._setObjectInStorage=function(t,n){e.Storage.setItem(t,JSON.stringify(n))}},64007:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._typedJsonParse=void 0;let r=n(71588);e._typedJsonParse=function(t,e,n){try{return JSON.parse(t)}catch(t){}return r.Log.error(`Failed to parse ${n}`),null}},23015:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._isTypeMatch=e._typeOf=void 0,e._typeOf=function(t){return Array.isArray(t)?"array":typeof t},e._isTypeMatch=function(t,e){let n=t=>Array.isArray(t)?"array":typeof t;return n(t)===n(e)}},75336:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getUUID=void 0,e.getUUID=function(){if("undefined"!=typeof crypto&&"function"==typeof crypto.randomUUID)return crypto.randomUUID();let t=new Date().getTime(),e="undefined"!=typeof performance&&performance.now&&1e3*performance.now()||0,n="89ab"[Math.floor(4*Math.random())];return`xxxxxxxx-xxxx-4xxx-${n}xxx-xxxxxxxxxxxx`.replace(/[xy]/g,n=>{let r=16*Math.random();return t>0?(r=(t+r)%16|0,t=Math.floor(t/16)):(r=(e+r)%16|0,e=Math.floor(e/16)),("x"===n?r:7&r|8).toString(16)})}},47419:function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._getOverridableUrl=void 0,e._getOverridableUrl=function(t,e,n,r){return t||(e?`${e}${n}`:`${r}${n}`)}},24457:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._notifyVisibilityChanged=e._subscribeToVisiblityChanged=e._isUnloading=e._isCurrentlyVisible=void 0;let r=n(58234),i="foreground",o="background",a=[],s=i,u=!1;e._isCurrentlyVisible=()=>s===i,e._isUnloading=()=>u,e._subscribeToVisiblityChanged=t=>{a.unshift(t)},e._notifyVisibilityChanged=t=>{t!==s&&(s=t,a.forEach(e=>e(t)))},(0,r._addWindowEventListenerSafe)("focus",()=>{u=!1,(0,e._notifyVisibilityChanged)(i)}),(0,r._addWindowEventListenerSafe)("blur",()=>(0,e._notifyVisibilityChanged)(o)),(0,r._addWindowEventListenerSafe)("beforeunload",()=>{u=!0,(0,e._notifyVisibilityChanged)(o)}),(0,r._addDocumentEventListenerSafe)("visibilitychange",()=>{(0,e._notifyVisibilityChanged)("visible"===document.visibilityState?i:o)})},59684:function(t,e,n){"use strict";var r=this&&this.__createBinding||(Object.create?function(t,e,n,r){void 0===r&&(r=n);var i=Object.getOwnPropertyDescriptor(e,n);(!i||("get"in i?!e.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return e[n]}}),Object.defineProperty(t,r,i)}:function(t,e,n,r){void 0===r&&(r=n),t[r]=e[n]}),i=this&&this.__exportStar||function(t,e){for(var n in t)"default"===n||Object.prototype.hasOwnProperty.call(e,n)||r(e,t,n)};Object.defineProperty(e,"__esModule",{value:!0}),e.Diagnostics=e.Log=e.Storage=e.EventLogger=void 0,n(4091);let o=n(27523);Object.defineProperty(e,"Diagnostics",{enumerable:!0,get:function(){return o.Diagnostics}});let a=n(12256);Object.defineProperty(e,"EventLogger",{enumerable:!0,get:function(){return a.EventLogger}});let s=n(71588);Object.defineProperty(e,"Log",{enumerable:!0,get:function(){return s.Log}});let u=n(6255),c=n(30960);Object.defineProperty(e,"Storage",{enumerable:!0,get:function(){return c.Storage}}),i(n(4091),e),i(n(90855),e),i(n(12656),e),i(n(92488),e),i(n(27523),e),i(n(69893),e),i(n(6721),e),i(n(13079),e),i(n(25139),e),i(n(22035),e),i(n(18782),e),i(n(71588),e),i(n(28392),e),i(n(47234),e),i(n(18774),e),i(n(57505),e),i(n(58234),e),i(n(54274),e),i(n(84425),e),i(n(20399),e),i(n(81438),e),i(n(68097),e),i(n(22134),e),i(n(94888),e),i(n(6255),e),i(n(4932),e),i(n(35917),e),i(n(67541),e),i(n(22171),e),i(n(30960),e),i(n(64007),e),i(n(23015),e),i(n(47419),e),i(n(75336),e),i(n(24457),e),__STATSIG__=Object.assign(Object.assign({},null!=__STATSIG__?__STATSIG__:{}),{Log:s.Log,SDK_VERSION:u.SDK_VERSION})},11071:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._resolveDeltasResponse=void 0;let r=n(59684);function i(t,e){null==t||t.forEach(t=>{delete e[t]})}e._resolveDeltasResponse=function(t,e){var n;let o=(0,r._typedJsonParse)(e,"checksum","DeltasEvaluationResponse");if(!o)return{hadBadDeltaChecksum:!0};let a=(i((n=Object.assign(Object.assign(Object.assign({},t),o),{feature_gates:Object.assign(Object.assign({},t.feature_gates),o.feature_gates),layer_configs:Object.assign(Object.assign({},t.layer_configs),o.layer_configs),dynamic_configs:Object.assign(Object.assign({},t.dynamic_configs),o.dynamic_configs)})).deleted_gates,n.feature_gates),delete n.deleted_gates,i(n.deleted_configs,n.dynamic_configs),delete n.deleted_configs,i(n.deleted_layers,n.layer_configs),delete n.deleted_layers,n),s=(0,r._DJB2Object)({feature_gates:a.feature_gates,dynamic_configs:a.dynamic_configs,layer_configs:a.layer_configs},2);return s!==o.checksumV2?{hadBadDeltaChecksum:!0,badChecksum:s,badMergedConfigs:a,badFullResponse:o.deltas_full_response}:JSON.stringify(a)}},25460:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});let r=n(59684);class i{constructor(){this._rawValues=null,this._values=null,this._source="Uninitialized",this._lcut=0,this._receivedAt=0}reset(){this._values=null,this._rawValues=null,this._source="Loading",this._lcut=0,this._receivedAt=0}finalize(){this._values||(this._source="NoValues")}getValues(){return this._rawValues?(0,r._typedJsonParse)(this._rawValues,"has_updates","EvaluationStoreValues"):null}setValues(t){if(!t)return!1;let e=(0,r._typedJsonParse)(t.data,"has_updates","EvaluationResponse");return null!=e&&(this._source=t.source,(null==e?void 0:e.has_updates)!==!0||(this._rawValues=t.data,this._lcut=e.time,this._receivedAt=t.receivedAt,this._values=e,!0))}getGate(t){var e;return this._getDetailedStoreResult(null===(e=this._values)||void 0===e?void 0:e.feature_gates,t)}getConfig(t){var e;return this._getDetailedStoreResult(null===(e=this._values)||void 0===e?void 0:e.dynamic_configs,t)}getLayer(t){var e;return this._getDetailedStoreResult(null===(e=this._values)||void 0===e?void 0:e.layer_configs,t)}getParamStore(t){var e;return this._getDetailedStoreResult(null===(e=this._values)||void 0===e?void 0:e.param_stores,t)}_getDetailedStoreResult(t,e){let n=null;return t&&(n=t[e]?t[e]:t[(0,r._DJB2)(e)]),{result:n,details:this._getDetails(null==n)}}getCurrentSourceDetails(){return"Uninitialized"===this._source||"NoValues"===this._source?{reason:this._source}:{reason:this._source,lcut:this._lcut,receivedAt:this._receivedAt}}_getDetails(t){let e=this.getCurrentSourceDetails(),n=e.reason;return"Uninitialized"!==n&&"NoValues"!==n&&(n=`${n}:${t?"Unrecognized":"Recognized"}`),Object.assign(Object.assign({},e),{reason:n})}}e.default=i},21790:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0});let i=n(59684),o=n(11071);class a extends i.NetworkCore{constructor(t,e){super(t,e);let n=null==t?void 0:t.networkConfig;this._initializeUrl=(0,i._getOverridableUrl)(null==n?void 0:n.initializeUrl,null==n?void 0:n.api,"/initialize",i.NetworkDefault.initializeApi)}fetchEvaluations(t,e,n,o){return r(this,void 0,void 0,function*(){let r=e?(0,i._typedJsonParse)(e,"has_updates","InitializeResponse"):null,a={user:o,hash:"djb2",deltasResponseRequested:!1};return(null==r?void 0:r.has_updates)&&(a=Object.assign(Object.assign({},a),{sinceTime:r.time,previousDerivedFields:"derived_fields"in r?r.derived_fields:{},deltasResponseRequested:!0})),this._fetchEvaluations(t,r,a,n)})}_fetchEvaluations(t,e,n,i){var a,s;return r(this,void 0,void 0,function*(){let r=yield this.post({sdkKey:t,url:this._initializeUrl,data:n,retries:2,isStatsigEncodable:!0,priority:i,isInitialize:!0});if((null==r?void 0:r.code)===204)return'{"has_updates": false}';if((null==r?void 0:r.code)!==200)return null!==(a=null==r?void 0:r.body)&&void 0!==a?a:null;if((null==e?void 0:e.has_updates)!==!0||(null===(s=r.body)||void 0===s?void 0:s.includes('"is_delta":true'))!==!0||!0!==n.deltasResponseRequested)return r.body;let u=(0,o._resolveDeltasResponse)(e,r.body);return"string"==typeof u?u:this._fetchEvaluations(t,e,Object.assign(Object.assign(Object.assign({},n),u),{deltasResponseRequested:!1}),i)})}}e.default=a},93583:function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e._makeParamStoreGetter=void 0;let r=n(59684),i={disableExposureLog:!0};function o(t){return null==t||!1===t.disableExposureLog}function a(t,e){return null!=e&&!(0,r._isTypeMatch)(t,e)}e._makeParamStoreGetter=function(t,e,n){return(s,u)=>{if(null==e)return u;let c=e[s];if(null==c||null!=u&&(0,r._typeOf)(u)!==c.param_type)return u;switch(c.ref_type){case"static":return c.value;case"gate":return t.getFeatureGate(c.gate_name,o(n)?void 0:i).value?c.pass_value:c.fail_value;case"dynamic_config":return function(t,e,n,r){let s=t.getDynamicConfig(e.config_name,i).get(e.param_name);return a(s,n)?n:(o(r)&&t.getDynamicConfig(e.config_name),s)}(t,c,u,n);case"experiment":return function(t,e,n,r){let s=t.getExperiment(e.experiment_name,i).get(e.param_name);return a(s,n)?n:(o(r)&&t.getExperiment(e.experiment_name),s)}(t,c,u,n);case"layer":return function(t,e,n,r){let s=t.getLayer(e.layer_name,i).get(e.param_name);return a(s,n)?n:(o(r)&&t.getLayer(e.layer_name).get(e.param_name),s)}(t,c,u,n);default:return u}}}},66038:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0});let i=n(59684),o=n(25460),a=n(21790),s=n(93583),u=n(67044);class c extends i.StatsigClientBase{static instance(t){let e=(0,i._getStatsigGlobal)().instance(t);return e instanceof c?e:(i.Log.warn((0,i._isServerEnv)()?"StatsigClient.instance is not supported in server environments":"Unable to find StatsigClient instance"),new c(null!=t?t:"",{}))}constructor(t,e,n=null){var r;i.SDKType._setClientType(t,"javascript-client"),super(t,null!==(r=null==n?void 0:n.dataAdapter)&&void 0!==r?r:new u.StatsigEvaluationsDataAdapter,new a.default(n,t=>{this.$emt(t)}),n),this._store=new o.default,this._user=(0,i._normalizeUser)(e,n)}initializeSync(t){this._logger.start(),this.updateUserSync(this._user,t)}initializeAsync(t){return r(this,void 0,void 0,function*(){return i.Storage.isReady()||(yield i.Storage.isReadyResolver()),this._logger.start(),this.updateUserAsync(this._user,t)})}updateUserSync(t,e){this._resetForUser(t);let n=this.dataAdapter.getDataSync(this._user);this._store.setValues(n),this._finalizeUpdate(n),(null==e?void 0:e.disableBackgroundCacheRefresh)||this._runPostUpdate(null!=n?n:null,this._user)}updateUserAsync(t,e){return r(this,void 0,void 0,function*(){this._resetForUser(t);let n=this._user;i.Diagnostics._markInitOverallStart(this._sdkKey);let r=this.dataAdapter.getDataSync(n);if(this._store.setValues(r),this._setStatus("Loading",r),r=yield this.dataAdapter.getDataAsync(r,n,e),n!==this._user)return;let o=!1;null!=r&&(i.Diagnostics._markInitProcessStart(this._sdkKey),o=this._store.setValues(r),i.Diagnostics._markInitProcessEnd(this._sdkKey,{success:o})),this._finalizeUpdate(r),i.Diagnostics._markInitOverallEnd(this._sdkKey,o,this._store.getCurrentSourceDetails()),i.Diagnostics._enqueueDiagnosticsEvent(this._user,this._logger,this._sdkKey,this._options)})}getContext(){return{sdkKey:this._sdkKey,options:this._options,values:this._store.getValues(),user:JSON.parse(JSON.stringify(this._user)),errorBoundary:this._errorBoundary,session:i.StatsigSession.get(this._sdkKey),stableID:i.StableID.get(this._sdkKey)}}checkGate(t,e){return this.getFeatureGate(t,e).value}getFeatureGate(t,e){var n,r;let{result:o,details:a}=this._store.getGate(t),s=(0,i._makeFeatureGate)(t,a,o),u=null===(r=null===(n=this.overrideAdapter)||void 0===n?void 0:n.getGateOverride)||void 0===r?void 0:r.call(n,s,this._user,e),c=null!=u?u:s;return this._enqueueExposure(t,(0,i._createGateExposure)(this._user,c),e),this.$emt({name:"gate_evaluation",gate:c}),c}getDynamicConfig(t,e){var n,r;let{result:o,details:a}=this._store.getConfig(t),s=(0,i._makeDynamicConfig)(t,a,o),u=null===(r=null===(n=this.overrideAdapter)||void 0===n?void 0:n.getDynamicConfigOverride)||void 0===r?void 0:r.call(n,s,this._user,e),c=null!=u?u:s;return this._enqueueExposure(t,(0,i._createConfigExposure)(this._user,c),e),this.$emt({name:"dynamic_config_evaluation",dynamicConfig:c}),c}getExperiment(t,e){var n,r;let{result:o,details:a}=this._store.getConfig(t),s=(0,i._makeExperiment)(t,a,o),u=null===(r=null===(n=this.overrideAdapter)||void 0===n?void 0:n.getExperimentOverride)||void 0===r?void 0:r.call(n,s,this._user,e),c=null!=u?u:s;return this._enqueueExposure(t,(0,i._createConfigExposure)(this._user,c),e),this.$emt({name:"experiment_evaluation",experiment:c}),c}getLayer(t,e){var n,r,o;let{result:a,details:s}=this._store.getLayer(t),u=(0,i._makeLayer)(t,s,a),c=null===(r=null===(n=this.overrideAdapter)||void 0===n?void 0:n.getLayerOverride)||void 0===r?void 0:r.call(n,u,this._user,e),l=(0,i._mergeOverride)(u,c,null!==(o=null==c?void 0:c.__value)&&void 0!==o?o:u.__value,n=>{this._enqueueExposure(t,(0,i._createLayerParameterExposure)(this._user,l,n),e)});return this.$emt({name:"layer_evaluation",layer:l}),l}getParameterStore(t,e){let{result:n,details:r}=this._store.getParamStore(t);return this._logger.incrementNonExposureCount(t),{name:t,details:r,__configuration:n,get:(0,s._makeParamStoreGetter)(this,n,e)}}logEvent(t,e,n){this._logger.enqueue(Object.assign(Object.assign({},"string"==typeof t?{eventName:t,value:e,metadata:n}:t),{user:this._user,time:Date.now()}))}_primeReadyRipcord(){this.$on("error",()=>{"Loading"===this.loadingStatus&&this._finalizeUpdate(null)})}_finalizeUpdate(t){this._store.finalize(),this._setStatus("Ready",t)}_runPostUpdate(t,e){this.dataAdapter.getDataAsync(t,e,{priority:"low"}).catch(t=>{i.Log.error("An error occurred after update.",t)})}_resetForUser(t){var e;this._logger.reset(),this._store.reset(),this._user=(0,i._normalizeUser)(t,this._options);let n=null===(e=this._user.customIDs)||void 0===e?void 0:e.stableID;n&&i.StableID.setOverride(n,this._sdkKey)}}e.default=c},67044:function(t,e,n){"use strict";var r=this&&this.__awaiter||function(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})};Object.defineProperty(e,"__esModule",{value:!0}),e.StatsigEvaluationsDataAdapter=void 0;let i=n(59684),o=n(21790);class a extends i.DataAdapterCore{constructor(){super("EvaluationsDataAdapter","evaluations"),this._network=null,this._options=null}attach(t,e){super.attach(t,e),this._network=new o.default(null!=e?e:{})}getDataAsync(t,e,n){return this._getDataAsyncImpl(t,(0,i._normalizeUser)(e,this._options),n)}prefetchData(t,e){return this._prefetchDataImpl(t,e)}setData(t){let e=(0,i._typedJsonParse)(t,"has_updates","data");e&&"user"in e?super.setData(t,e.user):i.Log.error("StatsigUser not found")}setDataLegacy(t,e){super.setData(t,e)}_fetchFromNetwork(t,e,n){var i;return r(this,void 0,void 0,function*(){let r=yield null===(i=this._network)||void 0===i?void 0:i.fetchEvaluations(this._getSdkKey(),t,null==n?void 0:n.priority,e);return null!=r?r:null})}_getCacheKey(t){var e;let n=(0,i._getStorageKey)(this._getSdkKey(),t,null===(e=this._options)||void 0===e?void 0:e.customUserCacheKeyFunc);return`${i.DataAdapterCachePrefix}.${this._cacheSuffix}.${n}`}_isCachedResultValidFor204(t,e){return null!=t.fullUserHash&&t.fullUserHash===(0,i._getFullUserHash)(e)}}e.StatsigEvaluationsDataAdapter=a},74636:function(t,e,n){"use strict";e.my=void 0;let r=n(66038);e.my=r.default,__STATSIG__=Object.assign(Object.assign({},null!=__STATSIG__?__STATSIG__:{}),{StatsigClient:r.default})},49668:function(t,e,n){"use strict";n.d(e,{v4:function(){return a}});for(var r,i=256,o=[];i--;)o[i]=(i+256).toString(16).substring(1);function a(){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],6==e?n+=o[15&t|64]:8==e?n+=o[63&t|128]:n+=o[t],1&e&&e>1&&e<11&&(n+="-");return i++,n}},1395:function(t,e,n){"use strict";function r(t,e,n){if(!e.has(t))throw TypeError("attempted to "+n+" private field on non-instance");return e.get(t)}n.d(e,{J:function(){return r}})},6151:function(t,e,n){"use strict";n.d(e,{_:function(){return i}});var r=n(1395);function i(t,e){var n=(0,r.J)(t,e,"get");return n.get?n.get.call(t):n.value}},16244:function(t,e,n){"use strict";function r(t,e,n){!function(t,e){if(e.has(t))throw TypeError("Cannot initialize the same private elements twice on an object")}(t,e),e.set(t,n)}n.d(e,{_:function(){return r}})},49778:function(t,e,n){"use strict";n.d(e,{_:function(){return i}});var r=n(1395);function i(t,e,n){var i=(0,r.J)(t,e,"set");return!function(t,e,n){if(e.set)e.set.call(t,n);else{if(!e.writable)throw TypeError("attempted to set read only private field");e.value=n}}(t,i,n),n}},44839:function(t,e,n){"use strict";function r(){for(var t,e,n=0,r="",i=arguments.length;ne.indexOf(r)&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols)for(var i=0,r=Object.getOwnPropertySymbols(t);ie.indexOf(r[i])&&Object.prototype.propertyIsEnumerable.call(t,r[i])&&(n[r[i]]=t[r[i]]);return n}function s(t,e,n,r){return new(n||(n=Promise))(function(i,o){function a(t){try{u(r.next(t))}catch(t){o(t)}}function s(t){try{u(r.throw(t))}catch(t){o(t)}}function u(t){var e;t.done?i(t.value):((e=t.value)instanceof n?e:new n(function(t){t(e)})).then(a,s)}u((r=r.apply(t,e||[])).next())})}function u(t,e){var n,r,i,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]},a=Object.create(("function"==typeof Iterator?Iterator:Object).prototype);return a.next=s(0),a.throw=s(1),a.return=s(2),"function"==typeof Symbol&&(a[Symbol.iterator]=function(){return this}),a;function s(s){return function(u){return function(s){if(n)throw TypeError("Generator is already executing.");for(;a&&(a=0,s[0]&&(o=0)),o;)try{if(n=1,r&&(i=2&s[0]?r.return:s[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,s[1])).done)return i;switch(r=0,i&&(s=[2&s[0],i.value]),s[0]){case 0:case 1:i=s;break;case 4:return o.label++,{value:s[1],done:!1};case 5:o.label++,r=s[1],s=[0];continue;case 7:s=o.ops.pop(),o.trys.pop();continue;default:if(!(i=(i=o.trys).length>0&&i[i.length-1])&&(6===s[0]||2===s[0])){o=0;continue}if(3===s[0]&&(!i||s[1]>i[0]&&s[1]d){a=t.lastIndexOf(";",s-1)+1;continue}var f=u(t,a,s),h=c(t,s,f),p=t.slice(f,h);if(!e.call(r,p)){var v=u(t,s+1,d),g=c(t,d,v);34===t.charCodeAt(v)&&34===t.charCodeAt(g-1)&&(v++,g--);var m=t.slice(v,g);r[p]=function(t,e){try{return e(t)}catch(e){return t}}(m,o)}a=d+1}while(an;){var r=t.charCodeAt(--e);if(32!==r&&9!==r)return e+1}return n}function l(t){return -1!==t.indexOf("%")?decodeURIComponent(t):t}return i}();function a(t,e={}){let n=t&&"j"===t[0]&&":"===t[1]?t.substr(2):t;if(!e.doNotParse)try{return JSON.parse(n)}catch(t){}return t}class s{constructor(t,e={}){var n;this.changeListeners=[],this.HAS_DOCUMENT_COOKIE=!1,this.update=()=>{if(!this.HAS_DOCUMENT_COOKIE)return;let t=this.cookies;this.cookies=o.parse(document.cookie),this._checkChanges(t)};let r="undefined"==typeof document?"":document.cookie;this.cookies="string"==typeof(n=t||r)?o.parse(n):"object"==typeof n&&null!==n?n:{},this.defaultSetOptions=e,this.HAS_DOCUMENT_COOKIE=function(){let t="undefined"==typeof global?void 0:global.TEST_HAS_DOCUMENT_COOKIE;return"boolean"==typeof t?t:"object"==typeof document&&"string"==typeof document.cookie}()}_emitChange(t){for(let e=0;e{t[e]!==this.cookies[e]&&this._emitChange({name:e,value:a(this.cookies[e])})})}_startPolling(){this.pollingInterval=setInterval(this.update,300)}_stopPolling(){this.pollingInterval&&clearInterval(this.pollingInterval)}get(t,e={}){return e.doNotUpdate||this.update(),a(this.cookies[t],e)}getAll(t={}){t.doNotUpdate||this.update();let e={};for(let n in this.cookies)e[n]=a(this.cookies[n],t);return e}set(t,e,n){n=n?Object.assign(Object.assign({},this.defaultSetOptions),n):this.defaultSetOptions;let r="string"==typeof e?e:JSON.stringify(e);this.cookies=Object.assign(Object.assign({},this.cookies),{[t]:r}),this.HAS_DOCUMENT_COOKIE&&(document.cookie=o.serialize(t,r,n)),this._emitChange({name:t,value:e,options:n})}remove(t,e){let n=e=Object.assign(Object.assign(Object.assign({},this.defaultSetOptions),e),{expires:new Date(1970,1,1,0,0,1),maxAge:0});this.cookies=Object.assign({},this.cookies),delete this.cookies[t],this.HAS_DOCUMENT_COOKIE&&(document.cookie=o.serialize(t,"",n)),this._emitChange({name:t,value:void 0,options:e})}addChangeListener(t){this.changeListeners.push(t),this.HAS_DOCUMENT_COOKIE&&1===this.changeListeners.length&&("object"==typeof window&&"cookieStore"in window?window.cookieStore.addEventListener("change",this.update):this._startPolling())}removeChangeListener(t){let e=this.changeListeners.indexOf(t);e>=0&&this.changeListeners.splice(e,1),this.HAS_DOCUMENT_COOKIE&&0===this.changeListeners.length&&("object"==typeof window&&"cookieStore"in window?window.cookieStore.removeEventListener("change",this.update):this._stopPolling())}}},29869:function(t){"use strict";t.exports=JSON.parse('{"Z":{"L":["af","af-NA","am","ar","ar-AE","ar-BH","ar-DJ","ar-DZ","ar-EG","ar-EH","ar-ER","ar-IL","ar-IQ","ar-JO","ar-KM","ar-KW","ar-LB","ar-LY","ar-MA","ar-MR","ar-OM","ar-PS","ar-QA","ar-SA","ar-SD","ar-SO","ar-SS","ar-SY","ar-TD","ar-TN","ar-YE","as","az","az-Latn","be","be-tarask","bg","bn","bn-IN","bs","bs-Latn","ca","ca-AD","ca-ES-valencia","ca-FR","ca-IT","chr","cs","cy","da","da-GL","de","de-AT","de-BE","de-CH","de-IT","de-LI","de-LU","dsb","el","el-CY","el-polyton","en","en-001","en-150","en-AE","en-AG","en-AI","en-AS","en-AT","en-AU","en-BB","en-BE","en-BI","en-BM","en-BS","en-BW","en-BZ","en-CA","en-CC","en-CH","en-CK","en-CM","en-CX","en-CY","en-DE","en-DG","en-DK","en-DM","en-ER","en-FI","en-FJ","en-FK","en-FM","en-GB","en-GD","en-GG","en-GH","en-GI","en-GM","en-GU","en-GY","en-HK","en-ID","en-IE","en-IL","en-IM","en-IN","en-IO","en-JE","en-JM","en-KE","en-KI","en-KN","en-KY","en-LC","en-LR","en-LS","en-MG","en-MH","en-MO","en-MP","en-MS","en-MT","en-MU","en-MV","en-MW","en-MY","en-NA","en-NF","en-NG","en-NL","en-NR","en-NU","en-NZ","en-PG","en-PH","en-PK","en-PN","en-PR","en-PW","en-RW","en-SB","en-SC","en-SD","en-SE","en-SG","en-SH","en-SI","en-SL","en-SS","en-SX","en-SZ","en-TC","en-TK","en-TO","en-TT","en-TV","en-TZ","en-UG","en-UM","en-VC","en-VG","en-VI","en-VU","en-WS","en-ZA","en-ZM","en-ZW","es","es-419","es-AR","es-BO","es-BR","es-BZ","es-CL","es-CO","es-CR","es-CU","es-DO","es-EA","es-EC","es-GQ","es-GT","es-HN","es-IC","es-MX","es-NI","es-PA","es-PE","es-PH","es-PR","es-PY","es-SV","es-US","es-UY","es-VE","et","eu","fa","fa-AF","fi","fil","fr","fr-BE","fr-BF","fr-BI","fr-BJ","fr-BL","fr-CA","fr-CD","fr-CF","fr-CG","fr-CH","fr-CI","fr-CM","fr-DJ","fr-DZ","fr-GA","fr-GF","fr-GN","fr-GP","fr-GQ","fr-HT","fr-KM","fr-LU","fr-MA","fr-MC","fr-MF","fr-MG","fr-ML","fr-MQ","fr-MR","fr-MU","fr-NC","fr-NE","fr-PF","fr-PM","fr-RE","fr-RW","fr-SC","fr-SN","fr-SY","fr-TD","fr-TG","fr-TN","fr-VU","fr-WF","fr-YT","ga","ga-GB","gd","gl","gu","ha","ha-GH","ha-NE","he","hi","hi-Latn","hr","hr-BA","hsb","hu","hy","id","ig","is","it","it-CH","it-SM","it-VA","ja","jv","ka","kk","km","kn","ko","ko-CN","ko-KP","kok","ky","lo","lt","lv","mk","ml","mn","mr","ms","ms-BN","ms-ID","ms-SG","my","nb","nb-SJ","ne","ne-IN","nl","nl-AW","nl-BE","nl-BQ","nl-CW","nl-SR","nl-SX","nn","no","or","pa","pa-Guru","pl","ps","ps-PK","pt","pt-AO","pt-CH","pt-CV","pt-GQ","pt-GW","pt-LU","pt-MO","pt-MZ","pt-PT","pt-ST","pt-TL","ro","ro-MD","ru","ru-BY","ru-KG","ru-KZ","ru-MD","ru-UA","sd","sd-Arab","si","sk","sl","so","so-DJ","so-ET","so-KE","sq","sq-MK","sq-XK","sr","sr-Cyrl","sr-Cyrl-BA","sr-Cyrl-ME","sr-Cyrl-XK","sr-Latn","sr-Latn-BA","sr-Latn-ME","sr-Latn-XK","sv","sv-AX","sv-FI","sw","sw-CD","sw-KE","sw-UG","ta","ta-LK","ta-MY","ta-SG","te","th","tk","tr","tr-CY","uk","und","ur","ur-IN","uz","uz-Latn","vi","yo","yo-BJ","yue","yue-Hans","yue-Hant","zh","zh-Hans","zh-Hans-HK","zh-Hans-MO","zh-Hans-SG","zh-Hant","zh-Hant-HK","zh-Hant-MO","zu"]}}')}}]);