@icanbwell/composite 1.620.0 → 1.622.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/170.index.js +3 -1
- package/170.index.js.map +1 -0
- package/279.index.js +2 -0
- package/279.index.js.map +1 -0
- package/311.index.js +2 -0
- package/311.index.js.map +1 -0
- package/{25.index.js → 878.index.js} +459 -450
- package/878.index.js.map +1 -0
- package/index.js +4 -2
- package/index.js.map +1 -0
- package/native.js +1 -1
- package/package.json +3 -3
package/170.index.js
CHANGED
|
@@ -15,7 +15,7 @@ ${JSON.stringify(i)}
|
|
|
15
15
|
Reason: ${g}`))})}_process(t){this._numProcessing++,t.then(n=>(this._numProcessing--,n),n=>(this._numProcessing--,n))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[s,o]=n.split(":");return{reason:s,category:o,quantity:r}})}_flushOutcomes(){_&&p.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){_&&p.log("No outcomes to send");return}if(!this._dsn){_&&p.log("No dsn provided, will not send outcomes");return}_&&p.log("Sending outcomes:",t);const n=Oo(t,this._options.tunnel&&Ae(this._dsn));this.sendEnvelope(n)}}function xo(e,t){const n=`${t} must return \`null\` or a valid event.`;if(Ee(e))return e.then(r=>{if(!ee(r)&&r!==null)throw new x(n);return r},r=>{throw new x(`${t} rejected with ${r}`)});if(!ee(e)&&e!==null)throw new x(n);return e}function Co(e,t,n,r){const{beforeSend:s,beforeSendTransaction:o,beforeSendSpan:i}=t;if(Bn(n)&&s)return s(n,r);if(Hn(n)){if(n.spans&&i){const a=[];for(const c of n.spans){const l=i(c);l?a.push(l):(hs(),e.recordDroppedEvent("before_send","span"))}n.spans=a}if(o){if(n.spans){const a=n.spans.length;n.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:a}}return o(n,r)}}return n}function Bn(e){return e.type===void 0}function Hn(e){return e.type==="transaction"}function Jc(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function Do(){return"npm"}function Ao(e,t,n=[t],r="npm"){const s=e._metadata||{};s.sdk||(s.sdk={name:`sentry.javascript.${t}`,packages:n.map(o=>({name:`${r}:@sentry/${o}`,version:$})),version:$}),e._metadata=s}const he=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__;function lt(e,t){const n=dt(e,t),r={type:Uo(t),value:$o(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function Po(e,t,n,r){const s=E(),o=s&&s.getOptions().normalizeDepth,i=zo(t),a={__serialized__:un(t,o)};if(i)return{exception:{values:[lt(e,i)]},extra:a};const c={exception:{values:[{type:ye(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:Ho(t,{isUnhandledRejection:r})}]},extra:a};if(n){const l=dt(e,n);l.length&&(c.exception.values[0].stacktrace={frames:l})}return c}function ft(e,t){return{exception:{values:[lt(e,t)]}}}function dt(e,t){const n=t.stacktrace||t.stack||"",r=Lo(t),s=jo(t);try{return e(n,r,s)}catch{}return[]}const Mo=/Minified React error #\d+;/i;function Lo(e){return e&&Mo.test(e.message)?1:0}function jo(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function Gn(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function Uo(e){const t=e&&e.name;return!t&&Gn(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function $o(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:Gn(e)&&Array.isArray(e.message)&&e.message.length==2?e.message[1]:t:"No error message"}function Fo(e,t,n,r){const s=n&&n.syntheticException||void 0,o=pt(e,t,s,r);return re(o),o.level="error",n&&n.event_id&&(o.event_id=n.event_id),z(o)}function Bo(e,t,n="info",r,s){const o=r&&r.syntheticException||void 0,i=ht(e,t,o,s);return i.level=n,r&&r.event_id&&(i.event_id=r.event_id),z(i)}function pt(e,t,n,r,s){let o;if($t(t)&&t.error)return ft(e,t.error);if(Ft(t)||hr(t)){const i=t;if("stack"in t)o=ft(e,t);else{const a=i.name||(Ft(i)?"DOMError":"DOMException"),c=i.message?`${a}: ${i.message}`:a;o=ht(e,c,n,r),Ke(o,c)}return"code"in i&&(o.tags={...o.tags,"DOMException.code":`${i.code}`}),o}return Ge(t)?ft(e,t):ee(t)||ye(t)?(o=Po(e,t,n,s),re(o,{synthetic:!0}),o):(o=ht(e,t,n,r),Ke(o,`${t}`,void 0),re(o,{synthetic:!0}),o)}function ht(e,t,n,r){const s={};if(r&&n){const o=dt(e,n);o.length&&(s.exception={values:[{value:t,stacktrace:{frames:o}}]}),re(s,{synthetic:!0})}if(ze(t)){const{__sentry_template_string__:o,__sentry_template_values__:i}=t;return s.logentry={message:o,params:i},s}return s.message=t,s}function Ho(e,{isUnhandledRejection:t}){const n=wr(e),r=t?"promise rejection":"exception";return $t(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:ye(e)?`Event \`${Go(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function Go(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function zo(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}const y=m;let gt=0;function zn(){return gt>0}function Wo(){gt++,setTimeout(()=>{gt--})}function ie(e,t={}){function n(s){return typeof s=="function"}if(!n(e))return e;try{const s=e.__sentry_wrapped__;if(s)return typeof s=="function"?s:e;if(Ye(e))return e}catch{return e}const r=function(...s){try{const o=s.map(i=>ie(i,t));return e.apply(this,o)}catch(o){throw Wo(),Fr(i=>{i.addEventProcessor(a=>(t.mechanism&&(Ke(a,void 0,void 0),re(a,t.mechanism)),a.extra={...a.extra,arguments:s},a)),bn(o)}),o}};try{for(const s in e)Object.prototype.hasOwnProperty.call(e,s)&&(r[s]=e[s])}catch{}zt(r,e),G(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}function qo(e,{metadata:t,tunnel:n,dsn:r}){const s={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!n&&!!r&&{dsn:Ae(r)}},o=Yo(e);return pe(s,[o])}function Yo(e){return[{type:"user_report"},e]}class Jo extends Ro{constructor(t){const n={parentSpanIsAlwaysRootSpan:!0,...t},r=y.SENTRY_SDK_SOURCE||Do();Ao(n,"browser",["browser"],r),super(n),n.sendClientReports&&y.document&&y.document.addEventListener("visibilitychange",()=>{y.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,n){return Fo(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return Bo(this._options.stackParser,t,n,r,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){he&&p.warn("SDK not enabled, will not capture user feedback.");return}const n=qo(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(n)}_prepareEvent(t,n,r){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r)}}const ae={},Wn={};function q(e,t){ae[e]=ae[e]||[],ae[e].push(t)}function Kc(){Object.keys(ae).forEach(e=>{ae[e]=void 0})}function Y(e,t){if(!Wn[e]){Wn[e]=!0;try{t()}catch(n){B&&p.error(`Error while instrumenting ${e}`,n)}}}function O(e,t){const n=e&&ae[e];if(!!n)for(const r of n)try{r(t)}catch(s){B&&p.error(`Error while triggering instrumentation handler.
|
|
16
16
|
Type: ${e}
|
|
17
17
|
Name: ${j(r)}
|
|
18
|
-
Error:`,s)}}const b=m,Ko=1e3;let qn,mt,_t;function Xo(e){const t="dom";q(t,e),Y(t,Vo)}function Vo(){if(!b.document)return;const e=O.bind(null,"dom"),t=Yn(e,!0);b.document.addEventListener("click",t,!1),b.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const s=b[n],o=s&&s.prototype;!o||!o.hasOwnProperty||!o.hasOwnProperty("addEventListener")||(v(o,"addEventListener",function(i){return function(a,c,l){if(a==="click"||a=="keypress")try{const f=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},u=f[a]=f[a]||{refCount:0};if(!u.handler){const d=Yn(e);u.handler=d,i.call(this,a,d,l)}u.refCount++}catch{}return i.call(this,a,c,l)}}),v(o,"removeEventListener",function(i){return function(a,c,l){if(a==="click"||a=="keypress")try{const f=this.__sentry_instrumentation_handlers__||{},u=f[a];u&&(u.refCount--,u.refCount<=0&&(i.call(this,a,u.handler,l),u.handler=void 0,delete f[a]),Object.keys(f).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return i.call(this,a,c,l)}}))})}function Zo(e){if(e.type!==mt)return!1;try{if(!e.target||e.target._sentryId!==_t)return!1}catch{}return!0}function Qo(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function Yn(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=ei(n);if(Qo(n.type,r))return;G(n,"_sentryCaptured",!0),r&&!r._sentryId&&G(r,"_sentryId",w());const s=n.type==="keypress"?"input":n.type;Zo(n)||(e({event:n,name:s,global:t}),mt=n.type,_t=r?r._sentryId:void 0),clearTimeout(qn),qn=b.setTimeout(()=>{_t=void 0,mt=void 0},Ko)}}function ei(e){try{return e.target}catch{return null}}const ge="__sentry_xhr_v3__";function ti(e){const t="xhr";q(t,e),Y(t,ni)}function ni(){if(!b.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const s=new Error,o=D()*1e3,i=C(r[0])?r[0].toUpperCase():void 0,a=ri(r[1]);if(!i||!a)return t.apply(n,r);n[ge]={method:i,url:a,request_headers:{}},i==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const l=n[ge];if(!!l&&n.readyState===4){try{l.status_code=n.status}catch{}const f={endTimestamp:D()*1e3,startTimestamp:o,xhr:n,virtualError:s};O("xhr",f)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(l,f,u){return c(),l.apply(f,u)}}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(l,f,u){const[d,h]=u,g=f[ge];return g&&C(d)&&C(h)&&(g.request_headers[d.toLowerCase()]=h),l.apply(f,u)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const s=n[ge];if(!s)return t.apply(n,r);r[0]!==void 0&&(s.body=r[0]);const o={startTimestamp:D()*1e3,xhr:n};return O("xhr",o),t.apply(n,r)}})}function ri(e){if(C(e))return e;try{return e.toString()}catch{}}const Me=m;function si(){const e=Me.chrome,t=e&&e.app&&e.app.runtime,n="history"in Me&&!!Me.history.pushState&&!!Me.history.replaceState;return!t&&n}let Le;function Jn(e){const t="history";q(t,e),Y(t,oi)}function oi(){if(!si())return;const e=b.onpopstate;b.onpopstate=function(...n){const r=b.location.href,s=Le;if(Le=r,O("history",{from:s,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){const s=r.length>2?r[2]:void 0;if(s){const o=Le,i=String(s);Le=i,O("history",{from:o,to:i})}return n.apply(this,r)}}v(b.history,"pushState",t),v(b.history,"replaceState",t)}function ii(e){const t="console";q(t,e),Y(t,ai)}function ai(){"console"in m&&qe.forEach(function(e){e in m.console&&v(m.console,e,function(t){return Se[e]=t,function(...n){O("console",{args:n,level:e});const s=Se[e];s&&s.apply(m.console,n)}})})}function ci(e,t){const n="fetch";q(n,e),Y(n,()=>Kn(void 0,t))}function Xc(e){const t="fetch-body-resolved";addHandler(t,e),maybeInstrument(t,()=>Kn(li))}function Kn(e,t=!1){t&&!so()||v(m,"fetch",function(n){return function(...r){const s=new Error,{method:o,url:i}=fi(r),a={args:r,fetchData:{method:o,url:i},startTimestamp:D()*1e3,virtualError:s};return e||O("fetch",{...a}),n.apply(m,r).then(async c=>(e?e(c):O("fetch",{...a,endTimestamp:D()*1e3,response:c}),c),c=>{throw O("fetch",{...a,endTimestamp:D()*1e3,error:c}),Ge(c)&&c.stack===void 0&&(c.stack=s.stack,G(c,"framesToPop",1)),c})}})}async function ui(e,t){if(e&&e.body){const n=e.body,r=n.getReader(),s=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let o=!0;for(;o;){let i;try{i=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(i),a&&(t(),o=!1)}catch{o=!1}finally{clearTimeout(i)}}clearTimeout(s),r.releaseLock(),n.cancel().then(null,()=>{})}}function li(e){let t;try{t=e.clone()}catch{return}ui(t,()=>{triggerHandlers("fetch-body-resolved",{endTimestamp:timestampInSeconds()*1e3,response:e})})}function yt(e,t){return!!e&&typeof e=="object"&&!!e[t]}function Xn(e){return typeof e=="string"?e:e?yt(e,"url")?e.url:e.toString?e.toString():"":""}function fi(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:Xn(n),method:yt(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:Xn(t),method:yt(t,"method")?String(t.method).toUpperCase():"GET"}}const di=100;function J(e,t){const n=E(),r=de();if(!n)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:o=di}=n.getOptions();if(o<=0)return;const a={timestamp:fe(),...e},c=s?H(()=>s(a,t)):a;c!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",c,t),r.addBreadcrumb(c,o))}const Vc=null;function pi(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}function Vn(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}function Et(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Zc(e){return e.split(/[?#]/,1)[0]}function Qc(e){return e.split(/\\?\//).filter(t=>t.length>0&&t!==",").length}function eu(e){const{protocol:t,host:n,path:r}=e,s=n&&n.replace(/^.*@/,"[filtered]:[filtered]@").replace(/(:80)$/,"").replace(/(:443)$/,"")||"";return`${t?`${t}://`:""}${s}${r}`}const je=1024,hi="Breadcrumbs",gi=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:hi,setup(n){t.console&&ii(yi(n)),t.dom&&Xo(_i(n,t.dom)),t.xhr&&ti(Ei(n)),t.fetch&&ci(Si(n)),t.history&&Jn(bi(n)),t.sentry&&n.on("beforeSendEvent",mi(n))}}};function mi(e){return function(n){E()===e&&J({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:M(n)},{event:n})}}function _i(e,t){return function(r){if(E()!==e)return;let s,o,i=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>je&&(he&&p.warn(`\`dom.maxStringLength\` cannot exceed ${je}, but a value of ${a} was configured. Sentry will use ${je} instead.`),a=je),typeof i=="string"&&(i=[i]);try{const l=r.event,f=vi(l)?l.target:l;s=Ht(f,{keyAttrs:i,maxStringLength:a}),o=br(f)}catch{s="<unknown>"}if(s.length===0)return;const c={category:`ui.${r.name}`,message:s};o&&(c.data={"ui.component_name":o}),J(c,{event:r.event,name:r.name,global:r.global})}}function yi(e){return function(n){if(E()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:pi(n.level),message:Gt(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${Gt(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;J(r,{input:n.args,level:n.level})}}function Ei(e){return function(n){if(E()!==e)return;const{startTimestamp:r,endTimestamp:s}=n,o=n.xhr[ge];if(!r||!s||!o)return;const{method:i,url:a,status_code:c,body:l}=o,f={method:i,url:a,status_code:c},u={xhr:n.xhr,input:l,startTimestamp:r,endTimestamp:s},d=Vn(c);J({category:"xhr",data:f,type:"http",level:d},u)}}function Si(e){return function(n){if(E()!==e)return;const{startTimestamp:r,endTimestamp:s}=n;if(!!s&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.error){const o=n.fetchData,i={data:n.error,input:n.args,startTimestamp:r,endTimestamp:s};J({category:"fetch",data:o,level:"error",type:"http"},i)}else{const o=n.response,i={...n.fetchData,status_code:o&&o.status},a={input:n.args,response:o,startTimestamp:r,endTimestamp:s},c=Vn(i.status_code);J({category:"fetch",data:i,type:"http",level:c},a)}}}function bi(e){return function(n){if(E()!==e)return;let r=n.from,s=n.to;const o=Et(y.location.href);let i=r?Et(r):void 0;const a=Et(s);(!i||!i.path)&&(i=o),o.protocol===a.protocol&&o.host===a.host&&(s=a.relative),o.protocol===i.protocol&&o.host===i.host&&(r=i.relative),J({category:"navigation",data:{from:r,to:s}})}}function vi(e){return!!e&&!!e.target}const Ti=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],Ii="BrowserApiErrors",wi=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:Ii,setupOnce(){t.setTimeout&&v(y,"setTimeout",Zn),t.setInterval&&v(y,"setInterval",Zn),t.requestAnimationFrame&&v(y,"requestAnimationFrame",ki),t.XMLHttpRequest&&"XMLHttpRequest"in y&&v(XMLHttpRequest.prototype,"send",Oi);const n=t.eventTarget;n&&(Array.isArray(n)?n:Ti).forEach(Ni)}}};function Zn(e){return function(...t){const n=t[0];return t[0]=ie(n,{mechanism:{data:{function:j(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function ki(e){return function(t){return e.apply(this,[ie(t,{mechanism:{data:{function:"requestAnimationFrame",handler:j(e)},handled:!1,type:"instrument"}})])}}function Oi(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in n&&typeof n[s]=="function"&&v(n,s,function(o){const i={mechanism:{data:{function:s,handler:j(o)},handled:!1,type:"instrument"}},a=Ye(o);return a&&(i.mechanism.data.handler=j(a)),ie(o,i)})}),e.apply(this,t)}}function Ni(e){const n=y[e],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(v(r,"addEventListener",function(s){return function(o,i,a){try{Ri(i)&&(i.handleEvent=ie(i.handleEvent,{mechanism:{data:{function:"handleEvent",handler:j(i),target:e},handled:!1,type:"instrument"}}))}catch{}return s.apply(this,[o,ie(i,{mechanism:{data:{function:"addEventListener",handler:j(i),target:e},handled:!1,type:"instrument"}}),a])}}),v(r,"removeEventListener",function(s){return function(o,i,a){try{const c=i.__sentry_wrapped__;c&&s.call(this,o,c,a)}catch{}return s.call(this,o,i,a)}}))}function Ri(e){return typeof e.handleEvent=="function"}const xi=()=>({name:"BrowserSession",setupOnce(){if(typeof y.document>"u"){he&&p.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}In({ignoreDuration:!0}),On(),Jn(({from:e,to:t})=>{e!==void 0&&e!==t&&(In({ignoreDuration:!0}),On())})}});let St=null;function Ci(e){const t="error";q(t,e),Y(t,Di)}function Di(){St=m.onerror,m.onerror=function(e,t,n,r,s){return O("error",{column:r,error:s,line:n,msg:e,url:t}),St?St.apply(this,arguments):!1},m.onerror.__SENTRY_INSTRUMENTED__=!0}let bt=null;function Ai(e){const t="unhandledrejection";q(t,e),Y(t,Pi)}function Pi(){bt=m.onunhandledrejection,m.onunhandledrejection=function(e){return O("unhandledrejection",e),bt?bt.apply(this,arguments):!0},m.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const Mi="GlobalHandlers",Li=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:Mi,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(ji(n),Qn("onerror")),t.onunhandledrejection&&(Ui(n),Qn("onunhandledrejection"))}}};function ji(e){Ci(t=>{const{stackParser:n,attachStacktrace:r}=er();if(E()!==e||zn())return;const{msg:s,url:o,line:i,column:a,error:c}=t,l=Bi(pt(n,c||s,void 0,r,!1),o,i,a);l.level="error",vn(l,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function Ui(e){Ai(t=>{const{stackParser:n,attachStacktrace:r}=er();if(E()!==e||zn())return;const s=$i(t),o=We(s)?Fi(s):pt(n,s,void 0,r,!0);o.level="error",vn(o,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function $i(e){if(We(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function Fi(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Bi(e,t,n,r){const s=e.exception=e.exception||{},o=s.values=s.values||[],i=o[0]=o[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],l=r,f=n,u=C(t)&&t.length>0?t:Sr();return c.length===0&&c.push({colno:l,filename:u,function:R,in_app:!0,lineno:f}),e}function Qn(e){he&&p.log(`Global Handler attached: ${e}`)}function er(){const e=E();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Hi=()=>({name:"HttpContext",preprocessEvent(e){if(!y.navigator&&!y.location&&!y.document)return;const t=e.request&&e.request.url||y.location&&y.location.href,{referrer:n}=y.document||{},{userAgent:r}=y.navigator||{},s={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},o={...e.request,...t&&{url:t},headers:s};e.request=o}});function Gi(e,t,n=250,r,s,o,i){if(!o.exception||!o.exception.values||!i||!F(i.originalException,Error))return;const a=o.exception.values.length>0?o.exception.values[o.exception.values.length-1]:void 0;a&&(o.exception.values=zi(vt(e,t,s,i.originalException,r,o.exception.values,a,0),n))}function vt(e,t,n,r,s,o,i,a){if(o.length>=n+1)return o;let c=[...o];if(F(r[s],Error)){tr(i,a);const l=e(t,r[s]),f=c.length;nr(l,s,f,a),c=vt(e,t,n,r[s],s,[l,...c],l,f)}return Array.isArray(r.errors)&&r.errors.forEach((l,f)=>{if(F(l,Error)){tr(i,a);const u=e(t,l),d=c.length;nr(u,`errors[${f}]`,d,a),c=vt(e,t,n,l,s,[u,...c],u,d)}}),c}function tr(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function nr(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function zi(e,t){return e.map(n=>(n.value&&(n.value=ne(n.value,t)),n))}const Wi="cause",qi=5,Yi="LinkedErrors",Ji=(e={})=>{const t=e.limit||qi,n=e.key||Wi;return{name:Yi,preprocessEvent(r,s,o){const i=o.getOptions();Gi(lt,i.stackParser,i.maxValueLength,n,t,r,s)}}},Ki=10,Xi=20,Vi=30,Zi=40,Qi=50;function ce(e,t,n,r){const s={filename:e,function:t==="<anonymous>"?R:t,in_app:!0};return n!==void 0&&(s.lineno=n),r!==void 0&&(s.colno=r),s}const ea=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,ta=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,na=/\((\S*)(?::(\d+))(?::(\d+))\)/,ra=[Vi,e=>{const t=ea.exec(e);if(t){const[,r,s,o]=t;return ce(r,R,+s,+o)}const n=ta.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const i=na.exec(n[2]);i&&(n[2]=i[1],n[3]=i[2],n[4]=i[3])}const[s,o]=rr(n[1]||R,n[2]);return ce(o,s,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}}],sa=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,oa=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,ia=[Qi,e=>{const t=sa.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const o=oa.exec(t[3]);o&&(t[1]=t[1]||"eval",t[3]=o[1],t[4]=o[2],t[5]="")}let r=t[3],s=t[1]||R;return[s,r]=rr(s,r),ce(r,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],aa=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,cu=[Zi,e=>{const t=aa.exec(e);return t?ce(t[2],t[1]||R,+t[3],t[4]?+t[4]:void 0):void 0}],ca=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,lu=[Ki,e=>{const t=ca.exec(e);return t?ce(t[2],t[3]||R,+t[1]):void 0}],ua=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,du=[Xi,e=>{const t=ua.exec(e);return t?ce(t[5],t[3]||t[4]||R,+t[1],+t[2]):void 0}],la=an(...[ra,ia]),rr=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:R,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},fa=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Ue={};function Tt(e){const t=Ue[e];if(t)return t;let n=b[e];if(ct(n))return Ue[e]=n.bind(b);const r=b.document;if(r&&typeof r.createElement=="function")try{const s=r.createElement("iframe");s.hidden=!0,r.head.appendChild(s);const o=s.contentWindow;o&&o[e]&&(n=o[e]),r.head.removeChild(s)}catch(s){fa&&p.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,s)}return n&&(Ue[e]=n.bind(b))}function sr(e){Ue[e]=void 0}function hu(...e){return Tt("fetch")(...e)}function gu(...e){return Tt("setTimeout")(...e)}function da(e){const t=[];function n(){return e===void 0||t.length<e}function r(i){return t.splice(t.indexOf(i),1)[0]||Promise.resolve(void 0)}function s(i){if(!n())return we(new x("Not adding Promise because buffer limit was reached."));const a=i();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function o(i){return new k((a,c)=>{let l=t.length;if(!l)return a(!0);const f=setTimeout(()=>{i&&i>0&&a(!1)},i);t.forEach(u=>{z(u).then(()=>{--l||(clearTimeout(f),a(!0))},c)})})}return{$:t,add:s,drain:o}}const pa=60*1e3;function ha(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?pa:r-t}function ga(e,t){return e[t]||e.all||0}function ma(e,t,n=Date.now()){return ga(e,t)>n}function _a(e,{statusCode:t,headers:n},r=Date.now()){const s={...e},o=n&&n["x-sentry-rate-limits"],i=n&&n["retry-after"];if(o)for(const a of o.trim().split(",")){const[c,l,,,f]=a.split(":",5),u=parseInt(c,10),d=(isNaN(u)?60:u)*1e3;if(!l)s.all=r+d;else for(const h of l.split(";"))h==="metric_bucket"?(!f||f.split(";").includes("custom"))&&(s[h]=r+d):s[h]=r+d}else i?s.all=r+ha(i,r):t===429&&(s.all=r+60*1e3);return s}const ya=64;function Ea(e,t,n=da(e.bufferSize||ya)){let r={};const s=i=>n.drain(i);function o(i){const a=[];if(ut(i,(u,d)=>{const h=Un(d);if(ma(r,h)){const g=or(u,d);e.recordDroppedEvent("ratelimit_backoff",h,g)}else a.push(u)}),a.length===0)return z({});const c=pe(i[0],a),l=u=>{ut(c,(d,h)=>{const g=or(d,h);e.recordDroppedEvent(u,Un(h),g)})},f=()=>t({body:Eo(c)}).then(u=>(u.statusCode!==void 0&&(u.statusCode<200||u.statusCode>=300)&&_&&p.warn(`Sentry responded with status code ${u.statusCode} to sent event.`),r=_a(r,u),u),u=>{throw l("network_error"),u});return n.add(f).then(u=>u,u=>{if(u instanceof x)return _&&p.error("Skipped sending event because buffer is full."),l("queue_overflow"),z({});throw u})}return{send:o,flush:s}}function or(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function Sa(e,t=Tt("fetch")){let n=0,r=0;function s(o){const i=o.body.length;n+=i,r++;const a={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return sr("fetch"),we("No fetch implementation available");try{return t(e.url,a).then(c=>(n-=i,r--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return sr("fetch"),n-=i,r--,we(c)}}return Ea(e,s)}function ba(e){const t=[Fs(),Zs(),wi(),gi(),Li(),Ji(),eo(),Hi()];return e.autoSessionTracking!==!1&&t.push(xi()),t}function va(e={}){const t={defaultIntegrations:ba(e),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:y.SENTRY_RELEASE&&y.SENTRY_RELEASE.id?y.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return e.defaultIntegrations==null&&delete e.defaultIntegrations,{...t,...e}}function Ta(){const e=typeof y.window<"u"&&y;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,s=y.location&&y.location.href||"",o=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],i=!!r&&y===y.top&&o.some(c=>s.startsWith(`${c}//`)),a=typeof e.nw<"u";return!!r&&!i&&!a}function Ia(e={}){const t=va(e);if(!t.skipBrowserExtensionCheck&&Ta()){H(()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")});return}he&&(at()||p.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:Gr(t.stackParser||la),integrations:Ls(t),transport:t.transport||Sa};return oo(Jo,n)}function mu(e={}){if(!WINDOW.document){DEBUG_BUILD&&logger.error("Global document not defined in showReportDialog call");return}const t=getCurrentScope(),n=t.getClient(),r=n&&n.getDsn();if(!r){DEBUG_BUILD&&logger.error("DSN not configured for showReportDialog call");return}if(t&&(e.user={...t.getUser(),...e.user}),!e.eventId){const a=lastEventId();a&&(e.eventId=a)}const s=WINDOW.document.createElement("script");s.async=!0,s.crossOrigin="anonymous",s.src=getReportDialogEndpoint(r,e),e.onLoad&&(s.onload=e.onLoad);const{onClose:o}=e;if(o){const a=c=>{if(c.data==="__sentry_reportdialog_closed__")try{o()}finally{WINDOW.removeEventListener("message",a)}};WINDOW.addEventListener("message",a)}const i=WINDOW.document.head||WINDOW.document.body;i?i.appendChild(s):DEBUG_BUILD&&logger.error("Not injecting report dialog. No injection point found in HTML")}function _u(){}function yu(e){e()}function Eu(e){const t=getClient();t&&t.captureUserFeedback(e)}class wa{constructor(t){if(!Ps())Ia(Object.assign(Object.assign({environment:t.environment,dsn:t.dsn},t.appVersion&&{release:t.appVersion}),{beforeSend(n){var r;return!((r=n.extra)===null||r===void 0)&&r.log?n:null}}));else if(t.clientSlug!==void 0&&t.environment!==void 0){const n=en();n.clear(),n.setTag("client.slug",t.clientSlug),n.addEventProcessor(r=>new Promise(s=>s(Object.assign(Object.assign(Object.assign({},r),{environment:t.environment}),t.appVersion&&{release:t.appVersion}))))}}write(t){t.err?bn(t.err,{extra:{log:!0}}):t.msg&&As(t.msg,{extra:{log:!0}})}}function It(){return It=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},It.apply(this,arguments)}var ir=typeof window<"u"?window.navigator.userAgent:"no-window",ka=/bot|crawler|spider|crawling/i.test(ir),Oa={"Content-Type":"application/json"},Na=function(){function e(n){var r=this;n===void 0&&(n={});var s=n.method,o=s===void 0?"PUT":s,i=n.url,a=i===void 0?"/log":i,c=n.headers,l=c===void 0?{}:c,f=n.throttleInterval,u=f===void 0?3e3:f,d=n.withCredentials,h=d!==void 0&&d,g=n.onError,Z=n.flushOnClose,S=Z!==void 0&&Z,U=n.writeCondition;this.writeCondition=U===void 0?e.defaultWriteCondition:U,this.records={},this.headers=It({},Oa,l),this.start({method:o,url:a,throttleInterval:u,withCredentials:h,onError:g}),S&&window.fetch!==void 0&&window.addEventListener("beforeunload",function(){r.currentThrottleTimeout&&window.clearTimeout(r.currentThrottleTimeout);var le=r.recordsAsArray();le.length&&window.fetch(a,{method:o,body:JSON.stringify(le),headers:r.headers,credentials:h?"include":"same-origin",mode:"cors",keepalive:!0})},!1)}var t=e.prototype;return t.start=function(n){var r=this,s=n.method,o=n.url,i=n.throttleInterval,a=n.withCredentials,c=n.onError;(function l(){r.currentThrottleTimeout=setTimeout(function(){var f=r.recordsAsArray();if(f.length){var u=new XMLHttpRequest;u.onreadystatechange=function(){u.readyState===XMLHttpRequest.DONE&&(u.status>=400&&(typeof c=="function"?c.call(r,f,u):console.warn("Browser Bunyan: A server log write failed")),r.records={},l())},u.open(s,o);for(var d=0,h=Object.entries(r.headers);d<h.length;d++){var g=h[d];u.setRequestHeader(g[0],g[1])}u.withCredentials=a,u.send(JSON.stringify(f))}else l()},i)})()},t.stop=function(){var n=this;setTimeout(function(){n.currentThrottleTimeout&&(clearTimeout(n.currentThrottleTimeout),n.currentThrottleTimeout=null)},1)},t.write=function(n){n.url=typeof window<"u"&&window.location.href,n.userAgent=ir,this.currentThrottleTimeout&&this.writeCondition(n)&&(this.records[n.msg]?this.records[n.msg].count++:(n.count=1,this.records[n.msg]=n))},t.recordsAsArray=function(){var n=this;return Object.keys(this.records).map(function(r){return n.records[r]})},e.defaultWriteCondition=function(){return window.navigator.onLine&&!ka},e}(),Su=10,bu=20,vu=30,Tu=40,Iu=50,wu=60,wt={trace:10,debug:20,info:30,warn:40,error:50,fatal:60},ar={};function kt(e){return typeof e=="string"?wt[e.toLowerCase()]:e}function Ot(e,t){return Ot=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n},Ot(e,t)}function Ra(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Nt(e,t,n){return Nt=Ra()?Reflect.construct:function(r,s,o){var i=[null];i.push.apply(i,s);var a=new(Function.bind.apply(r,i));return o&&Ot(a,o.prototype),a},Nt.apply(null,arguments)}function K(e){if(e==null)return e;if(Array.isArray(e))return e.slice();if(typeof e=="object"){var t={};return Object.keys(e).forEach(function(n){t[n]=e[n]}),t}return e}function Rt(e){return e===void 0?"undefined":e===null?"null":Array.isArray(e)?"[ "+e.map(function(t){return Rt(t)}).join(", ")+" ]":typeof e=="object"?JSON.stringify(e):typeof e=="function"?"[Function: "+e.name+"]":typeof e=="boolean"||typeof e=="number"?e:"'"+e.toString()+"'"}function X(e){if(typeof e!="string"){for(var t=new Array(arguments.length),n=0;n<arguments.length;n++)t[n]=Rt(arguments[n]);return t.join(" ")}for(var r=/%[sdj%]/g,s=1,o=arguments,i=o.length,a=String(e).replace(r,function(l){if(l==="%%")return"%";if(s>=i)return l;switch(l){case"%s":return String(o[s++]);case"%d":return Number(o[s++]);case"%j":try{return JSON.stringify(o[s++])}catch{return"[Circular]"}default:return l}}),c=o[s];s<i;c=o[++s])a+=c===null||typeof c!="object"?" "+c:" "+Rt(c);return a}function xa(e,t){var n=e.split(`
|
|
18
|
+
Error:`,s)}}const b=m,Ko=1e3;let qn,mt,_t;function Xo(e){const t="dom";q(t,e),Y(t,Vo)}function Vo(){if(!b.document)return;const e=O.bind(null,"dom"),t=Yn(e,!0);b.document.addEventListener("click",t,!1),b.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const s=b[n],o=s&&s.prototype;!o||!o.hasOwnProperty||!o.hasOwnProperty("addEventListener")||(v(o,"addEventListener",function(i){return function(a,c,l){if(a==="click"||a=="keypress")try{const f=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},u=f[a]=f[a]||{refCount:0};if(!u.handler){const d=Yn(e);u.handler=d,i.call(this,a,d,l)}u.refCount++}catch{}return i.call(this,a,c,l)}}),v(o,"removeEventListener",function(i){return function(a,c,l){if(a==="click"||a=="keypress")try{const f=this.__sentry_instrumentation_handlers__||{},u=f[a];u&&(u.refCount--,u.refCount<=0&&(i.call(this,a,u.handler,l),u.handler=void 0,delete f[a]),Object.keys(f).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return i.call(this,a,c,l)}}))})}function Zo(e){if(e.type!==mt)return!1;try{if(!e.target||e.target._sentryId!==_t)return!1}catch{}return!0}function Qo(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function Yn(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=ei(n);if(Qo(n.type,r))return;G(n,"_sentryCaptured",!0),r&&!r._sentryId&&G(r,"_sentryId",w());const s=n.type==="keypress"?"input":n.type;Zo(n)||(e({event:n,name:s,global:t}),mt=n.type,_t=r?r._sentryId:void 0),clearTimeout(qn),qn=b.setTimeout(()=>{_t=void 0,mt=void 0},Ko)}}function ei(e){try{return e.target}catch{return null}}const ge="__sentry_xhr_v3__";function ti(e){const t="xhr";q(t,e),Y(t,ni)}function ni(){if(!b.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const s=new Error,o=D()*1e3,i=C(r[0])?r[0].toUpperCase():void 0,a=ri(r[1]);if(!i||!a)return t.apply(n,r);n[ge]={method:i,url:a,request_headers:{}},i==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const l=n[ge];if(!!l&&n.readyState===4){try{l.status_code=n.status}catch{}const f={endTimestamp:D()*1e3,startTimestamp:o,xhr:n,virtualError:s};O("xhr",f)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(l,f,u){return c(),l.apply(f,u)}}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(l,f,u){const[d,h]=u,g=f[ge];return g&&C(d)&&C(h)&&(g.request_headers[d.toLowerCase()]=h),l.apply(f,u)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const s=n[ge];if(!s)return t.apply(n,r);r[0]!==void 0&&(s.body=r[0]);const o={startTimestamp:D()*1e3,xhr:n};return O("xhr",o),t.apply(n,r)}})}function ri(e){if(C(e))return e;try{return e.toString()}catch{}}const Me=m;function si(){const e=Me.chrome,t=e&&e.app&&e.app.runtime,n="history"in Me&&!!Me.history.pushState&&!!Me.history.replaceState;return!t&&n}let Le;function Jn(e){const t="history";q(t,e),Y(t,oi)}function oi(){if(!si())return;const e=b.onpopstate;b.onpopstate=function(...n){const r=b.location.href,s=Le;if(Le=r,O("history",{from:s,to:r}),e)try{return e.apply(this,n)}catch{}};function t(n){return function(...r){const s=r.length>2?r[2]:void 0;if(s){const o=Le,i=String(s);Le=i,O("history",{from:o,to:i})}return n.apply(this,r)}}v(b.history,"pushState",t),v(b.history,"replaceState",t)}function ii(e){const t="console";q(t,e),Y(t,ai)}function ai(){"console"in m&&qe.forEach(function(e){e in m.console&&v(m.console,e,function(t){return Se[e]=t,function(...n){O("console",{args:n,level:e});const s=Se[e];s&&s.apply(m.console,n)}})})}function ci(e,t){const n="fetch";q(n,e),Y(n,()=>Kn(void 0,t))}function Xc(e){const t="fetch-body-resolved";addHandler(t,e),maybeInstrument(t,()=>Kn(li))}function Kn(e,t=!1){t&&!so()||v(m,"fetch",function(n){return function(...r){const s=new Error,{method:o,url:i}=fi(r),a={args:r,fetchData:{method:o,url:i},startTimestamp:D()*1e3,virtualError:s};return e||O("fetch",{...a}),n.apply(m,r).then(async c=>(e?e(c):O("fetch",{...a,endTimestamp:D()*1e3,response:c}),c),c=>{throw O("fetch",{...a,endTimestamp:D()*1e3,error:c}),Ge(c)&&c.stack===void 0&&(c.stack=s.stack,G(c,"framesToPop",1)),c})}})}async function ui(e,t){if(e&&e.body){const n=e.body,r=n.getReader(),s=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let o=!0;for(;o;){let i;try{i=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(i),a&&(t(),o=!1)}catch{o=!1}finally{clearTimeout(i)}}clearTimeout(s),r.releaseLock(),n.cancel().then(null,()=>{})}}function li(e){let t;try{t=e.clone()}catch{return}ui(t,()=>{triggerHandlers("fetch-body-resolved",{endTimestamp:timestampInSeconds()*1e3,response:e})})}function yt(e,t){return!!e&&typeof e=="object"&&!!e[t]}function Xn(e){return typeof e=="string"?e:e?yt(e,"url")?e.url:e.toString?e.toString():"":""}function fi(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:Xn(n),method:yt(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:Xn(t),method:yt(t,"method")?String(t.method).toUpperCase():"GET"}}const di=100;function J(e,t){const n=E(),r=de();if(!n)return;const{beforeBreadcrumb:s=null,maxBreadcrumbs:o=di}=n.getOptions();if(o<=0)return;const a={timestamp:fe(),...e},c=s?H(()=>s(a,t)):a;c!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",c,t),r.addBreadcrumb(c,o))}const Vc=null;function pi(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}function Vn(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}function Et(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function Zc(e){return e.split(/[?#]/,1)[0]}function Qc(e){return e.split(/\\?\//).filter(t=>t.length>0&&t!==",").length}function eu(e){const{protocol:t,host:n,path:r}=e,s=n&&n.replace(/^.*@/,"[filtered]:[filtered]@").replace(/(:80)$/,"").replace(/(:443)$/,"")||"";return`${t?`${t}://`:""}${s}${r}`}const je=1024,hi="Breadcrumbs",gi=(e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:hi,setup(n){t.console&&ii(yi(n)),t.dom&&Xo(_i(n,t.dom)),t.xhr&&ti(Ei(n)),t.fetch&&ci(Si(n)),t.history&&Jn(bi(n)),t.sentry&&n.on("beforeSendEvent",mi(n))}}};function mi(e){return function(n){E()===e&&J({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:M(n)},{event:n})}}function _i(e,t){return function(r){if(E()!==e)return;let s,o,i=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>je&&(he&&p.warn(`\`dom.maxStringLength\` cannot exceed ${je}, but a value of ${a} was configured. Sentry will use ${je} instead.`),a=je),typeof i=="string"&&(i=[i]);try{const l=r.event,f=vi(l)?l.target:l;s=Ht(f,{keyAttrs:i,maxStringLength:a}),o=br(f)}catch{s="<unknown>"}if(s.length===0)return;const c={category:`ui.${r.name}`,message:s};o&&(c.data={"ui.component_name":o}),J(c,{event:r.event,name:r.name,global:r.global})}}function yi(e){return function(n){if(E()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:pi(n.level),message:Gt(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${Gt(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;J(r,{input:n.args,level:n.level})}}function Ei(e){return function(n){if(E()!==e)return;const{startTimestamp:r,endTimestamp:s}=n,o=n.xhr[ge];if(!r||!s||!o)return;const{method:i,url:a,status_code:c,body:l}=o,f={method:i,url:a,status_code:c},u={xhr:n.xhr,input:l,startTimestamp:r,endTimestamp:s},d=Vn(c);J({category:"xhr",data:f,type:"http",level:d},u)}}function Si(e){return function(n){if(E()!==e)return;const{startTimestamp:r,endTimestamp:s}=n;if(!!s&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.error){const o=n.fetchData,i={data:n.error,input:n.args,startTimestamp:r,endTimestamp:s};J({category:"fetch",data:o,level:"error",type:"http"},i)}else{const o=n.response,i={...n.fetchData,status_code:o&&o.status},a={input:n.args,response:o,startTimestamp:r,endTimestamp:s},c=Vn(i.status_code);J({category:"fetch",data:i,type:"http",level:c},a)}}}function bi(e){return function(n){if(E()!==e)return;let r=n.from,s=n.to;const o=Et(y.location.href);let i=r?Et(r):void 0;const a=Et(s);(!i||!i.path)&&(i=o),o.protocol===a.protocol&&o.host===a.host&&(s=a.relative),o.protocol===i.protocol&&o.host===i.host&&(r=i.relative),J({category:"navigation",data:{from:r,to:s}})}}function vi(e){return!!e&&!!e.target}const Ti=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],Ii="BrowserApiErrors",wi=(e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:Ii,setupOnce(){t.setTimeout&&v(y,"setTimeout",Zn),t.setInterval&&v(y,"setInterval",Zn),t.requestAnimationFrame&&v(y,"requestAnimationFrame",ki),t.XMLHttpRequest&&"XMLHttpRequest"in y&&v(XMLHttpRequest.prototype,"send",Oi);const n=t.eventTarget;n&&(Array.isArray(n)?n:Ti).forEach(Ni)}}};function Zn(e){return function(...t){const n=t[0];return t[0]=ie(n,{mechanism:{data:{function:j(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function ki(e){return function(t){return e.apply(this,[ie(t,{mechanism:{data:{function:"requestAnimationFrame",handler:j(e)},handled:!1,type:"instrument"}})])}}function Oi(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(s=>{s in n&&typeof n[s]=="function"&&v(n,s,function(o){const i={mechanism:{data:{function:s,handler:j(o)},handled:!1,type:"instrument"}},a=Ye(o);return a&&(i.mechanism.data.handler=j(a)),ie(o,i)})}),e.apply(this,t)}}function Ni(e){const n=y[e],r=n&&n.prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(v(r,"addEventListener",function(s){return function(o,i,a){try{Ri(i)&&(i.handleEvent=ie(i.handleEvent,{mechanism:{data:{function:"handleEvent",handler:j(i),target:e},handled:!1,type:"instrument"}}))}catch{}return s.apply(this,[o,ie(i,{mechanism:{data:{function:"addEventListener",handler:j(i),target:e},handled:!1,type:"instrument"}}),a])}}),v(r,"removeEventListener",function(s){return function(o,i,a){try{const c=i.__sentry_wrapped__;c&&s.call(this,o,c,a)}catch{}return s.call(this,o,i,a)}}))}function Ri(e){return typeof e.handleEvent=="function"}const xi=()=>({name:"BrowserSession",setupOnce(){if(typeof y.document>"u"){he&&p.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}In({ignoreDuration:!0}),On(),Jn(({from:e,to:t})=>{e!==void 0&&e!==t&&(In({ignoreDuration:!0}),On())})}});let St=null;function Ci(e){const t="error";q(t,e),Y(t,Di)}function Di(){St=m.onerror,m.onerror=function(e,t,n,r,s){return O("error",{column:r,error:s,line:n,msg:e,url:t}),St?St.apply(this,arguments):!1},m.onerror.__SENTRY_INSTRUMENTED__=!0}let bt=null;function Ai(e){const t="unhandledrejection";q(t,e),Y(t,Pi)}function Pi(){bt=m.onunhandledrejection,m.onunhandledrejection=function(e){return O("unhandledrejection",e),bt?bt.apply(this,arguments):!0},m.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const Mi="GlobalHandlers",Li=(e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:Mi,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(ji(n),Qn("onerror")),t.onunhandledrejection&&(Ui(n),Qn("onunhandledrejection"))}}};function ji(e){Ci(t=>{const{stackParser:n,attachStacktrace:r}=er();if(E()!==e||zn())return;const{msg:s,url:o,line:i,column:a,error:c}=t,l=Bi(pt(n,c||s,void 0,r,!1),o,i,a);l.level="error",vn(l,{originalException:c,mechanism:{handled:!1,type:"onerror"}})})}function Ui(e){Ai(t=>{const{stackParser:n,attachStacktrace:r}=er();if(E()!==e||zn())return;const s=$i(t),o=We(s)?Fi(s):pt(n,s,void 0,r,!0);o.level="error",vn(o,{originalException:s,mechanism:{handled:!1,type:"onunhandledrejection"}})})}function $i(e){if(We(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function Fi(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function Bi(e,t,n,r){const s=e.exception=e.exception||{},o=s.values=s.values||[],i=o[0]=o[0]||{},a=i.stacktrace=i.stacktrace||{},c=a.frames=a.frames||[],l=r,f=n,u=C(t)&&t.length>0?t:Sr();return c.length===0&&c.push({colno:l,filename:u,function:R,in_app:!0,lineno:f}),e}function Qn(e){he&&p.log(`Global Handler attached: ${e}`)}function er(){const e=E();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}const Hi=()=>({name:"HttpContext",preprocessEvent(e){if(!y.navigator&&!y.location&&!y.document)return;const t=e.request&&e.request.url||y.location&&y.location.href,{referrer:n}=y.document||{},{userAgent:r}=y.navigator||{},s={...e.request&&e.request.headers,...n&&{Referer:n},...r&&{"User-Agent":r}},o={...e.request,...t&&{url:t},headers:s};e.request=o}});function Gi(e,t,n=250,r,s,o,i){if(!o.exception||!o.exception.values||!i||!F(i.originalException,Error))return;const a=o.exception.values.length>0?o.exception.values[o.exception.values.length-1]:void 0;a&&(o.exception.values=zi(vt(e,t,s,i.originalException,r,o.exception.values,a,0),n))}function vt(e,t,n,r,s,o,i,a){if(o.length>=n+1)return o;let c=[...o];if(F(r[s],Error)){tr(i,a);const l=e(t,r[s]),f=c.length;nr(l,s,f,a),c=vt(e,t,n,r[s],s,[l,...c],l,f)}return Array.isArray(r.errors)&&r.errors.forEach((l,f)=>{if(F(l,Error)){tr(i,a);const u=e(t,l),d=c.length;nr(u,`errors[${f}]`,d,a),c=vt(e,t,n,l,s,[u,...c],u,d)}}),c}function tr(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function nr(e,t,n,r){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function zi(e,t){return e.map(n=>(n.value&&(n.value=ne(n.value,t)),n))}const Wi="cause",qi=5,Yi="LinkedErrors",Ji=(e={})=>{const t=e.limit||qi,n=e.key||Wi;return{name:Yi,preprocessEvent(r,s,o){const i=o.getOptions();Gi(lt,i.stackParser,i.maxValueLength,n,t,r,s)}}},Ki=10,Xi=20,Vi=30,Zi=40,Qi=50;function ce(e,t,n,r){const s={filename:e,function:t==="<anonymous>"?R:t,in_app:!0};return n!==void 0&&(s.lineno=n),r!==void 0&&(s.colno=r),s}const ea=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,ta=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,na=/\((\S*)(?::(\d+))(?::(\d+))\)/,ra=[Vi,e=>{const t=ea.exec(e);if(t){const[,r,s,o]=t;return ce(r,R,+s,+o)}const n=ta.exec(e);if(n){if(n[2]&&n[2].indexOf("eval")===0){const i=na.exec(n[2]);i&&(n[2]=i[1],n[3]=i[2],n[4]=i[3])}const[s,o]=rr(n[1]||R,n[2]);return ce(o,s,n[3]?+n[3]:void 0,n[4]?+n[4]:void 0)}}],sa=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,oa=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,ia=[Qi,e=>{const t=sa.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const o=oa.exec(t[3]);o&&(t[1]=t[1]||"eval",t[3]=o[1],t[4]=o[2],t[5]="")}let r=t[3],s=t[1]||R;return[s,r]=rr(s,r),ce(r,s,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],aa=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,cu=[Zi,e=>{const t=aa.exec(e);return t?ce(t[2],t[1]||R,+t[3],t[4]?+t[4]:void 0):void 0}],ca=/ line (\d+).*script (?:in )?(\S+)(?:: in function (\S+))?$/i,lu=[Ki,e=>{const t=ca.exec(e);return t?ce(t[2],t[3]||R,+t[1]):void 0}],ua=/ line (\d+), column (\d+)\s*(?:in (?:<anonymous function: ([^>]+)>|([^)]+))\(.*\))? in (.*):\s*$/i,du=[Xi,e=>{const t=ua.exec(e);return t?ce(t[5],t[3]||t[4]||R,+t[1],+t[2]):void 0}],la=an(...[ra,ia]),rr=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:R,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},fa=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Ue={};function Tt(e){const t=Ue[e];if(t)return t;let n=b[e];if(ct(n))return Ue[e]=n.bind(b);const r=b.document;if(r&&typeof r.createElement=="function")try{const s=r.createElement("iframe");s.hidden=!0,r.head.appendChild(s);const o=s.contentWindow;o&&o[e]&&(n=o[e]),r.head.removeChild(s)}catch(s){fa&&p.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,s)}return n&&(Ue[e]=n.bind(b))}function sr(e){Ue[e]=void 0}function hu(...e){return Tt("fetch")(...e)}function gu(...e){return Tt("setTimeout")(...e)}function da(e){const t=[];function n(){return e===void 0||t.length<e}function r(i){return t.splice(t.indexOf(i),1)[0]||Promise.resolve(void 0)}function s(i){if(!n())return we(new x("Not adding Promise because buffer limit was reached."));const a=i();return t.indexOf(a)===-1&&t.push(a),a.then(()=>r(a)).then(null,()=>r(a).then(null,()=>{})),a}function o(i){return new k((a,c)=>{let l=t.length;if(!l)return a(!0);const f=setTimeout(()=>{i&&i>0&&a(!1)},i);t.forEach(u=>{z(u).then(()=>{--l||(clearTimeout(f),a(!0))},c)})})}return{$:t,add:s,drain:o}}const pa=60*1e3;function ha(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?pa:r-t}function ga(e,t){return e[t]||e.all||0}function ma(e,t,n=Date.now()){return ga(e,t)>n}function _a(e,{statusCode:t,headers:n},r=Date.now()){const s={...e},o=n&&n["x-sentry-rate-limits"],i=n&&n["retry-after"];if(o)for(const a of o.trim().split(",")){const[c,l,,,f]=a.split(":",5),u=parseInt(c,10),d=(isNaN(u)?60:u)*1e3;if(!l)s.all=r+d;else for(const h of l.split(";"))h==="metric_bucket"?(!f||f.split(";").includes("custom"))&&(s[h]=r+d):s[h]=r+d}else i?s.all=r+ha(i,r):t===429&&(s.all=r+60*1e3);return s}const ya=64;function Ea(e,t,n=da(e.bufferSize||ya)){let r={};const s=i=>n.drain(i);function o(i){const a=[];if(ut(i,(u,d)=>{const h=Un(d);if(ma(r,h)){const g=or(u,d);e.recordDroppedEvent("ratelimit_backoff",h,g)}else a.push(u)}),a.length===0)return z({});const c=pe(i[0],a),l=u=>{ut(c,(d,h)=>{const g=or(d,h);e.recordDroppedEvent(u,Un(h),g)})},f=()=>t({body:Eo(c)}).then(u=>(u.statusCode!==void 0&&(u.statusCode<200||u.statusCode>=300)&&_&&p.warn(`Sentry responded with status code ${u.statusCode} to sent event.`),r=_a(r,u),u),u=>{throw l("network_error"),u});return n.add(f).then(u=>u,u=>{if(u instanceof x)return _&&p.error("Skipped sending event because buffer is full."),l("queue_overflow"),z({});throw u})}return{send:o,flush:s}}function or(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}function Sa(e,t=Tt("fetch")){let n=0,r=0;function s(o){const i=o.body.length;n+=i,r++;const a={body:o.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};if(!t)return sr("fetch"),we("No fetch implementation available");try{return t(e.url,a).then(c=>(n-=i,r--,{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}))}catch(c){return sr("fetch"),n-=i,r--,we(c)}}return Ea(e,s)}function ba(e){const t=[Fs(),Zs(),wi(),gi(),Li(),Ji(),eo(),Hi()];return e.autoSessionTracking!==!1&&t.push(xi()),t}function va(e={}){const t={defaultIntegrations:ba(e),release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:y.SENTRY_RELEASE&&y.SENTRY_RELEASE.id?y.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0};return e.defaultIntegrations==null&&delete e.defaultIntegrations,{...t,...e}}function Ta(){const e=typeof y.window<"u"&&y;if(!e)return!1;const t=e.chrome?"chrome":"browser",n=e[t],r=n&&n.runtime&&n.runtime.id,s=y.location&&y.location.href||"",o=["chrome-extension:","moz-extension:","ms-browser-extension:","safari-web-extension:"],i=!!r&&y===y.top&&o.some(c=>s.startsWith(`${c}//`)),a=typeof e.nw<"u";return!!r&&!i&&!a}function Ia(e={}){const t=va(e);if(!t.skipBrowserExtensionCheck&&Ta()){H(()=>{console.error("[Sentry] You cannot run Sentry this way in a browser extension, check: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")});return}he&&(at()||p.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill."));const n={...t,stackParser:Gr(t.stackParser||la),integrations:Ls(t),transport:t.transport||Sa};return oo(Jo,n)}function mu(e={}){if(!WINDOW.document){DEBUG_BUILD&&logger.error("Global document not defined in showReportDialog call");return}const t=getCurrentScope(),n=t.getClient(),r=n&&n.getDsn();if(!r){DEBUG_BUILD&&logger.error("DSN not configured for showReportDialog call");return}if(t&&(e.user={...t.getUser(),...e.user}),!e.eventId){const a=lastEventId();a&&(e.eventId=a)}const s=WINDOW.document.createElement("script");s.async=!0,s.crossOrigin="anonymous",s.src=getReportDialogEndpoint(r,e),e.onLoad&&(s.onload=e.onLoad);const{onClose:o}=e;if(o){const a=c=>{if(c.data==="__sentry_reportdialog_closed__")try{o()}finally{WINDOW.removeEventListener("message",a)}};WINDOW.addEventListener("message",a)}const i=WINDOW.document.head||WINDOW.document.body;i?i.appendChild(s):DEBUG_BUILD&&logger.error("Not injecting report dialog. No injection point found in HTML")}function _u(){}function yu(e){e()}function Eu(e){const t=getClient();t&&t.captureUserFeedback(e)}class wa{constructor(t){if(!Ps())Ia(Object.assign(Object.assign({environment:t.environment,dsn:t.dsn},t.appVersion&&{release:t.appVersion}),{beforeSend(n){var r;return!((r=n.extra)===null||r===void 0)&&r.log?n:null}}));else if(t.clientSlug!==void 0&&t.environment!==void 0){const n=en();n.clear(),n.setTag("client.slug",t.clientSlug),n.addEventProcessor(r=>new Promise(s=>s(Object.assign(Object.assign(Object.assign({},r),{environment:t.environment}),t.appVersion&&{release:t.appVersion}))))}}write(t){if(t.err){const n=new Error(t.err.message);n.name=t.msg?`${t.msg} - ${t.err.name}`:t.err.name,n.stack=t.err.stack,bn(n,{extra:{log:!0}})}else t.msg&&As(t.msg,{extra:{log:!0}})}}function It(){return It=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},It.apply(this,arguments)}var ir=typeof window<"u"?window.navigator.userAgent:"no-window",ka=/bot|crawler|spider|crawling/i.test(ir),Oa={"Content-Type":"application/json"},Na=function(){function e(n){var r=this;n===void 0&&(n={});var s=n.method,o=s===void 0?"PUT":s,i=n.url,a=i===void 0?"/log":i,c=n.headers,l=c===void 0?{}:c,f=n.throttleInterval,u=f===void 0?3e3:f,d=n.withCredentials,h=d!==void 0&&d,g=n.onError,Z=n.flushOnClose,S=Z!==void 0&&Z,U=n.writeCondition;this.writeCondition=U===void 0?e.defaultWriteCondition:U,this.records={},this.headers=It({},Oa,l),this.start({method:o,url:a,throttleInterval:u,withCredentials:h,onError:g}),S&&window.fetch!==void 0&&window.addEventListener("beforeunload",function(){r.currentThrottleTimeout&&window.clearTimeout(r.currentThrottleTimeout);var le=r.recordsAsArray();le.length&&window.fetch(a,{method:o,body:JSON.stringify(le),headers:r.headers,credentials:h?"include":"same-origin",mode:"cors",keepalive:!0})},!1)}var t=e.prototype;return t.start=function(n){var r=this,s=n.method,o=n.url,i=n.throttleInterval,a=n.withCredentials,c=n.onError;(function l(){r.currentThrottleTimeout=setTimeout(function(){var f=r.recordsAsArray();if(f.length){var u=new XMLHttpRequest;u.onreadystatechange=function(){u.readyState===XMLHttpRequest.DONE&&(u.status>=400&&(typeof c=="function"?c.call(r,f,u):console.warn("Browser Bunyan: A server log write failed")),r.records={},l())},u.open(s,o);for(var d=0,h=Object.entries(r.headers);d<h.length;d++){var g=h[d];u.setRequestHeader(g[0],g[1])}u.withCredentials=a,u.send(JSON.stringify(f))}else l()},i)})()},t.stop=function(){var n=this;setTimeout(function(){n.currentThrottleTimeout&&(clearTimeout(n.currentThrottleTimeout),n.currentThrottleTimeout=null)},1)},t.write=function(n){n.url=typeof window<"u"&&window.location.href,n.userAgent=ir,this.currentThrottleTimeout&&this.writeCondition(n)&&(this.records[n.msg]?this.records[n.msg].count++:(n.count=1,this.records[n.msg]=n))},t.recordsAsArray=function(){var n=this;return Object.keys(this.records).map(function(r){return n.records[r]})},e.defaultWriteCondition=function(){return window.navigator.onLine&&!ka},e}(),Su=10,bu=20,vu=30,Tu=40,Iu=50,wu=60,wt={trace:10,debug:20,info:30,warn:40,error:50,fatal:60},ar={};function kt(e){return typeof e=="string"?wt[e.toLowerCase()]:e}function Ot(e,t){return Ot=Object.setPrototypeOf||function(n,r){return n.__proto__=r,n},Ot(e,t)}function Ra(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Nt(e,t,n){return Nt=Ra()?Reflect.construct:function(r,s,o){var i=[null];i.push.apply(i,s);var a=new(Function.bind.apply(r,i));return o&&Ot(a,o.prototype),a},Nt.apply(null,arguments)}function K(e){if(e==null)return e;if(Array.isArray(e))return e.slice();if(typeof e=="object"){var t={};return Object.keys(e).forEach(function(n){t[n]=e[n]}),t}return e}function Rt(e){return e===void 0?"undefined":e===null?"null":Array.isArray(e)?"[ "+e.map(function(t){return Rt(t)}).join(", ")+" ]":typeof e=="object"?JSON.stringify(e):typeof e=="function"?"[Function: "+e.name+"]":typeof e=="boolean"||typeof e=="number"?e:"'"+e.toString()+"'"}function X(e){if(typeof e!="string"){for(var t=new Array(arguments.length),n=0;n<arguments.length;n++)t[n]=Rt(arguments[n]);return t.join(" ")}for(var r=/%[sdj%]/g,s=1,o=arguments,i=o.length,a=String(e).replace(r,function(l){if(l==="%%")return"%";if(s>=i)return l;switch(l){case"%s":return String(o[s++]);case"%d":return Number(o[s++]);case"%j":try{return JSON.stringify(o[s++])}catch{return"[Circular]"}default:return l}}),c=o[s];s<i;c=o[++s])a+=c===null||typeof c!="object"?" "+c:" "+Rt(c);return a}function xa(e,t){var n=e.split(`
|
|
19
19
|
`);n[0]&&n[0].indexOf("call-stack-error")>=0&&n.shift();var r=n[t],s=null;if(r){var o=/^\s*(at|.*@)\s*(.+)?$/.exec(r);s=Array.isArray(o)&&o[2]?o[2]:r}return s}Object.keys(wt).forEach(function(e){ar[wt[e]]=e});var xt={};function Ct(e,t){if(t){if(xt[t])return;xt[t]=!0}console.error(e+`
|
|
20
20
|
`)}function Ca(e){return xt[e]}function Da(){var e=[];return function(t,n){return n&&typeof n=="object"?e.indexOf(n)!==-1?"[Circular]":(e.push(n),n):n}}var Aa=function(){function e(){}return e.prototype.write=function(t){t.level<30?console.log(t):t.level<40?console.info(t):t.level<50?console.warn(t):console.error(t),t.err&&t.err.stack&&console.error(t.err.stack),t.obj&&console.log(t.obj)},e}(),V=function(){function e(n,r,s){var o,i,a,c,l=this;if(!(this instanceof e))return new e(n,r);if(r!==void 0&&(o=n,n=r,!(o instanceof e)))throw new TypeError("invalid Logger creation: do not pass a second arg");if(!n)throw new TypeError("options (object) is required");if(o){if(n.name)throw new TypeError("invalid options.name: child cannot set logger name")}else if(!n.name)throw new TypeError("options.name (string) is required");if(n.stream&&n.streams)throw new TypeError('cannot mix "streams" and "stream" options');if(n.streams&&!Array.isArray(n.streams))throw new TypeError("invalid options.streams: must be an array");if(n.serializers&&(typeof n.serializers!="object"||Array.isArray(n.serializers)))throw new TypeError("invalid options.serializers: must be an object");if(o&&s){this._level=o._level,this.streams=o.streams,this.serializers=o.serializers,this.src=o.src,i=this.fields={};var f=Object.keys(o.fields);for(c=0;c<f.length;c++)i[a=f[c]]=o.fields[a];var u=Object.keys(n);for(c=0;c<u.length;c++)i[a=u[c]]=n[a]}else{if(o){for(this._level=o._level,this.streams=[],c=0;c<o.streams.length;c++){var d=K(o.streams[c]);this.streams.push(d)}this.serializers=K(o.serializers),this.src=o.src,this.fields=K(o.fields),n.level&&this.level(n.level)}else this._level=Number.POSITIVE_INFINITY,this.streams=[],this.serializers=null,this.src=!1,this.fields={};n.stream?this.addStream({type:"stream",stream:n.stream,level:n.level}):n.streams?n.streams.forEach(function(h){l.addStream(h,n.level)}):o&&n.level?this.level(n.level):o||this.addStream({type:"raw",stream:new Aa,level:n.level}),n.serializers&&this.addSerializers(n.serializers),n.src&&(this.src=!0),delete(i=K(n)).stream,delete i.level,delete i.streams,delete i.serializers,delete i.src,this.serializers&&this._applySerializers(i),Object.keys(i).forEach(function(h){l.fields[h]=i[h]})}}var t=e.prototype;return t.addStream=function(n,r){r===void 0&&(r=30),(n=K(n)).type="raw",n.level=kt(n.level||r),n.level<this._level&&(this._level=n.level),this.streams.push(n),delete this.haveNonRawStreams},t.addSerializers=function(n){var r=this;this.serializers||(this.serializers={}),Object.keys(n).forEach(function(s){var o=n[s];if(typeof o!="function")throw new TypeError(X('invalid serializer for "%s" field: must be a function',s));r.serializers[s]=o})},t.child=function(n,r){return new this.constructor(this,n||{},r)},t.level=function(n){if(n===void 0)return this._level;for(var r=kt(n),s=this.streams.length,o=0;o<s;o++)this.streams[o].level=r;this._level=r},t.levels=function(n,r){if(n===void 0)return this.streams.map(function(l){return l.level});var s;if(typeof n=="number"){if((s=this.streams[n])===void 0)throw new Error("invalid stream index: "+n)}else{for(var o=this.streams.length,i=0;i<o;i++){var a=this.streams[i];if(a.name===n){s=a;break}}if(!s)throw new Error(X('no stream with name "%s"',n))}if(r===void 0)return s.level;var c=kt(r);s.level=c,c<this._level&&(this._level=c)},t._applySerializers=function(n,r){var s=this;Object.keys(this.serializers).forEach(function(o){if(!(n[o]===void 0||r&&r[o]))try{n[o]=s.serializers[o](n[o])}catch(i){Ct(X(`bunyan: ERROR: Exception thrown from the "%s" Bunyan serializer. This should never happen. This is a bugin that serializer function.
|
|
21
21
|
%s`,o,i.stack||i)),n[o]=X('(Error in Bunyan log "%s" serializer broke field. See stderr for details.)',o)}})},t._emit=function(n,r){var s,o;if(this.haveNonRawStreams===void 0){for(this.haveNonRawStreams=!1,s=0;s<this.streams.length;s++)if(!this.streams[s].raw){this.haveNonRawStreams=!0;break}}if(r||this.haveNonRawStreams)try{o=JSON.stringify(n,Da())+`
|
|
@@ -25,3 +25,5 @@ Error:`,s)}}const b=m,Ko=1e3;let qn,mt,_t;function Xo(e){const t="dom";q(t,e),Y(
|
|
|
25
25
|
%s`,n,l.stack)),i),o=X(`(Exception in JSON.stringify(rec): %j. See stderr for details.)
|
|
26
26
|
`,l.message)}if(r)return o;var a=n.level;for(s=0;s<this.streams.length;s++){var c=this.streams[s];c.level<=a&&c.stream.write(n)}return o},e}();function ue(e){return function(){var t=this;function n(i){var a;i[0]instanceof Error?(r={err:t.serializers&&t.serializers.err?t.serializers.err(i[0]):Pa.err(i[0])},a={err:!0},s=i.length===1?[r.err.message]:Array.prototype.slice.call(i,1)):typeof i[0]!="object"&&i[0]!==null||Array.isArray(i[0])?(r=null,s=Array.prototype.slice.call(i)):(r=i[0],s=i.length===1&&r.err&&r.err instanceof Error?[r.err.message]:Array.prototype.slice.call(i,1));var c=K(t.fields);c.level=e;var l=r?K(r):null;if(l&&(t.serializers&&t._applySerializers(l,a),Object.keys(l).forEach(function(u){c[u]=l[u]})),c.levelName=ar[e],c.msg=s.length?X.apply(t,s):"",c.time||(c.time=new Date),t.src&&!c.src)try{throw new Error("call-stack-error")}catch(u){var f=u.stack?xa(u.stack,2):"";f||Ca("src")||Ct("Unable to determine src line info","src"),c.src=f||""}return c.v=1,c}var r=null,s=arguments,o=null;if(arguments.length===0)return this._level<=e;this._level>e||(o=n(s),this._emit(o))}}function cr(e){var t=e.stack||e.toString();if(e.cause&&typeof e.cause=="function"){var n=e.cause();n&&(t+=`
|
|
27
27
|
Caused by: `+cr(n))}return t}V.prototype.trace=ue(10),V.prototype.debug=ue(20),V.prototype.info=ue(30),V.prototype.warn=ue(40),V.prototype.error=ue(50),V.prototype.fatal=ue(60);var Pa={err:function(e){return e&&e.stack?{message:e.message,name:e.name,stack:cr(e),code:e.code,signal:e.signal}:e}};function Ma(){return Nt(V,[].slice.call(arguments))}var ku={levels:{trace:"color: DeepPink",debug:"color: GoldenRod",info:"color: DarkTurquoise",warn:"color: Purple",error:"color: Crimson",fatal:"color: Black"},def:"color: DimGray",msg:"color: SteelBlue",src:"color: DimGray; font-style: italic; font-size: 0.9em"},Ou=null,Nu=null;function La({environment:e,clientSlug:t,url:n,telemetry:r,appVersion:s}={}){const{logging:o}=Object.assign({},r),i=[{level:Pt,stream:new pr({logByLevel:!0})}];return o&&i.push({level:$e,stream:new wa({dsn:"https://509e6f450227e178643e414fe50bd969@o4507853291716608.ingest.us.sentry.io/4508132363141120",environment:e,clientSlug:t,appVersion:s})}),n&&i.push({level:$e,stream:new Na({url:n,method:"POST",throttleInterval:5e3,flushOnClose:!0})}),Ma({name:"embeddable-logger",streams:i,environment:e,clientSlug:t})}}}]);
|
|
28
|
+
|
|
29
|
+
//# sourceMappingURL=170.index.js.map
|