!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{},t=Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="ea14dc28-78f8-464a-9d0d-596a7ee5af09",e._sentryDebugIdIdentifier="sentry-dbid-ea14dc28-78f8-464a-9d0d-596a7ee5af09")}catch(e){}}(),(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2888],{86010:function(e,t,r){"use strict";t.Z=function(){for(var e,t,r=0,n="";r<arguments.length;)(e=arguments[r++])&&(t=function e(t){var r,n,i="";if("string"==typeof t||"number"==typeof t)i+=t;else if("object"==typeof t){if(Array.isArray(t))for(r=0;r<t.length;r++)t[r]&&(n=e(t[r]))&&(i&&(i+=" "),i+=n);else for(r in t)t[r]&&(i&&(i+=" "),i+=r)}return i}(e))&&(n&&(n+=" "),n+=t);return n}},8679:function(e,t,r){"use strict";var n=r(59864),i={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},s={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},o={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},a={};function u(e){return n.isMemo(e)?o:a[e.$$typeof]||i}a[n.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},a[n.Memo]=o;var l=Object.defineProperty,c=Object.getOwnPropertyNames,d=Object.getOwnPropertySymbols,f=Object.getOwnPropertyDescriptor,h=Object.getPrototypeOf,p=Object.prototype;e.exports=function e(t,r,n){if("string"!=typeof r){if(p){var i=h(r);i&&i!==p&&e(t,i,n)}var o=c(r);d&&(o=o.concat(d(r)));for(var a=u(t),m=u(r),g=0;g<o.length;++g){var y=o[g];if(!s[y]&&!(n&&n[y])&&!(m&&m[y])&&!(a&&a[y])){var v=f(r,y);try{l(t,y,v)}catch(e){}}}}return t}},62705:function(e,t,r){var n=r(55639).Symbol;e.exports=n},44239:function(e,t,r){var n=r(62705),i=r(89607),s=r(2333),o=n?n.toStringTag:void 0;e.exports=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":o&&o in Object(e)?i(e):s(e)}},27561:function(e,t,r){var n=r(67990),i=/^\s+/;e.exports=function(e){return e?e.slice(0,n(e)+1).replace(i,""):e}},31957:function(e,t,r){var n="object"==typeof r.g&&r.g&&r.g.Object===Object&&r.g;e.exports=n},89607:function(e,t,r){var n=r(62705),i=Object.prototype,s=i.hasOwnProperty,o=i.toString,a=n?n.toStringTag:void 0;e.exports=function(e){var t=s.call(e,a),r=e[a];try{e[a]=void 0;var n=!0}catch(e){}var i=o.call(e);return n&&(t?e[a]=r:delete e[a]),i}},2333:function(e){var t=Object.prototype.toString;e.exports=function(e){return t.call(e)}},55639:function(e,t,r){var n=r(31957),i="object"==typeof self&&self&&self.Object===Object&&self,s=n||i||Function("return this")();e.exports=s},67990:function(e){var t=/\s/;e.exports=function(e){for(var r=e.length;r--&&t.test(e.charAt(r)););return r}},23279:function(e,t,r){var n=r(13218),i=r(7771),s=r(14841),o=Math.max,a=Math.min;e.exports=function(e,t,r){var u,l,c,d,f,h,p=0,m=!1,g=!1,y=!0;if("function"!=typeof e)throw TypeError("Expected a function");function v(t){var r=u,n=l;return u=l=void 0,p=t,d=e.apply(n,r)}function _(e){var r=e-h,n=e-p;return void 0===h||r>=t||r<0||g&&n>=c}function b(){var e,r,n,s=i();if(_(s))return S(s);f=setTimeout(b,(e=s-h,r=s-p,n=t-e,g?a(n,c-r):n))}function S(e){return(f=void 0,y&&u)?v(e):(u=l=void 0,d)}function E(){var e,r=i(),n=_(r);if(u=arguments,l=this,h=r,n){if(void 0===f)return p=e=h,f=setTimeout(b,t),m?v(e):d;if(g)return clearTimeout(f),f=setTimeout(b,t),v(h)}return void 0===f&&(f=setTimeout(b,t)),d}return t=s(t)||0,n(r)&&(m=!!r.leading,c=(g="maxWait"in r)?o(s(r.maxWait)||0,t):c,y="trailing"in r?!!r.trailing:y),E.cancel=function(){void 0!==f&&clearTimeout(f),p=0,u=h=l=f=void 0},E.flush=function(){return void 0===f?d:S(i())},E}},13218:function(e){e.exports=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}},37005:function(e){e.exports=function(e){return null!=e&&"object"==typeof e}},33448:function(e,t,r){var n=r(44239),i=r(37005);e.exports=function(e){return"symbol"==typeof e||i(e)&&"[object Symbol]"==n(e)}},7771:function(e,t,r){var n=r(55639);e.exports=function(){return n.Date.now()}},23493:function(e,t,r){var n=r(23279),i=r(13218);e.exports=function(e,t,r){var s=!0,o=!0;if("function"!=typeof e)throw TypeError("Expected a function");return i(r)&&(s="leading"in r?!!r.leading:s,o="trailing"in r?!!r.trailing:o),n(e,t,{leading:s,maxWait:t,trailing:o})}},14841:function(e,t,r){var n=r(27561),i=r(13218),s=r(33448),o=0/0,a=/^[-+]0x[0-9a-f]+$/i,u=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;e.exports=function(e){if("number"==typeof e)return e;if(s(e))return o;if(i(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=i(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=n(e);var r=u.test(e);return r||l.test(e)?c(e.slice(2),r?2:8):a.test(e)?o:+e}},44343:function(e,t,r){e.exports=r(32646)},6840:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/_app",function(){return r(76003)}])},41451:function(e,t,r){"use strict";t.ZP={MAGIC_LINK_SIGN_IN:{CTA:"MAGIC_LINK_SIGN_IN_CTA"},HEADER:{LOGIN_BUTTON:"HEADER_LOGIN_BUTTON",SIGNUP_BUTTON:"HEADER_SIGNUP_BUTTON",PLAYGROUND_BUTTON:"HEADER_PLAYGROUND_BUTTON",DASHBOARD_BUTTON:"HEADER_DASHBOARD_BUTTON",SETTINGS_BUTTON:"HEADER_SETTINGS_BUTTON",API_BUTTON:"HEADER_API_BUTTON",WEB_OPTIMIZER_BUTTON:"HEADER_WEB_OPTIMIZER_BUTTON",USER_SETTINGS:{$ELEMENT:"HEADER_USER_SETTINGS_ELEMENT",DROPDOWN:{$ELEMENT:"HEADER_USER_SETTINGS_DROPDOWN",BILLING:"HEADER_USER_SETTINGS_DROPDOWN_BILLING",SIGN_OUT:"HEADER_USER_SETTINGS_SIGN_OUT"}}},CLERK:{FORM:{SIGNUP_EMAIL_INPUT:'input[name="emailAddress"]',SIGNIN_EMAIL_INPUT:'input[name="identifier"]',SUBMIT_BUTTON:".cl-formButtonPrimary",CODE_INPUT_1:'input[name="codeInput-0"]',ORGANIZATION_NAME_INPUT:'input[name="name"]',SKIP_BUTTON:".cl-formButtonReset"},ORGANIZATION_SWITCHER:{$ELEMENT:".cl-organizationSwitcher-root"},USER_BUTTON:{POPOVER_CARD:{$ELEMENT:".cl-userButtonPopoverCard",USER:{$ELEMENT:".cl-userPreviewMainIdentifier"},SIGN_OUT:".cl-button__signOut"}}},STUDIO:{DASHBOARD:{REVIEW_MODE_SWITCHER:"STUDIO_DASHBOARD_REVIEW_MODE_SWITCHER",API_REQUESTS:{CELL:{IMAGE:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_CELL_IMAGE",IMG:"STUDIO_DASHBOARD_API_REQUESTS_CELL_IMAGE_IMG",ASSET_NAME:"STUDIO_DASHBOARD_API_REQUESTS_CELL_IMAGE_ASSET_NAME"},CREATED_AT:"STUDIO_DASHBOARD_API_REQUESTS_CELL_CREATED_AT",ENDPOINT:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_CELL_ENDPOINT",NAME:"STUDIO_DASHBOARD_API_REQUESTS_CELL_ENDPOINT_NAME"},RESPONSE:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_CELL_RESPONSE",TAG:"STUDIO_DASHBOARD_API_REQUESTS_CELL_RESPONSE_TAG"}},PAGINATION:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_PAGINATION",PAGES:"STUDIO_DASHBOARD_API_REQUESTS_PAGINATION_PAGES",PREVIOUS_BTN:"STUDIO_DASHBOARD_API_REQUESTS_PAGINATION_PREVIOUS_BTN",NEXT_BTN:"STUDIO_DASHBOARD_API_REQUESTS_PAGINATION_NEXT_BTN"},TABLE:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_TABLE",ROW:{$ELEMENT:"STUDIO_DASHBOARD_API_REQUESTS_TABLE_ROW"}},GRADING_TABLE:{$ELEMENT:"STUDIO_DASHBOARD_API_GRADING_TABLE",ROW:{$ELEMENT:"STUDIO_DASHBOARD_API_GRADING_TABLE_ROW"}}},TEAM:{INVITE_FORM_FIELD:"STUDIO_DASHBOARD_INVITE_FORM_FIELD",INVITE_SUBMIT_BUTTON:"STUDIO_DASHBOARD_INVITE_SUBMIT_BUTTON"},BILLING:{STARTER_PLAN_CTA:"STUDIO_DASHBOARD_BILLING_STARTER_PLAN_CTA",PRO_PLAN_CTA:"STUDIO_DASHBOARD_BILLING_PRO_PLAN_CTA",FREE_PLAN_CTA:"STUDIO_DASHBOARD_BILLING_FREE_PLAN_CTA",ENTERPRISE_PLAN_CTA:"STUDIO_DASHBOARD_BILLING_ENTERPRISE_PLAN_CTA",MANAGE_CTA:"STUDIO_DASHBOARD_BILLING_MANAGE_CTA",CANCEL_CTA:"STUDIO_DASHBOARD_BILLING_CANCEL_CTA",UPGRADE_CTA:"STUDIO_DASHBOARD_BILLING_UPGRADE_CTA",PLAN:{$ELEMENT:"STUDIO_DASHBOARD_BILLING_PLAN",NEXT_CHARGE:"STUDIO_DASHBOARD_BILLING_PLAN_NEXT_CHARGE"},USAGE:"STUDIO_DASHBOARD_BILLING_USAGE",SUBSCRIPTION_MODAL:{$ELEMENT:"STUDIO_DASHBOARD_BILLING_SUBSCRIPTION_MODAL",STANDARD_PLAN_CTA:"STUDIO_DASHBOARD_BILLING_SUBSCRIPTION_MODAL_STANDARD_PLAN_CTA",ENTERPRISE_FORM:{$ELEMENT:"STUDIO_DASHBOARD_BILLING_SUBSCRIPTION_MODAL_ENTERPRISE_FORM"},CONTACT_US_CTA:"STUDIO_DASHBOARD_BILLING_SUBSCRIPTION_MODAL_CONTACT_US_CTA"},CANCEL_MODAL:{$ELEMENT:"STUDIO_DASHBOARD_BILLING_CANCEL_MODAL"}}}},API_DETAILS:{API_KEY:{$ELEMENT:"API_DETAILS_API_KEY",INPUT:"API_DETAILS_API_KEY_INPUT",VIEW_KEY:"API_DETAILS_API_KEY_VIEW_KEY"}},COMPONENT:{MODAL:{$ELEMENT:"COMPONENT_MODAL",PRIMARY_BUTTON:"COMPONENT_MODAL_PRIMARY_BUTTON"},SELECT_BOX:{$ELEMENT:"COMPONENT_SELECT_BOX"}},EMAIL:{CONFIRM_EMAIL_BUTTON:"EMAIL_CONFIRM_EMAIL_BUTTON"}}},49110:function(e,t,r){"use strict";let n,i,s,o,a,u,l,c,d,f,h,p,m,g;var y,v,_,b,S,E,w,O,k=r(7659),T=r(39424),C=r(73076);function I(e){if("boolean"==typeof __SENTRY_TRACING__&&!__SENTRY_TRACING__)return!1;let t=(0,C.s3)(),r=e||t&&t.getOptions();return!!r&&(r.enableTracing||"tracesSampleRate"in r||"tracesSampler"in r)}var R=r(75686),x=r(67294),A=r(29531),P=r(34155),M=r(81585),N=r(13533),D=r(60811),L=r(31218),j=r(89366),U=r(72123),B=r(41001),F=r(94223),$=r(79769),z=r(41982);class H{constructor(e={}){this._traceId=e.traceId||(0,z.DM)(),this._spanId=e.spanId||(0,z.DM)().substring(16)}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:M.ve}}end(e){}setAttribute(e,t){return this}setAttributes(e){return this}setStatus(e){return this}updateName(e){return this}isRecording(){return!1}addEvent(e,t,r){return this}addLink(e){return this}addLinks(e){return this}recordException(e,t){}}var G=r(26181),q=r(27179),Z=r(11793),W=r(72751);function K(e){if(!e||0===e.length)return;let t={};return e.forEach(e=>{let r=e.attributes||{},n=r[L.E1],i=r[L.Wb];"string"==typeof n&&"number"==typeof i&&(t[e.name]={value:i,unit:n})}),t}let V="_sentryScope",Q="_sentryIsolationScope";function X(e){return{scope:e[V],isolationScope:e[Q]}}class J{constructor(e={}){this._traceId=e.traceId||(0,z.DM)(),this._spanId=e.spanId||(0,z.DM)().substring(16),this._startTime=e.startTimestamp||(0,G.ph)(),this._attributes={},this.setAttributes({[L.S3]:"manual",[L.$J]:e.op,...e.attributes}),this._name=e.name,e.parentSpanId&&(this._parentSpanId=e.parentSpanId),"sampled"in e&&(this._sampled=e.sampled),e.endTimestamp&&(this._endTime=e.endTimestamp),this._events=[],this._isStandaloneSpan=e.isStandalone,this._endTime&&this._onSpanEnded()}addLink(e){return this}addLinks(e){return this}recordException(e,t){}spanContext(){let{_spanId:e,_traceId:t,_sampled:r}=this;return{spanId:e,traceId:t,traceFlags:r?M.i0:M.ve}}setAttribute(e,t){return void 0===t?delete this._attributes[e]:this._attributes[e]=t,this}setAttributes(e){return Object.keys(e).forEach(t=>this.setAttribute(t,e[t])),this}updateStartTime(e){this._startTime=(0,M.$k)(e)}setStatus(e){return this._status=e,this}updateName(e){return this._name=e,this}end(e){this._endTime||(this._endTime=(0,M.$k)(e),function(e){if(!F.X)return;let{description:t="< unknown name >",op:r="< unknown op >"}=(0,M.XU)(e),{spanId:n}=e.spanContext(),i=(0,M.Gx)(e)===e,s=`[Tracing] Finishing "${r}" ${i?"root ":""}span "${t}" with ID ${n}`;B.kg.log(s)}(this),this._onSpanEnded())}getSpanJSON(){return(0,q.Jr)({data:this._attributes,description:this._name,op:this._attributes[L.$J],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:(0,M._4)(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[L.S3],_metrics_summary:(0,W.y)(this),profile_id:this._attributes[L.p6],exclusive_time:this._attributes[L.JQ],measurements:K(this._events),is_segment:this._isStandaloneSpan&&(0,M.Gx)(this)===this||void 0,segment_id:this._isStandaloneSpan?(0,M.Gx)(this).spanContext().spanId:void 0})}isRecording(){return!this._endTime&&!!this._sampled}addEvent(e,t,r){F.X&&B.kg.log("[Tracing] Adding an event to span:",e);let n=Y(t)?t:r||(0,G.ph)(),i=Y(t)?{}:t||{},s={name:e,time:(0,M.$k)(n),attributes:i};return this._events.push(s),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){let e=(0,C.s3)();if(e&&e.emit("spanEnd",this),!(this._isStandaloneSpan||this===(0,M.Gx)(this)))return;if(this._isStandaloneSpan){this._sampled?function(e){let t=(0,C.s3)();if(!t)return;let r=e[1];if(!r||0===r.length){t.recordDroppedEvent("before_send","span");return}let n=t.getTransport();n&&n.send(e).then(null,e=>{F.X&&B.kg.error("Error while sending span:",e)})}((0,Z.uE)([this],e)):(F.X&&B.kg.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),e&&e.recordDroppedEvent("sample_rate","span"));return}let t=this._convertSpanToTransaction();t&&(X(this).scope||(0,C.nZ)()).captureEvent(t)}_convertSpanToTransaction(){if(!ee((0,M.XU)(this)))return;this._name||(F.X&&B.kg.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");let{scope:e,isolationScope:t}=X(this),r=(e||(0,C.nZ)()).getClient()||(0,C.s3)();if(!0!==this._sampled){F.X&&B.kg.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),r&&r.recordDroppedEvent("sample_rate","transaction");return}let n=(0,M.Dp)(this).filter(e=>e!==this&&!(e instanceof J&&e.isStandaloneSpan())).map(e=>(0,M.XU)(e)).filter(ee),i=this._attributes[L.Zj],s={contexts:{trace:(0,M.HR)(this)},spans:n.length>1e3?n.sort((e,t)=>e.start_timestamp-t.start_timestamp).slice(0,1e3):n,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:e,capturedSpanIsolationScope:t,...(0,q.Jr)({dynamicSamplingContext:(0,U.jC)(this)})},_metrics_summary:(0,W.y)(this),...i&&{transaction_info:{source:i}}},o=K(this._events);return o&&Object.keys(o).length&&(F.X&&B.kg.log("[Measurements] Adding measurements to transaction event",JSON.stringify(o,void 0,2)),s.measurements=o),s}}function Y(e){return e&&"number"==typeof e||e instanceof Date||Array.isArray(e)}function ee(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}let et="__SENTRY_SUPPRESS_TRACING__";function er(e){let t=ei();if(t.startInactiveSpan)return t.startInactiveSpan(e);let r=function(e){let t={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){let r={...t};return r.startTimestamp=(0,M.$k)(e.startTime),delete r.startTime,r}return t}(e),{forceTransaction:n,parentSpan:i}=e;return(e.scope?t=>(0,C.$e)(e.scope,t):void 0!==i?e=>en(i,e):e=>e())(()=>{let t=(0,C.nZ)(),i=function(e){let t=(0,j.Y)(e);if(!t)return;let r=(0,C.s3)();return(r?r.getOptions():{}).parentSpanIsAlwaysRootSpan?(0,M.Gx)(t):t}(t);return e.onlyIfParent&&!i?new H:function({parentSpan:e,spanArguments:t,forceTransaction:r,scope:n}){var i;let s;if(!I())return new H;let o=(0,C.aF)();if(e&&!r)s=function(e,t,r){let{spanId:n,traceId:i}=e.spanContext(),s=!t.getScopeData().sdkProcessingMetadata[et]&&(0,M.Tt)(e),o=s?new J({...r,parentSpanId:n,traceId:i,sampled:s}):new H({traceId:i});(0,M.j5)(e,o);let a=(0,C.s3)();return a&&(a.emit("spanStart",o),r.endTimestamp&&a.emit("spanEnd",o)),o}(e,n,t),(0,M.j5)(e,s);else if(e){let r=(0,U.jC)(e),{traceId:i,spanId:o}=e.spanContext(),a=(0,M.Tt)(e);s=es({traceId:i,parentSpanId:o,...t},n,a),(0,U.Lh)(s,r)}else{let{traceId:e,dsc:r,parentSpanId:i,sampled:a}={...o.getPropagationContext(),...n.getPropagationContext()};s=es({traceId:e,parentSpanId:i,...t},n,a),r&&(0,U.Lh)(s,r)}return function(e){if(!F.X)return;let{description:t="< unknown name >",op:r="< unknown op >",parent_span_id:n}=(0,M.XU)(e),{spanId:i}=e.spanContext(),s=(0,M.Tt)(e),o=(0,M.Gx)(e),a=o===e,u=`[Tracing] Starting ${s?"sampled":"unsampled"} ${a?"root ":""}span`,l=[`op: ${r}`,`name: ${t}`,`ID: ${i}`];if(n&&l.push(`parent ID: ${n}`),!a){let{op:e,description:t}=(0,M.XU)(o);l.push(`root ID: ${o.spanContext().spanId}`),e&&l.push(`root op: ${e}`),t&&l.push(`root description: ${t}`)}B.kg.log(`${u}
  ${l.join("\n  ")}`)}(s),(i=s)&&((0,q.xp)(i,Q,o),(0,q.xp)(i,V,n)),s}({parentSpan:i,spanArguments:r,forceTransaction:n,scope:t})})}function en(e,t){let r=ei();return r.withActiveSpan?r.withActiveSpan(e,t):(0,C.$e)(r=>((0,j.D)(r,e||void 0),t(r)))}function ei(){let e=(0,N.c)();return(0,D.G)(e)}function es(e,t,r){let n=(0,C.s3)(),i=n&&n.getOptions()||{},{name:s="",attributes:o}=e,[a,u]=t.getScopeData().sdkProcessingMetadata[et]?[!1]:function(e,t){let r;if(!I(e))return[!1];r="function"==typeof e.tracesSampler?e.tracesSampler(t):void 0!==t.parentSampled?t.parentSampled:void 0!==e.tracesSampleRate?e.tracesSampleRate:1;let n=(0,$.o)(r);return void 0===n?(F.X&&B.kg.warn("[Tracing] Discarding transaction because of invalid sample rate."),[!1]):n?Math.random()<n?[!0,n]:(F.X&&B.kg.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(r)})`),[!1,n]):(F.X&&B.kg.log(`[Tracing] Discarding transaction because ${"function"==typeof e.tracesSampler?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,n])}(i,{name:s,parentSampled:r,attributes:o,transactionContext:{name:s,parentSampled:r}}),l=new J({...e,attributes:{[L.Zj]:"custom",...e.attributes},sampled:a});return void 0!==u&&l.setAttribute(L.TE,u),n&&n.emit("spanStart",l),l}var eo=r(1869),ea=r(42419),eu=r(12016),el=r(23039),ec=r(42283);let ed=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",ef=(e,t,r,n)=>{let i,s;return o=>{t.value>=0&&(o||n)&&((s=t.value-(i||0))||void 0===i)&&(i=t.value,t.delta=s,t.rating=ed(t.value,r),e(t))}},eh=()=>`v3-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,ep=()=>el.m.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0],em=()=>{let e=ep();return e&&e.activationStart||0},eg=(e,t)=>{let r=ep(),n="navigate";return r&&(el.m.document&&el.m.document.prerendering||em()>0?n="prerender":el.m.document&&el.m.document.wasDiscarded?n="restore":r.type&&(n=r.type.replace(/_/g,"-"))),{name:e,value:void 0===t?-1:t,rating:"good",delta:0,entries:[],id:eh(),navigationType:n}},ey=(e,t,r)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){let n=new PerformanceObserver(e=>{Promise.resolve().then(()=>{t(e.getEntries())})});return n.observe(Object.assign({type:e,buffered:!0},r||{})),n}}catch(e){}},ev=e=>{let t=t=>{("pagehide"===t.type||el.m.document&&"hidden"===el.m.document.visibilityState)&&e(t)};el.m.document&&(addEventListener("visibilitychange",t,!0),addEventListener("pagehide",t,!0))},e_=e=>{let t=!1;return r=>{t||(e(r),t=!0)}},eb=-1,eS=()=>{eb="hidden"!==el.m.document.visibilityState||el.m.document.prerendering?1/0:0},eE=e=>{"hidden"===el.m.document.visibilityState&&eb>-1&&(eb="visibilitychange"===e.type?e.timeStamp:0,removeEventListener("visibilitychange",eE,!0),removeEventListener("prerenderingchange",eE,!0))},ew=()=>{addEventListener("visibilitychange",eE,!0),addEventListener("prerenderingchange",eE,!0)},eO=()=>(el.m.document&&eb<0&&(eS(),ew()),{get firstHiddenTime(){return eb}}),ek=e=>{el.m.document&&el.m.document.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},eT=[1800,3e3],eC=(e,t={})=>{ek(()=>{let r;let n=eO(),i=eg("FCP"),s=ey("paint",e=>{e.forEach(e=>{"first-contentful-paint"===e.name&&(s.disconnect(),e.startTime<n.firstHiddenTime&&(i.value=Math.max(e.startTime-em(),0),i.entries.push(e),r(!0)))})});s&&(r=ef(e,i,eT,t.reportAllChanges))})},eI=[.1,.25],eR=(e,t={})=>{eC(e_(()=>{let r;let n=eg("CLS",0),i=0,s=[],o=e=>{e.forEach(e=>{if(!e.hadRecentInput){let t=s[0],r=s[s.length-1];i&&t&&r&&e.startTime-r.startTime<1e3&&e.startTime-t.startTime<5e3?(i+=e.value,s.push(e)):(i=e.value,s=[e])}}),i>n.value&&(n.value=i,n.entries=s,r())},a=ey("layout-shift",o);a&&(r=ef(e,n,eI,t.reportAllChanges),ev(()=>{o(a.takeRecords()),r(!0)}),setTimeout(r,0))}))},ex=[100,300],eA=(e,t={})=>{ek(()=>{let r;let n=eO(),i=eg("FID"),s=e=>{e.startTime<n.firstHiddenTime&&(i.value=e.processingStart-e.startTime,i.entries.push(e),r(!0))},o=e=>{e.forEach(s)},a=ey("first-input",o);r=ef(e,i,ex,t.reportAllChanges),a&&ev(e_(()=>{o(a.takeRecords()),a.disconnect()}))})},eP=0,eM=1/0,eN=0,eD=e=>{e.forEach(e=>{e.interactionId&&(eM=Math.min(eM,e.interactionId),eP=(eN=Math.max(eN,e.interactionId))?(eN-eM)/7+1:0)})},eL=()=>n?eP:performance.interactionCount||0,ej=()=>{"interactionCount"in performance||n||(n=ey("event",eD,{type:"event",buffered:!0,durationThreshold:0}))},eU=[200,500],eB=()=>eL()-0,eF=[],e$={},ez=e=>{let t=eF[eF.length-1],r=e$[e.interactionId];if(r||eF.length<10||t&&e.duration>t.latency){if(r)r.entries.push(e),r.latency=Math.max(r.latency,e.duration);else{let t={id:e.interactionId,latency:e.duration,entries:[e]};e$[t.id]=t,eF.push(t)}eF.sort((e,t)=>t.latency-e.latency),eF.splice(10).forEach(e=>{delete e$[e.id]})}},eH=()=>{let e=Math.min(eF.length-1,Math.floor(eB()/50));return eF[e]},eG=(e,t={})=>{ek(()=>{let r;ej();let n=eg("INP"),i=e=>{e.forEach(e=>{e.interactionId&&ez(e),"first-input"!==e.entryType||eF.some(t=>t.entries.some(t=>e.duration===t.duration&&e.startTime===t.startTime))||ez(e)});let t=eH();t&&t.latency!==n.value&&(n.value=t.latency,n.entries=t.entries,r())},s=ey("event",i,{durationThreshold:null!=t.durationThreshold?t.durationThreshold:40});r=ef(e,n,eU,t.reportAllChanges),s&&("PerformanceEventTiming"in el.m&&"interactionId"in PerformanceEventTiming.prototype&&s.observe({type:"first-input",buffered:!0}),ev(()=>{i(s.takeRecords()),n.value<0&&eB()>0&&(n.value=0,n.entries=[]),r(!0)}))})},eq=[2500,4e3],eZ={},eW=(e,t={})=>{ek(()=>{let r;let n=eO(),i=eg("LCP"),s=e=>{let t=e[e.length-1];t&&t.startTime<n.firstHiddenTime&&(i.value=Math.max(t.startTime-em(),0),i.entries=[t],r())},o=ey("largest-contentful-paint",s);if(o){r=ef(e,i,eq,t.reportAllChanges);let n=e_(()=>{eZ[i.id]||(s(o.takeRecords()),o.disconnect(),eZ[i.id]=!0,r(!0))});["keydown","click"].forEach(e=>{el.m.document&&addEventListener(e,()=>setTimeout(n,0),!0)}),ev(n)}})},eK=[800,1800],eV=e=>{el.m.document&&el.m.document.prerendering?ek(()=>eV(e)):el.m.document&&"complete"!==el.m.document.readyState?addEventListener("load",()=>eV(e),!0):setTimeout(e,0)},eQ=(e,t={})=>{let r=eg("TTFB"),n=ef(e,r,eK,t.reportAllChanges);eV(()=>{let e=ep();if(e){let t=e.responseStart;if(t<=0||t>performance.now())return;r.value=Math.max(t-em(),0),r.entries=[e],n(!0)}})},eX={},eJ={};function eY(e,t=!1){return te("cls",e,e9,i,t)}function e0(e,t=!1){return te("lcp",e,e8,o,t)}function e1(e){return te("fid",e,e5,s)}function e2(e){return te("inp",e,e7,u)}function e3(e,t){return tt(e,t),eJ[e]||(function(e){let t={};"event"===e&&(t.durationThreshold=0),ey(e,t=>{e4(e,{entries:t})},t)}(e),eJ[e]=!0),tr(e,t)}function e4(e,t){let r=eX[e];if(r&&r.length)for(let n of r)try{n(t)}catch(t){eu.X&&B.kg.error(`Error while triggering instrumentation handler.
Type: ${e}
Name: ${(0,ec.$P)(n)}
Error:`,t)}}function e9(){return eR(e=>{e4("cls",{metric:e}),i=e},{reportAllChanges:!0})}function e5(){return eA(e=>{e4("fid",{metric:e}),s=e})}function e8(){return eW(e=>{e4("lcp",{metric:e}),o=e},{reportAllChanges:!0})}function e6(){return eQ(e=>{e4("ttfb",{metric:e}),a=e})}function e7(){return eG(e=>{e4("inp",{metric:e}),u=e})}function te(e,t,r,n,i=!1){let s;return tt(e,t),eJ[e]||(s=r(),eJ[e]=!0),n&&t({metric:n}),tr(e,t,i?s:void 0)}function tt(e,t){eX[e]=eX[e]||[],eX[e].push(t)}function tr(e,t,r){return()=>{r&&r();let n=eX[e];if(!n)return;let i=n.indexOf(t);-1!==i&&n.splice(i,1)}}function tn(e){return"number"==typeof e&&isFinite(e)}function ti(e,t,r,{...n}){let i=(0,M.XU)(e).start_timestamp;return i&&i>t&&"function"==typeof e.updateStartTime&&e.updateStartTime(t),en(e,()=>{let e=er({startTime:t,...n});return e&&e.end(r),e})}function ts(){return el.m&&el.m.addEventListener&&el.m.performance}function to(e){return e/1e3}let ta=0,tu={};function tl(e,t,r,n,i,s){let o=s?t[s]:t[`${r}End`],a=t[`${r}Start`];a&&o&&ti(e,n+to(a),n+to(o),{op:"browser",name:i||r,attributes:{[L.S3]:"auto.ui.browser.metrics"}})}function tc(e,t,r,n){let i=t[r];null!=i&&i<2147483647&&(e[n]=i)}let td=[],tf=new Map,th={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};var tp=r(36708),tm=r(69737);let tg={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3};function ty(e,t={}){let r;let n=new Map,i=!1,s="externalFinish",o=!t.disableAutoFinish,a=[],{idleTimeout:u=tg.idleTimeout,finalTimeout:l=tg.finalTimeout,childSpanTimeout:c=tg.childSpanTimeout,beforeSpanEnd:d}=t,f=(0,C.s3)();if(!f||!I())return new H;let h=(0,C.nZ)(),p=(0,M.HN)(),m=function(e){let t=er(e);return(0,j.D)((0,C.nZ)(),t),F.X&&B.kg.log("[Tracing] Started span is an idle span"),t}(e);function g(){r&&(clearTimeout(r),r=void 0)}function y(e){g(),r=setTimeout(()=>{!i&&0===n.size&&o&&(s="idleTimeout",m.end(e))},u)}function v(e){r=setTimeout(()=>{!i&&o&&(s="heartbeatFailed",m.end(e))},c)}function _(e){i=!0,n.clear(),a.forEach(e=>e()),(0,j.D)(h,p);let t=(0,M.XU)(m),{start_timestamp:r}=t;if(!r)return;(t.data||{})[L.ju]||m.setAttribute(L.ju,s),B.kg.log(`[Tracing] Idle span "${t.op}" finished`);let o=(0,M.Dp)(m).filter(e=>e!==m),c=0;o.forEach(t=>{t.isRecording()&&(t.setStatus({code:tm.jt,message:"cancelled"}),t.end(e),F.X&&B.kg.log("[Tracing] Cancelling span since span ended early",JSON.stringify(t,void 0,2)));let{timestamp:r=0,start_timestamp:n=0}=(0,M.XU)(t),i=n<=e,s=r-n<=(l+u)/1e3;if(F.X){let e=JSON.stringify(t,void 0,2);i?s||B.kg.log("[Tracing] Discarding span since it finished after idle span final timeout",e):B.kg.log("[Tracing] Discarding span since it happened after idle span was finished",e)}(!s||!i)&&((0,M.ed)(m,t),c++)}),c>0&&m.setAttribute("sentry.idle_span_discarded_spans",c)}return m.end=new Proxy(m.end,{apply(e,t,r){d&&d(m);let[n,...i]=r,s=n||(0,G.ph)(),o=(0,M.$k)(s),a=(0,M.Dp)(m).filter(e=>e!==m);if(!a.length)return _(o),Reflect.apply(e,t,[o,...i]);let u=a.map(e=>(0,M.XU)(e).timestamp).filter(e=>!!e),c=u.length?Math.max(...u):void 0,f=(0,M.XU)(m).start_timestamp,h=Math.min(f?f+l/1e3:1/0,Math.max(f||-1/0,Math.min(o,c||1/0)));return _(h),Reflect.apply(e,t,[h,...i])}}),a.push(f.on("spanStart",e=>{if(!i&&e!==m&&!(0,M.XU)(e).timestamp&&(0,M.Dp)(m).includes(e)){var t;t=e.spanContext().spanId,g(),n.set(t,!0),v((0,G.ph)()+c/1e3)}})),a.push(f.on("spanEnd",e=>{var t;i||(t=e.spanContext().spanId,n.has(t)&&n.delete(t),0===n.size&&y((0,G.ph)()+u/1e3))})),a.push(f.on("idleSpanEnableAutoFinish",e=>{e===m&&(o=!0,y(),n.size&&v())})),t.disableAutoFinish||y(),setTimeout(()=>{i||(m.setStatus({code:tm.jt,message:"deadline_exceeded"}),s="finalTimeout",m.end())},l),m}var tv=r(7355),t_=r(40364);let tb=!1;function tS(){let e=(0,M.HN)(),t=e&&(0,M.Gx)(e);if(t){let e="internal_error";F.X&&B.kg.log(`[Tracing] Root span: ${e} -> Global error occured`),t.setStatus({code:tm.jt,message:e})}}tS.tag="sentry_tracingErrorCallback";var tE=r(85712),tw=r(19548),tO=r(70470),tk=r(22404),tT=r(67127),tC=r(60859),tI=r(16824),tR=r(69024),tx=r(89163);let tA=new WeakMap,tP=new Map,tM={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0};function tN(e){let{url:t}=(0,M.XU)(e).data||{};if(!t||"string"!=typeof t)return;let r=e3("resource",({entries:n})=>{n.forEach(n=>{"resource"===n.entryType&&"initiatorType"in n&&"string"==typeof n.nextHopProtocol&&("fetch"===n.initiatorType||"xmlhttprequest"===n.initiatorType)&&n.name.endsWith(t)&&((function(e){let{name:t,version:r}=function(e){let t="unknown",r="unknown",n="";for(let i of e){if("/"===i){[t,r]=e.split("/");break}if(!isNaN(Number(i))){t="h"===n?"http":n,r=e.split(n)[1];break}n+=i}return n===e&&(t=n),{name:t,version:r}}(e.nextHopProtocol),n=[];return(n.push(["network.protocol.version",r],["network.protocol.name",t]),G.Z1)?[...n,["http.request.redirect_start",tD(e.redirectStart)],["http.request.fetch_start",tD(e.fetchStart)],["http.request.domain_lookup_start",tD(e.domainLookupStart)],["http.request.domain_lookup_end",tD(e.domainLookupEnd)],["http.request.connect_start",tD(e.connectStart)],["http.request.secure_connection_start",tD(e.secureConnectionStart)],["http.request.connection_end",tD(e.connectEnd)],["http.request.request_start",tD(e.requestStart)],["http.request.response_start",tD(e.responseStart)],["http.request.response_end",tD(e.responseEnd)]]:n})(n).forEach(t=>e.setAttribute(...t)),setTimeout(r))})})}function tD(e=0){return((G.Z1||performance.timeOrigin)+e)/1e3}function tL(e){try{return new URL(e,tk.m9.location.origin).href}catch(e){return}}let tj={...tg,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroundSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!1,enableInp:!0,_experiments:{},...tM},tU=(e={})=>{tb||(tb=!0,(0,tv.V)(tS),(0,t_.h)(tS));let{enableInp:t,enableLongTask:r,enableLongAnimationFrame:n,_experiments:{enableInteractions:i},beforeStartSpan:s,idleTimeout:o,finalTimeout:u,childSpanTimeout:d,markBackgroundSpan:f,traceFetch:h,traceXHR:p,shouldCreateSpanForRequest:m,enableHTTPTimings:g,instrumentPageLoad:y,instrumentNavigation:v}={...tj,...e},_=function(){let e=ts();if(e&&G.Z1){e.mark&&el.m.performance.mark("sentry-tracing-init");let t=e1(({metric:e})=>{let t=e.entries[e.entries.length-1];if(!t)return;let r=to(G.Z1),n=to(t.startTime);eu.X&&B.kg.log("[Measurements] Adding FID"),tu.fid={value:e.value,unit:"millisecond"},tu["mark.fid"]={value:r+n,unit:"second"}}),r=eY(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(eu.X&&B.kg.log("[Measurements] Adding CLS"),tu.cls={value:e.value,unit:""},c=t)},!0),n=e0(({metric:e})=>{let t=e.entries[e.entries.length-1];t&&(eu.X&&B.kg.log("[Measurements] Adding LCP"),tu.lcp={value:e.value,unit:"millisecond"},l=t)},!0),i=te("ttfb",({metric:e})=>{e.entries[e.entries.length-1]&&(eu.X&&B.kg.log("[Measurements] Adding TTFB"),tu.ttfb={value:e.value,unit:"millisecond"})},e6,a);return()=>{t(),r(),n(),i()}}return()=>void 0}();t&&function(){if(ts()&&G.Z1){let e=e2(({metric:e})=>{let t;let r=(0,C.s3)();if(!r||void 0==e.value)return;let n=e.entries.find(t=>t.duration===e.value&&th[t.name]);if(!n)return;let{interactionId:i}=n,s=th[n.name],o=r.getOptions(),a=to(G.Z1+n.startTime),u=to(e.value),l=(0,C.nZ)(),c=(0,M.HN)(),d=c?(0,M.Gx)(c):void 0,f=(null!=i?tf.get(i):void 0)||d,h=f?(0,M.XU)(f).description:l.getScopeData().transactionName,p=l.getUser(),m=r.getIntegrationByName("Replay"),g=m&&m.getReplayId(),y=void 0!==p?p.email||p.id||p.ip_address:void 0;try{t=l.getScopeData().contexts.profile.profile_id}catch(e){}let v=er({name:(0,eo.Rt)(n.target),op:`ui.interaction.${s}`,attributes:(0,q.Jr)({release:o.release,environment:o.environment,transaction:h,[L.JQ]:e.value,[L.S3]:"auto.http.browser.inp",user:y||void 0,profile_id:t||void 0,replay_id:g||void 0,"user_agent.original":el.m.navigator&&el.m.navigator.userAgent}),startTime:a,experimental:{standalone:!0}});v.addEvent("inp",{[L.E1]:"millisecond",[L.Wb]:e.value}),v.end(a+u)})}}(),n&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?new PerformanceObserver(e=>{if((0,M.HN)())for(let t of e.getEntries()){if(!t.scripts[0])continue;let e=to(G.Z1+t.startTime),r=to(t.duration),n={[L.S3]:"auto.ui.browser.metrics"},{invoker:i,invokerType:s,sourceURL:o,sourceFunctionName:a,sourceCharPosition:u}=t.scripts[0];n["browser.script.invoker"]=i,n["browser.script.invoker_type"]=s,o&&(n["code.filepath"]=o),a&&(n["code.function"]=a),-1!==u&&(n["browser.script.source_char_position"]=u);let l=er({name:"Main UI thread blocked",op:"ui.long-animation-frame",startTime:e,attributes:n});l&&l.end(e+r)}}).observe({type:"long-animation-frame",buffered:!0}):r&&e3("longtask",({entries:e})=>{if((0,M.HN)())for(let t of e){let e=to(G.Z1+t.startTime),r=to(t.duration),n=er({name:"Main UI thread blocked",op:"ui.long-task",startTime:e,attributes:{[L.S3]:"auto.ui.browser.metrics"}});n&&n.end(e+r)}}),i&&e3("event",({entries:e})=>{if((0,M.HN)()){for(let t of e)if("click"===t.name){let e=to(G.Z1+t.startTime),r=to(t.duration),n={name:(0,eo.Rt)(t.target),op:`ui.interaction.${t.name}`,startTime:e,attributes:{[L.S3]:"auto.ui.browser.metrics"}},i=(0,eo.iY)(t.target);i&&(n.attributes["ui.component_name"]=i);let s=er(n);s&&s.end(e+r)}}});let b={name:void 0,source:void 0};function S(e,t){let r="pageload"===t.op,n=s?s(t):t,i=n.attributes||{};t.name!==n.name&&(i[L.Zj]="custom",n.attributes=i),b.name=n.name,b.source=i[L.Zj];let a=ty(n,{idleTimeout:o,finalTimeout:u,childSpanTimeout:d,disableAutoFinish:r,beforeSpanEnd:e=>{_(),function(e){let t=ts();if(!t||!el.m.performance.getEntries||!G.Z1)return;eu.X&&B.kg.log("[Tracing] Adding & adjusting spans using Performance API");let r=to(G.Z1),n=t.getEntries(),{op:i,start_timestamp:s}=(0,M.XU)(e);if(n.slice(ta).forEach(t=>{let n=to(t.startTime),o=to(Math.max(0,t.duration));if("navigation"!==i||!s||!(r+n<s))switch(t.entryType){case"navigation":["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(n=>{tl(e,t,n,r)}),tl(e,t,"secureConnection",r,"TLS/SSL","connectEnd"),tl(e,t,"fetch",r,"cache","domainLookupStart"),tl(e,t,"domainLookup",r,"DNS"),function(e,t,r){let n=r+to(t.requestStart),i=r+to(t.responseEnd),s=r+to(t.responseStart);t.responseEnd&&(ti(e,n,i,{op:"browser",name:"request",attributes:{[L.S3]:"auto.ui.browser.metrics"}}),ti(e,s,i,{op:"browser",name:"response",attributes:{[L.S3]:"auto.ui.browser.metrics"}}))}(e,t,r);break;case"mark":case"paint":case"measure":{(function(e,t,r,n,i){let s=ep(),o=i+Math.max(r,to(s?s.requestStart:0)),a=i+r,u={[L.S3]:"auto.resource.browser.metrics"};o!==a&&(u["sentry.browser.measure_happened_before_request"]=!0,u["sentry.browser.measure_start_time"]=o),ti(e,o,a+n,{name:t.name,op:t.entryType,attributes:u})})(e,t,n,o,r);let i=eO(),s=t.startTime<i.firstHiddenTime;"first-paint"===t.name&&s&&(eu.X&&B.kg.log("[Measurements] Adding FP"),tu.fp={value:t.startTime,unit:"millisecond"}),"first-contentful-paint"===t.name&&s&&(eu.X&&B.kg.log("[Measurements] Adding FCP"),tu.fcp={value:t.startTime,unit:"millisecond"});break}case"resource":(function(e,t,r,n,i,s){if("xmlhttprequest"===t.initiatorType||"fetch"===t.initiatorType)return;let o=(0,ea.en)(r),a={[L.S3]:"auto.resource.browser.metrics"};tc(a,t,"transferSize","http.response_transfer_size"),tc(a,t,"encodedBodySize","http.response_content_length"),tc(a,t,"decodedBodySize","http.decoded_response_content_length"),"renderBlockingStatus"in t&&(a["resource.render_blocking_status"]=t.renderBlockingStatus),o.protocol&&(a["url.scheme"]=o.protocol.split(":").pop()),o.host&&(a["server.address"]=o.host),a["url.same_origin"]=r.includes(el.m.location.origin);let u=s+n;ti(e,u,u+i,{name:r.replace(el.m.location.origin,""),op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",attributes:a})})(e,t,t.name,n,o,r)}}),ta=Math.max(n.length-1,0),function(e){let t=el.m.navigator;if(!t)return;let r=t.connection;r&&(r.effectiveType&&e.setAttribute("effectiveConnectionType",r.effectiveType),r.type&&e.setAttribute("connectionType",r.type),tn(r.rtt)&&(tu["connection.rtt"]={value:r.rtt,unit:"millisecond"})),tn(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),tn(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}(e),"pageload"===i){(function(e){let t=ep();if(!t)return;let{responseStart:r,requestStart:n}=t;n<=r&&(eu.X&&B.kg.log("[Measurements] Adding TTFB Request Time"),e["ttfb.requestTime"]={value:r-n,unit:"millisecond"})})(tu),["fcp","fp","lcp"].forEach(e=>{let t=tu[e];if(!t||!s||r>=s)return;let n=t.value,i=Math.abs((r+to(n)-s)*1e3),o=i-n;eu.X&&B.kg.log(`[Measurements] Normalized ${e} from ${n} to ${i} (${o})`),t.value=i});let t=tu["mark.fid"];t&&tu.fid&&(ti(e,t.value,t.value+to(tu.fid.value),{name:"first input delay",op:"ui.action",attributes:{[L.S3]:"auto.ui.browser.metrics"}}),delete tu["mark.fid"]),"fcp"in tu||delete tu.cls,Object.entries(tu).forEach(([e,t])=>{!function(e,t,r){let n=(0,M.HN)(),i=n&&(0,M.Gx)(n);i&&i.addEvent(e,{[L.Wb]:t,[L.E1]:r})}(e,t.value,t.unit)}),l&&(eu.X&&B.kg.log("[Measurements] Adding LCP Data"),l.element&&e.setAttribute("lcp.element",(0,eo.Rt)(l.element)),l.id&&e.setAttribute("lcp.id",l.id),l.url&&e.setAttribute("lcp.url",l.url.trim().slice(0,200)),e.setAttribute("lcp.size",l.size)),c&&c.sources&&(eu.X&&B.kg.log("[Measurements] Adding CLS Data"),c.sources.forEach((t,r)=>e.setAttribute(`cls.source.${r+1}`,(0,eo.Rt)(t.node))))}l=void 0,c=void 0,tu={}}(e)}});function f(){["interactive","complete"].includes(tk.m9.document.readyState)&&e.emit("idleSpanEnableAutoFinish",a)}return r&&tk.m9.document&&(tk.m9.document.addEventListener("readystatechange",()=>{f()}),f()),a}return{name:"BrowserTracing",afterAllSetup(e){let r,n;let s=tk.m9.location&&tk.m9.location.href;e.on("startNavigationSpan",t=>{(0,C.s3)()===e&&(r&&!(0,M.XU)(r).timestamp&&(tO.X&&B.kg.log(`[Tracing] Finishing current root span with op: ${(0,M.XU)(r).op}`),r.end()),r=S(e,{op:"navigation",...t}))}),e.on("startPageLoadSpan",(t,n={})=>{if((0,C.s3)()!==e)return;r&&!(0,M.XU)(r).timestamp&&(tO.X&&B.kg.log(`[Tracing] Finishing current root span with op: ${(0,M.XU)(r).op}`),r.end());let i=n.sentryTrace||t$("sentry-trace"),s=n.baggage||t$("baggage"),o=(0,tE.pT)(i,s);(0,C.nZ)().setPropagationContext(o),r=S(e,{op:"pageload",...t})}),e.on("spanEnd",e=>{let t=(0,M.XU)(e).op;if(e!==(0,M.Gx)(e)||"navigation"!==t&&"pageload"!==t)return;let r=(0,C.nZ)(),n=r.getPropagationContext();r.setPropagationContext({...n,sampled:void 0!==n.sampled?n.sampled:(0,M.Tt)(e),dsc:n.dsc||(0,U.jC)(e)})}),tk.m9.location&&(y&&tB(e,{name:tk.m9.location.pathname,startTime:G.Z1?G.Z1/1e3:void 0,attributes:{[L.Zj]:"url",[L.S3]:"auto.pageload.browser"}}),v&&(0,tp.a)(({to:t,from:r})=>{if(void 0===r&&s&&-1!==s.indexOf(t)){s=void 0;return}r!==t&&(s=void 0,tF(e,{name:tk.m9.location.pathname,attributes:{[L.Zj]:"url",[L.S3]:"auto.navigation.browser"}}))})),f&&(tk.m9&&tk.m9.document?tk.m9.document.addEventListener("visibilitychange",()=>{let e=(0,M.HN)();if(!e)return;let t=(0,M.Gx)(e);if(tk.m9.document.hidden&&t){let e="cancelled",{op:r,status:n}=(0,M.XU)(t);tO.X&&B.kg.log(`[Tracing] Transaction: ${e} -> since tab moved to the background, op: ${r}`),n||t.setStatus({code:tm.jt,message:e}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):tO.X&&B.kg.warn("[Tracing] Could not set up background tab detection due to lack of global document")),i&&tk.m9.document&&addEventListener("click",()=>{let e="ui.action.click",t=(0,M.HN)(),r=t&&(0,M.Gx)(t);if(r&&["navigation","pageload"].includes((0,M.XU)(r).op)){tO.X&&B.kg.warn(`[Tracing] Did not create ${e} span because a pageload or navigation span is in progress.`);return}if(n&&(n.setAttribute(L.ju,"interactionInterrupted"),n.end(),n=void 0),!b.name){tO.X&&B.kg.warn(`[Tracing] Did not create ${e} transaction because _latestRouteName is missing.`);return}n=ty({name:b.name,op:e,attributes:{[L.Zj]:b.source||"url"}},{idleTimeout:o,finalTimeout:u,childSpanTimeout:d})},{once:!1,capture:!0}),t&&function(){let e=({entries:e})=>{let t=(0,M.HN)(),r=t&&(0,M.Gx)(t);e.forEach(e=>{if(!("duration"in e)||!r)return;let t=e.interactionId;if(!(null==t||tf.has(t))){if(td.length>10){let e=td.shift();tf.delete(e)}td.push(t),tf.set(t,r)}})};e3("event",e),e3("first-input",e)}(),function(e,t){let{traceFetch:r,traceXHR:n,shouldCreateSpanForRequest:i,enableHTTPTimings:s,tracePropagationTargets:o}={traceFetch:tM.traceFetch,traceXHR:tM.traceXHR,...t},a="function"==typeof i?i:e=>!0,u=e=>(function(e,t){let r=tk.m9.location&&tk.m9.location.href;if(r){let n,i;try{n=new URL(e,r),i=new URL(r).origin}catch(e){return!1}let s=n.origin===i;return t?(0,tx.U0)(n.toString(),t)||s&&(0,tx.U0)(n.pathname,t):s}{let r=!!e.match(/^\/(?!\/)/);return t?(0,tx.U0)(e,t):r}})(e,o),l={};r&&(e.addEventProcessor(e=>("transaction"===e.type&&e.spans&&e.spans.forEach(e=>{if("http.client"===e.op){let t=tP.get(e.span_id);t&&(e.timestamp=t/1e3,tP.delete(e.span_id))}}),e)),(0,tR.cf)(e=>{if(e.response){let t=tA.get(e.response);t&&e.endTimestamp&&tP.set(t,e.endTimestamp)}}),(0,tR.Uf)(e=>{let t=function(e,t,r,n,i="auto.http.browser"){if(!e.fetchData)return;let s=I()&&t(e.fetchData.url);if(e.endTimestamp&&s){let t=e.fetchData.__span;if(!t)return;let r=n[t];r&&(function(e,t){if(t.response){(0,tm.Q0)(e,t.response.status);let r=t.response&&t.response.headers&&t.response.headers.get("content-length");if(r){let t=parseInt(r);t>0&&e.setAttribute("http.response_content_length",t)}}else t.error&&e.setStatus({code:tm.jt,message:"internal_error"});e.end()}(r,e),delete n[t]);return}let o=(0,C.nZ)(),a=(0,C.s3)(),{method:u,url:l}=e.fetchData,c=function(e){try{return new URL(e).href}catch(e){return}}(l),d=c?(0,ea.en)(c).host:void 0,f=!!(0,M.HN)(),h=s&&f?er({name:`${u} ${l}`,attributes:{url:l,type:"fetch","http.method":u,"http.url":c,"server.address":d,[L.S3]:i,[L.$J]:"http.client"}}):new H;if(e.fetchData.__span=h.spanContext().spanId,n[h.spanContext().spanId]=h,r(e.fetchData.url)&&a){let t=e.args[0];e.args[1]=e.args[1]||{};let r=e.args[1];r.headers=function(e,t,r,n,i){let{traceId:s,spanId:o,sampled:a,dsc:u}={...(0,C.aF)().getPropagationContext(),...r.getPropagationContext()},l=i?(0,M.Hb)(i):(0,tE.$p)(s,o,a),c=(0,tC.IQ)(u||(i?(0,U.jC)(i):(0,U._l)(s,t))),d=n.headers||("undefined"!=typeof Request&&(0,tI.V9)(e,Request)?e.headers:void 0);if(!d)return{"sentry-trace":l,baggage:c};if("undefined"!=typeof Headers&&(0,tI.V9)(d,Headers)){let e=new Headers(d);return e.append("sentry-trace",l),c&&e.append(tC.bU,c),e}if(Array.isArray(d)){let e=[...d,["sentry-trace",l]];return c&&e.push([tC.bU,c]),e}{let e="baggage"in d?d.baggage:void 0,t=[];return Array.isArray(e)?t.push(...e):e&&t.push(e),c&&t.push(c),{...d,"sentry-trace":l,baggage:t.length>0?t.join(","):void 0}}}(t,a,o,r,I()&&f?h:void 0)}return h}(e,a,u,l);if(e.response&&e.fetchData.__span&&tA.set(e.response,e.fetchData.__span),t){let r=tL(e.fetchData.url),n=r?(0,ea.en)(r).host:void 0;t.setAttributes({"http.url":r,"server.address":n})}s&&t&&tN(t)})),n&&(0,tT.UK)(e=>{let t=function(e,t,r,n){let i=e.xhr,s=i&&i[tT.xU];if(!i||i.__sentry_own_request__||!s)return;let o=I()&&t(s.url);if(e.endTimestamp&&o){let e=i.__sentry_xhr_span_id__;if(!e)return;let t=n[e];t&&void 0!==s.status_code&&((0,tm.Q0)(t,s.status_code),t.end(),delete n[e]);return}let a=tL(s.url),u=a?(0,ea.en)(a).host:void 0,l=!!(0,M.HN)(),c=o&&l?er({name:`${s.method} ${s.url}`,attributes:{type:"xhr","http.method":s.method,"http.url":a,url:s.url,"server.address":u,[L.S3]:"auto.http.browser",[L.$J]:"http.client"}}):new H;i.__sentry_xhr_span_id__=c.spanContext().spanId,n[i.__sentry_xhr_span_id__]=c;let d=(0,C.s3)();return i.setRequestHeader&&r(s.url)&&d&&function(e,t,r){let n=(0,C.nZ)(),{traceId:i,spanId:s,sampled:o,dsc:a}={...(0,C.aF)().getPropagationContext(),...n.getPropagationContext()};(function(e,t,r){try{e.setRequestHeader("sentry-trace",t),r&&e.setRequestHeader(tC.bU,r)}catch(e){}})(e,r&&I()?(0,M.Hb)(r):(0,tE.$p)(i,s,o),(0,tC.IQ)(a||(r?(0,U.jC)(r):(0,U._l)(i,t))))}(i,d,I()&&l?c:void 0),c}(e,a,u,l);s&&t&&tN(t)})}(e,{traceFetch:h,traceXHR:p,tracePropagationTargets:e.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:m,enableHTTPTimings:g})}}};function tB(e,t,r){e.emit("startPageLoadSpan",t,r),(0,C.nZ)().setTransactionName(t.name);let n=(0,M.HN)();return"pageload"===(n&&(0,M.XU)(n).op)?n:void 0}function tF(e,t){(0,C.aF)().setPropagationContext((0,tw.Q)()),(0,C.nZ)().setPropagationContext((0,tw.Q)()),e.emit("startNavigationSpan",t),(0,C.nZ)().setTransactionName(t.name);let r=(0,M.HN)();return"navigation"===(r&&(0,M.XU)(r).op)?r:void 0}function t$(e){let t=(0,eo.qT)(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}var tz=r(57608),tH=r(11163),tG=r(36096);let tq=tH.events?tH:tH.default,tZ=tk.m9;var tW=r(58942);let tK=/^(\S+:\\|\/?)([\s\S]*?)((?:\.{1,2}|[^/\\]+?|)(\.[^./\\]*|))(?:[/\\]*)$/;function tV(...e){let t="",r=!1;for(let n=e.length-1;n>=-1&&!r;n--){let i=n>=0?e[n]:"/";i&&(t=`${i}/${t}`,r="/"===i.charAt(0))}return t=(function(e,t){let r=0;for(let t=e.length-1;t>=0;t--){let n=e[t];"."===n?e.splice(t,1):".."===n?(e.splice(t,1),r++):r&&(e.splice(t,1),r--)}if(t)for(;r--;r)e.unshift("..");return e})(t.split("/").filter(e=>!!e),!r).join("/"),(r?"/":"")+t||"."}function tQ(e){let t=0;for(;t<e.length&&""===e[t];t++);let r=e.length-1;for(;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}let tX=(0,tW._I)((e={})=>{let t=e.root,r=e.prefix||"app:///",n="window"in A.GLOBAL_OBJ&&void 0!==A.GLOBAL_OBJ.window,i=e.iteratee||function({isBrowser:e,root:t,prefix:r}){return n=>{if(!n.filename)return n;let i=/^[a-zA-Z]:\\/.test(n.filename)||n.filename.includes("\\")&&!n.filename.includes("/"),s=/^\//.test(n.filename);if(e){if(t){let e=n.filename;0===e.indexOf(t)&&(n.filename=e.replace(t,r))}}else if(i||s){let e;let s=i?n.filename.replace(/^[a-zA-Z]:/,"").replace(/\\/g,"/"):n.filename,o=t?function(e,t){e=tV(e).slice(1),t=tV(t).slice(1);let r=tQ(e.split("/")),n=tQ(t.split("/")),i=Math.min(r.length,n.length),s=i;for(let e=0;e<i;e++)if(r[e]!==n[e]){s=e;break}let o=[];for(let e=s;e<r.length;e++)o.push("..");return(o=o.concat(n.slice(s))).join("/")}(t,s):function(e){let t=e.length>1024?`<truncated>${e.slice(-1024)}`:e,r=tK.exec(t);return r?r.slice(1):[]}(s)[2]||"";n.filename=`${r}${o}`}return n}}({isBrowser:n,root:t,prefix:r});return{name:"RewriteFrames",processEvent(e){let t=e;return e.exception&&Array.isArray(e.exception.values)&&(t=function(e){try{return{...e,exception:{...e.exception,values:e.exception.values.map(e=>{var t;return{...e,...e.stacktrace&&{stacktrace:{...t=e.stacktrace,frames:t&&t.frames&&t.frames.map(e=>i(e))}}}})}}}catch(t){return e}}(t)),t}}}),tJ=(0,tW._I)(({assetPrefixPath:e})=>({...tX({iteratee:t=>{try{let{origin:r}=new URL(t.filename);t.filename=(0,tz.x)([t,"access",e=>e.filename,"optionalAccess",e=>e.replace,"call",e=>e(r,"app://"),"access",e=>e.replace,"call",t=>t(e,"")])}catch(e){}return t.filename&&t.filename.startsWith("app:///_next")&&(t.filename=decodeURI(t.filename)),t.filename&&t.filename.match(/^app:\/\/\/_next\/static\/chunks\/(main-|main-app-|polyfills-|webpack-|framework-|framework\.)[0-9a-f]+\.js$/)&&(t.in_app=!1),t}}),name:"NextjsClientStackFrameNormalization"}));var tY=r(73326);let t0=A.GLOBAL_OBJ,t1=A.GLOBAL_OBJ;var t2=r(28643),t3=r(37895);function t4(e){return"/"===e[e.length-1]?e.slice(0,-1):e}var t9=r(76247),t5=r(83408),t8=r(39432),t6=r(80128),t7=r(83745),re=r(84281),rt=r(34155);function rr(){return"undefined"!=typeof window&&(!(!(0,re.n)()&&"[object process]"===Object.prototype.toString.call(void 0!==rt?rt:0))||void 0!==A.GLOBAL_OBJ.process&&"renderer"===A.GLOBAL_OBJ.process.type)}var rn=r(39877),ri=r(25460);let rs=A.GLOBAL_OBJ,ro="sentryReplaySession",ra="Unable to send Replay";function ru(e,t){return null!=e?e:t()}function rl(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}function rc(e){let t=rl([e,"optionalAccess",e=>e.host]);return rl([t,"optionalAccess",e=>e.shadowRoot])===e}function rd(e){return"[object ShadowRoot]"===Object.prototype.toString.call(e)}function rf(e){try{var t;let r=e.rules||e.cssRules;return r?((t=Array.from(r,rh).join("")).includes(" background-clip: text;")&&!t.includes(" -webkit-background-clip: text;")&&(t=t.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),t):null}catch(e){return null}}function rh(e){let t;if("styleSheet"in e)try{t=rf(e.styleSheet)||function(e){let{cssText:t}=e;if(t.split('"').length<3)return t;let r=["@import",`url(${JSON.stringify(e.href)})`];return""===e.layerName?r.push("layer"):e.layerName&&r.push(`layer(${e.layerName})`),e.supportsText&&r.push(`supports(${e.supportsText})`),e.media.length&&r.push(e.media.mediaText),r.join(" ")+";"}(e)}catch(e){}else if("selectorText"in e&&e.selectorText.includes(":"))return e.cssText.replace(/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm,"$1\\$2");return t||e.cssText}(y=w||(w={}))[y.Document=0]="Document",y[y.DocumentType=1]="DocumentType",y[y.Element=2]="Element",y[y.Text=3]="Text",y[y.CDATA=4]="CDATA",y[y.Comment=5]="Comment";class rp{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(e){return e?ru(rl([this,"access",e=>e.getMeta,"call",t=>t(e),"optionalAccess",e=>e.id]),()=>-1):-1}getNode(e){return this.idNodeMap.get(e)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(e){return this.nodeMetaMap.get(e)||null}removeNodeFromMap(e){let t=this.getId(e);this.idNodeMap.delete(t),e.childNodes&&e.childNodes.forEach(e=>this.removeNodeFromMap(e))}has(e){return this.idNodeMap.has(e)}hasNode(e){return this.nodeMetaMap.has(e)}add(e,t){let r=t.id;this.idNodeMap.set(r,e),this.nodeMetaMap.set(e,t)}replace(e,t){let r=this.getNode(e);if(r){let e=this.nodeMetaMap.get(r);e&&this.nodeMetaMap.set(t,e)}this.idNodeMap.set(e,t)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function rm({maskInputOptions:e,tagName:t,type:r}){return"OPTION"===t&&(t="SELECT"),!!(e[t.toLowerCase()]||r&&e[r]||"password"===r||"INPUT"===t&&!r&&e.text)}function rg({isMasked:e,element:t,value:r,maskInputFn:n}){let i=r||"";return e?(n&&(i=n(i,t)),"*".repeat(i.length)):i}function ry(e){return e.toLowerCase()}function rv(e){return e.toUpperCase()}let r_="__rrweb_original__";function rb(e){let t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?ry(t):null}function rS(e,t,r){return"INPUT"===t&&("radio"===r||"checkbox"===r)?e.getAttribute("value")||"":e.value}function rE(e,t){let r;try{r=new URL(e,ru(t,()=>window.location.href))}catch(e){return null}return ru(rl([r.pathname.match(/\.([0-9a-z]+)(?:$)/i),"optionalAccess",e=>e[1]]),()=>null)}let rw={};function rO(e){let t=rw[e];if(t)return t;let r=window.document,n=window[e];if(r&&"function"==typeof r.createElement)try{let t=r.createElement("iframe");t.hidden=!0,r.head.appendChild(t);let i=t.contentWindow;i&&i[e]&&(n=i[e]),r.head.removeChild(t)}catch(e){}return rw[e]=n.bind(window)}function rk(...e){return rO("setTimeout")(...e)}function rT(...e){return rO("clearTimeout")(...e)}let rC=1,rI=RegExp("[^a-z0-9-_:]");function rR(){return rC++}let rx=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,rA=/^(?:[a-z+]+:)?\/\//i,rP=/^www\..*/i,rM=/^(data:)([^,]*),(.*)/i;function rN(e,t){return(e||"").replace(rx,(e,r,n,i,s,o)=>{let a=n||s||o,u=r||i||"";if(!a)return e;if(rA.test(a)||rP.test(a)||rM.test(a))return`url(${u}${a}${u})`;if("/"===a[0])return`url(${u}${(t.indexOf("//")>-1?t.split("/").slice(0,3).join("/"):t.split("/")[0]).split("?")[0]+a}${u})`;let l=t.split("/"),c=a.split("/");for(let e of(l.pop(),c))"."!==e&&(".."===e?l.pop():l.push(e));return`url(${u}${l.join("/")}${u})`})}let rD=/^[^ \t\n\r\u000c]+/,rL=/^[, \t\n\r\u000c]+/;function rj(e,t){if(!t||""===t.trim())return t;let r=e.createElement("a");return r.href=t,r.href}function rU(){let e=document.createElement("a");return e.href="",e.href}function rB(e,t,r,n,i,s){return n?"src"!==r&&("href"!==r||"use"===t&&"#"===n[0])&&("xlink:href"!==r||"#"===n[0])&&("background"!==r||"table"!==t&&"td"!==t&&"th"!==t)?"srcset"===r?function(e,t){if(""===t.trim())return t;let r=0;function n(e){let n;let i=e.exec(t.substring(r));return i?(n=i[0],r+=n.length,n):""}let i=[];for(;n(rL),!(r>=t.length);){let s=n(rD);if(","===s.slice(-1))s=rj(e,s.substring(0,s.length-1)),i.push(s);else{let n="";s=rj(e,s);let o=!1;for(;;){let e=t.charAt(r);if(""===e){i.push((s+n).trim());break}if(o)")"===e&&(o=!1);else{if(","===e){r+=1,i.push((s+n).trim());break}"("===e&&(o=!0)}n+=e,r+=1}}}return i.join(", ")}(e,n):"style"===r?rN(n,rU()):"object"===t&&"data"===r?rj(e,n):"function"==typeof s?s(r,n,i):n:rj(e,n):n}function rF(e,t,r){return("video"===e||"audio"===e)&&"autoplay"===t}function r$(e,t,r=1/0,n=0){return!e||e.nodeType!==e.ELEMENT_NODE||n>r?-1:t(e)?n:r$(e.parentNode,t,r,n+1)}function rz(e,t){return r=>{if(null===r)return!1;try{if(e){if("string"==typeof e){if(r.matches(`.${e}`))return!0}else if(function(e,t){for(let r=e.classList.length;r--;){let n=e.classList[r];if(t.test(n))return!0}return!1}(r,e))return!0}if(t&&r.matches(t))return!0;return!1}catch(e){return!1}}}function rH(e,t,r,n,i,s){try{let o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(null===o)return!1;if("INPUT"===o.tagName){let e=o.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(e))return!0}let a=-1,u=-1;if(s){if((u=r$(o,rz(n,i)))<0)return!0;a=r$(o,rz(t,r),u>=0?u:1/0)}else{if((a=r$(o,rz(t,r)))<0)return!1;u=r$(o,rz(n,i),a>=0?a:1/0)}return a>=0?!(u>=0)||a<=u:!(u>=0)&&!!s}catch(e){}return!!s}function rG(e){return null==e?"":e.toLowerCase()}function rq(e,t){let r;let{doc:n,mirror:i,blockClass:s,blockSelector:o,unblockSelector:a,maskAllText:u,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,skipChild:m=!1,inlineStylesheet:g=!0,maskInputOptions:y={},maskAttributeFn:v,maskTextFn:_,maskInputFn:b,slimDOMOptions:S,dataURLOptions:E={},inlineImages:O=!1,recordCanvas:k=!1,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:I=5e3,onStylesheetLoad:R,stylesheetLoadTimeout:x=5e3,keepIframeSrcFn:A=()=>!1,newlyAddedElement:P=!1}=t,{preserveWhiteSpace:M=!0}=t,N=function(e,t){let{doc:r,mirror:n,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskAttributeFn:u,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,inlineStylesheet:m,maskInputOptions:g={},maskTextFn:y,maskInputFn:v,dataURLOptions:_={},inlineImages:b,recordCanvas:S,keepIframeSrcFn:E,newlyAddedElement:O=!1}=t,k=function(e,t){if(!t.hasNode(e))return;let r=t.getId(e);return 1===r?void 0:r}(r,n);switch(e.nodeType){case e.DOCUMENT_NODE:if("CSS1Compat"!==e.compatMode)return{type:w.Document,childNodes:[],compatMode:e.compatMode};return{type:w.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:w.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:k};case e.ELEMENT_NODE:return function(e,t){let r;let{doc:n,blockClass:i,blockSelector:s,unblockSelector:o,inlineStylesheet:a,maskInputOptions:u={},maskAttributeFn:l,maskInputFn:c,dataURLOptions:h={},inlineImages:p,recordCanvas:m,keepIframeSrcFn:g,newlyAddedElement:y=!1,rootId:v,maskAllText:_,maskTextClass:b,unmaskTextClass:S,maskTextSelector:E,unmaskTextSelector:O}=t,k=function(e,t,r,n){try{if(n&&e.matches(n))return!1;if("string"==typeof t){if(e.classList.contains(t))return!0}else for(let r=e.classList.length;r--;){let n=e.classList[r];if(t.test(n))return!0}if(r)return e.matches(r)}catch(e){}return!1}(e,i,s,o),T=function(e){if(e instanceof HTMLFormElement)return"form";let t=ry(e.tagName);return rI.test(t)?"div":t}(e),C={},I=e.attributes.length;for(let t=0;t<I;t++){let r=e.attributes[t];r.name&&!rF(T,r.name,r.value)&&(C[r.name]=rB(n,T,ry(r.name),r.value,e,l))}if("link"===T&&a){let t=Array.from(n.styleSheets).find(t=>t.href===e.href),r=null;t&&(r=rf(t)),r&&(delete C.rel,delete C.href,C._cssText=rN(r,t.href))}if("style"===T&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){let t=rf(e.sheet);t&&(C._cssText=rN(t,rU()))}if("input"===T||"textarea"===T||"select"===T||"option"===T){let t=rb(e),r=rS(e,rv(T),t),n=e.checked;if("submit"!==t&&"button"!==t&&r){let n=rH(e,b,E,S,O,rm({type:t,tagName:rv(T),maskInputOptions:u}));C.value=rg({isMasked:n,element:e,value:r,maskInputFn:c})}n&&(C.checked=n)}if("option"===T&&(e.selected&&!u.select?C.selected=!0:delete C.selected),"canvas"===T&&m){if("2d"===e.__context)!function(e){let t=e.getContext("2d");if(!t)return!0;for(let r=0;r<e.width;r+=50)for(let n=0;n<e.height;n+=50){let i=t.getImageData;if(new Uint32Array((r_ in i?i[r_]:i).call(t,r,n,Math.min(50,e.width-r),Math.min(50,e.height-n)).data.buffer).some(e=>0!==e))return!1}return!0}(e)&&(C.rr_dataURL=e.toDataURL(h.type,h.quality));else if(!("__context"in e)){let t=e.toDataURL(h.type,h.quality),r=document.createElement("canvas");r.width=e.width,r.height=e.height,t!==r.toDataURL(h.type,h.quality)&&(C.rr_dataURL=t)}}if("img"===T&&p){d||(f=(d=n.createElement("canvas")).getContext("2d"));let t=e.crossOrigin;e.crossOrigin="anonymous";let r=()=>{e.removeEventListener("load",r);try{d.width=e.naturalWidth,d.height=e.naturalHeight,f.drawImage(e,0,0),C.rr_dataURL=d.toDataURL(h.type,h.quality)}catch(t){console.warn(`Cannot inline img src=${e.currentSrc}! Error: ${t}`)}t?C.crossOrigin=t:e.removeAttribute("crossorigin")};e.complete&&0!==e.naturalWidth?r():e.addEventListener("load",r)}if(("audio"===T||"video"===T)&&(C.rr_mediaState=e.paused?"paused":"played",C.rr_mediaCurrentTime=e.currentTime),!y&&(e.scrollLeft&&(C.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(C.rr_scrollTop=e.scrollTop)),k){let{width:t,height:r}=e.getBoundingClientRect();C={class:C.class,rr_width:`${t}px`,rr_height:`${r}px`}}"iframe"!==T||g(C.src)||(k||e.contentDocument||(C.rr_src=C.src),delete C.src);try{customElements.get(T)&&(r=!0)}catch(e){}return{type:w.Element,tagName:T,attributes:C,childNodes:[],isSVG:!!("svg"===e.tagName||e.ownerSVGElement)||void 0,needBlock:k,rootId:v,isCustom:r}}(e,{doc:r,blockClass:i,blockSelector:s,unblockSelector:o,inlineStylesheet:m,maskAttributeFn:u,maskInputOptions:g,maskInputFn:v,dataURLOptions:_,inlineImages:b,recordCanvas:S,keepIframeSrcFn:E,newlyAddedElement:O,rootId:k,maskAllText:a,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p});case e.TEXT_NODE:return function(e,t){let{maskAllText:r,maskTextClass:n,unmaskTextClass:i,maskTextSelector:s,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:u,maskInputFn:l,rootId:c}=t,d=e.parentNode&&e.parentNode.tagName,f=e.textContent,h="STYLE"===d||void 0,p="SCRIPT"===d||void 0,m="TEXTAREA"===d||void 0;if(h&&f){try{e.nextSibling||e.previousSibling||rl([e,"access",e=>e.parentNode,"access",e=>e.sheet,"optionalAccess",e=>e.cssRules])&&(f=rf(e.parentNode.sheet))}catch(t){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${t}`,e)}f=rN(f,rU())}p&&(f="SCRIPT_PLACEHOLDER");let g=rH(e,n,s,i,o,r);return h||p||m||!f||!g||(f=a?a(f,e.parentElement):f.replace(/[\S]/g,"*")),m&&f&&(u.textarea||g)&&(f=l?l(f,e.parentNode):f.replace(/[\S]/g,"*")),"OPTION"===d&&f&&(f=rg({isMasked:rH(e,n,s,i,o,rm({type:null,tagName:d,maskInputOptions:u})),element:e,value:f,maskInputFn:l})),{type:w.Text,textContent:f||"",isStyle:h,rootId:c}}(e,{maskAllText:a,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,maskTextFn:y,maskInputOptions:g,maskInputFn:v,rootId:k});case e.CDATA_SECTION_NODE:return{type:w.CDATA,textContent:"",rootId:k};case e.COMMENT_NODE:return{type:w.Comment,textContent:e.textContent||"",rootId:k};default:return!1}}(e,{doc:n,mirror:i,blockClass:s,blockSelector:o,maskAllText:u,unblockSelector:a,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,inlineStylesheet:g,maskInputOptions:y,maskAttributeFn:v,maskTextFn:_,maskInputFn:b,dataURLOptions:E,inlineImages:O,recordCanvas:k,keepIframeSrcFn:A,newlyAddedElement:P});if(!N)return console.warn(e,"not serialized"),null;r=i.hasNode(e)?i.getId(e):!function(e,t){if(t.comment&&e.type===w.Comment)return!0;if(e.type===w.Element){if(t.script&&("script"===e.tagName||"link"===e.tagName&&("preload"===e.attributes.rel||"modulepreload"===e.attributes.rel)&&"script"===e.attributes.as||"link"===e.tagName&&"prefetch"===e.attributes.rel&&"string"==typeof e.attributes.href&&"js"===rE(e.attributes.href))||t.headFavicon&&("link"===e.tagName&&"shortcut icon"===e.attributes.rel||"meta"===e.tagName&&(rG(e.attributes.name).match(/^msapplication-tile(image|color)$/)||"application-name"===rG(e.attributes.name)||"icon"===rG(e.attributes.rel)||"apple-touch-icon"===rG(e.attributes.rel)||"shortcut icon"===rG(e.attributes.rel))))return!0;if("meta"===e.tagName){if(t.headMetaDescKeywords&&rG(e.attributes.name).match(/^description|keywords$/)||t.headMetaSocial&&(rG(e.attributes.property).match(/^(og|twitter|fb):/)||rG(e.attributes.name).match(/^(og|twitter):/)||"pinterest"===rG(e.attributes.name)))return!0;if(t.headMetaRobots&&("robots"===rG(e.attributes.name)||"googlebot"===rG(e.attributes.name)||"bingbot"===rG(e.attributes.name)))return!0;if(t.headMetaHttpEquiv&&void 0!==e.attributes["http-equiv"])return!0;else if(t.headMetaAuthorship&&("author"===rG(e.attributes.name)||"generator"===rG(e.attributes.name)||"framework"===rG(e.attributes.name)||"publisher"===rG(e.attributes.name)||"progid"===rG(e.attributes.name)||rG(e.attributes.property).match(/^article:/)||rG(e.attributes.property).match(/^product:/)))return!0;else if(t.headMetaVerification&&("google-site-verification"===rG(e.attributes.name)||"yandex-verification"===rG(e.attributes.name)||"csrf-token"===rG(e.attributes.name)||"p:domain_verify"===rG(e.attributes.name)||"verify-v1"===rG(e.attributes.name)||"verification"===rG(e.attributes.name)||"shopify-checkout-api-token"===rG(e.attributes.name)))return!0}}return!1}(N,S)&&(M||N.type!==w.Text||N.isStyle||N.textContent.replace(/^\s+|\s+$/gm,"").length)?rR():-2;let D=Object.assign(N,{id:r});if(i.add(e,D),-2===r)return null;T&&T(e);let L=!m;if(D.type===w.Element){L=L&&!D.needBlock,delete D.needBlock;let t=e.shadowRoot;t&&rd(t)&&(D.isShadowHost=!0)}if((D.type===w.Document||D.type===w.Element)&&L){S.headWhitespace&&D.type===w.Element&&"head"===D.tagName&&(M=!1);let t={doc:n,mirror:i,blockClass:s,blockSelector:o,maskAllText:u,unblockSelector:a,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,skipChild:m,inlineStylesheet:g,maskInputOptions:y,maskAttributeFn:v,maskTextFn:_,maskInputFn:b,slimDOMOptions:S,dataURLOptions:E,inlineImages:O,recordCanvas:k,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:I,onStylesheetLoad:R,stylesheetLoadTimeout:x,keepIframeSrcFn:A};for(let r of Array.from(e.childNodes)){let e=rq(r,t);e&&D.childNodes.push(e)}if(e.nodeType===e.ELEMENT_NODE&&e.shadowRoot)for(let r of Array.from(e.shadowRoot.childNodes)){let n=rq(r,t);n&&(rd(e.shadowRoot)&&(n.isShadow=!0),D.childNodes.push(n))}}return e.parentNode&&rc(e.parentNode)&&rd(e.parentNode)&&(D.isShadow=!0),D.type===w.Element&&"iframe"===D.tagName&&function(e,t,r){let n;let i=e.contentWindow;if(!i)return;let s=!1;try{n=i.document.readyState}catch(e){return}if("complete"!==n){let n=rk(()=>{s||(t(),s=!0)},r);e.addEventListener("load",()=>{rT(n),s=!0,t()});return}let o="about:blank";if(i.location.href!==o||e.src===o||""===e.src)return rk(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}(e,()=>{let t=e.contentDocument;if(t&&C){let r=rq(t,{doc:t,mirror:i,blockClass:s,blockSelector:o,unblockSelector:a,maskAllText:u,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,skipChild:!1,inlineStylesheet:g,maskInputOptions:y,maskAttributeFn:v,maskTextFn:_,maskInputFn:b,slimDOMOptions:S,dataURLOptions:E,inlineImages:O,recordCanvas:k,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:I,onStylesheetLoad:R,stylesheetLoadTimeout:x,keepIframeSrcFn:A});r&&C(e,r)}},I),D.type===w.Element&&"link"===D.tagName&&"string"==typeof D.attributes.rel&&("stylesheet"===D.attributes.rel||"preload"===D.attributes.rel&&"string"==typeof D.attributes.href&&"css"===rE(D.attributes.href))&&function(e,t,r){let n,i=!1;try{n=e.sheet}catch(e){return}if(n)return;let s=rk(()=>{i||(t(),i=!0)},r);e.addEventListener("load",()=>{rT(s),i=!0,t()})}(e,()=>{if(R){let t=rq(e,{doc:n,mirror:i,blockClass:s,blockSelector:o,unblockSelector:a,maskAllText:u,maskTextClass:l,unmaskTextClass:c,maskTextSelector:h,unmaskTextSelector:p,skipChild:!1,inlineStylesheet:g,maskInputOptions:y,maskAttributeFn:v,maskTextFn:_,maskInputFn:b,slimDOMOptions:S,dataURLOptions:E,inlineImages:O,recordCanvas:k,preserveWhiteSpace:M,onSerialize:T,onIframeLoad:C,iframeLoadTimeout:I,onStylesheetLoad:R,stylesheetLoadTimeout:x,keepIframeSrcFn:A});t&&R(e,t)}},x),D}function rZ(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}function rW(e,t,r=document){let n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}let rK="Please stop import mirror directly. Instead of that,\r\nnow you can use replayer.getMirror() to access the mirror instance of a replayer,\r\nor you can use record.mirror to access the mirror instance during recording.",rV={map:{},getId:()=>(console.error(rK),-1),getNode:()=>(console.error(rK),null),removeNodeFromMap(){console.error(rK)},has:()=>(console.error(rK),!1),reset(){console.error(rK)}};function rQ(e,t,r={}){let n=null,i=0;return function(...s){let o=Date.now();i||!1!==r.leading||(i=o);let a=t-(o-i),u=this;a<=0||a>t?(n&&(function(...e){nn("clearTimeout")(...e)}(n),n=null),i=o,e.apply(u,s)):n||!1===r.trailing||(n=ni(()=>{i=!1===r.leading?0:Date.now(),n=null,e.apply(u,s)},a))}}function rX(e,t,r){try{if(!(t in e))return()=>{};let n=e[t],i=r(n);return"function"==typeof i&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:n}})),e[t]=i,()=>{e[t]=n}}catch(e){return()=>{}}}"undefined"!=typeof window&&window.Proxy&&window.Reflect&&(rV=new Proxy(rV,{get:(e,t,r)=>("map"===t&&console.error(rK),Reflect.get(e,t,r))}));let rJ=Date.now;function rY(e){let t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:void 0!==e.pageXOffset?e.pageXOffset:rZ([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollLeft])||rZ([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollLeft])||rZ([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollLeft])||0,top:t.scrollingElement?t.scrollingElement.scrollTop:void 0!==e.pageYOffset?e.pageYOffset:rZ([t,"optionalAccess",e=>e.documentElement,"access",e=>e.scrollTop])||rZ([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.parentElement,"optionalAccess",e=>e.scrollTop])||rZ([t,"optionalAccess",e=>e.body,"optionalAccess",e=>e.scrollTop])||0}}function r0(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function r1(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function r2(e){return e?e.nodeType===e.ELEMENT_NODE?e:e.parentElement:null}function r3(e,t,r,n,i){if(!e)return!1;let s=r2(e);if(!s)return!1;let o=rz(t,r);if(!i){let e=n&&s.matches(n);return o(s)&&!e}let a=r$(s,o),u=-1;return!(a<0)&&(n&&(u=r$(s,rz(null,n))),a>-1&&u<0||a<u)}function r4(e,t){return -2===t.getId(e)}function r9(e){return!!e.changedTouches}function r5(e,t){return!!("IFRAME"===e.nodeName&&t.getMeta(e))}function r8(e,t){return!!("LINK"===e.nodeName&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&"stylesheet"===e.getAttribute("rel")&&t.getMeta(e))}function r6(e){return!!rZ([e,"optionalAccess",e=>e.shadowRoot])}/[1-9][0-9]{12}/.test(Date.now().toString())||(rJ=()=>new Date().getTime());class r7{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(e){return(0,t2.h)(this.styleIDMap.get(e),()=>-1)}has(e){return this.styleIDMap.has(e)}add(e,t){let r;return this.has(e)?this.getId(e):(r=void 0===t?this.id++:t,this.styleIDMap.set(e,r),this.idStyleMap.set(r,e),r)}getStyle(e){return this.idStyleMap.get(e)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function ne(e){let t=null;return rZ([e,"access",e=>e.getRootNode,"optionalCall",e=>e(),"optionalAccess",e=>e.nodeType])===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function nt(e){let t=e.ownerDocument;return!!t&&(t.contains(e)||function(e){let t=e.ownerDocument;if(!t)return!1;let r=function(e){let t,r=e;for(;t=ne(r);)r=t;return r}(e);return t.contains(r)}(e))}let nr={};function nn(e){let t=nr[e];if(t)return t;let r=window.document,n=window[e];if(r&&"function"==typeof r.createElement)try{let t=r.createElement("iframe");t.hidden=!0,r.head.appendChild(t);let i=t.contentWindow;i&&i[e]&&(n=i[e]),r.head.removeChild(t)}catch(e){}return nr[e]=n.bind(window)}function ni(...e){return nn("setTimeout")(...e)}var ns=((v=ns||{})[v.DomContentLoaded=0]="DomContentLoaded",v[v.Load=1]="Load",v[v.FullSnapshot=2]="FullSnapshot",v[v.IncrementalSnapshot=3]="IncrementalSnapshot",v[v.Meta=4]="Meta",v[v.Custom=5]="Custom",v[v.Plugin=6]="Plugin",v),no=((_=no||{})[_.Mutation=0]="Mutation",_[_.MouseMove=1]="MouseMove",_[_.MouseInteraction=2]="MouseInteraction",_[_.Scroll=3]="Scroll",_[_.ViewportResize=4]="ViewportResize",_[_.Input=5]="Input",_[_.TouchMove=6]="TouchMove",_[_.MediaInteraction=7]="MediaInteraction",_[_.StyleSheetRule=8]="StyleSheetRule",_[_.CanvasMutation=9]="CanvasMutation",_[_.Font=10]="Font",_[_.Log=11]="Log",_[_.Drag=12]="Drag",_[_.StyleDeclaration=13]="StyleDeclaration",_[_.Selection=14]="Selection",_[_.AdoptedStyleSheet=15]="AdoptedStyleSheet",_[_.CustomElement=16]="CustomElement",_),na=((b=na||{})[b.MouseUp=0]="MouseUp",b[b.MouseDown=1]="MouseDown",b[b.Click=2]="Click",b[b.ContextMenu=3]="ContextMenu",b[b.DblClick=4]="DblClick",b[b.Focus=5]="Focus",b[b.Blur=6]="Blur",b[b.TouchStart=7]="TouchStart",b[b.TouchMove_Departed=8]="TouchMove_Departed",b[b.TouchEnd=9]="TouchEnd",b[b.TouchCancel=10]="TouchCancel",b),nu=((S=nu||{})[S.Mouse=0]="Mouse",S[S.Pen=1]="Pen",S[S.Touch=2]="Touch",S);class nl{constructor(){this.length=0,this.head=null,this.tail=null}get(e){if(e>=this.length)throw Error("Position outside of list range");let t=this.head;for(let r=0;r<e;r++)t=function(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}([t,"optionalAccess",e=>e.next])||null;return t}addNode(e){let t={value:e,previous:null,next:null};if(e.__ln=t,e.previousSibling&&"__ln"in e.previousSibling){let r=e.previousSibling.__ln.next;t.next=r,t.previous=e.previousSibling.__ln,e.previousSibling.__ln.next=t,r&&(r.previous=t)}else if(e.nextSibling&&"__ln"in e.nextSibling&&e.nextSibling.__ln.previous){let r=e.nextSibling.__ln.previous;t.previous=r,t.next=e.nextSibling.__ln,e.nextSibling.__ln.previous=t,r&&(r.next=t)}else this.head&&(this.head.previous=t),t.next=this.head,this.head=t;null===t.next&&(this.tail=t),this.length++}removeNode(e){let t=e.__ln;this.head&&(t.previous?(t.previous.next=t.next,t.next?t.next.previous=t.previous:this.tail=t.previous):(this.head=t.next,this.head?this.head.previous=null:this.tail=null),e.__ln&&delete e.__ln,this.length--)}}let nc=(e,t)=>`${e}@${t}`;class nd{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=e=>{e.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;let e=[],t=new Set,r=new nl,n=e=>{let t=e,r=-2;for(;-2===r;)r=(t=t&&t.nextSibling)&&this.mirror.getId(t);return r},i=i=>{if(!i.parentNode||!nt(i))return;let s=rc(i.parentNode)?this.mirror.getId(ne(i)):this.mirror.getId(i.parentNode),o=n(i);if(-1===s||-1===o)return r.addNode(i);let a=rq(i,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:e=>{r5(e,this.mirror)&&this.iframeManager.addIframe(e),r8(e,this.mirror)&&this.stylesheetManager.trackLinkElement(e),r6(i)&&this.shadowDomManager.addShadowRoot(i.shadowRoot,this.doc)},onIframeLoad:(e,t)=>{this.iframeManager.attachIframe(e,t),e.contentWindow&&this.canvasManager.addWindow(e.contentWindow),this.shadowDomManager.observeAttachShadow(e)},onStylesheetLoad:(e,t)=>{this.stylesheetManager.attachLinkElement(e,t)}});a&&(e.push({parentId:s,nextId:o,node:a}),t.add(a.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(let e of this.movedSet)(!nh(this.removes,e,this.mirror)||this.movedSet.has(e.parentNode))&&i(e);for(let e of this.addedSet)np(this.droppedSet,e)||nh(this.removes,e,this.mirror)?np(this.movedSet,e)?i(e):this.droppedSet.add(e):i(e);let s=null;for(;r.length;){let e=null;if(s){let t=this.mirror.getId(s.value.parentNode),r=n(s.value);-1!==t&&-1!==r&&(e=s)}if(!e){let t=r.tail;for(;t;){let r=t;if(t=t.previous,r){let t=this.mirror.getId(r.value.parentNode);if(-1===n(r.value))continue;if(-1!==t){e=r;break}{let t=r.value;if(t.parentNode&&t.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){let n=t.parentNode.host;if(-1!==this.mirror.getId(n)){e=r;break}}}}}}if(!e){for(;r.head;)r.removeNode(r.head.value);break}s=e.previous,r.removeNode(e.value),i(e.value)}let o={texts:this.texts.map(e=>({id:this.mirror.getId(e.node),value:e.value})).filter(e=>!t.has(e.id)).filter(e=>this.mirror.has(e.id)),attributes:this.attributes.map(e=>{let{attributes:t}=e;if("string"==typeof t.style){let r=JSON.stringify(e.styleDiff),n=JSON.stringify(e._unchangedStyles);r.length<t.style.length&&(r+n).split("var(").length===t.style.split("var(").length&&(t.style=e.styleDiff)}return{id:this.mirror.getId(e.node),attributes:t}}).filter(e=>!t.has(e.id)).filter(e=>this.mirror.has(e.id)),removes:this.removes,adds:e};(o.texts.length||o.attributes.length||o.removes.length||o.adds.length)&&(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(o))},this.processMutation=e=>{if(!r4(e.target,this.mirror))switch(e.type){case"characterData":{let t=e.target.textContent;r3(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||t===e.oldValue||this.texts.push({value:rH(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&t?this.maskTextFn?this.maskTextFn(t,r2(e.target)):t.replace(/[\S]/g,"*"):t,node:e.target});break}case"attributes":{let t=e.target,r=e.attributeName,n=e.target.getAttribute(r);if("value"===r){let r=rb(t),i=t.tagName;n=rS(t,i,r);let s=rm({maskInputOptions:this.maskInputOptions,tagName:i,type:r});n=rg({isMasked:rH(e.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,s),element:t,value:n,maskInputFn:this.maskInputFn})}if(r3(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||n===e.oldValue)return;let i=this.attributeMap.get(e.target);if("IFRAME"===t.tagName&&"src"===r&&!this.keepIframeSrcFn(n)){if(t.contentDocument)return;r="rr_src"}if(i||(i={node:e.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(i),this.attributeMap.set(e.target,i)),"type"===r&&"INPUT"===t.tagName&&"password"===(e.oldValue||"").toLowerCase()&&t.setAttribute("data-rr-is-password","true"),!rF(t.tagName,r)&&(i.attributes[r]=rB(this.doc,ry(t.tagName),ry(r),n,t,this.maskAttributeFn),"style"===r)){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch(e){this.unattachedDoc=this.doc}let r=this.unattachedDoc.createElement("span");for(let n of(e.oldValue&&r.setAttribute("style",e.oldValue),Array.from(t.style))){let e=t.style.getPropertyValue(n),s=t.style.getPropertyPriority(n);e!==r.style.getPropertyValue(n)||s!==r.style.getPropertyPriority(n)?""===s?i.styleDiff[n]=e:i.styleDiff[n]=[e,s]:i._unchangedStyles[n]=[e,s]}for(let e of Array.from(r.style))""===t.style.getPropertyValue(e)&&(i.styleDiff[e]=!1)}break}case"childList":if(r3(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;e.addedNodes.forEach(t=>this.genAdds(t,e.target)),e.removedNodes.forEach(t=>{let r=this.mirror.getId(t),n=rc(e.target)?this.mirror.getId(e.target.host):this.mirror.getId(e.target);r3(e.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||r4(t,this.mirror)||-1===this.mirror.getId(t)||(this.addedSet.has(t)?(nf(this.addedSet,t),this.droppedSet.add(t)):this.addedSet.has(e.target)&&-1===r||function e(t,r){if(rc(t))return!1;let n=r.getId(t);return!r.has(n)||(!t.parentNode||t.parentNode.nodeType!==t.DOCUMENT_NODE)&&(!t.parentNode||e(t.parentNode,r))}(e.target,this.mirror)||(this.movedSet.has(t)&&this.movedMap[nc(r,n)]?nf(this.movedSet,t):this.removes.push({parentId:n,id:r,isShadow:!!(rc(e.target)&&rd(e.target))||void 0})),this.mapRemoves.push(t))})}},this.genAdds=(e,t)=>{if(!this.processedNodeManager.inOtherBuffer(e,this)&&!(this.addedSet.has(e)||this.movedSet.has(e))){if(this.mirror.hasNode(e)){if(r4(e,this.mirror))return;this.movedSet.add(e);let r=null;t&&this.mirror.hasNode(t)&&(r=this.mirror.getId(t)),r&&-1!==r&&(this.movedMap[nc(this.mirror.getId(e),r)]=!0)}else this.addedSet.add(e),this.droppedSet.delete(e);!r3(e,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&(e.childNodes.forEach(e=>this.genAdds(e)),r6(e)&&e.shadowRoot.childNodes.forEach(t=>{this.processedNodeManager.add(t,this),this.genAdds(t,e)}))}}}init(e){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager"].forEach(t=>{this[t]=e[t]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function nf(e,t){e.delete(t),t.childNodes.forEach(t=>nf(e,t))}function nh(e,t,r){return 0!==e.length&&function e(t,r,n){let{parentNode:i}=r;if(!i)return!1;let s=n.getId(i);return!!t.some(e=>e.id===s)||e(t,i,n)}(e,t,r)}function np(e,t){return 0!==e.size&&function e(t,r){let{parentNode:n}=r;return!!n&&(!!t.has(n)||e(t,n))}(e,t)}let nm=e=>h?(...t)=>{try{return e(...t)}catch(e){if(h&&!0===h(e))return()=>{};throw e}}:e;function ng(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}let ny=[];function nv(e){try{if("composedPath"in e){let t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch(e){}return e&&e.target}function n_(e,t){let r=new nd;ny.push(r),r.init(e);let n=window.MutationObserver||window.__rrMutationObserver,i=ng([window,"optionalAccess",e=>e.Zone,"optionalAccess",e=>e.__symbol__,"optionalCall",e=>e("MutationObserver")]);i&&window[i]&&(n=window[i]);let s=new n(nm(t=>{e.onMutation&&!1===e.onMutation(t)||r.processMutations.bind(r)(t)}));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function nb({scrollCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:s,sampling:o}){return rW("scroll",nm(rQ(nm(o=>{let a=nv(o);if(!a||r3(a,n,i,s,!0))return;let u=r.getId(a);if(a===t&&t.defaultView){let r=rY(t.defaultView);e({id:u,x:r.left,y:r.top})}else e({id:u,x:a.scrollLeft,y:a.scrollTop})}),o.scroll||100)),t)}let nS=["INPUT","TEXTAREA","SELECT"],nE=new WeakMap;function nw(e){var t;return t=[],nC("CSSGroupingRule")&&e.parentRule instanceof CSSGroupingRule||nC("CSSMediaRule")&&e.parentRule instanceof CSSMediaRule||nC("CSSSupportsRule")&&e.parentRule instanceof CSSSupportsRule||nC("CSSConditionRule")&&e.parentRule instanceof CSSConditionRule?t.unshift(Array.from(e.parentRule.cssRules).indexOf(e)):e.parentStyleSheet&&t.unshift(Array.from(e.parentStyleSheet.cssRules).indexOf(e)),t}function nO(e,t,r){let n,i;return e?(e.ownerNode?n=t.getId(e.ownerNode):i=r.getId(e),{styleId:i,id:n}):{}}function nk({mirror:e,stylesheetManager:t},r){let n=null;n="#document"===r.nodeName?e.getId(r):e.getId(r.host);let i="#document"===r.nodeName?ng([r,"access",e=>e.defaultView,"optionalAccess",e=>e.Document]):ng([r,"access",e=>e.ownerDocument,"optionalAccess",e=>e.defaultView,"optionalAccess",e=>e.ShadowRoot]),s=ng([i,"optionalAccess",e=>e.prototype])?Object.getOwnPropertyDescriptor(ng([i,"optionalAccess",e=>e.prototype]),"adoptedStyleSheets"):void 0;return null!==n&&-1!==n&&i&&s?(Object.defineProperty(r,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){return ng([s,"access",e=>e.get,"optionalAccess",e=>e.call,"call",e=>e(this)])},set(e){let r=ng([s,"access",e=>e.set,"optionalAccess",e=>e.call,"call",t=>t(this,e)]);if(null!==n&&-1!==n)try{t.adoptStyleSheets(e,n)}catch(e){}return r}}),nm(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})})):()=>{}}function nT(e,t={}){let r;let n=e.doc.defaultView;if(!n)return()=>{};e.recordDOM&&(r=n_(e,e.doc));let i=function({mousemoveCb:e,sampling:t,doc:r,mirror:n}){let i;if(!1===t.mousemove)return()=>{};let s="number"==typeof t.mousemove?t.mousemove:50,o="number"==typeof t.mousemoveCallback?t.mousemoveCallback:500,a=[],u=rQ(nm(t=>{let r=Date.now()-i;e(a.map(e=>(e.timeOffset-=r,e)),t),a=[],i=null}),o),l=nm(rQ(nm(e=>{let t=nv(e),{clientX:r,clientY:s}=r9(e)?e.changedTouches[0]:e;i||(i=rJ()),a.push({x:r,y:s,id:n.getId(t),timeOffset:rJ()-i}),u("undefined"!=typeof DragEvent&&e instanceof DragEvent?no.Drag:e instanceof MouseEvent?no.MouseMove:no.TouchMove)}),s,{trailing:!1})),c=[rW("mousemove",l,r),rW("touchmove",l,r),rW("drag",l,r)];return nm(()=>{c.forEach(e=>e())})}(e),s=function({mouseInteractionCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:s,sampling:o}){if(!1===o.mouseInteraction)return()=>{};let a=!0===o.mouseInteraction||void 0===o.mouseInteraction?{}:o.mouseInteraction,u=[],l=null,c=t=>o=>{let a=nv(o);if(r3(a,n,i,s,!0))return;let u=null,c=t;if("pointerType"in o){switch(o.pointerType){case"mouse":u=nu.Mouse;break;case"touch":u=nu.Touch;break;case"pen":u=nu.Pen}u===nu.Touch?na[t]===na.MouseDown?c="TouchStart":na[t]===na.MouseUp&&(c="TouchEnd"):nu.Pen}else r9(o)&&(u=nu.Touch);null!==u?(l=u,(c.startsWith("Touch")&&u===nu.Touch||c.startsWith("Mouse")&&u===nu.Mouse)&&(u=null)):na[t]===na.Click&&(u=l,l=null);let d=r9(o)?o.changedTouches[0]:o;if(!d)return;let f=r.getId(a),{clientX:h,clientY:p}=d;nm(e)({type:na[c],id:f,x:h,y:p,...null!==u&&{pointerType:u}})};return Object.keys(na).filter(e=>Number.isNaN(Number(e))&&!e.endsWith("_Departed")&&!1!==a[e]).forEach(e=>{let r=ry(e),n=c(e);if(window.PointerEvent)switch(na[e]){case na.MouseDown:case na.MouseUp:r=r.replace("mouse","pointer");break;case na.TouchStart:case na.TouchEnd:return}u.push(rW(r,n,t))}),nm(()=>{u.forEach(e=>e())})}(e),o=nb(e),a=function({viewportResizeCb:e},{win:t}){let r=-1,n=-1;return rW("resize",nm(rQ(nm(()=>{let t=r0(),i=r1();(r!==t||n!==i)&&(e({width:Number(i),height:Number(t)}),r=t,n=i)}),200)),t)}(e,{win:n}),u=function({inputCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:s,ignoreClass:o,ignoreSelector:a,maskInputOptions:u,maskInputFn:l,sampling:c,userTriggeredOnInput:d,maskTextClass:f,unmaskTextClass:h,maskTextSelector:p,unmaskTextSelector:m}){function g(e){let r=nv(e),c=e.isTrusted,g=r&&rv(r.tagName);if("OPTION"===g&&(r=r.parentElement),!r||!g||0>nS.indexOf(g)||r3(r,n,i,s,!0))return;let v=r;if(v.classList.contains(o)||a&&v.matches(a))return;let _=rb(r),b=rS(v,g,_),S=!1,E=rm({maskInputOptions:u,tagName:g,type:_}),w=rH(r,f,p,h,m,E);("radio"===_||"checkbox"===_)&&(S=r.checked),b=rg({isMasked:w,element:r,value:b,maskInputFn:l}),y(r,d?{text:b,isChecked:S,userTriggered:c}:{text:b,isChecked:S});let O=r.name;"radio"===_&&O&&S&&t.querySelectorAll(`input[type="radio"][name="${O}"]`).forEach(e=>{if(e!==r){let t=rg({isMasked:w,element:e,value:rS(e,g,_),maskInputFn:l});y(e,d?{text:t,isChecked:!S,userTriggered:!1}:{text:t,isChecked:!S})}})}function y(t,n){let i=nE.get(t);if(!i||i.text!==n.text||i.isChecked!==n.isChecked){nE.set(t,n);let i=r.getId(t);nm(e)({...n,id:i})}}let v=("last"===c.input?["change"]:["input","change"]).map(e=>rW(e,nm(g),t)),_=t.defaultView;if(!_)return()=>{v.forEach(e=>e())};let b=_.Object.getOwnPropertyDescriptor(_.HTMLInputElement.prototype,"value"),S=[[_.HTMLInputElement.prototype,"value"],[_.HTMLInputElement.prototype,"checked"],[_.HTMLSelectElement.prototype,"value"],[_.HTMLTextAreaElement.prototype,"value"],[_.HTMLSelectElement.prototype,"selectedIndex"],[_.HTMLOptionElement.prototype,"selected"]];return b&&b.set&&v.push(...S.map(e=>(function e(t,r,n,i,s=window){let o=s.Object.getOwnPropertyDescriptor(t,r);return s.Object.defineProperty(t,r,i?n:{set(e){ni(()=>{n.set.call(this,e)},0),o&&o.set&&o.set.call(this,e)}}),()=>e(t,r,o||{},!0)})(e[0],e[1],{set(){nm(g)({target:this,isTrusted:!1})}},!1,_))),nm(()=>{v.forEach(e=>e())})}(e),l=function({mediaInteractionCb:e,blockClass:t,blockSelector:r,unblockSelector:n,mirror:i,sampling:s,doc:o}){let a=nm(o=>rQ(nm(s=>{let a=nv(s);if(!a||r3(a,t,r,n,!0))return;let{currentTime:u,volume:l,muted:c,playbackRate:d}=a;e({type:o,id:i.getId(a),currentTime:u,volume:l,muted:c,playbackRate:d})}),s.media||500)),u=[rW("play",a(0),o),rW("pause",a(1),o),rW("seeked",a(2),o),rW("volumechange",a(3),o),rW("ratechange",a(4),o)];return nm(()=>{u.forEach(e=>e())})}(e),c=()=>{},d=()=>{},f=()=>{},h=()=>{};e.recordDOM&&(c=function({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:n}){let i,s;if(!n.CSSStyleSheet||!n.CSSStyleSheet.prototype)return()=>{};let o=n.CSSStyleSheet.prototype.insertRule;n.CSSStyleSheet.prototype.insertRule=new Proxy(o,{apply:nm((n,i,s)=>{let[o,a]=s,{id:u,styleId:l}=nO(i,t,r.styleMirror);return(u&&-1!==u||l&&-1!==l)&&e({id:u,styleId:l,adds:[{rule:o,index:a}]}),n.apply(i,s)})});let a=n.CSSStyleSheet.prototype.deleteRule;n.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:nm((n,i,s)=>{let[o]=s,{id:a,styleId:u}=nO(i,t,r.styleMirror);return(a&&-1!==a||u&&-1!==u)&&e({id:a,styleId:u,removes:[{index:o}]}),n.apply(i,s)})}),n.CSSStyleSheet.prototype.replace&&(i=n.CSSStyleSheet.prototype.replace,n.CSSStyleSheet.prototype.replace=new Proxy(i,{apply:nm((n,i,s)=>{let[o]=s,{id:a,styleId:u}=nO(i,t,r.styleMirror);return(a&&-1!==a||u&&-1!==u)&&e({id:a,styleId:u,replace:o}),n.apply(i,s)})})),n.CSSStyleSheet.prototype.replaceSync&&(s=n.CSSStyleSheet.prototype.replaceSync,n.CSSStyleSheet.prototype.replaceSync=new Proxy(s,{apply:nm((n,i,s)=>{let[o]=s,{id:a,styleId:u}=nO(i,t,r.styleMirror);return(a&&-1!==a||u&&-1!==u)&&e({id:a,styleId:u,replaceSync:o}),n.apply(i,s)})}));let u={};nI("CSSGroupingRule")?u.CSSGroupingRule=n.CSSGroupingRule:(nI("CSSMediaRule")&&(u.CSSMediaRule=n.CSSMediaRule),nI("CSSConditionRule")&&(u.CSSConditionRule=n.CSSConditionRule),nI("CSSSupportsRule")&&(u.CSSSupportsRule=n.CSSSupportsRule));let l={};return Object.entries(u).forEach(([n,i])=>{l[n]={insertRule:i.prototype.insertRule,deleteRule:i.prototype.deleteRule},i.prototype.insertRule=new Proxy(l[n].insertRule,{apply:nm((n,i,s)=>{let[o,a]=s,{id:u,styleId:l}=nO(i.parentStyleSheet,t,r.styleMirror);return(u&&-1!==u||l&&-1!==l)&&e({id:u,styleId:l,adds:[{rule:o,index:[...nw(i),a||0]}]}),n.apply(i,s)})}),i.prototype.deleteRule=new Proxy(l[n].deleteRule,{apply:nm((n,i,s)=>{let[o]=s,{id:a,styleId:u}=nO(i.parentStyleSheet,t,r.styleMirror);return(a&&-1!==a||u&&-1!==u)&&e({id:a,styleId:u,removes:[{index:[...nw(i),o]}]}),n.apply(i,s)})})}),nm(()=>{n.CSSStyleSheet.prototype.insertRule=o,n.CSSStyleSheet.prototype.deleteRule=a,i&&(n.CSSStyleSheet.prototype.replace=i),s&&(n.CSSStyleSheet.prototype.replaceSync=s),Object.entries(u).forEach(([e,t])=>{t.prototype.insertRule=l[e].insertRule,t.prototype.deleteRule=l[e].deleteRule})})}(e,{win:n}),d=nk(e,e.doc),f=function({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:n},{win:i}){let s=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:nm((i,o,a)=>{let[u,l,c]=a;if(r.has(u))return s.apply(o,[u,l,c]);let{id:d,styleId:f}=nO(ng([o,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,n.styleMirror);return(d&&-1!==d||f&&-1!==f)&&e({id:d,styleId:f,set:{property:u,value:l,priority:c},index:nw(o.parentRule)}),i.apply(o,a)})});let o=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:nm((i,s,a)=>{let[u]=a;if(r.has(u))return o.apply(s,[u]);let{id:l,styleId:c}=nO(ng([s,"access",e=>e.parentRule,"optionalAccess",e=>e.parentStyleSheet]),t,n.styleMirror);return(l&&-1!==l||c&&-1!==c)&&e({id:l,styleId:c,remove:{property:u},index:nw(s.parentRule)}),i.apply(s,a)})}),nm(()=>{i.CSSStyleDeclaration.prototype.setProperty=s,i.CSSStyleDeclaration.prototype.removeProperty=o})}(e,{win:n}),e.collectFonts&&(h=function({fontCb:e,doc:t}){let r=t.defaultView;if(!r)return()=>{};let n=[],i=new WeakMap,s=r.FontFace;r.FontFace=function(e,t,r){let n=new s(e,t,r);return i.set(n,{family:e,buffer:"string"!=typeof t,descriptors:r,fontSource:"string"==typeof t?t:JSON.stringify(Array.from(new Uint8Array(t)))}),n};let o=rX(t.fonts,"add",function(t){return function(r){return ni(nm(()=>{let t=i.get(r);t&&(e(t),i.delete(r))}),0),t.apply(this,[r])}});return n.push(()=>{r.FontFace=s}),n.push(o),nm(()=>{n.forEach(e=>e())})}(e)));let p=function(e){let{doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:s,selectionCb:o}=e,a=!0,u=nm(()=>{let e=t.getSelection();if(!e||a&&ng([e,"optionalAccess",e=>e.isCollapsed]))return;a=e.isCollapsed||!1;let u=[],l=e.rangeCount||0;for(let t=0;t<l;t++){let{startContainer:o,startOffset:a,endContainer:l,endOffset:c}=e.getRangeAt(t);r3(o,n,i,s,!0)||r3(l,n,i,s,!0)||u.push({start:r.getId(o),startOffset:a,end:r.getId(l),endOffset:c})}o({ranges:u})});return u(),rW("selectionchange",u)}(e),m=function({doc:e,customElementCb:t}){let r=e.defaultView;return r&&r.customElements?rX(r.customElements,"define",function(e){return function(r,n,i){try{t({define:{name:r}})}catch(e){}return e.apply(this,[r,n,i])}}):()=>{}}(e),g=[];for(let t of e.plugins)g.push(t.observer(t.callback,n,t.options));return nm(()=>{ny.forEach(e=>e.reset()),ng([r,"optionalAccess",e=>e.disconnect,"call",e=>e()]),i(),s(),o(),a(),u(),l(),c(),d(),f(),h(),p(),m(),g.forEach(e=>e())})}function nC(e){return void 0!==window[e]}function nI(e){return!!(void 0!==window[e]&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class nR{constructor(e){this.generateIdFn=e,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(e,t,r,n){let i=r||this.getIdToRemoteIdMap(e),s=n||this.getRemoteIdToIdMap(e),o=i.get(t);return o||(o=this.generateIdFn(),i.set(t,o),s.set(o,t)),o}getIds(e,t){let r=this.getIdToRemoteIdMap(e),n=this.getRemoteIdToIdMap(e);return t.map(t=>this.getId(e,t,r,n))}getRemoteId(e,t,r){let n=r||this.getRemoteIdToIdMap(e);return"number"!=typeof t?t:n.get(t)||-1}getRemoteIds(e,t){let r=this.getRemoteIdToIdMap(e);return t.map(t=>this.getRemoteId(e,t,r))}reset(e){if(!e){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(e),this.iframeRemoteIdToIdMap.delete(e)}getIdToRemoteIdMap(e){let t=this.iframeIdToRemoteIdMap.get(e);return t||(t=new Map,this.iframeIdToRemoteIdMap.set(e,t)),t}getRemoteIdToIdMap(e){let t=this.iframeRemoteIdToIdMap.get(e);return t||(t=new Map,this.iframeRemoteIdToIdMap.set(e,t)),t}}function nx(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}class nA{constructor(){this.crossOriginIframeMirror=new nR(rR),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class nP{constructor(e){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new nR(rR),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=e.mutationCb,this.wrappedEmit=e.wrappedEmit,this.stylesheetManager=e.stylesheetManager,this.recordCrossOriginIframes=e.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new nR(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=e.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(e){this.iframes.set(e,!0),e.contentWindow&&this.crossOriginIframeMap.set(e.contentWindow,e)}addLoadListener(e){this.loadListener=e}attachIframe(e,t){this.mutationCb({adds:[{parentId:this.mirror.getId(e),nextId:null,node:t}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),nx([this,"access",e=>e.loadListener,"optionalCall",t=>t(e)]),e.contentDocument&&e.contentDocument.adoptedStyleSheets&&e.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(e.contentDocument.adoptedStyleSheets,this.mirror.getId(e.contentDocument))}handleMessage(e){if("rrweb"!==e.data.type||e.origin!==e.data.origin||!e.source)return;let t=this.crossOriginIframeMap.get(e.source);if(!t)return;let r=this.transformCrossOriginEvent(t,e.data.event);r&&this.wrappedEmit(r,e.data.isCheckout)}transformCrossOriginEvent(e,t){switch(t.type){case ns.FullSnapshot:{this.crossOriginIframeMirror.reset(e),this.crossOriginIframeStyleMirror.reset(e),this.replaceIdOnNode(t.data.node,e);let r=t.data.node.id;return this.crossOriginIframeRootIdMap.set(e,r),this.patchRootIdOnNode(t.data.node,r),{timestamp:t.timestamp,type:ns.IncrementalSnapshot,data:{source:no.Mutation,adds:[{parentId:this.mirror.getId(e),nextId:null,node:t.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case ns.Meta:case ns.Load:case ns.DomContentLoaded:break;case ns.Plugin:return t;case ns.Custom:return this.replaceIds(t.data.payload,e,["id","parentId","previousId","nextId"]),t;case ns.IncrementalSnapshot:switch(t.data.source){case no.Mutation:return t.data.adds.forEach(t=>{this.replaceIds(t,e,["parentId","nextId","previousId"]),this.replaceIdOnNode(t.node,e);let r=this.crossOriginIframeRootIdMap.get(e);r&&this.patchRootIdOnNode(t.node,r)}),t.data.removes.forEach(t=>{this.replaceIds(t,e,["parentId","id"])}),t.data.attributes.forEach(t=>{this.replaceIds(t,e,["id"])}),t.data.texts.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case no.Drag:case no.TouchMove:case no.MouseMove:return t.data.positions.forEach(t=>{this.replaceIds(t,e,["id"])}),t;case no.ViewportResize:return!1;case no.MediaInteraction:case no.MouseInteraction:case no.Scroll:case no.CanvasMutation:case no.Input:return this.replaceIds(t.data,e,["id"]),t;case no.StyleSheetRule:case no.StyleDeclaration:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleId"]),t;case no.Font:return t;case no.Selection:return t.data.ranges.forEach(t=>{this.replaceIds(t,e,["start","end"])}),t;case no.AdoptedStyleSheet:return this.replaceIds(t.data,e,["id"]),this.replaceStyleIds(t.data,e,["styleIds"]),nx([t,"access",e=>e.data,"access",e=>e.styles,"optionalAccess",e=>e.forEach,"call",t=>t(t=>{this.replaceStyleIds(t,e,["styleId"])})]),t}}return!1}replace(e,t,r,n){for(let i of n)(Array.isArray(t[i])||"number"==typeof t[i])&&(Array.isArray(t[i])?t[i]=e.getIds(r,t[i]):t[i]=e.getId(r,t[i]));return t}replaceIds(e,t,r){return this.replace(this.crossOriginIframeMirror,e,t,r)}replaceStyleIds(e,t,r){return this.replace(this.crossOriginIframeStyleMirror,e,t,r)}replaceIdOnNode(e,t){this.replaceIds(e,t,["id","rootId"]),"childNodes"in e&&e.childNodes.forEach(e=>{this.replaceIdOnNode(e,t)})}patchRootIdOnNode(e,t){e.type===w.Document||e.rootId||(e.rootId=t),"childNodes"in e&&e.childNodes.forEach(e=>{this.patchRootIdOnNode(e,t)})}}class nM{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class nN{constructor(e){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=e.mutationCb,this.scrollCb=e.scrollCb,this.bypassOptions=e.bypassOptions,this.mirror=e.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(e,t){if(!rd(e)||this.shadowDoms.has(e))return;this.shadowDoms.add(e),this.bypassOptions.canvasManager.addShadowRoot(e);let r=n_({...this.bypassOptions,doc:t,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},e);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(nb({...this.bypassOptions,scrollCb:this.scrollCb,doc:e,mirror:this.mirror})),ni(()=>{e.adoptedStyleSheets&&e.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(e.adoptedStyleSheets,this.mirror.getId(e.host)),this.restoreHandlers.push(nk({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},e))},0)}observeAttachShadow(e){e.contentWindow&&e.contentDocument&&this.patchAttachShadow(e.contentWindow.Element,e.contentDocument)}patchAttachShadow(e,t){let r=this;this.restoreHandlers.push(rX(e.prototype,"attachShadow",function(e){return function(n){let i=e.call(this,n);return this.shadowRoot&&nt(this)&&r.addShadowRoot(this.shadowRoot,t),i}}))}reset(){this.restoreHandlers.forEach(e=>{try{e()}catch(e){}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}class nD{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class nL{constructor(e){this.trackedLinkElements=new WeakSet,this.styleMirror=new r7,this.mutationCb=e.mutationCb,this.adoptedStyleSheetCb=e.adoptedStyleSheetCb}attachLinkElement(e,t){"_cssText"in t.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:t.id,attributes:t.attributes}]}),this.trackLinkElement(e)}trackLinkElement(e){this.trackedLinkElements.has(e)||(this.trackedLinkElements.add(e),this.trackStylesheetInLinkElement(e))}adoptStyleSheets(e,t){if(0===e.length)return;let r={id:t,styleIds:[]},n=[];for(let t of e){let e;this.styleMirror.has(t)?e=this.styleMirror.getId(t):(e=this.styleMirror.add(t),n.push({styleId:e,rules:Array.from(t.rules||CSSRule,(e,t)=>({rule:rh(e),index:t}))})),r.styleIds.push(e)}n.length>0&&(r.styles=n),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(e){}}class nj{constructor(){this.nodeMap=new WeakMap,this.loop=!0,this.periodicallyClear()}periodicallyClear(){!function(...e){nn("requestAnimationFrame")(...e)}(()=>{this.clear(),this.loop&&this.periodicallyClear()})}inOtherBuffer(e,t){let r=this.nodeMap.get(e);return r&&Array.from(r).some(e=>e!==t)}add(e,t){this.nodeMap.set(e,(this.nodeMap.get(e)||new Set).add(t))}clear(){this.nodeMap=new WeakMap}destroy(){this.loop=!1}}try{if(2!==Array.from([1],e=>2*e)[0]){let e=document.createElement("iframe");document.body.appendChild(e),Array.from=(0,tz.x)([e,"access",e=>e.contentWindow,"optionalAccess",e=>e.Array,"access",e=>e.from])||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}let nU=new rp;function nB(e={}){let t;let{emit:r,checkoutEveryNms:n,checkoutEveryNth:i,blockClass:s="rr-block",blockSelector:o=null,unblockSelector:a=null,ignoreClass:u="rr-ignore",ignoreSelector:l=null,maskAllText:c=!1,maskTextClass:d="rr-mask",unmaskTextClass:f=null,maskTextSelector:g=null,unmaskTextSelector:y=null,inlineStylesheet:v=!0,maskAllInputs:_,maskInputOptions:b,slimDOMOptions:S,maskAttributeFn:E,maskInputFn:w,maskTextFn:O,maxCanvasSize:k=null,packFn:T,sampling:C={},dataURLOptions:I={},mousemoveWait:R,recordDOM:x=!0,recordCanvas:A=!1,recordCrossOriginIframes:P=!1,recordAfter:M="DOMContentLoaded"===e.recordAfter?e.recordAfter:"load",userTriggeredOnInput:N=!1,collectFonts:D=!1,inlineImages:L=!1,plugins:j,keepIframeSrcFn:U=()=>!1,ignoreCSSAttributes:B=new Set([]),errorHandler:F,onMutation:$,getCanvasManager:z}=e;h=F;let H=!P||window.parent===window,G=!1;if(!H)try{window.parent.document&&(G=!1)}catch(e){G=!0}if(H&&!r)throw Error("emit function is required");void 0!==R&&void 0===C.mousemove&&(C.mousemove=R),nU.reset();let q=!0===_?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:void 0!==b?b:{},Z=!0===S||"all"===S?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:"all"===S,headMetaDescKeywords:"all"===S}:S||{};!function(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...e)=>{let t=e[0];if(!(0 in e))throw TypeError("1 argument is required");do if(this===t)return!0;while(t=t&&t.parentNode);return!1})}();let W=0,K=e=>{for(let t of j||[])t.eventProcessor&&(e=t.eventProcessor(e));return T&&!G&&(e=T(e)),e};p=(e,s)=>{if(e.timestamp=rJ(),(0,tz.x)([ny,"access",e=>e[0],"optionalAccess",e=>e.isFrozen,"call",e=>e()])&&e.type!==ns.FullSnapshot&&!(e.type===ns.IncrementalSnapshot&&e.data.source===no.Mutation)&&ny.forEach(e=>e.unfreeze()),H)(0,tz.x)([r,"optionalCall",t=>t(K(e),s)]);else if(G){let t={type:"rrweb",event:K(e),origin:window.location.origin,isCheckout:s};window.parent.postMessage(t,"*")}if(e.type===ns.FullSnapshot)t=e,W=0;else if(e.type===ns.IncrementalSnapshot){if(e.data.source===no.Mutation&&e.data.isAttachIframe)return;W++;let r=i&&W>=i,s=n&&t&&e.timestamp-t.timestamp>n;(r||s)&&en(!0)}};let V=e=>{p({type:ns.IncrementalSnapshot,data:{source:no.Mutation,...e}})},Q=e=>p({type:ns.IncrementalSnapshot,data:{source:no.Scroll,...e}}),X=e=>p({type:ns.IncrementalSnapshot,data:{source:no.CanvasMutation,...e}}),J=new nL({mutationCb:V,adoptedStyleSheetCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.AdoptedStyleSheet,...e}})}),Y="boolean"==typeof __RRWEB_EXCLUDE_IFRAME__&&__RRWEB_EXCLUDE_IFRAME__?new nA:new nP({mirror:nU,mutationCb:V,stylesheetManager:J,recordCrossOriginIframes:P,wrappedEmit:p});for(let e of j||[])e.getMirror&&e.getMirror({nodeMirror:nU,crossOriginIframeMirror:Y.crossOriginIframeMirror,crossOriginIframeStyleMirror:Y.crossOriginIframeStyleMirror});let ee=new nj,et=function(e,t){try{return e?e(t):new nD}catch(e){return console.warn("Unable to initialize CanvasManager"),new nD}}(z,{mirror:nU,win:window,mutationCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.CanvasMutation,...e}}),recordCanvas:A,blockClass:s,blockSelector:o,unblockSelector:a,maxCanvasSize:k,sampling:C.canvas,dataURLOptions:I,errorHandler:F}),er="boolean"==typeof __RRWEB_EXCLUDE_SHADOW_DOM__&&__RRWEB_EXCLUDE_SHADOW_DOM__?new nM:new nN({mutationCb:V,scrollCb:Q,bypassOptions:{onMutation:$,blockClass:s,blockSelector:o,unblockSelector:a,maskAllText:c,maskTextClass:d,unmaskTextClass:f,maskTextSelector:g,unmaskTextSelector:y,inlineStylesheet:v,maskInputOptions:q,dataURLOptions:I,maskAttributeFn:E,maskTextFn:O,maskInputFn:w,recordCanvas:A,inlineImages:L,sampling:C,slimDOMOptions:Z,iframeManager:Y,stylesheetManager:J,canvasManager:et,keepIframeSrcFn:U,processedNodeManager:ee},mirror:nU}),en=(e=!1)=>{if(!x)return;p({type:ns.Meta,data:{href:window.location.href,width:r1(),height:r0()}},e),J.reset(),er.init(),ny.forEach(e=>e.lock());let t=function(e,t){let{mirror:r=new rp,blockClass:n="rr-block",blockSelector:i=null,unblockSelector:s=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:u=null,maskTextSelector:l=null,unmaskTextSelector:c=null,inlineStylesheet:d=!0,inlineImages:f=!1,recordCanvas:h=!1,maskAllInputs:p=!1,maskAttributeFn:m,maskTextFn:g,maskInputFn:y,slimDOM:v=!1,dataURLOptions:_,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:w,onStylesheetLoad:O,stylesheetLoadTimeout:k,keepIframeSrcFn:T=()=>!1}=t||{};return rq(e,{doc:e,mirror:r,blockClass:n,blockSelector:i,unblockSelector:s,maskAllText:o,maskTextClass:a,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:c,skipChild:!1,inlineStylesheet:d,maskInputOptions:!0===p?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:!1===p?{}:p,maskAttributeFn:m,maskTextFn:g,maskInputFn:y,slimDOMOptions:!0===v||"all"===v?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:"all"===v,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:!1===v?{}:v,dataURLOptions:_,inlineImages:f,recordCanvas:h,preserveWhiteSpace:b,onSerialize:S,onIframeLoad:E,iframeLoadTimeout:w,onStylesheetLoad:O,stylesheetLoadTimeout:k,keepIframeSrcFn:T,newlyAddedElement:!1})}(document,{mirror:nU,blockClass:s,blockSelector:o,unblockSelector:a,maskAllText:c,maskTextClass:d,unmaskTextClass:f,maskTextSelector:g,unmaskTextSelector:y,inlineStylesheet:v,maskAllInputs:q,maskAttributeFn:E,maskInputFn:w,maskTextFn:O,slimDOM:Z,dataURLOptions:I,recordCanvas:A,inlineImages:L,onSerialize:e=>{r5(e,nU)&&Y.addIframe(e),r8(e,nU)&&J.trackLinkElement(e),r6(e)&&er.addShadowRoot(e.shadowRoot,document)},onIframeLoad:(e,t)=>{Y.attachIframe(e,t),e.contentWindow&&et.addWindow(e.contentWindow),er.observeAttachShadow(e)},onStylesheetLoad:(e,t)=>{J.attachLinkElement(e,t)},keepIframeSrcFn:U});if(!t)return console.warn("Failed to snapshot the document");p({type:ns.FullSnapshot,data:{node:t,initialOffset:rY(window)}}),ny.forEach(e=>e.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&J.adoptStyleSheets(document.adoptedStyleSheets,nU.getId(document))};m=en;try{let e=[],t=e=>nm(nT)({onMutation:$,mutationCb:V,mousemoveCb:(e,t)=>p({type:ns.IncrementalSnapshot,data:{source:t,positions:e}}),mouseInteractionCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.MouseInteraction,...e}}),scrollCb:Q,viewportResizeCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.ViewportResize,...e}}),inputCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.Input,...e}}),mediaInteractionCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.MediaInteraction,...e}}),styleSheetRuleCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.StyleSheetRule,...e}}),styleDeclarationCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.StyleDeclaration,...e}}),canvasMutationCb:X,fontCb:e=>p({type:ns.IncrementalSnapshot,data:{source:no.Font,...e}}),selectionCb:e=>{p({type:ns.IncrementalSnapshot,data:{source:no.Selection,...e}})},customElementCb:e=>{p({type:ns.IncrementalSnapshot,data:{source:no.CustomElement,...e}})},blockClass:s,ignoreClass:u,ignoreSelector:l,maskAllText:c,maskTextClass:d,unmaskTextClass:f,maskTextSelector:g,unmaskTextSelector:y,maskInputOptions:q,inlineStylesheet:v,sampling:C,recordDOM:x,recordCanvas:A,inlineImages:L,userTriggeredOnInput:N,collectFonts:D,doc:e,maskAttributeFn:E,maskInputFn:w,maskTextFn:O,keepIframeSrcFn:U,blockSelector:o,unblockSelector:a,slimDOMOptions:Z,dataURLOptions:I,mirror:nU,iframeManager:Y,stylesheetManager:J,shadowDomManager:er,processedNodeManager:ee,canvasManager:et,ignoreCSSAttributes:B,plugins:(0,tz.x)([j,"optionalAccess",e=>e.filter,"call",e=>e(e=>e.observer),"optionalAccess",e=>e.map,"call",e=>e(e=>({observer:e.observer,options:e.options,callback:t=>p({type:ns.Plugin,data:{plugin:e.name,payload:t}})}))])||[]},{});Y.addLoadListener(r=>{try{e.push(t(r.contentDocument))}catch(e){console.warn(e)}});let r=()=>{en(),e.push(t(document))};return"interactive"===document.readyState||"complete"===document.readyState?r():(e.push(rW("DOMContentLoaded",()=>{p({type:ns.DomContentLoaded,data:{}}),"DOMContentLoaded"===M&&r()})),e.push(rW("load",()=>{p({type:ns.Load,data:{}}),"load"===M&&r()},window))),()=>{e.forEach(e=>e()),ee.destroy(),m=void 0,h=void 0}}catch(e){console.warn(e)}}function nF(e){return e>9999999999?e:1e3*e}function n$(e){return e>9999999999?e/1e3:e}function nz(e,t){"sentry.transaction"!==t.category&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:ns.Custom,timestamp:1e3*(t.timestamp||0),data:{tag:"breadcrumb",payload:(0,t5.Fv)(t,10,1e3)}}),"console"===t.category)))}function nH(e){return e.closest("button,a")||e}function nG(e){let t=nq(e);return t&&t instanceof Element?nH(t):t}function nq(e){return"object"==typeof e&&e&&"target"in e?e.target:e}nB.mirror=nU,nB.takeFullSnapshot=function(e){if(!m)throw Error("please take full snapshot after start recording");m(e)};class nZ{constructor(e,t,r=nz){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=t.timeout/1e3,this._threshold=t.threshold/1e3,this._scollTimeout=t.scrollTimeout/1e3,this._replay=e,this._ignoreSelector=t.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){var e;let t=(e=()=>{this._lastMutation=nK()},g||(g=[],(0,q.hl)(rs,"open",function(e){return function(...t){if(g)try{g.forEach(e=>e())}catch(e){}return e.apply(rs,t)}})),g.push(e),()=>{let t=g?g.indexOf(e):-1;t>-1&&g.splice(t,1)});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(e,t){var r;if(r=this._ignoreSelector,!nW.includes(t.tagName)||"INPUT"===t.tagName&&!["submit","button"].includes(t.getAttribute("type")||"")||"A"===t.tagName&&(t.hasAttribute("download")||t.hasAttribute("target")&&"_self"!==t.getAttribute("target"))||r&&t.matches(r)||!(e.data&&"number"==typeof e.data.nodeId&&e.timestamp))return;let n={timestamp:n$(e.timestamp),clickBreadcrumb:e,clickCount:0,node:t};this._clicks.some(e=>e.node===n.node&&1>Math.abs(e.timestamp-n.timestamp))||(this._clicks.push(n),1===this._clicks.length&&this._scheduleCheckClicks())}registerMutation(e=Date.now()){this._lastMutation=n$(e)}registerScroll(e=Date.now()){this._lastScroll=n$(e)}registerClick(e){let t=nH(e);this._handleMultiClick(t)}_handleMultiClick(e){this._getClicks(e).forEach(e=>{e.clickCount++})}_getClicks(e){return this._clicks.filter(t=>t.node===e)}_checkClicks(){let e=[],t=nK();for(let r of(this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=t&&e.push(r)}),e)){let e=this._clicks.indexOf(r);e>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(e,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(e){let t=this._replay,r=e.scrollAfter&&e.scrollAfter<=this._scollTimeout,n=e.mutationAfter&&e.mutationAfter<=this._threshold,{clickCount:i,clickBreadcrumb:s}=e;if(!r&&!n){let r=1e3*Math.min(e.mutationAfter||this._timeout,this._timeout),n=r<1e3*this._timeout?"mutation":"timeout",o={type:"default",message:s.message,timestamp:s.timestamp,category:"ui.slowClickDetected",data:{...s.data,url:rs.location.href,route:t.getCurrentRoute(),timeAfterClickMs:r,endReason:n,clickCount:i||1}};this._addBreadcrumbEvent(t,o);return}if(i>1){let e={type:"default",message:s.message,timestamp:s.timestamp,category:"ui.multiClick",data:{...s.data,url:rs.location.href,route:t.getCurrentRoute(),clickCount:i,metric:!0}};this._addBreadcrumbEvent(t,e)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=(0,rn.iK)(()=>this._checkClicks(),1e3)}}let nW=["A","BUTTON","INPUT"];function nK(){return Date.now()/1e3}function nV(e){return{timestamp:Date.now()/1e3,type:"default",...e}}(E=O||(O={}))[E.Document=0]="Document",E[E.DocumentType=1]="DocumentType",E[E.Element=2]="Element",E[E.Text=3]="Text",E[E.CDATA=4]="CDATA",E[E.Comment=5]="Comment";let nQ=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]),nX=e=>t=>{if(!e.isEnabled())return;let r=function(e){let{target:t,message:r}=function(e){let t;let r="click"===e.name,n=null;try{n=r?nG(e.event):nq(e.event),t=(0,eo.Rt)(n,{maxStringLength:200})||"<unknown>"}catch(e){t="<unknown>"}return{target:n,message:t}}(e);return nV({category:`ui.${e.name}`,...nJ(t,r)})}(t);if(!r)return;let n="click"===t.name,i=n?t.event:void 0;n&&e.clickDetector&&i&&i.target&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&function(e,t,r){e.handleClick(t,r)}(e.clickDetector,r,nG(t.event)),nz(e,r)};function nJ(e,t){let r=nB.mirror.getId(e),n=r&&nB.mirror.getNode(r),i=n&&nB.mirror.getMeta(n),s=i&&i.type===O.Element?i:null;return{message:t,data:s?{nodeId:r,node:{id:r,tagName:s.tagName,textContent:Array.from(s.childNodes).map(e=>e.type===O.Text&&e.textContent).filter(Boolean).map(e=>e.trim()).join(""),attributes:function(e){let t={};for(let r in!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]),e)if(nQ.has(r)){let n=r;("data-testid"===r||"data-test-id"===r)&&(n="testId"),t[n]=e[r]}return t}(s.attributes)}}:{}}}let nY={resource:function(e){let{entryType:t,initiatorType:r,name:n,responseEnd:i,startTime:s,decodedBodySize:o,encodedBodySize:a,responseStatus:u,transferSize:l}=e;return["fetch","xmlhttprequest"].includes(r)?null:{type:`${t}.${r}`,start:n2(s),end:n2(i),name:n,data:{size:l,statusCode:u,decodedBodySize:o,encodedBodySize:a}}},paint:function(e){let{duration:t,entryType:r,name:n,startTime:i}=e,s=n2(i);return{type:r,name:n,start:s,end:s+t,data:void 0}},navigation:function(e){let{entryType:t,name:r,decodedBodySize:n,duration:i,domComplete:s,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:u,domInteractive:l,loadEventStart:c,loadEventEnd:d,redirectCount:f,startTime:h,transferSize:p,type:m}=e;return 0===i?null:{type:`${t}.${m}`,start:n2(h),end:n2(s),name:r,data:{size:p,decodedBodySize:n,encodedBodySize:o,duration:i,domInteractive:l,domContentLoadedEventStart:a,domContentLoadedEventEnd:u,loadEventStart:c,loadEventEnd:d,domComplete:s,redirectCount:f}}}};function n0(e,t){return({metric:r})=>void t.replayPerformanceEntries.push(e(r))}function n1(e){let t=nY[e.entryType];return t?t(e):null}function n2(e){return((G.Z1||rs.performance.timeOrigin)+e)/1e3}function n3(e){let t=e.entries[e.entries.length-1];return n8(e,"largest-contentful-paint",t&&t.element?[t.element]:void 0)}function n4(e){let t=e.entries[e.entries.length-1],r=[];if(t&&t.sources)for(let e of t.sources)e.node&&r.push(e.node);return n8(e,"cumulative-layout-shift",r)}function n9(e){let t=e.entries[e.entries.length-1];return n8(e,"first-input-delay",t&&t.target?[t.target]:void 0)}function n5(e){let t=e.entries[e.entries.length-1];return n8(e,"interaction-to-next-paint",t&&t.target?[t.target]:void 0)}function n8(e,t,r){let n=e.value,i=e.rating,s=n2(n);return{type:"web-vital",name:t,start:s,end:s,data:{value:n,size:n,rating:i,nodeIds:r?r.map(e=>nB.mirror.getId(e)):void 0}}}let n6="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;function n7(e,t){n6&&(B.kg.info(e),t&&it(e))}function ie(e,t){n6&&(B.kg.info(e),t&&(0,rn.iK)(()=>{it(e)},0))}function it(e){(0,t3.n)({category:"console",data:{logger:"replay"},level:"info",message:e},{level:"info"})}class ir extends Error{constructor(){super("Event buffer exceeded maximum size of 20000000.")}}class ii{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(e){let t=JSON.stringify(e).length;if(this._totalSize+=t,this._totalSize>2e7)throw new ir;this.events.push(e)}finish(){return new Promise(e=>{let t=this.events;this.clear(),e(JSON.stringify(t))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){let e=this.events.map(e=>e.timestamp).sort()[0];return e?nF(e):null}}class is{constructor(e){this._worker=e,this._id=0}ensureReady(){return this._ensureReadyPromise||(this._ensureReadyPromise=new Promise((e,t)=>{this._worker.addEventListener("message",({data:r})=>{r.success?e():t()},{once:!0}),this._worker.addEventListener("error",e=>{t(e)},{once:!0})})),this._ensureReadyPromise}destroy(){n7("[Replay] Destroying compression worker"),this._worker.terminate()}postMessage(e,t){let r=this._getAndIncrementId();return new Promise((n,i)=>{let s=({data:t})=>{if(t.method===e&&t.id===r){if(this._worker.removeEventListener("message",s),!t.success){n6&&B.kg.error("[Replay]",t.response),i(Error("Error in compression worker"));return}n(t.response)}};this._worker.addEventListener("message",s),this._worker.postMessage({id:r,method:e,arg:t})})}_getAndIncrementId(){return this._id++}}class io{constructor(e){this._worker=new is(e),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(e){let t=nF(e.timestamp);(!this._earliestTimestamp||t<this._earliestTimestamp)&&(this._earliestTimestamp=t);let r=JSON.stringify(e);return(this._totalSize+=r.length,this._totalSize>2e7)?Promise.reject(new ir):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,e=>{n6&&B.kg.warn('[Replay] Sending "clear" message to worker failed',e)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(e){return this._worker.postMessage("addEvent",e)}async _finishRequest(){let e=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,e}}class ia{constructor(e){this._fallback=new ii,this._compression=new io(e),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(e){this._used.hasCheckout=e}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(e){return this._used.addEvent(e)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(e){n7("[Replay] Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){let{events:e,hasCheckout:t}=this._fallback,r=[];for(let t of e)r.push(this._compression.addEvent(t));this._compression.hasCheckout=t,this._used=this._compression;try{await Promise.all(r)}catch(e){n6&&B.kg.warn("[Replay] Failed to add events when switching buffers.",e)}}}function iu(){try{return"sessionStorage"in rs&&!!rs.sessionStorage}catch(e){return!1}}function il(e){return void 0!==e&&Math.random()<e}function ic(e){let t=Date.now(),r=e.id||(0,z.DM)(),n=e.started||t,i=e.lastActivity||t;return{id:r,started:n,lastActivity:i,segmentId:e.segmentId||0,sampled:e.sampled,previousSessionId:e.previousSessionId}}function id(e){if(iu())try{rs.sessionStorage.setItem(ro,JSON.stringify(e))}catch(e){}}function ih({sessionSampleRate:e,allowBuffering:t,stickySession:r=!1},{previousSessionId:n}={}){let i=ic({sampled:il(e)?"session":!!t&&"buffer",previousSessionId:n});return r&&id(i),i}function ip(e,t,r=+new Date){return null===e||void 0===t||t<0||0!==t&&e+t<=r}function im(e,{maxReplayDuration:t,sessionIdleExpire:r,targetTime:n=Date.now()}){return ip(e.started,t,n)||ip(e.lastActivity,r,n)}function ig(e,{sessionIdleExpire:t,maxReplayDuration:r}){return!!im(e,{sessionIdleExpire:t,maxReplayDuration:r})&&("buffer"!==e.sampled||0!==e.segmentId)}function iy({traceInternals:e,sessionIdleExpire:t,maxReplayDuration:r,previousSessionId:n},i){let s=i.stickySession&&function(e){if(!iu())return null;try{let t=rs.sessionStorage.getItem(ro);if(!t)return null;let r=JSON.parse(t);return ie("[Replay] Loading existing session",e),ic(r)}catch(e){return null}}(e);return s?ig(s,{sessionIdleExpire:t,maxReplayDuration:r})?(ie("[Replay] Session in sessionStorage is expired, creating new one..."),ih(i,{previousSessionId:s.id})):s:(ie("[Replay] Creating new session",e),ih(i,{previousSessionId:n}))}function iv(e,t,r){return!!ib(e,t)&&(i_(e,t,r),!0)}async function i_(e,t,r){if(!e.eventBuffer)return null;try{r&&"buffer"===e.recordingMode&&e.eventBuffer.clear(),r&&(e.eventBuffer.hasCheckout=!0);let n=e.getOptions(),i=function(e,t){try{if("function"==typeof t&&e.type===ns.Custom)return t(e)}catch(e){return n6&&B.kg.error("[Replay] An error occured in the `beforeAddRecordingEvent` callback, skipping the event...",e),null}return e}(t,n.beforeAddRecordingEvent);if(!i)return;return await e.eventBuffer.addEvent(i)}catch(n){let t=n&&n instanceof ir?"addEventSizeExceeded":"addEvent";e.handleException(n),await e.stop({reason:t});let r=(0,C.s3)();r&&r.recordDroppedEvent("internal_sdk_error","replay")}}function ib(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;let r=nF(t.timestamp);return!(r+e.timeouts.sessionIdlePause<Date.now())&&(!(r>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration)||(ie(`[Replay] Skipping event with timestamp ${r} because it is after maxReplayDuration`,e.getOptions()._experiments.traceInternals),!1))}function iS(e){return"transaction"===e.type}function iE(e){return"feedback"===e.type}function iw(e){return!!e.category}function iO(e,t){return t.map(({type:t,start:r,end:n,name:i,data:s})=>{let o=e.throttledAddEvent({type:ns.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:t,description:i,startTimestamp:r,endTimestamp:n,data:s}}});return"string"==typeof o?Promise.resolve(null):o})}function ik(e,t){var r;e.isEnabled()&&null!==t&&(r=t.name,(!n6||!e.getOptions()._experiments.traceInternals)&&function(e,t){let r=t&&t.getDsn(),n=t&&t.getOptions().tunnel;return!!r&&e.includes(r.host)||!!n&&t4(e)===t4(n)}(r,(0,C.s3)())||e.addUpdate(()=>(iO(e,[t]),!0)))}function iT(e){if(!e)return;let t=new TextEncoder;try{if("string"==typeof e)return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){let r=iN(e);return t.encode(r).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch(e){}}function iC(e){if(!e)return;let t=parseInt(e,10);return isNaN(t)?void 0:t}function iI(e){try{if("string"==typeof e)return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[iN(e)];if(!e)return[void 0]}catch(t){return n6&&B.kg.warn("[Replay] Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return n6&&B.kg.info("[Replay] Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function iR(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};let r={...e._meta},n=r.warnings||[];return r.warnings=[...n,t],e._meta=r,e}function ix(e,t){if(!t)return null;let{startTimestamp:r,endTimestamp:n,url:i,method:s,statusCode:o,request:a,response:u}=t;return{type:e,start:r/1e3,end:n/1e3,name:i,data:(0,q.Jr)({method:s,statusCode:o,request:a,response:u})}}function iA(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function iP(e,t,r){if(!t&&0===Object.keys(e).length)return;if(!t)return{headers:e};if(!r)return{headers:e,size:t};let n={headers:e,size:t},{body:i,warnings:s}=function(e){if(!e||"string"!=typeof e)return{body:e};let t=e.length>15e4,r=function(e){let t=e[0],r=e[e.length-1];return"["===t&&"]"===r||"{"===t&&"}"===r}(e);if(t){let t=e.slice(0,15e4);return r?{body:t,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${t}…`,warnings:["TEXT_TRUNCATED"]}}if(r)try{return{body:JSON.parse(e)}}catch(e){}return{body:e}}(r);return n.body=i,s&&s.length>0&&(n._meta={warnings:s}),n}function iM(e,t){return Object.entries(e).reduce((r,[n,i])=>{let s=n.toLowerCase();return t.includes(s)&&e[n]&&(r[s]=i),r},{})}function iN(e){return new URLSearchParams(e).toString()}function iD(e,t){let r=function(e,t=rs.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(rs.location.origin))return e;let r=new URL(e,t);if(r.origin!==new URL(t).origin)return e;let n=r.href;return!e.endsWith("/")&&n.endsWith("/")?n.slice(0,-1):n}(e);return(0,tx.U0)(r,t)}async function iL(e,t,r){try{let n=await ij(e,t,r),i=ix("resource.fetch",n);ik(r.replay,i)}catch(e){n6&&B.kg.error("[Replay] Failed to capture fetch breadcrumb",e)}}async function ij(e,t,r){let n=Date.now(),{startTimestamp:i=n,endTimestamp:s=n}=t,{url:o,method:a,status_code:u=0,request_body_size:l,response_body_size:c}=e.data,d=iD(o,r.networkDetailAllowUrls)&&!iD(o,r.networkDetailDenyUrls);return{startTimestamp:i,endTimestamp:s,url:o,method:a,statusCode:u,request:d?function({networkCaptureBodies:e,networkRequestHeaders:t},r,n){let i=r?1===r.length&&"string"!=typeof r[0]?iz(r[0],t):2===r.length?iz(r[1],t):{}:{};if(!e)return iP(i,n,void 0);let[s,o]=iI(iF(r)),a=iP(i,n,s);return o?iR(a,o):a}(r,t.input,l):iA(l),response:await iU(d,r,t.response,c)}}async function iU(e,{networkCaptureBodies:t,networkResponseHeaders:r},n,i){if(!e&&void 0!==i)return iA(i);let s=n?i$(n.headers,r):{};if(!n||!t&&void 0!==i)return iP(s,i,void 0);let[o,a]=await iB(n),u=function(e,{networkCaptureBodies:t,responseBodySize:r,captureDetails:n,headers:i}){try{let s=e&&e.length&&void 0===r?iT(e):r;if(!n)return iA(s);if(t)return iP(i,s,e);return iP(i,s,void 0)}catch(e){return n6&&B.kg.warn("[Replay] Failed to serialize response body",e),iP(i,r,void 0)}}(o,{networkCaptureBodies:t,responseBodySize:i,captureDetails:e,headers:s});return a?iR(u,a):u}async function iB(e){let t=function(e){try{return e.clone()}catch(e){n6&&B.kg.warn("[Replay] Failed to clone response body",e)}}(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await new Promise((e,r)=>{let n=(0,rn.iK)(()=>r(Error("Timeout while trying to read response body")),500);iH(t).then(t=>e(t),e=>r(e)).finally(()=>clearTimeout(n))})]}catch(e){return n6&&B.kg.warn("[Replay] Failed to get text body from response",e),[void 0,"BODY_PARSE_ERROR"]}}function iF(e=[]){if(2===e.length&&"object"==typeof e[1])return e[1].body}function i$(e,t){let r={};return t.forEach(t=>{e.get(t)&&(r[t]=e.get(t))}),r}function iz(e,t){if(!e)return{};let r=e.headers;return r?r instanceof Headers?i$(r,t):Array.isArray(r)?{}:iM(r,t):{}}async function iH(e){return await e.text()}async function iG(e,t,r){try{let n=function(e,t,r){let n=Date.now(),{startTimestamp:i=n,endTimestamp:s=n,input:o,xhr:a}=t,{url:u,method:l,status_code:c=0,request_body_size:d,response_body_size:f}=e.data;if(!u)return null;if(!a||!iD(u,r.networkDetailAllowUrls)||iD(u,r.networkDetailDenyUrls)){let e=iA(d);return{startTimestamp:i,endTimestamp:s,url:u,method:l,statusCode:c,request:e,response:iA(f)}}let h=a[tT.xU],p=h?iM(h.request_headers,r.networkRequestHeaders):{},m=iM(function(e){let t=e.getAllResponseHeaders();return t?t.split("\r\n").reduce((e,t)=>{let[r,n]=t.split(": ");return n&&(e[r.toLowerCase()]=n),e},{}):{}}(a),r.networkResponseHeaders),[g,y]=r.networkCaptureBodies?iI(o):[void 0],[v,_]=r.networkCaptureBodies?function(e){let t=[];try{return[e.responseText]}catch(e){t.push(e)}try{return function(e,t){try{if("string"==typeof e)return[e];if(e instanceof Document)return[e.body.outerHTML];if("json"===t&&e&&"object"==typeof e)return[JSON.stringify(e)];if(!e)return[void 0]}catch(t){return n6&&B.kg.warn("[Replay] Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return n6&&B.kg.info("[Replay] Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}(e.response,e.responseType)}catch(e){t.push(e)}return n6&&B.kg.warn("[Replay] Failed to get xhr response body",...t),[void 0]}(a):[void 0],b=iP(p,d,g),S=iP(m,f,v);return{startTimestamp:i,endTimestamp:s,url:u,method:l,statusCode:c,request:y?iR(b,y):b,response:_?iR(S,_):S}}(e,t,r),i=ix("resource.xhr",n);ik(r.replay,i)}catch(e){n6&&B.kg.error("[Replay] Failed to capture xhr breadcrumb",e)}}async function iq(e){try{return Promise.all(iO(e,[function(e){let{jsHeapSizeLimit:t,totalJSHeapSize:r,usedJSHeapSize:n}=e,i=Date.now()/1e3;return{type:"memory",name:"memory",start:i,end:i,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:r,usedJSHeapSize:n}}}}(rs.performance.memory)]))}catch(e){return[]}}async function iZ({client:e,scope:t,replayId:r,event:n}){let i={event_id:r,integrations:"object"!=typeof e._integrations||null===e._integrations||Array.isArray(e._integrations)?void 0:Object.keys(e._integrations)};e.emit("preprocessEvent",n,i);let s=await (0,t9.R)(e.getOptions(),n,i,t,e,(0,C.aF)());if(!s)return null;s.platform=s.platform||"javascript";let o=e.getSdkMetadata(),{name:a,version:u}=o&&o.sdk||{};return s.sdk={...s.sdk,name:a||"sentry.javascript.unknown",version:u||"0.0.0"},s}async function iW({recordingData:e,replayId:t,segmentId:r,eventContext:n,timestamp:i,session:s}){var o;let a;let u=function({recordingData:e,headers:t}){let r;let n=`${JSON.stringify(t)}
`;if("string"==typeof e)r=`${n}${e}`;else{let t=new TextEncoder().encode(n);(r=new Uint8Array(t.length+e.length)).set(t),r.set(e,t.length)}return r}({recordingData:e,headers:{segment_id:r}}),{urls:l,errorIds:c,traceIds:d,initialTimestamp:f}=n,h=(0,C.s3)(),p=(0,C.nZ)(),m=h&&h.getTransport(),g=h&&h.getDsn();if(!h||!m||!g||!s.sampled)return(0,t6.WD)({});let y={type:"replay_event",replay_start_timestamp:f/1e3,timestamp:i/1e3,error_ids:c,trace_ids:d,urls:l,replay_id:t,segment_id:r,replay_type:s.sampled},v=await iZ({scope:p,client:h,replayId:t,event:y});if(!v)return h.recordDroppedEvent("event_processor","replay",y),n7("An event processor returned `null`, will not send event."),(0,t6.WD)({});delete v.sdkProcessingMetadata;let _=(o=h.getOptions().tunnel,(0,t8.Jd)((0,t8.Cd)(v,(0,t8.HY)(v),o,g),[[{type:"replay_event"},v],[{type:"replay_recording",length:"string"==typeof u?new TextEncoder().encode(u).length:u.length},u]]));try{a=await m.send(_)}catch(t){let e=Error(ra);try{e.cause=t}catch(e){}throw e}if("number"==typeof a.statusCode&&(a.statusCode<200||a.statusCode>=300))throw new iK(a.statusCode);let b=(0,t7.WG)({},a);if((0,t7.Q)(b,"replay"))throw new iV(b);return a}class iK extends Error{constructor(e){super(`Transport returned status code ${e}`)}}class iV extends Error{constructor(e){super("Rate limit hit"),this.rateLimits=e}}async function iQ(e,t={count:0,interval:5e3}){let{recordingData:r,options:n}=e;if(r.length)try{return await iW(e),!0}catch(r){if(r instanceof iK||r instanceof iV)throw r;if((0,T.v)("Replays",{_retryCount:t.count}),n6&&n._experiments&&n._experiments.captureExceptions&&(0,T.Tb)(r),t.count>=3){let e=Error(`${ra} - max retries exceeded`);try{e.cause=r}catch(e){}throw e}return t.interval*=++t.count,new Promise((r,n)=>{(0,rn.iK)(async()=>{try{await iQ(e,t),r(!0)}catch(e){n(e)}},t.interval)})}}let iX="__THROTTLED";class iJ{constructor({options:e,recordingOptions:t}){iJ.prototype.__init.call(this),iJ.prototype.__init2.call(this),iJ.prototype.__init3.call(this),iJ.prototype.__init4.call(this),iJ.prototype.__init5.call(this),iJ.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:3e5,sessionIdleExpire:9e5},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=t,this._options=e,this._debouncedFlush=function(e,t,r){let n,i,s;let o=r&&r.maxWait?Math.max(r.maxWait,t):0;function a(){return u(),n=e()}function u(){void 0!==i&&clearTimeout(i),void 0!==s&&clearTimeout(s),i=s=void 0}function l(){return i&&clearTimeout(i),i=(0,rn.iK)(a,t),o&&void 0===s&&(s=(0,rn.iK)(a,o)),n}return l.cancel=u,l.flush=function(){return void 0!==i||void 0!==s?a():n},l}(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=function(e,t,r){let n=new Map,i=e=>{let t=e-5;n.forEach((e,r)=>{r<t&&n.delete(r)})},s=()=>[...n.values()].reduce((e,t)=>e+t,0),o=!1;return(...t)=>{let r=Math.floor(Date.now()/1e3);if(i(r),s()>=300){let e=o;return o=!0,e?"__SKIPPED":iX}o=!1;let a=n.get(r)||0;return n.set(r,a+1),e(...t)}}((e,t)=>ib(this,e)?i_(this,e,t):Promise.resolve(null),0,0);let{slowClickTimeout:r,slowClickIgnoreSelectors:n}=this.getOptions(),i=r?{threshold:Math.min(3e3,r),timeout:r,scrollTimeout:300,ignoreSelector:n?n.join(","):""}:void 0;i&&(this.clickDetector=new nZ(this,i))}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(e){n6&&B.kg.error("[Replay]",e),n6&&this._options._experiments&&this._options._experiments.captureExceptions&&(0,T.Tb)(e)}initializeSampling(e){let{errorSampleRate:t,sessionSampleRate:r}=this._options,n=t<=0&&r<=0;if(this._requiresManualStart=n,!n){if(this._initializeSessionForSampling(e),!this.session){this.handleException(Error("Unable to initialize and create session"));return}!1!==this.session.sampled&&(this.recordingMode="buffer"===this.session.sampled&&0===this.session.segmentId?"buffer":"session",ie(`[Replay] Starting replay in ${this.recordingMode} mode`,this._options._experiments.traceInternals),this._initializeRecording())}}start(){if(this._isEnabled&&"session"===this.recordingMode){n6&&B.kg.info("[Replay] Recording is already in progress");return}if(this._isEnabled&&"buffer"===this.recordingMode){n6&&B.kg.info("[Replay] Buffering is in progress, call `flush()` to save the replay");return}ie("[Replay] Starting replay in session mode",this._options._experiments.traceInternals),this._updateUserActivity();let e=iy({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire,traceInternals:this._options._experiments.traceInternals},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=e,this._initializeRecording()}startBuffering(){if(this._isEnabled){n6&&B.kg.info("[Replay] Buffering is in progress, call `flush()` to save the replay");return}ie("[Replay] Starting replay in buffer mode",this._options._experiments.traceInternals);let e=iy({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,traceInternals:this._options._experiments.traceInternals},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=e,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{var e;let t;let r=this._canvas;this._stopRecording=nB({...this._recordingOptions,..."buffer"===this.recordingMode&&{checkoutEveryNms:6e4},emit:(e=this,t=!1,(r,n)=>{if(!e.checkAndHandleExpiredSession()){n6&&B.kg.warn("[Replay] Received replay event after session expired.");return}let i=n||!t;t=!0,e.clickDetector&&function(e,t){try{if(3!==t.type)return;let{source:r}=t.data;if(r===no.Mutation&&e.registerMutation(t.timestamp),r===no.Scroll&&e.registerScroll(t.timestamp),t.data.source===no.MouseInteraction){let{type:r,id:n}=t.data,i=nB.mirror.getNode(n);i instanceof HTMLElement&&r===na.Click&&e.registerClick(i)}}catch(e){}}(e.clickDetector,r),e.addUpdate(()=>{if("buffer"===e.recordingMode&&i&&e.setInitialState(),!iv(e,r,i))return!0;if(!i)return!1;if(i&&e.session&&0===e.session.segmentId&&iv(e,function(e){let t=e.getOptions();return{type:ns.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:!!e.eventBuffer&&"worker"===e.eventBuffer.type,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}(e),!1),e.session&&e.session.previousSessionId)return!0;if("buffer"===e.recordingMode&&e.session&&e.eventBuffer){let t=e.eventBuffer.getEarliestTimestamp();t&&(n7(`[Replay] Updating session start time to earliest event in buffer to ${new Date(t)}`,e.getOptions()._experiments.traceInternals),e.session.started=t,e.getOptions().stickySession&&id(e.session))}return"session"===e.recordingMode&&e.flush(),!0})}),onMutation:this._onMutationHandler,...r?{recordCanvas:r.recordCanvas,getCanvasManager:r.getCanvasManager,sampling:r.sampling,dataURLOptions:r.dataURLOptions}:{}})}catch(e){this.handleException(e)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(e){return this.handleException(e),!1}}async stop({forceFlush:e=!1,reason:t}={}){if(this._isEnabled){this._isEnabled=!1;try{n7(`[Replay] Stopping Replay${t?` triggered by ${t}`:""}`,this._options._experiments.traceInternals),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),e&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,function(){if(iu())try{rs.sessionStorage.removeItem(ro)}catch(e){}}(),this.session=void 0}catch(e){this.handleException(e)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),n7("[Replay] Pausing replay",this._options._experiments.traceInternals))}resume(){this._isPaused&&this._checkSession()&&(this._isPaused=!1,this.startRecording(),n7("[Replay] Resuming replay",this._options._experiments.traceInternals))}async sendBufferedReplayOrFlush({continueRecording:e=!0}={}){if("session"===this.recordingMode)return this.flushImmediate();let t=Date.now();n7("[Replay] Converting buffer to session",this._options._experiments.traceInternals),await this.flushImmediate();let r=this.stopRecording();e&&r&&"session"!==this.recordingMode&&(this.recordingMode="session",this.session&&(this._updateUserActivity(t),this._updateSessionActivity(t),this._maybeSaveSession()),this.startRecording())}addUpdate(e){let t=e();"buffer"!==this.recordingMode&&!0!==t&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return"buffer"===this.recordingMode?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(){return this.session&&this.session.id}checkAndHandleExpiredSession(){if(this._lastActivity&&ip(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&"session"===this.session.sampled){this.pause();return}return!!this._checkSession()}setInitialState(){let e=`${rs.location.pathname}${rs.location.hash}${rs.location.search}`,t=`${rs.location.origin}${e}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=t,this._context.initialTimestamp=Date.now(),this._context.urls.push(t)}throttledAddEvent(e,t){let r=this._throttledAddEvent(e,t);if(r===iX){let e=nV({category:"replay.throttled"});this.addUpdate(()=>!iv(this,{type:5,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e,metric:!0}}))}return r}getCurrentRoute(){let e=this.lastActiveSpan||(0,M.HN)(),t=e&&(0,M.Gx)(e),r=(t&&(0,M.XU)(t).data||{})[L.Zj];if(t&&r&&["route","custom"].includes(r))return(0,M.XU)(t).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=function({useCompression:e,workerUrl:t}){if(e&&window.Worker){let e=function(e){try{let t=e||("undefined"!=typeof __SENTRY_EXCLUDE_REPLAY_WORKER__&&__SENTRY_EXCLUDE_REPLAY_WORKER__?"":function(){let e=new Blob(['var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([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,0,0,0]),i=new t([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,0,0]),a=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),s=function(t,e){for(var i=new n(31),a=0;a<31;++a)i[a]=e+=1<<t[a-1];var s=new r(i[30]);for(a=1;a<30;++a)for(var o=i[a];o<i[a+1];++o)s[o]=o-i[a]<<5|a;return{b:i,r:s}},o=s(e,2),f=o.b,h=o.r;f[28]=258,h[258]=28;for(var l=s(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,a=0,s=new n(r);a<i;++a)t[a]&&++s[t[a]-1];var o,f=new n(r);for(a=1;a<r;++a)f[a]=f[a-1]+s[a-1]<<1;if(e){o=new n(1<<r);var h=15-r;for(a=0;a<i;++a)if(t[a])for(var l=a<<4|t[a],c=r-t[a],v=f[t[a]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>h]=l}else for(o=new n(i),a=0;a<i;++a)t[a]&&(o[a]=u[f[t[a]-1]++]>>15-t[a]);return o},g=new t(288);for(c=0;c<144;++c)g[c]=8;for(c=144;c<256;++c)g[c]=9;for(c=256;c<280;++c)g[c]=7;for(c=280;c<288;++c)g[c]=8;var w=new t(32);for(c=0;c<32;++c)w[c]=5;var p=d(g,9,0),y=d(w,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==r||r<0)&&(r=0),(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},A=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},_=function(r,e){for(var i=[],a=0;a<r.length;++a)r[a]&&i.push({s:a,f:r[a]});var s=i.length,o=i.slice();if(!s)return{t:F,l:0};if(1==s){var f=new t(i[0].s+1);return f[i[0].s]=1,{t:f,l:1}}i.sort((function(t,n){return t.f-n.f})),i.push({s:-1,f:25001});var h=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:h.f+l.f,l:h,r:l};c!=s-1;)h=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:h.f+l.f,l:h,r:l};var d=o[0].s;for(a=1;a<s;++a)o[a].s>d&&(d=o[a].s);var g=new n(d+1),w=x(i[c-1],g,0);if(w>e){a=0;var p=0,y=w-e,m=1<<y;for(o.sort((function(t,n){return g[n.s]-g[t.s]||t.f-n.f}));a<s;++a){var b=o[a].s;if(!(g[b]>e))break;p+=m-(1<<w-g[b]),g[b]=e}for(p>>=y;p>0;){var M=o[a].s;g[M]<e?p-=1<<e-g[M]++-1:++a}for(;a>=0&&p;--a){var E=o[a].s;g[E]==e&&(--g[E],++p)}w=e}return{t:new t(g),l:w}},x=function(t,n,r){return-1==t.s?Math.max(x(t.l,n,r+1),x(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,a=t[0],s=1,o=function(t){e[i++]=t},f=1;f<=r;++f)if(t[f]==a&&f!=r)++s;else{if(!a&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(a),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(a);s=1,a=t[f]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a<e;++a)t[i+a+4]=r[a];return 8*(i+4+e)},C=function(t,r,s,o,f,h,l,u,c,v,m){z(r,m++,s),++f[256];for(var b=_(f,15),M=b.t,E=b.l,x=_(h,15),C=x.t,U=x.l,F=D(M),I=F.c,S=F.n,L=D(C),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=_(q,7),H=G.t,J=G.l,K=19;K>4&&!H[a[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(f,g)+T(h,w)+l,X=T(f,M)+T(h,C)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(C,U,0),R=C;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[a[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B<u;++B){var rt=o[B];if(rt>255){A(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;A(r,m,Q[et]),m+=R[et],et>3&&(A(r,m,rt>>5&8191),m+=i[et])}else A(r,m,N[rt]),m+=P[rt]}return A(r,m,N[256]),m+P[256]},U=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}},L=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,a=0|r.length,s=0;s!=a;){for(var o=Math.min(s+2655,a);s<o;++s)i+=e+=r[s];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},O=function(a,s,o,f,u){if(!u&&(u={l:1},s.dictionary)){var c=s.dictionary.subarray(-32768),v=new t(c.length+a.length);v.set(c),v.set(a,c.length),a=v,u.w=c.length}return function(a,s,o,f,u,c){var v=c.z||a.length,d=new t(f+v+5*(1+Math.ceil(v/7e3))+u),g=d.subarray(f,d.length-u),w=c.l,p=7&(c.r||0);if(s){p&&(g[0]=c.r>>3);for(var y=U[s-1],M=y>>13,E=8191&y,z=(1<<o)-1,A=c.p||new n(32768),_=c.h||new n(z+1),x=Math.ceil(o/3),D=2*x,T=function(t){return(a[t]^a[t+1]<<x^a[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=_[H];if(A[J]=K,_[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!w)){p=C(a,g,0,F,I,S,O,q,G,j-G,p),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(a[j+Q]==a[j+Q-W]){for(var $=0;$<Z&&a[j+$]==a[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-A[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=A[J])&32767}if(R){F[q++]=268435456|h[Q]<<18|l[R];var it=31&h[Q],at=31&l[R];O+=e[it]+i[at],++I[257+it],++S[at],B=j+Q,++L}else F[q++]=a[j],++I[a[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=a[j],++I[a[j]];p=C(a,g,w,F,I,S,O,q,G,j-G,p),w||(c.r=7&p|g[p/8|0]<<3,p-=7,c.h=_,c.p=A,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+w;j+=65535){var st=j+65535;st>=v&&(g[p/8|0]=w,st=v),p=k(g,p+1,a.subarray(j,st))}c.i=v}return b(d,0,f+m(p)+u)}(a,null==s.level?6:s.level,null==s.mem?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(a.length)))):12+s.mem,o,f,u)},j=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},q=function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&j(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}},B=function(t){return 10+(t.filename?t.filename.length+1:0)},G=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(O(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var a=this.b.length-this.s.z;a&&(this.b.set(n.subarray(0,a),this.s.z),this.s.z=this.b.length,this.p(this.b,!1)),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(a),32768),this.s.z=n.length-a+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n}();var H=function(){function t(t,n){this.c=L(),this.v=1,G.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),G.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=O(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=L();i.p(n.dictionary),j(t,2,i.d())}}(r,this.o),this.v=0),n&&j(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),J="undefined"!=typeof TextEncoder&&new TextEncoder,K="undefined"!=typeof TextDecoder&&new TextDecoder;try{K.decode(F,{stream:!0})}catch(t){}var N=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(P(t),this.d=n||!1)},t}();function P(n,r){if(r){for(var e=new t(n.length),i=0;i<n.length;++i)e[i]=n.charCodeAt(i);return e}if(J)return J.encode(n);var a=n.length,s=new t(n.length+(n.length>>1)),o=0,f=function(t){s[o++]=t};for(i=0;i<a;++i){if(o+5>s.length){var h=new t(o+8+(a-i<<1));h.set(s),s=h}var l=n.charCodeAt(i);l<128||r?f(l):l<2048?(f(192|l>>6),f(128|63&l)):l>55295&&l<57344?(f(240|(l=65536+(1047552&l)|1023&n.charCodeAt(++i))>>18),f(128|l>>12&63),f(128|l>>6&63),f(128|63&l)):(f(224|l>>12),f(128|l>>6&63),f(128|63&l))}return b(s,0,o)}function Q(t){return function(t,n){n||(n={});var r=S(),e=t.length;r.p(t);var i=O(t,n,B(n),8),a=i.length;return q(i,n),j(i,a-8,r.d()),j(i,a-4,e),i}(P(t))}const R=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new H,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new N(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},V={clear:()=>{R.clear()},addEvent:t=>R.addEvent(t),finish:()=>R.finish(),compress:t=>Q(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in V&&"function"==typeof V[n])try{const t=V[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}})),postMessage({id:void 0,method:"init",success:!0,response:void 0});']);return URL.createObjectURL(e)}());if(!t)return;n7(`[Replay] Using compression worker${e?` from ${e}`:""}`);let r=new Worker(t);return new ia(r)}catch(e){n7("[Replay] Failed to create compression worker")}}(t);if(e)return e}return n7("[Replay] Using simple buffer"),new ii}({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(e){let t=this._options.errorSampleRate>0,r=iy({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,traceInternals:this._options._experiments.traceInternals,previousSessionId:e},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:t});this.session=r}_checkSession(){if(!this.session)return!1;let e=this.session;return!ig(e,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})||(this._refreshSession(e),!1)}async _refreshSession(e){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(e.id))}_addListeners(){try{rs.document.addEventListener("visibilitychange",this._handleVisibilityChange),rs.addEventListener("blur",this._handleWindowBlur),rs.addEventListener("focus",this._handleWindowFocus),rs.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(function(e){let t=(0,C.s3)();(0,ri.O)(nX(e)),(0,tp.a)(t=>{if(!e.isEnabled())return;let r=function(e){let{from:t,to:r}=e,n=Date.now()/1e3;return{type:"navigation.push",start:n,end:n,name:r,data:{previous:t}}}(t);null!==r&&(e.getContext().urls.push(r.name),e.triggerUserActivity(),e.addUpdate(()=>(iO(e,[r]),!1)))}),function(e){let t=(0,C.s3)();t&&t.on("beforeAddBreadcrumb",t=>(function(e,t){if(!e.isEnabled()||!iw(t))return;let r=!iw(t)||["fetch","xhr","sentry.event","sentry.transaction"].includes(t.category)||t.category.startsWith("ui.")?null:"console"===t.category?function(e){let t=e.data&&e.data.arguments;if(!Array.isArray(t)||0===t.length)return nV(e);let r=!1,n=t.map(e=>{if(!e)return e;if("string"==typeof e)return e.length>5e3?(r=!0,`${e.slice(0,5e3)}…`):e;if("object"==typeof e)try{let t=(0,t5.Fv)(e,7);if(JSON.stringify(t).length>5e3)return r=!0,`${JSON.stringify(t,null,2).slice(0,5e3)}…`;return t}catch(e){}return e});return nV({...e,data:{...e.data,arguments:n,...r?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}(t):nV(t);r&&nz(e,r)})(e,t))}(e),function(e){let t=(0,C.s3)();try{let{networkDetailAllowUrls:r,networkDetailDenyUrls:n,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o}=e.getOptions(),a={replay:e,networkDetailAllowUrls:r,networkDetailDenyUrls:n,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o};t&&t.on("beforeAddBreadcrumb",(e,t)=>(function(e,t,r){if(t.data)try{var n,i;"xhr"===t.category&&(n=r)&&n.xhr&&(function(e,t){let{xhr:r,input:n}=t;if(!r)return;let i=iT(n),s=r.getResponseHeader("content-length")?iC(r.getResponseHeader("content-length")):function(e,t){try{let r="json"===t&&e&&"object"==typeof e?JSON.stringify(e):e;return iT(r)}catch(e){return}}(r.response,r.responseType);void 0!==i&&(e.data.request_body_size=i),void 0!==s&&(e.data.response_body_size=s)}(t,r),iG(t,r,e)),"fetch"===t.category&&(i=r)&&i.response&&(function(e,t){let{input:r,response:n}=t,i=iT(r?iF(r):void 0),s=n?iC(n.headers.get("content-length")):void 0;void 0!==i&&(e.data.request_body_size=i),void 0!==s&&(e.data.response_body_size=s)}(t,r),iL(t,r,e))}catch(e){n6&&B.kg.warn("Error when enriching network breadcrumb")}})(a,e,t))}catch(e){}}(e);let r=Object.assign((t,r)=>e.isEnabled()?"replay_event"===t.type?(delete t.breadcrumbs,t):(!t.type||iS(t)||iE(t))&&e.checkAndHandleExpiredSession()?iE(t)?(e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),e.triggerUserActivity(),e.addUpdate(()=>!t.timestamp||(e.throttledAddEvent({type:ns.Custom,timestamp:1e3*t.timestamp,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1)),t):!t.type&&t.exception&&t.exception.values&&t.exception.values.length&&r.originalException&&r.originalException.__rrweb__&&!e.getOptions()._experiments.captureExceptions?(n6&&B.kg.log("[Replay] Ignoring error from rrweb internals",t),null):(("buffer"===e.recordingMode&&t.message!==ra&&t.exception&&!t.type&&il(e.getOptions().errorSampleRate)||"session"===e.recordingMode)&&(t.tags={...t.tags,replayId:e.getSessionId()}),t):t:t,{id:"Replay"});(0,T.Qy)(r),t&&(t.on("beforeSendEvent",t=>{e.isEnabled()&&!t.type&&function(e,t){let r=t.exception&&t.exception.values&&t.exception.values[0]&&t.exception.values[0].value;"string"==typeof r&&(r.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||r.match(/(does not match server-rendered HTML|Hydration failed because)/i))&&nz(e,nV({category:"replay.hydrate-error",data:{url:(0,eo.l4)()}}))}(e,t)}),t.on("afterSendEvent",(t,r)=>{if(!e.isEnabled()||t.type&&!iS(t))return;let n=r&&r.statusCode;if(n&&!(n<200)&&!(n>=300)){if(iS(t)){(function(e,t){let r=e.getContext();t.contexts&&t.contexts.trace&&t.contexts.trace.trace_id&&r.traceIds.size<100&&r.traceIds.add(t.contexts.trace.trace_id)})(e,t);return}(function(e,t){let r=e.getContext();if(t.event_id&&r.errorIds.size<100&&r.errorIds.add(t.event_id),"buffer"!==e.recordingMode||!t.tags||!t.tags.replayId)return;let{beforeErrorSampling:n}=e.getOptions();("function"!=typeof n||n(t))&&(0,rn.iK)(()=>{e.sendBufferedReplayOrFlush()})})(e,t)}}),t.on("createDsc",t=>{let r=e.getSessionId();r&&e.isEnabled()&&"session"===e.recordingMode&&e.checkAndHandleExpiredSession()&&(t.replay_id=r)}),t.on("spanStart",t=>{e.lastActiveSpan=t}),t.on("spanEnd",t=>{e.lastActiveSpan=t}),t.on("beforeSendFeedback",(t,r)=>{let n=e.getSessionId();r&&r.includeReplay&&e.isEnabled()&&n&&t.contexts&&t.contexts.feedback&&(t.contexts.feedback.replay_id=n)}))}(this),this._hasInitializedCoreListeners=!0)}catch(e){this.handleException(e)}this._performanceCleanupCallback=function(e){function t(t){e.performanceEntries.includes(t)||e.performanceEntries.push(t)}function r({entries:e}){e.forEach(t)}let n=[];return["navigation","paint","resource"].forEach(e=>{n.push(e3(e,r))}),n.push(e0(n0(n3,e)),eY(n0(n4,e)),e1(n0(n9,e)),e2(n0(n5,e))),()=>{n.forEach(e=>e())}}(this)}_removeListeners(){try{rs.document.removeEventListener("visibilitychange",this._handleVisibilityChange),rs.removeEventListener("blur",this._handleWindowBlur),rs.removeEventListener("focus",this._handleWindowFocus),rs.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(e){this.handleException(e)}}__init(){this._handleVisibilityChange=()=>{"visible"===rs.document.visibilityState?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{let e=nV({category:"ui.blur"});this._doChangeToBackgroundTasks(e)}}__init3(){this._handleWindowFocus=()=>{let e=nV({category:"ui.focus"});this._doChangeToForegroundTasks(e)}}__init4(){this._handleKeyboardEvent=e=>{!function(e,t){if(!e.isEnabled())return;e.updateUserActivity();let r=function(e){var t;let{metaKey:r,shiftKey:n,ctrlKey:i,altKey:s,key:o,target:a}=e;if(!a||"INPUT"===(t=a).tagName||"TEXTAREA"===t.tagName||t.isContentEditable||!o)return null;let u=r||i||s,l=1===o.length;if(!u&&l)return null;let c=(0,eo.Rt)(a,{maxStringLength:200})||"<unknown>",d=nJ(a,c);return nV({category:"ui.keyDown",message:c,data:{...d.data,metaKey:r,shiftKey:n,ctrlKey:i,altKey:s,key:o}})}(t);r&&nz(e,r)}(this,e)}}_doChangeToBackgroundTasks(e){!this.session||im(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(e&&this._createCustomBreadcrumb(e),this.conditionalFlush())}_doChangeToForegroundTasks(e){if(this.session){if(!this.checkAndHandleExpiredSession()){n7("[Replay] Document has become active, but session has expired");return}e&&this._createCustomBreadcrumb(e)}}_updateUserActivity(e=Date.now()){this._lastActivity=e}_updateSessionActivity(e=Date.now()){this.session&&(this.session.lastActivity=e,this._maybeSaveSession())}_createCustomBreadcrumb(e){this.addUpdate(()=>{this.throttledAddEvent({type:ns.Custom,timestamp:e.timestamp||0,data:{tag:"breadcrumb",payload:e}})})}_addPerformanceEntries(){let e=this.performanceEntries.map(n1).filter(Boolean).concat(this.replayPerformanceEntries);return this.performanceEntries=[],this.replayPerformanceEntries=[],Promise.all(iO(this,e))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){let{session:e,eventBuffer:t}=this;if(!e||!t||this._requiresManualStart||e.segmentId)return;let r=t.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}_popEventContext(){let e={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),e}async _runFlush(){let e=this.getSessionId();if(!this.session||!this.eventBuffer||!e){n6&&B.kg.error("[Replay] No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),this.eventBuffer&&this.eventBuffer.hasEvents&&(await iq(this),this.eventBuffer&&e===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();let t=Date.now();if(t-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw Error("Session is too long, not sending replay");let r=this._popEventContext(),n=this.session.segmentId++;this._maybeSaveSession();let i=await this.eventBuffer.finish();await iQ({replayId:e,recordingData:i,segmentId:n,eventContext:r,session:this.session,options:this.getOptions(),timestamp:t})}catch(t){this.handleException(t),this.stop({reason:"sendReplay"});let e=(0,C.s3)();e&&e.recordDroppedEvent("send_error","replay")}}__init5(){this._flush=async({force:e=!1}={})=>{if(!this._isEnabled&&!e)return;if(!this.checkAndHandleExpiredSession()){n6&&B.kg.error("[Replay] Attempting to finish replay event after session expired.");return}if(!this.session)return;let t=this.session.started,r=Date.now()-t;this._debouncedFlush.cancel();let n=r<this._options.minReplayDuration,i=r>this._options.maxReplayDuration+5e3;if(n||i){n7(`[Replay] Session duration (${Math.floor(r/1e3)}s) is too ${n?"short":"long"}, not sending replay.`,this._options._experiments.traceInternals),n&&this._debouncedFlush();return}let s=this.eventBuffer;if(s&&0===this.session.segmentId&&!s.hasCheckout&&n7("[Replay] Flushing initial segment without checkout.",this._options._experiments.traceInternals),!this._flushLock){this._flushLock=this._runFlush(),await this._flushLock,this._flushLock=void 0;return}try{await this._flushLock}catch(e){n6&&B.kg.error(e)}finally{this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&id(this.session)}__init6(){this._onMutationHandler=e=>{let t=e.length,r=this._options.mutationLimit,n=this._options.mutationBreadcrumbLimit,i=r&&t>r;if(t>n||i){let e=nV({category:"replay.mutations",data:{count:t,limit:i}});this._createCustomBreadcrumb(e)}return!i||(this.stop({reason:"mutationLimit",forceFlush:"session"===this.recordingMode}),!1)}}}function iY(e,t){return[...e,...t].join(",")}let i0='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',i1=["content-length","content-type","accept"],i2=!1;class i3{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:e=5e3,flushMaxDelay:t=5500,minReplayDuration:r=4999,maxReplayDuration:n=36e5,stickySession:i=!0,useCompression:s=!0,workerUrl:o,_experiments:a={},maskAllText:u=!0,maskAllInputs:l=!0,blockAllMedia:c=!0,mutationBreadcrumbLimit:d=750,mutationLimit:f=1e4,slowClickTimeout:h=7e3,slowClickIgnoreSelectors:p=[],networkDetailAllowUrls:m=[],networkDetailDenyUrls:g=[],networkCaptureBodies:y=!0,networkRequestHeaders:v=[],networkResponseHeaders:_=[],mask:b=[],maskAttributes:S=["title","placeholder"],unmask:E=[],block:w=[],unblock:O=[],ignore:k=[],maskFn:T,beforeAddRecordingEvent:C,beforeErrorSampling:I}={}){this.name=i3.id;let R=function({mask:e,unmask:t,block:r,unblock:n,ignore:i}){return{maskTextSelector:iY(e,[".sentry-mask","[data-sentry-mask]"]),unmaskTextSelector:iY(t,[]),blockSelector:iY(r,[".sentry-block","[data-sentry-block]",'base[href="/"]']),unblockSelector:iY(n,[]),ignoreSelector:iY(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}({mask:b,unmask:E,block:w,unblock:O,ignore:k});if(this._recordingOptions={maskAllInputs:l,maskAllText:u,maskInputOptions:{password:!0},maskTextFn:T,maskInputFn:T,maskAttributeFn:(e,t,r)=>(function({el:e,key:t,maskAttributes:r,maskAllText:n,privacyOptions:i,value:s}){return!n||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?s:r.includes(t)||"value"===t&&"INPUT"===e.tagName&&["submit","button"].includes(e.getAttribute("type")||"")?s.replace(/[\S]/g,"*"):s})({maskAttributes:S,maskAllText:u,privacyOptions:R,key:e,value:t,el:r}),...R,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:e=>{try{e.__rrweb__=!0}catch(e){}}},this._initialOptions={flushMinDelay:e,flushMaxDelay:t,minReplayDuration:Math.min(r,15e3),maxReplayDuration:Math.min(n,36e5),stickySession:i,useCompression:s,workerUrl:o,blockAllMedia:c,maskAllInputs:l,maskAllText:u,mutationBreadcrumbLimit:d,mutationLimit:f,slowClickTimeout:h,slowClickIgnoreSelectors:p,networkDetailAllowUrls:m,networkDetailDenyUrls:g,networkCaptureBodies:y,networkRequestHeaders:i4(v),networkResponseHeaders:i4(_),beforeAddRecordingEvent:C,beforeErrorSampling:I,_experiments:a},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${i0}`:i0),this._isInitialized&&rr())throw Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return i2}set _isInitialized(e){i2=e}afterAllSetup(e){rr()&&!this._replay&&(this._setup(e),this._initialize(e))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:"session"===this._replay.recordingMode}):Promise.resolve()}flush(e){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(e):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(){if(this._replay&&this._replay.isEnabled())return this._replay.getSessionId()}_initialize(e){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(e),this._replay.initializeSampling())}_setup(e){let t=function(e,t){let r=t.getOptions(),n={sessionSampleRate:0,errorSampleRate:0,...(0,q.Jr)(e)},i=(0,$.o)(r.replaysSessionSampleRate),s=(0,$.o)(r.replaysOnErrorSampleRate);return null==i&&null==s&&(0,B.Cf)(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),null!=i&&(n.sessionSampleRate=i),null!=s&&(n.errorSampleRate=s),n}(this._initialOptions,e);this._replay=new iJ({options:t,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(e){try{let t=e.getIntegrationByName("ReplayCanvas");if(!t)return;this._replay._canvas=t.getOptions()}catch(e){}}}function i4(e){return[...i1,...e.map(e=>e.toLowerCase())]}i3.__initStatic();var i9=r(34155);globalThis.__sentryRewritesTunnelPath__=void 0,globalThis.SENTRY_RELEASE={id:"ed092b1bd2b6a41a45131d282b09a7c0ad739eef"},globalThis.__sentryBasePath=void 0,globalThis.__rewriteFramesAssetPrefixPath__="",!function(e){let t={environment:function(e){let t=e?P.env.NEXT_PUBLIC_VERCEL_ENV:P.env.VERCEL_ENV;return t?`vercel-${t}`:void 0}(!0)||"production",defaultIntegrations:function(e){let t=(0,R.nV)(e);("undefined"==typeof __SENTRY_TRACING__||__SENTRY_TRACING__)&&I(e)&&t.push(function(e={}){let t=tU({...e,instrumentNavigation:!1,instrumentPageLoad:!1}),{instrumentPageLoad:r=!0,instrumentNavigation:n=!0}=e;return{...t,afterAllSetup(e){var i;n&&(i=e,tk.m9.document.getElementById("__NEXT_DATA__")?tq.events.on("routeChangeStart",e=>{let t,r;let n=(0,ea.rt)(e),s=function(e){let t=(tZ.__BUILD_MANIFEST||{}).sortedPages;if(t)return t.find(t=>{let r=function(e){let t=e.split("/"),r="";(0,tz.x)([t,"access",e=>e[t.length-1],"optionalAccess",e=>e.match,"call",e=>e(/^\[\[\.\.\..+\]\]$/)])&&(t.pop(),r="(?:/(.+?))?");let n=t.map(e=>e.replace(/^\[\.\.\..+\]$/,"(.+?)").replace(/^\[.*\]$/,"([^/]+?)")).join("/");return RegExp(`^${n}${r}(?:/)?$`)}(t);return e.match(r)})}(n);s?(t=s,r="route"):(t=n,r="url"),tF(i,{name:t,attributes:{[L.$J]:"navigation",[L.S3]:"auto.navigation.nextjs.pages_router_instrumentation",[L.Zj]:r}})}):(0,tR.Uf)(e=>{if(void 0!==e.endTimestamp||"GET"!==e.fetchData.method)return;let t=function(e){if(!e[0]||"object"!=typeof e[0]||void 0===e[0].searchParams||!e[1]||"object"!=typeof e[1]||!("headers"in e[1]))return null;try{let t=e[0],r=e[1].headers;if("1"!==r.RSC||"1"===r["Next-Router-Prefetch"])return null;return{targetPathname:t.pathname}}catch(e){return null}}(e.args);null!==t&&tF(i,{name:t.targetPathname,attributes:{[L.$J]:"navigation",[L.S3]:"auto.navigation.nextjs.app_router_instrumentation",[L.Zj]:"url"}})})),t.afterAllSetup(e),r&&(tk.m9.document.getElementById("__NEXT_DATA__")?function(e){let{route:t,params:r,sentryTrace:n,baggage:i}=function(){let e;let t=tZ.document.getElementById("__NEXT_DATA__");if(t&&t.innerHTML)try{e=JSON.parse(t.innerHTML)}catch(e){tG.X&&B.kg.warn("Could not extract __NEXT_DATA__")}if(!e)return{};let r={},{page:n,query:i,props:s}=e;return r.route=n,r.params=i,s&&s.pageProps&&(r.sentryTrace=s.pageProps._sentryTraceData,r.baggage=s.pageProps._sentryBaggage),r}();tB(e,{name:t||tZ.location.pathname,startTime:G.Z1?G.Z1/1e3:void 0,attributes:{[L.$J]:"pageload",[L.S3]:"auto.pageload.nextjs.pages_router_instrumentation",[L.Zj]:t?"route":"url",...r&&e.getOptions().sendDefaultPii&&{...r}}},{sentryTrace:n,baggage:i})}(e):tB(e,{name:tk.m9.location.pathname,startTime:G.Z1?G.Z1/1e3:void 0,attributes:{[L.$J]:"pageload",[L.S3]:"auto.pageload.nextjs.app_router_instrumentation",[L.Zj]:"url"}}))}}}());let r=t1.__rewriteFramesAssetPrefixPath__||"";return t.push(tJ({assetPrefixPath:r})),t}(e),...e};(function(e){let t=t0.__sentryRewritesTunnelPath__;if(t&&e.dsn){let r=(0,tY.U4)(e.dsn);if(!r)return;let n=r.host.match(/^o(\d+)\.ingest(?:\.([a-z]{2}))?\.sentry\.io$/);if(n){let i=n[1],s=n[2],o=`${t}?o=${i}&p=${r.projectId}`;s&&(o+=`&r=${s}`),e.tunnel=o,tG.X&&B.kg.info(`Tunneling events to "${o}"`)}else tG.X&&B.kg.warn("Provided DSN is not a Sentry SaaS DSN. Will not tunnel events.")}})(t),(0,k.V)(t,"nextjs",["nextjs","react"]),function(e){let t={...e};(0,k.V)(t,"react"),(0,T.v)("react",{version:x.version}),(0,R.S1)(t)}(t);let r=e=>"transaction"===e.type&&"/404"===e.transaction?null:e;r.id="NextClient404Filter",(0,T.Qy)(r)}({dsn:i9.env.SENTRY_DSN||"https://be66e94c3a094163bca68a9f3c01c154@o4504791820337152.ingest.sentry.io/4504791922966528",environment:"production",tracesSampleRate:1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1,integrations:[new i3({maskAllText:!1,blockAllMedia:!1})]})},32646:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useRouter",{enumerable:!0,get:function(){return s}});let n=r(67294),i=r(9953);function s(){return(0,n.useContext)(i.RouterContext)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},8875:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"actionAsyncStorage",{enumerable:!0,get:function(){return n}});let n=(0,r(95039).createAsyncLocalStorage)();("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},26208:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"actionAsyncStorage",{enumerable:!0,get:function(){return n.actionAsyncStorage}});let n=r(8875);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},95039:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"createAsyncLocalStorage",{enumerable:!0,get:function(){return s}});let r=Error("Invariant: AsyncLocalStorage accessed in runtime where it is not available");class n{disable(){throw r}getStore(){}run(){throw r}exit(){throw r}enterWith(){throw r}}let i=globalThis.AsyncLocalStorage;function s(){return i?new i:new n}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},61649:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"DraftMode",{enumerable:!0,get:function(){return s}});let n=r(34916),i=r(47325);class s{get isEnabled(){return this._provider.isEnabled}enable(){let e=n.staticGenerationAsyncStorage.getStore();return e&&(0,i.trackDynamicDataAccessed)(e,"draftMode().enable()"),this._provider.enable()}disable(){let e=n.staticGenerationAsyncStorage.getStore();return e&&(0,i.trackDynamicDataAccessed)(e,"draftMode().disable()"),this._provider.disable()}constructor(e){this._provider=e}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},89383:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{cookies:function(){return f},draftMode:function(){return h},headers:function(){return d}});let n=r(9407),i=r(34042),s=r(80255),o=r(26208),a=r(61649),u=r(47325),l=r(34916),c=r(77218);function d(){let e="headers",t=l.staticGenerationAsyncStorage.getStore();if(t){if(t.forceStatic)return i.HeadersAdapter.seal(new Headers({}));(0,u.trackDynamicDataAccessed)(t,e)}return(0,c.getExpectedRequestStore)(e).headers}function f(){let e="cookies",t=l.staticGenerationAsyncStorage.getStore();if(t){if(t.forceStatic)return n.RequestCookiesAdapter.seal(new s.RequestCookies(new Headers({})));(0,u.trackDynamicDataAccessed)(t,e)}let r=(0,c.getExpectedRequestStore)(e),i=o.actionAsyncStorage.getStore();return(null==i?void 0:i.isAction)||(null==i?void 0:i.isAppRoute)?r.mutableCookies:r.cookies}function h(){let e=(0,c.getExpectedRequestStore)("draftMode");return new a.DraftMode(e.draftMode)}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},6253:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{DynamicServerError:function(){return n},isDynamicServerError:function(){return i}});let r="DYNAMIC_SERVER_USAGE";class n extends Error{constructor(e){super("Dynamic server usage: "+e),this.description=e,this.digest=r}}function i(e){return"object"==typeof e&&null!==e&&"digest"in e&&"string"==typeof e.digest&&e.digest===r}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},70827:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ReadonlyURLSearchParams:function(){return u.ReadonlyURLSearchParams},RedirectType:function(){return u.RedirectType},ServerInsertedHTMLContext:function(){return l.ServerInsertedHTMLContext},notFound:function(){return u.notFound},permanentRedirect:function(){return u.permanentRedirect},redirect:function(){return u.redirect},useParams:function(){return h},usePathname:function(){return d},useRouter:function(){return f},useSearchParams:function(){return c},useSelectedLayoutSegment:function(){return m},useSelectedLayoutSegments:function(){return p},useServerInsertedHTML:function(){return l.useServerInsertedHTML}});let n=r(67294),i=r(15320),s=r(51083),o=r(55363),a=r(74722),u=r(34138),l=r(23617);function c(){let e=(0,n.useContext)(s.SearchParamsContext);return(0,n.useMemo)(()=>e?new u.ReadonlyURLSearchParams(e):null,[e])}function d(){return(0,n.useContext)(s.PathnameContext)}function f(){let e=(0,n.useContext)(i.AppRouterContext);if(null===e)throw Error("invariant expected app router to be mounted");return e}function h(){return(0,n.useContext)(s.PathParamsContext)}function p(e){void 0===e&&(e="children");let t=(0,n.useContext)(i.LayoutRouterContext);return t?function e(t,r,n,i){let s;if(void 0===n&&(n=!0),void 0===i&&(i=[]),n)s=t[1][r];else{var u;let e=t[1];s=null!=(u=e.children)?u:Object.values(e)[0]}if(!s)return i;let l=s[0],c=(0,o.getSegmentValue)(l);return!c||c.startsWith(a.PAGE_SEGMENT_KEY)?i:(i.push(c),e(s,r,!1,i))}(t.tree,e):null}function m(e){void 0===e&&(e="children");let t=p(e);if(!t||0===t.length)return null;let r="children"===e?t[0]:t[t.length-1];return r===a.DEFAULT_SEGMENT_KEY?null:r}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},34138:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ReadonlyURLSearchParams:function(){return o},RedirectType:function(){return n.RedirectType},notFound:function(){return i.notFound},permanentRedirect:function(){return n.permanentRedirect},redirect:function(){return n.redirect}});let n=r(2830),i=r(79399);class s extends Error{constructor(){super("Method unavailable on `ReadonlyURLSearchParams`. Read more: https://nextjs.org/docs/app/api-reference/functions/use-search-params#updating-searchparams")}}class o extends URLSearchParams{append(){throw new s}delete(){throw new s}set(){throw new s}sort(){throw new s}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},79399:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{isNotFoundError:function(){return i},notFound:function(){return n}});let r="NEXT_NOT_FOUND";function n(){let e=Error(r);throw e.digest=r,e}function i(e){return"object"==typeof e&&null!==e&&"digest"in e&&e.digest===r}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},78074:function(e,t){"use strict";var r,n;Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"RedirectStatusCode",{enumerable:!0,get:function(){return r}}),(n=r||(r={}))[n.SeeOther=303]="SeeOther",n[n.TemporaryRedirect=307]="TemporaryRedirect",n[n.PermanentRedirect=308]="PermanentRedirect",("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},2830:function(e,t,r){"use strict";var n,i;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{RedirectType:function(){return n},getRedirectError:function(){return l},getRedirectStatusCodeFromError:function(){return m},getRedirectTypeFromError:function(){return p},getURLFromRedirectError:function(){return h},isRedirectError:function(){return f},permanentRedirect:function(){return d},redirect:function(){return c}});let s=r(77218),o=r(26208),a=r(78074),u="NEXT_REDIRECT";function l(e,t,r){void 0===r&&(r=a.RedirectStatusCode.TemporaryRedirect);let n=Error(u);n.digest=u+";"+t+";"+e+";"+r+";";let i=s.requestAsyncStorage.getStore();return i&&(n.mutableCookies=i.mutableCookies),n}function c(e,t){void 0===t&&(t="replace");let r=o.actionAsyncStorage.getStore();throw l(e,t,(null==r?void 0:r.isAction)?a.RedirectStatusCode.SeeOther:a.RedirectStatusCode.TemporaryRedirect)}function d(e,t){void 0===t&&(t="replace");let r=o.actionAsyncStorage.getStore();throw l(e,t,(null==r?void 0:r.isAction)?a.RedirectStatusCode.SeeOther:a.RedirectStatusCode.PermanentRedirect)}function f(e){if("object"!=typeof e||null===e||!("digest"in e)||"string"!=typeof e.digest)return!1;let[t,r,n,i]=e.digest.split(";",4),s=Number(i);return t===u&&("replace"===r||"push"===r)&&"string"==typeof n&&!isNaN(s)&&s in a.RedirectStatusCode}function h(e){return f(e)?e.digest.split(";",3)[2]:null}function p(e){if(!f(e))throw Error("Not a redirect error");return e.digest.split(";",2)[1]}function m(e){if(!f(e))throw Error("Not a redirect error");return Number(e.digest.split(";",4)[3])}(i=n||(n={})).push="push",i.replace="replace",("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},6718:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"requestAsyncStorage",{enumerable:!0,get:function(){return n}});let n=(0,r(95039).createAsyncLocalStorage)();("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},77218:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{getExpectedRequestStore:function(){return i},requestAsyncStorage:function(){return n.requestAsyncStorage}});let n=r(6718);function i(e){let t=n.requestAsyncStorage.getStore();if(t)return t;throw Error("`"+e+"` was called outside a request scope. Read more: https://nextjs.org/docs/messages/next-dynamic-api-wrong-context")}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},55363:function(e,t){"use strict";function r(e){return Array.isArray(e)?e[1]:e}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getSegmentValue",{enumerable:!0,get:function(){return r}}),("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},46691:function(e,t){"use strict";var r,n,i,s;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ACTION_FAST_REFRESH:function(){return d},ACTION_NAVIGATE:function(){return a},ACTION_PREFETCH:function(){return c},ACTION_REFRESH:function(){return o},ACTION_RESTORE:function(){return u},ACTION_SERVER_ACTION:function(){return f},ACTION_SERVER_PATCH:function(){return l},PrefetchCacheEntryStatus:function(){return n},PrefetchKind:function(){return r},isThenable:function(){return h}});let o="refresh",a="navigate",u="restore",l="server-patch",c="prefetch",d="fast-refresh",f="server-action";function h(e){return e&&("object"==typeof e||"function"==typeof e)&&"function"==typeof e.then}(i=r||(r={})).AUTO="auto",i.FULL="full",i.TEMPORARY="temporary",(s=n||(n={})).fresh="fresh",s.reusable="reusable",s.expired="expired",s.stale="stale",("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},41403:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"staticGenerationAsyncStorage",{enumerable:!0,get:function(){return n}});let n=(0,r(95039).createAsyncLocalStorage)();("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},34916:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"staticGenerationAsyncStorage",{enumerable:!0,get:function(){return n.staticGenerationAsyncStorage}});let n=r(41403);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},78984:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{StaticGenBailoutError:function(){return n},isStaticGenBailoutError:function(){return i}});let r="NEXT_STATIC_GEN_BAILOUT";class n extends Error{constructor(...e){super(...e),this.code=r}}function i(e){return"object"==typeof e&&null!==e&&"code"in e&&e.code===r}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},64318:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getDomainLocale",{enumerable:!0,get:function(){return i}});let n=r(98364);function i(e,t,i,s){{let o=r(19720).normalizeLocalePath,a=r(13656).detectDomainLocale,u=t||o(e,i).detectedLocale,l=a(s,void 0,u);if(l){let t="http"+(l.http?"":"s")+"://",r=u===l.defaultLocale?"":"/"+u;return""+t+l.domain+(0,n.normalizePathTrailingSlash)(""+r+e)}return!1}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},26541:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"Image",{enumerable:!0,get:function(){return _}});let n=r(38754),i=r(61757),s=r(85893),o=i._(r(67294)),a=n._(r(73935)),u=n._(r(7828)),l=r(17367),c=r(27903),d=r(54938);r(1997);let f=r(9953),h=n._(r(56663)),p={deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1};function m(e,t,r,n,i,s,o){let a=null==e?void 0:e.src;e&&e["data-loaded-src"]!==a&&(e["data-loaded-src"]=a,("decode"in e?e.decode():Promise.resolve()).catch(()=>{}).then(()=>{if(e.parentElement&&e.isConnected){if("empty"!==t&&i(!0),null==r?void 0:r.current){let t=new Event("load");Object.defineProperty(t,"target",{writable:!1,value:e});let n=!1,i=!1;r.current({...t,nativeEvent:t,currentTarget:e,target:e,isDefaultPrevented:()=>n,isPropagationStopped:()=>i,persist:()=>{},preventDefault:()=>{n=!0,t.preventDefault()},stopPropagation:()=>{i=!0,t.stopPropagation()}})}(null==n?void 0:n.current)&&n.current(e)}}))}function g(e){return o.use?{fetchPriority:e}:{fetchpriority:e}}let y=(0,o.forwardRef)((e,t)=>{let{src:r,srcSet:n,sizes:i,height:a,width:u,decoding:l,className:c,style:d,fetchPriority:f,placeholder:h,loading:p,unoptimized:y,fill:v,onLoadRef:_,onLoadingCompleteRef:b,setBlurComplete:S,setShowAltText:E,sizesInput:w,onLoad:O,onError:k,...T}=e;return(0,s.jsx)("img",{...T,...g(f),loading:p,width:u,height:a,decoding:l,"data-nimg":v?"fill":"1",className:c,style:d,sizes:i,srcSet:n,src:r,ref:(0,o.useCallback)(e=>{t&&("function"==typeof t?t(e):"object"==typeof t&&(t.current=e)),e&&(k&&(e.src=e.src),e.complete&&m(e,h,_,b,S,y,w))},[r,h,_,b,S,k,y,w,t]),onLoad:e=>{m(e.currentTarget,h,_,b,S,y,w)},onError:e=>{E(!0),"empty"!==h&&S(!0),k&&k(e)}})});function v(e){let{isAppRouter:t,imgAttributes:r}=e,n={as:"image",imageSrcSet:r.srcSet,imageSizes:r.sizes,crossOrigin:r.crossOrigin,referrerPolicy:r.referrerPolicy,...g(r.fetchPriority)};return t&&a.default.preload?(a.default.preload(r.src,n),null):(0,s.jsx)(u.default,{children:(0,s.jsx)("link",{rel:"preload",href:r.srcSet?void 0:r.src,...n},"__nimg-"+r.src+r.srcSet+r.sizes)})}let _=(0,o.forwardRef)((e,t)=>{let r=(0,o.useContext)(f.RouterContext),n=(0,o.useContext)(d.ImageConfigContext),i=(0,o.useMemo)(()=>{let e=p||n||c.imageConfigDefault,t=[...e.deviceSizes,...e.imageSizes].sort((e,t)=>e-t),r=e.deviceSizes.sort((e,t)=>e-t);return{...e,allSizes:t,deviceSizes:r}},[n]),{onLoad:a,onLoadingComplete:u}=e,m=(0,o.useRef)(a);(0,o.useEffect)(()=>{m.current=a},[a]);let g=(0,o.useRef)(u);(0,o.useEffect)(()=>{g.current=u},[u]);let[_,b]=(0,o.useState)(!1),[S,E]=(0,o.useState)(!1),{props:w,meta:O}=(0,l.getImgProps)(e,{defaultLoader:h.default,imgConf:i,blurComplete:_,showAltText:S});return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(y,{...w,unoptimized:O.unoptimized,placeholder:O.placeholder,fill:O.fill,onLoadRef:m,onLoadingCompleteRef:g,setBlurComplete:b,setShowAltText:E,sizesInput:e.sizes,ref:t}),O.priority?(0,s.jsx)(v,{isAppRouter:!r,imgAttributes:w}):null]})});("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},89577:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return b}});let n=r(38754),i=r(85893),s=n._(r(67294)),o=r(71401),a=r(2045),u=r(27420),l=r(57201),c=r(11443),d=r(9953),f=r(15320),h=r(52905),p=r(64318),m=r(90953),g=r(46691),y=new Set;function v(e,t,r,n,i,s){if(s||(0,a.isLocalURL)(t)){if(!n.bypassPrefetchedCheck){let i=t+"%"+r+"%"+(void 0!==n.locale?n.locale:"locale"in e?e.locale:void 0);if(y.has(i))return;y.add(i)}(async()=>s?e.prefetch(t,i):e.prefetch(t,r,n))().catch(e=>{})}}function _(e){return"string"==typeof e?e:(0,u.formatUrl)(e)}let b=s.default.forwardRef(function(e,t){let r,n;let{href:u,as:y,children:b,prefetch:S=null,passHref:E,replace:w,shallow:O,scroll:k,locale:T,onClick:C,onMouseEnter:I,onTouchStart:R,legacyBehavior:x=!1,...A}=e;r=b,x&&("string"==typeof r||"number"==typeof r)&&(r=(0,i.jsx)("a",{children:r}));let P=s.default.useContext(d.RouterContext),M=s.default.useContext(f.AppRouterContext),N=null!=P?P:M,D=!P,L=!1!==S,j=null===S?g.PrefetchKind.AUTO:g.PrefetchKind.FULL,{href:U,as:B}=s.default.useMemo(()=>{if(!P){let e=_(u);return{href:e,as:y?_(y):e}}let[e,t]=(0,o.resolveHref)(P,u,!0);return{href:e,as:y?(0,o.resolveHref)(P,y):t||e}},[P,u,y]),F=s.default.useRef(U),$=s.default.useRef(B);x&&(n=s.default.Children.only(r));let z=x?n&&"object"==typeof n&&n.ref:t,[H,G,q]=(0,h.useIntersection)({rootMargin:"200px"}),Z=s.default.useCallback(e=>{($.current!==B||F.current!==U)&&(q(),$.current=B,F.current=U),H(e),z&&("function"==typeof z?z(e):"object"==typeof z&&(z.current=e))},[B,z,U,q,H]);s.default.useEffect(()=>{N&&G&&L&&v(N,U,B,{locale:T},{kind:j},D)},[B,U,G,T,L,null==P?void 0:P.locale,N,D,j]);let W={ref:Z,onClick(e){x||"function"!=typeof C||C(e),x&&n.props&&"function"==typeof n.props.onClick&&n.props.onClick(e),N&&!e.defaultPrevented&&function(e,t,r,n,i,o,u,l,c){let{nodeName:d}=e.currentTarget;if("A"===d.toUpperCase()&&(function(e){let t=e.currentTarget.getAttribute("target");return t&&"_self"!==t||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.nativeEvent&&2===e.nativeEvent.which}(e)||!c&&!(0,a.isLocalURL)(r)))return;e.preventDefault();let f=()=>{let e=null==u||u;"beforePopState"in t?t[i?"replace":"push"](r,n,{shallow:o,locale:l,scroll:e}):t[i?"replace":"push"](n||r,{scroll:e})};c?s.default.startTransition(f):f()}(e,N,U,B,w,O,k,T,D)},onMouseEnter(e){x||"function"!=typeof I||I(e),x&&n.props&&"function"==typeof n.props.onMouseEnter&&n.props.onMouseEnter(e),N&&(L||!D)&&v(N,U,B,{locale:T,priority:!0,bypassPrefetchedCheck:!0},{kind:j},D)},onTouchStart:function(e){x||"function"!=typeof R||R(e),x&&n.props&&"function"==typeof n.props.onTouchStart&&n.props.onTouchStart(e),N&&(L||!D)&&v(N,U,B,{locale:T,priority:!0,bypassPrefetchedCheck:!0},{kind:j},D)}};if((0,l.isAbsoluteUrl)(B))W.href=B;else if(!x||E||"a"===n.type&&!("href"in n.props)){let e=void 0!==T?T:null==P?void 0:P.locale,t=(null==P?void 0:P.isLocaleDomain)&&(0,p.getDomainLocale)(B,e,null==P?void 0:P.locales,null==P?void 0:P.domainLocales);W.href=t||(0,m.addBasePath)((0,c.addLocale)(B,e,null==P?void 0:P.defaultLocale))}return x?s.default.cloneElement(n,W):(0,i.jsx)("a",{...A,...W,children:r})});("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},19720:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"normalizeLocalePath",{enumerable:!0,get:function(){return n}});let n=(e,t)=>r(1808).normalizeLocalePath(e,t);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},52905:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useIntersection",{enumerable:!0,get:function(){return u}});let n=r(67294),i=r(33815),s="function"==typeof IntersectionObserver,o=new Map,a=[];function u(e){let{rootRef:t,rootMargin:r,disabled:u}=e,l=u||!s,[c,d]=(0,n.useState)(!1),f=(0,n.useRef)(null),h=(0,n.useCallback)(e=>{f.current=e},[]);return(0,n.useEffect)(()=>{if(s){if(l||c)return;let e=f.current;if(e&&e.tagName)return function(e,t,r){let{id:n,observer:i,elements:s}=function(e){let t;let r={root:e.root||null,margin:e.rootMargin||""},n=a.find(e=>e.root===r.root&&e.margin===r.margin);if(n&&(t=o.get(n)))return t;let i=new Map;return t={id:r,observer:new IntersectionObserver(e=>{e.forEach(e=>{let t=i.get(e.target),r=e.isIntersecting||e.intersectionRatio>0;t&&r&&t(r)})},e),elements:i},a.push(r),o.set(r,t),t}(r);return s.set(e,t),i.observe(e),function(){if(s.delete(e),i.unobserve(e),0===s.size){i.disconnect(),o.delete(n);let e=a.findIndex(e=>e.root===n.root&&e.margin===n.margin);e>-1&&a.splice(e,1)}}}(e,e=>e&&d(e),{root:null==t?void 0:t.current,rootMargin:r})}else if(!c){let e=(0,i.requestIdleCallback)(()=>d(!0));return()=>(0,i.cancelIdleCallback)(e)}},[l,r,t,c,f.current]),[h,c,(0,n.useCallback)(()=>{d(!1)},[])]}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},17367:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImgProps",{enumerable:!0,get:function(){return a}}),r(1997);let n=r(69919),i=r(27903);function s(e){return void 0!==e.default}function o(e){return void 0===e?e:"number"==typeof e?Number.isFinite(e)?e:NaN:"string"==typeof e&&/^[0-9]+$/.test(e)?parseInt(e,10):NaN}function a(e,t){var r;let a,u,l,{src:c,sizes:d,unoptimized:f=!1,priority:h=!1,loading:p,className:m,quality:g,width:y,height:v,fill:_=!1,style:b,overrideSrc:S,onLoad:E,onLoadingComplete:w,placeholder:O="empty",blurDataURL:k,fetchPriority:T,layout:C,objectFit:I,objectPosition:R,lazyBoundary:x,lazyRoot:A,...P}=e,{imgConf:M,showAltText:N,blurComplete:D,defaultLoader:L}=t,j=M||i.imageConfigDefault;if("allSizes"in j)a=j;else{let e=[...j.deviceSizes,...j.imageSizes].sort((e,t)=>e-t),t=j.deviceSizes.sort((e,t)=>e-t);a={...j,allSizes:e,deviceSizes:t}}if(void 0===L)throw Error("images.loaderFile detected but the file is missing default export.\nRead more: https://nextjs.org/docs/messages/invalid-images-config");let U=P.loader||L;delete P.loader,delete P.srcSet;let B="__next_img_default"in U;if(B){if("custom"===a.loader)throw Error('Image with src "'+c+'" is missing "loader" prop.\nRead more: https://nextjs.org/docs/messages/next-image-missing-loader')}else{let e=U;U=t=>{let{config:r,...n}=t;return e(n)}}if(C){"fill"===C&&(_=!0);let e={intrinsic:{maxWidth:"100%",height:"auto"},responsive:{width:"100%",height:"auto"}}[C];e&&(b={...b,...e});let t={responsive:"100vw",fill:"100vw"}[C];t&&!d&&(d=t)}let F="",$=o(y),z=o(v);if("object"==typeof(r=c)&&(s(r)||void 0!==r.src)){let e=s(c)?c.default:c;if(!e.src)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include src. Received "+JSON.stringify(e));if(!e.height||!e.width)throw Error("An object should only be passed to the image component src parameter if it comes from a static image import. It must include height and width. Received "+JSON.stringify(e));if(u=e.blurWidth,l=e.blurHeight,k=k||e.blurDataURL,F=e.src,!_){if($||z){if($&&!z){let t=$/e.width;z=Math.round(e.height*t)}else if(!$&&z){let t=z/e.height;$=Math.round(e.width*t)}}else $=e.width,z=e.height}}let H=!h&&("lazy"===p||void 0===p);(!(c="string"==typeof c?c:F)||c.startsWith("data:")||c.startsWith("blob:"))&&(f=!0,H=!1),a.unoptimized&&(f=!0),B&&c.endsWith(".svg")&&!a.dangerouslyAllowSVG&&(f=!0),h&&(T="high");let G=o(g),q=Object.assign(_?{position:"absolute",height:"100%",width:"100%",left:0,top:0,right:0,bottom:0,objectFit:I,objectPosition:R}:{},N?{}:{color:"transparent"},b),Z=D||"empty"===O?null:"blur"===O?'url("data:image/svg+xml;charset=utf-8,'+(0,n.getImageBlurSvg)({widthInt:$,heightInt:z,blurWidth:u,blurHeight:l,blurDataURL:k||"",objectFit:q.objectFit})+'")':'url("'+O+'")',W=Z?{backgroundSize:q.objectFit||"cover",backgroundPosition:q.objectPosition||"50% 50%",backgroundRepeat:"no-repeat",backgroundImage:Z}:{},K=function(e){let{config:t,src:r,unoptimized:n,width:i,quality:s,sizes:o,loader:a}=e;if(n)return{src:r,srcSet:void 0,sizes:void 0};let{widths:u,kind:l}=function(e,t,r){let{deviceSizes:n,allSizes:i}=e;if(r){let e=/(^|\s)(1?\d?\d)vw/g,t=[];for(let n;n=e.exec(r);n)t.push(parseInt(n[2]));if(t.length){let e=.01*Math.min(...t);return{widths:i.filter(t=>t>=n[0]*e),kind:"w"}}return{widths:i,kind:"w"}}return"number"!=typeof t?{widths:n,kind:"w"}:{widths:[...new Set([t,2*t].map(e=>i.find(t=>t>=e)||i[i.length-1]))],kind:"x"}}(t,i,o),c=u.length-1;return{sizes:o||"w"!==l?o:"100vw",srcSet:u.map((e,n)=>a({config:t,src:r,quality:s,width:e})+" "+("w"===l?e:n+1)+l).join(", "),src:a({config:t,src:r,quality:s,width:u[c]})}}({config:a,src:c,unoptimized:f,width:$,quality:G,sizes:d,loader:U});return{props:{...P,loading:H?"lazy":p,fetchPriority:T,width:$,height:z,decoding:"async",className:m,style:{...q,...W},sizes:K.sizes,srcSet:K.srcSet,src:S||K.src},meta:{unoptimized:f,priority:h,placeholder:O,fill:_}}}},69919:function(e,t){"use strict";function r(e){let{widthInt:t,heightInt:r,blurWidth:n,blurHeight:i,blurDataURL:s,objectFit:o}=e,a=n?40*n:t,u=i?40*i:r,l=a&&u?"viewBox='0 0 "+a+" "+u+"'":"";return"%3Csvg xmlns='http://www.w3.org/2000/svg' "+l+"%3E%3Cfilter id='b' color-interpolation-filters='sRGB'%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3CfeColorMatrix values='1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 100 -1' result='s'/%3E%3CfeFlood x='0' y='0' width='100%25' height='100%25'/%3E%3CfeComposite operator='out' in='s'/%3E%3CfeComposite in2='SourceGraphic'/%3E%3CfeGaussianBlur stdDeviation='20'/%3E%3C/filter%3E%3Cimage width='100%25' height='100%25' x='0' y='0' preserveAspectRatio='"+(l?"none":"contain"===o?"xMidYMid":"cover"===o?"xMidYMid slice":"none")+"' style='filter: url(%23b);' href='"+s+"'/%3E%3C/svg%3E"}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"getImageBlurSvg",{enumerable:!0,get:function(){return r}})},35666:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{default:function(){return u},getImageProps:function(){return a}});let n=r(38754),i=r(17367),s=r(26541),o=n._(r(56663));function a(e){let{props:t}=(0,i.getImgProps)(e,{defaultLoader:o.default,imgConf:{deviceSizes:[640,750,828,1080,1200,1920,2048,3840],imageSizes:[16,32,48,64,96,128,256,384],path:"/_next/image",loader:"default",dangerouslyAllowSVG:!1,unoptimized:!1}});for(let[e,r]of Object.entries(t))void 0===r&&delete t[e];return{props:t}}let u=s.Image},56663:function(e,t){"use strict";function r(e){let{config:t,src:r,width:n,quality:i}=e;return t.path+"?url="+encodeURIComponent(r)+"&w="+n+"&q="+(i||75)}Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"default",{enumerable:!0,get:function(){return n}}),r.__next_img_default=!0;let n=r},23617:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{ServerInsertedHTMLContext:function(){return i},useServerInsertedHTML:function(){return s}});let n=r(61757)._(r(67294)),i=n.default.createContext(null);function s(e){let t=(0,n.useContext)(i);t&&t(e)}},51502:function(e,t,r){"use strict";r.d(t,{Ph:function(){return c},cT:function(){return l}});var n=r(85893),i=r(86010),s=r(64362),o=r(39202),a=r(41664),u=r.n(a);let l={SOLID_BLUE:"button--solid-blue",SOLID_BLUE_LIGHT:"button--solid-blue-light",SOLID_BLACK:"button--solid-black",SOLID_BLACK_OUTLINE:"button--solid-black-outline",SOLID_WHITE_OUTLINE:"button--solid-white-outline",SOLID_WHITE:"button--solid-white",SOLID_WHITE_TEXT_ONLY:"button--solid-white-text-only",SOLID_BLACK_TEXT_ONLY:"button--solid-black-text-only",TRANSLUCENT:"button--translucent",SOLID_RED:"button--solid-red",SOLID_GREY_PILL:"button--solid-grey-pill"},c={XXS:"button--xxs",XS:"button--xs",SM:"button--sm",BASE:"button--base",LG:"button--lg"};t.ZP=e=>{let{variant:t=l.SOLID_WHITE,size:r=c.BASE,padding:a,className:d,href:f,isTargetBlank:h=!1,type:p,Icon:m,onClick:g,disabled:y=!1,isLoading:v=!1,dataCy:_,tooltip:b,children:S}=e,E=(0,i.Z)("button",t,r,a,d);return f?(0,n.jsxs)(u(),{href:null!=f?f:"",className:E,...(0,o.Z)(_),target:h?"_blank":"_self",rel:h?"noopener noreferrer":"",title:b,children:[m&&(0,n.jsx)(m,{className:"button__icon"}),S]}):(0,n.jsx)("button",{className:E,type:p,onClick:g,disabled:y||v,...(0,o.Z)(_),title:b,children:(0,n.jsxs)(n.Fragment,{children:[v&&(0,n.jsx)(s.Z,{}),m&&(0,n.jsx)(m,{className:"button__icon"}),S]})})}},25477:function(e,t,r){"use strict";var n=r(85893),i=r(86010),s=r(50058);t.Z=e=>{let{size:t=s.o.H1,element:r=s.o.H1,className:o,children:a}=e,u=(0,i.Z)("heading",{["heading--".concat(t)]:t},o);return(0,n.jsx)(r,{className:u,children:a})}},50058:function(e,t,r){"use strict";var n,i;r.d(t,{o:function(){return n}}),(i=n||(n={})).H1="h1",i.H2="h2",i.H3="h3",i.H4="h4",i.H5="h5"},64362:function(e,t,r){"use strict";var n=r(85893),i=r(86010);t.Z=e=>{let{text:t,isLarge:r,color1:s="currentColor",color2:o="#1C64F2"}=e,a=(0,i.Z)("loading-spinner",{"loading-spinner--large":r});return(0,n.jsxs)("div",{className:a,children:[(0,n.jsxs)("svg",{role:"status",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:[(0,n.jsx)("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:s}),(0,n.jsx)("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:o})]}),t&&(0,n.jsx)("span",{children:t})]})}},28953:function(e,t,r){"use strict";var n=r(85893),i=r(25675),s=r.n(i);t.Z=e=>{let{isWhite:t=!1}=e;return(0,n.jsx)(s(),{priority:!0,src:"/app/images/loci-logo-".concat(t?"white":"black",".png"),alt:"Loci logo",width:105,height:35,quality:100})}},67748:function(e,t,r){"use strict";r.d(t,{cj:function(){return n},q2:function(){return i}});let n=50,i={createOrganization:{formButtonSubmit:"Create workspace",title:"Create workspace"},organizationSwitcher:{action__createOrganization:"Create workspace",notSelected:"No workspace selected"},organizationList:{action__createOrganization:"Create workspace",createOrganization:"Create workspace",titleWithoutPersonal:"Choose a workspace"},profilePage:{dangerSection:{deleteOrganization:{messageLine1:"Are you sure you want to delete this workspace?",successMessage:"You have deleted the workspace.",title:"Delete workspace"},leaveOrganization:{messageLine1:"Are you sure you want to leave this workspace? You will lose access to this organization and its applications.",successMessage:"You have left the workspace.",title:"Leave workspace"}}},start:{profileSection:{title:"Workspace Profile"}}}},26486:function(e,t,r){"use strict";var n=r(67294);t.Z=(e,t)=>{let{data:r,isLoading:i,isError:s}=e,{setResults:o,setIsLoading:a,setIsError:u}=t();return(0,n.useEffect)(()=>{a(i),u(s),r&&o(r)},[o,a,u,i,s,r]),e}},76003:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return eL}});var n,i,s,o,a=r(85893),u=r(86501),l=r(56342);r(77798);var c=r(13500),d=r(4298),f=r.n(d),h=()=>{let e="G-QQS8KLL89Y";return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(f(),{id:"hotjar",strategy:"lazyOnload",children:'\n          (function(h,o,t,j,a,r){\n            h.hj=h.hj||function(){(h.hj.q=h.hj.q||[]).push(arguments)};\n            h._hjSettings={hjid:"'.concat("3340469","\",hjsv:6};\n            a=o.getElementsByTagName('head')[0];\n            r=o.createElement('script');r.async=1;\n            r.src=t+h._hjSettings.hjid+j+h._hjSettings.hjsv;\n            a.appendChild(r);\n          })(window,document,'https://static.hotjar.com/c/hotjar-','.js?sv=');\n      ")},"hotjar"),(0,a.jsx)(f(),{src:"https://www.googletagmanager.com/gtag/js?id=".concat(e),strategy:"afterInteractive"}),(0,a.jsx)(f(),{id:"google-analytics",strategy:"afterInteractive",children:"\n          window.dataLayer = window.dataLayer || [];\n          function gtag(){dataLayer.push(arguments);}\n          gtag('js', new Date());\n        \n          gtag('config', '".concat(e,"');\n          ")},"google-analytics")]})},p=r(9008),m=r.n(p),g=()=>(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(m(),{children:(0,a.jsx)("title",{children:"Loci"},"title")}),(0,a.jsx)(h,{})]}),y=r(32358),v=r(51502),_=r(25477),b=r(11163),S=r.n(b),E=e=>{let{resetError:t}=e;return(0,a.jsx)("div",{className:"error-fallback",children:(0,a.jsxs)("div",{className:"error-fallback__box",children:[(0,a.jsx)(_.Z,{children:"Application Error"}),(0,a.jsx)("p",{className:"error-fallback__box__text",children:"We're sorry, the Loci app has encountered an error. Please try again, or contact support if the problem persists."}),(0,a.jsx)("div",{className:"error-fallback__box__cta",children:(0,a.jsx)(v.ZP,{variant:v.cT.SOLID_BLACK,onClick:()=>{t(),S().push(y.y.ROOT)},children:"Go back to Homepage"})})]})})},w=r(86010),O=r(23493),k=r.n(O),T=r(67294);(n=s||(s={})).EXACT="exact",n.STARTS_WITH="startsWith";let C=[{path:"".concat(y.y.TERMS,"/"),type:"startsWith"},{path:y.y.JOBS,type:"exact"},{path:"".concat(y.y.JOBS,"/[jobId]"),type:"exact"},{path:y.y.README_LOGIN,type:"exact"},{path:"".concat(y.y.STUDIO,"/"),type:"startsWith"},{path:"".concat(y.y.ONBOARDING),type:"startsWith"},{path:"".concat(y.y.SIGN_UP),type:"startsWith"},{path:"".concat(y.y.SIGN_IN),type:"startsWith"}];var I=e=>C.some(t=>{let{path:r,type:n}=t;switch(n){case"exact":return r===e;case"startsWith":return e.startsWith(r);default:return!1}});(i=o||(o={}))[i.DashboardRoot=y.y.STUDIO]="DashboardRoot",i[i.Dashboard=y.y.STUDIO_DASHBOARD]="Dashboard",i[i.Home=y.y.ROOT]="Home",i[i.Playground=y.y.PLAYGROUND_TAG]="Playground",i[i.Careers=y.y.JOBS]="Careers",i[i.Docs=y.y.README_LOGIN]="Docs",i[i.WebOptimizer=y.y.WEB_OPTIMIZER]="WebOptimizer",i[i.Settings=y.y.STUDIO_SETTINGS]="Settings",i[i.Search=y.y.SEARCH]="Search",i[i.Blog=y.sI.BLOG]="Blog";var R=r(41451),x=r(94767);let A={HOME:{name:"Home",rootPath:o.Home,path:o.Home,dataCy:R.ZP.HEADER.DASHBOARD_BUTTON},DASHBOARD:{name:"Dashboard",rootPath:o.Dashboard,path:o.Dashboard,dataCy:R.ZP.HEADER.DASHBOARD_BUTTON},DOCUMENTATION:{name:"Documentation",rootPath:x.xZ.NEXT_PUBLIC_README_URL,path:x.xZ.NEXT_PUBLIC_README_URL},SETTINGS:{name:"Settings",rootPath:o.Settings,path:o.Settings,dataCy:R.ZP.HEADER.SETTINGS_BUTTON},PLAYGROUND:{name:"Playground",rootPath:o.Playground,path:o.Playground,dataCy:R.ZP.HEADER.PLAYGROUND_BUTTON},WEB_OPTIMIZER:{name:"Asset Optimizer",rootPath:o.WebOptimizer,path:o.WebOptimizer,dataCy:R.ZP.HEADER.WEB_OPTIMIZER_BUTTON},CAREERS:{name:"Careers",rootPath:o.Careers,path:o.Careers},BLOG:{name:"Blog",rootPath:o.Blog,path:o.Blog,isExternal:!0}};var P=(e,t)=>!0===(t&&e)?[A.DASHBOARD,A.PLAYGROUND,A.SETTINGS]:[A.DOCUMENTATION,A.PLAYGROUND,A.WEB_OPTIMIZER,A.CAREERS,A.BLOG],M=r(44400),N=r(45007),D=r(41664),L=r.n(D),j=e=>{let{name:t,options:r}=e;return(0,a.jsxs)(M.v,{as:"div",className:"universal-header__dropdown-menu",children:[(0,a.jsx)("div",{children:(0,a.jsx)(M.v.Button,{className:"universal-header__menu__nav",children:t})}),(0,a.jsx)(N.u,{as:T.Fragment,unmount:!1,enter:"transition ease-out duration-100",enterFrom:"transform opacity-0 scale-95",enterTo:"transform opacity-100 scale-100",leave:"transition ease-in duration-75",leaveFrom:"transform opacity-100 scale-100",leaveTo:"transform opacity-0 scale-95",children:(0,a.jsx)(M.v.Items,{className:"universal-header__dropdown-menu__items",unmount:!1,children:r.map((e,t)=>{let{path:n,name:i,description:s}=e;return(0,a.jsx)(M.v.Item,{disabled:!n,children:e=>{let{active:o}=e,u=!!n,l=t===r.length-1,c=(0,w.Z)("universal-header__dropdown-menu__items__item",{"universal-header__dropdown-menu__items__item--active":o&&n,"universal-header__dropdown-menu__items__item--inactive":!o&&n,"universal-header__dropdown-menu__items__item--coming-soon":!u,"universal-header__dropdown-menu__items__item--top":0===t,"universal-header__dropdown-menu__items__item--bottom":l});return(0,a.jsxs)(L(),{href:n||"#",className:c,"aria-disabled":!n,children:[(0,a.jsx)("span",{children:i}),!n&&(0,a.jsx)("span",{className:"universal-header__dropdown-menu__items__item__coming-soon",children:"(COMING SOON)"}),(0,a.jsx)("p",{className:"universal-header__dropdown-menu__items__item__description",children:s})]})}},t)})})})]})},U=r(39202);let B=T.forwardRef(function(e,t){let{title:r,titleId:n,...i}=e;return T.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":n},i),r?T.createElement("title",{id:n},r):null,T.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M2.036 12.322a1.012 1.012 0 0 1 0-.639C3.423 7.51 7.36 4.5 12 4.5c4.638 0 8.573 3.007 9.963 7.178.07.207.07.431 0 .639C20.577 16.49 16.64 19.5 12 19.5c-4.638 0-8.573-3.007-9.963-7.178Z"}),T.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15 12a3 3 0 1 1-6 0 3 3 0 0 1 6 0Z"}))});var F=r(27880),$=e=>{let{onClose:t,apiKey:r}=e,[n,i]=(0,T.useState)(!1),s=n?r:"•".repeat(r.length),o=(0,T.useRef)(null),l=(0,T.useCallback)(()=>{navigator.clipboard.writeText(r).then(()=>{u.ZP.success("Api key copied to clipboard"),t()}).catch(()=>u.ZP.error("Failed to copy Api key"))},[r,t]),c=(0,T.useCallback)(()=>{i(e=>!e)},[]),d=(0,T.useCallback)(e=>{e.target instanceof Element&&o.current&&!o.current.contains(e.target)&&t()},[t]);return(0,T.useEffect)(()=>(document.addEventListener("mousedown",d),()=>{document.removeEventListener("mousedown",d)}),[d]),(0,a.jsx)("div",{ref:o,className:"universal-header__api-key",...(0,U.Z)(R.ZP.API_DETAILS.API_KEY.$ELEMENT),children:(0,a.jsxs)("div",{className:"universal-header__api-key__button-container",children:[(0,a.jsx)("input",{...(0,U.Z)(R.ZP.API_DETAILS.API_KEY.INPUT),type:"text",size:r.length,readOnly:!0,value:s,className:"universal-header__api-key__input"}),(0,a.jsx)(v.ZP,{dataCy:R.ZP.API_DETAILS.API_KEY.VIEW_KEY,size:v.Ph.SM,variant:v.cT.SOLID_WHITE,onClick:c,children:(0,a.jsx)(B,{className:"universal-header__api-key__icon"})}),(0,a.jsx)(v.ZP,{size:v.Ph.SM,variant:v.cT.SOLID_BLACK,onClick:l,children:(0,a.jsx)(F.Z,{className:"universal-header__api-key__icon"})})]})})},z=r(76599),H=()=>(0,a.jsx)("div",{...(0,U.Z)(R.ZP.HEADER.USER_SETTINGS.$ELEMENT),className:"universal-header__user-settings",children:(0,a.jsx)(z.l8,{})}),G=r(62996),q=r(49881),Z=e=>{let{isInStudio:t,handleDashboardClick:r,isRedirectingToDashboard:n,apiKey:i,isInverted:s}=e,[o,u]=(0,T.useState)(!1),{isTest:l}=(0,G.Z)(),{organization:c}=(0,z.o8)(),d=i&&o;return(0,T.useEffect)(()=>{l||u(!1)},[S().asPath]),t?(0,a.jsxs)(a.Fragment,{children:[d&&(0,a.jsx)($,{onClose:()=>{u(!1)},apiKey:i}),(0,a.jsxs)("div",{className:"universal-header__right__buttons",children:[!!c&&(0,a.jsx)(v.ZP,{dataCy:R.ZP.HEADER.API_BUTTON,onClick:()=>{u(e=>!e)},className:"universal-header__right__buttons__button",children:"API Key"}),(0,a.jsxs)(v.ZP,{onClick:()=>{window.open(y.y.README_LOGIN,"_blank")},variant:v.cT.SOLID_BLACK_TEXT_ONLY,children:["Documentation",(0,a.jsx)(q.Z,{className:"universal-header__right__buttons__icon"})]})]}),(0,a.jsx)(H,{})]}):(0,a.jsx)(v.ZP,{isLoading:n,size:v.Ph.SM,variant:s?v.cT.SOLID_BLACK:v.cT.SOLID_WHITE_OUTLINE,onClick:r,children:"Dashboard"})},W=r(66202),K=e=>{let{href:t,rootPath:r,children:n,dataCy:i,onClick:s}=e,{pagePathname:u}=(0,W.Z)(),l=r===o.Home&&"/"===u,c=r!==o.Home&&u.startsWith(r),d=(0,w.Z)("universal-header__menu__nav",{"universal-header__menu__nav--active":l||c});return(0,a.jsx)(L(),{...(0,U.Z)(i),href:null!=t?t:"",className:d,onClick:s,children:n})},V=r(50083),Q=e=>{let{links:t,toggleMobileMenu:r}=e;return(0,a.jsxs)("div",{className:"mobile-menu-overlay",children:[(0,a.jsx)("div",{className:"mobile-menu-overlay__close",children:(0,a.jsx)(V.Z,{onClick:r,className:"mobile-menu-overlay__close__icon"})}),t.map(e=>{let{dataCy:t,path:n,rootPath:i,name:s,icon:o}=e;return(0,a.jsxs)(K,{dataCy:t,href:n,rootPath:i,onClick:r,children:[s," ",o&&o]},n)})]})},X=r(28953),J=r(88303),Y=r(11776);let ee=T.forwardRef(function(e,t){let{title:r,titleId:n,...i}=e;return T.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":n},i),r?T.createElement("title",{id:n},r):null,T.createElement("path",{fillRule:"evenodd",d:"M3 6.75A.75.75 0 0 1 3.75 6h16.5a.75.75 0 0 1 0 1.5H3.75A.75.75 0 0 1 3 6.75ZM3 12a.75.75 0 0 1 .75-.75h16.5a.75.75 0 0 1 0 1.5H3.75A.75.75 0 0 1 3 12Zm0 5.25a.75.75 0 0 1 .75-.75h16.5a.75.75 0 0 1 0 1.5H3.75a.75.75 0 0 1-.75-.75Z",clipRule:"evenodd"}))}),et=[{name:"Auto Tag",description:"Power search",path:y.y.PRODUCTS_AUTO_TAG},{name:"Auto Categorize",description:"Power filters",path:y.y.PRODUCTS_AUTO_CATEGORIZE},{name:"Auto Extract",description:"Power sorting",path:y.y.PRODUCTS_AUTO_EXTRACT},{name:"Auto Caption",description:"Power datasets for Gen-AI",path:y.y.PRODUCTS_AUTO_CAPTION},{name:"Similarity Search",description:"Clean up your asset catalog",path:y.y.PRODUCTS_FIND_SIMILAR},{name:"Embeddings",description:"Embeddings, on demand.",path:y.y.PRODUCTS_EMBEDDINGS}],er=[{name:"AECO",description:"The intelligence layer for the built environment",path:y.y.SOLUTIONS_AECO},{name:"Studios",description:"Power search, procedural generation, and generative AI",path:y.y.SOLUTIONS_STUDIOS},{name:"DAMs",description:"Equipping DAMs for the age of 3D",path:y.y.SOLUTIONS_DAMS}];var en=()=>{let[e,t]=(0,T.useState)(!1),[r,n]=(0,T.useState)(!1),[i,s]=(0,T.useState)(!1),o=(0,T.useRef)(null),u=(0,b.useRouter)(),{user:l,isSignedIn:c=!1}=(0,z.aF)(),d=(0,J.Z)(e=>{var t;return null===(t=e.results)||void 0===t?void 0:t.key}),{pagePathname:f}=(0,W.Z)(),h=u.pathname===y.y.ROOT,p=f.startsWith(y.y.STUDIO),m=(0,T.useMemo)(()=>I(f),[f]),g=h&&!e,_=(0,T.useMemo)(()=>P(c,p),[c,p]),S=p&&c,E=(0,w.Z)("universal-header",{"universal-header--padded":g,"universal-header--inverted":m,"universal-header--scrolled":e}),O=()=>n(e=>!e),C=k()(()=>{o.current&&t(window.scrollY>=o.current.getBoundingClientRect().bottom)},500);(0,T.useEffect)(()=>(window.addEventListener("scroll",C),()=>{window.removeEventListener("scroll",C),u.events.off("routeChangeComplete",x),s(!1)}),[]);let x=()=>{s(!1),u.events.off("routeChangeComplete",x)};return(0,a.jsxs)("header",{className:E,ref:o,children:[(0,a.jsxs)("div",{className:"universal-header__left__container",children:[(0,a.jsx)(L(),{href:y.y.ROOT,className:"universal-header__logo",children:(0,a.jsx)(X.Z,{isWhite:!m})}),(0,a.jsx)("div",{className:"universal-header__clerk-org-switcher-container",children:S&&(0,a.jsx)(z.Li,{hidePersonal:!0,createOrganizationUrl:y.y.CREATE_WORKSPACE,createOrganizationMode:"navigation"})})]}),(0,a.jsxs)("nav",{className:"universal-header__menu",children:[!p&&(0,a.jsx)(j,{name:"Products",options:et}),!p&&(0,a.jsx)(j,{name:"Solutions",options:er}),_.map(e=>{if(!e)return null;let{dataCy:t,path:r,rootPath:n,name:i,icon:s,isExternal:o}=e;return(0,a.jsxs)(K,{dataCy:t,href:r,rootPath:n,children:[i," ",s&&s," ",o&&(0,a.jsx)(Y.Z,{className:"universal-header__menu__icon"})]},r)}),e&&!c&&(0,a.jsx)(v.ZP,{variant:m?v.cT.SOLID_BLACK:v.cT.SOLID_WHITE_OUTLINE,href:y.y.SIGN_UP,dataCy:R.ZP.HEADER.SIGNUP_BUTTON,children:"Sign up"})]}),(0,a.jsxs)("div",{className:"universal-header__right",children:[l?(0,a.jsx)(Z,{isInStudio:p,apiKey:d,handleDashboardClick:()=>{s(!0),u.push(y.y.STUDIO_DASHBOARD),u.events.on("routeChangeComplete",x)},isRedirectingToDashboard:i,isInverted:m}):(0,a.jsxs)("div",{className:"universal-header__cta",children:[(0,a.jsx)(v.ZP,{variant:m?v.cT.SOLID_BLACK_TEXT_ONLY:v.cT.SOLID_WHITE_TEXT_ONLY,dataCy:R.ZP.HEADER.LOGIN_BUTTON,href:y.y.SIGN_IN,children:"Sign in"}),(0,a.jsx)("div",{className:"universal-header__cta__sign-up-container",children:(0,a.jsx)(v.ZP,{href:y.y.SIGN_UP,variant:m?v.cT.SOLID_BLACK:v.cT.SOLID_WHITE_OUTLINE,dataCy:R.ZP.HEADER.SIGNUP_BUTTON,children:"Sign up"})})]}),(0,a.jsx)("div",{className:"universal-header__hamburger",onClick:O,children:(0,a.jsx)(ee,{className:"universal-header__hamburger__icon"})})]}),r&&(0,a.jsx)(Q,{links:_,toggleMobileMenu:O})]})},ei=r(67748),es=()=>{let{setPageQuery:e,setPagePathname:t}=(0,W.Z)(),{query:r,pathname:n}=(0,b.useRouter)();(0,T.useEffect)(()=>{e(r),t(n)},[n,r,t,e])},eo=r(26486),ea=r(44343),eu=r(39332);let el="undefined"!=typeof window?T.useLayoutEffect:T.useEffect,ec=T.createContext(void 0);ec.displayName="ClerkNextOptionsCtx";let ed=()=>T.useContext(ec).value,ef=e=>{let{children:t,options:r}=e;return T.createElement(ec.Provider,{value:{value:r}},t)};var eh=r(77183);function ep(e){let{publishableKey:t,clerkJSUrl:r,clerkJSVersion:n,clerkJSVariant:i}=ed(),{domain:s,proxyUrl:o}=(0,z.ll)(),a={domain:s,proxyUrl:o,publishableKey:t,clerkJSUrl:r,clerkJSVersion:n,clerkJSVariant:i},u=(0,eh.wE)(a),l="app"===e.router?"script":f();return T.createElement(l,{src:u,"data-clerk-js-script":!0,async:!0,defer:"pages"!==e.router&&void 0,crossOrigin:"anonymous",strategy:"pages"===e.router?"beforeInteractive":void 0,...(0,eh.iv)(a)})}var em=r(12599);r(19731);var eg=e=>"undefined"!=typeof atob&&"function"==typeof atob?atob(e):"undefined"!=typeof global&&global.Buffer?new global.Buffer(e,"base64").toString():e,ey="pk_live_",ev=[".lcl.dev",".lclstage.dev",".lclclerk.com"],e_=[".lcl.dev","lclstage.dev",".lclclerk.com",".accounts.lclclerk.com"],eb=[".accountsstage.dev"],eS="https://api.clerk.com",eE=r(34155);eE.env.NEXT_PUBLIC_CLERK_JS_VERSION,eE.env.NEXT_PUBLIC_CLERK_JS_URL,eE.env.CLERK_API_VERSION,eE.env.CLERK_SECRET_KEY,eE.env.CLERK_ENCRYPTION_KEY,eE.env.CLERK_API_URL||(e=>{var t;let r=null==(t=function(e,t={}){if(!(e=e||"")||!function(e){let t=(e=e||"").startsWith(ey)||e.startsWith("pk_test_"),r=eg(e.split("_")[2]||"").endsWith("$");return t&&r}(e)){if(t.fatal)throw Error("Publishable key not valid.");return null}let r=e.startsWith(ey)?"production":"development",n=eg(e.split("_")[2]);return n=n.slice(0,-1),t.proxyUrl?n=t.proxyUrl:"development"!==r&&t.domain&&(n=`clerk.${t.domain}`),{instanceType:r,frontendApi:n}}(e))?void 0:t.frontendApi;return(null==r?void 0:r.startsWith("clerk."))&&ev.some(e=>null==r?void 0:r.endsWith(e))?eS:e_.some(e=>null==r?void 0:r.endsWith(e))?"https://api.lclclerk.com":eb.some(e=>null==r?void 0:r.endsWith(e))?"https://api.clerkstage.dev":eS})("pk_live_Y2xlcmsubG9jaS5haSQ"),eE.env.NEXT_PUBLIC_CLERK_DOMAIN,eE.env.NEXT_PUBLIC_CLERK_PROXY_URL,(0,em.fQ)(eE.env.NEXT_PUBLIC_CLERK_IS_SATELLITE),eE.env.NEXT_PUBLIC_CLERK_SIGN_IN_URL,eE.env.NEXT_PUBLIC_CLERK_SIGN_UP_URL;let ew={name:"@clerk/nextjs",version:"5.2.2",environment:"production"};(0,em.fQ)(eE.env.NEXT_PUBLIC_CLERK_TELEMETRY_DISABLED),(0,em.fQ)(eE.env.NEXT_PUBLIC_CLERK_TELEMETRY_DEBUG);var eO=r(34155);let ek=e=>{var t;return{...e,publishableKey:e.publishableKey||"pk_live_Y2xlcmsubG9jaS5haSQ",clerkJSUrl:e.clerkJSUrl||eO.env.NEXT_PUBLIC_CLERK_JS_URL,clerkJSVersion:e.clerkJSVersion||eO.env.NEXT_PUBLIC_CLERK_JS_VERSION,proxyUrl:e.proxyUrl||eO.env.NEXT_PUBLIC_CLERK_PROXY_URL||"",domain:e.domain||eO.env.NEXT_PUBLIC_CLERK_DOMAIN||"",isSatellite:e.isSatellite||(0,em.fQ)(eO.env.NEXT_PUBLIC_CLERK_IS_SATELLITE),signInUrl:e.signInUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_IN_URL||"",signUpUrl:e.signUpUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_UP_URL||"",signInForceRedirectUrl:e.signInForceRedirectUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_IN_FORCE_REDIRECT_URL||"",signUpForceRedirectUrl:e.signUpForceRedirectUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_UP_FORCE_REDIRECT_URL||"",signInFallbackRedirectUrl:e.signInFallbackRedirectUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_IN_FALLBACK_REDIRECT_URL||"",signUpFallbackRedirectUrl:e.signUpFallbackRedirectUrl||eO.env.NEXT_PUBLIC_CLERK_SIGN_UP_FALLBACK_REDIRECT_URL||"",afterSignInUrl:e.afterSignInUrl||eO.env.NEXT_PUBLIC_CLERK_AFTER_SIGN_IN_URL||"",afterSignUpUrl:e.afterSignUpUrl||eO.env.NEXT_PUBLIC_CLERK_AFTER_SIGN_UP_URL||"",telemetry:null!=(t=e.telemetry)?t:{disabled:(0,em.fQ)(eO.env.NEXT_PUBLIC_CLERK_TELEMETRY_DISABLED),debug:(0,em.fQ)(eO.env.NEXT_PUBLIC_CLERK_TELEMETRY_DEBUG)},sdkMetadata:ew}};var eT=r(14970);async function eC(){return(0,eT.cookies)().delete(`__clerk_invalidate_cache_cookie_${Date.now()}`)}let eI=e=>{var t;return null!=window.__clerk_internal_navigations||(window.__clerk_internal_navigations={}),null!=(t=window.__clerk_internal_navigations)[e]||(t[e]={}),window.__clerk_internal_navigations[e]},eR=e=>{let{windowNav:t,routerNav:r,name:n}=e,i=(0,eu.usePathname)(),[s,o]=(0,T.useTransition)();t&&(eI(n).fun=(e,i)=>new Promise(s=>{var a,u;null!=(a=eI(n)).promisesBuffer||(a.promisesBuffer=[]),null==(u=eI(n).promisesBuffer)||u.push(s),o(()=>{var n,s,o;(null==(n=null==i?void 0:i.__internal_metadata)?void 0:n.navigationType)==="internal"?t((null!=(o=null==(s=window.next)?void 0:s.version)?o:"")<"14.1.0"?history.state:null,"",e):r(e)})}));let a=()=>{var e;null==(e=eI(n).promisesBuffer)||e.forEach(e=>e()),eI(n).promisesBuffer=[]};return(0,T.useEffect)(()=>(a(),a),[]),(0,T.useEffect)(()=>{s||a()},[i,s]),(0,T.useCallback)(e=>eI(n).fun(e),[])},ex=()=>{let e=(0,eu.useRouter)();return eR({windowNav:"undefined"!=typeof window?window.history.pushState.bind(window.history):void 0,routerNav:e.push.bind(e),name:"push"})},eA=()=>{let e=(0,eu.useRouter)();return eR({windowNav:"undefined"!=typeof window?window.history.replaceState.bind(window.history):void 0,routerNav:e.replace.bind(e),name:"replace"})},eP=e=>{let{__unstable_invokeMiddlewareOnAuthStateChange:t=!0,children:r}=e,n=(0,eu.useRouter)(),i=ex(),s=eA(),[o,a]=(0,T.useTransition)();(0,T.useEffect)(()=>{var e;o||null==(e=window.__clerk_internal_invalidateCachePromise)||e.call(window)},[o]),el(()=>{window.__unstable__onBeforeSetActive=()=>new Promise(e=>{window.__clerk_internal_invalidateCachePromise=e,a(()=>{var e;(null==(e=window.next)?void 0:e.version)&&"string"==typeof window.next.version&&window.next.version.startsWith("13")?n.refresh():eC()})}),window.__unstable__onAfterSetActive=()=>{if(t)return n.refresh()}},[]);let u=ek({...e,routerPush:i,routerReplace:s});return T.createElement(ef,{options:u},T.createElement(z.El,{...u},T.createElement(ep,{router:"app"}),r))},eM=()=>{if("undefined"==typeof window)return;let e=e=>{Object.keys(e).forEach(t=>{delete e[t]})};try{e(window.next.router.sdc),e(window.next.router.sbc)}catch(e){return}};function eN({children:e,...t}){var r;let{__unstable_invokeMiddlewareOnAuthStateChange:n=!0}=t,{push:i,replace:s}=(0,b.useRouter)();z.El.displayName="ReactClerkProvider",el(()=>{window.__unstable__onBeforeSetActive=eM},[]),el(()=>{window.__unstable__onAfterSetActive=()=>{n&&i(window.location.href)}},[]);let o=ek({...t,routerPush:e=>i(e),routerReplace:e=>s(e)}),a=(null==(r=t.authServerSideProps)?void 0:r.__clerk_ssr_state)||t.__clerk_ssr_state;return T.createElement(ef,{options:o},T.createElement(z.El,{...o,initialState:a},T.createElement(ep,{router:"pages"}),e))}(0,eh.JM)({packageName:"@clerk/nextjs"});let eD=function(e){let t=(0,ea.useRouter)();return T.createElement(t?eN:eP,{...e})};z.CH,z.tj,z.Cv,r(30462);var eL=c.d.withTRPC(e=>{let{Component:t,pageProps:{...r}}=e,{isDev:n,isStaging:i}=(0,G.Z)();return(0,eo.Z)(c.d.apiKey.getApiKey.useQuery(),J.Z),es(),(0,a.jsxs)(l.SV,{fallback:e=>{let{resetError:t}=e;return(0,a.jsx)(E,{resetError:t})},showDialog:n||i,children:[(0,a.jsx)(g,{}),(0,a.jsxs)(eD,{localization:ei.q2,publishableKey:x.xZ.NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY,children:[(0,a.jsx)(u.x7,{}),(0,a.jsx)(en,{}),(0,a.jsx)(t,{...r})]})]})})},88303:function(e,t,r){"use strict";var n=r(12902),i=r(64529),s=r(782);let o={results:null},a=(0,i.Ue)()((0,s.mW)(e=>({...o,setResults:t=>{e({results:t})},isError:!1,setIsError:t=>e((0,n.ZP)(e=>{e.isError=t})),isLoading:!1,setIsLoading:t=>e((0,n.ZP)(e=>{e.isLoading=t})),reset:()=>e(o)}),{name:"api-store"}));t.Z=a},66202:function(e,t,r){"use strict";var n=r(12902),i=r(64529),s=r(782);let o=(0,i.Ue)()((0,s.mW)(e=>({pagePathname:"",pageQuery:{},setPageQuery:t=>e((0,n.ZP)(e=>{e.pageQuery=t})),setPagePathname:t=>e((0,n.ZP)(e=>{e.pagePathname=t}))}),{name:"page-store"}));t.Z=o},32358:function(e,t,r){"use strict";var n,i,s,o,a,u,l,c,d,f,h,p,m,g,y,v,_,b,S,E,w,O,k,T;r.d(t,{Cf:function(){return n},Gr:function(){return a},JV:function(){return h},MG:function(){return i},c_:function(){return s},hG:function(){return p},mN:function(){return l},nV:function(){return d},sI:function(){return c},uG:function(){return f},y:function(){return u}}),(m=n||(n={})).LOCAL="local",m.DEVELOPMENT="development",m.TEST="test",m.PRODUCTION="production",m.STAGING="staging",(g=i||(i={})).LOCAL="local",g.DEVELOPMENT="dev",g.TEST="test",g.PRODUCTION="prod",g.STAGING="staging",(y=s||(s={})).TEN="10",y.TWENTY="20",y.THIRTY="30",y.FOURTY="40",y.FIFTY="50",(v=o||(o={})).USER_CREATED="user.created",v.ORGANIZATION_CREATED="organization.created",(_=a||(a={})).JACK="jack@loci.ai",_.SUPPORT="info@loci.ai",(b=u||(u={})).NO_REDIRECT="",b.ROOT="/",b.README_LOGIN="/readme-login",b.README_QUICKSTART_LOGIN="/readme-login?quickstart=true",b.README_SUPPORTED_FORMATS_LOGIN="/readme-login?supportedFormats=true",b.README_API_REFERENCE_LOGIN="/readme-login?apiReference=true",b.PLAYGROUND_TAG="/playground/tag",b.STUDIO="/studio",b.STUDIO_DASHBOARD="/studio/dashboard",b.STUDIO_SETTINGS="/studio/settings",b.TERMS="/terms",b.TERMS_TERMS_AND_CONDITIONS="/terms/terms-and-conditions-v2",b.TERMS_PRIVACY_POLICY="/terms/privacy-policy",b.TERMS_SERVICE_LEVEL_OBJECTIVE="/terms/service-level-objective",b.TERMS_DATA_USAGE_POLICY="/terms/data-usage-policy",b.JOBS="/jobs",b.PRODUCTS_AUTO_TAG="/products/auto-tag",b.PRODUCTS_AUTO_CATEGORIZE="/products/auto-categorize",b.PRODUCTS_AUTO_EXTRACT="/products/auto-extract",b.PRODUCTS_AUTO_CAPTION="/products/auto-caption",b.PRODUCTS_FIND_SIMILAR="/products/find-similar",b.PRODUCTS_EMBEDDINGS="/products/embeddings",b.SOLUTIONS_AECO="/solutions/aeco",b.SOLUTIONS_DAMS="/solutions/digital-asset-management",b.SOLUTIONS_STUDIOS="/solutions/studios",b.VIEWER="/viewer",b.WEB_OPTIMIZER="/optimizer",b.ONBOARDING="/onboarding",b.SIGN_UP="/sign-up",b.SIGN_IN="/sign-in",b.CREATE_WORKSPACE="/studio/create-workspace",b.GRADE="/studio/grade",b.SEARCH="/studio/search",(S=l||(l={})).ROOT="https://docs.loci.ai",S.LIMITS_LIMITATIONS="https://docs.loci.ai/docs/limits-limitations",S.QUICKSTART="https://docs.loci.ai/docs/quickstart",S.API_REFERENCE="https://docs.loci.ai/reference",S.OUR_EDGE="https://docs.loci.ai/docs/our-edge",(E=c||(c={})).SKETCHFAB_DEMO_COLLECTION="https://sketchfab.com/alexloci/collections/random-asset-collection-1dd5cc18b3994de5a823a1649ef26076",E.BLOG="https://medium.com/@loci.ai/",(w=d||(d={})).IDLE="idle",w.LOADING="loading",w.SUCCESS="success",w.ERROR="error",(O=f||(f={})).SPLASH="SPLASH",O.PRODUCT="PRODUCT",O.OUR_EDGE="OUR_EDGE",O.SUPPORTED_FORMATS="SUPPORTED_FORMATS",O.OUTPUTS="OUTPUTS",O.INTEGRATIONS="INTEGRATIONS",O.CTA="CTA",O.TECHNOLOGY="TECHNOLOGY",O.TAXONOMIES="TAXONOMIES",(k=h||(h={})).SPLASH="SPLASH",k.PROBLEM="PROBLEM",k.FEATURES="FEATURES",k.BENEFITS="BENEFITS",k.QUOTE="QUOTE",k.INTEGRATIONS="INTEGRATIONS",k.DEPLOYMENT="DEPLOYMENT",k.CTA="CTA",(T=p||(p={})).JAVASCRIPT="javascript",T.JSON="json"},62996:function(e,t,r){"use strict";var n=r(32358);t.Z=()=>{let e="production",t=e===n.Cf.LOCAL,r=e===n.Cf.TEST,i=e===n.Cf.DEVELOPMENT;return{isLocal:t,isTest:r,isDev:i,isProd:e===n.Cf.PRODUCTION,isStaging:e===n.Cf.STAGING}}},39202:function(e,t,r){"use strict";var n=r(62996);t.Z=e=>{let{isTest:t}=(0,n.Z)();return t&&e?{"data-cy":e}:{}}},13500:function(e,t,r){"use strict";let n;r.d(t,{d:function(){return tL}});var i,s,o,a=function(){function e(){this.keyToValue=new Map,this.valueToKey=new Map}return e.prototype.set=function(e,t){this.keyToValue.set(e,t),this.valueToKey.set(t,e)},e.prototype.getByKey=function(e){return this.keyToValue.get(e)},e.prototype.getByValue=function(e){return this.valueToKey.get(e)},e.prototype.clear=function(){this.keyToValue.clear(),this.valueToKey.clear()},e}(),u=function(){function e(e){this.generateIdentifier=e,this.kv=new a}return e.prototype.register=function(e,t){this.kv.getByValue(e)||(t||(t=this.generateIdentifier(e)),this.kv.set(t,e))},e.prototype.clear=function(){this.kv.clear()},e.prototype.getIdentifier=function(e){return this.kv.getByValue(e)},e.prototype.getValue=function(e){return this.kv.getByKey(e)},e}(),l=(i=function(e,t){return(i=Object.setPrototypeOf||({__proto__:[]})instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r])})(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw TypeError("Class extends value "+String(t)+" is not a constructor or null");function r(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(r.prototype=t.prototype,new r)}),c=new(function(e){function t(){var t=e.call(this,function(e){return e.name})||this;return t.classToAllowedProps=new Map,t}return l(t,e),t.prototype.register=function(t,r){"object"==typeof r?(r.allowProps&&this.classToAllowedProps.set(t,r.allowProps),e.prototype.register.call(this,t,r.identifier)):e.prototype.register.call(this,t,r)},t.prototype.getAllowedProps=function(e){return this.classToAllowedProps.get(e)},t}(u)),d=new u(function(e){var t;return null!==(t=e.description)&&void 0!==t?t:""}),f=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,s=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=s.next()).done;)o.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return o};function h(e,t){Object.entries(e).forEach(function(e){var r=f(e,2),n=r[0];return t(r[1],n)})}function p(e,t){return -1!==e.indexOf(t)}function m(e,t){for(var r=0;r<e.length;r++){var n=e[r];if(t(n))return n}}var g={},y=function(e){g[e.name]=e},v=function(e){return function(e,t){var r=function(e){if("values"in Object)return Object.values(e);var t=[];for(var r in e)e.hasOwnProperty(r)&&t.push(e[r]);return t}(e);if("find"in r)return r.find(t);for(var n=0;n<r.length;n++){var i=r[n];if(t(i))return i}}(g,function(t){return t.isApplicable(e)})},_=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,s=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=s.next()).done;)o.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return o},b=function(e,t){for(var r=0,n=t.length,i=e.length;r<n;r++,i++)e[i]=t[r];return e},S=[],E=function(e){return Object.prototype.toString.call(e).slice(8,-1)},w=function(e){return void 0===e},O=function(e){return"Object"===E(e)&&(null===Object.getPrototypeOf(e)||e!==Object.prototype&&e.constructor===Object&&Object.getPrototypeOf(e)===Object.prototype)},k=function(e){return O(e)&&0===Object.keys(e).length},T=function(e){return Array.isArray(e)},C=function(e){return e instanceof Map},I=function(e){return e instanceof Set},R=function(e){return"Symbol"===E(e)},x=function(e){return"number"==typeof e&&isNaN(e)},A=function(e){return"boolean"==typeof e||null===e||w(e)||"number"==typeof e&&!isNaN(e)||"string"==typeof e||R(e)},P=function(e){return e.replace(/\./g,"\\.")},M=function(e){return e.map(String).map(P).join(".")},N=function(e){for(var t=[],r="",n=0;n<e.length;n++){var i=e.charAt(n);if("\\"===i&&"."===e.charAt(n+1)){r+=".",n++;continue}if("."===i){t.push(r),r="";continue}r+=i}var s=r;return t.push(s),t},D=function(){return(D=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},L=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,s=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=s.next()).done;)o.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return o},j=function(e,t){for(var r=0,n=t.length,i=e.length;r<n;r++,i++)e[i]=t[r];return e};function U(e,t,r,n){return{isApplicable:e,annotation:t,transform:r,untransform:n}}var B=[U(w,"undefined",function(){return null},function(){}),U(function(e){return"bigint"==typeof e},"bigint",function(e){return e.toString()},function(e){return"undefined"!=typeof BigInt?BigInt(e):(console.error("Please add a BigInt polyfill."),e)}),U(function(e){return e instanceof Date&&!isNaN(e.valueOf())},"Date",function(e){return e.toISOString()},function(e){return new Date(e)}),U(function(e){return e instanceof Error},"Error",function(e){var t={name:e.name,message:e.message};return S.forEach(function(r){t[r]=e[r]}),t},function(e){var t=Error(e.message);return t.name=e.name,t.stack=e.stack,S.forEach(function(r){t[r]=e[r]}),t}),U(function(e){return e instanceof RegExp},"regexp",function(e){return""+e},function(e){return new RegExp(e.slice(1,e.lastIndexOf("/")),e.slice(e.lastIndexOf("/")+1))}),U(I,"set",function(e){return j([],L(e.values()))},function(e){return new Set(e)}),U(C,"map",function(e){return j([],L(e.entries()))},function(e){return new Map(e)}),U(function(e){var t;return x(e)||(t=e)===1/0||t===-1/0},"number",function(e){return x(e)?"NaN":e>0?"Infinity":"-Infinity"},Number),U(function(e){return 0===e&&1/e==-1/0},"number",function(){return"-0"},Number)];function F(e,t,r,n){return{isApplicable:e,annotation:t,transform:r,untransform:n}}var $=F(function(e){return!!R(e)&&!!d.getIdentifier(e)},function(e){return["symbol",d.getIdentifier(e)]},function(e){return e.description},function(e,t){var r=d.getValue(t[1]);if(!r)throw Error("Trying to deserialize unknown symbol");return r}),z=[Int8Array,Uint8Array,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array,Uint8ClampedArray].reduce(function(e,t){return e[t.name]=t,e},{}),H=F(function(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)},function(e){return["typed-array",e.constructor.name]},function(e){return j([],L(e))},function(e,t){var r=z[t[1]];if(!r)throw Error("Trying to deserialize unknown typed array");return new r(e)});function G(e){return null!=e&&!!e.constructor&&!!c.getIdentifier(e.constructor)}var q=F(G,function(e){return["class",c.getIdentifier(e.constructor)]},function(e){var t=c.getAllowedProps(e.constructor);if(!t)return D({},e);var r={};return t.forEach(function(t){r[t]=e[t]}),r},function(e,t){var r=c.getValue(t[1]);if(!r)throw Error("Trying to deserialize unknown class - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564");return Object.assign(Object.create(r.prototype),e)}),Z=F(function(e){return!!v(e)},function(e){return["custom",v(e).name]},function(e){return v(e).serialize(e)},function(e,t){var r=g[t[1]];if(!r)throw Error("Trying to deserialize unknown custom value");return r.deserialize(e)}),W=[q,$,Z,H],K=function(e){var t=m(W,function(t){return t.isApplicable(e)});if(t)return{value:t.transform(e),type:t.annotation(e)};var r=m(B,function(t){return t.isApplicable(e)});if(r)return{value:r.transform(e),type:r.annotation}},V={};B.forEach(function(e){V[e.annotation]=e});var Q=function(e,t){if(T(t))switch(t[0]){case"symbol":return $.untransform(e,t);case"class":return q.untransform(e,t);case"custom":return Z.untransform(e,t);case"typed-array":return H.untransform(e,t);default:throw Error("Unknown transformation: "+t)}else{var r=V[t];if(!r)throw Error("Unknown transformation: "+t);return r.untransform(e)}},X=function(e,t){for(var r=e.keys();t>0;)r.next(),t--;return r.next().value};function J(e){if(p(e,"__proto__"))throw Error("__proto__ is not allowed as a property");if(p(e,"prototype"))throw Error("prototype is not allowed as a property");if(p(e,"constructor"))throw Error("constructor is not allowed as a property")}var Y=function(e,t,r){if(J(t),0===t.length)return r(e);for(var n=e,i=0;i<t.length-1;i++){var s=t[i];if(T(n))n=n[+s];else if(O(n))n=n[s];else if(I(n)){var o=+s;n=X(n,o)}else if(C(n)){if(i===t.length-2)break;var o=+s,a=0==+t[++i]?"key":"value",u=X(n,o);switch(a){case"key":n=u;break;case"value":n=n.get(u)}}}var l=t[t.length-1];if((T(n)||O(n))&&(n[l]=r(n[l])),I(n)){var c=X(n,+l),d=r(c);c!==d&&(n.delete(c),n.add(d))}if(C(n)){var o=+t[t.length-2],f=X(n,o),a=0==+l?"key":"value";switch(a){case"key":var h=r(f);n.set(h,n.get(f)),h!==f&&n.delete(f);break;case"value":n.set(f,r(n.get(f)))}}return e},ee=function(e,t){var r="function"==typeof Symbol&&e[Symbol.iterator];if(!r)return e;var n,i,s=r.call(e),o=[];try{for(;(void 0===t||t-- >0)&&!(n=s.next()).done;)o.push(n.value)}catch(e){i={error:e}}finally{try{n&&!n.done&&(r=s.return)&&r.call(s)}finally{if(i)throw i.error}}return o},et=function(e,t){for(var r=0,n=t.length,i=e.length;r<n;r++,i++)e[i]=t[r];return e},er=function(e,t,r,n){if(void 0===r&&(r=[]),void 0===n&&(n=[]),A(e)||(i=r,(s=t.get(e))?s.push(i):t.set(e,[i])),!(O(e)||T(e)||C(e)||I(e)||G(e))){var i,s,o,a=K(e);return a?{transformedValue:a.value,annotations:[a.type]}:{transformedValue:e}}if(p(n,e))return{transformedValue:null};var u=K(e),l=null!==(o=null==u?void 0:u.value)&&void 0!==o?o:e;A(e)||(n=et(et([],ee(n)),[e]));var c=T(l)?[]:{},d={};return(h(l,function(e,i){var s=er(e,t,et(et([],ee(r)),[i]),n);c[i]=s.transformedValue,T(s.annotations)?d[i]=s.annotations:O(s.annotations)&&h(s.annotations,function(e,t){d[P(i)+"."+t]=e})}),k(d))?{transformedValue:c,annotations:u?[u.type]:void 0}:{transformedValue:c,annotations:u?[u.type,d]:d}};function en(e){return Object.prototype.toString.call(e).slice(8,-1)}function ei(e){return"Array"===en(e)}s=function(e){return"Null"===en(e)},o=function(e){return"Undefined"===en(e)},e=>s(e)||o(e)||!1;var es=function(){return(es=Object.assign||function(e){for(var t,r=1,n=arguments.length;r<n;r++)for(var i in t=arguments[r])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)},eo=function(e){var t,r,n=new Map,i=er(e,n),s={json:i.transformedValue};i.annotations&&(s.meta=es(es({},s.meta),{values:i.annotations}));var o=(t={},r=void 0,(n.forEach(function(e){if(!(e.length<=1)){var n=ee(e.map(function(e){return e.map(String)}).sort(function(e,t){return e.length-t.length})),i=n[0],s=n.slice(1);0===i.length?r=s.map(M):t[M(i)]=s.map(M)}}),r)?k(t)?[r]:[r,t]:k(t)?void 0:t);return o&&(s.meta=es(es({},s.meta),{referentialEqualities:o})),s},ea=function(e){var t,r=e.json,n=e.meta,i=function e(t,r={}){return ei(t)?t.map(t=>e(t,r)):!function(e){if("Object"!==en(e))return!1;let t=Object.getPrototypeOf(e);return!!t&&t.constructor===Object&&t===Object.prototype}(t)?t:[...Object.getOwnPropertyNames(t),...Object.getOwnPropertySymbols(t)].reduce((n,i)=>{if(ei(r.props)&&!r.props.includes(i))return n;let s=e(t[i],r);return function(e,t,r,n,i){let s=({}).propertyIsEnumerable.call(n,t)?"enumerable":"nonenumerable";"enumerable"===s&&(e[t]=r),i&&"nonenumerable"===s&&Object.defineProperty(e,t,{value:r,enumerable:!1,writable:!0,configurable:!0})}(n,i,s,t,r.nonenumerable),n},{})}(r);return(null==n?void 0:n.values)&&(t=i,function e(t,r,n){if(void 0===n&&(n=[]),t){if(!T(t)){h(t,function(t,i){return e(t,r,et(et([],ee(n)),ee(N(i))))});return}var i=ee(t,2),s=i[0],o=i[1];o&&h(o,function(t,i){e(t,r,et(et([],ee(n)),ee(N(i))))}),r(s,n)}}(n.values,function(e,r){t=Y(t,r,function(t){return Q(t,e)})}),i=t),(null==n?void 0:n.referentialEqualities)&&(i=function(e,t){function r(t,r){var n,i,s=(n=e,J(i=N(r)),i.forEach(function(e){n=n[e]}),n);t.map(N).forEach(function(t){e=Y(e,t,function(){return s})})}if(T(t)){var n=ee(t,2),i=n[0],s=n[1];i.forEach(function(t){e=Y(e,N(t),function(){return e})}),s&&h(s,r)}else h(t,r);return e}(i,n.referentialEqualities)),i},eu={stringify:function(e){return JSON.stringify(eo(e))},parse:function(e){return ea(JSON.parse(e))},serialize:eo,deserialize:ea,registerClass:function(e,t){return c.register(e,t)},registerSymbol:function(e,t){return d.register(e,t)},registerCustom:function(e,t){return y(es({name:t},e))},allowErrorProps:function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];S.push.apply(S,b([],_(e)))}};function el(e){let t={subscribe(t){let r=null,n=!1,i=!1,s=!1;function o(){if(null===r){s=!0;return}!i&&(i=!0,"function"==typeof r?r():r&&r.unsubscribe())}return r=e({next(e){n||t.next?.(e)},error(e){n||(n=!0,t.error?.(e),o())},complete(){n||(n=!0,t.complete?.(),o())}}),s&&o(),{unsubscribe:o}},pipe:(...e)=>(0===e.length?function(e){return e}:1===e.length?e[0]:function(t){return e.reduce((e,t)=>t(e),t)})(t)};return t}class ec extends Error{constructor(e){super(e),this.name="ObservableAbortError",Object.setPrototypeOf(this,ec.prototype)}}function ed(e){let t=Object.create(null);for(let r in e)t[e[r]]=r;return t}let ef={PARSE_ERROR:-32700,BAD_REQUEST:-32600,INTERNAL_SERVER_ERROR:-32603,NOT_IMPLEMENTED:-32603,UNAUTHORIZED:-32001,FORBIDDEN:-32003,NOT_FOUND:-32004,METHOD_NOT_SUPPORTED:-32005,TIMEOUT:-32008,CONFLICT:-32009,PRECONDITION_FAILED:-32012,PAYLOAD_TOO_LARGE:-32013,UNPROCESSABLE_CONTENT:-32022,TOO_MANY_REQUESTS:-32029,CLIENT_CLOSED_REQUEST:-32099};ed(ef),ed(ef);let eh=()=>{},ep=e=>(function e(t,r){return new Proxy(eh,{get(n,i){if("string"==typeof i&&"then"!==i)return e(t,[...r,i])},apply(e,n,i){let s="apply"===r[r.length-1];return t({args:s?i.length>=2?i[1]:[]:i,path:s?r.slice(0,-1):r})}})})(e,[]),em=e=>new Proxy(eh,{get(t,r){if("string"==typeof r&&"then"!==r)return e(r)}});class eg extends Error{}function ey(e){return!!e&&!Array.isArray(e)&&"object"==typeof e}class ev extends Error{constructor(){super("Unable to transform response from server")}}function e_(e,t){let r;try{r=function(e,t){if("error"in e){let r=t.transformer.deserialize(e.error);return{ok:!1,error:{...e,error:r}}}return{ok:!0,result:{...e.result,...(!e.result.type||"data"===e.result.type)&&{type:"data",data:t.transformer.deserialize(e.result.data)}}}}(e,t)}catch(e){throw new ev}if(!r.ok&&(!ey(r.error.error)||"number"!=typeof r.error.error.code)||r.ok&&!ey(r.result))throw new ev;return r}class eb extends Error{static from(e,t={}){return e instanceof eb||e instanceof Error&&"TRPCClientError"===e.name?(t.meta&&(e.meta={...e.meta,...t.meta}),e):ey(e)&&ey(e.error)&&"number"==typeof e.error.code&&"string"==typeof e.error.message?new eb(e.error.message,{...t,result:e}):e instanceof Error?new eb(e.message,{...t,cause:function(e){if(e instanceof Error)return e;let t=typeof e;if("undefined"!==t&&"function"!==t&&null!==e){if("object"!==t)return Error(String(e));if(e&&!Array.isArray(e)&&"object"==typeof e){let t=new eg;for(let r in e)t[r]=e[r];return t}}}(e)}):new eb("Unknown error",{...t,cause:e})}constructor(e,t){let r=t?.cause;super(e,{cause:r}),this.meta=t?.meta,this.cause=r,this.shape=t?.result?.error,this.data=t?.result?.error.data,this.name="TRPCClientError",Object.setPrototypeOf(this,eb.prototype)}}let eS=e=>"function"==typeof e;function eE(e){var t;return{url:e.url.toString().replace(/\/$/,""),fetch:e.fetch,AbortController:(t=e.AbortController)?t:"undefined"!=typeof window&&window.AbortController?window.AbortController:"undefined"!=typeof globalThis&&globalThis.AbortController?globalThis.AbortController:null}}let ew={query:"GET",mutation:"POST"};function eO(e){return"input"in e?e.runtime.transformer.serialize(e.input):function(e){let t={};for(let r=0;r<e.length;r++){let n=e[r];t[r]=n}return t}(e.inputs.map(t=>e.runtime.transformer.serialize(t)))}let ek=e=>{let t=e.url+"/"+e.path,r=[];if("inputs"in e&&r.push("batch=1"),"query"===e.type){let t=eO(e);void 0!==t&&r.push(`input=${encodeURIComponent(JSON.stringify(t))}`)}return r.length&&(t+="?"+r.join("&")),t},eT=e=>{if("query"===e.type)return;let t=eO(e);return void 0!==t?JSON.stringify(t):void 0},eC=e=>eR({...e,contentTypeHeader:"application/json",getUrl:ek,getBody:eT});async function eI(e,t){let r=e.getUrl(e),n=e.getBody(e),{type:i}=e,s=await e.headers();/* istanbul ignore if -- @preserve */if("subscription"===i)throw Error("Subscriptions should use wsLink");let o={...e.contentTypeHeader?{"content-type":e.contentTypeHeader}:{},...e.batchModeHeader?{"trpc-batch-mode":e.batchModeHeader}:{},...s};return(function(e){if(e)return e;if("undefined"!=typeof window&&eS(window.fetch))return window.fetch;if("undefined"!=typeof globalThis&&eS(globalThis.fetch))return globalThis.fetch;throw Error("No fetch implementation found")})(e.fetch)(r,{method:ew[i],signal:t?.signal,body:n,headers:o})}function eR(e){let t=e.AbortController?new e.AbortController:null,r={},n=!1;return{promise:new Promise((i,s)=>{eI(e,t).then(e=>(r.response=e,n=!0,e.json())).then(e=>{r.responseJSON=e,i({json:e,meta:r})}).catch(e=>{n=!0,s(eb.from(e,{meta:r}))})}),cancel:()=>{n||t?.abort()}}}let ex=()=>{throw Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new")};function eA(e){let t=null,r=null,n=()=>{clearTimeout(r),r=null,t=null};function i(){let r=function(t){let r=[[]],n=0;for(;;){let i=t[n];if(!i)break;let s=r[r.length-1];if(i.aborted){i.reject?.(Error("Aborted")),n++;continue}if(e.validate(s.concat(i).map(e=>e.key))){s.push(i),n++;continue}if(0===s.length){i.reject?.(Error("Input is too big for a single dispatch")),n++;continue}r.push([])}return r}(t);for(let t of(n(),r)){if(!t.length)continue;let r={items:t,cancel:ex};for(let e of t)e.batch=r;let n=(e,t)=>{let n=r.items[e];n.resolve?.(t),n.batch=null,n.reject=null,n.resolve=null},{promise:i,cancel:s}=e.fetch(r.items.map(e=>e.key),n);r.cancel=s,i.then(e=>{for(let t=0;t<e.length;t++){let r=e[t];n(t,r)}for(let e of r.items)e.reject?.(Error("Missing result")),e.batch=null}).catch(e=>{for(let t of r.items)t.reject?.(e),t.batch=null})}}return{load:function(e){let n={aborted:!1,key:e,batch:null,resolve:ex,reject:ex},s=new Promise((e,r)=>{n.reject=r,n.resolve=e,t||(t=[]),t.push(n)});return r||(r=setTimeout(i)),{promise:s,cancel:()=>{n.aborted=!0,n.batch?.items.every(e=>e.aborted)&&(n.batch.cancel(),n.batch=null)}}}}}function eP(e){return function(t){let r=eE(t),n=t.maxURLLength??1/0;return i=>{let s=s=>({validate:e=>{if(n===1/0)return!0;let t=e.map(e=>e.path).join(","),o=e.map(e=>e.input);return ek({...r,runtime:i,type:s,path:t,inputs:o}).length<=n},fetch:e({...r,runtime:i,type:s,opts:t})}),o=eA(s("query")),a=eA(s("mutation")),u={query:o,subscription:eA(s("subscription")),mutation:a};return({op:e})=>el(t=>{let r;let{promise:n,cancel:s}=u[e.type].load(e);return n.then(e=>{r=e;let n=e_(e.json,i);if(!n.ok){t.error(eb.from(n.error,{meta:e.meta}));return}t.next({context:e.meta,result:n.result}),t.complete()}).catch(e=>{t.error(eb.from(e,{meta:r?.meta}))}),()=>{s()}})}}}let eM=eP(e=>t=>{let r=t.map(e=>e.path).join(","),n=t.map(e=>e.input),{promise:i,cancel:s}=eC({...e,path:r,inputs:n,headers:()=>e.opts.headers?"function"==typeof e.opts.headers?e.opts.headers({opList:t}):e.opts.headers:{}});return{promise:i.then(e=>(Array.isArray(e.json)?e.json:t.map(()=>e.json)).map(t=>({meta:e.meta,json:t}))),cancel:s}});function eN(e){return t=>{let r=eE(t);return n=>({op:i})=>el(s=>{let o;let{path:a,input:u,type:l}=i,{promise:c,cancel:d}=e.requester({...r,runtime:n,type:l,path:a,input:u,headers:()=>t.headers?"function"==typeof t.headers?t.headers({op:i}):t.headers:{}});return c.then(e=>{o=e.meta;let t=e_(e.json,n);if(!t.ok){s.error(eb.from(t.error,{meta:o}));return}s.next({context:e.meta,result:t.result}),s.complete()}).catch(e=>{s.error(eb.from(e,{meta:o}))}),()=>{d()}})}}eN({requester:eC});let eD={css:{query:["72e3ff","3fb0d8"],mutation:["c5a3fc","904dfc"],subscription:["ff49e1","d83fbe"]},ansi:{regular:{query:["\x1b[30;46m","\x1b[97;46m"],mutation:["\x1b[30;45m","\x1b[97;45m"],subscription:["\x1b[30;42m","\x1b[97;42m"]},bold:{query:["\x1b[1;30;46m","\x1b[1;97;46m"],mutation:["\x1b[1;30;45m","\x1b[1;97;45m"],subscription:["\x1b[1;30;42m","\x1b[1;97;42m"]}}},eL=({c:e=console,colorMode:t="css"})=>r=>{let n=r.input,i="undefined"!=typeof FormData&&n instanceof FormData?Object.fromEntries(n):n,{parts:s,args:o}=function(e){let{direction:t,type:r,path:n,id:i,input:s}=e,o=[],a=[];if("ansi"===e.colorMode){let[s,u]=eD.ansi.regular[r],[l,c]=eD.ansi.bold[r];return o.push("up"===t?s:u,"up"===t?">>":"<<",r,"up"===t?l:c,`#${i}`,n,"\x1b[0m"),"up"===t?a.push({input:e.input}):a.push({input:e.input,result:"result"in e.result?e.result.result:e.result,elapsedMs:e.elapsedMs}),{parts:o,args:a}}let[u,l]=eD.css[r],c=`
    background-color: #${"up"===t?u:l}; 
    color: ${"up"===t?"black":"white"};
    padding: 2px;
  `;return o.push("%c","up"===t?">>":"<<",r,`#${i}`,`%c${n}%c`,"%O"),a.push(c,`${c}; font-weight: bold;`,`${c}; font-weight: normal;`),"up"===t?a.push({input:s,context:e.context}):a.push({input:s,result:e.result,elapsedMs:e.elapsedMs,context:e.context}),{parts:o,args:a}}({...r,colorMode:t,input:i});e["down"===r.direction&&r.result&&(r.result instanceof Error||"error"in r.result.result)?"error":"log"].apply(null,[s.join(" ")].concat(o))};class ej{$request({type:e,input:t,path:r,context:n={}}){var i;return(i={links:this.links,op:{id:++this.requestId,type:e,path:r,input:t,context:n}},el(e=>(function e(t=0,r=i.op){let n=i.links[t];if(!n)throw Error("No more links to execute - did you forget to add an ending link?");return n({op:r,next:r=>e(t+1,r)})})().subscribe(e))).pipe(e=>{let t=0,r=null,n=[];return{subscribe:i=>(t++,n.push(i),r||(r=e.subscribe({next(e){for(let t of n)t.next?.(e)},error(e){for(let t of n)t.error?.(e)},complete(){for(let e of n)e.complete?.()}})),{unsubscribe(){t--,function(){if(0===t&&r){let e=r;r=null,e.unsubscribe()}}();let e=n.findIndex(e=>e===i);e>-1&&n.splice(e,1)}})}})}requestAsPromise(e){var t;let r;let{promise:n,abort:i}=(t=this.$request(e),{promise:new Promise((e,n)=>{let i=!1;function s(){i||(i=!0,n(new ec("This operation was aborted.")),o.unsubscribe())}let o=t.subscribe({next(t){i=!0,e(t),s()},error(e){i=!0,n(e),s()},complete(){i=!0,s()}});r=s}),abort:r});return new Promise((t,r)=>{e.signal?.addEventListener("abort",i),n.then(e=>{t(e.result.data)}).catch(e=>{r(eb.from(e))})})}query(e,t,r){return this.requestAsPromise({type:"query",path:e,input:t,context:r?.context,signal:r?.signal})}mutation(e,t,r){return this.requestAsPromise({type:"mutation",path:e,input:t,context:r?.context,signal:r?.signal})}subscription(e,t,r){return this.$request({type:"subscription",path:e,input:t,context:r?.context}).subscribe({next(e){"started"===e.result.type?r.onStarted?.():"stopped"===e.result.type?r.onStopped?.():r.onData?.(e.result.data)},error(e){r.onError?.(e)},complete(){r.onComplete?.()}})}constructor(e){this.requestId=0;let t=(()=>{let t=e.transformer;return t?"input"in t?e.transformer:{input:t,output:t}:{input:{serialize:e=>e,deserialize:e=>e},output:{serialize:e=>e,deserialize:e=>e}}})();this.runtime={transformer:{serialize:e=>t.input.serialize(e),deserialize:e=>t.output.deserialize(e)},combinedTransformer:t},this.links=e.links.map(e=>e(this.runtime))}}let eU={query:"query",mutate:"mutation",subscribe:"subscription"},eB=e=>eU[e];async function eF(e){let t=e.parse??JSON.parse;await e$(e.readableStream,r=>{if(e.signal?.aborted||!r||"}"===r)return;let n=r.indexOf(":"),i=r.substring(2,n-1),s=r.substring(n+1);e.onSingle(Number(i),t(s))},e.textDecoder)}async function e$(e,t,r){let n="",i=e=>{let i=r.decode(e).split("\n");if(1===i.length)n+=i[0];else if(i.length>1){t(n+i[0]);for(let e=1;e<i.length-1;e++)t(i[e]);n=i[i.length-1]}};"getReader"in e?await ez(e,i):await new Promise(t=>{e.on("data",i),e.on("end",t)}),t(n)}async function ez(e,t){let r=e.getReader(),n=await r.read();for(;!n.done;)t(n.value),n=await r.read()}let eH=(e,t)=>{let r=e.AbortController?new e.AbortController:null;return{cancel:()=>r?.abort(),promise:eI({...e,contentTypeHeader:"application/json",batchModeHeader:"stream",getUrl:ek,getBody:eT},r).then(async n=>{if(!n.body)throw Error("Received response without body");let i={response:n};return eF({readableStream:n.body,onSingle:t,parse:e=>({json:JSON.parse(e),meta:i}),signal:r?.signal,textDecoder:e.textDecoder})})}};eP(e=>{let t=function(e){if(e)return e;if("undefined"!=typeof window&&window.TextDecoder)return new window.TextDecoder;if("undefined"!=typeof globalThis&&globalThis.TextDecoder)return new globalThis.TextDecoder;throw Error("No TextDecoder implementation found")}(e.opts.textDecoder);return(r,n)=>{let i=r.map(e=>e.path).join(","),s=r.map(e=>e.input),{cancel:o,promise:a}=eH({...e,textDecoder:t,path:i,inputs:s,headers:()=>e.opts.headers?"function"==typeof e.opts.headers?e.opts.headers({opList:r}):e.opts.headers:{}},(e,t)=>{n(e,t)});return{promise:a.then(()=>[]),cancel:o}}});let eG=e=>{if("input"in e){if(!(e.input instanceof FormData))throw Error("Input is not FormData");return e.input}};eN({requester:e=>{if("mutation"!==e.type)throw Error("We only handle mutations with formdata");return eR({...e,getUrl:()=>`${e.url}/${e.path}`,getBody:eG})}});var eq=r(85945),eZ=r(67294);function eW(e){return e.state.isPaused}function eK(e){return"success"===e.state.status}let eV=({children:e,options:t,state:r})=>((function(e,t={}){let r=(0,eq.NL)({context:t.context}),n=eZ.useRef(t);n.current=t,eZ.useMemo(()=>{e&&function(e,t,r){if("object"!=typeof t||null===t)return;let n=e.getMutationCache(),i=e.getQueryCache(),s=t.mutations||[],o=t.queries||[];s.forEach(t=>{var i;n.build(e,{...null==r?void 0:null==(i=r.defaultOptions)?void 0:i.mutations,mutationKey:t.mutationKey},t.state)}),o.forEach(({queryKey:t,state:n,queryHash:s})=>{var o;let a=i.get(s);if(a){if(a.state.dataUpdatedAt<n.dataUpdatedAt){let{fetchStatus:e,...t}=n;a.setState(t)}return}i.build(e,{...null==r?void 0:null==(o=r.defaultOptions)?void 0:o.queries,queryKey:t,queryHash:s},{...n,fetchStatus:"idle"})})}(r,e,n.current)},[r,e])})(r,t),e);function eQ(e,t){let[r,n]=Array.isArray(e)?e:[e],i="string"!=typeof r||""===r?[]:r.split(".");return n||t&&"any"!==t?[i,{...void 0!==n&&{input:n},...t&&"any"!==t&&{type:t}}]:i.length?[i]:[]}var eX=r(32161),eJ=r(30081),eY=r(15761),e0=r(33989),e1=r(72379);class e2 extends e0.l{constructor(e,t){super(),this.client=e,this.options=t,this.trackedProps=new Set,this.selectError=null,this.bindMethods(),this.setOptions(t)}bindMethods(){this.remove=this.remove.bind(this),this.refetch=this.refetch.bind(this)}onSubscribe(){1===this.listeners.size&&(this.currentQuery.addObserver(this),e3(this.currentQuery,this.options)&&this.executeFetch(),this.updateTimers())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return e4(this.currentQuery,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return e4(this.currentQuery,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.clearStaleTimeout(),this.clearRefetchInterval(),this.currentQuery.removeObserver(this)}setOptions(e,t){let r=this.options,n=this.currentQuery;if(this.options=this.client.defaultQueryOptions(e),(0,eX.VS)(r,this.options)||this.client.getQueryCache().notify({type:"observerOptionsUpdated",query:this.currentQuery,observer:this}),void 0!==this.options.enabled&&"boolean"!=typeof this.options.enabled)throw Error("Expected enabled to be a boolean");this.options.queryKey||(this.options.queryKey=r.queryKey),this.updateQuery();let i=this.hasListeners();i&&e9(this.currentQuery,n,this.options,r)&&this.executeFetch(),this.updateResult(t),i&&(this.currentQuery!==n||this.options.enabled!==r.enabled||this.options.staleTime!==r.staleTime)&&this.updateStaleTimeout();let s=this.computeRefetchInterval();i&&(this.currentQuery!==n||this.options.enabled!==r.enabled||s!==this.currentRefetchInterval)&&this.updateRefetchInterval(s)}getOptimisticResult(e){let t=this.client.getQueryCache().build(this.client,e),r=this.createResult(t,e);return e.keepPreviousData||(void 0!==e.placeholderData?!r.isPlaceholderData:(0,eX.VS)(this.getCurrentResult(),r))||(this.currentResult=r,this.currentResultOptions=this.options,this.currentResultState=this.currentQuery.state),r}getCurrentResult(){return this.currentResult}trackResult(e){let t={};return Object.keys(e).forEach(r=>{Object.defineProperty(t,r,{configurable:!1,enumerable:!0,get:()=>(this.trackedProps.add(r),e[r])})}),t}getCurrentQuery(){return this.currentQuery}remove(){this.client.getQueryCache().remove(this.currentQuery)}refetch({refetchPage:e,...t}={}){return this.fetch({...t,meta:{refetchPage:e}})}fetchOptimistic(e){let t=this.client.defaultQueryOptions(e),r=this.client.getQueryCache().build(this.client,t);return r.isFetchingOptimistic=!0,r.fetch().then(()=>this.createResult(r,t))}fetch(e){var t;return this.executeFetch({...e,cancelRefetch:null==(t=e.cancelRefetch)||t}).then(()=>(this.updateResult(),this.currentResult))}executeFetch(e){this.updateQuery();let t=this.currentQuery.fetch(this.options,e);return null!=e&&e.throwOnError||(t=t.catch(eX.ZT)),t}updateStaleTimeout(){if(this.clearStaleTimeout(),eX.sk||this.currentResult.isStale||!(0,eX.PN)(this.options.staleTime))return;let e=(0,eX.Kp)(this.currentResult.dataUpdatedAt,this.options.staleTime);this.staleTimeoutId=setTimeout(()=>{this.currentResult.isStale||this.updateResult()},e+1)}computeRefetchInterval(){var e;return"function"==typeof this.options.refetchInterval?this.options.refetchInterval(this.currentResult.data,this.currentQuery):null!=(e=this.options.refetchInterval)&&e}updateRefetchInterval(e){this.clearRefetchInterval(),this.currentRefetchInterval=e,!eX.sk&&!1!==this.options.enabled&&(0,eX.PN)(this.currentRefetchInterval)&&0!==this.currentRefetchInterval&&(this.refetchIntervalId=setInterval(()=>{(this.options.refetchIntervalInBackground||eY.j.isFocused())&&this.executeFetch()},this.currentRefetchInterval))}updateTimers(){this.updateStaleTimeout(),this.updateRefetchInterval(this.computeRefetchInterval())}clearStaleTimeout(){this.staleTimeoutId&&(clearTimeout(this.staleTimeoutId),this.staleTimeoutId=void 0)}clearRefetchInterval(){this.refetchIntervalId&&(clearInterval(this.refetchIntervalId),this.refetchIntervalId=void 0)}createResult(e,t){let r;let n=this.currentQuery,i=this.options,s=this.currentResult,o=this.currentResultState,a=this.currentResultOptions,u=e!==n,l=u?e.state:this.currentQueryInitialState,c=u?this.currentResult:this.previousQueryResult,{state:d}=e,{dataUpdatedAt:f,error:h,errorUpdatedAt:p,fetchStatus:m,status:g}=d,y=!1,v=!1;if(t._optimisticResults){let r=this.hasListeners(),s=!r&&e3(e,t),o=r&&e9(e,n,t,i);(s||o)&&(m=(0,e1.Kw)(e.options.networkMode)?"fetching":"paused",f||(g="loading")),"isRestoring"===t._optimisticResults&&(m="idle")}if(t.keepPreviousData&&!d.dataUpdatedAt&&null!=c&&c.isSuccess&&"error"!==g)r=c.data,f=c.dataUpdatedAt,g=c.status,y=!0;else if(t.select&&void 0!==d.data){if(s&&d.data===(null==o?void 0:o.data)&&t.select===this.selectFn)r=this.selectResult;else try{this.selectFn=t.select,r=t.select(d.data),r=(0,eX.oE)(null==s?void 0:s.data,r,t),this.selectResult=r,this.selectError=null}catch(e){this.selectError=e}}else r=d.data;if(void 0!==t.placeholderData&&void 0===r&&"loading"===g){let e;if(null!=s&&s.isPlaceholderData&&t.placeholderData===(null==a?void 0:a.placeholderData))e=s.data;else if(e="function"==typeof t.placeholderData?t.placeholderData():t.placeholderData,t.select&&void 0!==e)try{e=t.select(e),this.selectError=null}catch(e){this.selectError=e}void 0!==e&&(g="success",r=(0,eX.oE)(null==s?void 0:s.data,e,t),v=!0)}this.selectError&&(h=this.selectError,r=this.selectResult,p=Date.now(),g="error");let _="fetching"===m,b="loading"===g,S="error"===g;return{status:g,fetchStatus:m,isLoading:b,isSuccess:"success"===g,isError:S,isInitialLoading:b&&_,data:r,dataUpdatedAt:f,error:h,errorUpdatedAt:p,failureCount:d.fetchFailureCount,failureReason:d.fetchFailureReason,errorUpdateCount:d.errorUpdateCount,isFetched:d.dataUpdateCount>0||d.errorUpdateCount>0,isFetchedAfterMount:d.dataUpdateCount>l.dataUpdateCount||d.errorUpdateCount>l.errorUpdateCount,isFetching:_,isRefetching:_&&!b,isLoadingError:S&&0===d.dataUpdatedAt,isPaused:"paused"===m,isPlaceholderData:v,isPreviousData:y,isRefetchError:S&&0!==d.dataUpdatedAt,isStale:e5(e,t),refetch:this.refetch,remove:this.remove}}updateResult(e){let t=this.currentResult,r=this.createResult(this.currentQuery,this.options);if(this.currentResultState=this.currentQuery.state,this.currentResultOptions=this.options,(0,eX.VS)(r,t))return;this.currentResult=r;let n={cache:!0};(null==e?void 0:e.listeners)!==!1&&(()=>{if(!t)return!0;let{notifyOnChangeProps:e}=this.options,r="function"==typeof e?e():e;if("all"===r||!r&&!this.trackedProps.size)return!0;let n=new Set(null!=r?r:this.trackedProps);return this.options.useErrorBoundary&&n.add("error"),Object.keys(this.currentResult).some(e=>this.currentResult[e]!==t[e]&&n.has(e))})()&&(n.listeners=!0),this.notify({...n,...e})}updateQuery(){let e=this.client.getQueryCache().build(this.client,this.options);if(e===this.currentQuery)return;let t=this.currentQuery;this.currentQuery=e,this.currentQueryInitialState=e.state,this.previousQueryResult=this.currentResult,this.hasListeners()&&(null==t||t.removeObserver(this),e.addObserver(this))}onQueryUpdate(e){let t={};"success"===e.type?t.onSuccess=!e.manual:"error"!==e.type||(0,e1.DV)(e.error)||(t.onError=!0),this.updateResult(t),this.hasListeners()&&this.updateTimers()}notify(e){eJ.V.batch(()=>{var t,r,n,i,s,o,a,u;e.onSuccess?(null==(t=(r=this.options).onSuccess)||t.call(r,this.currentResult.data),null==(n=(i=this.options).onSettled)||n.call(i,this.currentResult.data,null)):e.onError&&(null==(s=(o=this.options).onError)||s.call(o,this.currentResult.error),null==(a=(u=this.options).onSettled)||a.call(u,void 0,this.currentResult.error)),e.listeners&&this.listeners.forEach(({listener:e})=>{e(this.currentResult)}),e.cache&&this.client.getQueryCache().notify({query:this.currentQuery,type:"observerResultsUpdated"})})}}function e3(e,t){return!1!==t.enabled&&!e.state.dataUpdatedAt&&!("error"===e.state.status&&!1===t.retryOnMount)||e.state.dataUpdatedAt>0&&e4(e,t,t.refetchOnMount)}function e4(e,t,r){if(!1!==t.enabled){let n="function"==typeof r?r(e):r;return"always"===n||!1!==n&&e5(e,t)}return!1}function e9(e,t,r,n){return!1!==r.enabled&&(e!==t||!1===n.enabled)&&(!r.suspense||"error"!==e.state.status)&&e5(e,r)}function e5(e,t){return e.isStaleByTime(t.staleTime)}var e8=r(464);let e6=eZ.createContext((n=!1,{clearReset:()=>{n=!1},reset:()=>{n=!0},isReset:()=>n})),e7=()=>eZ.useContext(e6),te=eZ.createContext(!1),tt=()=>eZ.useContext(te);te.Provider;var tr=r(24798);let tn=(e,t)=>{(e.suspense||e.useErrorBoundary)&&!t.isReset()&&(e.retryOnMount=!1)},ti=e=>{eZ.useEffect(()=>{e.clearReset()},[e])},ts=({result:e,errorResetBoundary:t,useErrorBoundary:r,query:n})=>e.isError&&!t.isReset()&&!e.isFetching&&(0,tr.L)(r,[e.error,n]),to=e=>{e.suspense&&"number"!=typeof e.staleTime&&(e.staleTime=1e3)},ta=(e,t)=>e.isLoading&&e.isFetching&&!t,tu=(e,t,r)=>(null==e?void 0:e.suspense)&&ta(t,r),tl=(e,t,r)=>t.fetchOptimistic(e).then(({data:t})=>{null==e.onSuccess||e.onSuccess(t),null==e.onSettled||e.onSettled(t,null)}).catch(t=>{r.clearReset(),null==e.onError||e.onError(t),null==e.onSettled||e.onSettled(void 0,t)});function tc(e,t){let r=(0,eq.NL)({context:e.context}),n=tt(),i=e7(),s=r.defaultQueryOptions(e);s._optimisticResults=n?"isRestoring":"optimistic",s.onError&&(s.onError=eJ.V.batchCalls(s.onError)),s.onSuccess&&(s.onSuccess=eJ.V.batchCalls(s.onSuccess)),s.onSettled&&(s.onSettled=eJ.V.batchCalls(s.onSettled)),to(s),tn(s,i),ti(i);let[o]=eZ.useState(()=>new t(r,s)),a=o.getOptimisticResult(s);if((0,e8.$)(eZ.useCallback(e=>{let t=n?()=>void 0:o.subscribe(eJ.V.batchCalls(e));return o.updateResult(),t},[o,n]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),eZ.useEffect(()=>{o.setOptions(s,{listeners:!1})},[s,o]),tu(s,a,n))throw tl(s,o,i);if(ts({result:a,errorResetBoundary:i,useErrorBoundary:s.useErrorBoundary,query:o.getCurrentQuery()}))throw a.error;return s.notifyOnChangeProps?a:o.trackResult(a)}var td=r(48228);function tf(){return{onFetch:e=>{e.fetchFn=()=>{var t,r,n,i,s,o;let a;let u=null==(t=e.fetchOptions)?void 0:null==(r=t.meta)?void 0:r.refetchPage,l=null==(n=e.fetchOptions)?void 0:null==(i=n.meta)?void 0:i.fetchMore,c=null==l?void 0:l.pageParam,d=(null==l?void 0:l.direction)==="forward",f=(null==l?void 0:l.direction)==="backward",h=(null==(s=e.state.data)?void 0:s.pages)||[],p=(null==(o=e.state.data)?void 0:o.pageParams)||[],m=p,g=!1,y=t=>{Object.defineProperty(t,"signal",{enumerable:!0,get:()=>{var t,r;return null!=(t=e.signal)&&t.aborted?g=!0:null==(r=e.signal)||r.addEventListener("abort",()=>{g=!0}),e.signal}})},v=e.options.queryFn||(()=>Promise.reject("Missing queryFn for queryKey '"+e.options.queryHash+"'")),_=(e,t,r,n)=>(m=n?[t,...m]:[...m,t],n?[r,...e]:[...e,r]),b=(t,r,n,i)=>{if(g)return Promise.reject("Cancelled");if(void 0===n&&!r&&t.length)return Promise.resolve(t);let s={queryKey:e.queryKey,pageParam:n,meta:e.options.meta};return y(s),Promise.resolve(v(s)).then(e=>_(t,n,e,i))};if(h.length){if(d){let t=void 0!==c,r=t?c:th(e.options,h);a=b(h,t,r)}else if(f){let t=void 0!==c,r=t?c:tp(e.options,h);a=b(h,t,r,!0)}else{m=[];let t=void 0===e.options.getNextPageParam;a=!u||!h[0]||u(h[0],0,h)?b([],t,p[0]):Promise.resolve(_([],p[0],h[0]));for(let r=1;r<h.length;r++)a=a.then(n=>{if(!u||!h[r]||u(h[r],r,h)){let i=t?p[r]:th(e.options,n);return b(n,t,i)}return Promise.resolve(_(n,p[r],h[r]))})}}else a=b([]);return a.then(e=>({pages:e,pageParams:m}))}}}}function th(e,t){return null==e.getNextPageParam?void 0:e.getNextPageParam(t[t.length-1],t)}function tp(e,t){return null==e.getPreviousPageParam?void 0:e.getPreviousPageParam(t[0],t)}class tm extends e2{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e,t){super.setOptions({...e,behavior:tf()},t)}getOptimisticResult(e){return e.behavior=tf(),super.getOptimisticResult(e)}fetchNextPage({pageParam:e,...t}={}){return this.fetch({...t,meta:{fetchMore:{direction:"forward",pageParam:e}}})}fetchPreviousPage({pageParam:e,...t}={}){return this.fetch({...t,meta:{fetchMore:{direction:"backward",pageParam:e}}})}createResult(e,t){var r,n,i,s,o,a;let{state:u}=e,l=super.createResult(e,t),{isFetching:c,isRefetching:d}=l,f=c&&(null==(r=u.fetchMeta)?void 0:null==(n=r.fetchMore)?void 0:n.direction)==="forward",h=c&&(null==(i=u.fetchMeta)?void 0:null==(s=i.fetchMore)?void 0:s.direction)==="backward";return{...l,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:function(e,t){if(e.getNextPageParam&&Array.isArray(t)){let r=th(e,t);return null!=r&&!1!==r}}(t,null==(o=u.data)?void 0:o.pages),hasPreviousPage:function(e,t){if(e.getPreviousPageParam&&Array.isArray(t)){let r=tp(e,t);return null!=r&&!1!==r}}(t,null==(a=u.data)?void 0:a.pages),isFetchingNextPage:f,isFetchingPreviousPage:h,isRefetching:d&&!f&&!h}}}class tg extends e0.l{constructor(e,t){super(),this.client=e,this.queries=[],this.result=[],this.observers=[],this.observersMap={},t&&this.setQueries(t)}onSubscribe(){1===this.listeners.size&&this.observers.forEach(e=>{e.subscribe(t=>{this.onUpdate(e,t)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,this.observers.forEach(e=>{e.destroy()})}setQueries(e,t){this.queries=e,eJ.V.batch(()=>{let e=this.observers,r=this.findMatchingObservers(this.queries);r.forEach(e=>e.observer.setOptions(e.defaultedQueryOptions,t));let n=r.map(e=>e.observer),i=Object.fromEntries(n.map(e=>[e.options.queryHash,e])),s=n.map(e=>e.getCurrentResult()),o=n.some((t,r)=>t!==e[r]);(e.length!==n.length||o)&&(this.observers=n,this.observersMap=i,this.result=s,this.hasListeners()&&((0,eX.e5)(e,n).forEach(e=>{e.destroy()}),(0,eX.e5)(n,e).forEach(e=>{e.subscribe(t=>{this.onUpdate(e,t)})}),this.notify()))})}getCurrentResult(){return this.result}getQueries(){return this.observers.map(e=>e.getCurrentQuery())}getObservers(){return this.observers}getOptimisticResult(e){return this.findMatchingObservers(e).map(e=>e.observer.getOptimisticResult(e.defaultedQueryOptions))}findMatchingObservers(e){let t=this.observers,r=new Map(t.map(e=>[e.options.queryHash,e])),n=e.map(e=>this.client.defaultQueryOptions(e)),i=n.flatMap(e=>{let t=r.get(e.queryHash);return null!=t?[{defaultedQueryOptions:e,observer:t}]:[]}),s=new Set(i.map(e=>e.defaultedQueryOptions.queryHash)),o=n.filter(e=>!s.has(e.queryHash)),a=new Set(i.map(e=>e.observer)),u=t.filter(e=>!a.has(e)),l=e=>{let t=this.client.defaultQueryOptions(e),r=this.observersMap[t.queryHash];return null!=r?r:new e2(this.client,t)},c=o.map((e,t)=>{if(e.keepPreviousData){let r=u[t];if(void 0!==r)return{defaultedQueryOptions:e,observer:r}}return{defaultedQueryOptions:e,observer:l(e)}});return i.concat(c).sort((e,t)=>n.indexOf(e.defaultedQueryOptions)-n.indexOf(t.defaultedQueryOptions))}onUpdate(e,t){let r=this.observers.indexOf(e);-1!==r&&(this.result=(0,eX.Rc)(this.result,r,t),this.notify())}notify(){eJ.V.batch(()=>{this.listeners.forEach(({listener:e})=>{e(this.result)})})}}function ty(e,t){return e.length?void 0===t?[e]:[e,t]:[]}function tv(e,t){return ep(r=>{let n=r.args,i=[e,...r.path],s=i.pop(),o=i.join(".");if("useMutation"===s)return t[s](o,...n);let[a,...u]=n,l=ty(o,a);if("getQueryKey"===s)return eQ(l,u[0]??"any");if("_def"===s)return{path:i};if(s.startsWith("useSuspense")){let e=u[0]||{},r=t["useSuspenseQuery"===s?"useQuery":"useInfiniteQuery"](l,{...e,suspense:!0,enabled:!0});return[r.data,r]}return t[s](l,...u)})}let t_=["client","ssrContext","ssrState","abortOnUnmount"],tb=(0,eZ.createContext)(null);function tS(e){return em(t=>{if("client"===t){var r;return r=e.client,em(e=>r.hasOwnProperty(e)?r[e]:"__untypedClient"===e?r:ep(({path:t,args:n})=>{let i=[e,...t],s=eB(i.pop()),o=i.join(".");return r[s](o,...n)}))}return t_.includes(t)?e[t]:ep(({path:r,args:n})=>{let i=[t,...r],s=i.pop(),o=i.join("."),{queryKey:a,rest:u,updater:l}=(e=>{if(["setData","setInfiniteData"].includes(e)){let[e,t,...r]=n;return{queryKey:ty(o,e),updater:t,rest:r}}let[t,...r]=n;return{queryKey:ty(o,t),rest:r}})(s);return({fetch:()=>e.fetchQuery(a,...u),fetchInfinite:()=>e.fetchInfiniteQuery(a,...u),prefetch:()=>e.prefetchQuery(a,...u),prefetchInfinite:()=>e.prefetchInfiniteQuery(a,...u),ensureData:()=>e.ensureQueryData(a,...u),invalidate:()=>e.invalidateQueries(a,...u),reset:()=>e.resetQueries(a,...u),refetch:()=>e.refetchQueries(a,...u),cancel:()=>e.cancelQuery(a,...u),setData:()=>{e.setQueryData(a,l,...u)},setInfiniteData:()=>{e.setInfiniteQueryData(a,l,...u)},getData:()=>e.getQueryData(a),getInfiniteData:()=>e.getInfiniteQueryData(a)})[s]()})})}function tE(e,t){let[r,n]=e;return[r,n,t?.trpc]}function tw(e){let{path:t}=e;return(0,eZ.useMemo)(()=>({path:t}),[t])}function tO(e){return function(e){let t=(e?.overrides??e?.unstable_overrides)?.useMutation?.onSuccess??(e=>e.originalFn()),r=e?.context??tb,n=e?.reactQueryContext;function i(){return eZ.useContext(r)}function s(e,t,r){let{queryClient:n,ssrState:s}=i();return s&&"mounted"!==s&&n.getQueryCache().find(eQ(e,t))?.state.status==="error"?{retryOnMount:!1,...r}:r}return{Provider:e=>{let{abortOnUnmount:t=!1,client:n,queryClient:i,ssrContext:s}=e,[o,a]=(0,eZ.useState)(e.ssrState??!1);return(0,eZ.useEffect)(()=>{a(e=>!!e&&"mounted")},[]),eZ.createElement(r.Provider,{value:{abortOnUnmount:t,queryClient:i,client:n,ssrContext:s??null,ssrState:o,fetchQuery:(0,eZ.useCallback)((e,t)=>i.fetchQuery({...t,queryKey:eQ(e,"query"),queryFn:()=>n.query(...tE(e,t))}),[n,i]),fetchInfiniteQuery:(0,eZ.useCallback)((e,t)=>i.fetchInfiniteQuery({...t,queryKey:eQ(e,"infinite"),queryFn:({pageParam:r})=>{let[i,s]=e,o={...s,cursor:r};return n.query(...tE([i,o],t))}}),[n,i]),prefetchQuery:(0,eZ.useCallback)((e,t)=>i.prefetchQuery({...t,queryKey:eQ(e,"query"),queryFn:()=>n.query(...tE(e,t))}),[n,i]),prefetchInfiniteQuery:(0,eZ.useCallback)((e,t)=>i.prefetchInfiniteQuery({...t,queryKey:eQ(e,"infinite"),queryFn:({pageParam:r})=>{let[i,s]=e,o={...s,cursor:r};return n.query(...tE([i,o],t))}}),[n,i]),ensureQueryData:(0,eZ.useCallback)((e,t)=>i.ensureQueryData({...t,queryKey:eQ(e,"query"),queryFn:()=>n.query(...tE(e,t))}),[n,i]),invalidateQueries:(0,eZ.useCallback)((e,t,r)=>i.invalidateQueries({...t,queryKey:eQ(e,"any")},r),[i]),resetQueries:(0,eZ.useCallback)((...e)=>{let[t,r,n]=e;return i.resetQueries({...r,queryKey:eQ(t,"any")},n)},[i]),refetchQueries:(0,eZ.useCallback)((...e)=>{let[t,r,n]=e;return i.refetchQueries({...r,queryKey:eQ(t,"any")},n)},[i]),cancelQuery:(0,eZ.useCallback)(e=>i.cancelQueries({queryKey:eQ(e,"any")}),[i]),setQueryData:(0,eZ.useCallback)((...e)=>{let[t,...r]=e;return i.setQueryData(eQ(t,"query"),...r)},[i]),getQueryData:(0,eZ.useCallback)((...e)=>{let[t,...r]=e;return i.getQueryData(eQ(t,"query"),...r)},[i]),setInfiniteQueryData:(0,eZ.useCallback)((...e)=>{let[t,...r]=e;return i.setQueryData(eQ(t,"infinite"),...r)},[i]),getInfiniteQueryData:(0,eZ.useCallback)((...e)=>{let[t,...r]=e;return i.getQueryData(eQ(t,"infinite"),...r)},[i])}},e.children)},createClient:e=>new ej(e),useContext:i,useUtils:i,useQuery:function(t,r){var o;let a=i();if(!a)throw Error("Unable to retrieve application context. Did you forget to wrap your App inside `withTRPC` HoC?");let{abortOnUnmount:u,client:l,ssrState:c,queryClient:d,prefetchQuery:f}=a,h=d.getQueryDefaults(eQ(t,"query"));"undefined"!=typeof window||"prepass"!==c||r?.trpc?.ssr===!1||(r?.enabled??h?.enabled)===!1||d.getQueryCache().find(eQ(t,"query"))||f(t,r);let p=s(t,"query",{...h,...r}),m=r?.trpc?.abortOnUnmount??e?.abortOnUnmount??u,g=(o={...p,queryKey:eQ(t,"query"),queryFn:e=>{let r={...p,trpc:{...p?.trpc,...m?{signal:e.signal}:{}}};return l.query(...tE(t,r))},context:n},tc((0,eX._v)(o,void 0,void 0),e2));return g.trpc=tw({path:t[0]}),g},useQueries:(e,t)=>{let{ssrState:r,queryClient:n,prefetchQuery:s,client:o}=i(),a=e(ep(e=>{let t=e.path.join("."),[r,n]=e.args;return{queryKey:ty(t,r),queryFn:()=>o.query(t,r,n?.trpc),...n}}));if("undefined"==typeof window&&"prepass"===r)for(let e of a)e.trpc?.ssr===!1||n.getQueryCache().find(eQ(e.queryKey,"query"))||s(e.queryKey,e);return function({queries:e,context:t}){let r=(0,eq.NL)({context:t}),n=tt(),i=e7(),s=eZ.useMemo(()=>e.map(e=>{let t=r.defaultQueryOptions(e);return t._optimisticResults=n?"isRestoring":"optimistic",t}),[e,r,n]);s.forEach(e=>{to(e),tn(e,i)}),ti(i);let[o]=eZ.useState(()=>new tg(r,s)),a=o.getOptimisticResult(s);(0,e8.$)(eZ.useCallback(e=>n?()=>void 0:o.subscribe(eJ.V.batchCalls(e)),[o,n]),()=>o.getCurrentResult(),()=>o.getCurrentResult()),eZ.useEffect(()=>{o.setQueries(s,{listeners:!1})},[s,o]);let u=a.some((e,t)=>tu(s[t],e,n))?a.flatMap((e,t)=>{let r=s[t],a=o.getObservers()[t];if(r&&a){if(tu(r,e,n))return tl(r,a,i);ta(e,n)&&tl(r,a,i)}return[]}):[];if(u.length>0)throw Promise.all(u);let l=o.getQueries(),c=a.find((e,t)=>{var r,n;return ts({result:e,errorResetBoundary:i,useErrorBoundary:null!=(r=null==(n=s[t])?void 0:n.useErrorBoundary)&&r,query:l[t]})});if(null!=c&&c.error)throw c.error;return a}({queries:a.map(e=>({...e,queryKey:eQ(e.queryKey,"query")})),context:t})},useMutation:function(e,r){let{client:s}=i(),o=(0,eq.NL)({context:n}),a=Array.isArray(e)?e[0]:e,u=o.getMutationDefaults([a.split(".")]),l=(0,td.D)({...r,mutationKey:[a.split(".")],mutationFn:e=>s.mutation(...tE([a,e],r)),context:n,onSuccess:(...e)=>t({originalFn:()=>r?.onSuccess?.(...e)??u?.onSuccess?.(...e),queryClient:o,meta:r?.meta??u?.meta??{}})});return l.trpc=tw({path:a}),l},useSubscription:/* istanbul ignore next -- @preserve */function(e,t){let r=t?.enabled??!0,n=(0,eX.yF)(e),{client:s}=i(),o=(0,eZ.useRef)(t);o.current=t,(0,eZ.useEffect)(()=>{if(!r)return;let[t,n]=e,i=!1,a=s.subscription(t,n??void 0,{onStarted:()=>{i||o.current.onStarted?.()},onData:e=>{i||o.current.onData(e)},onError:e=>{i||o.current.onError?.(e)}});return()=>{i=!0,a.unsubscribe()}},[n,r])},useDehydratedState:(e,t)=>(0,eZ.useMemo)(()=>t?e.runtime.transformer.deserialize(t):t,[t,e]),useInfiniteQuery:function(e,t){var r;let[o,a]=e,{client:u,ssrState:l,prefetchInfiniteQuery:c,queryClient:d,abortOnUnmount:f}=i(),h=d.getQueryDefaults(eQ(e,"infinite"));"undefined"!=typeof window||"prepass"!==l||t?.trpc?.ssr===!1||(t?.enabled??h?.enabled)===!1||d.getQueryCache().find(eQ(e,"infinite"))||c(e,{...h,...t});let p=s(e,"infinite",{...h,...t}),m=t?.trpc?.abortOnUnmount??f,g=(r={...p,queryKey:eQ(e,"infinite"),queryFn:e=>{let r={...p,trpc:{...p?.trpc,...m?{signal:e.signal}:{}}},n={...a??{},cursor:e.pageParam??t?.initialCursor};return u.query(...tE([o,n],r))},context:n},tc((0,eX._v)(r,void 0,void 0),tm));return g.trpc=tw({path:o}),g}}}(e)}var tk=r(30819),tT=r(89643);class tC extends tT.F{constructor(e){super(),this.abortSignalConsumed=!1,this.defaultOptions=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.cache=e.cache,this.logger=e.logger||tk._,this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.initialState=e.state||function(e){let t="function"==typeof e.initialData?e.initialData():e.initialData,r=void 0!==t,n=r?"function"==typeof e.initialDataUpdatedAt?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?null!=n?n:Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"loading",fetchStatus:"idle"}}(this.options),this.state=this.initialState,this.scheduleGc()}get meta(){return this.options.meta}setOptions(e){this.options={...this.defaultOptions,...e},this.updateCacheTime(this.options.cacheTime)}optionalRemove(){this.observers.length||"idle"!==this.state.fetchStatus||this.cache.remove(this)}setData(e,t){let r=(0,eX.oE)(this.state.data,e,this.options);return this.dispatch({data:r,type:"success",dataUpdatedAt:null==t?void 0:t.updatedAt,manual:null==t?void 0:t.manual}),r}setState(e,t){this.dispatch({type:"setState",state:e,setStateOptions:t})}cancel(e){var t;let r=this.promise;return null==(t=this.retryer)||t.cancel(e),r?r.then(eX.ZT).catch(eX.ZT):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.initialState)}isActive(){return this.observers.some(e=>!1!==e.options.enabled)}isDisabled(){return this.getObserversCount()>0&&!this.isActive()}isStale(){return this.state.isInvalidated||!this.state.dataUpdatedAt||this.observers.some(e=>e.getCurrentResult().isStale)}isStaleByTime(e=0){return this.state.isInvalidated||!this.state.dataUpdatedAt||!(0,eX.Kp)(this.state.dataUpdatedAt,e)}onFocus(){var e;let t=this.observers.find(e=>e.shouldFetchOnWindowFocus());t&&t.refetch({cancelRefetch:!1}),null==(e=this.retryer)||e.continue()}onOnline(){var e;let t=this.observers.find(e=>e.shouldFetchOnReconnect());t&&t.refetch({cancelRefetch:!1}),null==(e=this.retryer)||e.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.cache.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.retryer&&(this.abortSignalConsumed?this.retryer.cancel({revert:!0}):this.retryer.cancelRetry()),this.scheduleGc()),this.cache.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.dispatch({type:"invalidate"})}fetch(e,t){var r,n,i,s;if("idle"!==this.state.fetchStatus){if(this.state.dataUpdatedAt&&null!=t&&t.cancelRefetch)this.cancel({silent:!0});else if(this.promise)return null==(i=this.retryer)||i.continueRetry(),this.promise}if(e&&this.setOptions(e),!this.options.queryFn){let e=this.observers.find(e=>e.options.queryFn);e&&this.setOptions(e.options)}let o=(0,eX.G9)(),a={queryKey:this.queryKey,pageParam:void 0,meta:this.meta},u=e=>{Object.defineProperty(e,"signal",{enumerable:!0,get:()=>{if(o)return this.abortSignalConsumed=!0,o.signal}})};u(a);let l={fetchOptions:t,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:()=>this.options.queryFn?(this.abortSignalConsumed=!1,this.options.queryFn(a)):Promise.reject("Missing queryFn for queryKey '"+this.options.queryHash+"'")};u(l),null==(r=this.options.behavior)||r.onFetch(l),this.revertState=this.state,("idle"===this.state.fetchStatus||this.state.fetchMeta!==(null==(n=l.fetchOptions)?void 0:n.meta))&&this.dispatch({type:"fetch",meta:null==(s=l.fetchOptions)?void 0:s.meta});let c=e=>{if((0,e1.DV)(e)&&e.silent||this.dispatch({type:"error",error:e}),!(0,e1.DV)(e)){var t,r,n,i;null==(t=(r=this.cache.config).onError)||t.call(r,e,this),null==(n=(i=this.cache.config).onSettled)||n.call(i,this.state.data,e,this)}this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1};return this.retryer=(0,e1.Mz)({fn:l.fetchFn,abort:null==o?void 0:o.abort.bind(o),onSuccess:e=>{var t,r,n,i;if(void 0===e){c(Error(this.queryHash+" data is undefined"));return}this.setData(e),null==(t=(r=this.cache.config).onSuccess)||t.call(r,e,this),null==(n=(i=this.cache.config).onSettled)||n.call(i,e,this.state.error,this),this.isFetchingOptimistic||this.scheduleGc(),this.isFetchingOptimistic=!1},onError:c,onFail:(e,t)=>{this.dispatch({type:"failed",failureCount:e,error:t})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:l.options.retry,retryDelay:l.options.retryDelay,networkMode:l.options.networkMode}),this.promise=this.retryer.promise,this.promise}dispatch(e){this.state=(t=>{var r,n;switch(e.type){case"failed":return{...t,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...t,fetchStatus:"paused"};case"continue":return{...t,fetchStatus:"fetching"};case"fetch":return{...t,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null!=(r=e.meta)?r:null,fetchStatus:(0,e1.Kw)(this.options.networkMode)?"fetching":"paused",...!t.dataUpdatedAt&&{error:null,status:"loading"}};case"success":return{...t,data:e.data,dataUpdateCount:t.dataUpdateCount+1,dataUpdatedAt:null!=(n=e.dataUpdatedAt)?n:Date.now(),error:null,isInvalidated:!1,status:"success",...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":let i=e.error;if((0,e1.DV)(i)&&i.revert&&this.revertState)return{...this.revertState,fetchStatus:"idle"};return{...t,error:i,errorUpdateCount:t.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:t.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...t,isInvalidated:!0};case"setState":return{...t,...e.state}}})(this.state),eJ.V.batch(()=>{this.observers.forEach(t=>{t.onQueryUpdate(e)}),this.cache.notify({query:this,type:"updated",action:e})})}}class tI extends e0.l{constructor(e){super(),this.config=e||{},this.queries=[],this.queriesMap={}}build(e,t,r){var n;let i=t.queryKey,s=null!=(n=t.queryHash)?n:(0,eX.Rm)(i,t),o=this.get(s);return o||(o=new tC({cache:this,logger:e.getLogger(),queryKey:i,queryHash:s,options:e.defaultQueryOptions(t),state:r,defaultOptions:e.getQueryDefaults(i)}),this.add(o)),o}add(e){this.queriesMap[e.queryHash]||(this.queriesMap[e.queryHash]=e,this.queries.push(e),this.notify({type:"added",query:e}))}remove(e){let t=this.queriesMap[e.queryHash];t&&(e.destroy(),this.queries=this.queries.filter(t=>t!==e),t===e&&delete this.queriesMap[e.queryHash],this.notify({type:"removed",query:e}))}clear(){eJ.V.batch(()=>{this.queries.forEach(e=>{this.remove(e)})})}get(e){return this.queriesMap[e]}getAll(){return this.queries}find(e,t){let[r]=(0,eX.I6)(e,t);return void 0===r.exact&&(r.exact=!0),this.queries.find(e=>(0,eX._x)(r,e))}findAll(e,t){let[r]=(0,eX.I6)(e,t);return Object.keys(r).length>0?this.queries.filter(e=>(0,eX._x)(r,e)):this.queries}notify(e){eJ.V.batch(()=>{this.listeners.forEach(({listener:t})=>{t(e)})})}onFocus(){eJ.V.batch(()=>{this.queries.forEach(e=>{e.onFocus()})})}onOnline(){eJ.V.batch(()=>{this.queries.forEach(e=>{e.onOnline()})})}}var tR=r(89886);class tx extends e0.l{constructor(e){super(),this.config=e||{},this.mutations=[],this.mutationId=0}build(e,t,r){let n=new tR.m({mutationCache:this,logger:e.getLogger(),mutationId:++this.mutationId,options:e.defaultMutationOptions(t),state:r,defaultOptions:t.mutationKey?e.getMutationDefaults(t.mutationKey):void 0});return this.add(n),n}add(e){this.mutations.push(e),this.notify({type:"added",mutation:e})}remove(e){this.mutations=this.mutations.filter(t=>t!==e),this.notify({type:"removed",mutation:e})}clear(){eJ.V.batch(()=>{this.mutations.forEach(e=>{this.remove(e)})})}getAll(){return this.mutations}find(e){return void 0===e.exact&&(e.exact=!0),this.mutations.find(t=>(0,eX.X7)(e,t))}findAll(e){return this.mutations.filter(t=>(0,eX.X7)(e,t))}notify(e){eJ.V.batch(()=>{this.listeners.forEach(({listener:t})=>{t(e)})})}resumePausedMutations(){var e;return this.resuming=(null!=(e=this.resuming)?e:Promise.resolve()).then(()=>{let e=this.mutations.filter(e=>e.state.isPaused);return eJ.V.batch(()=>e.reduce((e,t)=>e.then(()=>t.continue().catch(eX.ZT)),Promise.resolve()))}).then(()=>{this.resuming=void 0}),this.resuming}}var tA=r(96474);class tP{constructor(e={}){this.queryCache=e.queryCache||new tI,this.mutationCache=e.mutationCache||new tx,this.logger=e.logger||tk._,this.defaultOptions=e.defaultOptions||{},this.queryDefaults=[],this.mutationDefaults=[],this.mountCount=0}mount(){this.mountCount++,1===this.mountCount&&(this.unsubscribeFocus=eY.j.subscribe(()=>{eY.j.isFocused()&&(this.resumePausedMutations(),this.queryCache.onFocus())}),this.unsubscribeOnline=tA.N.subscribe(()=>{tA.N.isOnline()&&(this.resumePausedMutations(),this.queryCache.onOnline())}))}unmount(){var e,t;this.mountCount--,0===this.mountCount&&(null==(e=this.unsubscribeFocus)||e.call(this),this.unsubscribeFocus=void 0,null==(t=this.unsubscribeOnline)||t.call(this),this.unsubscribeOnline=void 0)}isFetching(e,t){let[r]=(0,eX.I6)(e,t);return r.fetchStatus="fetching",this.queryCache.findAll(r).length}isMutating(e){return this.mutationCache.findAll({...e,fetching:!0}).length}getQueryData(e,t){var r;return null==(r=this.queryCache.find(e,t))?void 0:r.state.data}ensureQueryData(e,t,r){let n=(0,eX._v)(e,t,r),i=this.getQueryData(n.queryKey);return i?Promise.resolve(i):this.fetchQuery(n)}getQueriesData(e){return this.getQueryCache().findAll(e).map(({queryKey:e,state:t})=>[e,t.data])}setQueryData(e,t,r){let n=this.queryCache.find(e),i=null==n?void 0:n.state.data,s=(0,eX.SE)(t,i);if(void 0===s)return;let o=(0,eX._v)(e),a=this.defaultQueryOptions(o);return this.queryCache.build(this,a).setData(s,{...r,manual:!0})}setQueriesData(e,t,r){return eJ.V.batch(()=>this.getQueryCache().findAll(e).map(({queryKey:e})=>[e,this.setQueryData(e,t,r)]))}getQueryState(e,t){var r;return null==(r=this.queryCache.find(e,t))?void 0:r.state}removeQueries(e,t){let[r]=(0,eX.I6)(e,t),n=this.queryCache;eJ.V.batch(()=>{n.findAll(r).forEach(e=>{n.remove(e)})})}resetQueries(e,t,r){let[n,i]=(0,eX.I6)(e,t,r),s=this.queryCache,o={type:"active",...n};return eJ.V.batch(()=>(s.findAll(n).forEach(e=>{e.reset()}),this.refetchQueries(o,i)))}cancelQueries(e,t,r){let[n,i={}]=(0,eX.I6)(e,t,r);return void 0===i.revert&&(i.revert=!0),Promise.all(eJ.V.batch(()=>this.queryCache.findAll(n).map(e=>e.cancel(i)))).then(eX.ZT).catch(eX.ZT)}invalidateQueries(e,t,r){let[n,i]=(0,eX.I6)(e,t,r);return eJ.V.batch(()=>{var e,t;if(this.queryCache.findAll(n).forEach(e=>{e.invalidate()}),"none"===n.refetchType)return Promise.resolve();let r={...n,type:null!=(e=null!=(t=n.refetchType)?t:n.type)?e:"active"};return this.refetchQueries(r,i)})}refetchQueries(e,t,r){let[n,i]=(0,eX.I6)(e,t,r),s=Promise.all(eJ.V.batch(()=>this.queryCache.findAll(n).filter(e=>!e.isDisabled()).map(e=>{var t;return e.fetch(void 0,{...i,cancelRefetch:null==(t=null==i?void 0:i.cancelRefetch)||t,meta:{refetchPage:n.refetchPage}})}))).then(eX.ZT);return null!=i&&i.throwOnError||(s=s.catch(eX.ZT)),s}fetchQuery(e,t,r){let n=(0,eX._v)(e,t,r),i=this.defaultQueryOptions(n);void 0===i.retry&&(i.retry=!1);let s=this.queryCache.build(this,i);return s.isStaleByTime(i.staleTime)?s.fetch(i):Promise.resolve(s.state.data)}prefetchQuery(e,t,r){return this.fetchQuery(e,t,r).then(eX.ZT).catch(eX.ZT)}fetchInfiniteQuery(e,t,r){let n=(0,eX._v)(e,t,r);return n.behavior=tf(),this.fetchQuery(n)}prefetchInfiniteQuery(e,t,r){return this.fetchInfiniteQuery(e,t,r).then(eX.ZT).catch(eX.ZT)}resumePausedMutations(){return this.mutationCache.resumePausedMutations()}getQueryCache(){return this.queryCache}getMutationCache(){return this.mutationCache}getLogger(){return this.logger}getDefaultOptions(){return this.defaultOptions}setDefaultOptions(e){this.defaultOptions=e}setQueryDefaults(e,t){let r=this.queryDefaults.find(t=>(0,eX.yF)(e)===(0,eX.yF)(t.queryKey));r?r.defaultOptions=t:this.queryDefaults.push({queryKey:e,defaultOptions:t})}getQueryDefaults(e){if(!e)return;let t=this.queryDefaults.find(t=>(0,eX.to)(e,t.queryKey));return null==t?void 0:t.defaultOptions}setMutationDefaults(e,t){let r=this.mutationDefaults.find(t=>(0,eX.yF)(e)===(0,eX.yF)(t.mutationKey));r?r.defaultOptions=t:this.mutationDefaults.push({mutationKey:e,defaultOptions:t})}getMutationDefaults(e){if(!e)return;let t=this.mutationDefaults.find(t=>(0,eX.to)(e,t.mutationKey));return null==t?void 0:t.defaultOptions}defaultQueryOptions(e){if(null!=e&&e._defaulted)return e;let t={...this.defaultOptions.queries,...this.getQueryDefaults(null==e?void 0:e.queryKey),...e,_defaulted:!0};return!t.queryHash&&t.queryKey&&(t.queryHash=(0,eX.Rm)(t.queryKey,t)),void 0===t.refetchOnReconnect&&(t.refetchOnReconnect="always"!==t.networkMode),void 0===t.useErrorBoundary&&(t.useErrorBoundary=!!t.suspense),t}defaultMutationOptions(e){return null!=e&&e._defaulted?e:{...this.defaultOptions.mutations,...this.getMutationDefaults(null==e?void 0:e.mutationKey),...e,_defaulted:!0}}clear(){this.queryCache.clear(),this.mutationCache.clear()}}let tM=e=>e.queryClient??new tP(e.queryClientConfig);function tN(e){let t=e.state.error;if(t instanceof Error&&"TRPCClientError"===t.name){let r={message:t.message,data:t.data,shape:t.shape};return{...e,state:{...e.state,error:r}}}return e}r(34155);let tD=()=>"",tL=/* istanbul ignore file -- @preserve */function(e){let t=tO(e),n=function(e){let{config:t}=e;return n=>{let i=function(e){let t=tO(e),r=em(e=>"useContext"===e||"useUtils"===e?()=>{let e=t.useUtils();return(0,eZ.useMemo)(()=>tS(e),[e])}:t.hasOwnProperty(e)?t[e]:tv(e,t));return{...t,proxy:r}}(e),s=r=>{let[s]=(0,eZ.useState)(()=>{if(r.trpc)return r.trpc;let n=t({}),s=tM(n),o=i.createClient(n);return{abortOnUnmount:n.abortOnUnmount,queryClient:s,trpcClient:o,ssrState:!!e.ssr&&"mounting",ssrContext:null}}),{queryClient:o,trpcClient:a,ssrState:u,ssrContext:l}=s,c=i.useDehydratedState(a,r.pageProps?.trpcState);return eZ.createElement(i.Provider,{abortOnUnmount:s.abortOnUnmount??!1,client:a,queryClient:o,ssrState:u,ssrContext:l},eZ.createElement(eq.aH,{client:o},eZ.createElement(eV,{state:c},eZ.createElement(n,Object.assign({},r)))))};(n.getInitialProps??e.ssr)&&(s.getInitialProps=async i=>{let s=async()=>{if("function"==typeof e.ssr){if("undefined"!=typeof window)return!1;try{return await e.ssr({ctx:i.ctx})}catch(e){return!1}}return e.ssr},o=await s(),a=i.AppTree,u=!!i.Component,l=u?i.ctx:i,c={};if(n.getInitialProps){let e=await n.getInitialProps(i);c={...u?e.pageProps??{}:e,...c}}let d=e=>u?{pageProps:e}:e;if("undefined"!=typeof window||!o)return d(c);let f=t({ctx:l}),h=new ej(f),p=tM(f),m={pageProps:c,trpc:{config:f,trpcClient:h,queryClient:p,ssrState:"prepass",ssrContext:l}},g=await r.e(9774).then(r.t.bind(r,97762,19));for(;g.renderToString((0,eZ.createElement)(a,m)),p.isFetching();)await new Promise(e=>{let t=p.getQueryCache().subscribe(r=>{r?.query.getObserversCount()===0&&(e(),t())})});let y=function(e,t={}){let r=[],n=[];if(!1!==t.dehydrateMutations){let n=t.shouldDehydrateMutation||eW;e.getMutationCache().getAll().forEach(e=>{n(e)&&r.push({mutationKey:e.options.mutationKey,state:e.state})})}if(!1!==t.dehydrateQueries){let r=t.shouldDehydrateQuery||eK;e.getQueryCache().getAll().forEach(e=>{r(e)&&n.push({state:e.state,queryKey:e.queryKey,queryHash:e.queryHash})})}return{mutations:r,queries:n}}(p,{shouldDehydrateQuery:e=>!("idle"===e.state.fetchStatus&&"loading"===e.state.status)}),v={...y,queries:y.queries.map(tN),mutations:y.mutations.map(tN)};c.trpcState=h.runtime.combinedTransformer.output.serialize(v);let _=d(c);if("responseMeta"in e){let t=e.responseMeta?.({ctx:l,clientErrors:[...y.queries,...y.mutations].map(e=>e.state.error).flatMap(e=>e instanceof Error&&"TRPCClientError"===e.name?[e]:[])})??{};for(let[e,r]of Object.entries(t.headers??{}))"string"==typeof r&&l.res?.setHeader(e,r);t.status&&l.res&&(l.res.statusCode=t.status)}return _});let o=n.displayName??n.name??"Component";return s.displayName=`withTRPC(${o})`,s}}(e);return em(e=>"useContext"===e||"useUtils"===e?()=>{let e=t.useUtils();return(0,eZ.useMemo)(()=>tS(e),[e])}:"useQueries"===e?t.useQueries:"withTRPC"===e?n:tv(e,t))}({config:()=>({transformer:eu,links:[function(e={}){let{enabled:t=()=>!0}=e,r=e.colorMode??("undefined"==typeof window?"ansi":"css"),{logger:n=eL({c:e.console,colorMode:r})}=e;return()=>({op:e,next:r})=>el(i=>{var s;t({...e,direction:"up"})&&n({...e,direction:"up"});let o=Date.now();function a(r){let i=Date.now()-o;t({...e,direction:"down",result:r})&&n({...e,direction:"down",elapsedMs:i,result:r})}return r(e).pipe((s={next(e){a(e)},error(e){a(e)}},e=>({subscribe:t=>e.subscribe({next(e){s.next?.(e),t.next?.(e)},error(e){s.error?.(e),t.error?.(e)},complete(){s.complete?.(),t.complete?.()}})}))).subscribe(i)})}({enabled:e=>"down"===e.direction&&e.result instanceof Error}),eM({url:"".concat(tD(),"/api/trpc")})]}),ssr:!1})},89079:function(e){"use strict";var t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,i=Object.prototype.hasOwnProperty,s={};function o(e){var t;let r=["path"in e&&e.path&&`Path=${e.path}`,"expires"in e&&(e.expires||0===e.expires)&&`Expires=${("number"==typeof e.expires?new Date(e.expires):e.expires).toUTCString()}`,"maxAge"in e&&"number"==typeof e.maxAge&&`Max-Age=${e.maxAge}`,"domain"in e&&e.domain&&`Domain=${e.domain}`,"secure"in e&&e.secure&&"Secure","httpOnly"in e&&e.httpOnly&&"HttpOnly","sameSite"in e&&e.sameSite&&`SameSite=${e.sameSite}`,"partitioned"in e&&e.partitioned&&"Partitioned","priority"in e&&e.priority&&`Priority=${e.priority}`].filter(Boolean),n=`${e.name}=${encodeURIComponent(null!=(t=e.value)?t:"")}`;return 0===r.length?n:`${n}; ${r.join("; ")}`}function a(e){let t=new Map;for(let r of e.split(/; */)){if(!r)continue;let e=r.indexOf("=");if(-1===e){t.set(r,"true");continue}let[n,i]=[r.slice(0,e),r.slice(e+1)];try{t.set(n,decodeURIComponent(null!=i?i:"true"))}catch{}}return t}function u(e){var t,r;if(!e)return;let[[n,i],...s]=a(e),{domain:o,expires:u,httponly:d,maxage:f,path:h,samesite:p,secure:m,partitioned:g,priority:y}=Object.fromEntries(s.map(([e,t])=>[e.toLowerCase(),t]));return function(e){let t={};for(let r in e)e[r]&&(t[r]=e[r]);return t}({name:n,value:decodeURIComponent(i),domain:o,...u&&{expires:new Date(u)},...d&&{httpOnly:!0},..."string"==typeof f&&{maxAge:Number(f)},path:h,...p&&{sameSite:l.includes(t=(t=p).toLowerCase())?t:void 0},...m&&{secure:!0},...y&&{priority:c.includes(r=(r=y).toLowerCase())?r:void 0},...g&&{partitioned:!0}})}((e,r)=>{for(var n in r)t(e,n,{get:r[n],enumerable:!0})})(s,{RequestCookies:()=>d,ResponseCookies:()=>f,parseCookie:()=>a,parseSetCookie:()=>u,stringifyCookie:()=>o}),e.exports=((e,s,o,a)=>{if(s&&"object"==typeof s||"function"==typeof s)for(let u of n(s))i.call(e,u)||u===o||t(e,u,{get:()=>s[u],enumerable:!(a=r(s,u))||a.enumerable});return e})(t({},"__esModule",{value:!0}),s);var l=["strict","lax","none"],c=["low","medium","high"],d=class{constructor(e){this._parsed=new Map,this._headers=e;let t=e.get("cookie");if(t)for(let[e,r]of a(t))this._parsed.set(e,{name:e,value:r})}[Symbol.iterator](){return this._parsed[Symbol.iterator]()}get size(){return this._parsed.size}get(...e){let t="string"==typeof e[0]?e[0]:e[0].name;return this._parsed.get(t)}getAll(...e){var t;let r=Array.from(this._parsed);if(!e.length)return r.map(([e,t])=>t);let n="string"==typeof e[0]?e[0]:null==(t=e[0])?void 0:t.name;return r.filter(([e])=>e===n).map(([e,t])=>t)}has(e){return this._parsed.has(e)}set(...e){let[t,r]=1===e.length?[e[0].name,e[0].value]:e,n=this._parsed;return n.set(t,{name:t,value:r}),this._headers.set("cookie",Array.from(n).map(([e,t])=>o(t)).join("; ")),this}delete(e){let t=this._parsed,r=Array.isArray(e)?e.map(e=>t.delete(e)):t.delete(e);return this._headers.set("cookie",Array.from(t).map(([e,t])=>o(t)).join("; ")),r}clear(){return this.delete(Array.from(this._parsed.keys())),this}[Symbol.for("edge-runtime.inspect.custom")](){return`RequestCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`}toString(){return[...this._parsed.values()].map(e=>`${e.name}=${encodeURIComponent(e.value)}`).join("; ")}},f=class{constructor(e){var t,r,n;this._parsed=new Map,this._headers=e;let i=null!=(n=null!=(r=null==(t=e.getSetCookie)?void 0:t.call(e))?r:e.get("set-cookie"))?n:[];for(let e of Array.isArray(i)?i:function(e){if(!e)return[];var t,r,n,i,s,o=[],a=0;function u(){for(;a<e.length&&/\s/.test(e.charAt(a));)a+=1;return a<e.length}for(;a<e.length;){for(t=a,s=!1;u();)if(","===(r=e.charAt(a))){for(n=a,a+=1,u(),i=a;a<e.length&&"="!==(r=e.charAt(a))&&";"!==r&&","!==r;)a+=1;a<e.length&&"="===e.charAt(a)?(s=!0,a=i,o.push(e.substring(t,n)),t=a):a=n+1}else a+=1;(!s||a>=e.length)&&o.push(e.substring(t,e.length))}return o}(i)){let t=u(e);t&&this._parsed.set(t.name,t)}}get(...e){let t="string"==typeof e[0]?e[0]:e[0].name;return this._parsed.get(t)}getAll(...e){var t;let r=Array.from(this._parsed.values());if(!e.length)return r;let n="string"==typeof e[0]?e[0]:null==(t=e[0])?void 0:t.name;return r.filter(e=>e.name===n)}has(e){return this._parsed.has(e)}set(...e){let[t,r,n]=1===e.length?[e[0].name,e[0].value,e[0]]:e,i=this._parsed;return i.set(t,function(e={name:"",value:""}){return"number"==typeof e.expires&&(e.expires=new Date(e.expires)),e.maxAge&&(e.expires=new Date(Date.now()+1e3*e.maxAge)),(null===e.path||void 0===e.path)&&(e.path="/"),e}({name:t,value:r,...n})),function(e,t){for(let[,r]of(t.delete("set-cookie"),e)){let e=o(r);t.append("set-cookie",e)}}(i,this._headers),this}delete(...e){let[t,r,n]="string"==typeof e[0]?[e[0]]:[e[0].name,e[0].path,e[0].domain];return this.set({name:t,path:r,domain:n,value:"",expires:new Date(0)})}[Symbol.for("edge-runtime.inspect.custom")](){return`ResponseCookies ${JSON.stringify(Object.fromEntries(this._parsed))}`}toString(){return[...this._parsed.values()].map(o).join("; ")}}},30462:function(){},77798:function(){},84040:function(e,t){"use strict";function r(e){return new URL(e,"http://n").pathname}function n(e){return/https?:\/\//.test(e)}Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{getPathname:function(){return r},isFullStringUrl:function(){return n}})},47325:function(e,t,r){"use strict";var n;Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{Postpone:function(){return f},createPostponedAbortSignal:function(){return v},createPrerenderState:function(){return l},formatDynamicAPIAccesses:function(){return g},markCurrentScopeAsDynamic:function(){return c},trackDynamicDataAccessed:function(){return d},trackDynamicFetch:function(){return h},usedDynamicAPIs:function(){return m}});let i=(n=r(67294))&&n.__esModule?n:{default:n},s=r(6253),o=r(78984),a=r(84040),u="function"==typeof i.default.unstable_postpone;function l(e){return{isDebugSkeleton:e,dynamicAccesses:[]}}function c(e,t){let r=(0,a.getPathname)(e.urlPathname);if(!e.isUnstableCacheCallback){if(e.dynamicShouldError)throw new o.StaticGenBailoutError(`Route ${r} with \`dynamic = "error"\` couldn't be rendered statically because it used \`${t}\`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering`);if(e.prerenderState)p(e.prerenderState,t,r);else if(e.revalidate=0,e.isStaticGeneration){let n=new s.DynamicServerError(`Route ${r} couldn't be rendered statically because it used ${t}. See more info here: https://nextjs.org/docs/messages/dynamic-server-error`);throw e.dynamicUsageDescription=t,e.dynamicUsageStack=n.stack,n}}}function d(e,t){let r=(0,a.getPathname)(e.urlPathname);if(e.isUnstableCacheCallback)throw Error(`Route ${r} used "${t}" inside a function cached with "unstable_cache(...)". Accessing Dynamic data sources inside a cache scope is not supported. If you need this data inside a cached function use "${t}" outside of the cached function and pass the required dynamic data in as an argument. See more info here: https://nextjs.org/docs/app/api-reference/functions/unstable_cache`);if(e.dynamicShouldError)throw new o.StaticGenBailoutError(`Route ${r} with \`dynamic = "error"\` couldn't be rendered statically because it used \`${t}\`. See more info here: https://nextjs.org/docs/app/building-your-application/rendering/static-and-dynamic#dynamic-rendering`);if(e.prerenderState)p(e.prerenderState,t,r);else if(e.revalidate=0,e.isStaticGeneration){let n=new s.DynamicServerError(`Route ${r} couldn't be rendered statically because it used \`${t}\`. See more info here: https://nextjs.org/docs/messages/dynamic-server-error`);throw e.dynamicUsageDescription=t,e.dynamicUsageStack=n.stack,n}}function f({reason:e,prerenderState:t,pathname:r}){p(t,e,r)}function h(e,t){e.prerenderState&&p(e.prerenderState,t,e.urlPathname)}function p(e,t,r){y();let n=`Route ${r} needs to bail out of prerendering at this point because it used ${t}. React throws this special object to indicate where. It should not be caught by your own try/catch. Learn more: https://nextjs.org/docs/messages/ppr-caught-error`;e.dynamicAccesses.push({stack:e.isDebugSkeleton?Error().stack:void 0,expression:t}),i.default.unstable_postpone(n)}function m(e){return e.dynamicAccesses.length>0}function g(e){return e.dynamicAccesses.filter(e=>"string"==typeof e.stack&&e.stack.length>0).map(({expression:e,stack:t})=>(t=t.split("\n").slice(4).filter(e=>!(e.includes("node_modules/next/")||e.includes(" (<anonymous>)")||e.includes(" (node:"))).join("\n"),`Dynamic API Usage Debug - ${e}:
${t}`))}function y(){if(!u)throw Error("Invariant: React.unstable_postpone is not defined. This suggests the wrong version of React was loaded. This is a bug in Next.js")}function v(e){y();let t=new AbortController;try{i.default.unstable_postpone(e)}catch(e){t.abort(e)}return t.signal}},34042:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{HeadersAdapter:function(){return s},ReadonlyHeadersError:function(){return i}});let n=r(47246);class i extends Error{constructor(){super("Headers cannot be modified. Read more: https://nextjs.org/docs/app/api-reference/functions/headers")}static callable(){throw new i}}class s extends Headers{constructor(e){super(),this.headers=new Proxy(e,{get(t,r,i){if("symbol"==typeof r)return n.ReflectAdapter.get(t,r,i);let s=r.toLowerCase(),o=Object.keys(e).find(e=>e.toLowerCase()===s);if(void 0!==o)return n.ReflectAdapter.get(t,o,i)},set(t,r,i,s){if("symbol"==typeof r)return n.ReflectAdapter.set(t,r,i,s);let o=r.toLowerCase(),a=Object.keys(e).find(e=>e.toLowerCase()===o);return n.ReflectAdapter.set(t,a??r,i,s)},has(t,r){if("symbol"==typeof r)return n.ReflectAdapter.has(t,r);let i=r.toLowerCase(),s=Object.keys(e).find(e=>e.toLowerCase()===i);return void 0!==s&&n.ReflectAdapter.has(t,s)},deleteProperty(t,r){if("symbol"==typeof r)return n.ReflectAdapter.deleteProperty(t,r);let i=r.toLowerCase(),s=Object.keys(e).find(e=>e.toLowerCase()===i);return void 0===s||n.ReflectAdapter.deleteProperty(t,s)}})}static seal(e){return new Proxy(e,{get(e,t,r){switch(t){case"append":case"delete":case"set":return i.callable;default:return n.ReflectAdapter.get(e,t,r)}}})}merge(e){return Array.isArray(e)?e.join(", "):e}static from(e){return e instanceof Headers?e:new s(e)}append(e,t){let r=this.headers[e];"string"==typeof r?this.headers[e]=[r,t]:Array.isArray(r)?r.push(t):this.headers[e]=t}delete(e){delete this.headers[e]}get(e){let t=this.headers[e];return void 0!==t?this.merge(t):null}has(e){return void 0!==this.headers[e]}set(e,t){this.headers[e]=t}forEach(e,t){for(let[r,n]of this.entries())e.call(t,n,r,this)}*entries(){for(let e of Object.keys(this.headers)){let t=e.toLowerCase(),r=this.get(t);yield[t,r]}}*keys(){for(let e of Object.keys(this.headers)){let t=e.toLowerCase();yield t}}*values(){for(let e of Object.keys(this.headers)){let t=this.get(e);yield t}}[Symbol.iterator](){return this.entries()}}},47246:function(e,t){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"ReflectAdapter",{enumerable:!0,get:function(){return r}});class r{static get(e,t,r){let n=Reflect.get(e,t,r);return"function"==typeof n?n.bind(e):n}static set(e,t,r,n){return Reflect.set(e,t,r,n)}static has(e,t){return Reflect.has(e,t)}static deleteProperty(e,t){return Reflect.deleteProperty(e,t)}}},9407:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{MutableRequestCookiesAdapter:function(){return d},ReadonlyRequestCookiesError:function(){return o},RequestCookiesAdapter:function(){return a},appendMutableCookies:function(){return c},getModifiedCookieValues:function(){return l}});let n=r(80255),i=r(47246),s=r(34916);class o extends Error{constructor(){super("Cookies can only be modified in a Server Action or Route Handler. Read more: https://nextjs.org/docs/app/api-reference/functions/cookies#cookiessetname-value-options")}static callable(){throw new o}}class a{static seal(e){return new Proxy(e,{get(e,t,r){switch(t){case"clear":case"delete":case"set":return o.callable;default:return i.ReflectAdapter.get(e,t,r)}}})}}let u=Symbol.for("next.mutated.cookies");function l(e){let t=e[u];return t&&Array.isArray(t)&&0!==t.length?t:[]}function c(e,t){let r=l(t);if(0===r.length)return!1;let i=new n.ResponseCookies(e),s=i.getAll();for(let e of r)i.set(e);for(let e of s)i.set(e);return!0}class d{static wrap(e,t){let r=new n.ResponseCookies(new Headers);for(let t of e.getAll())r.set(t);let o=[],a=new Set,l=()=>{let e=s.staticGenerationAsyncStorage.getStore();if(e&&(e.pathWasRevalidated=!0),o=r.getAll().filter(e=>a.has(e.name)),t){let e=[];for(let t of o){let r=new n.ResponseCookies(new Headers);r.set(t),e.push(r.toString())}t(e)}};return new Proxy(r,{get(e,t,r){switch(t){case u:return o;case"delete":return function(...t){a.add("string"==typeof t[0]?t[0]:t[0].name);try{e.delete(...t)}finally{l()}};case"set":return function(...t){a.add("string"==typeof t[0]?t[0]:t[0].name);try{return e.set(...t)}finally{l()}};default:return i.ReflectAdapter.get(e,t,r)}}})}}},80255:function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{RequestCookies:function(){return n.RequestCookies},ResponseCookies:function(){return n.ResponseCookies}});let n=r(89079)},9008:function(e,t,r){e.exports=r(7828)},14970:function(e,t,r){e.exports=r(89383)},25675:function(e,t,r){e.exports=r(35666)},41664:function(e,t,r){e.exports=r(89577)},39332:function(e,t,r){e.exports=r(70827)},11163:function(e,t,r){e.exports=r(9090)},4298:function(e,t,r){e.exports=r(32892)},34155:function(e){var t,r,n,i=e.exports={};function s(){throw Error("setTimeout has not been defined")}function o(){throw Error("clearTimeout has not been defined")}function a(e){if(t===setTimeout)return setTimeout(e,0);if((t===s||!t)&&setTimeout)return t=setTimeout,setTimeout(e,0);try{return t(e,0)}catch(r){try{return t.call(null,e,0)}catch(r){return t.call(this,e,0)}}}!function(){try{t="function"==typeof setTimeout?setTimeout:s}catch(e){t=s}try{r="function"==typeof clearTimeout?clearTimeout:o}catch(e){r=o}}();var u=[],l=!1,c=-1;function d(){l&&n&&(l=!1,n.length?u=n.concat(u):c=-1,u.length&&f())}function f(){if(!l){var e=a(d);l=!0;for(var t=u.length;t;){for(n=u,u=[];++c<t;)n&&n[c].run();c=-1,t=u.length}n=null,l=!1,function(e){if(r===clearTimeout)return clearTimeout(e);if((r===o||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(e);try{r(e)}catch(t){try{return r.call(null,e)}catch(t){return r.call(this,e)}}}(e)}}function h(e,t){this.fun=e,this.array=t}function p(){}i.nextTick=function(e){var t=Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];u.push(new h(e,t)),1!==u.length||l||a(f)},h.prototype.run=function(){this.fun.apply(null,this.array)},i.title="browser",i.browser=!0,i.env={},i.argv=[],i.version="",i.versions={},i.on=p,i.addListener=p,i.once=p,i.off=p,i.removeListener=p,i.removeAllListeners=p,i.emit=p,i.prependListener=p,i.prependOnceListener=p,i.listeners=function(e){return[]},i.binding=function(e){throw Error("process.binding is not supported")},i.cwd=function(){return"/"},i.chdir=function(e){throw Error("process.chdir is not supported")},i.umask=function(){return 0}},69921:function(e,t){"use strict";/** @license React v16.13.1
 * react-is.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var r="function"==typeof Symbol&&Symbol.for,n=r?Symbol.for("react.element"):60103,i=r?Symbol.for("react.portal"):60106,s=r?Symbol.for("react.fragment"):60107,o=r?Symbol.for("react.strict_mode"):60108,a=r?Symbol.for("react.profiler"):60114,u=r?Symbol.for("react.provider"):60109,l=r?Symbol.for("react.context"):60110,c=r?Symbol.for("react.async_mode"):60111,d=r?Symbol.for("react.concurrent_mode"):60111,f=r?Symbol.for("react.forward_ref"):60112,h=r?Symbol.for("react.suspense"):60113,p=r?Symbol.for("react.suspense_list"):60120,m=r?Symbol.for("react.memo"):60115,g=r?Symbol.for("react.lazy"):60116,y=r?Symbol.for("react.block"):60121,v=r?Symbol.for("react.fundamental"):60117,_=r?Symbol.for("react.responder"):60118,b=r?Symbol.for("react.scope"):60119;function S(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case n:switch(e=e.type){case c:case d:case s:case a:case o:case h:return e;default:switch(e=e&&e.$$typeof){case l:case f:case g:case m:case u:return e;default:return t}}case i:return t}}}function E(e){return S(e)===d}t.AsyncMode=c,t.ConcurrentMode=d,t.ContextConsumer=l,t.ContextProvider=u,t.Element=n,t.ForwardRef=f,t.Fragment=s,t.Lazy=g,t.Memo=m,t.Portal=i,t.Profiler=a,t.StrictMode=o,t.Suspense=h,t.isAsyncMode=function(e){return E(e)||S(e)===c},t.isConcurrentMode=E,t.isContextConsumer=function(e){return S(e)===l},t.isContextProvider=function(e){return S(e)===u},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===n},t.isForwardRef=function(e){return S(e)===f},t.isFragment=function(e){return S(e)===s},t.isLazy=function(e){return S(e)===g},t.isMemo=function(e){return S(e)===m},t.isPortal=function(e){return S(e)===i},t.isProfiler=function(e){return S(e)===a},t.isStrictMode=function(e){return S(e)===o},t.isSuspense=function(e){return S(e)===h},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===s||e===d||e===a||e===o||e===h||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===g||e.$$typeof===m||e.$$typeof===u||e.$$typeof===l||e.$$typeof===f||e.$$typeof===v||e.$$typeof===_||e.$$typeof===b||e.$$typeof===y)},t.typeOf=S},59864:function(e,t,r){"use strict";e.exports=r(69921)},53250:function(e,t,r){"use strict";/**
 * @license React
 * use-sync-external-store-shim.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var n=r(67294),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=n.useState,o=n.useEffect,a=n.useLayoutEffect,u=n.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!i(e,r)}catch(e){return!0}}var c="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var r=t(),n=s({inst:{value:r,getSnapshot:t}}),i=n[0].inst,c=n[1];return a(function(){i.value=r,i.getSnapshot=t,l(i)&&c({inst:i})},[e,r,t]),o(function(){return l(i)&&c({inst:i}),e(function(){l(i)&&c({inst:i})})},[e]),u(r),r};t.useSyncExternalStore=void 0!==n.useSyncExternalStore?n.useSyncExternalStore:c},61688:function(e,t,r){"use strict";e.exports=r(53250)},26849:function(e,t,r){"use strict";/**
 * @license React
 * use-sync-external-store-shim.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var n=r(67294),i="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},s=n.useState,o=n.useEffect,a=n.useLayoutEffect,u=n.useDebugValue;function l(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!i(e,r)}catch(e){return!0}}var c="undefined"==typeof window||void 0===window.document||void 0===window.document.createElement?function(e,t){return t()}:function(e,t){var r=t(),n=s({inst:{value:r,getSnapshot:t}}),i=n[0].inst,c=n[1];return a(function(){i.value=r,i.getSnapshot=t,l(i)&&c({inst:i})},[e,r,t]),o(function(){return l(i)&&c({inst:i}),e(function(){l(i)&&c({inst:i})})},[e]),u(r),r};t.useSyncExternalStore=void 0!==n.useSyncExternalStore?n.useSyncExternalStore:c},49743:function(e,t,r){"use strict";/**
 * @license React
 * use-sync-external-store-shim/with-selector.production.min.js
 *
 * Copyright (c) Facebook, Inc. and its affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 */var n=r(67294),i=r(54652),s="function"==typeof Object.is?Object.is:function(e,t){return e===t&&(0!==e||1/e==1/t)||e!=e&&t!=t},o=i.useSyncExternalStore,a=n.useRef,u=n.useEffect,l=n.useMemo,c=n.useDebugValue;t.useSyncExternalStoreWithSelector=function(e,t,r,n,i){var d=a(null);if(null===d.current){var f={hasValue:!1,value:null};d.current=f}else f=d.current;var h=o(e,(d=l(function(){function e(e){if(!u){if(u=!0,o=e,e=n(e),void 0!==i&&f.hasValue){var t=f.value;if(i(t,e))return a=t}return a=e}if(t=a,s(o,e))return t;var r=n(e);return void 0!==i&&i(t,r)?t:(o=e,a=r)}var o,a,u=!1,l=void 0===r?null:r;return[function(){return e(t())},null===l?void 0:function(){return e(l())}]},[t,r,n,i]))[0],d[1]);return u(function(){f.hasValue=!0,f.value=h},[h]),c(h),h}},54652:function(e,t,r){"use strict";e.exports=r(26849)},28258:function(e,t,r){"use strict";e.exports=r(49743)},71624:function(e,t,r){"use strict";r.d(t,{Vo:function(){return O},iz:function(){return T},Cv:function(){return K},CH:function(){return Z},tj:function(){return W},iv:function(){return E},wE:function(){return S},Gl:function(){return j},oG:function(){return L},E7:function(){return D},RM:function(){return h},RE:function(){return B},YJ:function(){return b},tF:function(){return R},KQ:function(){return I},Gv:function(){return U},Rl:function(){return N},ej:function(){return M},JM:function(){return p},qq:function(){return x},cL:function(){return f.cL},o8:function(){return f.o8},eW:function(){return f.eW},kP:function(){return f.kP},aF:function(){return f.aF},Mp:function(){return P},ge:function(){return A},r0:function(){return q}});var n,i,s,o,a=r(92873),u=(r(58153),r(1709));async function l(e="",t){let{async:r,defer:n,beforeLoad:i,crossOrigin:s}=t||{};return new Promise((t,o)=>{e||o("loadScript cannot be called without a src"),document&&document.body||o("loadScript cannot be called when document does not exist");let a=document.createElement("script");s&&a.setAttribute("crossorigin",s),a.async=r||!1,a.defer=n||!1,a.addEventListener("load",()=>{a.remove(),t(a)}),a.addEventListener("error",()=>{a.remove(),o()}),a.src=e,null==i||i(a),document.body.appendChild(a)})}function c(e){return e.startsWith("/")}var d=r(67294),f=r(66763);r(22671),r(34155),new WeakMap,new WeakMap,new WeakSet,new WeakMap,new WeakMap,new WeakMap,new WeakMap,new WeakMap,new WeakSet;var h=(0,a.t5)({packageName:"@clerk/clerk-react"});function p(e){h.setMessages(e).setPackageName(e)}var{isDevOrStagingUrl:m}=(0,u.MY)(),g=(e,t="5.2.7")=>{if(e)return e;let r=y(t);return r?"snapshot"===r?"5.8.0":r:v(t)},y=e=>{var t;return null==(t=e.trim().replace(/^v/,"").match(/-(.+?)(\.|$)/))?void 0:t[1]},v=e=>e.trim().replace(/^v/,"").split(".")[0],_="Clerk: Failed to load Clerk",b=e=>{let{publishableKey:t}=e;t||h.throwMissingPublishableKeyError();let r=document.querySelector("script[data-clerk-js-script]");return r?new Promise((e,t)=>{r.addEventListener("load",()=>{e(r)}),r.addEventListener("error",()=>{t(_)})}):l(S(e),{async:!0,crossOrigin:"anonymous",beforeLoad:w(e)}).catch(()=>{throw Error(_)})},S=e=>{var t,r;let{clerkJSUrl:n,clerkJSVariant:i,clerkJSVersion:s,proxyUrl:o,domain:a,publishableKey:l}=e;if(n)return n;let d="";d=o&&(!o||/^http(s)?:\/\//.test(o||"")||c(o))?(o?c(o)?new URL(o,window.location.origin).toString():o:"").replace(/http(s)?:\/\//,""):a&&!m((null==(t=(0,u.nQ)(l))?void 0:t.frontendApi)||"")?function(e){let t;if(!e)return"";if(e.match(/^(clerk\.)+\w*$/))t=/(clerk\.)*(?=clerk\.)/;else{if(e.match(/\.clerk.accounts/))return e;t=/^(clerk\.)*/gi}let r=e.replace(t,"");return`clerk.${r}`}(a):(null==(r=(0,u.nQ)(l))?void 0:r.frontendApi)||"";let f=i?`${i.replace(/\.+$/,"")}.`:"",h=g(s);return`https://${d}/npm/@clerk/clerk-js@${h}/dist/clerk.${f}browser.js`},E=e=>{let t={};return e.publishableKey&&(t["data-clerk-publishable-key"]=e.publishableKey),e.proxyUrl&&(t["data-clerk-proxy-url"]=e.proxyUrl),e.domain&&(t["data-clerk-domain"]=e.domain),t},w=e=>t=>{let r=E(e);for(let e in r)t.setAttribute(e,r[e])},[O,k]=(0,f.uH)("AuthContext"),T=f.b5,C=f.rI,I="You've added multiple <ClerkProvider> components in your React component tree. Wrap your components in a single <ClerkProvider>.",R=e=>`You've passed multiple children components to <${e}/>. You can only pass a single child component or text.`,x="Unsupported usage of isSatellite, domain or proxyUrl. The usage of isSatellite, domain or proxyUrl as function is not supported in non-browser environments.",A="<UserProfile.Page /> component needs to be a direct child of `<UserProfile />` or `<UserButton />`.",P="<UserProfile.Link /> component needs to be a direct child of `<UserProfile />` or `<UserButton />`.",M="<OrganizationProfile.Page /> component needs to be a direct child of `<OrganizationProfile />` or `<OrganizationSwitcher />`.",N="<OrganizationProfile.Link /> component needs to be a direct child of `<OrganizationProfile />` or `<OrganizationSwitcher />`.",D=e=>`<${e} /> can only accept <${e}.Page /> and <${e}.Link /> as its children. Any other provided component will be ignored.`,L=e=>`Missing props. <${e}.Page /> component requires the following props: url, label, labelIcon, alongside with children to be rendered inside the page.`,j=e=>`Missing props. <${e}.Link /> component requires the following props: url, label and labelIcon.`,U=e=>`The <${e}/> component uses path-based routing by default unless a different routing strategy is provided using the \`routing\` prop. When path-based routing is used, you need to provide the path where the component is mounted on by using the \`path\` prop. Example: <${e} path={'/my-path'} />`,B=e=>`The \`path\` prop will only be respected when the Clerk component uses path-based routing. To resolve this error, pass \`routing='path'\` to the <${e}/> component, or drop the \`path\` prop to switch to hash-based routing. For more details please refer to our docs: https://clerk.com/docs`,F=e=>{(0,f.Rm)(()=>{h.throwMissingClerkProviderError({source:e})})},$=e=>new Promise(t=>{e.loaded&&t(),e.addOnLoaded(t)}),z=e=>async t=>(await $(e),e.session)?e.session.getToken(t):null,H=e=>async(...t)=>(await $(e),e.signOut(...t)),G=()=>{F("useAuth");let{sessionId:e,userId:t,actor:r,orgId:n,orgRole:i,orgSlug:s,orgPermissions:o}=k(),a=C(),u=(0,d.useCallback)(z(a),[a]),l=(0,d.useCallback)(H(a),[a]),c=(0,d.useCallback)(e=>((null==e?void 0:e.permission)||(null==e?void 0:e.role)||h.throw('Missing parameters. `has` from `useAuth` requires a permission or role key to be passed. Example usage: `has({permission: "org:posts:edit"`'),!!n&&!!t&&!!i&&!!o&&(e.permission?o.includes(e.permission):!!e.role&&i===e.role)),[n,i,t,o]);return void 0===e&&void 0===t?{isLoaded:!1,isSignedIn:void 0,sessionId:e,userId:t,actor:void 0,orgId:void 0,orgRole:void 0,orgSlug:void 0,has:void 0,signOut:l,getToken:u}:null===e&&null===t?{isLoaded:!0,isSignedIn:!1,sessionId:e,userId:t,actor:null,orgId:null,orgRole:null,orgSlug:null,has:()=>!1,signOut:l,getToken:u}:e&&t&&n&&i?{isLoaded:!0,isSignedIn:!0,sessionId:e,userId:t,actor:r||null,orgId:n,orgRole:i,orgSlug:s||null,has:c,signOut:l,getToken:u}:e&&t&&!n?{isLoaded:!0,isSignedIn:!0,sessionId:e,userId:t,actor:r||null,orgId:null,orgRole:null,orgSlug:null,has:()=>!1,signOut:l,getToken:u}:h.throw("Invalid state. Feel free to submit a bug or reach out to support here: https://clerk.com/support")},q=(e,t)=>{t=t||e.displayName||e.name||"Component",e.displayName=t;let r=r=>{F(t||"withClerk");let n=C();return n.loaded?d.createElement(e,{...r,clerk:n}):null};return r.displayName=`withClerk(${t})`,r},Z=({children:e})=>{F("SignedIn");let{userId:t}=k();return t?d.createElement(d.Fragment,null,e):null},W=({children:e})=>{F("SignedOut");let{userId:t}=k();return null===t?d.createElement(d.Fragment,null,e):null},K=({children:e,fallback:t,...r})=>{F("Protect");let{isLoaded:n,has:i,userId:s}=G();if(!n)return null;let o=d.createElement(d.Fragment,null,null!=t?t:null),a=d.createElement(d.Fragment,null,e);return s?"function"==typeof r.condition?r.condition(i)?a:o:r.role||r.permission?i(r)?a:o:a:o};q(({clerk:e,...t})=>{let{client:r,session:n}=e,i=r.activeSessions&&r.activeSessions.length>0;return d.useEffect(()=>{null===n&&i?e.redirectToAfterSignOut():e.redirectToSignIn(t)},[]),null},"RedirectToSignIn"),q(({clerk:e,...t})=>(d.useEffect(()=>{e.redirectToSignUp(t)},[]),null),"RedirectToSignUp"),q(({clerk:e})=>(d.useEffect(()=>{e.redirectToUserProfile()},[]),null),"RedirectToUserProfile"),q(({clerk:e})=>(d.useEffect(()=>{e.redirectToOrganizationProfile()},[]),null),"RedirectToOrganizationProfile"),q(({clerk:e})=>(d.useEffect(()=>{e.redirectToCreateOrganization()},[]),null),"RedirectToCreateOrganization"),q(({clerk:e,...t})=>(d.useEffect(()=>{e.handleRedirectCallback(t)},[]),null),"AuthenticateWithRedirectCallback")},76599:function(e,t,r){"use strict";r.d(t,{El:function(){return es},Gp:function(){return Q},A:function(){return V},Li:function(){return X},Cv:function(){return c.Cv},cL:function(){return $},Mo:function(){return z},CH:function(){return c.CH},tj:function(){return c.tj},l8:function(){return Z},Iw:function(){return q},ll:function(){return c.cL},o8:function(){return c.o8},eW:function(){return c.eW},kP:function(){return c.kP},aF:function(){return c.aF}});var n,i,s,o,a,u,l,c=r(71624),d=e=>{throw TypeError(e)},f=(e,t,r)=>t.has(e)||d("Cannot "+r),h=(e,t,r)=>(f(e,t,"read from private field"),r?r.call(e):t.get(e)),p=(e,t,r)=>t.has(e)?d("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),m=(e,t,r,n)=>(f(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),g=(e,t,r)=>(f(e,t,"access private method"),r),y=(e,...t)=>{let r={...e};for(let e of t)delete r[e];return r};function v(){return"undefined"!=typeof window}r(22671),r(92873),Object.freeze({"image/png":"png","image/jpeg":"jpg","image/gif":"gif","image/webp":"webp","image/x-icon":"ico","image/vnd.microsoft.icon":"ico"}),RegExp("bot|spider|crawl|APIs-Google|AdsBot|Googlebot|mediapartners|Google Favicon|FeedFetcher|Google-Read-Aloud|DuplexWeb-Google|googleweblight|bing|yandex|baidu|duckduck|yahoo|ecosia|ia_archiver|facebook|instagram|pinterest|reddit|slack|twitter|whatsapp|youtube|semrush","i");var _=()=>!1;r(58153);var b=e=>{_()&&console.error(`Clerk: ${e}`)},S=r(66763),E=r(67294),w=r(73935),O=r(1709);function k(e,t,r){return"function"==typeof e?e(t):void 0!==e?e:void 0!==r?r:void 0}"undefined"==typeof window||window.global||(window.global="undefined"==typeof global?window:global);var T=e=>t=>{try{return E.Children.only(e)}catch(e){return c.RM.throw((0,c.tF)(t))}},C=(e,t)=>(e||(e=t),"string"==typeof e&&(e=E.createElement("button",null,e)),e),I=e=>(...t)=>{if(e&&"function"==typeof e)return e(...t)},R=new Map,x=e=>{let t=Array(e.length).fill(null),[r,n]=(0,E.useState)(t);return e.map((e,t)=>({id:e.id,mount:e=>n(r=>r.map((r,n)=>n===t?e:r)),unmount:()=>n(e=>e.map((e,r)=>r===t?null:e)),portal:()=>E.createElement(E.Fragment,null,r[t]?(0,w.createPortal)(e.component,r[t]):null)}))},A=(e,t)=>!!e&&E.isValidElement(e)&&(null==e?void 0:e.type)===t,P=e=>N({children:e,reorderItemsLabels:["account","security"],LinkComponent:G,PageComponent:H,componentName:"UserProfile"}),M=e=>N({children:e,reorderItemsLabels:["general","members"],LinkComponent:K,PageComponent:W,componentName:"OrganizationProfile"}),N=({children:e,LinkComponent:t,PageComponent:r,reorderItemsLabels:n,componentName:i})=>{let s=[];E.Children.forEach(e,e=>{if(!A(e,r)&&!A(e,t)){e&&b((0,c.E7)(i));return}let{props:o}=e,{children:a,label:u,url:l,labelIcon:d}=o;if(A(e,r)){if(D(o,n))s.push({label:u});else if(L(o))s.push({label:u,labelIcon:d,children:a,url:l});else{b((0,c.oG)(i));return}}if(A(e,t)){if(j(o))s.push({label:u,labelIcon:d,url:l});else{b((0,c.Gl)(i));return}}});let o=[],a=[],u=[];s.forEach((e,t)=>{if(L(e)){o.push({component:e.children,id:t}),a.push({component:e.labelIcon,id:t});return}j(e)&&u.push({component:e.labelIcon,id:t})});let l=x(o),d=x(a),f=x(u),h=[],p=[];return s.forEach((e,t)=>{if(D(e,n)){h.push({label:e.label});return}if(L(e)){let{portal:r,mount:n,unmount:i}=l.find(e=>e.id===t),{portal:s,mount:o,unmount:a}=d.find(e=>e.id===t);h.push({label:e.label,url:e.url,mount:n,unmount:i,mountIcon:o,unmountIcon:a}),p.push(r),p.push(s);return}if(j(e)){let{portal:r,mount:n,unmount:i}=f.find(e=>e.id===t);h.push({label:e.label,url:e.url,mountIcon:n,unmountIcon:i}),p.push(r);return}}),{customPages:h,customPagesPortals:p}},D=(e,t)=>{let{children:r,label:n,url:i,labelIcon:s}=e;return!r&&!i&&!s&&t.some(e=>e===n)},L=e=>{let{children:t,label:r,url:n,labelIcon:i}=e;return!!t&&!!n&&!!i&&!!r},j=e=>{let{children:t,label:r,url:n,labelIcon:i}=e;return!t&&!!n&&!!i&&!!r},U=e=>"mount"in e,B=e=>"open"in e,F=class extends E.PureComponent{constructor(){super(...arguments),this.portalRef=E.createRef()}componentDidUpdate(e){var t,r;if(!U(e)||!U(this.props))return;let n=y(e.props,"customPages","children"),i=y(this.props.props,"customPages","children"),s=(null==(t=n.customPages)?void 0:t.length)!==(null==(r=i.customPages)?void 0:r.length);(!(0,S.c1)(n,i)||s)&&this.props.updateProps({node:this.portalRef.current,props:this.props.props})}componentDidMount(){this.portalRef.current&&(U(this.props)&&this.props.mount(this.portalRef.current,this.props.props),B(this.props)&&this.props.open(this.props.props))}componentWillUnmount(){this.portalRef.current&&(U(this.props)&&this.props.unmount(this.portalRef.current),B(this.props)&&this.props.close())}render(){var e,t;return E.createElement(E.Fragment,null,E.createElement("div",{ref:this.portalRef}),U(this.props)&&(null==(t=null==(e=this.props)?void 0:e.customPagesPortals)?void 0:t.map((e,t)=>(0,E.createElement)(e,{key:t}))))}},$=(0,c.r0)(({clerk:e,...t})=>E.createElement(F,{mount:e.mountSignIn,unmount:e.unmountSignIn,updateProps:e.__unstable__updateProps,props:t}),"SignIn"),z=(0,c.r0)(({clerk:e,...t})=>E.createElement(F,{mount:e.mountSignUp,unmount:e.unmountSignUp,updateProps:e.__unstable__updateProps,props:t}),"SignUp");function H({children:e}){return b(c.ge),E.createElement(E.Fragment,null,e)}function G({children:e}){return b(c.Mp),E.createElement(E.Fragment,null,e)}var q=Object.assign((0,c.r0)(({clerk:e,...t})=>{let{customPages:r,customPagesPortals:n}=P(t.children);return E.createElement(F,{mount:e.mountUserProfile,unmount:e.unmountUserProfile,updateProps:e.__unstable__updateProps,props:{...t,customPages:r},customPagesPortals:n})},"UserProfile"),{Page:H,Link:G}),Z=Object.assign((0,c.r0)(({clerk:e,...t})=>{let{customPages:r,customPagesPortals:n}=P(t.children),i=Object.assign(t.userProfileProps||{},{customPages:r});return E.createElement(F,{mount:e.mountUserButton,unmount:e.unmountUserButton,updateProps:e.__unstable__updateProps,props:{...t,userProfileProps:i},customPagesPortals:n})},"UserButton"),{UserProfilePage:H,UserProfileLink:G});function W({children:e}){return b(c.ej),E.createElement(E.Fragment,null,e)}function K({children:e}){return b(c.Rl),E.createElement(E.Fragment,null,e)}var V=Object.assign((0,c.r0)(({clerk:e,...t})=>{let{customPages:r,customPagesPortals:n}=M(t.children);return E.createElement(F,{mount:e.mountOrganizationProfile,unmount:e.unmountOrganizationProfile,updateProps:e.__unstable__updateProps,props:{...t,customPages:r},customPagesPortals:n})},"OrganizationProfile"),{Page:W,Link:K}),Q=(0,c.r0)(({clerk:e,...t})=>E.createElement(F,{mount:e.mountCreateOrganization,unmount:e.unmountCreateOrganization,updateProps:e.__unstable__updateProps,props:t}),"CreateOrganization"),X=Object.assign((0,c.r0)(({clerk:e,...t})=>{let{customPages:r,customPagesPortals:n}=M(t.children),i=Object.assign(t.organizationProfileProps||{},{customPages:r});return E.createElement(F,{mount:e.mountOrganizationSwitcher,unmount:e.unmountOrganizationSwitcher,updateProps:e.__unstable__updateProps,props:{...t,organizationProfileProps:i},customPagesPortals:n})},"OrganizationSwitcher"),{OrganizationProfilePage:W,OrganizationProfileLink:K});(0,c.r0)(({clerk:e,...t})=>E.createElement(F,{mount:e.mountOrganizationList,unmount:e.unmountOrganizationList,updateProps:e.__unstable__updateProps,props:t}),"OrganizationList"),(0,c.r0)(({clerk:e,...t})=>E.createElement(F,{open:e.openGoogleOneTap,close:e.closeGoogleOneTap,props:t}),"GoogleOneTap"),(0,c.r0)(({clerk:e,children:t,...r})=>{let{signUpFallbackRedirectUrl:n,forceRedirectUrl:i,fallbackRedirectUrl:s,signUpForceRedirectUrl:o,mode:a,...u}=r,l=T(t=C(t,"Sign in"))("SignInButton"),c=()=>{let t={forceRedirectUrl:i,fallbackRedirectUrl:s,signUpFallbackRedirectUrl:n,signUpForceRedirectUrl:o};return"modal"===a?e.openSignIn(t):e.redirectToSignIn({...t,signInFallbackRedirectUrl:s,signInForceRedirectUrl:i})},d=async e=>(l&&"object"==typeof l&&"props"in l&&await I(l.props.onClick)(e),c()),f={...u,onClick:d};return E.cloneElement(l,f)},"SignInButton"),(0,c.r0)(({clerk:e,children:t,...r})=>{let{fallbackRedirectUrl:n,forceRedirectUrl:i,signInFallbackRedirectUrl:s,signInForceRedirectUrl:o,mode:a,unsafeMetadata:u,...l}=r,c=T(t=C(t,"Sign up"))("SignUpButton"),d=()=>{let t={fallbackRedirectUrl:n,forceRedirectUrl:i,signInFallbackRedirectUrl:s,signInForceRedirectUrl:o,unsafeMetadata:u};return"modal"===a?e.openSignUp(t):e.redirectToSignUp({...t,signUpFallbackRedirectUrl:n,signUpForceRedirectUrl:i})},f=async e=>(c&&"object"==typeof c&&"props"in c&&await I(c.props.onClick)(e),d()),h={...l,onClick:f};return E.cloneElement(c,h)},"SignUpButton"),(0,c.r0)(({clerk:e,children:t,...r})=>{let{redirectUrl:n="/",signOutOptions:i,...s}=r,o=T(t=C(t,"Sign out"))("SignOutButton"),a=()=>e.signOut({redirectUrl:n}),u=async e=>(await I(o.props.onClick)(e),a()),l={...s,onClick:u};return E.cloneElement(o,l)},"SignOutButton"),(0,c.r0)(({clerk:e,children:t,...r})=>{let{redirectUrl:n,...i}=r,s=T(t=C(t,"Sign in with Metamask"))("SignInWithMetamaskButton"),o=async()=>{(async function(){await e.authenticateWithMetamask({redirectUrl:n||void 0})})()},a=async e=>(await I(s.props.onClick)(e),o()),u={...i,onClick:a};return E.cloneElement(s,u)},"SignInWithMetamask");var J={name:"@clerk/clerk-react",version:"5.2.7",environment:"production"},Y=class e{constructor(e){p(this,u),this.clerkjs=null,this.preopenOneTap=null,this.preopenSignIn=null,this.preopenSignUp=null,this.preopenUserProfile=null,this.preopenOrganizationProfile=null,this.preopenCreateOrganization=null,this.premountSignInNodes=new Map,this.premountSignUpNodes=new Map,this.premountUserProfileNodes=new Map,this.premountUserButtonNodes=new Map,this.premountOrganizationProfileNodes=new Map,this.premountCreateOrganizationNodes=new Map,this.premountOrganizationSwitcherNodes=new Map,this.premountOrganizationListNodes=new Map,this.premountMethodCalls=new Map,this.loadedListeners=[],p(this,n,!1),p(this,i),p(this,s),p(this,o),this.buildSignInUrl=e=>{let t=()=>{var t;return(null==(t=this.clerkjs)?void 0:t.buildSignInUrl(e))||""};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("buildSignInUrl",t)},this.buildSignUpUrl=e=>{let t=()=>{var t;return(null==(t=this.clerkjs)?void 0:t.buildSignUpUrl(e))||""};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("buildSignUpUrl",t)},this.buildAfterSignInUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildAfterSignInUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildAfterSignInUrl",e)},this.buildAfterSignUpUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildAfterSignUpUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildAfterSignUpUrl",e)},this.buildAfterSignOutUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildAfterSignOutUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildAfterSignOutUrl",e)},this.buildAfterMultiSessionSingleSignOutUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildAfterMultiSessionSingleSignOutUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildAfterMultiSessionSingleSignOutUrl",e)},this.buildUserProfileUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildUserProfileUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildUserProfileUrl",e)},this.buildCreateOrganizationUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildCreateOrganizationUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildCreateOrganizationUrl",e)},this.buildOrganizationProfileUrl=()=>{let e=()=>{var e;return(null==(e=this.clerkjs)?void 0:e.buildOrganizationProfileUrl())||""};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("buildOrganizationProfileUrl",e)},this.buildUrlWithAuth=e=>{let t=()=>{var t;return(null==(t=this.clerkjs)?void 0:t.buildUrlWithAuth(e))||""};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("buildUrlWithAuth",t)},this.handleUnauthenticated=()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.handleUnauthenticated()};this.clerkjs&&h(this,n)?e():this.premountMethodCalls.set("handleUnauthenticated",e)},this.addOnLoaded=e=>{this.loadedListeners.push(e),this.loaded&&this.emitLoaded()},this.emitLoaded=()=>{this.loadedListeners.forEach(e=>e()),this.loadedListeners=[]},this.hydrateClerkJS=e=>{if(!e)throw Error("Failed to hydrate latest Clerk JS");return this.clerkjs=e,this.premountMethodCalls.forEach(e=>e()),null!==this.preopenSignIn&&e.openSignIn(this.preopenSignIn),null!==this.preopenSignUp&&e.openSignUp(this.preopenSignUp),null!==this.preopenUserProfile&&e.openUserProfile(this.preopenUserProfile),null!==this.preopenOneTap&&e.openGoogleOneTap(this.preopenOneTap),null!==this.preopenOrganizationProfile&&e.openOrganizationProfile(this.preopenOrganizationProfile),null!==this.preopenCreateOrganization&&e.openCreateOrganization(this.preopenCreateOrganization),this.premountSignInNodes.forEach((t,r)=>{e.mountSignIn(r,t)}),this.premountSignUpNodes.forEach((t,r)=>{e.mountSignUp(r,t)}),this.premountUserProfileNodes.forEach((t,r)=>{e.mountUserProfile(r,t)}),this.premountUserButtonNodes.forEach((t,r)=>{e.mountUserButton(r,t)}),this.premountOrganizationListNodes.forEach((t,r)=>{e.mountOrganizationList(r,t)}),m(this,n,!0),this.emitLoaded(),this.clerkjs},this.__unstable__updateProps=async e=>{let t=await g(this,u,l).call(this);if(t&&"__unstable__updateProps"in t)return t.__unstable__updateProps(e)},this.setActive=({session:e,organization:t,beforeEmit:r})=>this.clerkjs?this.clerkjs.setActive({session:e,organization:t,beforeEmit:r}):Promise.reject(),this.openSignIn=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openSignIn(e):this.preopenSignIn=e},this.closeSignIn=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeSignIn():this.preopenSignIn=null},this.openGoogleOneTap=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openGoogleOneTap(e):this.preopenOneTap=e},this.closeGoogleOneTap=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeGoogleOneTap():this.preopenOneTap=null},this.openUserProfile=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openUserProfile(e):this.preopenUserProfile=e},this.closeUserProfile=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeUserProfile():this.preopenUserProfile=null},this.openOrganizationProfile=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openOrganizationProfile(e):this.preopenOrganizationProfile=e},this.closeOrganizationProfile=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeOrganizationProfile():this.preopenOrganizationProfile=null},this.openCreateOrganization=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openCreateOrganization(e):this.preopenCreateOrganization=e},this.closeCreateOrganization=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeCreateOrganization():this.preopenCreateOrganization=null},this.openSignUp=e=>{this.clerkjs&&h(this,n)?this.clerkjs.openSignUp(e):this.preopenSignUp=e},this.closeSignUp=()=>{this.clerkjs&&h(this,n)?this.clerkjs.closeSignUp():this.preopenSignUp=null},this.mountSignIn=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountSignIn(e,t):this.premountSignInNodes.set(e,t)},this.unmountSignIn=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountSignIn(e):this.premountSignInNodes.delete(e)},this.mountSignUp=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountSignUp(e,t):this.premountSignUpNodes.set(e,t)},this.unmountSignUp=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountSignUp(e):this.premountSignUpNodes.delete(e)},this.mountUserProfile=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountUserProfile(e,t):this.premountUserProfileNodes.set(e,t)},this.unmountUserProfile=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountUserProfile(e):this.premountUserProfileNodes.delete(e)},this.mountOrganizationProfile=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountOrganizationProfile(e,t):this.premountOrganizationProfileNodes.set(e,t)},this.unmountOrganizationProfile=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountOrganizationProfile(e):this.premountOrganizationProfileNodes.delete(e)},this.mountCreateOrganization=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountCreateOrganization(e,t):this.premountCreateOrganizationNodes.set(e,t)},this.unmountCreateOrganization=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountCreateOrganization(e):this.premountCreateOrganizationNodes.delete(e)},this.mountOrganizationSwitcher=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountOrganizationSwitcher(e,t):this.premountOrganizationSwitcherNodes.set(e,t)},this.unmountOrganizationSwitcher=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountOrganizationSwitcher(e):this.premountOrganizationSwitcherNodes.delete(e)},this.mountOrganizationList=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountOrganizationList(e,t):this.premountOrganizationListNodes.set(e,t)},this.unmountOrganizationList=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountOrganizationList(e):this.premountOrganizationListNodes.delete(e)},this.mountUserButton=(e,t)=>{this.clerkjs&&h(this,n)?this.clerkjs.mountUserButton(e,t):this.premountUserButtonNodes.set(e,t)},this.unmountUserButton=e=>{this.clerkjs&&h(this,n)?this.clerkjs.unmountUserButton(e):this.premountUserButtonNodes.delete(e)},this.addListener=e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.addListener(e)};return this.clerkjs?t():(this.premountMethodCalls.set("addListener",t),()=>this.premountMethodCalls.delete("addListener"))},this.navigate=e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.navigate(e)};this.clerkjs&&h(this,n)?t():this.premountMethodCalls.set("navigate",t)},this.redirectWithAuth=async(...e)=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.redirectWithAuth(...e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("redirectWithAuth",t)},this.redirectToSignIn=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.redirectToSignIn(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("redirectToSignIn",t)},this.redirectToSignUp=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.redirectToSignUp(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("redirectToSignUp",t)},this.redirectToUserProfile=async()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToUserProfile()};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("redirectToUserProfile",e)},this.redirectToAfterSignUp=()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToAfterSignUp()};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("redirectToAfterSignUp",e)},this.redirectToAfterSignIn=()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToAfterSignIn()};this.clerkjs&&h(this,n)?e():this.premountMethodCalls.set("redirectToAfterSignIn",e)},this.redirectToAfterSignOut=()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToAfterSignOut()};this.clerkjs&&h(this,n)?e():this.premountMethodCalls.set("redirectToAfterSignOut",e)},this.redirectToOrganizationProfile=async()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToOrganizationProfile()};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("redirectToOrganizationProfile",e)},this.redirectToCreateOrganization=async()=>{let e=()=>{var e;return null==(e=this.clerkjs)?void 0:e.redirectToCreateOrganization()};if(this.clerkjs&&h(this,n))return e();this.premountMethodCalls.set("redirectToCreateOrganization",e)},this.handleRedirectCallback=e=>{var t;let r=()=>{var t;return null==(t=this.clerkjs)?void 0:t.handleRedirectCallback(e)};this.clerkjs&&h(this,n)?null==(t=r())||t.catch(()=>{}):this.premountMethodCalls.set("handleRedirectCallback",r)},this.handleGoogleOneTapCallback=(e,t)=>{var r;let i=()=>{var r;return null==(r=this.clerkjs)?void 0:r.handleGoogleOneTapCallback(e,t)};this.clerkjs&&h(this,n)?null==(r=i())||r.catch(()=>{}):this.premountMethodCalls.set("handleGoogleOneTapCallback",i)},this.handleEmailLinkVerification=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.handleEmailLinkVerification(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("handleEmailLinkVerification",t)},this.authenticateWithMetamask=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.authenticateWithMetamask(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("authenticateWithMetamask",t)},this.authenticateWithGoogleOneTap=async e=>(await g(this,u,l).call(this)).authenticateWithGoogleOneTap(e),this.createOrganization=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.createOrganization(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("createOrganization",t)},this.getOrganization=async e=>{let t=()=>{var t;return null==(t=this.clerkjs)?void 0:t.getOrganization(e)};if(this.clerkjs&&h(this,n))return t();this.premountMethodCalls.set("getOrganization",t)},this.signOut=async(e,t)=>{let r=()=>{var r;return null==(r=this.clerkjs)?void 0:r.signOut(e,t)};if(this.clerkjs&&h(this,n))return r();this.premountMethodCalls.set("signOut",r)};let{Clerk:t=null,publishableKey:r}=e||{};m(this,o,r),m(this,s,null==e?void 0:e.proxyUrl),m(this,i,null==e?void 0:e.domain),this.options=e,this.Clerk=t,this.mode=v()?"browser":"server",this.options.sdkMetadata||(this.options.sdkMetadata=J),this.loadClerkJS()}get publishableKey(){return h(this,o)}get loaded(){return h(this,n)}static getOrCreateInstance(t){return v()&&h(this,a)&&(!t.Clerk||h(this,a).Clerk===t.Clerk)||m(this,a,new e(t)),h(this,a)}static clearInstance(){m(this,a,null)}get domain(){return"undefined"!=typeof window&&window.location?k(h(this,i),new URL(window.location.href),""):"function"==typeof h(this,i)?c.RM.throw(c.qq):h(this,i)||""}get proxyUrl(){return"undefined"!=typeof window&&window.location?k(h(this,s),new URL(window.location.href),""):"function"==typeof h(this,s)?c.RM.throw(c.qq):h(this,s)||""}get sdkMetadata(){var e;return(null==(e=this.clerkjs)?void 0:e.sdkMetadata)||this.options.sdkMetadata||void 0}get instanceType(){var e;return null==(e=this.clerkjs)?void 0:e.instanceType}get frontendApi(){var e;return(null==(e=this.clerkjs)?void 0:e.frontendApi)||""}get isStandardBrowser(){var e;return(null==(e=this.clerkjs)?void 0:e.isStandardBrowser)||this.options.standardBrowser||!1}get isSatellite(){return"undefined"!=typeof window&&window.location?k(this.options.isSatellite,new URL(window.location.href),!1):"function"==typeof this.options.isSatellite&&c.RM.throw(c.qq)}async loadClerkJS(){var e,t;if(!("browser"!==this.mode||h(this,n))){"undefined"!=typeof window&&(window.__clerk_publishable_key=h(this,o),window.__clerk_proxy_url=this.proxyUrl,window.__clerk_domain=this.domain);try{if(this.Clerk){let e;(t=this.Clerk,"function"==typeof t)?(e=new this.Clerk(h(this,o),{proxyUrl:this.proxyUrl,domain:this.domain}),await e.load(this.options)):(e=this.Clerk).loaded||await e.load(this.options),global.Clerk=e}else{if(global.Clerk||await (0,c.YJ)({...this.options,publishableKey:h(this,o),proxyUrl:this.proxyUrl,domain:this.domain}),!global.Clerk)throw Error("Failed to download latest ClerkJS. Contact support@clerk.com.");await global.Clerk.load(this.options)}if(null==(e=global.Clerk)?void 0:e.loaded)return this.hydrateClerkJS(global.Clerk);return}catch(e){console.error(e.stack||e.message||e);return}}}get version(){var e;return null==(e=this.clerkjs)?void 0:e.version}get client(){return this.clerkjs?this.clerkjs.client:void 0}get session(){return this.clerkjs?this.clerkjs.session:void 0}get user(){return this.clerkjs?this.clerkjs.user:void 0}get organization(){return this.clerkjs?this.clerkjs.organization:void 0}get telemetry(){return this.clerkjs?this.clerkjs.telemetry:void 0}get __unstable__environment(){return this.clerkjs?this.clerkjs.__unstable__environment:void 0}__unstable__setEnvironment(...e){this.clerkjs&&"__unstable__setEnvironment"in this.clerkjs&&this.clerkjs.__unstable__setEnvironment(e)}};n=new WeakMap,i=new WeakMap,s=new WeakMap,o=new WeakMap,a=new WeakMap,u=new WeakSet,l=function(){return new Promise(e=>{this.addOnLoaded(()=>e(this.clerkjs))})},p(Y,a);var ee=(e,t,r)=>!e&&r?et(r):er(t),et=e=>{let t=e.userId,r=e.user,n=e.sessionId,i=e.session,s=e.organization,o=e.orgId,a=e.orgRole;return{userId:t,user:r,sessionId:n,session:i,organization:s,orgId:o,orgRole:a,orgPermissions:e.orgPermissions,orgSlug:e.orgSlug,actor:e.actor}},er=e=>{var t;let r=e.user?e.user.id:e.user,n=e.user,i=e.session?e.session.id:e.session,s=e.session,o=null==s?void 0:s.actor,a=e.organization,u=e.organization?e.organization.id:e.organization,l=null==a?void 0:a.slug,c=a?null==(t=null==n?void 0:n.organizationMemberships)?void 0:t.find(e=>e.organization.id===u):a,d=c?c.permissions:c;return{userId:r,user:n,sessionId:i,session:s,organization:a,orgId:u,orgRole:c?c.role:c,orgSlug:l,orgPermissions:d,actor:o}};function en(e){let{isomorphicClerkOptions:t,initialState:r,children:n}=e,{isomorphicClerk:i,loaded:s}=ei(t),[o,a]=E.useState({client:i.client,session:i.session,user:i.user,organization:i.organization});E.useEffect(()=>i.addListener(e=>a({...e})),[]);let u=ee(s,o,r),l=E.useMemo(()=>({value:i}),[s]),d=E.useMemo(()=>({value:o.client}),[o.client]),{sessionId:f,session:h,userId:p,user:m,orgId:g,actor:y,organization:v,orgRole:_,orgSlug:b,orgPermissions:w}=u,O=E.useMemo(()=>({value:{sessionId:f,userId:p,actor:y,orgId:g,orgRole:_,orgSlug:b,orgPermissions:w}}),[f,p,y,g,_,b]),k=E.useMemo(()=>({value:m}),[p,m]),T=E.useMemo(()=>({value:h}),[f,h]),C=E.useMemo(()=>({value:{organization:v}}),[g,v]);return E.createElement(c.iz.Provider,{value:l},E.createElement(S.RY.Provider,{value:d},E.createElement(S.B3.Provider,{value:T},E.createElement(S.f0,{...C.value},E.createElement(c.Vo.Provider,{value:O},E.createElement(S.St.Provider,{value:k},n))))))}var ei=e=>{let[t,r]=E.useState(!1),n=E.useMemo(()=>Y.getOrCreateInstance(e),[]);return E.useEffect(()=>{n.__unstable__updateProps({appearance:e.appearance})},[e.appearance]),E.useEffect(()=>{n.__unstable__updateProps({options:e})},[e.localization]),E.useEffect(()=>{n.addOnLoaded(()=>r(!0))},[]),E.useEffect(()=>()=>{Y.clearInstance()},[]),{isomorphicClerk:n,loaded:t}},es=function(e,t,r){let n=e.displayName||e.name||t||"Component",i=n=>((function(e,t,r=1){E.useEffect(()=>{let n=R.get(e)||0;return n==r?c.RM.throw(t):(R.set(e,n+1),()=>{R.set(e,(R.get(e)||1)-1)})},[])})(t,r),E.createElement(e,{...n}));return i.displayName=`withMaxAllowedInstancesGuard(${n})`,i}(function(e){let{initialState:t,children:r,...n}=e,{publishableKey:i="",Clerk:s}=n;return s||(i?i&&!(0,O.x9)(i)&&c.RM.throwInvalidPublishableKeyError({key:i}):c.RM.throwMissingPublishableKeyError()),E.createElement(en,{initialState:t,isomorphicClerkOptions:n},r)},"ClerkProvider",c.KQ);es.displayName="ClerkProvider",(0,c.JM)({packageName:"@clerk/clerk-react"})},77183:function(e,t,r){"use strict";r.d(t,{EJ:function(){return i},JM:function(){return n.JM},iv:function(){return n.iv},wE:function(){return n.wE}});var n=r(71624);function i(e,t,r){let i=t.path||(null==r?void 0:r.path);return"path"===(t.routing||(null==r?void 0:r.routing)||"path")?i?{...r,...t,routing:"path"}:n.RM.throw((0,n.Gv)(e)):t.path?n.RM.throw((0,n.RE)(e)):{...r,...t,path:void 0}}},58153:function(e,t,r){"use strict";r.d(t,{U9:function(){return p},ac:function(){return f},qx:function(){return h},r2:function(){return u},yA:function(){return c}});var n=Object.defineProperty,i=Object.getOwnPropertyDescriptor,s=Object.getOwnPropertyNames,o=Object.prototype.hasOwnProperty,a=e=>{throw TypeError(e)},u=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},l=(e,t,r,a)=>{if(t&&"object"==typeof t||"function"==typeof t)for(let u of s(t))o.call(e,u)||u===r||n(e,u,{get:()=>t[u],enumerable:!(a=i(t,u))||a.enumerable});return e},c=(e,t,r)=>(l(e,t,"default"),r&&l(r,t,"default")),d=(e,t,r)=>t.has(e)||a("Cannot "+r),f=(e,t,r)=>(d(e,t,"read from private field"),r?r.call(e):t.get(e)),h=(e,t,r,n)=>(d(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),p=(e,t,r)=>(d(e,t,"access private method"),r)},22671:function(e,t,r){"use strict";var n=e=>{let t=r=>{if(!r)return r;if(Array.isArray(r))return r.map(e=>"object"==typeof e||Array.isArray(e)?t(e):e);let n={...r};for(let r of Object.keys(n)){let i=e(r.toString());i!==r&&(n[i]=n[r],delete n[r]),"object"==typeof n[i]&&(n[i]=t(n[i]))}return n};return t};n(function(e){return e?e.replace(/[A-Z]/g,e=>`_${e.toLowerCase()}`):""}),n(function(e){return e?e.replace(/([-_][a-z])/g,e=>e.toUpperCase().replace(/-|_/,"")):""})},92873:function(e,t,r){"use strict";r.d(t,{t5:function(){return i}});var n=Object.freeze({InvalidProxyUrlErrorMessage:"The proxyUrl passed to Clerk is invalid. The expected value for proxyUrl is an absolute URL or a relative path with a leading '/'. (key={{url}})",InvalidPublishableKeyErrorMessage:"The publishableKey passed to Clerk is invalid. You can get your Publishable key at https://dashboard.clerk.com/last-active?path=api-keys. (key={{key}})",MissingPublishableKeyErrorMessage:"Missing publishableKey. You can get your key at https://dashboard.clerk.com/last-active?path=api-keys.",MissingSecretKeyErrorMessage:"Missing secretKey. You can get your key at https://dashboard.clerk.com/last-active?path=api-keys.",MissingClerkProvider:"{{source}} can only be used within the <ClerkProvider /> component. Learn more: https://clerk.com/docs/components/clerk-provider"});function i({packageName:e,customMessages:t}){let r=e,i={...n,...t};function s(e,t){if(!t)return`${r}: ${e}`;let n=e;for(let r of e.matchAll(/{{([a-zA-Z0-9-_]+)}}/g)){let e=(t[r[1]]||"").toString();n=n.replace(`{{${r[1]}}}`,e)}return`${r}: ${n}`}return{setPackageName({packageName:e}){return"string"==typeof e&&(r=e),this},setMessages({customMessages:e}){return Object.assign(i,e||{}),this},throwInvalidPublishableKeyError(e){throw Error(s(i.InvalidPublishableKeyErrorMessage,e))},throwInvalidProxyUrl(e){throw Error(s(i.InvalidProxyUrlErrorMessage,e))},throwMissingPublishableKeyError(){throw Error(s(i.MissingPublishableKeyErrorMessage))},throwMissingSecretKeyError(){throw Error(s(i.MissingSecretKeyErrorMessage))},throwMissingClerkProviderError(e){throw Error(s(i.MissingClerkProvider,e))},throw(e){throw Error(s(e))}}}},1709:function(e,t,r){"use strict";r.d(t,{MY:function(){return u},x9:function(){return a},nQ:function(){return o}});var n=e=>"undefined"!=typeof atob&&"function"==typeof atob?atob(e):"undefined"!=typeof global&&global.Buffer?new global.Buffer(e,"base64").toString():e,i=[".lcl.dev",".stg.dev",".lclstage.dev",".stgstage.dev",".dev.lclclerk.com",".stg.lclclerk.com",".accounts.lclclerk.com","accountsstage.dev","accounts.dev"],s="pk_live_";function o(e,t={}){if(!(e=e||"")||!a(e)){if(t.fatal)throw Error("Publishable key not valid.");return null}let r=e.startsWith(s)?"production":"development",i=n(e.split("_")[2]);return i=i.slice(0,-1),t.proxyUrl?i=t.proxyUrl:"development"!==r&&t.domain&&(i=`clerk.${t.domain}`),{instanceType:r,frontendApi:i}}function a(e){let t=(e=e||"").startsWith(s)||e.startsWith("pk_test_"),r=n(e.split("_")[2]||"").endsWith("$");return t&&r}function u(){let e=new Map;return{isDevOrStagingUrl:t=>{if(!t)return!1;let r="string"==typeof t?t:t.hostname,n=e.get(r);return void 0===n&&(n=i.some(e=>r.endsWith(e)),e.set(r,n)),n}}}r(58153)},66763:function(e,t,r){"use strict";let n;r.d(t,{b5:function(){return e_},RY:function(){return ew},f0:function(){return eR},B3:function(){return ek},St:function(){return eS},uH:function(){return ey},c1:function(){return eq},Rm:function(){return ex},cL:function(){return e$},rI:function(){return eb},o8:function(){return eL},eW:function(){return eU},kP:function(){return eB},aF:function(){return eF}});var i={};function s(e,t){return{event:"METHOD_CALLED",payload:{method:e,...t}}}r.r(i),r.d(i,{SWRConfig:function(){return eu},default:function(){return el},mutate:function(){return q},preload:function(){return et},unstable_serialize:function(){return es},useSWRConfig:function(){return ee}});var o=r(58153),a=r(67294),u=r(61688);let l=()=>{},c=l(),d=Object,f=e=>e===c,h=e=>"function"==typeof e,p=(e,t)=>({...e,...t}),m=e=>h(e.then),g=new WeakMap,y=0,v=e=>{let t,r;let n=typeof e,i=e&&e.constructor,s=i==Date;if(d(e)!==e||s||i==RegExp)t=s?e.toJSON():"symbol"==n?e.toString():"string"==n?JSON.stringify(e):""+e;else{if(t=g.get(e))return t;if(t=++y+"~",g.set(e,t),i==Array){for(r=0,t="@";r<e.length;r++)t+=v(e[r])+",";g.set(e,t)}if(i==d){t="#";let n=d.keys(e).sort();for(;!f(r=n.pop());)f(e[r])||(t+=r+":"+v(e[r])+",");g.set(e,t)}}return t},_=new WeakMap,b={},S={},E="undefined",w=typeof window!=E,O=typeof document!=E,k=()=>w&&typeof window.requestAnimationFrame!=E,T=(e,t)=>{let r=_.get(e);return[()=>!f(t)&&e.get(t)||b,n=>{if(!f(t)){let i=e.get(t);t in S||(S[t]=i),r[5](t,p(i,n),i||b)}},r[6],()=>!f(t)&&t in S?S[t]:!f(t)&&e.get(t)||b]},C=!0,[I,R]=w&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[l,l],x={initFocus:e=>(O&&document.addEventListener("visibilitychange",e),I("focus",e),()=>{O&&document.removeEventListener("visibilitychange",e),R("focus",e)}),initReconnect:e=>{let t=()=>{C=!0,e()},r=()=>{C=!1};return I("online",t),I("offline",r),()=>{R("online",t),R("offline",r)}}},A=!a.useId,P=!w||"Deno"in window,M=e=>k()?window.requestAnimationFrame(e):setTimeout(e,1),N=P?a.useEffect:a.useLayoutEffect,D="undefined"!=typeof navigator&&navigator.connection,L=!P&&D&&(["slow-2g","2g"].includes(D.effectiveType)||D.saveData),j=e=>{if(h(e))try{e=e()}catch(t){e=""}let t=e;return[e="string"==typeof e?e:(Array.isArray(e)?e.length:e)?v(e):"",t]},U=0,B=()=>++U;var F={ERROR_REVALIDATE_EVENT:3,FOCUS_EVENT:0,MUTATE_EVENT:2,RECONNECT_EVENT:1};async function $(...e){let[t,r,n,i]=e,s=p({populateCache:!0,throwOnError:!0},"boolean"==typeof i?{revalidate:i}:i||{}),o=s.populateCache,a=s.rollbackOnError,u=s.optimisticData,l=e=>"function"==typeof a?a(e):!1!==a,d=s.throwOnError;if(h(r)){let e=[];for(let n of t.keys())!/^\$(inf|sub)\$/.test(n)&&r(t.get(n)._k)&&e.push(n);return Promise.all(e.map(g))}return g(r);async function g(r){let i;let[a]=j(r);if(!a)return;let[p,g]=T(t,a),[y,v,b,S]=_.get(t),E=()=>{let e=y[a];return(h(s.revalidate)?s.revalidate(p().data,r):!1!==s.revalidate)&&(delete b[a],delete S[a],e&&e[0])?e[0](2).then(()=>p().data):p().data};if(e.length<3)return E();let w=n,O=B();v[a]=[O,0];let k=!f(u),C=p(),I=C.data,R=C._c,x=f(R)?I:R;if(k&&g({data:u=h(u)?u(x,I):u,_c:x}),h(w))try{w=w(x)}catch(e){i=e}if(w&&m(w)){if(w=await w.catch(e=>{i=e}),O!==v[a][0]){if(i)throw i;return w}i&&k&&l(i)&&(o=!0,g({data:x,_c:c}))}if(o&&!i&&(h(o)?g({data:o(w,x),error:c,_c:c}):g({data:w,error:c,_c:c})),v[a][1]=B(),Promise.resolve(E()).then(()=>{g({_c:c})}),i){if(d)throw i;return}return w}}let z=(e,t)=>{for(let r in e)e[r][0]&&e[r][0](t)},H=(e,t)=>{if(!_.has(e)){let r=p(x,t),n={},i=$.bind(c,e),s=l,o={},a=(e,t)=>{let r=o[e]||[];return o[e]=r,r.push(t),()=>r.splice(r.indexOf(t),1)},u=(t,r,n)=>{e.set(t,r);let i=o[t];if(i)for(let e of i)e(r,n)},d=()=>{if(!_.has(e)&&(_.set(e,[n,{},{},{},i,u,a]),!P)){let t=r.initFocus(setTimeout.bind(c,z.bind(c,n,0))),i=r.initReconnect(setTimeout.bind(c,z.bind(c,n,1)));s=()=>{t&&t(),i&&i(),_.delete(e)}}};return d(),[e,i,d,s]}return[e,_.get(e)[4]]},[G,q]=H(new Map),Z=p({onLoadingSlow:l,onSuccess:l,onError:l,onErrorRetry:(e,t,r,n,i)=>{let s=r.errorRetryCount,o=i.retryCount,a=~~((Math.random()+.5)*(1<<(o<8?o:8)))*r.errorRetryInterval;(f(s)||!(o>s))&&setTimeout(n,a,i)},onDiscarded:l,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:L?1e4:5e3,focusThrottleInterval:5e3,dedupingInterval:2e3,loadingTimeout:L?5e3:3e3,compare:(e,t)=>v(e)==v(t),isPaused:()=>!1,cache:G,mutate:q,fallback:{}},{isOnline:()=>C,isVisible:()=>{let e=O&&document.visibilityState;return f(e)||"hidden"!==e}}),W=(e,t)=>{let r=p(e,t);if(t){let{use:n,fallback:i}=e,{use:s,fallback:o}=t;n&&s&&(r.use=n.concat(s)),i&&o&&(r.fallback=p(i,o))}return r},K=(0,a.createContext)({}),V=e=>{let{value:t}=e,r=(0,a.useContext)(K),n=h(t),i=(0,a.useMemo)(()=>n?t(r):t,[n,r,t]),s=(0,a.useMemo)(()=>n?i:W(r,i),[n,r,i]),o=i&&i.provider,u=(0,a.useRef)(c);o&&!u.current&&(u.current=H(o(s.cache||G),i));let l=u.current;return l&&(s.cache=l[0],s.mutate=l[1]),N(()=>{if(l)return l[2]&&l[2](),l[3]},[]),(0,a.createElement)(K.Provider,p(e,{value:s}))},Q="$inf$",X=w&&window.__SWR_DEVTOOLS_USE__,J=X?window.__SWR_DEVTOOLS_USE__:[],Y=e=>h(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(null===e[1]?e[2]:e[1])||{}],ee=()=>p(Z,(0,a.useContext)(K)),et=(e,t)=>{let[r,n]=j(e),[,,,i]=_.get(G);if(i[r])return i[r];let s=t(n);return i[r]=s,s},er=J.concat(e=>(t,r,n)=>{let i=r&&((...e)=>{let[n]=j(t),[,,,i]=_.get(G);if(n.startsWith(Q))return r(...e);let s=i[n];return f(s)?r(...e):(delete i[n],s)});return e(t,i,n)}),en=e=>function(...t){let r=ee(),[n,i,s]=Y(t),o=W(r,s),a=e,{use:u}=o,l=(u||[]).concat(er);for(let e=l.length;e--;)a=l[e](a);return a(n,i||o.fetcher||null,o)},ei=(e,t,r)=>{let n=t[e]||(t[e]=[]);return n.push(r),()=>{let e=n.indexOf(r);e>=0&&(n[e]=n[n.length-1],n.pop())}};X&&(window.__SWR_DEVTOOLS_REACT__=a);let es=e=>j(e)[0],eo=a.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),ea={dedupe:!0},eu=d.defineProperty(V,"defaultValue",{value:Z}),el=en((e,t,r)=>{let{cache:n,compare:i,suspense:s,fallbackData:o,revalidateOnMount:l,revalidateIfStale:d,refreshInterval:m,refreshWhenHidden:g,refreshWhenOffline:y,keepPreviousData:v}=r,[b,S,E,w]=_.get(n),[O,k]=j(e),C=(0,a.useRef)(!1),I=(0,a.useRef)(!1),R=(0,a.useRef)(O),x=(0,a.useRef)(t),D=(0,a.useRef)(r),L=()=>D.current,U=()=>L().isVisible()&&L().isOnline(),[z,H,G,q]=T(n,O),Z=(0,a.useRef)({}).current,W=f(o)?r.fallback[O]:o,K=(e,t)=>{for(let r in Z)if("data"===r){if(!i(e[r],t[r])&&(!f(e[r])||!i(en,t[r])))return!1}else if(t[r]!==e[r])return!1;return!0},V=(0,a.useMemo)(()=>{let e=!!O&&!!t&&(f(l)?!L().isPaused()&&!s&&(!!f(d)||d):l),r=t=>{let r=p(t);return(delete r._k,e)?{isValidating:!0,isLoading:!0,...r}:r},n=z(),i=q(),o=r(n),a=n===i?o:r(i),u=o;return[()=>{let e=r(z());return K(e,u)?(u.data=e.data,u.isLoading=e.isLoading,u.isValidating=e.isValidating,u.error=e.error,u):(u=e,e)},()=>a]},[n,O]),Q=(0,u.useSyncExternalStore)((0,a.useCallback)(e=>G(O,(t,r)=>{K(r,t)||e()}),[n,O]),V[0],V[1]),X=!C.current,J=b[O]&&b[O].length>0,Y=Q.data,ee=f(Y)?W:Y,et=Q.error,er=(0,a.useRef)(ee),en=v?f(Y)?er.current:Y:ee,es=(!J||!!f(et))&&(X&&!f(l)?l:!L().isPaused()&&(s?!f(ee)&&d:f(ee)||d)),eu=!!(O&&t&&X&&es),el=f(Q.isValidating)?eu:Q.isValidating,ec=f(Q.isLoading)?eu:Q.isLoading,ed=(0,a.useCallback)(async e=>{let t,n;let s=x.current;if(!O||!s||I.current||L().isPaused())return!1;let o=!0,a=e||{},u=!E[O]||!a.dedupe,l=()=>A?!I.current&&O===R.current&&C.current:O===R.current,d={isValidating:!1,isLoading:!1},p=()=>{H(d)},m=()=>{let e=E[O];e&&e[1]===n&&delete E[O]},g={isValidating:!0};f(z().data)&&(g.isLoading=!0);try{if(u&&(H(g),r.loadingTimeout&&f(z().data)&&setTimeout(()=>{o&&l()&&L().onLoadingSlow(O,r)},r.loadingTimeout),E[O]=[s(k),B()]),[t,n]=E[O],t=await t,u&&setTimeout(m,r.dedupingInterval),!E[O]||E[O][1]!==n)return u&&l()&&L().onDiscarded(O),!1;d.error=c;let e=S[O];if(!f(e)&&(n<=e[0]||n<=e[1]||0===e[1]))return p(),u&&l()&&L().onDiscarded(O),!1;let a=z().data;d.data=i(a,t)?a:t,u&&l()&&L().onSuccess(t,O,r)}catch(r){m();let e=L(),{shouldRetryOnError:t}=e;!e.isPaused()&&(d.error=r,u&&l()&&(e.onError(r,O,e),(!0===t||h(t)&&t(r))&&(!L().revalidateOnFocus||!L().revalidateOnReconnect||U())&&e.onErrorRetry(r,O,e,e=>{let t=b[O];t&&t[0]&&t[0](F.ERROR_REVALIDATE_EVENT,e)},{retryCount:(a.retryCount||0)+1,dedupe:!0})))}return o=!1,p(),!0},[O,n]),ef=(0,a.useCallback)((...e)=>$(n,R.current,...e),[]);if(N(()=>{x.current=t,D.current=r,f(Y)||(er.current=Y)}),N(()=>{if(!O)return;let e=ed.bind(c,ea),t=0,r=ei(O,b,(r,n={})=>{if(r==F.FOCUS_EVENT){let r=Date.now();L().revalidateOnFocus&&r>t&&U()&&(t=r+L().focusThrottleInterval,e())}else if(r==F.RECONNECT_EVENT)L().revalidateOnReconnect&&U()&&e();else if(r==F.MUTATE_EVENT)return ed();else if(r==F.ERROR_REVALIDATE_EVENT)return ed(n)});return I.current=!1,R.current=O,C.current=!0,H({_k:k}),es&&(f(ee)||P?e():M(e)),()=>{I.current=!0,r()}},[O]),N(()=>{let e;function t(){let t=h(m)?m(z().data):m;t&&-1!==e&&(e=setTimeout(r,t))}function r(){!z().error&&(g||L().isVisible())&&(y||L().isOnline())?ed(ea).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[m,g,y,O]),(0,a.useDebugValue)(en),s&&f(ee)&&O){if(!A&&P)throw Error("Fallback data is required when using suspense in SSR.");x.current=t,D.current=r,I.current=!1;let e=w[O];if(f(e)||eo(ef(e)),f(et)){let e=ed(ea);f(en)||(e.status="fulfilled",e.value=!0),eo(e)}else throw et}return{mutate:ef,get data(){return Z.data=!0,en},get error(){return Z.error=!0,et},get isValidating(){return Z.isValidating=!0,el},get isLoading(){return Z.isLoading=!0,ec}}}),ec=a.use||(e=>{if("pending"===e.status)throw e;if("fulfilled"===e.status)return e.value;if("rejected"===e.status)throw e.reason;throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}),ed={dedupe:!0};d.defineProperty(V,"defaultValue",{value:Z});let ef=en((e,t,r)=>{let{cache:n,compare:i,suspense:s,fallbackData:o,revalidateOnMount:l,revalidateIfStale:d,refreshInterval:m,refreshWhenHidden:g,refreshWhenOffline:y,keepPreviousData:v}=r,[b,S,E,w]=_.get(n),[O,k]=j(e),C=(0,a.useRef)(!1),I=(0,a.useRef)(!1),R=(0,a.useRef)(O),x=(0,a.useRef)(t),D=(0,a.useRef)(r),L=()=>D.current,U=()=>L().isVisible()&&L().isOnline(),[z,H,G,q]=T(n,O),Z=(0,a.useRef)({}).current,W=f(o)?r.fallback[O]:o,K=(e,t)=>{for(let r in Z)if("data"===r){if(!i(e[r],t[r])&&(!f(e[r])||!i(en,t[r])))return!1}else if(t[r]!==e[r])return!1;return!0},V=(0,a.useMemo)(()=>{let e=!!O&&!!t&&(f(l)?!L().isPaused()&&!s&&(!!f(d)||d):l),r=t=>{let r=p(t);return(delete r._k,e)?{isValidating:!0,isLoading:!0,...r}:r},n=z(),i=q(),o=r(n),a=n===i?o:r(i),u=o;return[()=>{let e=r(z());return K(e,u)?(u.data=e.data,u.isLoading=e.isLoading,u.isValidating=e.isValidating,u.error=e.error,u):(u=e,e)},()=>a]},[n,O]),Q=(0,u.useSyncExternalStore)((0,a.useCallback)(e=>G(O,(t,r)=>{K(r,t)||e()}),[n,O]),V[0],V[1]),X=!C.current,J=b[O]&&b[O].length>0,Y=Q.data,ee=f(Y)?W:Y,et=Q.error,er=(0,a.useRef)(ee),en=v?f(Y)?er.current:Y:ee,es=(!J||!!f(et))&&(X&&!f(l)?l:!L().isPaused()&&(s?!f(ee)&&d:f(ee)||d)),eo=!!(O&&t&&X&&es),ea=f(Q.isValidating)?eo:Q.isValidating,eu=f(Q.isLoading)?eo:Q.isLoading,el=(0,a.useCallback)(async e=>{let t,n;let s=x.current;if(!O||!s||I.current||L().isPaused())return!1;let o=!0,a=e||{},u=!E[O]||!a.dedupe,l=()=>A?!I.current&&O===R.current&&C.current:O===R.current,d={isValidating:!1,isLoading:!1},p=()=>{H(d)},m=()=>{let e=E[O];e&&e[1]===n&&delete E[O]},g={isValidating:!0};f(z().data)&&(g.isLoading=!0);try{if(u&&(H(g),r.loadingTimeout&&f(z().data)&&setTimeout(()=>{o&&l()&&L().onLoadingSlow(O,r)},r.loadingTimeout),E[O]=[s(k),B()]),[t,n]=E[O],t=await t,u&&setTimeout(m,r.dedupingInterval),!E[O]||E[O][1]!==n)return u&&l()&&L().onDiscarded(O),!1;d.error=c;let e=S[O];if(!f(e)&&(n<=e[0]||n<=e[1]||0===e[1]))return p(),u&&l()&&L().onDiscarded(O),!1;let a=z().data;d.data=i(a,t)?a:t,u&&l()&&L().onSuccess(t,O,r)}catch(r){m();let e=L(),{shouldRetryOnError:t}=e;!e.isPaused()&&(d.error=r,u&&l()&&(e.onError(r,O,e),(!0===t||h(t)&&t(r))&&(!L().revalidateOnFocus||!L().revalidateOnReconnect||U())&&e.onErrorRetry(r,O,e,e=>{let t=b[O];t&&t[0]&&t[0](F.ERROR_REVALIDATE_EVENT,e)},{retryCount:(a.retryCount||0)+1,dedupe:!0})))}return o=!1,p(),!0},[O,n]),ef=(0,a.useCallback)((...e)=>$(n,R.current,...e),[]);if(N(()=>{x.current=t,D.current=r,f(Y)||(er.current=Y)}),N(()=>{if(!O)return;let e=el.bind(c,ed),t=0,r=ei(O,b,(r,n={})=>{if(r==F.FOCUS_EVENT){let r=Date.now();L().revalidateOnFocus&&r>t&&U()&&(t=r+L().focusThrottleInterval,e())}else if(r==F.RECONNECT_EVENT)L().revalidateOnReconnect&&U()&&e();else if(r==F.MUTATE_EVENT)return el();else if(r==F.ERROR_REVALIDATE_EVENT)return el(n)});return I.current=!1,R.current=O,C.current=!0,H({_k:k}),es&&(f(ee)||P?e():M(e)),()=>{I.current=!0,r()}},[O]),N(()=>{let e;function t(){let t=h(m)?m(z().data):m;t&&-1!==e&&(e=setTimeout(r,t))}function r(){!z().error&&(g||L().isVisible())&&(y||L().isOnline())?el(ed).then(t):t()}return t(),()=>{e&&(clearTimeout(e),e=-1)}},[m,g,y,O]),(0,a.useDebugValue)(en),s&&f(ee)&&O){if(!A&&P)throw Error("Fallback data is required when using suspense in SSR.");x.current=t,D.current=r,I.current=!1;let e=w[O];if(f(e)||ec(ef(e)),f(et)){let e=el(ed);f(en)||(e.status="fulfilled",e.value=!0),ec(e)}else throw et}return{mutate:ef,get data(){return Z.data=!0,en},get error(){return Z.error=!0,et},get isValidating(){return Z.isValidating=!0,ea},get isLoading(){return Z.isLoading=!0,eu}}}),eh=e=>j(e?e(0,null):null)[0],ep=Promise.resolve(),em=(n=e=>(t,r,n)=>{let i;let s=(0,a.useRef)(!1),{cache:o,initialSize:l=1,revalidateAll:d=!1,persistSize:p=!1,revalidateFirstPage:m=!0,revalidateOnMount:g=!1,parallel:y=!1}=n,[,,,v]=_.get(G);try{(i=eh(t))&&(i=Q+i)}catch(e){}let[b,S,E]=T(o,i),w=(0,a.useCallback)(()=>f(b()._l)?l:b()._l,[o,i,l]);(0,u.useSyncExternalStore)((0,a.useCallback)(e=>i?E(i,()=>{e()}):()=>{},[o,i]),w,w);let O=(0,a.useCallback)(()=>{let e=b()._l;return f(e)?l:e},[i,l]),k=(0,a.useRef)(O());N(()=>{if(!s.current){s.current=!0;return}i&&S({_l:p?k.current:O()})},[i,o]);let C=g&&!s.current,I=e(i,async e=>{let i=b()._i,s=b()._r;S({_r:c});let a=[],u=O(),[l]=T(o,e),h=l().data,p=[],g=null;for(let e=0;e<u;++e){let[u,l]=j(t(e,y?null:g));if(!u)break;let[c,_]=T(o,u),b=c().data,S=d||i||f(b)||m&&!e&&!f(h)||C||h&&!f(h[e])&&!n.compare(h[e],b);if(r&&("function"==typeof s?s(b,l):S)){let t=async()=>{if(u in v){let e=v[u];delete v[u],b=await e}else b=await r(l);_({data:b,_k:l}),a[e]=b};y?p.push(t):await t()}else a[e]=b;y||(g=b)}return y&&await Promise.all(p.map(e=>e())),S({_i:c}),a},n),R=(0,a.useCallback)(function(e,t){let r="boolean"==typeof t?{revalidate:t}:t||{},n=!1!==r.revalidate;return i?(n&&(f(e)?S({_i:!0,_r:r.revalidate}):S({_i:!1,_r:r.revalidate})),arguments.length?I.mutate(e,{...r,revalidate:n}):I.mutate()):ep},[i,o]),x=(0,a.useCallback)(e=>{let r;if(!i)return ep;let[,n]=T(o,i);if(h(e)?r=e(O()):"number"==typeof e&&(r=e),"number"!=typeof r)return ep;n({_l:r}),k.current=r;let s=[],[a]=T(o,i),u=null;for(let e=0;e<r;++e){let[r]=j(t(e,u)),[n]=T(o,r),i=r?n().data:c;if(f(i))return R(a().data);s.push(i),u=i}return R(s)},[i,o,R,O]);return{size:O(),setSize:x,mutate:R,get data(){return I.data},get error(){return I.error},get isValidating(){return I.isValidating},get isLoading(){return I.isLoading}}},(...e)=>{let[t,r,i]=Y(e),s=(i.use||[]).concat(n);return ef(t,r,{...i,use:s})});function eg(e,t){if(!e)throw"string"==typeof t?Error(t):Error(`${t.displayName} not found`)}var ey=(e,t)=>{let{assertCtxFn:r=eg}=t||{},n=a.createContext(void 0);return n.displayName=e,[n,()=>{let t=a.useContext(n);return r(t,`${e} not found`),t.value},()=>{let e=a.useContext(n);return e?e.value:{}}]},ev={};(0,o.r2)(ev,{SWRConfig:()=>eu,useSWR:()=>el,useSWRInfinite:()=>em}),(0,o.yA)(ev,i);var[e_,eb]=ey("ClerkInstanceContext"),[eS,eE]=ey("UserContext"),[ew,eO]=ey("ClientContext"),[ek,eT]=ey("SessionContext"),[eC,eI]=ey("OrganizationContext"),eR=({children:e,organization:t,swrConfig:r})=>a.createElement(eu,{value:r},a.createElement(eC.Provider,{value:{value:{organization:t}}},e));function ex(e){if(!a.useContext(e_)){if("function"==typeof e){e();return}throw Error(`${e} can only be used within the <ClerkProvider /> component. Learn more: https://clerk.com/docs/components/clerk-provider`)}}function eA(e,t){let r=new Set(Object.keys(t)),n={};for(let t of Object.keys(e))r.has(t)||(n[t]=e[t]);return n}var eP=(e,t)=>{var r,n,i;let s="boolean"==typeof e&&e,o=(0,a.useRef)(s?t.initialPage:null!=(r=null==e?void 0:e.initialPage)?r:t.initialPage),u=(0,a.useRef)(s?t.pageSize:null!=(n=null==e?void 0:e.pageSize)?n:t.pageSize),l={};for(let r of Object.keys(t))l[r]=s?t[r]:null!=(i=null==e?void 0:e[r])?i:t[r];return{...l,initialPage:o.current,pageSize:u.current}},eM={dedupingInterval:6e4,focusThrottleInterval:12e4},eN=(e,t,r,n)=>{var i,s,o,u,l,c,d;let[f,h]=(0,a.useState)(null!=(i=e.initialPage)?i:1),p=(0,a.useRef)(null!=(s=e.initialPage)?s:1),m=(0,a.useRef)(null!=(o=e.pageSize)?o:10),g=null==(u=r.enabled)||u,y=null!=(l=r.infinite)&&l,v=null!=(c=r.keepPreviousData)&&c,_={...n,...e,initialPage:f,pageSize:m.current},{data:b,isValidating:S,isLoading:E,error:w,mutate:O}=el(!y&&t&&g?_:null,e=>{let r=eA(e,n);return null==t?void 0:t(r)},{keepPreviousData:v,...eM}),{data:k,isLoading:T,isValidating:C,error:I,size:R,setSize:x,mutate:A}=em(t=>y&&g?{...e,...n,initialPage:p.current+t,pageSize:m.current}:null,e=>{let r=eA(e,n);return null==t?void 0:t(r)},eM),P=(0,a.useMemo)(()=>y?R:f,[y,R,f]),M=(0,a.useCallback)(e=>{if(y){x(e);return}return h(e)},[x]),N=(0,a.useMemo)(()=>{var e,t;return y?null!=(e=null==k?void 0:k.map(e=>null==e?void 0:e.data).flat())?e:[]:null!=(t=null==b?void 0:b.data)?t:[]},[y,b,k]),D=(0,a.useMemo)(()=>{var e,t;return y?(null==(e=null==k?void 0:k[(null==k?void 0:k.length)-1])?void 0:e.total_count)||0:null!=(t=null==b?void 0:b.total_count)?t:0},[y,b,k]),L=y?T:E,j=y?C:S,U=null!=(d=y?I:w)?d:null,B=(0,a.useCallback)(()=>{M(e=>Math.max(0,e+1))},[M]),F=(0,a.useCallback)(()=>{M(e=>Math.max(0,e-1))},[M]),$=(p.current-1)*m.current,z=Math.ceil((D-$)/m.current),H=D-$*m.current>P*m.current,G=(P-1)*m.current>$*m.current,q=y?e=>A(e,{revalidate:!1}):e=>O(e,{revalidate:!1});return{data:N,count:D,error:U,isLoading:L,isFetching:j,isError:!!U,page:P,pageCount:z,fetchPage:M,fetchNext:B,fetchPrevious:F,hasNextPage:H,hasPreviousPage:G,revalidate:y?()=>A():()=>O(),setData:q}},eD={data:void 0,count:void 0,error:void 0,isLoading:!1,isFetching:!1,isError:!1,page:void 0,pageCount:void 0,fetchPage:void 0,fetchNext:void 0,fetchPrevious:void 0,hasNextPage:!1,hasPreviousPage:!1,revalidate:void 0,setData:void 0},eL=e=>{var t,r,n;let{domains:i,membershipRequests:o,memberships:a,invitations:u}=e||{};ex("useOrganization");let{organization:l}=eI(),c=eT(),d=eP(i,{initialPage:1,pageSize:10,keepPreviousData:!1,infinite:!1,enrollmentMode:void 0}),f=eP(o,{initialPage:1,pageSize:10,status:"pending",keepPreviousData:!1,infinite:!1}),h=eP(a,{initialPage:1,pageSize:10,role:void 0,keepPreviousData:!1,infinite:!1}),p=eP(u,{initialPage:1,pageSize:10,status:["pending"],keepPreviousData:!1,infinite:!1}),m=eb();null==(t=m.telemetry)||t.record(s("useOrganization"));let g=void 0===i?void 0:{initialPage:d.initialPage,pageSize:d.pageSize,enrollmentMode:d.enrollmentMode},y=void 0===o?void 0:{initialPage:f.initialPage,pageSize:f.pageSize,status:f.status},v=void 0===a?void 0:{initialPage:h.initialPage,pageSize:h.pageSize,role:h.role},_=void 0===u?void 0:{initialPage:p.initialPage,pageSize:p.pageSize,status:p.status},b=eN({...g},null==l?void 0:l.getDomains,{keepPreviousData:d.keepPreviousData,infinite:d.infinite,enabled:!!g},{type:"domains",organizationId:null==l?void 0:l.id}),S=eN({...y},null==l?void 0:l.getMembershipRequests,{keepPreviousData:f.keepPreviousData,infinite:f.infinite,enabled:!!y},{type:"membershipRequests",organizationId:null==l?void 0:l.id}),E=eN(v||{},null==l?void 0:l.getMemberships,{keepPreviousData:h.keepPreviousData,infinite:h.infinite,enabled:!!v},{type:"members",organizationId:null==l?void 0:l.id}),w=eN({..._},null==l?void 0:l.getInvitations,{keepPreviousData:p.keepPreviousData,infinite:p.infinite,enabled:!!_},{type:"invitations",organizationId:null==l?void 0:l.id});return void 0===l?{isLoaded:!1,organization:void 0,membership:void 0,domains:eD,membershipRequests:eD,memberships:eD,invitations:eD}:null===l?{isLoaded:!0,organization:null,membership:null,domains:null,membershipRequests:null,memberships:null,invitations:null}:!m.loaded&&l?{isLoaded:!0,organization:l,membership:void 0,domains:eD,membershipRequests:eD,memberships:eD,invitations:eD}:{isLoaded:m.loaded,organization:l,membership:(r=c.user.organizationMemberships,n=l.id,r.find(e=>e.organization.id===n)),domains:b,membershipRequests:S,memberships:E,invitations:w}},ej={data:void 0,count:void 0,error:void 0,isLoading:!1,isFetching:!1,isError:!1,page:void 0,pageCount:void 0,fetchPage:void 0,fetchNext:void 0,fetchPrevious:void 0,hasNextPage:!1,hasPreviousPage:!1,revalidate:void 0,setData:void 0},eU=e=>{var t;let{userMemberships:r,userInvitations:n,userSuggestions:i}=e||{};ex("useOrganizationList");let o=eP(r,{initialPage:1,pageSize:10,keepPreviousData:!1,infinite:!1}),a=eP(n,{initialPage:1,pageSize:10,status:"pending",keepPreviousData:!1,infinite:!1}),u=eP(i,{initialPage:1,pageSize:10,status:"pending",keepPreviousData:!1,infinite:!1}),l=eb(),c=eE();null==(t=l.telemetry)||t.record(s("useOrganizationList"));let d=void 0===r?void 0:{initialPage:o.initialPage,pageSize:o.pageSize},f=void 0===n?void 0:{initialPage:a.initialPage,pageSize:a.pageSize,status:a.status},h=void 0===i?void 0:{initialPage:u.initialPage,pageSize:u.pageSize,status:u.status},p=!!(l.loaded&&c),m=eN(d||{},null==c?void 0:c.getOrganizationMemberships,{keepPreviousData:o.keepPreviousData,infinite:o.infinite,enabled:!!d},{type:"userMemberships",userId:null==c?void 0:c.id}),g=eN({...f},null==c?void 0:c.getOrganizationInvitations,{keepPreviousData:a.keepPreviousData,infinite:a.infinite,enabled:!!f},{type:"userInvitations",userId:null==c?void 0:c.id}),y=eN({...h},null==c?void 0:c.getOrganizationSuggestions,{keepPreviousData:u.keepPreviousData,infinite:u.infinite,enabled:!!h},{type:"userSuggestions",userId:null==c?void 0:c.id});return p?{isLoaded:p,setActive:l.setActive,createOrganization:l.createOrganization,userMemberships:m,userInvitations:g,userSuggestions:y}:{isLoaded:!1,createOrganization:void 0,setActive:void 0,userMemberships:ej,userInvitations:ej,userSuggestions:ej}};"undefined"!=typeof window?a.useLayoutEffect:a.useEffect;var eB=()=>{ex("useSession");let e=eT();return void 0===e?{isLoaded:!1,isSignedIn:void 0,session:void 0}:null===e?{isLoaded:!0,isSignedIn:!1,session:null}:{isLoaded:!0,isSignedIn:!0,session:e}};function eF(){ex("useUser");let e=eE();return void 0===e?{isLoaded:!1,isSignedIn:void 0,user:void 0}:null===e?{isLoaded:!0,isSignedIn:!1,user:null}:{isLoaded:!0,isSignedIn:!0,user:e}}var e$=()=>(ex("useClerk"),eb()),ez=Object.prototype.hasOwnProperty;function eH(e,t,r){for(r of e.keys())if(eG(r,t))return r}function eG(e,t){var r,n,i;if(e===t)return!0;if(e&&t&&(r=e.constructor)===t.constructor){if(r===Date)return e.getTime()===t.getTime();if(r===RegExp)return e.toString()===t.toString();if(r===Array){if((n=e.length)===t.length)for(;n--&&eG(e[n],t[n]););return -1===n}if(r===Set){if(e.size!==t.size)return!1;for(n of e)if((i=n)&&"object"==typeof i&&!(i=eH(t,i))||!t.has(i))return!1;return!0}if(r===Map){if(e.size!==t.size)return!1;for(n of e)if((i=n[0])&&"object"==typeof i&&!(i=eH(t,i))||!eG(n[1],t.get(i)))return!1;return!0}if(r===ArrayBuffer)e=new Uint8Array(e),t=new Uint8Array(t);else if(r===DataView){if((n=e.byteLength)===t.byteLength)for(;n--&&e.getInt8(n)===t.getInt8(n););return -1===n}if(ArrayBuffer.isView(e)){if((n=e.byteLength)===t.byteLength)for(;n--&&e[n]===t[n];);return -1===n}if(!r||"object"==typeof e){for(r in n=0,e)if(ez.call(e,r)&&++n&&!ez.call(t,r)||!(r in t)||!eG(e[r],t[r]))return!1;return Object.keys(t).length===n}}return e!=e&&t!=t}var eq=eG},19731:function(e,t,r){"use strict";Object.prototype.hasOwnProperty},12599:function(e,t,r){"use strict";r.d(t,{fQ:function(){return i}});var n=e=>{let t=r=>{if(!r)return r;if(Array.isArray(r))return r.map(e=>"object"==typeof e||Array.isArray(e)?t(e):e);let n={...r};for(let r of Object.keys(n)){let i=e(r.toString());i!==r&&(n[i]=n[r],delete n[r]),"object"==typeof n[i]&&(n[i]=t(n[i]))}return n};return t};function i(e){if("boolean"==typeof e)return e;if(null==e)return!1;if("string"==typeof e){if("true"===e.toLowerCase())return!0;if("false"===e.toLowerCase())return!1}let t=parseInt(e,10);return!isNaN(t)&&t>0}n(function(e){return e?e.replace(/[A-Z]/g,e=>`_${e.toLowerCase()}`):""}),n(function(e){return e?e.replace(/([-_][a-z])/g,e=>e.toUpperCase().replace(/-|_/,"")):""})},12016:function(e,t,r){"use strict";r.d(t,{X:function(){return n}});let n="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},39877:function(e,t,r){"use strict";r.d(t,{L2:function(){return u},_6:function(){return l},iK:function(){return c}});var n=r(36731),i=r(41001),s=r(12016),o=r(23039);let a={};function u(e){let t=a[e];if(t)return t;let r=o.m[e];if((0,n.QC)(r))return a[e]=r.bind(o.m);let u=o.m.document;if(u&&"function"==typeof u.createElement)try{let t=u.createElement("iframe");t.hidden=!0,u.head.appendChild(t);let n=t.contentWindow;n&&n[e]&&(r=n[e]),u.head.removeChild(t)}catch(t){s.X&&i.kg.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,t)}return r?a[e]=r.bind(o.m):r}function l(e){a[e]=void 0}function c(...e){return u("setTimeout")(...e)}},25460:function(e,t,r){"use strict";let n,i,s;r.d(t,{O:function(){return c}});var o=r(68562),a=r(27179),u=r(41982),l=r(23039);function c(e){(0,o.Hj)("dom",e),(0,o.D2)("dom",d)}function d(){if(!l.m.document)return;let e=o.rK.bind(null,"dom"),t=f(e,!0);l.m.document.addEventListener("click",t,!1),l.m.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(t=>{let r=l.m[t]&&l.m[t].prototype;r&&r.hasOwnProperty&&r.hasOwnProperty("addEventListener")&&((0,a.hl)(r,"addEventListener",function(t){return function(r,n,i){if("click"===r||"keypress"==r)try{let n=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},s=n[r]=n[r]||{refCount:0};if(!s.handler){let n=f(e);s.handler=n,t.call(this,r,n,i)}s.refCount++}catch(e){}return t.call(this,r,n,i)}}),(0,a.hl)(r,"removeEventListener",function(e){return function(t,r,n){if("click"===t||"keypress"==t)try{let r=this.__sentry_instrumentation_handlers__||{},i=r[t];i&&(i.refCount--,i.refCount<=0&&(e.call(this,t,i.handler,n),i.handler=void 0,delete r[t]),0===Object.keys(r).length&&delete this.__sentry_instrumentation_handlers__)}catch(e){}return e.call(this,t,r,n)}}))})}function f(e,t=!1){return r=>{if(!r||r._sentryCaptured)return;let o=function(e){try{return e.target}catch(e){return null}}(r);if("keypress"===r.type&&(!o||!o.tagName||"INPUT"!==o.tagName&&"TEXTAREA"!==o.tagName&&!o.isContentEditable))return;(0,a.xp)(r,"_sentryCaptured",!0),o&&!o._sentryId&&(0,a.xp)(o,"_sentryId",(0,u.DM)());let c="keypress"===r.type?"input":r.type;!function(e){if(e.type!==i)return!1;try{if(!e.target||e.target._sentryId!==s)return!1}catch(e){}return!0}(r)&&(e({event:r,name:c,global:t}),i=r.type,s=o?o._sentryId:void 0),clearTimeout(n),n=l.m.setTimeout(()=>{s=void 0,i=void 0},1e3)}}},36708:function(e,t,r){"use strict";let n;r.d(t,{a:function(){return u}});var i=r(68562);let s=r(29531).GLOBAL_OBJ;var o=r(27179),a=r(23039);function u(e){let t="history";(0,i.Hj)(t,e),(0,i.D2)(t,l)}function l(){if(!function(){let e=s.chrome,t=e&&e.app&&e.app.runtime,r="history"in s&&!!s.history.pushState&&!!s.history.replaceState;return!t&&r}())return;let e=a.m.onpopstate;function t(e){return function(...t){let r=t.length>2?t[2]:void 0;if(r){let e=n,t=String(r);n=t,(0,i.rK)("history",{from:e,to:t})}return e.apply(this,t)}}a.m.onpopstate=function(...t){let r=a.m.location.href,s=n;if(n=r,(0,i.rK)("history",{from:s,to:r}),e)try{return e.apply(this,t)}catch(e){}},(0,o.hl)(a.m.history,"pushState",t),(0,o.hl)(a.m.history,"replaceState",t)}},67127:function(e,t,r){"use strict";r.d(t,{UK:function(){return l},xU:function(){return u}});var n=r(68562),i=r(27179),s=r(26181),o=r(16824),a=r(23039);let u="__sentry_xhr_v3__";function l(e){(0,n.Hj)("xhr",e),(0,n.D2)("xhr",c)}function c(){if(!a.m.XMLHttpRequest)return;let e=XMLHttpRequest.prototype;(0,i.hl)(e,"open",function(e){return function(...t){let r=1e3*(0,s.ph)(),a=(0,o.HD)(t[0])?t[0].toUpperCase():void 0,l=function(e){if((0,o.HD)(e))return e;try{return e.toString()}catch(e){}}(t[1]);if(!a||!l)return e.apply(this,t);this[u]={method:a,url:l,request_headers:{}},"POST"===a&&l.match(/sentry_key/)&&(this.__sentry_own_request__=!0);let c=()=>{let e=this[u];if(e&&4===this.readyState){try{e.status_code=this.status}catch(e){}let t={endTimestamp:1e3*(0,s.ph)(),startTimestamp:r,xhr:this};(0,n.rK)("xhr",t)}};return"onreadystatechange"in this&&"function"==typeof this.onreadystatechange?(0,i.hl)(this,"onreadystatechange",function(e){return function(...t){return c(),e.apply(this,t)}}):this.addEventListener("readystatechange",c),(0,i.hl)(this,"setRequestHeader",function(e){return function(...t){let[r,n]=t,i=this[u];return i&&(0,o.HD)(r)&&(0,o.HD)(n)&&(i.request_headers[r.toLowerCase()]=n),e.apply(this,t)}}),e.apply(this,t)}}),(0,i.hl)(e,"send",function(e){return function(...t){let r=this[u];if(!r)return e.apply(this,t);void 0!==t[0]&&(r.body=t[0]);let i={startTimestamp:1e3*(0,s.ph)(),xhr:this};return(0,n.rK)("xhr",i),e.apply(this,t)}})}},23039:function(e,t,r){"use strict";r.d(t,{m:function(){return n}});let n=r(29531).GLOBAL_OBJ},80771:function(e,t,r){"use strict";r.d(t,{R:function(){return x}});var n=r(73326),i=r(41001),s=r(41982),o=r(16824),a=r(80128),u=r(39432),l=r(27179),c=r(16825),d=r(26181),f=r(66013),h=r(73076),p=r(94223),m=r(11793),g=r(58942),y=r(10042),v=r(72123),_=r(79769),b=r(76247);let S="Not capturing exception because it's already been captured.";class E{constructor(e){if(this._options=e,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],e.dsn?this._dsn=(0,n.vK)(e.dsn):p.X&&i.kg.warn("No DSN provided, client will not send events."),this._dsn){let t=(0,f.U)(this._dsn,e.tunnel,e._metadata?e._metadata.sdk:void 0);this._transport=e.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...e.transportOptions,url:t})}}captureException(e,t,r){let n=(0,s.DM)();if((0,s.YO)(e))return p.X&&i.kg.log(S),n;let o={event_id:n,...t};return this._process(this.eventFromException(e,o).then(e=>this._captureEvent(e,o,r))),o.event_id}captureMessage(e,t,r,n){let i={event_id:(0,s.DM)(),...r},a=(0,o.Le)(e)?e:String(e),u=(0,o.pt)(e)?this.eventFromMessage(a,t,i):this.eventFromException(e,i);return this._process(u.then(e=>this._captureEvent(e,i,n))),i.event_id}captureEvent(e,t,r){let n=(0,s.DM)();if(t&&t.originalException&&(0,s.YO)(t.originalException))return p.X&&i.kg.log(S),n;let o={event_id:n,...t},a=(e.sdkProcessingMetadata||{}).capturedSpanScope;return this._process(this._captureEvent(e,o,a||r)),o.event_id}captureSession(e){"string"!=typeof e.release?p.X&&i.kg.warn("Discarded session because of missing or non-string release"):(this.sendSession(e),(0,y.CT)(e,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(e){let t=this._transport;return t?(this.emit("flush"),this._isClientDoneProcessing(e).then(r=>t.flush(e).then(e=>r&&e))):(0,a.WD)(!0)}close(e){return this.flush(e).then(e=>(this.getOptions().enabled=!1,this.emit("close"),e))}getEventProcessors(){return this._eventProcessors}addEventProcessor(e){this._eventProcessors.push(e)}init(){this._isEnabled()&&this._setupIntegrations()}getIntegrationByName(e){return this._integrations[e]}addIntegration(e){let t=this._integrations[e.name];(0,g.m7)(this,e,this._integrations),t||(0,g.uf)(this,[e])}sendEvent(e,t={}){this.emit("beforeSendEvent",e,t);let r=(0,m.Mq)(e,this._dsn,this._options._metadata,this._options.tunnel);for(let e of t.attachments||[])r=(0,u.BO)(r,(0,u.zQ)(e));let n=this.sendEnvelope(r);n&&n.then(t=>this.emit("afterSendEvent",e,t),null)}sendSession(e){let t=(0,m.Q3)(e,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(t)}recordDroppedEvent(e,t,r){if(this._options.sendClientReports){let n="number"==typeof r?r:1,s=`${e}:${t}`;p.X&&i.kg.log(`Recording outcome: "${s}"${n>1?` (${n} times)`:""}`),this._outcomes[s]=(this._outcomes[s]||0)+n}}on(e,t){let r=this._hooks[e]=this._hooks[e]||[];return r.push(t),()=>{let e=r.indexOf(t);e>-1&&r.splice(e,1)}}emit(e,...t){let r=this._hooks[e];r&&r.forEach(e=>e(...t))}sendEnvelope(e){return(this.emit("beforeEnvelope",e),this._isEnabled()&&this._transport)?this._transport.send(e).then(null,e=>(p.X&&i.kg.error("Error while sending event:",e),e)):(p.X&&i.kg.error("Transport disabled"),(0,a.WD)({}))}_setupIntegrations(){let{integrations:e}=this._options;this._integrations=(0,g.q4)(this,e),(0,g.uf)(this,e)}_updateSessionFromEvent(e,t){let r=!1,n=!1,i=t.exception&&t.exception.values;if(i)for(let e of(n=!0,i)){let t=e.mechanism;if(t&&!1===t.handled){r=!0;break}}let s="ok"===e.status;(s&&0===e.errors||s&&r)&&((0,y.CT)(e,{...r&&{status:"crashed"},errors:e.errors||Number(n||r)}),this.captureSession(e))}_isClientDoneProcessing(e){return new a.cW(t=>{let r=0,n=setInterval(()=>{0==this._numProcessing?(clearInterval(n),t(!0)):(r+=1,e&&r>=e&&(clearInterval(n),t(!1)))},1)})}_isEnabled(){return!1!==this.getOptions().enabled&&void 0!==this._transport}_prepareEvent(e,t,r,n=(0,h.aF)()){let i=this.getOptions(),s=Object.keys(this._integrations);return!t.integrations&&s.length>0&&(t.integrations=s),this.emit("preprocessEvent",e,t),e.type||n.setLastEventId(e.event_id||t.event_id),(0,b.R)(i,e,t,r,this,n).then(e=>{if(null===e)return e;let t={...n.getPropagationContext(),...r?r.getPropagationContext():void 0};if(!(e.contexts&&e.contexts.trace)&&t){let{traceId:r,spanId:n,parentSpanId:i,dsc:s}=t;e.contexts={trace:(0,l.Jr)({trace_id:r,span_id:n,parent_span_id:i}),...e.contexts};let o=s||(0,v._l)(r,this);e.sdkProcessingMetadata={dynamicSamplingContext:o,...e.sdkProcessingMetadata}}return e})}_captureEvent(e,t={},r){return this._processEvent(e,t,r).then(e=>e.event_id,e=>{p.X&&("log"===e.logLevel?i.kg.log(e.message):i.kg.warn(e))})}_processEvent(e,t,r){let n=this.getOptions(),{sampleRate:i}=n,s=O(e),u=w(e),l=e.type||"error",d=`before send for type \`${l}\``,f=void 0===i?void 0:(0,_.o)(i);if(u&&"number"==typeof f&&Math.random()>f)return this.recordDroppedEvent("sample_rate","error",e),(0,a.$2)(new c.b(`Discarding event because it's not included in the random sample (sampling rate = ${i})`,"log"));let h="replay_event"===l?"replay":l,p=(e.sdkProcessingMetadata||{}).capturedSpanIsolationScope;return this._prepareEvent(e,t,r,p).then(r=>{if(null===r)throw this.recordDroppedEvent("event_processor",h,e),new c.b("An event processor returned `null`, will not send event.","log");return t.data&&!0===t.data.__sentry__?r:function(e,t){let r=`${t} must return \`null\` or a valid event.`;if((0,o.J8)(e))return e.then(e=>{if(!(0,o.PO)(e)&&null!==e)throw new c.b(r);return e},e=>{throw new c.b(`${t} rejected with ${e}`)});if(!(0,o.PO)(e)&&null!==e)throw new c.b(r);return e}(function(e,t,r,n){let{beforeSend:i,beforeSendTransaction:s,beforeSendSpan:o}=t;if(w(r)&&i)return i(r,n);if(O(r)){if(r.spans&&o){let t=[];for(let n of r.spans){let r=o(n);r?t.push(r):e.recordDroppedEvent("before_send","span")}r.spans=t}if(s){if(r.spans){let e=r.spans.length;r.sdkProcessingMetadata={...r.sdkProcessingMetadata,spanCountBeforeProcessing:e}}return s(r,n)}}return r}(this,n,r,t),d)}).then(n=>{if(null===n){if(this.recordDroppedEvent("before_send",h,e),s){let t=1+(e.spans||[]).length;this.recordDroppedEvent("before_send","span",t)}throw new c.b(`${d} returned \`null\`, will not send event.`,"log")}let i=r&&r.getSession();if(!s&&i&&this._updateSessionFromEvent(i,n),s){let e=(n.sdkProcessingMetadata&&n.sdkProcessingMetadata.spanCountBeforeProcessing||0)-(n.spans?n.spans.length:0);e>0&&this.recordDroppedEvent("before_send","span",e)}let o=n.transaction_info;return s&&o&&n.transaction!==e.transaction&&(n.transaction_info={...o,source:"custom"}),this.sendEvent(n,t),n}).then(null,e=>{if(e instanceof c.b)throw e;throw this.captureException(e,{data:{__sentry__:!0},originalException:e}),new c.b(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event.
Reason: ${e}`)})}_process(e){this._numProcessing++,e.then(e=>(this._numProcessing--,e),e=>(this._numProcessing--,e))}_clearOutcomes(){let e=this._outcomes;return this._outcomes={},Object.entries(e).map(([e,t])=>{let[r,n]=e.split(":");return{reason:r,category:n,quantity:t}})}_flushOutcomes(){p.X&&i.kg.log("Flushing outcomes...");let e=this._clearOutcomes();if(0===e.length){p.X&&i.kg.log("No outcomes to send");return}if(!this._dsn){p.X&&i.kg.log("No dsn provided, will not send outcomes");return}p.X&&i.kg.log("Sending outcomes:",e);let t=function(e,t,r){let n=[{type:"client_report"},{timestamp:(0,d.yW)(),discarded_events:e}];return(0,u.Jd)(t?{dsn:t}:{},[n])}(e,this._options.tunnel&&(0,n.RA)(this._dsn));this.sendEnvelope(t)}}function w(e){return void 0===e.type}function O(e){return"transaction"===e.type}var k=r(7659),T=r(84281),C=r(70470),I=r(83362),R=r(22404);class x extends E{constructor(e){let t={parentSpanIsAlwaysRootSpan:!0,...e},r=R.m9.SENTRY_SDK_SOURCE||(0,T.S)();(0,k.V)(t,"browser",["browser"],r),super(t),t.sendClientReports&&R.m9.document&&R.m9.document.addEventListener("visibilitychange",()=>{"hidden"===R.m9.document.visibilityState&&this._flushOutcomes()})}eventFromException(e,t){return(0,I.dr)(this._options.stackParser,e,t,this._options.attachStacktrace)}eventFromMessage(e,t="info",r){return(0,I.aB)(this._options.stackParser,e,t,r,this._options.attachStacktrace)}captureUserFeedback(e){if(!this._isEnabled()){C.X&&i.kg.warn("SDK not enabled, will not capture user feedback.");return}let t=function(e,{metadata:t,tunnel:r,dsn:i}){let s={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!r&&!!i&&{dsn:(0,n.RA)(i)}};return(0,u.Jd)(s,[[{type:"user_report"},e]])}(e,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this.sendEnvelope(t)}_prepareEvent(e,t,r){return e.platform=e.platform||"javascript",super._prepareEvent(e,t,r)}}},70470:function(e,t,r){"use strict";r.d(t,{X:function(){return n}});let n="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},83362:function(e,t,r){"use strict";r.d(t,{GJ:function(){return l},ME:function(){return m},aB:function(){return p},dr:function(){return h}});var n=r(73076),i=r(83408),s=r(16824),o=r(41982),a=r(80128),u=r(27179);function l(e,t){let r=d(e,t),n={type:t&&t.name,value:function(e){let t=e&&e.message;return t?t.error&&"string"==typeof t.error.message?t.error.message:t:"No error message"}(t)};return r.length&&(n.stacktrace={frames:r}),void 0===n.type&&""===n.value&&(n.value="Unrecoverable error caught"),n}function c(e,t){return{exception:{values:[l(e,t)]}}}function d(e,t){let r=t.stacktrace||t.stack||"",n=t&&f.test(t.message)?1:0,i="number"==typeof t.framesToPop?t.framesToPop:0;try{return e(r,n,i)}catch(e){}return[]}let f=/Minified React error #\d+;/i;function h(e,t,r,n){let i=m(e,t,r&&r.syntheticException||void 0,n);return(0,o.EG)(i),i.level="error",r&&r.event_id&&(i.event_id=r.event_id),(0,a.WD)(i)}function p(e,t,r="info",n,i){let s=g(e,t,n&&n.syntheticException||void 0,i);return s.level=r,n&&n.event_id&&(s.event_id=n.event_id),(0,a.WD)(s)}function m(e,t,r,a,f){let h;if((0,s.VW)(t)&&t.error)return c(e,t.error);if((0,s.TX)(t)||(0,s.fm)(t)){if("stack"in t)h=c(e,t);else{let n=t.name||((0,s.TX)(t)?"DOMError":"DOMException"),i=t.message?`${n}: ${t.message}`:n;h=g(e,i,r,a),(0,o.Db)(h,i)}return"code"in t&&(h.tags={...h.tags,"DOMException.code":`${t.code}`}),h}return(0,s.VZ)(t)?c(e,t):((0,s.PO)(t)||(0,s.cO)(t)?h=function(e,t,r,o){let a=(0,n.s3)(),c=a&&a.getOptions().normalizeDepth,f=function(e){for(let t in e)if(Object.prototype.hasOwnProperty.call(e,t)){let r=e[t];if(r instanceof Error)return r}}(t),h={__serialized__:(0,i.Qy)(t,c)};if(f)return{exception:{values:[l(e,f)]},extra:h};let p={exception:{values:[{type:(0,s.cO)(t)?t.constructor.name:o?"UnhandledRejection":"Error",value:function(e,{isUnhandledRejection:t}){let r=(0,u.zf)(e),n=t?"promise rejection":"exception";if((0,s.VW)(e))return`Event \`ErrorEvent\` captured as ${n} with message \`${e.message}\``;if((0,s.cO)(e)){let t=function(e){try{let t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch(e){}}(e);return`Event \`${t}\` (type=${e.type}) captured as ${n}`}return`Object captured as ${n} with keys: ${r}`}(t,{isUnhandledRejection:o})}]},extra:h};if(r){let t=d(e,r);t.length&&(p.exception.values[0].stacktrace={frames:t})}return p}(e,t,r,f):(h=g(e,t,r,a),(0,o.Db)(h,`${t}`,void 0)),(0,o.EG)(h,{synthetic:!0}),h)}function g(e,t,r,n){let i={};if(n&&r){let n=d(e,r);n.length&&(i.exception={values:[{value:t,stacktrace:{frames:n}}]})}if((0,s.Le)(t)){let{__sentry_template_string__:e,__sentry_template_values__:r}=t;return i.logentry={message:e,params:r},i}return i.message=t,i}},22404:function(e,t,r){"use strict";r.d(t,{Wz:function(){return c},m9:function(){return u},re:function(){return function e(t,r={},s){if("function"!=typeof t)return t;try{let e=t.__sentry_wrapped__;if(e)return e;if((0,o.HK)(t))return t}catch(e){return t}let u=function(){let o=Array.prototype.slice.call(arguments);try{s&&"function"==typeof s&&s.apply(this,arguments);let n=o.map(t=>e(t,r));return t.apply(this,n)}catch(e){throw l++,setTimeout(()=>{l--}),(0,n.$e)(t=>{t.addEventProcessor(e=>(r.mechanism&&((0,a.Db)(e,void 0,void 0),(0,a.EG)(e,r.mechanism)),e.extra={...e.extra,arguments:o},e)),(0,i.Tb)(e)}),e}};try{for(let e in t)Object.prototype.hasOwnProperty.call(t,e)&&(u[e]=t[e])}catch(e){}(0,o.$Q)(u,t),(0,o.xp)(t,"__sentry_wrapped__",u);try{Object.getOwnPropertyDescriptor(u,"name").configurable&&Object.defineProperty(u,"name",{get:()=>t.name})}catch(e){}return u}}});var n=r(73076),i=r(39424),s=r(29531),o=r(27179),a=r(41982);let u=s.GLOBAL_OBJ,l=0;function c(){return l>0}},15299:function(e,t,r){"use strict";r.d(t,{f:function(){return E}});var n=r(25460),i=r(67127),s=r(36708),o=r(58942),a=r(73076),u=r(37895),l=r(41001),c=r(27179),d=r(29531),f=r(68562);function h(){"console"in d.GLOBAL_OBJ&&l.RU.forEach(function(e){e in d.GLOBAL_OBJ.console&&(0,c.hl)(d.GLOBAL_OBJ.console,e,function(t){return l.LD[e]=t,function(...t){(0,f.rK)("console",{args:t,level:e});let r=l.LD[e];r&&r.apply(d.GLOBAL_OBJ.console,t)}})})}var p=r(69024),m=r(41982),g=r(1869);let y=["fatal","error","warning","log","info","debug"];var v=r(89163),_=r(42419),b=r(70470),S=r(22404);let E=(0,o._I)((e={})=>{let t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:"Breadcrumbs",setup(e){var r;t.console&&function(e){let t="console";(0,f.Hj)(t,e),(0,f.D2)(t,h)}(function(t){var r;if((0,a.s3)()!==e)return;let n={category:"console",data:{arguments:t.args,logger:"console"},level:"warn"===(r=t.level)?"warning":y.includes(r)?r:"log",message:(0,v.nK)(t.args," ")};if("assert"===t.level){if(!1!==t.args[0])return;n.message=`Assertion failed: ${(0,v.nK)(t.args.slice(1)," ")||"console.assert"}`,n.data.arguments=t.args.slice(1)}(0,u.n)(n,{input:t.args,level:t.level})}),t.dom&&(0,n.O)((r=t.dom,function(t){let n,i;if((0,a.s3)()!==e)return;let s="object"==typeof r?r.serializeAttribute:void 0,o="object"==typeof r&&"number"==typeof r.maxStringLength?r.maxStringLength:void 0;o&&o>1024&&(b.X&&l.kg.warn(`\`dom.maxStringLength\` cannot exceed 1024, but a value of ${o} was configured. Sentry will use 1024 instead.`),o=1024),"string"==typeof s&&(s=[s]);try{let e=t.event,r=e&&e.target?e.target:e;n=(0,g.Rt)(r,{keyAttrs:s,maxStringLength:o}),i=(0,g.iY)(r)}catch(e){n="<unknown>"}if(0===n.length)return;let c={category:`ui.${t.name}`,message:n};i&&(c.data={"ui.component_name":i}),(0,u.n)(c,{event:t.event,name:t.name,global:t.global})})),t.xhr&&(0,i.UK)(function(t){if((0,a.s3)()!==e)return;let{startTimestamp:r,endTimestamp:n}=t,s=t.xhr[i.xU];if(!r||!n||!s)return;let{method:o,url:l,status_code:c,body:d}=s,f={xhr:t.xhr,input:d,startTimestamp:r,endTimestamp:n};(0,u.n)({category:"xhr",data:{method:o,url:l,status_code:c},type:"http"},f)}),t.fetch&&(0,p.Uf)(function(t){if((0,a.s3)()!==e)return;let{startTimestamp:r,endTimestamp:n}=t;if(!(!n||t.fetchData.url.match(/sentry_key/)&&"POST"===t.fetchData.method)){if(t.error){let e=t.fetchData,i={data:t.error,input:t.args,startTimestamp:r,endTimestamp:n};(0,u.n)({category:"fetch",data:e,level:"error",type:"http"},i)}else{let e=t.response,i={...t.fetchData,status_code:e&&e.status},s={input:t.args,response:e,startTimestamp:r,endTimestamp:n};(0,u.n)({category:"fetch",data:i,type:"http"},s)}}}),t.history&&(0,s.a)(function(t){if((0,a.s3)()!==e)return;let r=t.from,n=t.to,i=(0,_.en)(S.m9.location.href),s=r?(0,_.en)(r):void 0,o=(0,_.en)(n);s&&s.path||(s=i),i.protocol===o.protocol&&i.host===o.host&&(n=o.relative),i.protocol===s.protocol&&i.host===s.host&&(r=s.relative),(0,u.n)({category:"navigation",data:{from:r,to:n}})}),t.sentry&&e.on("beforeSendEvent",function(t){(0,a.s3)()===e&&(0,u.n)({category:`sentry.${"transaction"===t.type?"transaction":"event"}`,event_id:t.event_id,level:t.level,message:(0,m.jH)(t)},{event:t})})}}})},43749:function(e,t,r){"use strict";r.d(t,{t:function(){return u}});var n=r(58942),i=r(27179),s=r(42283),o=r(22404);let a=["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"],u=(0,n._I)((e={})=>{let t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...e};return{name:"BrowserApiErrors",setupOnce(){t.setTimeout&&(0,i.hl)(o.m9,"setTimeout",l),t.setInterval&&(0,i.hl)(o.m9,"setInterval",l),t.requestAnimationFrame&&(0,i.hl)(o.m9,"requestAnimationFrame",c),t.XMLHttpRequest&&"XMLHttpRequest"in o.m9&&(0,i.hl)(XMLHttpRequest.prototype,"send",d);let e=t.eventTarget;e&&(Array.isArray(e)?e:a).forEach(f)}}});function l(e){return function(...t){let r=t[0];return t[0]=(0,o.re)(r,{mechanism:{data:{function:(0,s.$P)(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function c(e){return function(t){return e.apply(this,[(0,o.re)(t,{mechanism:{data:{function:"requestAnimationFrame",handler:(0,s.$P)(e)},handled:!1,type:"instrument"}})])}}function d(e){return function(...t){let r=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(e=>{e in r&&"function"==typeof r[e]&&(0,i.hl)(r,e,function(t){let r={mechanism:{data:{function:e,handler:(0,s.$P)(t)},handled:!1,type:"instrument"}},n=(0,i.HK)(t);return n&&(r.mechanism.data.handler=(0,s.$P)(n)),(0,o.re)(t,r)})}),e.apply(this,t)}}function f(e){let t=o.m9,r=t[e]&&t[e].prototype;r&&r.hasOwnProperty&&r.hasOwnProperty("addEventListener")&&((0,i.hl)(r,"addEventListener",function(t){return function(r,n,i){try{"function"==typeof n.handleEvent&&(n.handleEvent=(0,o.re)(n.handleEvent,{mechanism:{data:{function:"handleEvent",handler:(0,s.$P)(n),target:e},handled:!1,type:"instrument"}}))}catch(e){}return t.apply(this,[r,(0,o.re)(n,{mechanism:{data:{function:"addEventListener",handler:(0,s.$P)(n),target:e},handled:!1,type:"instrument"}}),i])}}),(0,i.hl)(r,"removeEventListener",function(e){return function(t,r,n){try{let i=r&&r.__sentry_wrapped__;i&&e.call(this,t,i,n)}catch(e){}return e.call(this,t,r,n)}}))}},44426:function(e,t,r){"use strict";r.d(t,{k:function(){return m}});var n=r(58942),i=r(73076),s=r(39424),o=r(7355),a=r(40364),u=r(16824),l=r(1869),c=r(42283),d=r(41001),f=r(70470),h=r(83362),p=r(22404);let m=(0,n._I)((e={})=>{let t={onerror:!0,onunhandledrejection:!0,...e};return{name:"GlobalHandlers",setupOnce(){Error.stackTraceLimit=50},setup(e){t.onerror&&((0,o.V)(t=>{let{stackParser:r,attachStacktrace:n}=y();if((0,i.s3)()!==e||(0,p.Wz)())return;let{msg:o,url:a,line:d,column:f,error:m}=t,g=function(e,t,r,n){let i=e.exception=e.exception||{},s=i.values=i.values||[],o=s[0]=s[0]||{},a=o.stacktrace=o.stacktrace||{},d=a.frames=a.frames||[],f=isNaN(parseInt(n,10))?void 0:n,h=isNaN(parseInt(r,10))?void 0:r,p=(0,u.HD)(t)&&t.length>0?t:(0,l.l4)();return 0===d.length&&d.push({colno:f,filename:p,function:c.Fi,in_app:!0,lineno:h}),e}((0,h.ME)(r,m||o,void 0,n,!1),a,d,f);g.level="error",(0,s.eN)(g,{originalException:m,mechanism:{handled:!1,type:"onerror"}})}),g("onerror")),t.onunhandledrejection&&((0,a.h)(t=>{let{stackParser:r,attachStacktrace:n}=y();if((0,i.s3)()!==e||(0,p.Wz)())return;let o=function(e){if((0,u.pt)(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch(e){}return e}(t),a=(0,u.pt)(o)?{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(o)}`}]}}:(0,h.ME)(r,o,void 0,n,!0);a.level="error",(0,s.eN)(a,{originalException:o,mechanism:{handled:!1,type:"onunhandledrejection"}})}),g("onunhandledrejection"))}}});function g(e){f.X&&d.kg.log(`Global Handler attached: ${e}`)}function y(){let e=(0,i.s3)();return e&&e.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}},21429:function(e,t,r){"use strict";r.d(t,{s:function(){return s}});var n=r(58942),i=r(22404);let s=(0,n._I)(()=>({name:"HttpContext",preprocessEvent(e){if(!i.m9.navigator&&!i.m9.location&&!i.m9.document)return;let t=e.request&&e.request.url||i.m9.location&&i.m9.location.href,{referrer:r}=i.m9.document||{},{userAgent:n}=i.m9.navigator||{},s={...e.request&&e.request.headers,...r&&{Referer:r},...n&&{"User-Agent":n}},o={...e.request,...t&&{url:t},headers:s};e.request=o}}))},67233:function(e,t,r){"use strict";r.d(t,{O:function(){return l}});var n=r(58942),i=r(16824),s=r(89163);function o(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,..."AggregateError"===e.type&&{is_exception_group:!0},exception_id:t}}function a(e,t,r,n){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,type:"chained",source:t,exception_id:r,parent_id:n}}var u=r(83362);let l=(0,n._I)((e={})=>{let t=e.limit||5,r=e.key||"cause";return{name:"LinkedErrors",preprocessEvent(e,n,l){let c=l.getOptions();!function(e,t,r=250,n,u,l,c){if(!l.exception||!l.exception.values||!c||!(0,i.V9)(c.originalException,Error))return;let d=l.exception.values.length>0?l.exception.values[l.exception.values.length-1]:void 0;d&&(l.exception.values=(function e(t,r,n,s,u,l,c,d){if(l.length>=n+1)return l;let f=[...l];if((0,i.V9)(s[u],Error)){o(c,d);let i=t(r,s[u]),l=f.length;a(i,u,l,d),f=e(t,r,n,s[u],u,[i,...f],i,l)}return Array.isArray(s.errors)&&s.errors.forEach((s,l)=>{if((0,i.V9)(s,Error)){o(c,d);let i=t(r,s),h=f.length;a(i,`errors[${l}]`,h,d),f=e(t,r,n,s,u,[i,...f],i,h)}}),f})(e,t,u,c.originalException,n,l.exception.values,d,0).map(e=>(e.value&&(e.value=(0,s.$G)(e.value,r)),e)))}(u.GJ,c.stackParser,c.maxValueLength,r,t,e,n)}}})},75686:function(e,t,r){"use strict";r.d(t,{S1:function(){return T},jp:function(){return C},nV:function(){return k}});var n=r(87228),i=r(93790),s=r(90092),o=r(58942),a=r(66516),u=r(73076),l=r(39424),c=r(66013),d=r(41001),f=r(36731),h=r(42283),p=r(36708),m=r(80771),g=r(70470),y=r(22404),v=r(15299),_=r(43749),b=r(44426),S=r(21429),E=r(67233),w=r(55525),O=r(45976);function k(e){return[(0,n.S)(),(0,i.C)(),(0,_.t)(),(0,v.f)(),(0,b.k)(),(0,E.O)(),(0,s.R)(),(0,S.s)()]}function T(e={}){let t=function(e={}){return{defaultIntegrations:k(),release:"string"==typeof __SENTRY_RELEASE__?__SENTRY_RELEASE__:y.m9.SENTRY_RELEASE&&y.m9.SENTRY_RELEASE.id?y.m9.SENTRY_RELEASE.id:void 0,autoSessionTracking:!0,sendClientReports:!0,...e}}(e);if(function(){let e=void 0!==y.m9.window&&y.m9;if(!e)return!1;let t=e.chrome?"chrome":"browser",r=e[t],n=r&&r.runtime&&r.runtime.id,i=y.m9.location&&y.m9.location.href||"",s=!!n&&y.m9===y.m9.top&&["chrome-extension:","moz-extension:","ms-browser-extension:"].some(e=>i.startsWith(`${e}//`)),o=void 0!==e.nw;return!!n&&!s&&!o}()){(0,d.Cf)(()=>{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}g.X&&!(0,f.Ak)()&&d.kg.warn("No Fetch API detected. The Sentry SDK requires a Fetch API compatible environment to send events. Please add a Fetch API polyfill.");let r={...t,stackParser:(0,h.Sq)(t.stackParser||w.Dt),integrations:(0,o.m8)(t),transport:t.transport||O.f},n=(0,a.M)(m.R,r);return t.autoSessionTracking&&function(){if(void 0===y.m9.document){g.X&&d.kg.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}(0,l.yj)({ignoreDuration:!0}),(0,l.cg)(),(0,p.a)(({from:e,to:t})=>{void 0!==e&&e!==t&&((0,l.yj)({ignoreDuration:!0}),(0,l.cg)())})}(),n}function C(e={}){if(!y.m9.document){g.X&&d.kg.error("Global document not defined in showReportDialog call");return}let t=(0,u.nZ)(),r=t.getClient(),n=r&&r.getDsn();if(!n){g.X&&d.kg.error("DSN not configured for showReportDialog call");return}if(t&&(e.user={...t.getUser(),...e.user}),!e.eventId){let t=(0,l.eW)();t&&(e.eventId=t)}let i=y.m9.document.createElement("script");i.async=!0,i.crossOrigin="anonymous",i.src=(0,c.h)(n,e),e.onLoad&&(i.onload=e.onLoad);let{onClose:s}=e;if(s){let e=t=>{if("__sentry_reportdialog_closed__"===t.data)try{s()}finally{y.m9.removeEventListener("message",e)}};y.m9.addEventListener("message",e)}let o=y.m9.document.head||y.m9.document.body;o?o.appendChild(i):g.X&&d.kg.error("Not injecting report dialog. No injection point found in HTML")}},55525:function(e,t,r){"use strict";r.d(t,{Dt:function(){return f}});var n=r(42283);function i(e,t,r,i){let s={filename:e,function:"<anonymous>"===t?n.Fi:t,in_app:!0};return void 0!==r&&(s.lineno=r),void 0!==i&&(s.colno=i),s}let s=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,o=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,a=/\((\S*)(?::(\d+))(?::(\d+))\)/,u=[30,e=>{let t=s.exec(e);if(t){let[,e,r,s]=t;return i(e,n.Fi,+r,+s)}let r=o.exec(e);if(r){if(r[2]&&0===r[2].indexOf("eval")){let e=a.exec(r[2]);e&&(r[2]=e[1],r[3]=e[2],r[4]=e[3])}let[e,t]=h(r[1]||n.Fi,r[2]);return i(t,e,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}}],l=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,c=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,d=[50,e=>{let t=l.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){let e=c.exec(t[3]);e&&(t[1]=t[1]||"eval",t[3]=e[1],t[4]=e[2],t[5]="")}let e=t[3],r=t[1]||n.Fi;return[r,e]=h(r,e),i(e,r,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],f=(0,n.pE)(u,d),h=(e,t)=>{let r=-1!==e.indexOf("safari-extension"),i=-1!==e.indexOf("safari-web-extension");return r||i?[-1!==e.indexOf("@")?e.split("@")[0]:n.Fi,r?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]}},45976:function(e,t,r){"use strict";r.d(t,{f:function(){return d}});var n=r(39877),i=r(16825),s=r(80128),o=r(39432),a=r(83745),u=r(41001),l=r(94223);function c(e,t){if("event"===t||"transaction"===t)return Array.isArray(e)?e[1]:void 0}function d(e,t=(0,n.L2)("fetch")){let r=0,d=0;return function(e,t,r=function(e){let t=[];function r(e){return t.splice(t.indexOf(e),1)[0]||Promise.resolve(void 0)}return{$:t,add:function(n){if(!(void 0===e||t.length<e))return(0,s.$2)(new i.b("Not adding Promise because buffer limit was reached."));let o=n();return -1===t.indexOf(o)&&t.push(o),o.then(()=>r(o)).then(null,()=>r(o).then(null,()=>{})),o},drain:function(e){return new s.cW((r,n)=>{let i=t.length;if(!i)return r(!0);let o=setTimeout(()=>{e&&e>0&&r(!1)},e);t.forEach(e=>{(0,s.WD)(e).then(()=>{--i||(clearTimeout(o),r(!0))},n)})})}}}(e.bufferSize||64)){let n={};return{send:function(d){let f=[];if((0,o.gv)(d,(t,r)=>{let i=(0,o.mL)(r);if((0,a.Q)(n,i)){let n=c(t,r);e.recordDroppedEvent("ratelimit_backoff",i,n)}else f.push(t)}),0===f.length)return(0,s.WD)({});let h=(0,o.Jd)(d[0],f),p=t=>{(0,o.gv)(h,(r,n)=>{let i=c(r,n);e.recordDroppedEvent(t,(0,o.mL)(n),i)})};return r.add(()=>t({body:(0,o.V$)(h)}).then(e=>(void 0!==e.statusCode&&(e.statusCode<200||e.statusCode>=300)&&l.X&&u.kg.warn(`Sentry responded with status code ${e.statusCode} to sent event.`),n=(0,a.WG)(n,e),e),e=>{throw p("network_error"),e})).then(e=>e,e=>{if(e instanceof i.b)return l.X&&u.kg.error("Skipped sending event because buffer is full."),p("queue_overflow"),(0,s.WD)({});throw e})},flush:e=>r.drain(e)}}(e,function(i){let o=i.body.length;r+=o,d++;let a={body:i.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:r<=6e4&&d<15,...e.fetchOptions};if(!t)return(0,n._6)("fetch"),(0,s.$2)("No fetch implementation available");try{return t(e.url,a).then(e=>(r-=o,d--,{statusCode:e.status,headers:{"x-sentry-rate-limits":e.headers.get("X-Sentry-Rate-Limits"),"retry-after":e.headers.get("Retry-After")}}))}catch(e){return(0,n._6)("fetch"),r-=o,d--,(0,s.$2)(e)}})}},66013:function(e,t,r){"use strict";r.d(t,{U:function(){return o},h:function(){return a}});var n=r(27179),i=r(73326);function s(e){let t=e.protocol?`${e.protocol}:`:"",r=e.port?`:${e.port}`:"";return`${t}//${e.host}${r}${e.path?`/${e.path}`:""}/api/`}function o(e,t,r){return t||`${s(e)}${e.projectId}/envelope/?${(0,n._j)({sentry_key:e.publicKey,sentry_version:"7",...r&&{sentry_client:`${r.name}/${r.version}`}})}`}function a(e,t){let r=(0,i.vK)(e);if(!r)return"";let n=`${s(r)}embed/error-page/`,o=`dsn=${(0,i.RA)(r)}`;for(let e in t)if("dsn"!==e&&"onClose"!==e){if("user"===e){let e=t.user;if(!e)continue;e.name&&(o+=`&name=${encodeURIComponent(e.name)}`),e.email&&(o+=`&email=${encodeURIComponent(e.email)}`)}else o+=`&${encodeURIComponent(e)}=${encodeURIComponent(t[e])}`}return`${n}?${o}`}},60811:function(e,t,r){"use strict";r.d(t,{G:function(){return f}});var n=r(13533),i=r(16824),s=r(29531),o=r(43927);class a{constructor(e,t){let r,n;r=e||new o.s,n=t||new o.s,this._stack=[{scope:r}],this._isolationScope=n}withScope(e){let t;let r=this._pushScope();try{t=e(r)}catch(e){throw this._popScope(),e}return(0,i.J8)(t)?t.then(e=>(this._popScope(),e),e=>{throw this._popScope(),e}):(this._popScope(),t)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){let e=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:e}),e}_popScope(){return!(this._stack.length<=1)&&!!this._stack.pop()}}function u(){let e=(0,n.c)(),t=(0,n.q)(e);return t.stack=t.stack||new a((0,s.Y)("defaultCurrentScope",()=>new o.s),(0,s.Y)("defaultIsolationScope",()=>new o.s))}function l(e){return u().withScope(e)}function c(e,t){let r=u();return r.withScope(()=>(r.getStackTop().scope=e,t(e)))}function d(e){return u().withScope(()=>e(u().getIsolationScope()))}function f(e){let t=(0,n.q)(e);return t.acs?t.acs:{withIsolationScope:d,withScope:l,withSetScope:c,withSetIsolationScope:(e,t)=>d(t),getCurrentScope:()=>u().getScope(),getIsolationScope:()=>u().getIsolationScope()}}},37895:function(e,t,r){"use strict";r.d(t,{n:function(){return o}});var n=r(26181),i=r(41001),s=r(73076);function o(e,t){let r=(0,s.s3)(),o=(0,s.aF)();if(!r)return;let{beforeBreadcrumb:a=null,maxBreadcrumbs:u=100}=r.getOptions();if(u<=0)return;let l={timestamp:(0,n.yW)(),...e},c=a?(0,i.Cf)(()=>a(l,t)):l;null!==c&&(r.emit&&r.emit("beforeAddBreadcrumb",c,t),o.addBreadcrumb(c,u))}},13533:function(e,t,r){"use strict";r.d(t,{c:function(){return s},q:function(){return o}});var n=r(29531),i=r(42990);function s(){return o(n.GLOBAL_OBJ),n.GLOBAL_OBJ}function o(e){let t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||i.J,t[i.J]=t[i.J]||{}}},73243:function(e,t,r){"use strict";r.d(t,{J:function(){return n}});let n="production"},73076:function(e,t,r){"use strict";r.d(t,{$e:function(){return c},aF:function(){return u},lW:function(){return l},nZ:function(){return a},s3:function(){return d}});var n=r(29531),i=r(60811),s=r(13533),o=r(43927);function a(){let e=(0,s.c)();return(0,i.G)(e).getCurrentScope()}function u(){let e=(0,s.c)();return(0,i.G)(e).getIsolationScope()}function l(){return(0,n.Y)("globalScope",()=>new o.s)}function c(...e){let t=(0,s.c)(),r=(0,i.G)(t);if(2===e.length){let[t,n]=e;return t?r.withSetScope(t,n):r.withScope(n)}return r.withScope(e[0])}function d(){return a().getClient()}},94223:function(e,t,r){"use strict";r.d(t,{X:function(){return n}});let n="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},11793:function(e,t,r){"use strict";r.d(t,{Mq:function(){return u},Q3:function(){return a},uE:function(){return l}});var n=r(39432),i=r(73326),s=r(72123),o=r(81585);function a(e,t,r,s){let o=(0,n.HY)(r),a={sent_at:new Date().toISOString(),...o&&{sdk:o},...!!s&&t&&{dsn:(0,i.RA)(t)}},u="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return(0,n.Jd)(a,[u])}function u(e,t,r,i){var s;let o=(0,n.HY)(r),a=e.type&&"replay_event"!==e.type?e.type:"event";(s=r&&r.sdk)&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||s.name,e.sdk.version=e.sdk.version||s.version,e.sdk.integrations=[...e.sdk.integrations||[],...s.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...s.packages||[]]);let u=(0,n.Cd)(e,o,i,t);delete e.sdkProcessingMetadata;let l=[{type:a},e];return(0,n.Jd)(u,[l])}function l(e,t){let r=(0,s.jC)(e[0]),a=t&&t.getDsn(),u=t&&t.getOptions().tunnel,l={sent_at:new Date().toISOString(),...!!r.trace_id&&!!r.public_key&&{trace:r},...!!u&&a&&{dsn:(0,i.RA)(a)}},c=t&&t.getOptions().beforeSendSpan,d=c?e=>c((0,o.XU)(e)):e=>(0,o.XU)(e),f=[];for(let t of e){let e=d(t);e&&f.push((0,n.KQ)(e))}return(0,n.Jd)(l,f)}},90988:function(e,t,r){"use strict";r.d(t,{R:function(){return function e(t,r,a,u=0){return new n.cW((n,l)=>{let c=t[u];if(null===r||"function"!=typeof c)n(r);else{let d=c({...r},a);o.X&&c.id&&null===d&&i.kg.log(`Event processor "${c.id}" dropped event`),(0,s.J8)(d)?d.then(r=>e(t,r,a,u+1).then(n)).then(null,l):e(t,d,a,u+1).then(n).then(null,l)}})}}});var n=r(80128),i=r(41001),s=r(16824),o=r(94223)},39424:function(e,t,r){"use strict";r.d(t,{Qy:function(){return y},Tb:function(){return c},YA:function(){return h},av:function(){return p},cg:function(){return S},eN:function(){return d},eW:function(){return m},v:function(){return f},yj:function(){return v},yl:function(){return g}});var n=r(41001),i=r(29531),s=r(73243),o=r(73076),a=r(94223),u=r(10042),l=r(76247);function c(e,t){return(0,o.nZ)().captureException(e,(0,l.U0)(t))}function d(e,t){return(0,o.nZ)().captureEvent(e,t)}function f(e,t){(0,o.aF)().setContext(e,t)}function h(e,t){(0,o.aF)().setTag(e,t)}function p(e){(0,o.aF)().setUser(e)}function m(){return(0,o.aF)().lastEventId()}async function g(e){let t=(0,o.s3)();return t?t.flush(e):(a.X&&n.kg.warn("Cannot flush events. No client defined."),Promise.resolve(!1))}function y(e){(0,o.aF)().addEventProcessor(e)}function v(e){let t=(0,o.s3)(),r=(0,o.aF)(),n=(0,o.nZ)(),{release:a,environment:l=s.J}=t&&t.getOptions()||{},{userAgent:c}=i.GLOBAL_OBJ.navigator||{},d=(0,u.Hv)({release:a,environment:l,user:n.getUser()||r.getUser(),...c&&{userAgent:c},...e}),f=r.getSession();return f&&"ok"===f.status&&(0,u.CT)(f,{status:"exited"}),_(),r.setSession(d),n.setSession(d),d}function _(){let e=(0,o.aF)(),t=(0,o.nZ)(),r=t.getSession()||e.getSession();r&&(0,u.RJ)(r),b(),e.setSession(),t.setSession()}function b(){let e=(0,o.aF)(),t=(0,o.nZ)(),r=(0,o.s3)(),n=t.getSession()||e.getSession();n&&r&&r.captureSession(n)}function S(e=!1){if(e){_();return}b()}},58942:function(e,t,r){"use strict";r.d(t,{_I:function(){return d},m7:function(){return c},m8:function(){return a},q4:function(){return u},uf:function(){return l}});var n=r(41982),i=r(41001),s=r(94223);let o=[];function a(e){let t=e.defaultIntegrations||[],r=e.integrations;t.forEach(e=>{e.isDefaultInstance=!0});let i=function(e){let t={};return e.forEach(e=>{let{name:r}=e,n=t[r];n&&!n.isDefaultInstance&&e.isDefaultInstance||(t[r]=e)}),Object.values(t)}(Array.isArray(r)?[...t,...r]:"function"==typeof r?(0,n.lE)(r(t)):t),s=i.findIndex(e=>"Debug"===e.name);if(s>-1){let[e]=i.splice(s,1);i.push(e)}return i}function u(e,t){let r={};return t.forEach(t=>{t&&c(e,t,r)}),r}function l(e,t){for(let r of t)r&&r.afterAllSetup&&r.afterAllSetup(e)}function c(e,t,r){if(r[t.name]){s.X&&i.kg.log(`Integration skipped because it was already installed: ${t.name}`);return}if(r[t.name]=t,-1===o.indexOf(t.name)&&"function"==typeof t.setupOnce&&(t.setupOnce(),o.push(t.name)),t.setup&&"function"==typeof t.setup&&t.setup(e),"function"==typeof t.preprocessEvent){let r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(t,n)=>r(t,n,e))}if("function"==typeof t.processEvent){let r=t.processEvent.bind(t),n=Object.assign((t,n)=>r(t,n,e),{id:t.name});e.addEventProcessor(n)}s.X&&i.kg.log(`Integration installed: ${t.name}`)}function d(e){return e}},90092:function(e,t,r){"use strict";r.d(t,{R:function(){return a}});var n=r(41001),i=r(42283),s=r(58942),o=r(94223);let a=(0,s._I)(()=>{let e;return{name:"Dedupe",processEvent(t){if(t.type)return t;try{var r;if((r=e)&&(function(e,t){let r=e.message,n=t.message;return!!((r||n)&&(!r||n)&&(r||!n)&&r===n&&l(e,t)&&u(e,t))}(t,r)||function(e,t){let r=c(t),n=c(e);return!!(r&&n&&r.type===n.type&&r.value===n.value&&l(e,t)&&u(e,t))}(t,r)))return o.X&&n.kg.warn("Event dropped due to being a duplicate of previously captured event."),null}catch(e){}return e=t}}});function u(e,t){let r=(0,i.Fr)(e),n=(0,i.Fr)(t);if(!r&&!n)return!0;if(r&&!n||!r&&n||n.length!==r.length)return!1;for(let e=0;e<n.length;e++){let t=n[e],i=r[e];if(t.filename!==i.filename||t.lineno!==i.lineno||t.colno!==i.colno||t.function!==i.function)return!1}return!0}function l(e,t){let r=e.fingerprint,n=t.fingerprint;if(!r&&!n)return!0;if(r&&!n||!r&&n)return!1;try{return!(r.join("")!==n.join(""))}catch(e){return!1}}function c(e){return e.exception&&e.exception.values&&e.exception.values[0]}},93790:function(e,t,r){"use strict";let n;r.d(t,{C:function(){return u}});var i=r(27179),s=r(73076),o=r(58942);let a=new WeakMap,u=(0,o._I)(()=>({name:"FunctionToString",setupOnce(){n=Function.prototype.toString;try{Function.prototype.toString=function(...e){let t=(0,i.HK)(this),r=a.has((0,s.s3)())&&void 0!==t?t:this;return n.apply(r,e)}}catch(e){}},setup(e){a.set(e,!0)}}))},87228:function(e,t,r){"use strict";r.d(t,{S:function(){return l}});var n=r(41001),i=r(41982),s=r(89163),o=r(94223),a=r(58942);let u=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,"undefined is not an object (evaluating 'a.L')",'can\'t redefine non-configurable property "solana"',"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler"],l=(0,a._I)((e={})=>({name:"InboundFilters",processEvent:(t,r,a)=>{var l,d;return((l=function(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:u],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]],ignoreInternal:void 0===e.ignoreInternal||e.ignoreInternal}}(e,a.getOptions())).ignoreInternal&&function(e){try{return"SentryError"===e.exception.values[0].type}catch(e){}return!1}(t)?(o.X&&n.kg.warn(`Event dropped due to being internal Sentry Error.
Event: ${(0,i.jH)(t)}`),0):(d=l.ignoreErrors,!t.type&&d&&d.length&&(function(e){let t;let r=[];e.message&&r.push(e.message);try{t=e.exception.values[e.exception.values.length-1]}catch(e){}return t&&t.value&&(r.push(t.value),t.type&&r.push(`${t.type}: ${t.value}`)),r})(t).some(e=>(0,s.U0)(e,d)))?(o.X&&n.kg.warn(`Event dropped due to being matched by \`ignoreErrors\` option.
Event: ${(0,i.jH)(t)}`),0):t.type||!t.exception||!t.exception.values||0===t.exception.values.length||t.message||t.exception.values.some(e=>e.stacktrace||e.type&&"Error"!==e.type||e.value)?!function(e,t){if("transaction"!==e.type||!t||!t.length)return!1;let r=e.transaction;return!!r&&(0,s.U0)(r,t)}(t,l.ignoreTransactions)?!function(e,t){if(!t||!t.length)return!1;let r=c(e);return!!r&&(0,s.U0)(r,t)}(t,l.denyUrls)?function(e,t){if(!t||!t.length)return!0;let r=c(e);return!r||(0,s.U0)(r,t)}(t,l.allowUrls)||(o.X&&n.kg.warn(`Event dropped due to not being matched by \`allowUrls\` option.
Event: ${(0,i.jH)(t)}.
Url: ${c(t)}`),0):(o.X&&n.kg.warn(`Event dropped due to being matched by \`denyUrls\` option.
Event: ${(0,i.jH)(t)}.
Url: ${c(t)}`),0):(o.X&&n.kg.warn(`Event dropped due to being matched by \`ignoreTransactions\` option.
Event: ${(0,i.jH)(t)}`),0):(o.X&&n.kg.warn(`Event dropped due to not having an error message, error type or stacktrace.
Event: ${(0,i.jH)(t)}`),0))?t:null}}));function c(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch(e){}return t?function(e=[]){for(let t=e.length-1;t>=0;t--){let r=e[t];if(r&&"<anonymous>"!==r.filename&&"[native code]"!==r.filename)return r.filename||null}return null}(t):null}catch(t){return o.X&&n.kg.error(`Cannot extract url for event ${(0,i.jH)(e)}`),null}}},72751:function(e,t,r){"use strict";r.d(t,{y:function(){return i}});var n=r(27179);function i(e){let t=e._sentryMetrics;if(!t)return;let r={};for(let[,[e,i]]of t)(r[e]||(r[e]=[])).push((0,n.Jr)(i));return r}},43927:function(e,t,r){"use strict";r.d(t,{s:function(){return d}});var n=r(19548),i=r(16824),s=r(26181),o=r(41982),a=r(41001),u=r(10042),l=r(89366);class c{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=(0,n.Q)()}clone(){let e=new c;return e._breadcrumbs=[...this._breadcrumbs],e._tags={...this._tags},e._extra={...this._extra},e._contexts={...this._contexts},e._user=this._user,e._level=this._level,e._session=this._session,e._transactionName=this._transactionName,e._fingerprint=this._fingerprint,e._eventProcessors=[...this._eventProcessors],e._requestSession=this._requestSession,e._attachments=[...this._attachments],e._sdkProcessingMetadata={...this._sdkProcessingMetadata},e._propagationContext={...this._propagationContext},e._client=this._client,e._lastEventId=this._lastEventId,(0,l.D)(e,(0,l.Y)(this)),e}setClient(e){this._client=e}setLastEventId(e){this._lastEventId=e}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(e){this._scopeListeners.push(e)}addEventProcessor(e){return this._eventProcessors.push(e),this}setUser(e){return this._user=e||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&(0,u.CT)(this._session,{user:e}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(e){return this._requestSession=e,this}setTags(e){return this._tags={...this._tags,...e},this._notifyScopeListeners(),this}setTag(e,t){return this._tags={...this._tags,[e]:t},this._notifyScopeListeners(),this}setExtras(e){return this._extra={...this._extra,...e},this._notifyScopeListeners(),this}setExtra(e,t){return this._extra={...this._extra,[e]:t},this._notifyScopeListeners(),this}setFingerprint(e){return this._fingerprint=e,this._notifyScopeListeners(),this}setLevel(e){return this._level=e,this._notifyScopeListeners(),this}setTransactionName(e){return this._transactionName=e,this._notifyScopeListeners(),this}setContext(e,t){return null===t?delete this._contexts[e]:this._contexts[e]=t,this._notifyScopeListeners(),this}setSession(e){return e?this._session=e:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(e){if(!e)return this;let t="function"==typeof e?e(this):e,[r,n]=t instanceof d?[t.getScopeData(),t.getRequestSession()]:(0,i.PO)(t)?[e,e.requestSession]:[],{tags:s,extra:o,user:a,contexts:u,level:l,fingerprint:c=[],propagationContext:f}=r||{};return this._tags={...this._tags,...s},this._extra={...this._extra,...o},this._contexts={...this._contexts,...u},a&&Object.keys(a).length&&(this._user=a),l&&(this._level=l),c.length&&(this._fingerprint=c),f&&(this._propagationContext=f),n&&(this._requestSession=n),this}clear(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._requestSession=void 0,this._session=void 0,(0,l.D)(this,void 0),this._attachments=[],this._propagationContext=(0,n.Q)(),this._notifyScopeListeners(),this}addBreadcrumb(e,t){let r="number"==typeof t?t:100;if(r<=0)return this;let n={timestamp:(0,s.yW)(),...e},i=this._breadcrumbs;return i.push(n),this._breadcrumbs=i.length>r?i.slice(-r):i,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(e){return this._attachments.push(e),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:(0,l.Y)(this)}}setSDKProcessingMetadata(e){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...e},this}setPropagationContext(e){return this._propagationContext=e,this}getPropagationContext(){return this._propagationContext}captureException(e,t){let r=t&&t.event_id?t.event_id:(0,o.DM)();if(!this._client)return a.kg.warn("No client configured on scope - will not capture exception!"),r;let n=Error("Sentry syntheticException");return this._client.captureException(e,{originalException:e,syntheticException:n,...t,event_id:r},this),r}captureMessage(e,t,r){let n=r&&r.event_id?r.event_id:(0,o.DM)();if(!this._client)return a.kg.warn("No client configured on scope - will not capture message!"),n;let i=Error(e);return this._client.captureMessage(e,t,{originalException:e,syntheticException:i,...r,event_id:n},this),n}captureEvent(e,t){let r=t&&t.event_id?t.event_id:(0,o.DM)();return this._client?this._client.captureEvent(e,{...t,event_id:r},this):a.kg.warn("No client configured on scope - will not capture event!"),r}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(e=>{e(this)}),this._notifyingListeners=!1)}}let d=c},66516:function(e,t,r){"use strict";r.d(t,{M:function(){return o}});var n=r(41001),i=r(73076),s=r(94223);function o(e,t){!0===t.debug&&(s.X?n.kg.enable():(0,n.Cf)(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),(0,i.nZ)().update(t.initialScope);let r=new e(t);return(0,i.nZ)().setClient(r),r.init(),r}},31218:function(e,t,r){"use strict";r.d(t,{$J:function(){return s},E1:function(){return u},JQ:function(){return d},S3:function(){return o},TE:function(){return i},Wb:function(){return l},Zj:function(){return n},ju:function(){return a},p6:function(){return c}});let n="sentry.source",i="sentry.sample_rate",s="sentry.op",o="sentry.origin",a="sentry.idle_span_finish_reason",u="sentry.measurement_unit",l="sentry.measurement_value",c="sentry.profile_id",d="sentry.exclusive_time"},10042:function(e,t,r){"use strict";r.d(t,{CT:function(){return a},Hv:function(){return o},RJ:function(){return u}});var n=r(26181),i=r(41982),s=r(27179);function o(e){let t=(0,n.ph)(),r={sid:(0,i.DM)(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>(0,s.Jr)({sid:`${r.sid}`,init:r.init,started:new Date(1e3*r.started).toISOString(),timestamp:new Date(1e3*r.timestamp).toISOString(),status:r.status,errors:r.errors,did:"number"==typeof r.did||"string"==typeof r.did?`${r.did}`:void 0,duration:r.duration,abnormal_mechanism:r.abnormal_mechanism,attrs:{release:r.release,environment:r.environment,ip_address:r.ipAddress,user_agent:r.userAgent}})};return e&&a(r,e),r}function a(e,t={}){if(!t.user||(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),e.did||t.did||(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||(0,n.ph)(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=32===t.sid.length?t.sid:(0,i.DM)()),void 0!==t.init&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),"number"==typeof t.started&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if("number"==typeof t.duration)e.duration=t.duration;else{let t=e.timestamp-e.started;e.duration=t>=0?t:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),"number"==typeof t.errors&&(e.errors=t.errors),t.status&&(e.status=t.status)}function u(e,t){let r={};t?r={status:t}:"ok"===e.status&&(r={status:"exited"}),a(e,r)}},72123:function(e,t,r){"use strict";r.d(t,{Lh:function(){return c},_l:function(){return d},jC:function(){return f}});var n=r(27179),i=r(60859),s=r(73243),o=r(73076),a=r(31218),u=r(81585);let l="_frozenDsc";function c(e,t){(0,n.xp)(e,l,t)}function d(e,t){let r=t.getOptions(),{publicKey:i}=t.getDsn()||{},o=(0,n.Jr)({environment:r.environment||s.J,release:r.release,public_key:i,trace_id:e});return t.emit("createDsc",o),o}function f(e){let t=(0,o.s3)();if(!t)return{};let r=d((0,u.XU)(e).trace_id||"",t),n=(0,u.Gx)(e),s=n[l];if(s)return s;let c=n.spanContext().traceState,f=c&&c.get("sentry.dsc"),h=f&&(0,i.EN)(f);if(h)return h;let p=(0,u.XU)(n),m=p.data||{},g=m[a.TE];null!=g&&(r.sample_rate=`${g}`);let y=m[a.Zj],v=p.description;return"url"!==y&&v&&(r.transaction=v),r.sampled=String((0,u.Tt)(n)),t.emit("createDsc",r,n),r}},69737:function(e,t,r){"use strict";r.d(t,{OP:function(){return i},Q0:function(){return o},jt:function(){return s},pq:function(){return n}});let n=0,i=1,s=2;function o(e,t){e.setAttribute("http.response.status_code",t);let r=function(e){if(e<400&&e>=100)return{code:i};if(e>=400&&e<500)switch(e){case 401:return{code:s,message:"unauthenticated"};case 403:return{code:s,message:"permission_denied"};case 404:return{code:s,message:"not_found"};case 409:return{code:s,message:"already_exists"};case 413:return{code:s,message:"failed_precondition"};case 429:return{code:s,message:"resource_exhausted"};case 499:return{code:s,message:"cancelled"};default:return{code:s,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:s,message:"unimplemented"};case 503:return{code:s,message:"unavailable"};case 504:return{code:s,message:"deadline_exceeded"};default:return{code:s,message:"internal_error"}}return{code:s,message:"unknown_error"}}(t);"unknown_error"!==r.message&&e.setStatus(r)}},62821:function(e,t,r){"use strict";r.d(t,{gi:function(){return a},yo:function(){return u}});var n=r(27179),i=r(41982),s=r(72123),o=r(81585);function a(e,t){let{fingerprint:r,span:a,breadcrumbs:u,sdkProcessingMetadata:l}=t;(function(e,t){let{extra:r,tags:i,user:s,contexts:o,level:a,transactionName:u}=t,l=(0,n.Jr)(r);l&&Object.keys(l).length&&(e.extra={...l,...e.extra});let c=(0,n.Jr)(i);c&&Object.keys(c).length&&(e.tags={...c,...e.tags});let d=(0,n.Jr)(s);d&&Object.keys(d).length&&(e.user={...d,...e.user});let f=(0,n.Jr)(o);f&&Object.keys(f).length&&(e.contexts={...f,...e.contexts}),a&&(e.level=a),u&&"transaction"!==e.type&&(e.transaction=u)})(e,t),a&&function(e,t){e.contexts={trace:(0,o.wy)(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:(0,s.jC)(t),...e.sdkProcessingMetadata};let r=(0,o.Gx)(t),n=(0,o.XU)(r).description;n&&!e.transaction&&"transaction"===e.type&&(e.transaction=n)}(e,a),e.fingerprint=e.fingerprint?(0,i.lE)(e.fingerprint):[],r&&(e.fingerprint=e.fingerprint.concat(r)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint,function(e,t){let r=[...e.breadcrumbs||[],...t];e.breadcrumbs=r.length?r:void 0}(e,u),e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...l}}function u(e,t){let{extra:r,tags:n,user:i,contexts:s,level:o,sdkProcessingMetadata:a,breadcrumbs:u,fingerprint:c,eventProcessors:d,attachments:f,propagationContext:h,transactionName:p,span:m}=t;l(e,"extra",r),l(e,"tags",n),l(e,"user",i),l(e,"contexts",s),l(e,"sdkProcessingMetadata",a),o&&(e.level=o),p&&(e.transactionName=p),m&&(e.span=m),u.length&&(e.breadcrumbs=[...e.breadcrumbs,...u]),c.length&&(e.fingerprint=[...e.fingerprint,...c]),d.length&&(e.eventProcessors=[...e.eventProcessors,...d]),f.length&&(e.attachments=[...e.attachments,...f]),e.propagationContext={...e.propagationContext,...h}}function l(e,t,r){if(r&&Object.keys(r).length)for(let n in e[t]={...e[t]},r)Object.prototype.hasOwnProperty.call(r,n)&&(e[t][n]=r[n])}},79769:function(e,t,r){"use strict";r.d(t,{o:function(){return s}});var n=r(41001),i=r(94223);function s(e){if("boolean"==typeof e)return Number(e);let t="string"==typeof e?parseFloat(e):e;if("number"!=typeof t||isNaN(t)||t<0||t>1){i.X&&n.kg.warn(`[Tracing] Given sample rate is invalid. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(e)} of type ${JSON.stringify(typeof e)}.`);return}return t}},76247:function(e,t,r){"use strict";r.d(t,{R:function(){return h},U0:function(){return m}});var n=r(41982),i=r(26181),s=r(89163),o=r(29531),a=r(83408),u=r(73243),l=r(73076),c=r(90988),d=r(43927),f=r(62821);function h(e,t,r,h,m,g){let{normalizeDepth:y=3,normalizeMaxBreadth:v=1e3}=e,_={...t,event_id:t.event_id||r.event_id||(0,n.DM)(),timestamp:t.timestamp||(0,i.yW)()},b=r.integrations||e.integrations.map(e=>e.name);(function(e,t){let{environment:r,release:n,dist:i,maxValueLength:o=250}=t;"environment"in e||(e.environment="environment"in t?r:u.J),void 0===e.release&&void 0!==n&&(e.release=n),void 0===e.dist&&void 0!==i&&(e.dist=i),e.message&&(e.message=(0,s.$G)(e.message,o));let a=e.exception&&e.exception.values&&e.exception.values[0];a&&a.value&&(a.value=(0,s.$G)(a.value,o));let l=e.request;l&&l.url&&(l.url=(0,s.$G)(l.url,o))})(_,e),b.length>0&&(_.sdk=_.sdk||{},_.sdk.integrations=[..._.sdk.integrations||[],...b]),m&&m.emit("applyFrameMetadata",t),void 0===t.type&&function(e,t){let r;let n=o.GLOBAL_OBJ._sentryDebugIds;if(!n)return;let i=p.get(t);i?r=i:(r=new Map,p.set(t,r));let s=Object.entries(n).reduce((e,[n,i])=>{let s;let o=r.get(n);o?s=o:(s=t(n),r.set(n,s));for(let t=s.length-1;t>=0;t--){let r=s[t];if(r.filename){e[r.filename]=i;break}}return e},{});try{e.exception.values.forEach(e=>{e.stacktrace.frames.forEach(e=>{e.filename&&(e.debug_id=s[e.filename])})})}catch(e){}}(_,e.stackParser);let S=function(e,t){if(!t)return e;let r=e?e.clone():new d.s;return r.update(t),r}(h,r.captureContext);r.mechanism&&(0,n.EG)(_,r.mechanism);let E=m?m.getEventProcessors():[],w=(0,l.lW)().getScopeData();if(g){let e=g.getScopeData();(0,f.yo)(w,e)}if(S){let e=S.getScopeData();(0,f.yo)(w,e)}let O=[...r.attachments||[],...w.attachments];O.length&&(r.attachments=O),(0,f.gi)(_,w);let k=[...E,...w.eventProcessors];return(0,c.R)(k,_,r).then(e=>(e&&function(e){let t={};try{e.exception.values.forEach(e=>{e.stacktrace.frames.forEach(e=>{e.debug_id&&(e.abs_path?t[e.abs_path]=e.debug_id:e.filename&&(t[e.filename]=e.debug_id),delete e.debug_id)})})}catch(e){}if(0===Object.keys(t).length)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];let r=e.debug_meta.images;Object.entries(t).forEach(([e,t])=>{r.push({type:"sourcemap",code_file:e,debug_id:t})})}(e),"number"==typeof y&&y>0)?function(e,t,r){if(!e)return null;let n={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(e=>({...e,...e.data&&{data:(0,a.Fv)(e.data,t,r)}}))},...e.user&&{user:(0,a.Fv)(e.user,t,r)},...e.contexts&&{contexts:(0,a.Fv)(e.contexts,t,r)},...e.extra&&{extra:(0,a.Fv)(e.extra,t,r)}};return e.contexts&&e.contexts.trace&&n.contexts&&(n.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(n.contexts.trace.data=(0,a.Fv)(e.contexts.trace.data,t,r))),e.spans&&(n.spans=e.spans.map(e=>({...e,...e.data&&{data:(0,a.Fv)(e.data,t,r)}}))),n}(e,y,v):e)}let p=new WeakMap;function m(e){return e?e instanceof d.s||"function"==typeof e||Object.keys(e).some(e=>g.includes(e))?{captureContext:e}:e:void 0}let g=["user","level","extra","contexts","tags","fingerprint","requestSession","propagationContext"]},7659:function(e,t,r){"use strict";r.d(t,{V:function(){return i}});var n=r(42990);function i(e,t,r=[t],i="npm"){let s=e._metadata||{};s.sdk||(s.sdk={name:`sentry.javascript.${t}`,packages:r.map(e=>({name:`${i}:@sentry/${e}`,version:n.J})),version:n.J}),e._metadata=s}},89366:function(e,t,r){"use strict";r.d(t,{D:function(){return s},Y:function(){return o}});var n=r(27179);let i="_sentrySpan";function s(e,t){t?(0,n.xp)(e,i,t):delete e[i]}function o(e){return e[i]}},81585:function(e,t,r){"use strict";r.d(t,{$k:function(){return v},Dp:function(){return C},Gx:function(){return I},HN:function(){return R},HR:function(){return m},Hb:function(){return y},Tt:function(){return S},XU:function(){return b},_4:function(){return E},ed:function(){return T},i0:function(){return p},j5:function(){return k},ve:function(){return h},wy:function(){return g}});var n=r(27179),i=r(85712),s=r(26181),o=r(60811),a=r(13533),u=r(73076),l=r(72751),c=r(31218),d=r(69737),f=r(89366);let h=0,p=1;function m(e){let{spanId:t,traceId:r}=e.spanContext(),{data:i,op:s,parent_span_id:o,status:a,origin:u}=b(e);return(0,n.Jr)({parent_span_id:o,span_id:t,trace_id:r,data:i,op:s,status:a,origin:u})}function g(e){let{spanId:t,traceId:r}=e.spanContext(),{parent_span_id:i}=b(e);return(0,n.Jr)({parent_span_id:i,span_id:t,trace_id:r})}function y(e){let{traceId:t,spanId:r}=e.spanContext(),n=S(e);return(0,i.$p)(t,r,n)}function v(e){return"number"==typeof e?_(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?_(e.getTime()):(0,s.ph)()}function _(e){return e>9999999999?e/1e3:e}function b(e){if("function"==typeof e.getSpanJSON)return e.getSpanJSON();try{let{spanId:t,traceId:r}=e.spanContext();if(e.attributes&&e.startTime&&e.name&&e.endTime&&e.status){let{attributes:i,startTime:s,name:o,endTime:a,parentSpanId:u,status:d}=e;return(0,n.Jr)({span_id:t,trace_id:r,data:i,description:o,parent_span_id:u,start_timestamp:v(s),timestamp:v(a)||void 0,status:E(d),op:i[c.$J],origin:i[c.S3],_metrics_summary:(0,l.y)(e)})}return{span_id:t,trace_id:r}}catch(e){return{}}}function S(e){let{traceFlags:t}=e.spanContext();return t===p}function E(e){return e&&e.code!==d.pq?e.code===d.OP?"ok":e.message||"unknown_error":void 0}let w="_sentryChildSpans",O="_sentryRootSpan";function k(e,t){let r=e[O]||e;(0,n.xp)(t,O,r),e[w]?e[w].add(t):(0,n.xp)(e,w,new Set([t]))}function T(e,t){e[w]&&e[w].delete(t)}function C(e){let t=new Set;return function e(r){if(!t.has(r)&&S(r))for(let n of(t.add(r),r[w]?Array.from(r[w]):[]))e(n)}(e),Array.from(t)}function I(e){return e[O]||e}function R(){let e=(0,a.c)(),t=(0,o.G)(e);return t.getActiveSpan?t.getActiveSpan():(0,f.Y)((0,u.nZ)())}},36096:function(e,t,r){"use strict";r.d(t,{X:function(){return n}});let n="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},56342:function(e,t,r){"use strict";r.d(t,{SV:function(){return d}});var n=r(73076),i=r(75686),s=r(41001);r(8679);var o=r(67294);let a="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__;var u=r(39424),l=r(16824);let c={componentStack:null,error:null,eventId:null};class d extends o.Component{constructor(e){super(e),d.prototype.__init.call(this),this.state=c,this._openFallbackReportDialog=!0;let t=(0,n.s3)();t&&e.showDialog&&(this._openFallbackReportDialog=!1,this._cleanupHook=t.on("afterSendEvent",t=>{!t.type&&this._lastEventId&&t.event_id===this._lastEventId&&(0,i.jp)({...e.dialogOptions,eventId:this._lastEventId})}))}componentDidCatch(e,t){let{componentStack:r}=t,s=null==r?void 0:r,{beforeCapture:a,onError:c,showDialog:d,dialogOptions:f}=this.props;(0,n.$e)(n=>{a&&a(n,e,s);let h=function(e,{componentStack:t},r){if(function(e){let t=e.match(/^([^.]+)/);return null!==t&&parseInt(t[0])>=17}(o.version)&&(0,l.VZ)(e)&&t){let r=Error(e.message);r.name=`React ErrorBoundary ${e.name}`,r.stack=t,function(e,t){let r=new WeakSet;!function e(t,n){if(!r.has(t)){if(t.cause)return r.add(t),e(t.cause,n);t.cause=n}}(e,t)}(e,r)}return(0,u.Tb)(e,{...r,captureContext:{contexts:{react:{componentStack:t}}}})}(e,t,{mechanism:{handled:!!this.props.fallback}});c&&c(e,s,h),d&&(this._lastEventId=h,this._openFallbackReportDialog&&(0,i.jp)({...f,eventId:h})),this.setState({error:e,componentStack:r,eventId:h})})}componentDidMount(){let{onMount:e}=this.props;e&&e()}componentWillUnmount(){let{error:e,componentStack:t,eventId:r}=this.state,{onUnmount:n}=this.props;n&&n(e,t,r),this._cleanupHook&&(this._cleanupHook(),this._cleanupHook=void 0)}__init(){this.resetErrorBoundary=()=>{let{onReset:e}=this.props,{error:t,componentStack:r,eventId:n}=this.state;e&&e(t,r,n),this.setState(c)}}render(){let{fallback:e,children:t}=this.props,r=this.state;if(r.error){let t;return(t="function"==typeof e?o.createElement(e,{error:r.error,componentStack:r.componentStack,resetError:this.resetErrorBoundary,eventId:r.eventId}):e,o.isValidElement(t))?t:(e&&a&&s.kg.warn("fallback did not produce a valid ReactElement"),null)}return"function"==typeof t?t():t}}},60859:function(e,t,r){"use strict";r.d(t,{EN:function(){return l},IQ:function(){return c},bU:function(){return o}});var n=r(1525),i=r(16824),s=r(41001);let o="baggage",a="sentry-",u=/^sentry-/;function l(e){let t=e&&((0,i.HD)(e)||Array.isArray(e))?Array.isArray(e)?e.reduce((e,t)=>(Object.entries(d(t)).forEach(([t,r])=>{e[t]=r}),e),{}):d(e):void 0;if(!t)return;let r=Object.entries(t).reduce((e,[t,r])=>(t.match(u)&&(e[t.slice(a.length)]=r),e),{});return Object.keys(r).length>0?r:void 0}function c(e){if(e)return function(e){if(0!==Object.keys(e).length)return Object.entries(e).reduce((e,[t,r],i)=>{let o=`${encodeURIComponent(t)}=${encodeURIComponent(r)}`,a=0===i?o:`${e},${o}`;return a.length>8192?(n.X&&s.kg.warn(`Not adding key: ${t} with val: ${r} to baggage header due to exceeding baggage size limits.`),e):a},"")}(Object.entries(e).reduce((e,[t,r])=>(r&&(e[`${a}${t}`]=r),e),{}))}function d(e){return e.split(",").map(e=>e.split("=").map(e=>decodeURIComponent(e.trim()))).reduce((e,[t,r])=>(t&&r&&(e[t]=r),e),{})}},1869:function(e,t,r){"use strict";r.d(t,{Rt:function(){return s},iY:function(){return u},l4:function(){return o},qT:function(){return a}});var n=r(16824);let i=r(29531).GLOBAL_OBJ;function s(e,t={}){if(!e)return"<unknown>";try{let r,s=e,o=[],a=0,u=0,l=Array.isArray(t)?t:t.keyAttrs,c=!Array.isArray(t)&&t.maxStringLength||80;for(;s&&a++<5&&(r=function(e,t){let r=[];if(!e||!e.tagName)return"";if(i.HTMLElement&&e instanceof HTMLElement&&e.dataset){if(e.dataset.sentryComponent)return e.dataset.sentryComponent;if(e.dataset.sentryElement)return e.dataset.sentryElement}r.push(e.tagName.toLowerCase());let s=t&&t.length?t.filter(t=>e.getAttribute(t)).map(t=>[t,e.getAttribute(t)]):null;if(s&&s.length)s.forEach(e=>{r.push(`[${e[0]}="${e[1]}"]`)});else{e.id&&r.push(`#${e.id}`);let t=e.className;if(t&&(0,n.HD)(t))for(let e of t.split(/\s+/))r.push(`.${e}`)}for(let t of["aria-label","type","name","title","alt"]){let n=e.getAttribute(t);n&&r.push(`[${t}="${n}"]`)}return r.join("")}(s,l),"html"!==r&&(!(a>1)||!(u+3*o.length+r.length>=c)));)o.push(r),u+=r.length,s=s.parentNode;return o.reverse().join(" > ")}catch(e){return"<unknown>"}}function o(){try{return i.document.location.href}catch(e){return""}}function a(e){return i.document&&i.document.querySelector?i.document.querySelector(e):null}function u(e){if(!i.HTMLElement)return null;let t=e;for(let e=0;e<5&&t;e++){if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}},28643:function(e,t,r){"use strict";function n(e,t){return null!=e?e:t()}r.d(t,{h:function(){return n}})},57608:function(e,t,r){"use strict";function n(e){let t;let r=e[0],n=1;for(;n<e.length;){let i=e[n],s=e[n+1];if(n+=2,("optionalAccess"===i||"optionalCall"===i)&&null==r)return;"access"===i||"optionalAccess"===i?(t=r,r=s(r)):("call"===i||"optionalCall"===i)&&(r=s((...e)=>r.call(t,...e)),t=void 0)}return r}r.d(t,{x:function(){return n}})},1525:function(e,t,r){"use strict";r.d(t,{X:function(){return n}});let n="undefined"==typeof __SENTRY_DEBUG__||__SENTRY_DEBUG__},73326:function(e,t,r){"use strict";r.d(t,{RA:function(){return o},U4:function(){return a},vK:function(){return l}});var n=r(1525),i=r(41001);let s=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function o(e,t=!1){let{host:r,path:n,pass:i,port:s,projectId:o,protocol:a,publicKey:u}=e;return`${a}://${u}${t&&i?`:${i}`:""}@${r}${s?`:${s}`:""}/${n?`${n}/`:n}${o}`}function a(e){let t=s.exec(e);if(!t){(0,i.Cf)(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}let[r,n,o="",a="",l="",c=""]=t.slice(1),d="",f=c,h=f.split("/");if(h.length>1&&(d=h.slice(0,-1).join("/"),f=h.pop()),f){let e=f.match(/^\d+/);e&&(f=e[0])}return u({host:a,pass:o,path:d,projectId:f,port:l,protocol:r,publicKey:n})}function u(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function l(e){let t="string"==typeof e?a(e):u(e);if(t&&function(e){if(!n.X)return!0;let{port:t,projectId:r,protocol:s}=e;return!["protocol","publicKey","host","projectId"].find(t=>!e[t]&&(i.kg.error(`Invalid Sentry Dsn: ${t} missing`),!0))&&(r.match(/^\d+$/)?"http"===s||"https"===s?!(t&&isNaN(parseInt(t,10)))||(i.kg.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):(i.kg.error(`Invalid Sentry Dsn: Invalid protocol ${s}`),!1):(i.kg.error(`Invalid Sentry Dsn: Invalid projectId ${r}`),!1))}(t))return t}},84281:function(e,t,r){"use strict";function n(){return"undefined"!=typeof __SENTRY_BROWSER_BUNDLE__&&!!__SENTRY_BROWSER_BUNDLE__}function i(){return"npm"}r.d(t,{S:function(){return i},n:function(){return n}})},39432:function(e,t,r){"use strict";r.d(t,{BO:function(){return u},Cd:function(){return y},HY:function(){return g},Jd:function(){return a},KQ:function(){return f},V$:function(){return d},gv:function(){return l},mL:function(){return m},zQ:function(){return h}});var n=r(73326),i=r(83408),s=r(27179),o=r(29531);function a(e,t=[]){return[e,t]}function u(e,t){let[r,n]=e;return[r,[...n,t]]}function l(e,t){for(let r of e[1]){let e=r[0].type;if(t(r,e))return!0}return!1}function c(e){return o.GLOBAL_OBJ.__SENTRY__&&o.GLOBAL_OBJ.__SENTRY__.encodePolyfill?o.GLOBAL_OBJ.__SENTRY__.encodePolyfill(e):new TextEncoder().encode(e)}function d(e){let[t,r]=e,n=JSON.stringify(t);function s(e){"string"==typeof n?n="string"==typeof e?n+e:[c(n),e]:n.push("string"==typeof e?c(e):e)}for(let e of r){let[t,r]=e;if(s(`
${JSON.stringify(t)}
`),"string"==typeof r||r instanceof Uint8Array)s(r);else{let e;try{e=JSON.stringify(r)}catch(t){e=JSON.stringify((0,i.Fv)(r))}s(e)}}return"string"==typeof n?n:function(e){let t=new Uint8Array(e.reduce((e,t)=>e+t.length,0)),r=0;for(let n of e)t.set(n,r),r+=n.length;return t}(n)}function f(e){return[{type:"span"},e]}function h(e){let t="string"==typeof e.data?c(e.data):e.data;return[(0,s.Jr)({type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),t]}let p={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",statsd:"metric_bucket"};function m(e){return p[e]}function g(e){if(!e||!e.sdk)return;let{name:t,version:r}=e.sdk;return{name:t,version:r}}function y(e,t,r,i){let o=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!r&&i&&{dsn:(0,n.RA)(i)},...o&&{trace:(0,s.Jr)({...o})}}}},16825:function(e,t,r){"use strict";r.d(t,{b:function(){return n}});class n extends Error{constructor(e,t="warn"){super(e),this.message=e,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=t}}},69024:function(e,t,r){"use strict";r.d(t,{Uf:function(){return l},cf:function(){return c}});var n=r(16824),i=r(27179),s=r(36731),o=r(26181),a=r(29531),u=r(68562);function l(e,t){let r="fetch";(0,u.Hj)(r,e),(0,u.D2)(r,()=>d(void 0,t))}function c(e){let t="fetch-body-resolved";(0,u.Hj)(t,e),(0,u.D2)(t,()=>d(h))}function d(e,t=!1){(!t||(0,s.t$)())&&(0,i.hl)(a.GLOBAL_OBJ,"fetch",function(t){return function(...r){let{method:s,url:l}=function(e){if(0===e.length)return{method:"GET",url:""};if(2===e.length){let[t,r]=e;return{url:m(t),method:p(r,"method")?String(r.method).toUpperCase():"GET"}}let t=e[0];return{url:m(t),method:p(t,"method")?String(t.method).toUpperCase():"GET"}}(r),c={args:r,fetchData:{method:s,url:l},startTimestamp:1e3*(0,o.ph)()};e||(0,u.rK)("fetch",{...c});let d=Error().stack;return t.apply(a.GLOBAL_OBJ,r).then(async t=>(e?e(t):(0,u.rK)("fetch",{...c,endTimestamp:1e3*(0,o.ph)(),response:t}),t),e=>{throw(0,u.rK)("fetch",{...c,endTimestamp:1e3*(0,o.ph)(),error:e}),(0,n.VZ)(e)&&void 0===e.stack&&(e.stack=d,(0,i.xp)(e,"framesToPop",1)),e})}})}async function f(e,t){if(e&&e.body&&e.body.getReader){let n=e.body.getReader();async function r({done:e}){if(e)return Promise.resolve();try{let e=await Promise.race([n.read(),new Promise(e=>{setTimeout(()=>{e({done:!0})},5e3)})]);await r(e)}catch(e){}}return n.read().then(r).then(t).catch(()=>void 0)}}async function h(e){let t;try{t=e.clone()}catch(e){return}await f(t,()=>{(0,u.rK)("fetch-body-resolved",{endTimestamp:1e3*(0,o.ph)(),response:e})})}function p(e,t){return!!e&&"object"==typeof e&&!!e[t]}function m(e){return"string"==typeof e?e:e?p(e,"url")?e.url:e.toString?e.toString():"":""}},7355:function(e,t,r){"use strict";r.d(t,{V:function(){return o}});var n=r(29531),i=r(68562);let s=null;function o(e){let t="error";(0,i.Hj)(t,e),(0,i.D2)(t,a)}function a(){s=n.GLOBAL_OBJ.onerror,n.GLOBAL_OBJ.onerror=function(e,t,r,n,o){return(0,i.rK)("error",{column:n,error:o,line:r,msg:e,url:t}),!!s&&!s.__SENTRY_LOADER__&&s.apply(this,arguments)},n.GLOBAL_OBJ.onerror.__SENTRY_INSTRUMENTED__=!0}},40364:function(e,t,r){"use strict";r.d(t,{h:function(){return o}});var n=r(29531),i=r(68562);let s=null;function o(e){let t="unhandledrejection";(0,i.Hj)(t,e),(0,i.D2)(t,a)}function a(){s=n.GLOBAL_OBJ.onunhandledrejection,n.GLOBAL_OBJ.onunhandledrejection=function(e){return(0,i.rK)("unhandledrejection",e),!s||!!s.__SENTRY_LOADER__||s.apply(this,arguments)},n.GLOBAL_OBJ.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}},68562:function(e,t,r){"use strict";r.d(t,{D2:function(){return l},Hj:function(){return u},rK:function(){return c}});var n=r(1525),i=r(41001),s=r(42283);let o={},a={};function u(e,t){o[e]=o[e]||[],o[e].push(t)}function l(e,t){a[e]||(t(),a[e]=!0)}function c(e,t){let r=e&&o[e];if(r)for(let o of r)try{o(t)}catch(t){n.X&&i.kg.error(`Error while triggering instrumentation handler.
Type: ${e}
Name: ${(0,s.$P)(o)}
Error:`,t)}}},16824:function(e,t,r){"use strict";r.d(t,{Cy:function(){return y},HD:function(){return l},J8:function(){return g},Kj:function(){return m},Le:function(){return c},PO:function(){return f},TX:function(){return a},V9:function(){return v},VW:function(){return o},VZ:function(){return i},cO:function(){return h},fm:function(){return u},kK:function(){return p},pt:function(){return d},y1:function(){return _}});let n=Object.prototype.toString;function i(e){switch(n.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return v(e,Error)}}function s(e,t){return n.call(e)===`[object ${t}]`}function o(e){return s(e,"ErrorEvent")}function a(e){return s(e,"DOMError")}function u(e){return s(e,"DOMException")}function l(e){return s(e,"String")}function c(e){return"object"==typeof e&&null!==e&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function d(e){return null===e||c(e)||"object"!=typeof e&&"function"!=typeof e}function f(e){return s(e,"Object")}function h(e){return"undefined"!=typeof Event&&v(e,Event)}function p(e){return"undefined"!=typeof Element&&v(e,Element)}function m(e){return s(e,"RegExp")}function g(e){return!!(e&&e.then&&"function"==typeof e.then)}function y(e){return f(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function v(e,t){try{return e instanceof t}catch(e){return!1}}function _(e){return!!("object"==typeof e&&null!==e&&(e.__isVue||e._isVue))}},41001:function(e,t,r){"use strict";r.d(t,{Cf:function(){return a},LD:function(){return o},RU:function(){return s},kg:function(){return u}});var n=r(1525),i=r(29531);let s=["debug","info","warn","error","log","assert","trace"],o={};function a(e){if(!("console"in i.GLOBAL_OBJ))return e();let t=i.GLOBAL_OBJ.console,r={},n=Object.keys(o);n.forEach(e=>{let n=o[e];r[e]=t[e],t[e]=n});try{return e()}finally{n.forEach(e=>{t[e]=r[e]})}}let u=function(){let e=!1,t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return n.X?s.forEach(r=>{t[r]=(...t)=>{e&&a(()=>{i.GLOBAL_OBJ.console[r](`Sentry Logger [${r}]:`,...t)})}}):s.forEach(e=>{t[e]=()=>void 0}),t}()},41982:function(e,t,r){"use strict";r.d(t,{DM:function(){return s},Db:function(){return u},EG:function(){return l},YO:function(){return c},jH:function(){return a},lE:function(){return d}});var n=r(27179),i=r(29531);function s(){let e=i.GLOBAL_OBJ,t=e.crypto||e.msCrypto,r=()=>16*Math.random();try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(r=()=>{let e=new Uint8Array(1);return t.getRandomValues(e),e[0]})}catch(e){}return"10000000100040008000100000000000".replace(/[018]/g,e=>(e^(15&r())>>e/4).toString(16))}function o(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function a(e){let{message:t,event_id:r}=e;if(t)return t;let n=o(e);return n?n.type&&n.value?`${n.type}: ${n.value}`:n.type||n.value||r||"<unknown>":r||"<unknown>"}function u(e,t,r){let n=e.exception=e.exception||{},i=n.values=n.values||[],s=i[0]=i[0]||{};s.value||(s.value=t||""),s.type||(s.type=r||"Error")}function l(e,t){let r=o(e);if(!r)return;let n=r.mechanism;if(r.mechanism={type:"generic",handled:!0,...n,...t},t&&"data"in t){let e={...n&&n.data,...t.data};r.mechanism.data=e}}function c(e){if(e&&e.__sentry_captured__)return!0;try{(0,n.xp)(e,"__sentry_captured__",!0)}catch(e){}return!1}function d(e){return Array.isArray(e)?e:[e]}},83408:function(e,t,r){"use strict";r.d(t,{Fv:function(){return o},Qy:function(){return function e(t,r=3,n=102400){let i=o(t,r);return~-encodeURI(JSON.stringify(i)).split(/%..|./).length>n?e(t,r-1,n):i}}});var n=r(16824),i=r(27179),s=r(42283);function o(e,t=100,r=Infinity){try{return function e(t,r,o=Infinity,a=Infinity,u=function(){let e="function"==typeof WeakSet,t=e?new WeakSet:[];return[function(r){if(e)return!!t.has(r)||(t.add(r),!1);for(let e=0;e<t.length;e++)if(t[e]===r)return!0;return t.push(r),!1},function(r){if(e)t.delete(r);else for(let e=0;e<t.length;e++)if(t[e]===r){t.splice(e,1);break}}]}()){let[l,c]=u;if(null==r||["number","boolean","string"].includes(typeof r)&&!Number.isNaN(r))return r;let d=function(e,t){try{if("domain"===e&&t&&"object"==typeof t&&t._events)return"[Domain]";if("domainEmitter"===e)return"[DomainEmitter]";if("undefined"!=typeof global&&t===global)return"[Global]";if("undefined"!=typeof window&&t===window)return"[Window]";if("undefined"!=typeof document&&t===document)return"[Document]";if((0,n.y1)(t))return"[VueViewModel]";if((0,n.Cy)(t))return"[SyntheticEvent]";if("number"==typeof t&&t!=t)return"[NaN]";if("function"==typeof t)return`[Function: ${(0,s.$P)(t)}]`;if("symbol"==typeof t)return`[${String(t)}]`;if("bigint"==typeof t)return`[BigInt: ${String(t)}]`;let r=function(e){let t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}(t);if(/^HTML(\w*)Element$/.test(r))return`[HTMLElement: ${r}]`;return`[object ${r}]`}catch(e){return`**non-serializable** (${e})`}}(t,r);if(!d.startsWith("[object "))return d;if(r.__sentry_skip_normalization__)return r;let f="number"==typeof r.__sentry_override_normalization_depth__?r.__sentry_override_normalization_depth__:o;if(0===f)return d.replace("object ","");if(l(r))return"[Circular ~]";if(r&&"function"==typeof r.toJSON)try{let t=r.toJSON();return e("",t,f-1,a,u)}catch(e){}let h=Array.isArray(r)?[]:{},p=0,m=(0,i.Sh)(r);for(let t in m){if(!Object.prototype.hasOwnProperty.call(m,t))continue;if(p>=a){h[t]="[MaxProperties ~]";break}let r=m[t];h[t]=e(t,r,f-1,a,u),p++}return c(r),h}("",e,t,r)}catch(e){return{ERROR:`**non-serializable** (${e})`}}}},27179:function(e,t,r){"use strict";r.d(t,{$Q:function(){return c},HK:function(){return d},Jr:function(){return y},Sh:function(){return h},_j:function(){return f},hl:function(){return u},xp:function(){return l},zf:function(){return g}});var n=r(1869),i=r(1525),s=r(16824),o=r(41001),a=r(89163);function u(e,t,r){if(!(t in e))return;let n=e[t],i=r(n);"function"==typeof i&&c(i,n),e[t]=i}function l(e,t,r){try{Object.defineProperty(e,t,{value:r,writable:!0,configurable:!0})}catch(r){i.X&&o.kg.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function c(e,t){try{let r=t.prototype||{};e.prototype=t.prototype=r,l(e,"__sentry_original__",t)}catch(e){}}function d(e){return e.__sentry_original__}function f(e){return Object.keys(e).map(t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`).join("&")}function h(e){if((0,s.VZ)(e))return{message:e.message,name:e.name,stack:e.stack,...m(e)};if(!(0,s.cO)(e))return e;{let t={type:e.type,target:p(e.target),currentTarget:p(e.currentTarget),...m(e)};return"undefined"!=typeof CustomEvent&&(0,s.V9)(e,CustomEvent)&&(t.detail=e.detail),t}}function p(e){try{return(0,s.kK)(e)?(0,n.Rt)(e):Object.prototype.toString.call(e)}catch(e){return"<unknown>"}}function m(e){if("object"!=typeof e||null===e)return{};{let t={};for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}}function g(e,t=40){let r=Object.keys(h(e));r.sort();let n=r[0];if(!n)return"[object has no keys]";if(n.length>=t)return(0,a.$G)(n,t);for(let e=r.length;e>0;e--){let n=r.slice(0,e).join(", ");if(!(n.length>t)){if(e===r.length)return n;return(0,a.$G)(n,t)}}return""}function y(e){return function e(t,r){if(function(e){if(!(0,s.PO)(e))return!1;try{let t=Object.getPrototypeOf(e).constructor.name;return!t||"Object"===t}catch(e){return!0}}(t)){let n=r.get(t);if(void 0!==n)return n;let i={};for(let n of(r.set(t,i),Object.keys(t)))void 0!==t[n]&&(i[n]=e(t[n],r));return i}if(Array.isArray(t)){let n=r.get(t);if(void 0!==n)return n;let i=[];return r.set(t,i),t.forEach(t=>{i.push(e(t,r))}),i}return t}(e,new Map)}},19548:function(e,t,r){"use strict";r.d(t,{Q:function(){return i}});var n=r(41982);function i(){return{traceId:(0,n.DM)(),spanId:(0,n.DM)().substring(16)}}},83745:function(e,t,r){"use strict";function n(e,t,r=Date.now()){return(e[t]||e.all||0)>r}function i(e,{statusCode:t,headers:r},n=Date.now()){let i={...e},s=r&&r["x-sentry-rate-limits"],o=r&&r["retry-after"];if(s)for(let e of s.trim().split(",")){let[t,r,,,s]=e.split(":",5),o=parseInt(t,10),a=(isNaN(o)?60:o)*1e3;if(r)for(let e of r.split(";"))"metric_bucket"===e?(!s||s.split(";").includes("custom"))&&(i[e]=n+a):i[e]=n+a;else i.all=n+a}else o?i.all=n+function(e,t=Date.now()){let r=parseInt(`${e}`,10);if(!isNaN(r))return 1e3*r;let n=Date.parse(`${e}`);return isNaN(n)?6e4:n-t}(o,n):429===t&&(i.all=n+6e4);return i}r.d(t,{Q:function(){return n},WG:function(){return i}})},42283:function(e,t,r){"use strict";r.d(t,{$P:function(){return c},Fi:function(){return n},Fr:function(){return d},Sq:function(){return a},pE:function(){return o}});let n="?",i=/\(error: (.*)\)/,s=/captureMessage|captureException/;function o(...e){let t=e.sort((e,t)=>e[0]-t[0]).map(e=>e[1]);return(e,r=0,o=0)=>{let a=[],l=e.split("\n");for(let e=r;e<l.length;e++){let r=l[e];if(r.length>1024)continue;let n=i.test(r)?r.replace(i,"$1"):r;if(!n.match(/\S*Error: /)){for(let e of t){let t=e(n);if(t){a.push(t);break}}if(a.length>=50+o)break}}return function(e){if(!e.length)return[];let t=Array.from(e);return/sentryWrapped/.test(u(t).function||"")&&t.pop(),t.reverse(),s.test(u(t).function||"")&&(t.pop(),s.test(u(t).function||"")&&t.pop()),t.slice(0,50).map(e=>({...e,filename:e.filename||u(t).filename,function:e.function||n}))}(a.slice(o))}}function a(e){return Array.isArray(e)?o(...e):e}function u(e){return e[e.length-1]||{}}let l="<anonymous>";function c(e){try{if(!e||"function"!=typeof e)return l;return e.name||l}catch(e){return l}}function d(e){let t=e.exception;if(t){let e=[];try{return t.values.forEach(t=>{t.stacktrace.frames&&e.push(...t.stacktrace.frames)}),e}catch(e){}}}},89163:function(e,t,r){"use strict";r.d(t,{$G:function(){return i},U0:function(){return o},nK:function(){return s}});var n=r(16824);function i(e,t=0){return"string"!=typeof e||0===t?e:e.length<=t?e:`${e.slice(0,t)}...`}function s(e,t){if(!Array.isArray(e))return"";let r=[];for(let t=0;t<e.length;t++){let i=e[t];try{(0,n.y1)(i)?r.push("[VueViewModel]"):r.push(String(i))}catch(e){r.push("[value cannot be serialized]")}}return r.join(t)}function o(e,t=[],r=!1){return t.some(t=>(function(e,t,r=!1){return!!(0,n.HD)(e)&&((0,n.Kj)(t)?t.test(e):!!(0,n.HD)(t)&&(r?e===t:e.includes(t)))})(e,t,r))}},36731:function(e,t,r){"use strict";r.d(t,{Ak:function(){return o},QC:function(){return a},t$:function(){return u}});var n=r(1525),i=r(41001);let s=r(29531).GLOBAL_OBJ;function o(){if(!("fetch"in s))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch(e){return!1}}function a(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function u(){if("string"==typeof EdgeRuntime)return!0;if(!o())return!1;if(a(s.fetch))return!0;let e=!1,t=s.document;if(t&&"function"==typeof t.createElement)try{let r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(e=a(r.contentWindow.fetch)),t.head.removeChild(r)}catch(e){n.X&&i.kg.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",e)}return e}},80128:function(e,t,r){"use strict";r.d(t,{$2:function(){return a},WD:function(){return o},cW:function(){return u}});var n,i,s=r(16824);function o(e){return new u(t=>{t(e)})}function a(e){return new u((t,r)=>{r(e)})}(n=i||(i={}))[n.PENDING=0]="PENDING",n[n.RESOLVED=1]="RESOLVED",n[n.REJECTED=2]="REJECTED";class u{constructor(e){u.prototype.__init.call(this),u.prototype.__init2.call(this),u.prototype.__init3.call(this),u.prototype.__init4.call(this),this._state=i.PENDING,this._handlers=[];try{e(this._resolve,this._reject)}catch(e){this._reject(e)}}then(e,t){return new u((r,n)=>{this._handlers.push([!1,t=>{if(e)try{r(e(t))}catch(e){n(e)}else r(t)},e=>{if(t)try{r(t(e))}catch(e){n(e)}else n(e)}]),this._executeHandlers()})}catch(e){return this.then(e=>e,e)}finally(e){return new u((t,r)=>{let n,i;return this.then(t=>{i=!1,n=t,e&&e()},t=>{i=!0,n=t,e&&e()}).then(()=>{if(i){r(n);return}t(n)})})}__init(){this._resolve=e=>{this._setResult(i.RESOLVED,e)}}__init2(){this._reject=e=>{this._setResult(i.REJECTED,e)}}__init3(){this._setResult=(e,t)=>{if(this._state===i.PENDING){if((0,s.J8)(t)){t.then(this._resolve,this._reject);return}this._state=e,this._value=t,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===i.PENDING)return;let e=this._handlers.slice();this._handlers=[],e.forEach(e=>{e[0]||(this._state===i.RESOLVED&&e[1](this._value),this._state===i.REJECTED&&e[2](this._value),e[0]=!0)})}}}},26181:function(e,t,r){"use strict";r.d(t,{Z1:function(){return o},ph:function(){return s},yW:function(){return i}});var n=r(29531);function i(){return Date.now()/1e3}let s=function(){let{performance:e}=n.GLOBAL_OBJ;if(!e||!e.now)return i;let t=Date.now()-e.now(),r=void 0==e.timeOrigin?t:e.timeOrigin;return()=>(r+e.now())/1e3}(),o=(()=>{let{performance:e}=n.GLOBAL_OBJ;if(!e||!e.now)return;let t=e.now(),r=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+t-r):36e5,s=e.timing&&e.timing.navigationStart,o="number"==typeof s?Math.abs(s+t-r):36e5;return i<36e5||o<36e5?i<=o?e.timeOrigin:s:r})()},85712:function(e,t,r){"use strict";r.d(t,{$p:function(){return a},pT:function(){return o}});var n=r(60859),i=r(41982);let s=RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function o(e,t){let r=function(e){let t;if(!e)return;let r=e.match(s);if(r)return"1"===r[3]?t=!0:"0"===r[3]&&(t=!1),{traceId:r[1],parentSampled:t,parentSpanId:r[2]}}(e),o=(0,n.EN)(t),{traceId:a,parentSpanId:u,parentSampled:l}=r||{};return r?{traceId:a||(0,i.DM)(),parentSpanId:u||(0,i.DM)().substring(16),spanId:(0,i.DM)().substring(16),sampled:l,dsc:o||{}}:{traceId:a||(0,i.DM)(),spanId:(0,i.DM)().substring(16)}}function a(e=(0,i.DM)(),t=(0,i.DM)().substring(16),r){let n="";return void 0!==r&&(n=r?"-1":"-0"),`${e}-${t}${n}`}},42419:function(e,t,r){"use strict";function n(e){if(!e)return{};let t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};let r=t[6]||"",n=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:r,hash:n,relative:t[5]+r+n}}function i(e){return e.split(/[?#]/,1)[0]}r.d(t,{en:function(){return n},rt:function(){return i}})},42990:function(e,t,r){"use strict";r.d(t,{J:function(){return n}});let n="8.24.0"},29531:function(e,t,r){"use strict";r.d(t,{GLOBAL_OBJ:function(){return i},Y:function(){return s}});var n=r(42990);let i=globalThis;function s(e,t,r){let s=r||i,o=s.__SENTRY__=s.__SENTRY__||{},a=o[n.J]=o[n.J]||{};return a[e]||(a[e]=t())}},15761:function(e,t,r){"use strict";r.d(t,{j:function(){return o}});var n=r(33989),i=r(32161);class s extends n.l{constructor(){super(),this.setup=e=>{if(!i.sk&&window.addEventListener){let t=()=>e();return window.addEventListener("visibilitychange",t,!1),window.addEventListener("focus",t,!1),()=>{window.removeEventListener("visibilitychange",t),window.removeEventListener("focus",t)}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.cleanup)||e.call(this),this.cleanup=void 0}}setEventListener(e){var t;this.setup=e,null==(t=this.cleanup)||t.call(this),this.cleanup=e(e=>{"boolean"==typeof e?this.setFocused(e):this.onFocus()})}setFocused(e){this.focused!==e&&(this.focused=e,this.onFocus())}onFocus(){this.listeners.forEach(({listener:e})=>{e()})}isFocused(){return"boolean"==typeof this.focused?this.focused:"undefined"==typeof document||[void 0,"visible","prerender"].includes(document.visibilityState)}}let o=new s},30819:function(e,t,r){"use strict";r.d(t,{_:function(){return n}});let n=console},89886:function(e,t,r){"use strict";r.d(t,{R:function(){return u},m:function(){return a}});var n=r(30819),i=r(30081),s=r(89643),o=r(72379);class a extends s.F{constructor(e){super(),this.defaultOptions=e.defaultOptions,this.mutationId=e.mutationId,this.mutationCache=e.mutationCache,this.logger=e.logger||n._,this.observers=[],this.state=e.state||u(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options={...this.defaultOptions,...e},this.updateCacheTime(this.options.cacheTime)}get meta(){return this.options.meta}setState(e){this.dispatch({type:"setState",state:e})}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.mutationCache.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.observers=this.observers.filter(t=>t!==e),this.scheduleGc(),this.mutationCache.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.observers.length||("loading"===this.state.status?this.scheduleGc():this.mutationCache.remove(this))}continue(){var e,t;return null!=(e=null==(t=this.retryer)?void 0:t.continue())?e:this.execute()}async execute(){var e,t,r,n,i,s,a,u,l,c,d,f,h,p,m,g,y,v,_,b;let S="loading"===this.state.status;try{if(!S){this.dispatch({type:"loading",variables:this.options.variables}),await (null==(l=(c=this.mutationCache.config).onMutate)?void 0:l.call(c,this.state.variables,this));let e=await (null==(d=(f=this.options).onMutate)?void 0:d.call(f,this.state.variables));e!==this.state.context&&this.dispatch({type:"loading",context:e,variables:this.state.variables})}let h=await (()=>{var e;return this.retryer=(0,o.Mz)({fn:()=>this.options.mutationFn?this.options.mutationFn(this.state.variables):Promise.reject("No mutationFn found"),onFail:(e,t)=>{this.dispatch({type:"failed",failureCount:e,error:t})},onPause:()=>{this.dispatch({type:"pause"})},onContinue:()=>{this.dispatch({type:"continue"})},retry:null!=(e=this.options.retry)?e:0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode}),this.retryer.promise})();return await (null==(e=(t=this.mutationCache.config).onSuccess)?void 0:e.call(t,h,this.state.variables,this.state.context,this)),await (null==(r=(n=this.options).onSuccess)?void 0:r.call(n,h,this.state.variables,this.state.context)),await (null==(i=(s=this.mutationCache.config).onSettled)?void 0:i.call(s,h,null,this.state.variables,this.state.context,this)),await (null==(a=(u=this.options).onSettled)?void 0:a.call(u,h,null,this.state.variables,this.state.context)),this.dispatch({type:"success",data:h}),h}catch(e){try{throw await (null==(h=(p=this.mutationCache.config).onError)?void 0:h.call(p,e,this.state.variables,this.state.context,this)),await (null==(m=(g=this.options).onError)?void 0:m.call(g,e,this.state.variables,this.state.context)),await (null==(y=(v=this.mutationCache.config).onSettled)?void 0:y.call(v,void 0,e,this.state.variables,this.state.context,this)),await (null==(_=(b=this.options).onSettled)?void 0:_.call(b,void 0,e,this.state.variables,this.state.context)),e}finally{this.dispatch({type:"error",error:e})}}}dispatch(e){this.state=(t=>{switch(e.type){case"failed":return{...t,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...t,isPaused:!0};case"continue":return{...t,isPaused:!1};case"loading":return{...t,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:!(0,o.Kw)(this.options.networkMode),status:"loading",variables:e.variables};case"success":return{...t,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...t,data:void 0,error:e.error,failureCount:t.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"};case"setState":return{...t,...e.state}}})(this.state),i.V.batch(()=>{this.observers.forEach(t=>{t.onMutationUpdate(e)}),this.mutationCache.notify({mutation:this,type:"updated",action:e})})}}function u(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0}}},30081:function(e,t,r){"use strict";r.d(t,{V:function(){return i}});var n=r(32161);let i=function(){let e=[],t=0,r=e=>{e()},i=e=>{e()},s=i=>{t?e.push(i):(0,n.A4)(()=>{r(i)})},o=()=>{let t=e;e=[],t.length&&(0,n.A4)(()=>{i(()=>{t.forEach(e=>{r(e)})})})};return{batch:e=>{let r;t++;try{r=e()}finally{--t||o()}return r},batchCalls:e=>(...t)=>{s(()=>{e(...t)})},schedule:s,setNotifyFunction:e=>{r=e},setBatchNotifyFunction:e=>{i=e}}}()},96474:function(e,t,r){"use strict";r.d(t,{N:function(){return a}});var n=r(33989),i=r(32161);let s=["online","offline"];class o extends n.l{constructor(){super(),this.setup=e=>{if(!i.sk&&window.addEventListener){let t=()=>e();return s.forEach(e=>{window.addEventListener(e,t,!1)}),()=>{s.forEach(e=>{window.removeEventListener(e,t)})}}}}onSubscribe(){this.cleanup||this.setEventListener(this.setup)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.cleanup)||e.call(this),this.cleanup=void 0}}setEventListener(e){var t;this.setup=e,null==(t=this.cleanup)||t.call(this),this.cleanup=e(e=>{"boolean"==typeof e?this.setOnline(e):this.onOnline()})}setOnline(e){this.online!==e&&(this.online=e,this.onOnline())}onOnline(){this.listeners.forEach(({listener:e})=>{e()})}isOnline(){return"boolean"==typeof this.online?this.online:"undefined"==typeof navigator||void 0===navigator.onLine||navigator.onLine}}let a=new o},89643:function(e,t,r){"use strict";r.d(t,{F:function(){return i}});var n=r(32161);class i{destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),(0,n.PN)(this.cacheTime)&&(this.gcTimeout=setTimeout(()=>{this.optionalRemove()},this.cacheTime))}updateCacheTime(e){this.cacheTime=Math.max(this.cacheTime||0,null!=e?e:n.sk?1/0:3e5)}clearGcTimeout(){this.gcTimeout&&(clearTimeout(this.gcTimeout),this.gcTimeout=void 0)}}},72379:function(e,t,r){"use strict";r.d(t,{DV:function(){return l},Kw:function(){return a},Mz:function(){return c}});var n=r(15761),i=r(96474),s=r(32161);function o(e){return Math.min(1e3*2**e,3e4)}function a(e){return(null!=e?e:"online")!=="online"||i.N.isOnline()}class u{constructor(e){this.revert=null==e?void 0:e.revert,this.silent=null==e?void 0:e.silent}}function l(e){return e instanceof u}function c(e){let t,r,l,c=!1,d=0,f=!1,h=new Promise((e,t)=>{r=e,l=t}),p=()=>!n.j.isFocused()||"always"!==e.networkMode&&!i.N.isOnline(),m=n=>{f||(f=!0,null==e.onSuccess||e.onSuccess(n),null==t||t(),r(n))},g=r=>{f||(f=!0,null==e.onError||e.onError(r),null==t||t(),l(r))},y=()=>new Promise(r=>{t=e=>{let t=f||!p();return t&&r(e),t},null==e.onPause||e.onPause()}).then(()=>{t=void 0,f||null==e.onContinue||e.onContinue()}),v=()=>{let t;if(!f){try{t=e.fn()}catch(e){t=Promise.reject(e)}Promise.resolve(t).then(m).catch(t=>{var r,n;if(f)return;let i=null!=(r=e.retry)?r:3,a=null!=(n=e.retryDelay)?n:o,u="function"==typeof a?a(d,t):a,l=!0===i||"number"==typeof i&&d<i||"function"==typeof i&&i(d,t);if(c||!l){g(t);return}d++,null==e.onFail||e.onFail(d,t),(0,s.Gh)(u).then(()=>{if(p())return y()}).then(()=>{c?g(t):v()})})}};return a(e.networkMode)?v():y().then(v),{promise:h,cancel:t=>{f||(g(new u(t)),null==e.abort||e.abort())},continue:()=>(null==t?void 0:t())?h:Promise.resolve(),cancelRetry:()=>{c=!0},continueRetry:()=>{c=!1}}}},33989:function(e,t,r){"use strict";r.d(t,{l:function(){return n}});class n{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){let t={listener:e};return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}}},32161:function(e,t,r){"use strict";r.d(t,{A4:function(){return k},G9:function(){return T},Gh:function(){return O},I6:function(){return f},Kp:function(){return l},PN:function(){return o},Rc:function(){return u},Rm:function(){return m},SE:function(){return s},VS:function(){return _},X7:function(){return p},ZT:function(){return i},_v:function(){return c},_x:function(){return h},e5:function(){return a},lV:function(){return d},oE:function(){return C},sk:function(){return n},to:function(){return y},yF:function(){return g}});let n="undefined"==typeof window||"Deno"in window;function i(){}function s(e,t){return"function"==typeof e?e(t):e}function o(e){return"number"==typeof e&&e>=0&&e!==1/0}function a(e,t){return e.filter(e=>!t.includes(e))}function u(e,t,r){let n=e.slice(0);return n[t]=r,n}function l(e,t){return Math.max(e+(t||0)-Date.now(),0)}function c(e,t,r){return w(e)?"function"==typeof t?{...r,queryKey:e,queryFn:t}:{...t,queryKey:e}:e}function d(e,t,r){return w(e)?"function"==typeof t?{...r,mutationKey:e,mutationFn:t}:{...t,mutationKey:e}:"function"==typeof e?{...t,mutationFn:e}:{...e}}function f(e,t,r){return w(e)?[{...t,queryKey:e},r]:[e||{},t]}function h(e,t){let{type:r="all",exact:n,fetchStatus:i,predicate:s,queryKey:o,stale:a}=e;if(w(o)){if(n){if(t.queryHash!==m(o,t.options))return!1}else{if(!v(t.queryKey,o))return!1}}if("all"!==r){let e=t.isActive();if("active"===r&&!e||"inactive"===r&&e)return!1}return("boolean"!=typeof a||t.isStale()===a)&&(void 0===i||i===t.state.fetchStatus)&&(!s||!!s(t))}function p(e,t){let{exact:r,fetching:n,predicate:i,mutationKey:s}=e;if(w(s)){if(!t.options.mutationKey)return!1;if(r){if(g(t.options.mutationKey)!==g(s))return!1}else{if(!v(t.options.mutationKey,s))return!1}}return("boolean"!=typeof n||"loading"===t.state.status===n)&&(!i||!!i(t))}function m(e,t){return((null==t?void 0:t.queryKeyHashFn)||g)(e)}function g(e){return JSON.stringify(e,(e,t)=>S(t)?Object.keys(t).sort().reduce((e,r)=>(e[r]=t[r],e),{}):t)}function y(e,t){return v(e,t)}function v(e,t){return e===t||typeof e==typeof t&&!!e&&!!t&&"object"==typeof e&&"object"==typeof t&&!Object.keys(t).some(r=>!v(e[r],t[r]))}function _(e,t){if(e&&!t||t&&!e)return!1;for(let r in e)if(e[r]!==t[r])return!1;return!0}function b(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function S(e){if(!E(e))return!1;let t=e.constructor;if(void 0===t)return!0;let r=t.prototype;return!!(E(r)&&r.hasOwnProperty("isPrototypeOf"))}function E(e){return"[object Object]"===Object.prototype.toString.call(e)}function w(e){return Array.isArray(e)}function O(e){return new Promise(t=>{setTimeout(t,e)})}function k(e){O(0).then(e)}function T(){if("function"==typeof AbortController)return new AbortController}function C(e,t,r){return null!=r.isDataEqual&&r.isDataEqual(e,t)?e:"function"==typeof r.structuralSharing?r.structuralSharing(e,t):!1!==r.structuralSharing?function e(t,r){if(t===r)return t;let n=b(t)&&b(r);if(n||S(t)&&S(r)){let i=n?t.length:Object.keys(t).length,s=n?r:Object.keys(r),o=s.length,a=n?[]:{},u=0;for(let i=0;i<o;i++){let o=n?i:s[i];a[o]=e(t[o],r[o]),a[o]===t[o]&&u++}return i===o&&u===i?t:a}return r}(e,t):t}},85945:function(e,t,r){"use strict";r.d(t,{NL:function(){return a},aH:function(){return u}});var n=r(67294);let i=n.createContext(void 0),s=n.createContext(!1);function o(e,t){return e||(t&&"undefined"!=typeof window?(window.ReactQueryClientContext||(window.ReactQueryClientContext=i),window.ReactQueryClientContext):i)}let a=({context:e}={})=>{let t=n.useContext(o(e,n.useContext(s)));if(!t)throw Error("No QueryClient set, use QueryClientProvider to set one");return t},u=({client:e,children:t,context:r,contextSharing:i=!1})=>{n.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]);let a=o(r,i);return n.createElement(s.Provider,{value:!r&&i},n.createElement(a.Provider,{value:e},t))}},48228:function(e,t,r){"use strict";r.d(t,{D:function(){return f}});var n=r(67294),i=r(32161),s=r(89886),o=r(30081),a=r(33989);class u extends a.l{constructor(e,t){super(),this.client=e,this.setOptions(t),this.bindMethods(),this.updateResult()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(e){var t;let r=this.options;this.options=this.client.defaultMutationOptions(e),(0,i.VS)(r,this.options)||this.client.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.currentMutation,observer:this}),null==(t=this.currentMutation)||t.setOptions(this.options)}onUnsubscribe(){if(!this.hasListeners()){var e;null==(e=this.currentMutation)||e.removeObserver(this)}}onMutationUpdate(e){this.updateResult();let t={listeners:!0};"success"===e.type?t.onSuccess=!0:"error"===e.type&&(t.onError=!0),this.notify(t)}getCurrentResult(){return this.currentResult}reset(){this.currentMutation=void 0,this.updateResult(),this.notify({listeners:!0})}mutate(e,t){return this.mutateOptions=t,this.currentMutation&&this.currentMutation.removeObserver(this),this.currentMutation=this.client.getMutationCache().build(this.client,{...this.options,variables:void 0!==e?e:this.options.variables}),this.currentMutation.addObserver(this),this.currentMutation.execute()}updateResult(){let e=this.currentMutation?this.currentMutation.state:(0,s.R)(),t={...e,isLoading:"loading"===e.status,isSuccess:"success"===e.status,isError:"error"===e.status,isIdle:"idle"===e.status,mutate:this.mutate,reset:this.reset};this.currentResult=t}notify(e){o.V.batch(()=>{if(this.mutateOptions&&this.hasListeners()){var t,r,n,i,s,o,a,u;e.onSuccess?(null==(t=(r=this.mutateOptions).onSuccess)||t.call(r,this.currentResult.data,this.currentResult.variables,this.currentResult.context),null==(n=(i=this.mutateOptions).onSettled)||n.call(i,this.currentResult.data,null,this.currentResult.variables,this.currentResult.context)):e.onError&&(null==(s=(o=this.mutateOptions).onError)||s.call(o,this.currentResult.error,this.currentResult.variables,this.currentResult.context),null==(a=(u=this.mutateOptions).onSettled)||a.call(u,void 0,this.currentResult.error,this.currentResult.variables,this.currentResult.context))}e.listeners&&this.listeners.forEach(({listener:e})=>{e(this.currentResult)})})}}var l=r(464),c=r(85945),d=r(24798);function f(e,t,r){let s=(0,i.lV)(e,t,r),a=(0,c.NL)({context:s.context}),[f]=n.useState(()=>new u(a,s));n.useEffect(()=>{f.setOptions(s)},[f,s]);let p=(0,l.$)(n.useCallback(e=>f.subscribe(o.V.batchCalls(e)),[f]),()=>f.getCurrentResult(),()=>f.getCurrentResult()),m=n.useCallback((e,t)=>{f.mutate(e,t).catch(h)},[f]);if(p.error&&(0,d.L)(f.options.useErrorBoundary,[p.error]))throw p.error;return{...p,mutate:m,mutateAsync:p.mutate}}function h(){}},464:function(e,t,r){"use strict";r.d(t,{$:function(){return n}});let n=r(61688).useSyncExternalStore},24798:function(e,t,r){"use strict";function n(e,t){return"function"==typeof e?e(...t):!!e}r.d(t,{L:function(){return n}})},12902:function(e,t,r){"use strict";function n(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];throw Error("[Immer] minified error nr: "+e+(r.length?" "+r.map(function(e){return"'"+e+"'"}).join(","):"")+". Find the full error at: https://bit.ly/3cXEKWf")}function i(e){return!!e&&!!e[$]}function s(e){var t;return!!e&&(function(e){if(!e||"object"!=typeof e)return!1;var t=Object.getPrototypeOf(e);if(null===t)return!0;var r=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;return r===Object||"function"==typeof r&&Function.toString.call(r)===z}(e)||Array.isArray(e)||!!e[F]||!!(null===(t=e.constructor)||void 0===t?void 0:t[F])||c(e)||d(e))}function o(e,t,r){void 0===r&&(r=!1),0===a(e)?(r?Object.keys:H)(e).forEach(function(n){r&&"symbol"==typeof n||t(n,e[n],e)}):e.forEach(function(r,n){return t(n,r,e)})}function a(e){var t=e[$];return t?t.i>3?t.i-4:t.i:Array.isArray(e)?1:c(e)?2:d(e)?3:0}function u(e,t){return 2===a(e)?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function l(e,t,r){var n=a(e);2===n?e.set(t,r):3===n?e.add(r):e[t]=r}function c(e){return L&&e instanceof Map}function d(e){return j&&e instanceof Set}function f(e){return e.o||e.t}function h(e){if(Array.isArray(e))return Array.prototype.slice.call(e);var t=G(e);delete t[$];for(var r=H(t),n=0;n<r.length;n++){var i=r[n],s=t[i];!1===s.writable&&(s.writable=!0,s.configurable=!0),(s.get||s.set)&&(t[i]={configurable:!0,writable:!0,enumerable:s.enumerable,value:e[i]})}return Object.create(Object.getPrototypeOf(e),t)}function p(e,t){return void 0===t&&(t=!1),g(e)||i(e)||!s(e)||(a(e)>1&&(e.set=e.add=e.clear=e.delete=m),Object.freeze(e),t&&o(e,function(e,t){return p(t,!0)},!0)),e}function m(){n(2)}function g(e){return null==e||"object"!=typeof e||Object.isFrozen(e)}function y(e){var t=q[e];return t||n(18,e),t}function v(e,t){t&&(y("Patches"),e.u=[],e.s=[],e.v=t)}function _(e){b(e),e.p.forEach(E),e.p=null}function b(e){e===N&&(N=e.l)}function S(e){return N={p:[],l:N,h:e,m:!0,_:0}}function E(e){var t=e[$];0===t.i||1===t.i?t.j():t.g=!0}function w(e,t){t._=t.p.length;var r=t.p[0],i=void 0!==e&&e!==r;return t.h.O||y("ES5").S(t,e,i),i?(r[$].P&&(_(t),n(4)),s(e)&&(e=O(t,e),t.l||T(t,e)),t.u&&y("Patches").M(r[$].t,e,t.u,t.s)):e=O(t,r,[]),_(t),t.u&&t.v(t.u,t.s),e!==B?e:void 0}function O(e,t,r){if(g(t))return t;var n=t[$];if(!n)return o(t,function(i,s){return k(e,n,t,i,s,r)},!0),t;if(n.A!==e)return t;if(!n.P)return T(e,n.t,!0),n.t;if(!n.I){n.I=!0,n.A._--;var i=4===n.i||5===n.i?n.o=h(n.k):n.o,s=i,a=!1;3===n.i&&(s=new Set(i),i.clear(),a=!0),o(s,function(t,s){return k(e,n,i,t,s,r,a)}),T(e,i,!1),r&&e.u&&y("Patches").N(n,r,e.u,e.s)}return n.o}function k(e,t,r,n,o,a,c){if(i(o)){var d=O(e,o,a&&t&&3!==t.i&&!u(t.R,n)?a.concat(n):void 0);if(l(r,n,d),!i(d))return;e.m=!1}else c&&r.add(o);if(s(o)&&!g(o)){if(!e.h.D&&e._<1)return;O(e,o),t&&t.A.l||T(e,o)}}function T(e,t,r){void 0===r&&(r=!1),!e.l&&e.h.D&&e.m&&p(t,r)}function C(e,t){var r=e[$];return(r?f(r):e)[t]}function I(e,t){if(t in e)for(var r=Object.getPrototypeOf(e);r;){var n=Object.getOwnPropertyDescriptor(r,t);if(n)return n;r=Object.getPrototypeOf(r)}}function R(e){e.P||(e.P=!0,e.l&&R(e.l))}function x(e){e.o||(e.o=h(e.t))}function A(e,t,r){var n,i,s,o,a,u,l,f=c(t)?y("MapSet").F(t,r):d(t)?y("MapSet").T(t,r):e.O?(s=i={i:(n=Array.isArray(t))?1:0,A:r?r.A:N,P:!1,I:!1,R:{},l:r,t:t,k:null,o:null,j:null,C:!1},o=Z,n&&(s=[i],o=W),u=(a=Proxy.revocable(s,o)).revoke,l=a.proxy,i.k=l,i.j=u,l):y("ES5").J(t,r);return(r?r.A:N).p.push(f),f}function P(e,t){switch(t){case 2:return new Map(e);case 3:return Array.from(e)}return h(e)}var M,N,D="undefined"!=typeof Symbol&&"symbol"==typeof Symbol("x"),L="undefined"!=typeof Map,j="undefined"!=typeof Set,U="undefined"!=typeof Proxy&&void 0!==Proxy.revocable&&"undefined"!=typeof Reflect,B=D?Symbol.for("immer-nothing"):((M={})["immer-nothing"]=!0,M),F=D?Symbol.for("immer-draftable"):"__$immer_draftable",$=D?Symbol.for("immer-state"):"__$immer_state",z=""+Object.prototype.constructor,H="undefined"!=typeof Reflect&&Reflect.ownKeys?Reflect.ownKeys:void 0!==Object.getOwnPropertySymbols?function(e){return Object.getOwnPropertyNames(e).concat(Object.getOwnPropertySymbols(e))}:Object.getOwnPropertyNames,G=Object.getOwnPropertyDescriptors||function(e){var t={};return H(e).forEach(function(r){t[r]=Object.getOwnPropertyDescriptor(e,r)}),t},q={},Z={get:function(e,t){if(t===$)return e;var r,n,i=f(e);if(!u(i,t))return(n=I(i,t))?"value"in n?n.value:null===(r=n.get)||void 0===r?void 0:r.call(e.k):void 0;var o=i[t];return e.I||!s(o)?o:o===C(e.t,t)?(x(e),e.o[t]=A(e.A.h,o,e)):o},has:function(e,t){return t in f(e)},ownKeys:function(e){return Reflect.ownKeys(f(e))},set:function(e,t,r){var n=I(f(e),t);if(null==n?void 0:n.set)return n.set.call(e.k,r),!0;if(!e.P){var i=C(f(e),t),s=null==i?void 0:i[$];if(s&&s.t===r)return e.o[t]=r,e.R[t]=!1,!0;if((r===i?0!==r||1/r==1/i:r!=r&&i!=i)&&(void 0!==r||u(e.t,t)))return!0;x(e),R(e)}return e.o[t]===r&&(void 0!==r||t in e.o)||Number.isNaN(r)&&Number.isNaN(e.o[t])||(e.o[t]=r,e.R[t]=!0),!0},deleteProperty:function(e,t){return void 0!==C(e.t,t)||t in e.t?(e.R[t]=!1,x(e),R(e)):delete e.R[t],e.o&&delete e.o[t],!0},getOwnPropertyDescriptor:function(e,t){var r=f(e),n=Reflect.getOwnPropertyDescriptor(r,t);return n?{writable:!0,configurable:1!==e.i||"length"!==t,enumerable:n.enumerable,value:r[t]}:n},defineProperty:function(){n(11)},getPrototypeOf:function(e){return Object.getPrototypeOf(e.t)},setPrototypeOf:function(){n(12)}},W={};o(Z,function(e,t){W[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}}),W.deleteProperty=function(e,t){return W.set.call(this,e,t,void 0)},W.set=function(e,t,r){return Z.set.call(this,e[0],t,r,e[0])};var K=new(function(){function e(e){var t=this;this.O=U,this.D=!0,this.produce=function(e,r,i){if("function"==typeof e&&"function"!=typeof r){var o,a=r;return r=e,function(e){var n=this;void 0===e&&(e=a);for(var i=arguments.length,s=Array(i>1?i-1:0),o=1;o<i;o++)s[o-1]=arguments[o];return t.produce(e,function(e){var t;return(t=r).call.apply(t,[n,e].concat(s))})}}if("function"!=typeof r&&n(6),void 0!==i&&"function"!=typeof i&&n(7),s(e)){var u=S(t),l=A(t,e,void 0),c=!0;try{o=r(l),c=!1}finally{c?_(u):b(u)}return"undefined"!=typeof Promise&&o instanceof Promise?o.then(function(e){return v(u,i),w(e,u)},function(e){throw _(u),e}):(v(u,i),w(o,u))}if(!e||"object"!=typeof e){if(void 0===(o=r(e))&&(o=e),o===B&&(o=void 0),t.D&&p(o,!0),i){var d=[],f=[];y("Patches").M(e,o,d,f),i(d,f)}return o}n(21,e)},this.produceWithPatches=function(e,r){if("function"==typeof e)return function(r){for(var n=arguments.length,i=Array(n>1?n-1:0),s=1;s<n;s++)i[s-1]=arguments[s];return t.produceWithPatches(r,function(t){return e.apply(void 0,[t].concat(i))})};var n,i,s=t.produce(e,r,function(e,t){n=e,i=t});return"undefined"!=typeof Promise&&s instanceof Promise?s.then(function(e){return[e,n,i]}):[s,n,i]},"boolean"==typeof(null==e?void 0:e.useProxies)&&this.setUseProxies(e.useProxies),"boolean"==typeof(null==e?void 0:e.autoFreeze)&&this.setAutoFreeze(e.autoFreeze)}var t=e.prototype;return t.createDraft=function(e){s(e)||n(8),i(e)&&(i(t=e)||n(22,t),e=function e(t){if(!s(t))return t;var r,n=t[$],i=a(t);if(n){if(!n.P&&(n.i<4||!y("ES5").K(n)))return n.t;n.I=!0,r=P(t,i),n.I=!1}else r=P(t,i);return o(r,function(t,i){var s;n&&(2===a(s=n.t)?s.get(t):s[t])===i||l(r,t,e(i))}),3===i?new Set(r):r}(t));var t,r=S(this),u=A(this,e,void 0);return u[$].C=!0,b(r),u},t.finishDraft=function(e,t){var r=(e&&e[$]).A;return v(r,t),w(void 0,r)},t.setAutoFreeze=function(e){this.D=e},t.setUseProxies=function(e){e&&!U&&n(20),this.O=e},t.applyPatches=function(e,t){for(r=t.length-1;r>=0;r--){var r,n=t[r];if(0===n.path.length&&"replace"===n.op){e=n.value;break}}r>-1&&(t=t.slice(r+1));var s=y("Patches").$;return i(e)?s(e,t):this.produce(e,function(e){return s(e,t)})},e}()),V=K.produce;K.produceWithPatches.bind(K),K.setAutoFreeze.bind(K),K.setUseProxies.bind(K),K.applyPatches.bind(K),K.createDraft.bind(K),K.finishDraft.bind(K),t.ZP=V},90933:function(e,t,r){"use strict";let n;r.d(t,{R:function(){return i}});var i=((n=i||{}).Space=" ",n.Enter="Enter",n.Escape="Escape",n.Backspace="Backspace",n.Delete="Delete",n.ArrowLeft="ArrowLeft",n.ArrowUp="ArrowUp",n.ArrowRight="ArrowRight",n.ArrowDown="ArrowDown",n.Home="Home",n.End="End",n.PageUp="PageUp",n.PageDown="PageDown",n.Tab="Tab",n)},44400:function(e,t,r){"use strict";let n,i,s,o;r.d(t,{v:function(){return B}});var a=r(67294),u=r(23285),l=r(10003),c=r(94924),d=r(1378),f=r(2196),h=r(54671);function p(e){var t;if(e.type)return e.type;let r=null!=(t=e.as)?t:"button";if("string"==typeof r&&"button"===r.toLowerCase())return"button"}var m=r(51813);let g=/([\u2700-\u27BF]|[\uE000-\uF8FF]|\uD83C[\uDC00-\uDFFF]|\uD83D[\uDC00-\uDFFF]|[\u2011-\u26FF]|\uD83E[\uDD10-\uDDFF])/g;function y(e){var t,r;let n=null!=(t=e.innerText)?t:"",i=e.cloneNode(!0);if(!(i instanceof HTMLElement))return n;let s=!1;for(let e of i.querySelectorAll('[hidden],[aria-hidden],[role="img"]'))e.remove(),s=!0;let o=s?null!=(r=i.innerText)?r:"":n;return g.test(o)&&(o=o.replace(g,"")),o}function v(e){return[e.screenX,e.screenY]}var _=r(78961),b=r(24358),S=r(84480),E=((n=E||{})[n.First=0]="First",n[n.Previous=1]="Previous",n[n.Next=2]="Next",n[n.Last=3]="Last",n[n.Specific=4]="Specific",n[n.Nothing=5]="Nothing",n),w=r(93580),O=r(78657),k=r(48844),T=r(18287),C=r(90933),I=((i=I||{})[i.Open=0]="Open",i[i.Closed=1]="Closed",i),R=((s=R||{})[s.Pointer=0]="Pointer",s[s.Other=1]="Other",s),x=((o=x||{})[o.OpenMenu=0]="OpenMenu",o[o.CloseMenu=1]="CloseMenu",o[o.GoToItem=2]="GoToItem",o[o.Search=3]="Search",o[o.ClearSearch=4]="ClearSearch",o[o.RegisterItem=5]="RegisterItem",o[o.UnregisterItem=6]="UnregisterItem",o);function A(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e=>e,r=null!==e.activeItemIndex?e.items[e.activeItemIndex]:null,n=(0,O.z2)(t(e.items.slice()),e=>e.dataRef.current.domRef.current),i=r?n.indexOf(r):null;return -1===i&&(i=null),{items:n,activeItemIndex:i}}let P={1:e=>1===e.menuState?e:{...e,activeItemIndex:null,menuState:1},0:e=>0===e.menuState?e:{...e,__demoMode:!1,menuState:0},2:(e,t)=>{var r;let n=A(e),i=function(e,t){let r=t.resolveItems();if(r.length<=0)return null;let n=t.resolveActiveIndex(),i=null!=n?n:-1;switch(e.focus){case 0:for(let e=0;e<r.length;++e)if(!t.resolveDisabled(r[e],e,r))return e;return n;case 1:for(let e=i-1;e>=0;--e)if(!t.resolveDisabled(r[e],e,r))return e;return n;case 2:for(let e=i+1;e<r.length;++e)if(!t.resolveDisabled(r[e],e,r))return e;return n;case 3:for(let e=r.length-1;e>=0;--e)if(!t.resolveDisabled(r[e],e,r))return e;return n;case 4:for(let n=0;n<r.length;++n)if(t.resolveId(r[n],n,r)===e.id)return n;return n;case 5:return null;default:!function(e){throw Error("Unexpected object: "+e)}(e)}}(t,{resolveItems:()=>n.items,resolveActiveIndex:()=>n.activeItemIndex,resolveId:e=>e.id,resolveDisabled:e=>e.dataRef.current.disabled});return{...e,...n,searchQuery:"",activeItemIndex:i,activationTrigger:null!=(r=t.trigger)?r:1}},3:(e,t)=>{let r=""!==e.searchQuery?0:1,n=e.searchQuery+t.value.toLowerCase(),i=(null!==e.activeItemIndex?e.items.slice(e.activeItemIndex+r).concat(e.items.slice(0,e.activeItemIndex+r)):e.items).find(e=>{var t;return(null==(t=e.dataRef.current.textValue)?void 0:t.startsWith(n))&&!e.dataRef.current.disabled}),s=i?e.items.indexOf(i):-1;return -1===s||s===e.activeItemIndex?{...e,searchQuery:n}:{...e,searchQuery:n,activeItemIndex:s,activationTrigger:1}},4:e=>""===e.searchQuery?e:{...e,searchQuery:"",searchActiveItemIndex:null},5:(e,t)=>{let r=A(e,e=>[...e,{id:t.id,dataRef:t.dataRef}]);return{...e,...r}},6:(e,t)=>{let r=A(e,e=>{let r=e.findIndex(e=>e.id===t.id);return -1!==r&&e.splice(r,1),e});return{...e,...r,activationTrigger:1}}},M=(0,a.createContext)(null);function N(e){let t=(0,a.useContext)(M);if(null===t){let t=Error("<".concat(e," /> is missing a parent <Menu /> component."));throw Error.captureStackTrace&&Error.captureStackTrace(t,N),t}return t}function D(e,t){return(0,k.E)(t.type,P,e,t)}M.displayName="MenuContext";let L=a.Fragment,j=T.AN.RenderStrategy|T.AN.Static,U=a.Fragment,B=Object.assign((0,T.yV)(function(e,t){let{__demoMode:r=!1,...n}=e,i=(0,a.useReducer)(D,{__demoMode:r,menuState:r?0:1,buttonRef:(0,a.createRef)(),itemsRef:(0,a.createRef)(),items:[],searchQuery:"",activeItemIndex:null,activationTrigger:1}),[{menuState:s,itemsRef:o,buttonRef:u},c]=i,d=(0,m.T)(t);(0,f.O)([u,o],(e,t)=>{var r;c({type:1}),(0,O.sP)(t,O.tJ.Loose)||(e.preventDefault(),null==(r=u.current)||r.focus())},0===s);let h=(0,l.z)(()=>{c({type:1})}),p=(0,a.useMemo)(()=>({open:0===s,close:h}),[s,h]);return a.createElement(M.Provider,{value:i},a.createElement(b.up,{value:(0,k.E)(s,{0:b.ZM.Open,1:b.ZM.Closed})},(0,T.sY)({ourProps:{ref:d},theirProps:n,slot:p,defaultTag:L,name:"Menu"})))}),{Button:(0,T.yV)(function(e,t){var r;let n=(0,c.M)(),{id:i="headlessui-menu-button-".concat(n),...s}=e,[o,f]=N("Menu.Button"),h=(0,m.T)(o.buttonRef,t),g=(0,u.G)(),y=(0,l.z)(e=>{switch(e.key){case C.R.Space:case C.R.Enter:case C.R.ArrowDown:e.preventDefault(),e.stopPropagation(),f({type:0}),g.nextFrame(()=>f({type:2,focus:E.First}));break;case C.R.ArrowUp:e.preventDefault(),e.stopPropagation(),f({type:0}),g.nextFrame(()=>f({type:2,focus:E.Last}))}}),v=(0,l.z)(e=>{e.key===C.R.Space&&e.preventDefault()}),_=(0,l.z)(t=>{if((0,S.P)(t.currentTarget))return t.preventDefault();e.disabled||(0===o.menuState?(f({type:1}),g.nextFrame(()=>{var e;return null==(e=o.buttonRef.current)?void 0:e.focus({preventScroll:!0})})):(t.preventDefault(),f({type:0})))}),b=(0,a.useMemo)(()=>({open:0===o.menuState}),[o]),w={ref:h,id:i,type:function(e,t){let[r,n]=(0,a.useState)(()=>p(e));return(0,d.e)(()=>{n(p(e))},[e.type,e.as]),(0,d.e)(()=>{r||t.current&&t.current instanceof HTMLButtonElement&&!t.current.hasAttribute("type")&&n("button")},[r,t]),r}(e,o.buttonRef),"aria-haspopup":"menu","aria-controls":null==(r=o.itemsRef.current)?void 0:r.id,"aria-expanded":0===o.menuState,onKeyDown:y,onKeyUp:v,onClick:_};return(0,T.sY)({ourProps:w,theirProps:s,slot:b,defaultTag:"button",name:"Menu.Button"})}),Items:(0,T.yV)(function(e,t){var r,n;let i=(0,c.M)(),{id:s="headlessui-menu-items-".concat(i),...o}=e,[f,p]=N("Menu.Items"),g=(0,m.T)(f.itemsRef,t),y=(0,h.i)(f.itemsRef),v=(0,u.G)(),S=(0,b.oJ)(),k=null!==S?(S&b.ZM.Open)===b.ZM.Open:0===f.menuState;(0,a.useEffect)(()=>{let e=f.itemsRef.current;e&&0===f.menuState&&e!==(null==y?void 0:y.activeElement)&&e.focus({preventScroll:!0})},[f.menuState,f.itemsRef,y]),function(e){let{container:t,accept:r,walk:n,enabled:i=!0}=e,s=(0,a.useRef)(r),o=(0,a.useRef)(n);(0,a.useEffect)(()=>{s.current=r,o.current=n},[r,n]),(0,d.e)(()=>{if(!t||!i)return;let e=(0,_.r)(t);if(!e)return;let r=s.current,n=o.current,a=Object.assign(e=>r(e),{acceptNode:r}),u=e.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,a,!1);for(;u.nextNode();)n(u.currentNode)},[t,i,s,o])}({container:f.itemsRef.current,enabled:0===f.menuState,accept:e=>"menuitem"===e.getAttribute("role")?NodeFilter.FILTER_REJECT:e.hasAttribute("role")?NodeFilter.FILTER_SKIP:NodeFilter.FILTER_ACCEPT,walk(e){e.setAttribute("role","none")}});let I=(0,l.z)(e=>{var t,r;switch(v.dispose(),e.key){case C.R.Space:if(""!==f.searchQuery)return e.preventDefault(),e.stopPropagation(),p({type:3,value:e.key});case C.R.Enter:if(e.preventDefault(),e.stopPropagation(),p({type:1}),null!==f.activeItemIndex){let{dataRef:e}=f.items[f.activeItemIndex];null==(r=null==(t=e.current)?void 0:t.domRef.current)||r.click()}(0,O.wI)(f.buttonRef.current);break;case C.R.ArrowDown:return e.preventDefault(),e.stopPropagation(),p({type:2,focus:E.Next});case C.R.ArrowUp:return e.preventDefault(),e.stopPropagation(),p({type:2,focus:E.Previous});case C.R.Home:case C.R.PageUp:return e.preventDefault(),e.stopPropagation(),p({type:2,focus:E.First});case C.R.End:case C.R.PageDown:return e.preventDefault(),e.stopPropagation(),p({type:2,focus:E.Last});case C.R.Escape:e.preventDefault(),e.stopPropagation(),p({type:1}),(0,w.k)().nextFrame(()=>{var e;return null==(e=f.buttonRef.current)?void 0:e.focus({preventScroll:!0})});break;case C.R.Tab:e.preventDefault(),e.stopPropagation(),p({type:1}),(0,w.k)().nextFrame(()=>{(0,O.EO)(f.buttonRef.current,e.shiftKey?O.TO.Previous:O.TO.Next)});break;default:1===e.key.length&&(p({type:3,value:e.key}),v.setTimeout(()=>p({type:4}),350))}}),R=(0,l.z)(e=>{e.key===C.R.Space&&e.preventDefault()}),x=(0,a.useMemo)(()=>({open:0===f.menuState}),[f]),A={"aria-activedescendant":null===f.activeItemIndex||null==(r=f.items[f.activeItemIndex])?void 0:r.id,"aria-labelledby":null==(n=f.buttonRef.current)?void 0:n.id,id:s,onKeyDown:I,onKeyUp:R,role:"menu",tabIndex:0,ref:g};return(0,T.sY)({ourProps:A,theirProps:o,slot:x,defaultTag:"div",features:j,visible:k,name:"Menu.Items"})}),Item:(0,T.yV)(function(e,t){let r,n,i,s=(0,c.M)(),{id:o="headlessui-menu-item-".concat(s),disabled:u=!1,...f}=e,[h,p]=N("Menu.Item"),g=null!==h.activeItemIndex&&h.items[h.activeItemIndex].id===o,_=(0,a.useRef)(null),b=(0,m.T)(t,_);(0,d.e)(()=>{if(h.__demoMode||0!==h.menuState||!g||0===h.activationTrigger)return;let e=(0,w.k)();return e.requestAnimationFrame(()=>{var e,t;null==(t=null==(e=_.current)?void 0:e.scrollIntoView)||t.call(e,{block:"nearest"})}),e.dispose},[h.__demoMode,_,g,h.menuState,h.activationTrigger,h.activeItemIndex]);let S=(r=(0,a.useRef)(""),n=(0,a.useRef)(""),(0,l.z)(()=>{let e=_.current;if(!e)return"";let t=e.innerText;if(r.current===t)return n.current;let i=(function(e){let t=e.getAttribute("aria-label");if("string"==typeof t)return t.trim();let r=e.getAttribute("aria-labelledby");if(r){let e=r.split(" ").map(e=>{let t=document.getElementById(e);if(t){let e=t.getAttribute("aria-label");return"string"==typeof e?e.trim():y(t).trim()}return null}).filter(Boolean);if(e.length>0)return e.join(", ")}return y(e).trim()})(e).trim().toLowerCase();return r.current=t,n.current=i,i})),k=(0,a.useRef)({disabled:u,domRef:_,get textValue(){return S()}});(0,d.e)(()=>{k.current.disabled=u},[k,u]),(0,d.e)(()=>(p({type:5,id:o,dataRef:k}),()=>p({type:6,id:o})),[k,o]);let C=(0,l.z)(()=>{p({type:1})}),I=(0,l.z)(e=>{if(u)return e.preventDefault();p({type:1}),(0,O.wI)(h.buttonRef.current)}),R=(0,l.z)(()=>{if(u)return p({type:2,focus:E.Nothing});p({type:2,focus:E.Specific,id:o})}),x=(i=(0,a.useRef)([-1,-1]),{wasMoved(e){let t=v(e);return(i.current[0]!==t[0]||i.current[1]!==t[1])&&(i.current=t,!0)},update(e){i.current=v(e)}}),A=(0,l.z)(e=>x.update(e)),P=(0,l.z)(e=>{x.wasMoved(e)&&(u||g||p({type:2,focus:E.Specific,id:o,trigger:0}))}),M=(0,l.z)(e=>{x.wasMoved(e)&&(u||g&&p({type:2,focus:E.Nothing}))}),D=(0,a.useMemo)(()=>({active:g,disabled:u,close:C}),[g,u,C]);return(0,T.sY)({ourProps:{id:o,ref:b,role:"menuitem",tabIndex:!0===u?void 0:-1,"aria-disabled":!0===u||void 0,disabled:void 0,onClick:I,onFocus:R,onPointerEnter:A,onMouseEnter:A,onPointerMove:P,onMouseMove:P,onPointerLeave:M,onMouseLeave:M},theirProps:f,slot:D,defaultTag:U,name:"Menu.Item"})})})},45007:function(e,t,r){"use strict";let n;r.d(t,{u:function(){return P}});var i=r(67294),s=r(23285),o=r(10003),a=r(42308),u=r(1378),l=r(85508),c=r(62047),d=r(51813),f=r(93580),h=r(48844);function p(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];e&&r.length>0&&e.classList.add(...r)}function m(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];e&&r.length>0&&e.classList.remove(...r)}var g=r(24358),y=r(25602),v=r(18287);function _(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"";return e.split(/\s+/).filter(e=>e.length>1)}let b=(0,i.createContext)(null);b.displayName="TransitionContext";var S=((n=S||{}).Visible="visible",n.Hidden="hidden",n);let E=(0,i.createContext)(null);function w(e){return"children"in e?w(e.children):e.current.filter(e=>{let{el:t}=e;return null!==t.current}).filter(e=>{let{state:t}=e;return"visible"===t}).length>0}function O(e,t){let r=(0,l.E)(e),n=(0,i.useRef)([]),u=(0,a.t)(),c=(0,s.G)(),d=(0,o.z)(function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:v.l4.Hidden,i=n.current.findIndex(t=>{let{el:r}=t;return r===e});-1!==i&&((0,h.E)(t,{[v.l4.Unmount](){n.current.splice(i,1)},[v.l4.Hidden](){n.current[i].state="hidden"}}),c.microTask(()=>{var e;!w(n)&&u.current&&(null==(e=r.current)||e.call(r))}))}),f=(0,o.z)(e=>{let t=n.current.find(t=>{let{el:r}=t;return r===e});return t?"visible"!==t.state&&(t.state="visible"):n.current.push({el:e,state:"visible"}),()=>d(e,v.l4.Unmount)}),p=(0,i.useRef)([]),m=(0,i.useRef)(Promise.resolve()),g=(0,i.useRef)({enter:[],leave:[],idle:[]}),y=(0,o.z)((e,r,n)=>{p.current.splice(0),t&&(t.chains.current[r]=t.chains.current[r].filter(t=>{let[r]=t;return r!==e})),null==t||t.chains.current[r].push([e,new Promise(e=>{p.current.push(e)})]),null==t||t.chains.current[r].push([e,new Promise(e=>{Promise.all(g.current[r].map(e=>{let[t,r]=e;return r})).then(()=>e())})]),"enter"===r?m.current=m.current.then(()=>null==t?void 0:t.wait.current).then(()=>n(r)):n(r)}),_=(0,o.z)((e,t,r)=>{Promise.all(g.current[t].splice(0).map(e=>{let[t,r]=e;return r})).then(()=>{var e;null==(e=p.current.shift())||e()}).then(()=>r(t))});return(0,i.useMemo)(()=>({children:n,register:f,unregister:d,onStart:y,onStop:_,wait:m,chains:g}),[f,d,n,y,_,g,m])}function k(){}E.displayName="NestingContext";let T=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function C(e){var t;let r={};for(let n of T)r[n]=null!=(t=e[n])?t:k;return r}let I=v.AN.RenderStrategy,R=(0,v.yV)(function(e,t){let{show:r,appear:n=!1,unmount:s=!0,...a}=e,l=(0,i.useRef)(null),f=(0,d.T)(l,t);(0,c.H)();let h=(0,g.oJ)();if(void 0===r&&null!==h&&(r=(h&g.ZM.Open)===g.ZM.Open),![!0,!1].includes(r))throw Error("A <Transition /> is used but it is missing a `show={true | false}` prop.");let[p,m]=(0,i.useState)(r?"visible":"hidden"),y=O(()=>{m("hidden")}),[_,S]=(0,i.useState)(!0),k=(0,i.useRef)([r]);(0,u.e)(()=>{!1!==_&&k.current[k.current.length-1]!==r&&(k.current.push(r),S(!1))},[k,r]);let T=(0,i.useMemo)(()=>({show:r,appear:n,initial:_}),[r,n,_]);(0,i.useEffect)(()=>{if(r)m("visible");else if(w(y)){let e=l.current;if(!e)return;let t=e.getBoundingClientRect();0===t.x&&0===t.y&&0===t.width&&0===t.height&&m("hidden")}else m("hidden")},[r,y]);let C={unmount:s},R=(0,o.z)(()=>{var t;_&&S(!1),null==(t=e.beforeEnter)||t.call(e)}),A=(0,o.z)(()=>{var t;_&&S(!1),null==(t=e.beforeLeave)||t.call(e)});return i.createElement(E.Provider,{value:y},i.createElement(b.Provider,{value:T},(0,v.sY)({ourProps:{...C,as:i.Fragment,children:i.createElement(x,{ref:f,...C,...a,beforeEnter:R,beforeLeave:A})},theirProps:{},defaultTag:i.Fragment,features:I,visible:"visible"===p,name:"Transition"})))}),x=(0,v.yV)(function(e,t){var r,n,S;let k;let{beforeEnter:T,afterEnter:R,beforeLeave:x,afterLeave:A,enter:P,enterFrom:M,enterTo:N,entered:D,leave:L,leaveFrom:j,leaveTo:U,...B}=e,F=(0,i.useRef)(null),$=(0,d.T)(F,t),z=null==(r=B.unmount)||r?v.l4.Unmount:v.l4.Hidden,{show:H,appear:G,initial:q}=function(){let e=(0,i.useContext)(b);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),[Z,W]=(0,i.useState)(H?"visible":"hidden"),K=function(){let e=(0,i.useContext)(E);if(null===e)throw Error("A <Transition.Child /> is used but it is missing a parent <Transition /> or <Transition.Root />.");return e}(),{register:V,unregister:Q}=K;(0,i.useEffect)(()=>V(F),[V,F]),(0,i.useEffect)(()=>{if(z===v.l4.Hidden&&F.current){if(H&&"visible"!==Z){W("visible");return}return(0,h.E)(Z,{hidden:()=>Q(F),visible:()=>V(F)})}},[Z,F,V,Q,H,z]);let X=(0,l.E)({base:_(B.className),enter:_(P),enterFrom:_(M),enterTo:_(N),entered:_(D),leave:_(L),leaveFrom:_(j),leaveTo:_(U)}),J=(S={beforeEnter:T,afterEnter:R,beforeLeave:x,afterLeave:A},k=(0,i.useRef)(C(S)),(0,i.useEffect)(()=>{k.current=C(S)},[S]),k),Y=(0,c.H)();(0,i.useEffect)(()=>{if(Y&&"visible"===Z&&null===F.current)throw Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[F,Z,Y]);let ee=G&&H&&q,et=Y&&(!q||G)?H?"enter":"leave":"idle",er=function(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,[t,r]=(0,i.useState)(e),n=(0,a.t)(),s=(0,i.useCallback)(e=>{n.current&&r(t=>t|e)},[t,n]),o=(0,i.useCallback)(e=>!!(t&e),[t]);return{flags:t,addFlag:s,hasFlag:o,removeFlag:(0,i.useCallback)(e=>{n.current&&r(t=>t&~e)},[r,n]),toggleFlag:(0,i.useCallback)(e=>{n.current&&r(t=>t^e)},[r])}}(0),en=(0,o.z)(e=>(0,h.E)(e,{enter:()=>{er.addFlag(g.ZM.Opening),J.current.beforeEnter()},leave:()=>{er.addFlag(g.ZM.Closing),J.current.beforeLeave()},idle:()=>{}})),ei=(0,o.z)(e=>(0,h.E)(e,{enter:()=>{er.removeFlag(g.ZM.Opening),J.current.afterEnter()},leave:()=>{er.removeFlag(g.ZM.Closing),J.current.afterLeave()},idle:()=>{}})),es=O(()=>{W("hidden"),Q(F)},K),eo=(0,i.useRef)(!1);!function(e){let{immediate:t,container:r,direction:n,classes:i,onStart:o,onStop:c}=e,d=(0,a.t)(),g=(0,s.G)(),y=(0,l.E)(n);(0,u.e)(()=>{t&&(y.current="enter")},[t]),(0,u.e)(()=>{let e=(0,f.k)();g.add(e.dispose);let t=r.current;if(t&&"idle"!==y.current&&d.current){var n,s,a;let r,u,l,d,g,v,_;return e.dispose(),o.current(y.current),e.add((n=i.current,s="enter"===y.current,a=()=>{e.dispose(),c.current(y.current)},u=s?"enter":"leave",l=(0,f.k)(),d=void 0!==a?(r={called:!1},function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];if(!r.called)return r.called=!0,a(...t)}):()=>{},"enter"===u&&(t.removeAttribute("hidden"),t.style.display=""),g=(0,h.E)(u,{enter:()=>n.enter,leave:()=>n.leave}),v=(0,h.E)(u,{enter:()=>n.enterTo,leave:()=>n.leaveTo}),_=(0,h.E)(u,{enter:()=>n.enterFrom,leave:()=>n.leaveFrom}),m(t,...n.base,...n.enter,...n.enterTo,...n.enterFrom,...n.leave,...n.leaveFrom,...n.leaveTo,...n.entered),p(t,...n.base,...g,..._),l.nextFrame(()=>{m(t,...n.base,...g,..._),p(t,...n.base,...g,...v),function(e,t){let r=(0,f.k)();if(!e)return r.dispose;let{transitionDuration:n,transitionDelay:i}=getComputedStyle(e),[s,o]=[n,i].map(e=>{let[t=0]=e.split(",").filter(Boolean).map(e=>e.includes("ms")?parseFloat(e):1e3*parseFloat(e)).sort((e,t)=>t-e);return t}),a=s+o;if(0!==a){r.group(r=>{r.setTimeout(()=>{t(),r.dispose()},a),r.addEventListener(e,"transitionrun",e=>{e.target===e.currentTarget&&r.dispose()})});let n=r.addEventListener(e,"transitionend",e=>{e.target===e.currentTarget&&(t(),n())})}else t();r.add(()=>t()),r.dispose}(t,()=>(m(t,...n.base,...g),p(t,...n.base,...n.entered),d()))}),l.dispose)),e.dispose}},[n])}({immediate:ee,container:F,classes:X,direction:et,onStart:(0,l.E)(e=>{eo.current=!0,es.onStart(F,e,en)}),onStop:(0,l.E)(e=>{eo.current=!1,es.onStop(F,e,ei),"leave"!==e||w(es)||(W("hidden"),Q(F))})});let ea=B;return ee?ea={...ea,className:(0,y.A)(B.className,...X.current.enter,...X.current.enterFrom)}:eo.current&&(ea.className=(0,y.A)(B.className,null==(n=F.current)?void 0:n.className),""===ea.className&&delete ea.className),i.createElement(E.Provider,{value:es},i.createElement(g.up,{value:(0,h.E)(Z,{visible:g.ZM.Open,hidden:g.ZM.Closed})|er.flags},(0,v.sY)({ourProps:{ref:$},theirProps:ea,defaultTag:"div",features:I,visible:"visible"===Z,name:"Transition.Child"})))}),A=(0,v.yV)(function(e,t){let r=null!==(0,i.useContext)(b),n=null!==(0,g.oJ)();return i.createElement(i.Fragment,null,!r&&n?i.createElement(R,{ref:t,...e}):i.createElement(x,{ref:t,...e}))}),P=Object.assign(R,{Child:A,Root:R})},23285:function(e,t,r){"use strict";r.d(t,{G:function(){return s}});var n=r(67294),i=r(93580);function s(){let[e]=(0,n.useState)(i.k);return(0,n.useEffect)(()=>()=>e.dispose(),[e]),e}},10003:function(e,t,r){"use strict";r.d(t,{z:function(){return s}});var n=r(67294),i=r(85508);let s=function(e){let t=(0,i.E)(e);return n.useCallback(function(){for(var e=arguments.length,r=Array(e),n=0;n<e;n++)r[n]=arguments[n];return t.current(...r)},[t])}},94924:function(e,t,r){"use strict";r.d(t,{M:function(){return u}});var n,i=r(67294),s=r(41830),o=r(1378),a=r(62047);let u=null!=(n=i.useId)?n:function(){let e=(0,a.H)(),[t,r]=i.useState(e?()=>s.O.nextId():null);return(0,o.e)(()=>{null===t&&r(s.O.nextId())},[t]),null!=t?""+t:void 0}},42308:function(e,t,r){"use strict";r.d(t,{t:function(){return s}});var n=r(67294),i=r(1378);function s(){let e=(0,n.useRef)(!1);return(0,i.e)(()=>(e.current=!0,()=>{e.current=!1}),[]),e}},1378:function(e,t,r){"use strict";r.d(t,{e:function(){return s}});var n=r(67294),i=r(41830);let s=(e,t)=>{i.O.isServer?(0,n.useEffect)(e,t):(0,n.useLayoutEffect)(e,t)}},85508:function(e,t,r){"use strict";r.d(t,{E:function(){return s}});var n=r(67294),i=r(1378);function s(e){let t=(0,n.useRef)(e);return(0,i.e)(()=>{t.current=e},[e]),t}},2196:function(e,t,r){"use strict";r.d(t,{O:function(){return l}});var n=r(67294),i=r(78657),s=r(27253),o=r(85508);function a(e,t,r){let i=(0,o.E)(t);(0,n.useEffect)(()=>{function t(e){i.current(e)}return document.addEventListener(e,t,r),()=>document.removeEventListener(e,t,r)},[e,r])}var u=r(59264);function l(e,t){let r=!(arguments.length>2)||void 0===arguments[2]||arguments[2],o=(0,n.useRef)(!1);function l(r,n){if(!o.current||r.defaultPrevented)return;let s=n(r);if(null!==s&&s.getRootNode().contains(s)&&s.isConnected){for(let t of function e(t){return"function"==typeof t?e(t()):Array.isArray(t)||t instanceof Set?t:[t]}(e)){if(null===t)continue;let e=t instanceof HTMLElement?t:t.current;if(null!=e&&e.contains(s)||r.composed&&r.composedPath().includes(e))return}return(0,i.sP)(s,i.tJ.Loose)||-1===s.tabIndex||r.preventDefault(),t(r,s)}}(0,n.useEffect)(()=>{requestAnimationFrame(()=>{o.current=r})},[r]);let c=(0,n.useRef)(null);a("pointerdown",e=>{var t,r;o.current&&(c.current=(null==(r=null==(t=e.composedPath)?void 0:t.call(e))?void 0:r[0])||e.target)},!0),a("mousedown",e=>{var t,r;o.current&&(c.current=(null==(r=null==(t=e.composedPath)?void 0:t.call(e))?void 0:r[0])||e.target)},!0),a("click",e=>{(0,s.tq)()||c.current&&(l(e,()=>c.current),c.current=null)},!0),a("touchend",e=>l(e,()=>e.target instanceof HTMLElement?e.target:null),!0),(0,u.s)("blur",e=>l(e,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}},54671:function(e,t,r){"use strict";r.d(t,{i:function(){return s}});var n=r(67294),i=r(78961);function s(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return(0,n.useMemo)(()=>(0,i.r)(...t),[...t])}},62047:function(e,t,r){"use strict";r.d(t,{H:function(){return o}});var n,i=r(67294),s=r(41830);function o(){let e;let t=(e="undefined"==typeof document,(0,(n||(n=r.t(i,2))).useSyncExternalStore)(()=>()=>{},()=>!1,()=>!e)),[o,a]=i.useState(s.O.isHandoffComplete);return o&&!1===s.O.isHandoffComplete&&a(!1),i.useEffect(()=>{!0!==o&&a(!0)},[o]),i.useEffect(()=>s.O.handoff(),[]),!t&&o}},51813:function(e,t,r){"use strict";r.d(t,{T:function(){return a},h:function(){return o}});var n=r(67294),i=r(10003);let s=Symbol();function o(e){let t=!(arguments.length>1)||void 0===arguments[1]||arguments[1];return Object.assign(e,{[s]:t})}function a(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];let o=(0,n.useRef)(t);(0,n.useEffect)(()=>{o.current=t},[t]);let a=(0,i.z)(e=>{for(let t of o.current)null!=t&&("function"==typeof t?t(e):t.current=e)});return t.every(e=>null==e||(null==e?void 0:e[s]))?void 0:a}},59264:function(e,t,r){"use strict";r.d(t,{s:function(){return s}});var n=r(67294),i=r(85508);function s(e,t,r){let s=(0,i.E)(t);(0,n.useEffect)(()=>{function t(e){s.current(e)}return window.addEventListener(e,t,r),()=>window.removeEventListener(e,t,r)},[e,r])}},24358:function(e,t,r){"use strict";let n;r.d(t,{ZM:function(){return o},oJ:function(){return a},up:function(){return u}});var i=r(67294);let s=(0,i.createContext)(null);s.displayName="OpenClosedContext";var o=((n=o||{})[n.Open=1]="Open",n[n.Closed=2]="Closed",n[n.Closing=4]="Closing",n[n.Opening=8]="Opening",n);function a(){return(0,i.useContext)(s)}function u(e){let{value:t,children:r}=e;return i.createElement(s.Provider,{value:t},r)}},84480:function(e,t,r){"use strict";function n(e){let t=e.parentElement,r=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(r=t),t=t.parentElement;let n=(null==t?void 0:t.getAttribute("disabled"))==="";return!(n&&function(e){if(!e)return!1;let t=e.previousElementSibling;for(;null!==t;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}(r))&&n}r.d(t,{P:function(){return n}})},25602:function(e,t,r){"use strict";function n(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return Array.from(new Set(t.flatMap(e=>"string"==typeof e?e.split(" "):[]))).filter(Boolean).join(" ")}r.d(t,{A:function(){return n}})},93580:function(e,t,r){"use strict";r.d(t,{k:function(){return function e(){let t=[],r={addEventListener:(e,t,n,i)=>(e.addEventListener(t,n,i),r.add(()=>e.removeEventListener(t,n,i))),requestAnimationFrame(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let i=requestAnimationFrame(...t);return r.add(()=>cancelAnimationFrame(i))},nextFrame(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];return r.requestAnimationFrame(()=>r.requestAnimationFrame(...t))},setTimeout(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];let i=setTimeout(...t);return r.add(()=>clearTimeout(i))},microTask(){for(var e=arguments.length,t=Array(e),i=0;i<e;i++)t[i]=arguments[i];let s={current:!0};return(0,n.Y)(()=>{s.current&&t[0]()}),r.add(()=>{s.current=!1})},style(e,t,r){let n=e.style.getPropertyValue(t);return Object.assign(e.style,{[t]:r}),this.add(()=>{Object.assign(e.style,{[t]:n})})},group(t){let r=e();return t(r),this.add(()=>r.dispose())},add:e=>(t.push(e),()=>{let r=t.indexOf(e);if(r>=0)for(let e of t.splice(r,1))e()}),dispose(){for(let e of t.splice(0))e()}};return r}}});var n=r(11291)},41830:function(e,t,r){"use strict";r.d(t,{O:function(){return a}});var n=Object.defineProperty,i=(e,t,r)=>t in e?n(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,s=(e,t,r)=>(i(e,"symbol"!=typeof t?t+"":t,r),r);class o{set(e){this.current!==e&&(this.handoffState="pending",this.currentId=0,this.current=e)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return"server"===this.current}get isClient(){return"client"===this.current}detect(){return"undefined"==typeof document?"server":"client"}handoff(){"pending"===this.handoffState&&(this.handoffState="complete")}get isHandoffComplete(){return"complete"===this.handoffState}constructor(){s(this,"current",this.detect()),s(this,"handoffState","pending"),s(this,"currentId",0)}}let a=new o},78657:function(e,t,r){"use strict";let n,i,s,o,a;r.d(t,{C5:function(){return b},EO:function(){return E},TO:function(){return f},fE:function(){return h},jA:function(){return w},sP:function(){return y},tJ:function(){return g},wI:function(){return v},z2:function(){return S}});var u=r(93580),l=r(48844),c=r(78961);let d=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>"".concat(e,":not([tabindex='-1'])")).join(",");var f=((n=f||{})[n.First=1]="First",n[n.Previous=2]="Previous",n[n.Next=4]="Next",n[n.Last=8]="Last",n[n.WrapAround=16]="WrapAround",n[n.NoScroll=32]="NoScroll",n),h=((i=h||{})[i.Error=0]="Error",i[i.Overflow=1]="Overflow",i[i.Success=2]="Success",i[i.Underflow=3]="Underflow",i),p=((s=p||{})[s.Previous=-1]="Previous",s[s.Next=1]="Next",s);function m(){let e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:document.body;return null==e?[]:Array.from(e.querySelectorAll(d)).sort((e,t)=>Math.sign((e.tabIndex||Number.MAX_SAFE_INTEGER)-(t.tabIndex||Number.MAX_SAFE_INTEGER)))}var g=((o=g||{})[o.Strict=0]="Strict",o[o.Loose=1]="Loose",o);function y(e){var t;let r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return e!==(null==(t=(0,c.r)(e))?void 0:t.body)&&(0,l.E)(r,{0:()=>e.matches(d),1(){let t=e;for(;null!==t;){if(t.matches(d))return!0;t=t.parentElement}return!1}})}function v(e){let t=(0,c.r)(e);(0,u.k)().nextFrame(()=>{t&&!y(t.activeElement,0)&&b(e)})}var _=((a=_||{})[a.Keyboard=0]="Keyboard",a[a.Mouse=1]="Mouse",a);function b(e){null==e||e.focus({preventScroll:!0})}function S(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:e=>e;return e.slice().sort((e,r)=>{let n=t(e),i=t(r);if(null===n||null===i)return 0;let s=n.compareDocumentPosition(i);return s&Node.DOCUMENT_POSITION_FOLLOWING?-1:s&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function E(e,t){return w(m(),t,{relativeTo:e})}function w(e,t){var r,n,i;let{sorted:s=!0,relativeTo:o=null,skipElements:a=[]}=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},u=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,l=Array.isArray(e)?s?S(e):e:m(e);a.length>0&&l.length>1&&(l=l.filter(e=>!a.includes(e))),o=null!=o?o:u.activeElement;let c=(()=>{if(5&t)return 1;if(10&t)return -1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),d=(()=>{if(1&t)return 0;if(2&t)return Math.max(0,l.indexOf(o))-1;if(4&t)return Math.max(0,l.indexOf(o))+1;if(8&t)return l.length-1;throw Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),f=32&t?{preventScroll:!0}:{},h=0,p=l.length,g;do{if(h>=p||h+p<=0)return 0;let e=d+h;if(16&t)e=(e+p)%p;else{if(e<0)return 3;if(e>=p)return 1}null==(g=l[e])||g.focus(f),h+=c}while(g!==u.activeElement);return 6&t&&null!=(i=null==(n=null==(r=g)?void 0:r.matches)?void 0:n.call(r,"textarea,input"))&&i&&g.select(),2}"undefined"!=typeof document&&(document.addEventListener("keydown",e=>{e.metaKey||e.altKey||e.ctrlKey||(document.documentElement.dataset.headlessuiFocusVisible="")},!0),document.addEventListener("click",e=>{1===e.detail?delete document.documentElement.dataset.headlessuiFocusVisible:0===e.detail&&(document.documentElement.dataset.headlessuiFocusVisible="")},!0))},48844:function(e,t,r){"use strict";function n(e,t){for(var r=arguments.length,i=Array(r>2?r-2:0),s=2;s<r;s++)i[s-2]=arguments[s];if(e in t){let r=t[e];return"function"==typeof r?r(...i):r}let o=Error('Tried to handle "'.concat(e,'" but there is no handler defined. Only defined handlers are: ').concat(Object.keys(t).map(e=>'"'.concat(e,'"')).join(", "),"."));throw Error.captureStackTrace&&Error.captureStackTrace(o,n),o}r.d(t,{E:function(){return n}})},11291:function(e,t,r){"use strict";function n(e){"function"==typeof queueMicrotask?queueMicrotask(e):Promise.resolve().then(e).catch(e=>setTimeout(()=>{throw e}))}r.d(t,{Y:function(){return n}})},78961:function(e,t,r){"use strict";r.d(t,{r:function(){return i}});var n=r(41830);function i(e){return n.O.isServer?null:e instanceof Node?e.ownerDocument:null!=e&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}},27253:function(e,t,r){"use strict";function n(){return/iPhone/gi.test(window.navigator.platform)||/Mac/gi.test(window.navigator.platform)&&window.navigator.maxTouchPoints>0}function i(){return n()||/Android/gi.test(window.navigator.userAgent)}r.d(t,{gn:function(){return n},tq:function(){return i}})},18287:function(e,t,r){"use strict";let n,i;r.d(t,{AN:function(){return u},l4:function(){return l},sY:function(){return c},yV:function(){return p}});var s=r(67294),o=r(25602),a=r(48844),u=((n=u||{})[n.None=0]="None",n[n.RenderStrategy=1]="RenderStrategy",n[n.Static=2]="Static",n),l=((i=l||{})[i.Unmount=0]="Unmount",i[i.Hidden=1]="Hidden",i);function c(e){let{ourProps:t,theirProps:r,slot:n,defaultTag:i,features:s,visible:o=!0,name:u,mergeRefs:l}=e;l=null!=l?l:f;let c=h(r,t);if(o)return d(c,n,i,u,l);let p=null!=s?s:0;if(2&p){let{static:e=!1,...t}=c;if(e)return d(t,n,i,u,l)}if(1&p){let{unmount:e=!0,...t}=c;return(0,a.E)(e?0:1,{0:()=>null,1:()=>d({...t,hidden:!0,style:{display:"none"}},n,i,u,l)})}return d(c,n,i,u,l)}function d(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,n=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0,{as:a=r,children:u,refName:l="ref",...c}=g(e,["unmount","static"]),d=void 0!==e.ref?{[l]:e.ref}:{},f="function"==typeof u?u(t):u;"className"in c&&c.className&&"function"==typeof c.className&&(c.className=c.className(t));let p={};if(t){let e=!1,r=[];for(let[n,i]of Object.entries(t))"boolean"==typeof i&&(e=!0),!0===i&&r.push(n);e&&(p["data-headlessui-state"]=r.join(" "))}if(a===s.Fragment&&Object.keys(m(c)).length>0){if(!(0,s.isValidElement)(f)||Array.isArray(f)&&f.length>1)throw Error(['Passing props on "Fragment"!',"","The current component <".concat(n,' /> is rendering a "Fragment".'),"However we need to passthrough the following props:",Object.keys(c).map(e=>"  - ".concat(e)).join("\n"),"","You can apply a few solutions:",['Add an `as="..."` prop, to ensure that we render an actual element instead of a "Fragment".',"Render a single element as the child so that we can forward the props onto that element."].map(e=>"  - ".concat(e)).join("\n")].join("\n"));let e=f.props,t="function"==typeof(null==e?void 0:e.className)?function(){for(var t=arguments.length,r=Array(t),n=0;n<t;n++)r[n]=arguments[n];return(0,o.A)(null==e?void 0:e.className(...r),c.className)}:(0,o.A)(null==e?void 0:e.className,c.className);return(0,s.cloneElement)(f,Object.assign({},h(f.props,m(g(c,["ref"]))),p,d,{ref:i(f.ref,d.ref)},t?{className:t}:{}))}return(0,s.createElement)(a,Object.assign({},g(c,["ref"]),a!==s.Fragment&&d,a!==s.Fragment&&p),f)}function f(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];return t.every(e=>null==e)?void 0:e=>{for(let r of t)null!=r&&("function"==typeof r?r(e):r.current=e)}}function h(){for(var e=arguments.length,t=Array(e),r=0;r<e;r++)t[r]=arguments[r];if(0===t.length)return{};if(1===t.length)return t[0];let n={},i={};for(let e of t)for(let t in e)t.startsWith("on")&&"function"==typeof e[t]?(null!=i[t]||(i[t]=[]),i[t].push(e[t])):n[t]=e[t];if(n.disabled||n["aria-disabled"])return Object.assign(n,Object.fromEntries(Object.keys(i).map(e=>[e,void 0])));for(let e in i)Object.assign(n,{[e](t){for(var r=arguments.length,n=Array(r>1?r-1:0),s=1;s<r;s++)n[s-1]=arguments[s];for(let r of i[e]){if((t instanceof Event||(null==t?void 0:t.nativeEvent)instanceof Event)&&t.defaultPrevented)return;r(t,...n)}}});return n}function p(e){var t;return Object.assign((0,s.forwardRef)(e),{displayName:null!=(t=e.displayName)?t:e.name})}function m(e){let t=Object.assign({},e);for(let e in t)void 0===t[e]&&delete t[e];return t}function g(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],r=Object.assign({},e);for(let e of t)e in r&&delete r[e];return r}},50083:function(e,t,r){"use strict";var n=r(67294);let i=n.forwardRef(function(e,t){let{title:r,titleId:i,...s}=e;return n.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},s),r?n.createElement("title",{id:i},r):null,n.createElement("path",{d:"M6.28 5.22a.75.75 0 0 0-1.06 1.06L8.94 10l-3.72 3.72a.75.75 0 1 0 1.06 1.06L10 11.06l3.72 3.72a.75.75 0 1 0 1.06-1.06L11.06 10l3.72-3.72a.75.75 0 0 0-1.06-1.06L10 8.94 6.28 5.22Z"}))});t.Z=i},49881:function(e,t,r){"use strict";var n=r(67294);let i=n.forwardRef(function(e,t){let{title:r,titleId:i,...s}=e;return n.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},s),r?n.createElement("title",{id:i},r):null,n.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M13.5 6H5.25A2.25 2.25 0 0 0 3 8.25v10.5A2.25 2.25 0 0 0 5.25 21h10.5A2.25 2.25 0 0 0 18 18.75V10.5m-10.5 6L21 3m0 0h-5.25M21 3v5.25"}))});t.Z=i},11776:function(e,t,r){"use strict";var n=r(67294);let i=n.forwardRef(function(e,t){let{title:r,titleId:i,...s}=e;return n.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},s),r?n.createElement("title",{id:i},r):null,n.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m4.5 19.5 15-15m0 0H8.25m11.25 0v11.25"}))});t.Z=i},27880:function(e,t,r){"use strict";var n=r(67294);let i=n.forwardRef(function(e,t){let{title:r,titleId:i,...s}=e;return n.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:t,"aria-labelledby":i},s),r?n.createElement("title",{id:i},r):null,n.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M15.666 3.888A2.25 2.25 0 0 0 13.5 2.25h-3c-1.03 0-1.9.693-2.166 1.638m7.332 0c.055.194.084.4.084.612v0a.75.75 0 0 1-.75.75H9a.75.75 0 0 1-.75-.75v0c0-.212.03-.418.084-.612m7.332 0c.646.049 1.288.11 1.927.184 1.1.128 1.907 1.077 1.907 2.185V19.5a2.25 2.25 0 0 1-2.25 2.25H6.75A2.25 2.25 0 0 1 4.5 19.5V6.257c0-1.108.806-2.057 1.907-2.185a48.208 48.208 0 0 1 1.927-.184"}))});t.Z=i},94767:function(e,t,r){"use strict";let n;r.d(t,{xZ:function(){return tl}}),(e6=tt||(tt={})).assertEqual=e=>e,e6.assertIs=function(e){},e6.assertNever=function(e){throw Error()},e6.arrayToEnum=e=>{let t={};for(let r of e)t[r]=r;return t},e6.getValidEnumValues=e=>{let t=e6.objectKeys(e).filter(t=>"number"!=typeof e[e[t]]),r={};for(let n of t)r[n]=e[n];return e6.objectValues(r)},e6.objectValues=e=>e6.objectKeys(e).map(function(t){return e[t]}),e6.objectKeys="function"==typeof Object.keys?e=>Object.keys(e):e=>{let t=[];for(let r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t},e6.find=(e,t)=>{for(let r of e)if(t(r))return r},e6.isInteger="function"==typeof Number.isInteger?e=>Number.isInteger(e):e=>"number"==typeof e&&isFinite(e)&&Math.floor(e)===e,e6.joinValues=function(e,t=" | "){return e.map(e=>"string"==typeof e?`'${e}'`:e).join(t)},e6.jsonStringifyReplacer=(e,t)=>"bigint"==typeof t?t.toString():t,(tr||(tr={})).mergeShapes=(e,t)=>({...e,...t});let i=tt.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),s=e=>{switch(typeof e){case"undefined":return i.undefined;case"string":return i.string;case"number":return isNaN(e)?i.nan:i.number;case"boolean":return i.boolean;case"function":return i.function;case"bigint":return i.bigint;case"symbol":return i.symbol;case"object":if(Array.isArray(e))return i.array;if(null===e)return i.null;if(e.then&&"function"==typeof e.then&&e.catch&&"function"==typeof e.catch)return i.promise;if("undefined"!=typeof Map&&e instanceof Map)return i.map;if("undefined"!=typeof Set&&e instanceof Set)return i.set;if("undefined"!=typeof Date&&e instanceof Date)return i.date;return i.object;default:return i.unknown}},o=tt.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class a extends Error{constructor(e){super(),this.issues=[],this.addIssue=e=>{this.issues=[...this.issues,e]},this.addIssues=(e=[])=>{this.issues=[...this.issues,...e]};let t=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,t):this.__proto__=t,this.name="ZodError",this.issues=e}get errors(){return this.issues}format(e){let t=e||function(e){return e.message},r={_errors:[]},n=e=>{for(let i of e.issues)if("invalid_union"===i.code)i.unionErrors.map(n);else if("invalid_return_type"===i.code)n(i.returnTypeError);else if("invalid_arguments"===i.code)n(i.argumentsError);else if(0===i.path.length)r._errors.push(t(i));else{let e=r,n=0;for(;n<i.path.length;){let r=i.path[n];n===i.path.length-1?(e[r]=e[r]||{_errors:[]},e[r]._errors.push(t(i))):e[r]=e[r]||{_errors:[]},e=e[r],n++}}};return n(this),r}static assert(e){if(!(e instanceof a))throw Error(`Not a ZodError: ${e}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,tt.jsonStringifyReplacer,2)}get isEmpty(){return 0===this.issues.length}flatten(e=e=>e.message){let t={},r=[];for(let n of this.issues)n.path.length>0?(t[n.path[0]]=t[n.path[0]]||[],t[n.path[0]].push(e(n))):r.push(e(n));return{formErrors:r,fieldErrors:t}}get formErrors(){return this.flatten()}}a.create=e=>new a(e);let u=(e,t)=>{let r;switch(e.code){case o.invalid_type:r=e.received===i.undefined?"Required":`Expected ${e.expected}, received ${e.received}`;break;case o.invalid_literal:r=`Invalid literal value, expected ${JSON.stringify(e.expected,tt.jsonStringifyReplacer)}`;break;case o.unrecognized_keys:r=`Unrecognized key(s) in object: ${tt.joinValues(e.keys,", ")}`;break;case o.invalid_union:r="Invalid input";break;case o.invalid_union_discriminator:r=`Invalid discriminator value. Expected ${tt.joinValues(e.options)}`;break;case o.invalid_enum_value:r=`Invalid enum value. Expected ${tt.joinValues(e.options)}, received '${e.received}'`;break;case o.invalid_arguments:r="Invalid function arguments";break;case o.invalid_return_type:r="Invalid function return type";break;case o.invalid_date:r="Invalid date";break;case o.invalid_string:"object"==typeof e.validation?"includes"in e.validation?(r=`Invalid input: must include "${e.validation.includes}"`,"number"==typeof e.validation.position&&(r=`${r} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?r=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?r=`Invalid input: must end with "${e.validation.endsWith}"`:tt.assertNever(e.validation):r="regex"!==e.validation?`Invalid ${e.validation}`:"Invalid";break;case o.too_small:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:"date"===e.type?`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:"Invalid input";break;case o.too_big:r="array"===e.type?`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:"string"===e.type?`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:"number"===e.type?`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"bigint"===e.type?`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:"date"===e.type?`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:"Invalid input";break;case o.custom:r="Invalid input";break;case o.invalid_intersection_types:r="Intersection results could not be merged";break;case o.not_multiple_of:r=`Number must be a multiple of ${e.multipleOf}`;break;case o.not_finite:r="Number must be finite";break;default:r=t.defaultError,tt.assertNever(e)}return{message:r}},l=u;function c(){return l}let d=e=>{let{data:t,path:r,errorMaps:n,issueData:i}=e,s=[...r,...i.path||[]],o={...i,path:s};if(void 0!==i.message)return{...i,path:s,message:i.message};let a="";for(let e of n.filter(e=>!!e).slice().reverse())a=e(o,{data:t,defaultError:a}).message;return{...i,path:s,message:a}};function f(e,t){let r=c(),n=d({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,r,r===u?void 0:u].filter(e=>!!e)});e.common.issues.push(n)}class h{constructor(){this.value="valid"}dirty(){"valid"===this.value&&(this.value="dirty")}abort(){"aborted"!==this.value&&(this.value="aborted")}static mergeArray(e,t){let r=[];for(let n of t){if("aborted"===n.status)return p;"dirty"===n.status&&e.dirty(),r.push(n.value)}return{status:e.value,value:r}}static async mergeObjectAsync(e,t){let r=[];for(let e of t){let t=await e.key,n=await e.value;r.push({key:t,value:n})}return h.mergeObjectSync(e,r)}static mergeObjectSync(e,t){let r={};for(let n of t){let{key:t,value:i}=n;if("aborted"===t.status||"aborted"===i.status)return p;"dirty"===t.status&&e.dirty(),"dirty"===i.status&&e.dirty(),"__proto__"!==t.value&&(void 0!==i.value||n.alwaysSet)&&(r[t.value]=i.value)}return{status:e.value,value:r}}}let p=Object.freeze({status:"aborted"}),m=e=>({status:"dirty",value:e}),g=e=>({status:"valid",value:e}),y=e=>"aborted"===e.status,v=e=>"dirty"===e.status,_=e=>"valid"===e.status,b=e=>"undefined"!=typeof Promise&&e instanceof Promise;function S(e,t,r,n){if("a"===r&&!n)throw TypeError("Private accessor was defined without a getter");if("function"==typeof t?e!==t||!n:!t.has(e))throw TypeError("Cannot read private member from an object whose class did not declare it");return"m"===r?n:"a"===r?n.call(e):n?n.value:t.get(e)}function E(e,t,r,n,i){if("m"===n)throw TypeError("Private method is not writable");if("a"===n&&!i)throw TypeError("Private accessor was defined without a setter");if("function"==typeof t?e!==t||!i:!t.has(e))throw TypeError("Cannot write private member to an object whose class did not declare it");return"a"===n?i.call(e,r):i?i.value=r:t.set(e,r),r}"function"==typeof SuppressedError&&SuppressedError,(e7=tn||(tn={})).errToObj=e=>"string"==typeof e?{message:e}:e||{},e7.toString=e=>"string"==typeof e?e:null==e?void 0:e.message;class w{constructor(e,t,r,n){this._cachedPath=[],this.parent=e,this.data=t,this._path=r,this._key=n}get path(){return this._cachedPath.length||(this._key instanceof Array?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}let O=(e,t)=>{if(_(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;let t=new a(e.common.issues);return this._error=t,this._error}}};function k(e){if(!e)return{};let{errorMap:t,invalid_type_error:r,required_error:n,description:i}=e;if(t&&(r||n))throw Error('Can\'t use "invalid_type_error" or "required_error" in conjunction with custom error map.');return t?{errorMap:t,description:i}:{errorMap:(t,i)=>{var s,o;let{message:a}=e;return"invalid_enum_value"===t.code?{message:null!=a?a:i.defaultError}:void 0===i.data?{message:null!==(s=null!=a?a:n)&&void 0!==s?s:i.defaultError}:"invalid_type"!==t.code?{message:i.defaultError}:{message:null!==(o=null!=a?a:r)&&void 0!==o?o:i.defaultError}},description:i}}class T{constructor(e){this.spa=this.safeParseAsync,this._def=e,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this)}get description(){return this._def.description}_getType(e){return s(e.data)}_getOrReturnCtx(e,t){return t||{common:e.parent.common,data:e.data,parsedType:s(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}_processInputParams(e){return{status:new h,ctx:{common:e.parent.common,data:e.data,parsedType:s(e.data),schemaErrorMap:this._def.errorMap,path:e.path,parent:e.parent}}}_parseSync(e){let t=this._parse(e);if(b(t))throw Error("Synchronous parse encountered promise.");return t}_parseAsync(e){return Promise.resolve(this._parse(e))}parse(e,t){let r=this.safeParse(e,t);if(r.success)return r.data;throw r.error}safeParse(e,t){var r;let n={common:{issues:[],async:null!==(r=null==t?void 0:t.async)&&void 0!==r&&r,contextualErrorMap:null==t?void 0:t.errorMap},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:s(e)},i=this._parseSync({data:e,path:n.path,parent:n});return O(n,i)}async parseAsync(e,t){let r=await this.safeParseAsync(e,t);if(r.success)return r.data;throw r.error}async safeParseAsync(e,t){let r={common:{issues:[],contextualErrorMap:null==t?void 0:t.errorMap,async:!0},path:(null==t?void 0:t.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:e,parsedType:s(e)},n=this._parse({data:e,path:r.path,parent:r});return O(r,await (b(n)?n:Promise.resolve(n)))}refine(e,t){let r=e=>"string"==typeof t||void 0===t?{message:t}:"function"==typeof t?t(e):t;return this._refinement((t,n)=>{let i=e(t),s=()=>n.addIssue({code:o.custom,...r(t)});return"undefined"!=typeof Promise&&i instanceof Promise?i.then(e=>!!e||(s(),!1)):!!i||(s(),!1)})}refinement(e,t){return this._refinement((r,n)=>!!e(r)||(n.addIssue("function"==typeof t?t(r,n):t),!1))}_refinement(e){return new eg({schema:this,typeName:to.ZodEffects,effect:{type:"refinement",refinement:e}})}superRefine(e){return this._refinement(e)}optional(){return ey.create(this,this._def)}nullable(){return ev.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Y.create(this,this._def)}promise(){return em.create(this,this._def)}or(e){return et.create([this,e],this._def)}and(e){return ei.create(this,e,this._def)}transform(e){return new eg({...k(this._def),schema:this,typeName:to.ZodEffects,effect:{type:"transform",transform:e}})}default(e){return new e_({...k(this._def),innerType:this,defaultValue:"function"==typeof e?e:()=>e,typeName:to.ZodDefault})}brand(){return new ew({typeName:to.ZodBranded,type:this,...k(this._def)})}catch(e){return new eb({...k(this._def),innerType:this,catchValue:"function"==typeof e?e:()=>e,typeName:to.ZodCatch})}describe(e){return new this.constructor({...this._def,description:e})}pipe(e){return eO.create(this,e)}readonly(){return ek.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}let C=/^c[^\s-]{8,}$/i,I=/^[0-9a-z]+$/,R=/^[0-9A-HJKMNP-TV-Z]{26}$/,x=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,A=/^[a-z0-9_-]{21}$/i,P=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,M=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,N=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,D=/^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/,L=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,j="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",U=RegExp(`^${j}$`);function B(e){let t="([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d";return e.precision?t=`${t}\\.\\d{${e.precision}}`:null==e.precision&&(t=`${t}(\\.\\d+)?`),t}function F(e){let t=`${j}T${B(e)}`,r=[];return r.push(e.local?"Z?":"Z"),e.offset&&r.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${r.join("|")})`,RegExp(`^${t}$`)}class $ extends T{_parse(e){var t,r;let s;if(this._def.coerce&&(e.data=String(e.data)),this._getType(e)!==i.string){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.string,received:t.parsedType}),p}let a=new h;for(let i of this._def.checks)if("min"===i.kind)e.data.length<i.value&&(f(s=this._getOrReturnCtx(e,s),{code:o.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),a.dirty());else if("max"===i.kind)e.data.length>i.value&&(f(s=this._getOrReturnCtx(e,s),{code:o.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),a.dirty());else if("length"===i.kind){let t=e.data.length>i.value,r=e.data.length<i.value;(t||r)&&(s=this._getOrReturnCtx(e,s),t?f(s,{code:o.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):r&&f(s,{code:o.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),a.dirty())}else if("email"===i.kind)M.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"email",code:o.invalid_string,message:i.message}),a.dirty());else if("emoji"===i.kind)n||(n=RegExp("^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$","u")),n.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"emoji",code:o.invalid_string,message:i.message}),a.dirty());else if("uuid"===i.kind)x.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"uuid",code:o.invalid_string,message:i.message}),a.dirty());else if("nanoid"===i.kind)A.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"nanoid",code:o.invalid_string,message:i.message}),a.dirty());else if("cuid"===i.kind)C.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"cuid",code:o.invalid_string,message:i.message}),a.dirty());else if("cuid2"===i.kind)I.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"cuid2",code:o.invalid_string,message:i.message}),a.dirty());else if("ulid"===i.kind)R.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"ulid",code:o.invalid_string,message:i.message}),a.dirty());else if("url"===i.kind)try{new URL(e.data)}catch(t){f(s=this._getOrReturnCtx(e,s),{validation:"url",code:o.invalid_string,message:i.message}),a.dirty()}else"regex"===i.kind?(i.regex.lastIndex=0,i.regex.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"regex",code:o.invalid_string,message:i.message}),a.dirty())):"trim"===i.kind?e.data=e.data.trim():"includes"===i.kind?e.data.includes(i.value,i.position)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),a.dirty()):"toLowerCase"===i.kind?e.data=e.data.toLowerCase():"toUpperCase"===i.kind?e.data=e.data.toUpperCase():"startsWith"===i.kind?e.data.startsWith(i.value)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:{startsWith:i.value},message:i.message}),a.dirty()):"endsWith"===i.kind?e.data.endsWith(i.value)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:{endsWith:i.value},message:i.message}),a.dirty()):"datetime"===i.kind?F(i).test(e.data)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:"datetime",message:i.message}),a.dirty()):"date"===i.kind?U.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:"date",message:i.message}),a.dirty()):"time"===i.kind?RegExp(`^${B(i)}$`).test(e.data)||(f(s=this._getOrReturnCtx(e,s),{code:o.invalid_string,validation:"time",message:i.message}),a.dirty()):"duration"===i.kind?P.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"duration",code:o.invalid_string,message:i.message}),a.dirty()):"ip"===i.kind?(t=e.data,("v4"===(r=i.version)||!r)&&N.test(t)||("v6"===r||!r)&&D.test(t)||(f(s=this._getOrReturnCtx(e,s),{validation:"ip",code:o.invalid_string,message:i.message}),a.dirty())):"base64"===i.kind?L.test(e.data)||(f(s=this._getOrReturnCtx(e,s),{validation:"base64",code:o.invalid_string,message:i.message}),a.dirty()):tt.assertNever(i);return{status:a.value,value:e.data}}_regex(e,t,r){return this.refinement(t=>e.test(t),{validation:t,code:o.invalid_string,...tn.errToObj(r)})}_addCheck(e){return new $({...this._def,checks:[...this._def.checks,e]})}email(e){return this._addCheck({kind:"email",...tn.errToObj(e)})}url(e){return this._addCheck({kind:"url",...tn.errToObj(e)})}emoji(e){return this._addCheck({kind:"emoji",...tn.errToObj(e)})}uuid(e){return this._addCheck({kind:"uuid",...tn.errToObj(e)})}nanoid(e){return this._addCheck({kind:"nanoid",...tn.errToObj(e)})}cuid(e){return this._addCheck({kind:"cuid",...tn.errToObj(e)})}cuid2(e){return this._addCheck({kind:"cuid2",...tn.errToObj(e)})}ulid(e){return this._addCheck({kind:"ulid",...tn.errToObj(e)})}base64(e){return this._addCheck({kind:"base64",...tn.errToObj(e)})}ip(e){return this._addCheck({kind:"ip",...tn.errToObj(e)})}datetime(e){var t,r;return"string"==typeof e?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:e}):this._addCheck({kind:"datetime",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,offset:null!==(t=null==e?void 0:e.offset)&&void 0!==t&&t,local:null!==(r=null==e?void 0:e.local)&&void 0!==r&&r,...tn.errToObj(null==e?void 0:e.message)})}date(e){return this._addCheck({kind:"date",message:e})}time(e){return"string"==typeof e?this._addCheck({kind:"time",precision:null,message:e}):this._addCheck({kind:"time",precision:void 0===(null==e?void 0:e.precision)?null:null==e?void 0:e.precision,...tn.errToObj(null==e?void 0:e.message)})}duration(e){return this._addCheck({kind:"duration",...tn.errToObj(e)})}regex(e,t){return this._addCheck({kind:"regex",regex:e,...tn.errToObj(t)})}includes(e,t){return this._addCheck({kind:"includes",value:e,position:null==t?void 0:t.position,...tn.errToObj(null==t?void 0:t.message)})}startsWith(e,t){return this._addCheck({kind:"startsWith",value:e,...tn.errToObj(t)})}endsWith(e,t){return this._addCheck({kind:"endsWith",value:e,...tn.errToObj(t)})}min(e,t){return this._addCheck({kind:"min",value:e,...tn.errToObj(t)})}max(e,t){return this._addCheck({kind:"max",value:e,...tn.errToObj(t)})}length(e,t){return this._addCheck({kind:"length",value:e,...tn.errToObj(t)})}nonempty(e){return this.min(1,tn.errToObj(e))}trim(){return new $({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new $({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new $({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(e=>"datetime"===e.kind)}get isDate(){return!!this._def.checks.find(e=>"date"===e.kind)}get isTime(){return!!this._def.checks.find(e=>"time"===e.kind)}get isDuration(){return!!this._def.checks.find(e=>"duration"===e.kind)}get isEmail(){return!!this._def.checks.find(e=>"email"===e.kind)}get isURL(){return!!this._def.checks.find(e=>"url"===e.kind)}get isEmoji(){return!!this._def.checks.find(e=>"emoji"===e.kind)}get isUUID(){return!!this._def.checks.find(e=>"uuid"===e.kind)}get isNANOID(){return!!this._def.checks.find(e=>"nanoid"===e.kind)}get isCUID(){return!!this._def.checks.find(e=>"cuid"===e.kind)}get isCUID2(){return!!this._def.checks.find(e=>"cuid2"===e.kind)}get isULID(){return!!this._def.checks.find(e=>"ulid"===e.kind)}get isIP(){return!!this._def.checks.find(e=>"ip"===e.kind)}get isBase64(){return!!this._def.checks.find(e=>"base64"===e.kind)}get minLength(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxLength(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}$.create=e=>{var t;return new $({checks:[],typeName:to.ZodString,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...k(e)})};class z extends T{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(e){let t;if(this._def.coerce&&(e.data=Number(e.data)),this._getType(e)!==i.number){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.number,received:t.parsedType}),p}let r=new h;for(let n of this._def.checks)"int"===n.kind?tt.isInteger(e.data)||(f(t=this._getOrReturnCtx(e,t),{code:o.invalid_type,expected:"integer",received:"float",message:n.message}),r.dirty()):"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_small,minimum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),r.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_big,maximum:n.value,type:"number",inclusive:n.inclusive,exact:!1,message:n.message}),r.dirty()):"multipleOf"===n.kind?0!==function(e,t){let r=(e.toString().split(".")[1]||"").length,n=(t.toString().split(".")[1]||"").length,i=r>n?r:n;return parseInt(e.toFixed(i).replace(".",""))%parseInt(t.toFixed(i).replace(".",""))/Math.pow(10,i)}(e.data,n.value)&&(f(t=this._getOrReturnCtx(e,t),{code:o.not_multiple_of,multipleOf:n.value,message:n.message}),r.dirty()):"finite"===n.kind?Number.isFinite(e.data)||(f(t=this._getOrReturnCtx(e,t),{code:o.not_finite,message:n.message}),r.dirty()):tt.assertNever(n);return{status:r.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,tn.toString(t))}gt(e,t){return this.setLimit("min",e,!1,tn.toString(t))}lte(e,t){return this.setLimit("max",e,!0,tn.toString(t))}lt(e,t){return this.setLimit("max",e,!1,tn.toString(t))}setLimit(e,t,r,n){return new z({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:tn.toString(n)}]})}_addCheck(e){return new z({...this._def,checks:[...this._def.checks,e]})}int(e){return this._addCheck({kind:"int",message:tn.toString(e)})}positive(e){return this._addCheck({kind:"min",value:0,inclusive:!1,message:tn.toString(e)})}negative(e){return this._addCheck({kind:"max",value:0,inclusive:!1,message:tn.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:0,inclusive:!0,message:tn.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:0,inclusive:!0,message:tn.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:tn.toString(t)})}finite(e){return this._addCheck({kind:"finite",message:tn.toString(e)})}safe(e){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:tn.toString(e)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:tn.toString(e)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}get isInt(){return!!this._def.checks.find(e=>"int"===e.kind||"multipleOf"===e.kind&&tt.isInteger(e.value))}get isFinite(){let e=null,t=null;for(let r of this._def.checks){if("finite"===r.kind||"int"===r.kind||"multipleOf"===r.kind)return!0;"min"===r.kind?(null===t||r.value>t)&&(t=r.value):"max"===r.kind&&(null===e||r.value<e)&&(e=r.value)}return Number.isFinite(t)&&Number.isFinite(e)}}z.create=e=>new z({checks:[],typeName:to.ZodNumber,coerce:(null==e?void 0:e.coerce)||!1,...k(e)});class H extends T{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(e){let t;if(this._def.coerce&&(e.data=BigInt(e.data)),this._getType(e)!==i.bigint){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.bigint,received:t.parsedType}),p}let r=new h;for(let n of this._def.checks)"min"===n.kind?(n.inclusive?e.data<n.value:e.data<=n.value)&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_small,type:"bigint",minimum:n.value,inclusive:n.inclusive,message:n.message}),r.dirty()):"max"===n.kind?(n.inclusive?e.data>n.value:e.data>=n.value)&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_big,type:"bigint",maximum:n.value,inclusive:n.inclusive,message:n.message}),r.dirty()):"multipleOf"===n.kind?e.data%n.value!==BigInt(0)&&(f(t=this._getOrReturnCtx(e,t),{code:o.not_multiple_of,multipleOf:n.value,message:n.message}),r.dirty()):tt.assertNever(n);return{status:r.value,value:e.data}}gte(e,t){return this.setLimit("min",e,!0,tn.toString(t))}gt(e,t){return this.setLimit("min",e,!1,tn.toString(t))}lte(e,t){return this.setLimit("max",e,!0,tn.toString(t))}lt(e,t){return this.setLimit("max",e,!1,tn.toString(t))}setLimit(e,t,r,n){return new H({...this._def,checks:[...this._def.checks,{kind:e,value:t,inclusive:r,message:tn.toString(n)}]})}_addCheck(e){return new H({...this._def,checks:[...this._def.checks,e]})}positive(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:tn.toString(e)})}negative(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:tn.toString(e)})}nonpositive(e){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:tn.toString(e)})}nonnegative(e){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:tn.toString(e)})}multipleOf(e,t){return this._addCheck({kind:"multipleOf",value:e,message:tn.toString(t)})}get minValue(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return e}get maxValue(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return e}}H.create=e=>{var t;return new H({checks:[],typeName:to.ZodBigInt,coerce:null!==(t=null==e?void 0:e.coerce)&&void 0!==t&&t,...k(e)})};class G extends T{_parse(e){if(this._def.coerce&&(e.data=!!e.data),this._getType(e)!==i.boolean){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.boolean,received:t.parsedType}),p}return g(e.data)}}G.create=e=>new G({typeName:to.ZodBoolean,coerce:(null==e?void 0:e.coerce)||!1,...k(e)});class q extends T{_parse(e){let t;if(this._def.coerce&&(e.data=new Date(e.data)),this._getType(e)!==i.date){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.date,received:t.parsedType}),p}if(isNaN(e.data.getTime()))return f(this._getOrReturnCtx(e),{code:o.invalid_date}),p;let r=new h;for(let n of this._def.checks)"min"===n.kind?e.data.getTime()<n.value&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_small,message:n.message,inclusive:!0,exact:!1,minimum:n.value,type:"date"}),r.dirty()):"max"===n.kind?e.data.getTime()>n.value&&(f(t=this._getOrReturnCtx(e,t),{code:o.too_big,message:n.message,inclusive:!0,exact:!1,maximum:n.value,type:"date"}),r.dirty()):tt.assertNever(n);return{status:r.value,value:new Date(e.data.getTime())}}_addCheck(e){return new q({...this._def,checks:[...this._def.checks,e]})}min(e,t){return this._addCheck({kind:"min",value:e.getTime(),message:tn.toString(t)})}max(e,t){return this._addCheck({kind:"max",value:e.getTime(),message:tn.toString(t)})}get minDate(){let e=null;for(let t of this._def.checks)"min"===t.kind&&(null===e||t.value>e)&&(e=t.value);return null!=e?new Date(e):null}get maxDate(){let e=null;for(let t of this._def.checks)"max"===t.kind&&(null===e||t.value<e)&&(e=t.value);return null!=e?new Date(e):null}}q.create=e=>new q({checks:[],coerce:(null==e?void 0:e.coerce)||!1,typeName:to.ZodDate,...k(e)});class Z extends T{_parse(e){if(this._getType(e)!==i.symbol){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.symbol,received:t.parsedType}),p}return g(e.data)}}Z.create=e=>new Z({typeName:to.ZodSymbol,...k(e)});class W extends T{_parse(e){if(this._getType(e)!==i.undefined){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.undefined,received:t.parsedType}),p}return g(e.data)}}W.create=e=>new W({typeName:to.ZodUndefined,...k(e)});class K extends T{_parse(e){if(this._getType(e)!==i.null){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.null,received:t.parsedType}),p}return g(e.data)}}K.create=e=>new K({typeName:to.ZodNull,...k(e)});class V extends T{constructor(){super(...arguments),this._any=!0}_parse(e){return g(e.data)}}V.create=e=>new V({typeName:to.ZodAny,...k(e)});class Q extends T{constructor(){super(...arguments),this._unknown=!0}_parse(e){return g(e.data)}}Q.create=e=>new Q({typeName:to.ZodUnknown,...k(e)});class X extends T{_parse(e){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.never,received:t.parsedType}),p}}X.create=e=>new X({typeName:to.ZodNever,...k(e)});class J extends T{_parse(e){if(this._getType(e)!==i.undefined){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.void,received:t.parsedType}),p}return g(e.data)}}J.create=e=>new J({typeName:to.ZodVoid,...k(e)});class Y extends T{_parse(e){let{ctx:t,status:r}=this._processInputParams(e),n=this._def;if(t.parsedType!==i.array)return f(t,{code:o.invalid_type,expected:i.array,received:t.parsedType}),p;if(null!==n.exactLength){let e=t.data.length>n.exactLength.value,i=t.data.length<n.exactLength.value;(e||i)&&(f(t,{code:e?o.too_big:o.too_small,minimum:i?n.exactLength.value:void 0,maximum:e?n.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:n.exactLength.message}),r.dirty())}if(null!==n.minLength&&t.data.length<n.minLength.value&&(f(t,{code:o.too_small,minimum:n.minLength.value,type:"array",inclusive:!0,exact:!1,message:n.minLength.message}),r.dirty()),null!==n.maxLength&&t.data.length>n.maxLength.value&&(f(t,{code:o.too_big,maximum:n.maxLength.value,type:"array",inclusive:!0,exact:!1,message:n.maxLength.message}),r.dirty()),t.common.async)return Promise.all([...t.data].map((e,r)=>n.type._parseAsync(new w(t,e,t.path,r)))).then(e=>h.mergeArray(r,e));let s=[...t.data].map((e,r)=>n.type._parseSync(new w(t,e,t.path,r)));return h.mergeArray(r,s)}get element(){return this._def.type}min(e,t){return new Y({...this._def,minLength:{value:e,message:tn.toString(t)}})}max(e,t){return new Y({...this._def,maxLength:{value:e,message:tn.toString(t)}})}length(e,t){return new Y({...this._def,exactLength:{value:e,message:tn.toString(t)}})}nonempty(e){return this.min(1,e)}}Y.create=(e,t)=>new Y({type:e,minLength:null,maxLength:null,exactLength:null,typeName:to.ZodArray,...k(t)});class ee extends T{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(null!==this._cached)return this._cached;let e=this._def.shape(),t=tt.objectKeys(e);return this._cached={shape:e,keys:t}}_parse(e){if(this._getType(e)!==i.object){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.object,received:t.parsedType}),p}let{status:t,ctx:r}=this._processInputParams(e),{shape:n,keys:s}=this._getCached(),a=[];if(!(this._def.catchall instanceof X&&"strip"===this._def.unknownKeys))for(let e in r.data)s.includes(e)||a.push(e);let u=[];for(let e of s){let t=n[e],i=r.data[e];u.push({key:{status:"valid",value:e},value:t._parse(new w(r,i,r.path,e)),alwaysSet:e in r.data})}if(this._def.catchall instanceof X){let e=this._def.unknownKeys;if("passthrough"===e)for(let e of a)u.push({key:{status:"valid",value:e},value:{status:"valid",value:r.data[e]}});else if("strict"===e)a.length>0&&(f(r,{code:o.unrecognized_keys,keys:a}),t.dirty());else if("strip"===e);else throw Error("Internal ZodObject error: invalid unknownKeys value.")}else{let e=this._def.catchall;for(let t of a){let n=r.data[t];u.push({key:{status:"valid",value:t},value:e._parse(new w(r,n,r.path,t)),alwaysSet:t in r.data})}}return r.common.async?Promise.resolve().then(async()=>{let e=[];for(let t of u){let r=await t.key,n=await t.value;e.push({key:r,value:n,alwaysSet:t.alwaysSet})}return e}).then(e=>h.mergeObjectSync(t,e)):h.mergeObjectSync(t,u)}get shape(){return this._def.shape()}strict(e){return tn.errToObj,new ee({...this._def,unknownKeys:"strict",...void 0!==e?{errorMap:(t,r)=>{var n,i,s,o;let a=null!==(s=null===(i=(n=this._def).errorMap)||void 0===i?void 0:i.call(n,t,r).message)&&void 0!==s?s:r.defaultError;return"unrecognized_keys"===t.code?{message:null!==(o=tn.errToObj(e).message)&&void 0!==o?o:a}:{message:a}}}:{}})}strip(){return new ee({...this._def,unknownKeys:"strip"})}passthrough(){return new ee({...this._def,unknownKeys:"passthrough"})}extend(e){return new ee({...this._def,shape:()=>({...this._def.shape(),...e})})}merge(e){return new ee({unknownKeys:e._def.unknownKeys,catchall:e._def.catchall,shape:()=>({...this._def.shape(),...e._def.shape()}),typeName:to.ZodObject})}setKey(e,t){return this.augment({[e]:t})}catchall(e){return new ee({...this._def,catchall:e})}pick(e){let t={};return tt.objectKeys(e).forEach(r=>{e[r]&&this.shape[r]&&(t[r]=this.shape[r])}),new ee({...this._def,shape:()=>t})}omit(e){let t={};return tt.objectKeys(this.shape).forEach(r=>{e[r]||(t[r]=this.shape[r])}),new ee({...this._def,shape:()=>t})}deepPartial(){return function e(t){if(t instanceof ee){let r={};for(let n in t.shape){let i=t.shape[n];r[n]=ey.create(e(i))}return new ee({...t._def,shape:()=>r})}return t instanceof Y?new Y({...t._def,type:e(t.element)}):t instanceof ey?ey.create(e(t.unwrap())):t instanceof ev?ev.create(e(t.unwrap())):t instanceof es?es.create(t.items.map(t=>e(t))):t}(this)}partial(e){let t={};return tt.objectKeys(this.shape).forEach(r=>{let n=this.shape[r];e&&!e[r]?t[r]=n:t[r]=n.optional()}),new ee({...this._def,shape:()=>t})}required(e){let t={};return tt.objectKeys(this.shape).forEach(r=>{if(e&&!e[r])t[r]=this.shape[r];else{let e=this.shape[r];for(;e instanceof ey;)e=e._def.innerType;t[r]=e}}),new ee({...this._def,shape:()=>t})}keyof(){return ef(tt.objectKeys(this.shape))}}ee.create=(e,t)=>new ee({shape:()=>e,unknownKeys:"strip",catchall:X.create(),typeName:to.ZodObject,...k(t)}),ee.strictCreate=(e,t)=>new ee({shape:()=>e,unknownKeys:"strict",catchall:X.create(),typeName:to.ZodObject,...k(t)}),ee.lazycreate=(e,t)=>new ee({shape:e,unknownKeys:"strip",catchall:X.create(),typeName:to.ZodObject,...k(t)});class et extends T{_parse(e){let{ctx:t}=this._processInputParams(e),r=this._def.options;if(t.common.async)return Promise.all(r.map(async e=>{let r={...t,common:{...t.common,issues:[]},parent:null};return{result:await e._parseAsync({data:t.data,path:t.path,parent:r}),ctx:r}})).then(function(e){for(let t of e)if("valid"===t.result.status)return t.result;for(let r of e)if("dirty"===r.result.status)return t.common.issues.push(...r.ctx.common.issues),r.result;let r=e.map(e=>new a(e.ctx.common.issues));return f(t,{code:o.invalid_union,unionErrors:r}),p});{let e;let n=[];for(let i of r){let r={...t,common:{...t.common,issues:[]},parent:null},s=i._parseSync({data:t.data,path:t.path,parent:r});if("valid"===s.status)return s;"dirty"!==s.status||e||(e={result:s,ctx:r}),r.common.issues.length&&n.push(r.common.issues)}if(e)return t.common.issues.push(...e.ctx.common.issues),e.result;let i=n.map(e=>new a(e));return f(t,{code:o.invalid_union,unionErrors:i}),p}}get options(){return this._def.options}}et.create=(e,t)=>new et({options:e,typeName:to.ZodUnion,...k(t)});let er=e=>{if(e instanceof ec)return er(e.schema);if(e instanceof eg)return er(e.innerType());if(e instanceof ed)return[e.value];if(e instanceof eh)return e.options;if(e instanceof ep)return tt.objectValues(e.enum);if(e instanceof e_)return er(e._def.innerType);if(e instanceof W)return[void 0];else if(e instanceof K)return[null];else if(e instanceof ey)return[void 0,...er(e.unwrap())];else if(e instanceof ev)return[null,...er(e.unwrap())];else if(e instanceof ew)return er(e.unwrap());else if(e instanceof ek)return er(e.unwrap());else if(e instanceof eb)return er(e._def.innerType);else return[]};class en extends T{_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==i.object)return f(t,{code:o.invalid_type,expected:i.object,received:t.parsedType}),p;let r=this.discriminator,n=t.data[r],s=this.optionsMap.get(n);return s?t.common.async?s._parseAsync({data:t.data,path:t.path,parent:t}):s._parseSync({data:t.data,path:t.path,parent:t}):(f(t,{code:o.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),p)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(e,t,r){let n=new Map;for(let r of t){let t=er(r.shape[e]);if(!t.length)throw Error(`A discriminator value for key \`${e}\` could not be extracted from all schema options`);for(let i of t){if(n.has(i))throw Error(`Discriminator property ${String(e)} has duplicate value ${String(i)}`);n.set(i,r)}}return new en({typeName:to.ZodDiscriminatedUnion,discriminator:e,options:t,optionsMap:n,...k(r)})}}class ei extends T{_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=(e,n)=>{if(y(e)||y(n))return p;let a=function e(t,r){let n=s(t),o=s(r);if(t===r)return{valid:!0,data:t};if(n===i.object&&o===i.object){let n=tt.objectKeys(r),i=tt.objectKeys(t).filter(e=>-1!==n.indexOf(e)),s={...t,...r};for(let n of i){let i=e(t[n],r[n]);if(!i.valid)return{valid:!1};s[n]=i.data}return{valid:!0,data:s}}if(n===i.array&&o===i.array){if(t.length!==r.length)return{valid:!1};let n=[];for(let i=0;i<t.length;i++){let s=e(t[i],r[i]);if(!s.valid)return{valid:!1};n.push(s.data)}return{valid:!0,data:n}}return n===i.date&&o===i.date&&+t==+r?{valid:!0,data:t}:{valid:!1}}(e.value,n.value);return a.valid?((v(e)||v(n))&&t.dirty(),{status:t.value,value:a.data}):(f(r,{code:o.invalid_intersection_types}),p)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([e,t])=>n(e,t)):n(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}ei.create=(e,t,r)=>new ei({left:e,right:t,typeName:to.ZodIntersection,...k(r)});class es extends T{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==i.array)return f(r,{code:o.invalid_type,expected:i.array,received:r.parsedType}),p;if(r.data.length<this._def.items.length)return f(r,{code:o.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),p;!this._def.rest&&r.data.length>this._def.items.length&&(f(r,{code:o.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),t.dirty());let n=[...r.data].map((e,t)=>{let n=this._def.items[t]||this._def.rest;return n?n._parse(new w(r,e,r.path,t)):null}).filter(e=>!!e);return r.common.async?Promise.all(n).then(e=>h.mergeArray(t,e)):h.mergeArray(t,n)}get items(){return this._def.items}rest(e){return new es({...this._def,rest:e})}}es.create=(e,t)=>{if(!Array.isArray(e))throw Error("You must pass an array of schemas to z.tuple([ ... ])");return new es({items:e,typeName:to.ZodTuple,rest:null,...k(t)})};class eo extends T{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==i.object)return f(r,{code:o.invalid_type,expected:i.object,received:r.parsedType}),p;let n=[],s=this._def.keyType,a=this._def.valueType;for(let e in r.data)n.push({key:s._parse(new w(r,e,r.path,e)),value:a._parse(new w(r,r.data[e],r.path,e)),alwaysSet:e in r.data});return r.common.async?h.mergeObjectAsync(t,n):h.mergeObjectSync(t,n)}get element(){return this._def.valueType}static create(e,t,r){return new eo(t instanceof T?{keyType:e,valueType:t,typeName:to.ZodRecord,...k(r)}:{keyType:$.create(),valueType:e,typeName:to.ZodRecord,...k(t)})}}class ea extends T{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==i.map)return f(r,{code:o.invalid_type,expected:i.map,received:r.parsedType}),p;let n=this._def.keyType,s=this._def.valueType,a=[...r.data.entries()].map(([e,t],i)=>({key:n._parse(new w(r,e,r.path,[i,"key"])),value:s._parse(new w(r,t,r.path,[i,"value"]))}));if(r.common.async){let e=new Map;return Promise.resolve().then(async()=>{for(let r of a){let n=await r.key,i=await r.value;if("aborted"===n.status||"aborted"===i.status)return p;("dirty"===n.status||"dirty"===i.status)&&t.dirty(),e.set(n.value,i.value)}return{status:t.value,value:e}})}{let e=new Map;for(let r of a){let n=r.key,i=r.value;if("aborted"===n.status||"aborted"===i.status)return p;("dirty"===n.status||"dirty"===i.status)&&t.dirty(),e.set(n.value,i.value)}return{status:t.value,value:e}}}}ea.create=(e,t,r)=>new ea({valueType:t,keyType:e,typeName:to.ZodMap,...k(r)});class eu extends T{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.parsedType!==i.set)return f(r,{code:o.invalid_type,expected:i.set,received:r.parsedType}),p;let n=this._def;null!==n.minSize&&r.data.size<n.minSize.value&&(f(r,{code:o.too_small,minimum:n.minSize.value,type:"set",inclusive:!0,exact:!1,message:n.minSize.message}),t.dirty()),null!==n.maxSize&&r.data.size>n.maxSize.value&&(f(r,{code:o.too_big,maximum:n.maxSize.value,type:"set",inclusive:!0,exact:!1,message:n.maxSize.message}),t.dirty());let s=this._def.valueType;function a(e){let r=new Set;for(let n of e){if("aborted"===n.status)return p;"dirty"===n.status&&t.dirty(),r.add(n.value)}return{status:t.value,value:r}}let u=[...r.data.values()].map((e,t)=>s._parse(new w(r,e,r.path,t)));return r.common.async?Promise.all(u).then(e=>a(e)):a(u)}min(e,t){return new eu({...this._def,minSize:{value:e,message:tn.toString(t)}})}max(e,t){return new eu({...this._def,maxSize:{value:e,message:tn.toString(t)}})}size(e,t){return this.min(e,t).max(e,t)}nonempty(e){return this.min(1,e)}}eu.create=(e,t)=>new eu({valueType:e,minSize:null,maxSize:null,typeName:to.ZodSet,...k(t)});class el extends T{constructor(){super(...arguments),this.validate=this.implement}_parse(e){let{ctx:t}=this._processInputParams(e);if(t.parsedType!==i.function)return f(t,{code:o.invalid_type,expected:i.function,received:t.parsedType}),p;function r(e,r){return d({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,c(),u].filter(e=>!!e),issueData:{code:o.invalid_arguments,argumentsError:r}})}function n(e,r){return d({data:e,path:t.path,errorMaps:[t.common.contextualErrorMap,t.schemaErrorMap,c(),u].filter(e=>!!e),issueData:{code:o.invalid_return_type,returnTypeError:r}})}let s={errorMap:t.common.contextualErrorMap},l=t.data;if(this._def.returns instanceof em){let e=this;return g(async function(...t){let i=new a([]),o=await e._def.args.parseAsync(t,s).catch(e=>{throw i.addIssue(r(t,e)),i}),u=await Reflect.apply(l,this,o);return await e._def.returns._def.type.parseAsync(u,s).catch(e=>{throw i.addIssue(n(u,e)),i})})}{let e=this;return g(function(...t){let i=e._def.args.safeParse(t,s);if(!i.success)throw new a([r(t,i.error)]);let o=Reflect.apply(l,this,i.data),u=e._def.returns.safeParse(o,s);if(!u.success)throw new a([n(o,u.error)]);return u.data})}}parameters(){return this._def.args}returnType(){return this._def.returns}args(...e){return new el({...this._def,args:es.create(e).rest(Q.create())})}returns(e){return new el({...this._def,returns:e})}implement(e){return this.parse(e)}strictImplement(e){return this.parse(e)}static create(e,t,r){return new el({args:e||es.create([]).rest(Q.create()),returns:t||Q.create(),typeName:to.ZodFunction,...k(r)})}}class ec extends T{get schema(){return this._def.getter()}_parse(e){let{ctx:t}=this._processInputParams(e);return this._def.getter()._parse({data:t.data,path:t.path,parent:t})}}ec.create=(e,t)=>new ec({getter:e,typeName:to.ZodLazy,...k(t)});class ed extends T{_parse(e){if(e.data!==this._def.value){let t=this._getOrReturnCtx(e);return f(t,{received:t.data,code:o.invalid_literal,expected:this._def.value}),p}return{status:"valid",value:e.data}}get value(){return this._def.value}}function ef(e,t){return new eh({values:e,typeName:to.ZodEnum,...k(t)})}ed.create=(e,t)=>new ed({value:e,typeName:to.ZodLiteral,...k(t)});class eh extends T{constructor(){super(...arguments),ti.set(this,void 0)}_parse(e){if("string"!=typeof e.data){let t=this._getOrReturnCtx(e),r=this._def.values;return f(t,{expected:tt.joinValues(r),received:t.parsedType,code:o.invalid_type}),p}if(S(this,ti,"f")||E(this,ti,new Set(this._def.values),"f"),!S(this,ti,"f").has(e.data)){let t=this._getOrReturnCtx(e),r=this._def.values;return f(t,{received:t.data,code:o.invalid_enum_value,options:r}),p}return g(e.data)}get options(){return this._def.values}get enum(){let e={};for(let t of this._def.values)e[t]=t;return e}get Values(){let e={};for(let t of this._def.values)e[t]=t;return e}get Enum(){let e={};for(let t of this._def.values)e[t]=t;return e}extract(e,t=this._def){return eh.create(e,{...this._def,...t})}exclude(e,t=this._def){return eh.create(this.options.filter(t=>!e.includes(t)),{...this._def,...t})}}ti=new WeakMap,eh.create=ef;class ep extends T{constructor(){super(...arguments),ts.set(this,void 0)}_parse(e){let t=tt.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(e);if(r.parsedType!==i.string&&r.parsedType!==i.number){let e=tt.objectValues(t);return f(r,{expected:tt.joinValues(e),received:r.parsedType,code:o.invalid_type}),p}if(S(this,ts,"f")||E(this,ts,new Set(tt.getValidEnumValues(this._def.values)),"f"),!S(this,ts,"f").has(e.data)){let e=tt.objectValues(t);return f(r,{received:r.data,code:o.invalid_enum_value,options:e}),p}return g(e.data)}get enum(){return this._def.values}}ts=new WeakMap,ep.create=(e,t)=>new ep({values:e,typeName:to.ZodNativeEnum,...k(t)});class em extends T{unwrap(){return this._def.type}_parse(e){let{ctx:t}=this._processInputParams(e);return t.parsedType!==i.promise&&!1===t.common.async?(f(t,{code:o.invalid_type,expected:i.promise,received:t.parsedType}),p):g((t.parsedType===i.promise?t.data:Promise.resolve(t.data)).then(e=>this._def.type.parseAsync(e,{path:t.path,errorMap:t.common.contextualErrorMap})))}}em.create=(e,t)=>new em({type:e,typeName:to.ZodPromise,...k(t)});class eg extends T{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===to.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(e){let{status:t,ctx:r}=this._processInputParams(e),n=this._def.effect||null,i={addIssue:e=>{f(r,e),e.fatal?t.abort():t.dirty()},get path(){return r.path}};if(i.addIssue=i.addIssue.bind(i),"preprocess"===n.type){let e=n.transform(r.data,i);if(r.common.async)return Promise.resolve(e).then(async e=>{if("aborted"===t.value)return p;let n=await this._def.schema._parseAsync({data:e,path:r.path,parent:r});return"aborted"===n.status?p:"dirty"===n.status||"dirty"===t.value?m(n.value):n});{if("aborted"===t.value)return p;let n=this._def.schema._parseSync({data:e,path:r.path,parent:r});return"aborted"===n.status?p:"dirty"===n.status||"dirty"===t.value?m(n.value):n}}if("refinement"===n.type){let e=e=>{let t=n.refinement(e,i);if(r.common.async)return Promise.resolve(t);if(t instanceof Promise)throw Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return e};if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(r=>"aborted"===r.status?p:("dirty"===r.status&&t.dirty(),e(r.value).then(()=>({status:t.value,value:r.value}))));{let n=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===n.status?p:("dirty"===n.status&&t.dirty(),e(n.value),{status:t.value,value:n.value})}}if("transform"===n.type){if(!1!==r.common.async)return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(e=>_(e)?Promise.resolve(n.transform(e.value,i)).then(e=>({status:t.value,value:e})):e);{let e=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!_(e))return e;let s=n.transform(e.value,i);if(s instanceof Promise)throw Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:t.value,value:s}}}tt.assertNever(n)}}eg.create=(e,t,r)=>new eg({schema:e,typeName:to.ZodEffects,effect:t,...k(r)}),eg.createWithPreprocess=(e,t,r)=>new eg({schema:t,effect:{type:"preprocess",transform:e},typeName:to.ZodEffects,...k(r)});class ey extends T{_parse(e){return this._getType(e)===i.undefined?g(void 0):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ey.create=(e,t)=>new ey({innerType:e,typeName:to.ZodOptional,...k(t)});class ev extends T{_parse(e){return this._getType(e)===i.null?g(null):this._def.innerType._parse(e)}unwrap(){return this._def.innerType}}ev.create=(e,t)=>new ev({innerType:e,typeName:to.ZodNullable,...k(t)});class e_ extends T{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return t.parsedType===i.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:t.path,parent:t})}removeDefault(){return this._def.innerType}}e_.create=(e,t)=>new e_({innerType:e,typeName:to.ZodDefault,defaultValue:"function"==typeof t.default?t.default:()=>t.default,...k(t)});class eb extends T{_parse(e){let{ctx:t}=this._processInputParams(e),r={...t,common:{...t.common,issues:[]}},n=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return b(n)?n.then(e=>({status:"valid",value:"valid"===e.status?e.value:this._def.catchValue({get error(){return new a(r.common.issues)},input:r.data})})):{status:"valid",value:"valid"===n.status?n.value:this._def.catchValue({get error(){return new a(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}eb.create=(e,t)=>new eb({innerType:e,typeName:to.ZodCatch,catchValue:"function"==typeof t.catch?t.catch:()=>t.catch,...k(t)});class eS extends T{_parse(e){if(this._getType(e)!==i.nan){let t=this._getOrReturnCtx(e);return f(t,{code:o.invalid_type,expected:i.nan,received:t.parsedType}),p}return{status:"valid",value:e.data}}}eS.create=e=>new eS({typeName:to.ZodNaN,...k(e)});let eE=Symbol("zod_brand");class ew extends T{_parse(e){let{ctx:t}=this._processInputParams(e),r=t.data;return this._def.type._parse({data:r,path:t.path,parent:t})}unwrap(){return this._def.type}}class eO extends T{_parse(e){let{status:t,ctx:r}=this._processInputParams(e);if(r.common.async)return(async()=>{let e=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?p:"dirty"===e.status?(t.dirty(),m(e.value)):this._def.out._parseAsync({data:e.value,path:r.path,parent:r})})();{let e=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return"aborted"===e.status?p:"dirty"===e.status?(t.dirty(),{status:"dirty",value:e.value}):this._def.out._parseSync({data:e.value,path:r.path,parent:r})}}static create(e,t){return new eO({in:e,out:t,typeName:to.ZodPipeline})}}class ek extends T{_parse(e){let t=this._def.innerType._parse(e);return _(t)&&(t.value=Object.freeze(t.value)),t}unwrap(){return this._def.innerType}}function eT(e,t={},r){return e?V.create().superRefine((n,i)=>{var s,o;if(!e(n)){let e="function"==typeof t?t(n):"string"==typeof t?{message:t}:t,a=null===(o=null!==(s=e.fatal)&&void 0!==s?s:r)||void 0===o||o;i.addIssue({code:"custom",..."string"==typeof e?{message:e}:e,fatal:a})}}):V.create()}ek.create=(e,t)=>new ek({innerType:e,typeName:to.ZodReadonly,...k(t)});let eC={object:ee.lazycreate};(te=to||(to={})).ZodString="ZodString",te.ZodNumber="ZodNumber",te.ZodNaN="ZodNaN",te.ZodBigInt="ZodBigInt",te.ZodBoolean="ZodBoolean",te.ZodDate="ZodDate",te.ZodSymbol="ZodSymbol",te.ZodUndefined="ZodUndefined",te.ZodNull="ZodNull",te.ZodAny="ZodAny",te.ZodUnknown="ZodUnknown",te.ZodNever="ZodNever",te.ZodVoid="ZodVoid",te.ZodArray="ZodArray",te.ZodObject="ZodObject",te.ZodUnion="ZodUnion",te.ZodDiscriminatedUnion="ZodDiscriminatedUnion",te.ZodIntersection="ZodIntersection",te.ZodTuple="ZodTuple",te.ZodRecord="ZodRecord",te.ZodMap="ZodMap",te.ZodSet="ZodSet",te.ZodFunction="ZodFunction",te.ZodLazy="ZodLazy",te.ZodLiteral="ZodLiteral",te.ZodEnum="ZodEnum",te.ZodEffects="ZodEffects",te.ZodNativeEnum="ZodNativeEnum",te.ZodOptional="ZodOptional",te.ZodNullable="ZodNullable",te.ZodDefault="ZodDefault",te.ZodCatch="ZodCatch",te.ZodPromise="ZodPromise",te.ZodBranded="ZodBranded",te.ZodPipeline="ZodPipeline",te.ZodReadonly="ZodReadonly";let eI=$.create,eR=z.create,ex=eS.create,eA=H.create,eP=G.create,eM=q.create,eN=Z.create,eD=W.create,eL=K.create,ej=V.create,eU=Q.create,eB=X.create,eF=J.create,e$=Y.create,ez=ee.create,eH=ee.strictCreate,eG=et.create,eq=en.create,eZ=ei.create,eW=es.create,eK=eo.create,eV=ea.create,eQ=eu.create,eX=el.create,eJ=ec.create,eY=ed.create,e0=eh.create,e1=ep.create,e2=em.create,e3=eg.create,e4=ey.create,e9=ev.create,e5=eg.createWithPreprocess,e8=eO.create;var e6,e7,te,tt,tr,tn,ti,ts,to,ta=Object.freeze({__proto__:null,defaultErrorMap:u,setErrorMap:function(e){l=e},getErrorMap:c,makeIssue:d,EMPTY_PATH:[],addIssueToContext:f,ParseStatus:h,INVALID:p,DIRTY:m,OK:g,isAborted:y,isDirty:v,isValid:_,isAsync:b,get util(){return tt},get objectUtil(){return tr},ZodParsedType:i,getParsedType:s,ZodType:T,datetimeRegex:F,ZodString:$,ZodNumber:z,ZodBigInt:H,ZodBoolean:G,ZodDate:q,ZodSymbol:Z,ZodUndefined:W,ZodNull:K,ZodAny:V,ZodUnknown:Q,ZodNever:X,ZodVoid:J,ZodArray:Y,ZodObject:ee,ZodUnion:et,ZodDiscriminatedUnion:en,ZodIntersection:ei,ZodTuple:es,ZodRecord:eo,ZodMap:ea,ZodSet:eu,ZodFunction:el,ZodLazy:ec,ZodLiteral:ed,ZodEnum:eh,ZodNativeEnum:ep,ZodPromise:em,ZodEffects:eg,ZodTransformer:eg,ZodOptional:ey,ZodNullable:ev,ZodDefault:e_,ZodCatch:eb,ZodNaN:eS,BRAND:eE,ZodBranded:ew,ZodPipeline:eO,ZodReadonly:ek,custom:eT,Schema:T,ZodSchema:T,late:eC,get ZodFirstPartyTypeKind(){return to},coerce:{string:e=>$.create({...e,coerce:!0}),number:e=>z.create({...e,coerce:!0}),boolean:e=>G.create({...e,coerce:!0}),bigint:e=>H.create({...e,coerce:!0}),date:e=>q.create({...e,coerce:!0})},any:ej,array:e$,bigint:eA,boolean:eP,date:eM,discriminatedUnion:eq,effect:e3,enum:e0,function:eX,instanceof:(e,t={message:`Input not instance of ${e.name}`})=>eT(t=>t instanceof e,t),intersection:eZ,lazy:eJ,literal:eY,map:eV,nan:ex,nativeEnum:e1,never:eB,null:eL,nullable:e9,number:eR,object:ez,oboolean:()=>eP().optional(),onumber:()=>eR().optional(),optional:e4,ostring:()=>eI().optional(),pipeline:e8,preprocess:e5,promise:e2,record:eK,set:eQ,strictObject:eH,string:eI,symbol:eN,transformer:e3,tuple:eW,undefined:eD,union:eG,unknown:eU,void:eF,NEVER:p,ZodIssueCode:o,quotelessJson:e=>JSON.stringify(e,null,2).replace(/"([^"]+)":/g,"$1:"),ZodError:a}),tu=r(34155);ta.object({DATABASE_URL:ta.string().url(),NODE_ENV:ta.enum(["development","test","production"]),NEXTAUTH_SECRET:ta.string(),NEXTAUTH_URL:ta.preprocess(e=>null!=e?e:tu.env.VERCEL_URL,tu.env.NEXTAUTH_URL?ta.string().url():ta.string()),GOOGLE_CLIENT_ID:ta.string(),GOOGLE_CLIENT_SECRET:ta.string(),LOCI_AWS_REGION:ta.string(),LOCI_MASTER_API_KEY:ta.string(),LOCI_AWS_ACCESS_KEY_ID:ta.string(),ALGOLIA_APP_ID:ta.string(),ALGOLIA_API_KEY:ta.string(),LOCI_TAXONOMIES_BUCKET_NAME:ta.string(),LOCI_AWS_SECRET_ACCESS_KEY:ta.string(),STRIPE_SECRET_KEY:ta.string(),STRIPE_STARTER_SUBSCRIPTION_PRICE_ID:ta.string(),STRIPE_PRO_SUBSCRIPTION_PRICE_ID:ta.string(),STRIPE_STARTER_SUBSCRIPTION_FIRST_MONTH_HALF_OFF_COUPON_ID:ta.string(),SLACK_API_BASE_URL:ta.string(),SLACK_BOT_TOKEN:ta.string(),SLACK_AUTO_WEBSITE_NEW_USERS_CHANNEL_ID:ta.string(),LOCI_API_URL:ta.string(),LOCI_PUBLIC_API_KEY:ta.string(),PLAYGROUND_UPLOADS_S3_BUCKET_NAME:ta.string(),APP_ENV:ta.string(),SENDGRID_API_KEY:ta.string(),SENDGRID_CONTACTS_ENDPOINT:ta.string(),SENDGRID_PRODUCT_UPDATE_LIST_ID:ta.string().optional(),SENDGRID_INVITE_TEMPLATE_ID:ta.string(),SENDGRID_SIGNIN_TEMPLATE_ID:ta.string(),SENDGRID_WELCOME_TEMPLATE_ID:ta.string(),LOCI_FROM_EMAIL:ta.string()}),ta.object({NEXT_PUBLIC_LOCI_API_URL:ta.string(),NEXT_PUBLIC_GOOGLE_ANALYTICS_ID:ta.string(),NEXT_PUBLIC_HOTJAR_ID:ta.string().optional(),NEXT_PUBLIC_APP_ENV:ta.string().optional(),NEXT_PUBLIC_README_URL:ta.string().optional(),NEXT_PUBLIC_STRIPE_STARTER_SUBSCRIPTION_PRICE_ID:ta.string(),NEXT_PUBLIC_STRIPE_PRO_SUBSCRIPTION_PRICE_ID:ta.string(),NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY:ta.string()});let tl={NEXT_PUBLIC_README_URL:"https://docs.loci.ai",NEXT_PUBLIC_LOCI_API_URL:"https://loci-api.com",NEXT_PUBLIC_GOOGLE_ANALYTICS_ID:"G-QQS8KLL89Y",NEXT_PUBLIC_HOTJAR_ID:"3340469",NEXT_PUBLIC_APP_ENV:"production",NEXT_PUBLIC_STRIPE_STARTER_SUBSCRIPTION_PRICE_ID:"price_1PGKyiGUJ05soCP4gDfFxZQB",NEXT_PUBLIC_STRIPE_PRO_SUBSCRIPTION_PRICE_ID:"price_1PGKxUGUJ05soCP470Qa3dJr",NEXT_PUBLIC_CLERK_PUBLISHABLE_KEY:"pk_live_Y2xlcmsubG9jaS5haSQ"}},86501:function(e,t,r){"use strict";let n,i;r.d(t,{x7:function(){return ed},ZP:function(){return ef},Am:function(){return U}});var s,o=r(67294);let a={data:""},u=e=>"object"==typeof window?((e?e.querySelector("#_goober"):window._goober)||Object.assign((e||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:e||a,l=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,c=/\/\*[^]*?\*\/|  +/g,d=/\n+/g,f=(e,t)=>{let r="",n="",i="";for(let s in e){let o=e[s];"@"==s[0]?"i"==s[1]?r=s+" "+o+";":n+="f"==s[1]?f(o,s):s+"{"+f(o,"k"==s[1]?"":t)+"}":"object"==typeof o?n+=f(o,t?t.replace(/([^,])+/g,e=>s.replace(/(^:.*)|([^,])+/g,t=>/&/.test(t)?t.replace(/&/g,e):e?e+" "+t:t)):s):null!=o&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=f.p?f.p(s,o):s+":"+o+";")}return r+(t&&i?t+"{"+i+"}":i)+n},h={},p=e=>{if("object"==typeof e){let t="";for(let r in e)t+=r+p(e[r]);return t}return e},m=(e,t,r,n,i)=>{var s;let o=p(e),a=h[o]||(h[o]=(e=>{let t=0,r=11;for(;t<e.length;)r=101*r+e.charCodeAt(t++)>>>0;return"go"+r})(o));if(!h[a]){let t=o!==e?e:(e=>{let t,r,n=[{}];for(;t=l.exec(e.replace(c,""));)t[4]?n.shift():t[3]?(r=t[3].replace(d," ").trim(),n.unshift(n[0][r]=n[0][r]||{})):n[0][t[1]]=t[2].replace(d," ").trim();return n[0]})(e);h[a]=f(i?{["@keyframes "+a]:t}:t,r?"":"."+a)}let u=r&&h.g?h.g:null;return r&&(h.g=h[a]),s=h[a],u?t.data=t.data.replace(u,s):-1===t.data.indexOf(s)&&(t.data=n?s+t.data:t.data+s),a},g=(e,t,r)=>e.reduce((e,n,i)=>{let s=t[i];if(s&&s.call){let e=s(r),t=e&&e.props&&e.props.className||/^go/.test(e)&&e;s=t?"."+t:e&&"object"==typeof e?e.props?"":f(e,""):!1===e?"":e}return e+n+(null==s?"":s)},"");function y(e){let t=this||{},r=e.call?e(t.p):e;return m(r.unshift?r.raw?g(r,[].slice.call(arguments,1),t.p):r.reduce((e,r)=>Object.assign(e,r&&r.call?r(t.p):r),{}):r,u(t.target),t.g,t.o,t.k)}y.bind({g:1});let v,_,b,S=y.bind({k:1});function E(e,t){let r=this||{};return function(){let n=arguments;function i(s,o){let a=Object.assign({},s),u=a.className||i.className;r.p=Object.assign({theme:_&&_()},a),r.o=/ *go\d+/.test(u),a.className=y.apply(r,n)+(u?" "+u:""),t&&(a.ref=o);let l=e;return e[0]&&(l=a.as||e,delete a.as),b&&l[0]&&b(a),v(l,a)}return t?t(i):i}}var w=e=>"function"==typeof e,O=(e,t)=>w(e)?e(t):e,k=(n=0,()=>(++n).toString()),T=()=>{if(void 0===i&&"u">typeof window){let e=matchMedia("(prefers-reduced-motion: reduce)");i=!e||e.matches}return i},C=new Map,I=e=>{if(C.has(e))return;let t=setTimeout(()=>{C.delete(e),M({type:4,toastId:e})},1e3);C.set(e,t)},R=e=>{let t=C.get(e);t&&clearTimeout(t)},x=(e,t)=>{switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,20)};case 1:return t.toast.id&&R(t.toast.id),{...e,toasts:e.toasts.map(e=>e.id===t.toast.id?{...e,...t.toast}:e)};case 2:let{toast:r}=t;return e.toasts.find(e=>e.id===r.id)?x(e,{type:1,toast:r}):x(e,{type:0,toast:r});case 3:let{toastId:n}=t;return n?I(n):e.toasts.forEach(e=>{I(e.id)}),{...e,toasts:e.toasts.map(e=>e.id===n||void 0===n?{...e,visible:!1}:e)};case 4:return void 0===t.toastId?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(e=>e.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let i=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(e=>({...e,pauseDuration:e.pauseDuration+i}))}}},A=[],P={toasts:[],pausedAt:void 0},M=e=>{P=x(P,e),A.forEach(e=>{e(P)})},N={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},D=(e={})=>{let[t,r]=(0,o.useState)(P);(0,o.useEffect)(()=>(A.push(r),()=>{let e=A.indexOf(r);e>-1&&A.splice(e,1)}),[t]);let n=t.toasts.map(t=>{var r,n;return{...e,...e[t.type],...t,duration:t.duration||(null==(r=e[t.type])?void 0:r.duration)||(null==e?void 0:e.duration)||N[t.type],style:{...e.style,...null==(n=e[t.type])?void 0:n.style,...t.style}}});return{...t,toasts:n}},L=(e,t="blank",r)=>({createdAt:Date.now(),visible:!0,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...r,id:(null==r?void 0:r.id)||k()}),j=e=>(t,r)=>{let n=L(t,e,r);return M({type:2,toast:n}),n.id},U=(e,t)=>j("blank")(e,t);U.error=j("error"),U.success=j("success"),U.loading=j("loading"),U.custom=j("custom"),U.dismiss=e=>{M({type:3,toastId:e})},U.remove=e=>M({type:4,toastId:e}),U.promise=(e,t,r)=>{let n=U.loading(t.loading,{...r,...null==r?void 0:r.loading});return e.then(e=>(U.success(O(t.success,e),{id:n,...r,...null==r?void 0:r.success}),e)).catch(e=>{U.error(O(t.error,e),{id:n,...r,...null==r?void 0:r.error})}),e};var B=(e,t)=>{M({type:1,toast:{id:e,height:t}})},F=()=>{M({type:5,time:Date.now()})},$=e=>{let{toasts:t,pausedAt:r}=D(e);(0,o.useEffect)(()=>{if(r)return;let e=Date.now(),n=t.map(t=>{if(t.duration===1/0)return;let r=(t.duration||0)+t.pauseDuration-(e-t.createdAt);if(r<0){t.visible&&U.dismiss(t.id);return}return setTimeout(()=>U.dismiss(t.id),r)});return()=>{n.forEach(e=>e&&clearTimeout(e))}},[t,r]);let n=(0,o.useCallback)(()=>{r&&M({type:6,time:Date.now()})},[r]),i=(0,o.useCallback)((e,r)=>{let{reverseOrder:n=!1,gutter:i=8,defaultPosition:s}=r||{},o=t.filter(t=>(t.position||s)===(e.position||s)&&t.height),a=o.findIndex(t=>t.id===e.id),u=o.filter((e,t)=>t<a&&e.visible).length;return o.filter(e=>e.visible).slice(...n?[u+1]:[0,u]).reduce((e,t)=>e+(t.height||0)+i,0)},[t]);return{toasts:t,handlers:{updateHeight:B,startPause:F,endPause:n,calculateOffset:i}}},z=S`
from {
  transform: scale(0) rotate(45deg);
	opacity: 0;
}
to {
 transform: scale(1) rotate(45deg);
  opacity: 1;
}`,H=S`
from {
  transform: scale(0);
  opacity: 0;
}
to {
  transform: scale(1);
  opacity: 1;
}`,G=S`
from {
  transform: scale(0) rotate(90deg);
	opacity: 0;
}
to {
  transform: scale(1) rotate(90deg);
	opacity: 1;
}`,q=E("div")`
  width: 20px;
  opacity: 0;
  height: 20px;
  border-radius: 10px;
  background: ${e=>e.primary||"#ff4b4b"};
  position: relative;
  transform: rotate(45deg);

  animation: ${z} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
  animation-delay: 100ms;

  &:after,
  &:before {
    content: '';
    animation: ${H} 0.15s ease-out forwards;
    animation-delay: 150ms;
    position: absolute;
    border-radius: 3px;
    opacity: 0;
    background: ${e=>e.secondary||"#fff"};
    bottom: 9px;
    left: 4px;
    height: 2px;
    width: 12px;
  }

  &:before {
    animation: ${G} 0.15s ease-out forwards;
    animation-delay: 180ms;
    transform: rotate(90deg);
  }
`,Z=S`
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
`,W=E("div")`
  width: 12px;
  height: 12px;
  box-sizing: border-box;
  border: 2px solid;
  border-radius: 100%;
  border-color: ${e=>e.secondary||"#e0e0e0"};
  border-right-color: ${e=>e.primary||"#616161"};
  animation: ${Z} 1s linear infinite;
`,K=S`
from {
  transform: scale(0) rotate(45deg);
	opacity: 0;
}
to {
  transform: scale(1) rotate(45deg);
	opacity: 1;
}`,V=S`
0% {
	height: 0;
	width: 0;
	opacity: 0;
}
40% {
  height: 0;
	width: 6px;
	opacity: 1;
}
100% {
  opacity: 1;
  height: 10px;
}`,Q=E("div")`
  width: 20px;
  opacity: 0;
  height: 20px;
  border-radius: 10px;
  background: ${e=>e.primary||"#61d345"};
  position: relative;
  transform: rotate(45deg);

  animation: ${K} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
  animation-delay: 100ms;
  &:after {
    content: '';
    box-sizing: border-box;
    animation: ${V} 0.2s ease-out forwards;
    opacity: 0;
    animation-delay: 200ms;
    position: absolute;
    border-right: 2px solid;
    border-bottom: 2px solid;
    border-color: ${e=>e.secondary||"#fff"};
    bottom: 6px;
    left: 6px;
    height: 10px;
    width: 6px;
  }
`,X=E("div")`
  position: absolute;
`,J=E("div")`
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 20px;
  min-height: 20px;
`,Y=S`
from {
  transform: scale(0.6);
  opacity: 0.4;
}
to {
  transform: scale(1);
  opacity: 1;
}`,ee=E("div")`
  position: relative;
  transform: scale(0.6);
  opacity: 0.4;
  min-width: 20px;
  animation: ${Y} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275)
    forwards;
`,et=({toast:e})=>{let{icon:t,type:r,iconTheme:n}=e;return void 0!==t?"string"==typeof t?o.createElement(ee,null,t):t:"blank"===r?null:o.createElement(J,null,o.createElement(W,{...n}),"loading"!==r&&o.createElement(X,null,"error"===r?o.createElement(q,{...n}):o.createElement(Q,{...n})))},er=e=>`
0% {transform: translate3d(0,${-200*e}%,0) scale(.6); opacity:.5;}
100% {transform: translate3d(0,0,0) scale(1); opacity:1;}
`,en=e=>`
0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;}
100% {transform: translate3d(0,${-150*e}%,-1px) scale(.6); opacity:0;}
`,ei=E("div")`
  display: flex;
  align-items: center;
  background: #fff;
  color: #363636;
  line-height: 1.3;
  will-change: transform;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05);
  max-width: 350px;
  pointer-events: auto;
  padding: 8px 10px;
  border-radius: 8px;
`,es=E("div")`
  display: flex;
  justify-content: center;
  margin: 4px 10px;
  color: inherit;
  flex: 1 1 auto;
  white-space: pre-line;
`,eo=(e,t)=>{let r=e.includes("top")?1:-1,[n,i]=T()?["0%{opacity:0;} 100%{opacity:1;}","0%{opacity:1;} 100%{opacity:0;}"]:[er(r),en(r)];return{animation:t?`${S(n)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${S(i)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},ea=o.memo(({toast:e,position:t,style:r,children:n})=>{let i=e.height?eo(e.position||t||"top-center",e.visible):{opacity:0},s=o.createElement(et,{toast:e}),a=o.createElement(es,{...e.ariaProps},O(e.message,e));return o.createElement(ei,{className:e.className,style:{...i,...r,...e.style}},"function"==typeof n?n({icon:s,message:a}):o.createElement(o.Fragment,null,s,a))});s=o.createElement,f.p=void 0,v=s,_=void 0,b=void 0;var eu=({id:e,className:t,style:r,onHeightUpdate:n,children:i})=>{let s=o.useCallback(t=>{if(t){let r=()=>{n(e,t.getBoundingClientRect().height)};r(),new MutationObserver(r).observe(t,{subtree:!0,childList:!0,characterData:!0})}},[e,n]);return o.createElement("div",{ref:s,className:t,style:r},i)},el=(e,t)=>{let r=e.includes("top"),n=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:T()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(r?1:-1)}px)`,...r?{top:0}:{bottom:0},...n}},ec=y`
  z-index: 9999;
  > * {
    pointer-events: auto;
  }
`,ed=({reverseOrder:e,position:t="top-center",toastOptions:r,gutter:n,children:i,containerStyle:s,containerClassName:a})=>{let{toasts:u,handlers:l}=$(r);return o.createElement("div",{style:{position:"fixed",zIndex:9999,top:16,left:16,right:16,bottom:16,pointerEvents:"none",...s},className:a,onMouseEnter:l.startPause,onMouseLeave:l.endPause},u.map(r=>{let s=r.position||t,a=el(s,l.calculateOffset(r,{reverseOrder:e,gutter:n,defaultPosition:t}));return o.createElement(eu,{id:r.id,key:r.id,onHeightUpdate:l.updateHeight,className:r.visible?ec:"",style:a},"custom"===r.type?O(r.message,r):i?i(r):o.createElement(ea,{toast:r,position:s}))}))},ef=U},64529:function(e,t,r){"use strict";r.d(t,{Ue:function(){return f}});let n=e=>{let t;let r=new Set,n=(e,n)=>{let i="function"==typeof e?e(t):e;if(!Object.is(i,t)){let e=t;t=(null!=n?n:"object"!=typeof i||null===i)?i:Object.assign({},t,i),r.forEach(r=>r(t,e))}},i=()=>t,s={setState:n,getState:i,getInitialState:()=>o,subscribe:e=>(r.add(e),()=>r.delete(e)),destroy:()=>{console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}},o=t=e(n,i,s);return s},i=e=>e?n(e):n;var s=r(67294),o=r(28258);let{useDebugValue:a}=s,{useSyncExternalStoreWithSelector:u}=o,l=!1,c=e=>e,d=e=>{"function"!=typeof e&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");let t="function"==typeof e?i(e):e,r=(e,r)=>(function(e,t=c,r){r&&!l&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),l=!0);let n=u(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,r);return a(n),n})(t,e,r);return Object.assign(r,t),r},f=e=>e?d(e):d},782:function(e,t,r){"use strict";r.d(t,{mW:function(){return o}});let n=new Map,i=e=>{let t=n.get(e);return t?Object.fromEntries(Object.entries(t.stores).map(([e,t])=>[e,t.getState()])):{}},s=(e,t,r)=>{if(void 0===e)return{type:"untracked",connection:t.connect(r)};let i=n.get(r.name);if(i)return{type:"tracked",store:e,...i};let s={connection:t.connect(r),stores:{}};return n.set(r.name,s),{type:"tracked",store:e,...s}},o=(e,t={})=>(r,n,o)=>{let u;let{enabled:l,anonymousActionType:c,store:d,...f}=t;try{u=(null==l||l)&&window.__REDUX_DEVTOOLS_EXTENSION__}catch(e){}if(!u)return l&&console.warn("[zustand devtools middleware] Please install/enable Redux devtools extension"),e(r,n,o);let{connection:h,...p}=s(d,u,f),m=!0;o.setState=(e,t,s)=>{let a=r(e,t);if(!m)return a;let u=void 0===s?{type:c||"anonymous"}:"string"==typeof s?{type:s}:s;return void 0===d?null==h||h.send(u,n()):null==h||h.send({...u,type:`${d}/${u.type}`},{...i(f.name),[d]:o.getState()}),a};let g=(...e)=>{let t=m;m=!1,r(...e),m=t},y=e(o.setState,n,o);if("untracked"===p.type?null==h||h.init(y):(p.stores[p.store]=o,null==h||h.init(Object.fromEntries(Object.entries(p.stores).map(([e,t])=>[e,e===p.store?y:t.getState()])))),o.dispatchFromDevtools&&"function"==typeof o.dispatch){let e=!1,t=o.dispatch;o.dispatch=(...r)=>{"__setState"!==r[0].type||e||(console.warn('[zustand devtools middleware] "__setState" action type is reserved to set state from the devtools. Avoid using it.'),e=!0),t(...r)}}return h.subscribe(e=>{var t;switch(e.type){case"ACTION":if("string"!=typeof e.payload){console.error("[zustand devtools middleware] Unsupported action format");return}return a(e.payload,e=>{if("__setState"===e.type){if(void 0===d){g(e.state);return}1!==Object.keys(e.state).length&&console.error(`
                    [zustand devtools middleware] Unsupported __setState action format. 
                    When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),
                    and value of this only key should be a state object. Example: { "type": "__setState", "state": { "abc123Store": { "foo": "bar" } } }
                    `);let t=e.state[d];if(null==t)return;JSON.stringify(o.getState())!==JSON.stringify(t)&&g(t);return}o.dispatchFromDevtools&&"function"==typeof o.dispatch&&o.dispatch(e)});case"DISPATCH":switch(e.payload.type){case"RESET":if(g(y),void 0===d)return null==h?void 0:h.init(o.getState());return null==h?void 0:h.init(i(f.name));case"COMMIT":if(void 0===d){null==h||h.init(o.getState());break}return null==h?void 0:h.init(i(f.name));case"ROLLBACK":return a(e.state,e=>{if(void 0===d){g(e),null==h||h.init(o.getState());return}g(e[d]),null==h||h.init(i(f.name))});case"JUMP_TO_STATE":case"JUMP_TO_ACTION":return a(e.state,e=>{if(void 0===d){g(e);return}JSON.stringify(o.getState())!==JSON.stringify(e[d])&&g(e[d])});case"IMPORT_STATE":{let{nextLiftedState:r}=e.payload,n=null==(t=r.computedStates.slice(-1)[0])?void 0:t.state;if(!n)return;void 0===d?g(n):g(n[d]),null==h||h.send(null,r);break}case"PAUSE_RECORDING":return m=!m}return}}),y},a=(e,t)=>{let r;try{r=JSON.parse(e)}catch(e){console.error("[zustand devtools middleware] Could not parse the received json",e)}void 0!==r&&t(r)}}},function(e){var t=function(t){return e(e.s=t)};e.O(0,[9774,179],function(){return t(49110),t(6840),t(9090)}),_N_E=e.O()}]);