var nG=Object.defineProperty;var iG=(e,t,r)=>t in e?nG(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r;var Ri=(e,t,r)=>(iG(e,typeof t!="symbol"?t+"":t,r),r);function lq(e,t){for(var r=0;rn[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const o of a.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();var Ut=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function $u(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Zo(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var r=function n(){return this instanceof n?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};r.prototype=t.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(e).forEach(function(n){var i=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(r,n,i.get?i:{enumerable:!0,get:function(){return e[n]}})}),r}var cq={exports:{}},cp={},fq={exports:{}},Fe={};/** * @license React * react.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 Dc=Symbol.for("react.element"),aG=Symbol.for("react.portal"),oG=Symbol.for("react.fragment"),sG=Symbol.for("react.strict_mode"),uG=Symbol.for("react.profiler"),lG=Symbol.for("react.provider"),cG=Symbol.for("react.context"),fG=Symbol.for("react.forward_ref"),dG=Symbol.for("react.suspense"),hG=Symbol.for("react.memo"),pG=Symbol.for("react.lazy"),k1=Symbol.iterator;function vG(e){return e===null||typeof e!="object"?null:(e=k1&&e[k1]||e["@@iterator"],typeof e=="function"?e:null)}var dq={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},hq=Object.assign,pq={};function Du(e,t,r){this.props=e,this.context=t,this.refs=pq,this.updater=r||dq}Du.prototype.isReactComponent={};Du.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Du.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function vq(){}vq.prototype=Du.prototype;function JR(e,t,r){this.props=e,this.context=t,this.refs=pq,this.updater=r||dq}var XR=JR.prototype=new vq;XR.constructor=JR;hq(XR,Du.prototype);XR.isPureReactComponent=!0;var O1=Array.isArray,mq=Object.prototype.hasOwnProperty,ZR={current:null},gq={key:!0,ref:!0,__self:!0,__source:!0};function _q(e,t,r){var n,i={},a=null,o=null;if(t!=null)for(n in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(a=""+t.key),t)mq.call(t,n)&&!gq.hasOwnProperty(n)&&(i[n]=t[n]);var s=arguments.length-2;if(s===1)i.children=r;else if(1>>1,Z=D[ee];if(0>>1;eei(ae,z))rei(ie,ae)?(D[ee]=ie,D[re]=z,ee=re):(D[ee]=ae,D[Q]=z,ee=Q);else if(rei(ie,z))D[ee]=ie,D[re]=z,ee=re;else break e}}return F}function i(D,F){var z=D.sortIndex-F.sortIndex;return z!==0?z:D.id-F.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var u=[],l=[],c=1,f=null,d=3,h=!1,p=!1,v=!1,_=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function y(D){for(var F=r(l);F!==null;){if(F.callback===null)n(l);else if(F.startTime<=D)n(l),F.sortIndex=F.expirationTime,t(u,F);else break;F=r(l)}}function S(D){if(v=!1,y(D),!p)if(r(u)!==null)p=!0,Y(b);else{var F=r(l);F!==null&&B(S,F.startTime-D)}}function b(D,F){p=!1,v&&(v=!1,m(R),R=-1),h=!0;var z=d;try{for(y(F),f=r(u);f!==null&&(!(f.expirationTime>F)||D&&!C());){var ee=f.callback;if(typeof ee=="function"){f.callback=null,d=f.priorityLevel;var Z=ee(f.expirationTime<=F);F=e.unstable_now(),typeof Z=="function"?f.callback=Z:f===r(u)&&n(u),y(F)}else n(u);f=r(u)}if(f!==null)var W=!0;else{var Q=r(l);Q!==null&&B(S,Q.startTime-F),W=!1}return W}finally{f=null,d=z,h=!1}}var E=!1,w=null,R=-1,O=5,k=-1;function C(){return!(e.unstable_now()-kD||125ee?(D.sortIndex=z,t(l,D),r(u)===null&&D===r(l)&&(v?(m(R),R=-1):v=!0,B(S,z-ee))):(D.sortIndex=Z,t(u,D),p||h||(p=!0,Y(b))),D},e.unstable_shouldYield=C,e.unstable_wrapCallback=function(D){var F=d;return function(){var z=d;d=F;try{return D.apply(this,arguments)}finally{d=z}}}})(Eq);bq.exports=Eq;var kG=bq.exports;/** * @license React * react-dom.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 wq=I,fn=kG;function X(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),bE=Object.prototype.hasOwnProperty,OG=/^[:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD][:A-Z_a-z\u00C0-\u00D6\u00D8-\u00F6\u00F8-\u02FF\u0370-\u037D\u037F-\u1FFF\u200C-\u200D\u2070-\u218F\u2C00-\u2FEF\u3001-\uD7FF\uF900-\uFDCF\uFDF0-\uFFFD\-.0-9\u00B7\u0300-\u036F\u203F-\u2040]*$/,I1={},x1={};function PG(e){return bE.call(x1,e)?!0:bE.call(I1,e)?!1:OG.test(e)?x1[e]=!0:(I1[e]=!0,!1)}function IG(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function xG(e,t,r,n){if(t===null||typeof t>"u"||IG(e,t,r,n))return!0;if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function zr(e,t,r,n,i,a,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=o}var gr={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){gr[e]=new zr(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];gr[t]=new zr(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){gr[e]=new zr(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){gr[e]=new zr(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){gr[e]=new zr(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){gr[e]=new zr(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){gr[e]=new zr(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){gr[e]=new zr(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){gr[e]=new zr(e,5,!1,e.toLowerCase(),null,!1,!1)});var tT=/[\-:]([a-z])/g;function rT(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(tT,rT);gr[t]=new zr(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(tT,rT);gr[t]=new zr(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(tT,rT);gr[t]=new zr(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){gr[e]=new zr(e,1,!1,e.toLowerCase(),null,!1,!1)});gr.xlinkHref=new zr("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){gr[e]=new zr(e,1,!1,e.toLowerCase(),null,!0,!0)});function nT(e,t,r,n){var i=gr.hasOwnProperty(t)?gr[t]:null;(i!==null?i.type!==0:n||!(2s||i[o]!==a[s]){var u=` `+i[o].replace(" at new "," at ");return e.displayName&&u.includes("")&&(u=u.replace("",e.displayName)),u}while(1<=o&&0<=s);break}}}finally{um=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Tl(e):""}function CG(e){switch(e.tag){case 5:return Tl(e.type);case 16:return Tl("Lazy");case 13:return Tl("Suspense");case 19:return Tl("SuspenseList");case 0:case 2:case 15:return e=lm(e.type,!1),e;case 11:return e=lm(e.type.render,!1),e;case 1:return e=lm(e.type,!0),e;default:return""}}function TE(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Rs:return"Fragment";case ws:return"Portal";case EE:return"Profiler";case iT:return"StrictMode";case wE:return"Suspense";case RE:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case kq:return(e.displayName||"Context")+".Consumer";case Tq:return(e._context.displayName||"Context")+".Provider";case aT:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case oT:return t=e.displayName||null,t!==null?t:TE(e.type)||"Memo";case ya:t=e._payload,e=e._init;try{return TE(e(t))}catch{}}return null}function $G(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return TE(t);case 8:return t===iT?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Qa(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Pq(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function DG(e){var t=Pq(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){n=""+o,a.call(this,o)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function df(e){e._valueTracker||(e._valueTracker=DG(e))}function Iq(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=Pq(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function Xd(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function kE(e,t){var r=t.checked;return Et({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function $1(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=Qa(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function xq(e,t){t=t.checked,t!=null&&nT(e,"checked",t,!1)}function OE(e,t){xq(e,t);var r=Qa(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?PE(e,t.type,r):t.hasOwnProperty("defaultValue")&&PE(e,t.type,Qa(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function D1(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function PE(e,t,r){(t!=="number"||Xd(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var kl=Array.isArray;function Vs(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i"+t.valueOf().toString()+"",t=hf.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function tc(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Dl={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},NG=["Webkit","ms","Moz","O"];Object.keys(Dl).forEach(function(e){NG.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Dl[t]=Dl[e]})});function Nq(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Dl.hasOwnProperty(e)&&Dl[e]?(""+t).trim():t+"px"}function Aq(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=Nq(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var AG=Et({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function CE(e,t){if(t){if(AG[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(X(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(X(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(X(61))}if(t.style!=null&&typeof t.style!="object")throw Error(X(62))}}function $E(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var DE=null;function sT(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var NE=null,Ys=null,Qs=null;function L1(e){if(e=Lc(e)){if(typeof NE!="function")throw Error(X(280));var t=e.stateNode;t&&(t=vp(t),NE(e.stateNode,e.type,t))}}function Lq(e){Ys?Qs?Qs.push(e):Qs=[e]:Ys=e}function Mq(){if(Ys){var e=Ys,t=Qs;if(Qs=Ys=null,L1(e),t)for(e=0;e>>=0,e===0?32:31-(GG(e)/VG|0)|0}var pf=64,vf=4194304;function Ol(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function rh(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,a=e.pingedLanes,o=r&268435455;if(o!==0){var s=o&~i;s!==0?n=Ol(s):(a&=o,a!==0&&(n=Ol(a)))}else o=r&~i,o!==0?n=Ol(o):a!==0&&(n=Ol(a));if(n===0)return 0;if(t!==0&&t!==n&&!(t&i)&&(i=n&-n,a=t&-t,i>=a||i===16&&(a&4194240)!==0))return t;if(n&4&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0r;r++)t.push(e);return t}function Nc(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Vn(t),e[t]=r}function JG(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0=Al),W1=String.fromCharCode(32),G1=!1;function nU(e,t){switch(e){case"keyup":return TV.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function iU(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Ts=!1;function OV(e,t){switch(e){case"compositionend":return iU(t);case"keypress":return t.which!==32?null:(G1=!0,W1);case"textInput":return e=t.data,e===W1&&G1?null:e;default:return null}}function PV(e,t){if(Ts)return e==="compositionend"||!vT&&nU(e,t)?(e=tU(),hd=dT=Da=null,Ts=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=K1(r)}}function uU(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?uU(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function lU(){for(var e=window,t=Xd();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Xd(e.document)}return t}function mT(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function MV(e){var t=lU(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&uU(r.ownerDocument.documentElement,r)){if(n!==null&&mT(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,a=Math.min(n.start,i);n=n.end===void 0?a:Math.min(n.end,i),!e.extend&&a>n&&(i=n,n=a,a=i),i=J1(r,a);var o=J1(r,n);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),a>n?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r=document.documentMode,ks=null,qE=null,Ml=null,UE=!1;function X1(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;UE||ks==null||ks!==Xd(n)||(n=ks,"selectionStart"in n&&mT(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focusNode:n.focusNode,focusOffset:n.focusOffset}),Ml&&sc(Ml,n)||(Ml=n,n=ah(qE,"onSelect"),0Is||(e.current=VE[Is],VE[Is]=null,Is--)}function ct(e,t){Is++,VE[Is]=e.current,e.current=t}var Ka={},Or=oo(Ka),Kr=oo(!1),zo=Ka;function lu(e,t){var r=e.type.contextTypes;if(!r)return Ka;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},a;for(a in r)i[a]=t[a];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Jr(e){return e=e.childContextTypes,e!=null}function sh(){vt(Kr),vt(Or)}function aP(e,t,r){if(Or.current!==Ka)throw Error(X(168));ct(Or,t),ct(Kr,r)}function _U(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(X(108,$G(e)||"Unknown",i));return Et({},r,n)}function uh(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Ka,zo=Or.current,ct(Or,e),ct(Kr,Kr.current),!0}function oP(e,t,r){var n=e.stateNode;if(!n)throw Error(X(169));r?(e=_U(e,t,zo),n.__reactInternalMemoizedMergedChildContext=e,vt(Kr),vt(Or),ct(Or,e)):vt(Kr),ct(Kr,r)}var xi=null,mp=!1,wm=!1;function yU(e){xi===null?xi=[e]:xi.push(e)}function QV(e){mp=!0,yU(e)}function so(){if(!wm&&xi!==null){wm=!0;var e=0,t=Ze;try{var r=xi;for(Ze=1;e>=o,i-=o,$i=1<<32-Vn(t)+i|r<R?(O=w,w=null):O=w.sibling;var k=d(m,w,y[R],S);if(k===null){w===null&&(w=O);break}e&&w&&k.alternate===null&&t(m,w),g=a(k,g,R),E===null?b=k:E.sibling=k,E=k,w=O}if(R===y.length)return r(m,w),gt&&So(m,R),b;if(w===null){for(;RR?(O=w,w=null):O=w.sibling;var C=d(m,w,k.value,S);if(C===null){w===null&&(w=O);break}e&&w&&C.alternate===null&&t(m,w),g=a(C,g,R),E===null?b=C:E.sibling=C,E=C,w=O}if(k.done)return r(m,w),gt&&So(m,R),b;if(w===null){for(;!k.done;R++,k=y.next())k=f(m,k.value,S),k!==null&&(g=a(k,g,R),E===null?b=k:E.sibling=k,E=k);return gt&&So(m,R),b}for(w=n(m,w);!k.done;R++,k=y.next())k=h(w,m,R,k.value,S),k!==null&&(e&&k.alternate!==null&&w.delete(k.key===null?R:k.key),g=a(k,g,R),E===null?b=k:E.sibling=k,E=k);return e&&w.forEach(function(T){return t(m,T)}),gt&&So(m,R),b}function _(m,g,y,S){if(typeof y=="object"&&y!==null&&y.type===Rs&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case ff:e:{for(var b=y.key,E=g;E!==null;){if(E.key===b){if(b=y.type,b===Rs){if(E.tag===7){r(m,E.sibling),g=i(E,y.props.children),g.return=m,m=g;break e}}else if(E.elementType===b||typeof b=="object"&&b!==null&&b.$$typeof===ya&&hP(b)===E.type){r(m,E.sibling),g=i(E,y.props),g.ref=sl(m,E,y),g.return=m,m=g;break e}r(m,E);break}else t(m,E);E=E.sibling}y.type===Rs?(g=Fo(y.props.children,m.mode,S,y.key),g.return=m,m=g):(S=bd(y.type,y.key,y.props,null,m.mode,S),S.ref=sl(m,g,y),S.return=m,m=S)}return o(m);case ws:e:{for(E=y.key;g!==null;){if(g.key===E)if(g.tag===4&&g.stateNode.containerInfo===y.containerInfo&&g.stateNode.implementation===y.implementation){r(m,g.sibling),g=i(g,y.children||[]),g.return=m,m=g;break e}else{r(m,g);break}else t(m,g);g=g.sibling}g=Cm(y,m.mode,S),g.return=m,m=g}return o(m);case ya:return E=y._init,_(m,g,E(y._payload),S)}if(kl(y))return p(m,g,y,S);if(rl(y))return v(m,g,y,S);Ef(m,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,g!==null&&g.tag===6?(r(m,g.sibling),g=i(g,y),g.return=m,m=g):(r(m,g),g=xm(y,m.mode,S),g.return=m,m=g),o(m)):r(m,g)}return _}var fu=OU(!0),PU=OU(!1),Mc={},gi=oo(Mc),fc=oo(Mc),dc=oo(Mc);function Co(e){if(e===Mc)throw Error(X(174));return e}function TT(e,t){switch(ct(dc,t),ct(fc,e),ct(gi,Mc),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:xE(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=xE(t,e)}vt(gi),ct(gi,t)}function du(){vt(gi),vt(fc),vt(dc)}function IU(e){Co(dc.current);var t=Co(gi.current),r=xE(t,e.type);t!==r&&(ct(fc,e),ct(gi,r))}function kT(e){fc.current===e&&(vt(gi),vt(fc))}var _t=oo(0);function ph(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Rm=[];function OT(){for(var e=0;er?r:4,e(!0);var n=Tm.transition;Tm.transition={};try{e(!1),t()}finally{Ze=r,Tm.transition=n}}function WU(){return xn().memoizedState}function ZV(e,t,r){var n=za(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},GU(e))VU(t,r);else if(r=wU(e,t,r,n),r!==null){var i=jr();Yn(r,e,n,i),YU(r,t,n)}}function e8(e,t,r){var n=za(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(GU(e))VU(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,r);if(i.hasEagerState=!0,i.eagerState=s,Jn(s,o)){var u=t.interleaved;u===null?(i.next=i,wT(t)):(i.next=u.next,u.next=i),t.interleaved=i;return}}catch{}finally{}r=wU(e,t,i,n),r!==null&&(i=jr(),Yn(r,e,n,i),YU(r,t,n))}}function GU(e){var t=e.alternate;return e===bt||t!==null&&t===bt}function VU(e,t){Fl=vh=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function YU(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,lT(e,r)}}var mh={readContext:In,useCallback:br,useContext:br,useEffect:br,useImperativeHandle:br,useInsertionEffect:br,useLayoutEffect:br,useMemo:br,useReducer:br,useRef:br,useState:br,useDebugValue:br,useDeferredValue:br,useTransition:br,useMutableSource:br,useSyncExternalStore:br,useId:br,unstable_isNewReconciler:!1},t8={readContext:In,useCallback:function(e,t){return ui().memoizedState=[e,t===void 0?null:t],e},useContext:In,useEffect:vP,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,gd(4194308,4,qU.bind(null,t,e),r)},useLayoutEffect:function(e,t){return gd(4194308,4,e,t)},useInsertionEffect:function(e,t){return gd(4,2,e,t)},useMemo:function(e,t){var r=ui();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=ui();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=ZV.bind(null,bt,e),[n.memoizedState,e]},useRef:function(e){var t=ui();return e={current:e},t.memoizedState=e},useState:pP,useDebugValue:$T,useDeferredValue:function(e){return ui().memoizedState=e},useTransition:function(){var e=pP(!1),t=e[0];return e=XV.bind(null,e[1]),ui().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=bt,i=ui();if(gt){if(r===void 0)throw Error(X(407));r=r()}else{if(r=t(),ar===null)throw Error(X(349));Wo&30||$U(n,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,vP(NU.bind(null,n,a,e),[e]),n.flags|=2048,vc(9,DU.bind(null,n,a,r,t),void 0,null),r},useId:function(){var e=ui(),t=ar.identifierPrefix;if(gt){var r=Di,n=$i;r=(n&~(1<<32-Vn(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=hc++,0<\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=o.createElement(r,{is:n.is}):(e=o.createElement(r),r==="select"&&(o=e,n.multiple?o.multiple=!0:n.size&&(o.size=n.size))):e=o.createElementNS(e,r),e[di]=t,e[cc]=n,nB(e,t,!1,!1),t.stateNode=e;e:{switch(o=$E(r,n),r){case"dialog":ht("cancel",e),ht("close",e),i=n;break;case"iframe":case"object":case"embed":ht("load",e),i=n;break;case"video":case"audio":for(i=0;ipu&&(t.flags|=128,n=!0,ul(a,!1),t.lanes=4194304)}else{if(!n)if(e=ph(o),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),ul(a,!0),a.tail===null&&a.tailMode==="hidden"&&!o.alternate&&!gt)return Er(t),null}else 2*$t()-a.renderingStartTime>pu&&r!==1073741824&&(t.flags|=128,n=!0,ul(a,!1),t.lanes=4194304);a.isBackwards?(o.sibling=t.child,t.child=o):(r=a.last,r!==null?r.sibling=o:t.child=o,a.last=o)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=$t(),t.sibling=null,r=_t.current,ct(_t,n?r&1|2:r&1),t):(Er(t),null);case 22:case 23:return FT(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?nn&1073741824&&(Er(t),t.subtreeFlags&6&&(t.flags|=8192)):Er(t),null;case 24:return null;case 25:return null}throw Error(X(156,t.tag))}function l8(e,t){switch(_T(t),t.tag){case 1:return Jr(t.type)&&sh(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return du(),vt(Kr),vt(Or),OT(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return kT(t),null;case 13:if(vt(_t),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(X(340));cu()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return vt(_t),null;case 4:return du(),null;case 10:return ET(t.type._context),null;case 22:case 23:return FT(),null;case 24:return null;default:return null}}var Rf=!1,Tr=!1,c8=typeof WeakSet=="function"?WeakSet:Set,ce=null;function Ds(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Ot(e,t,n)}else r.current=null}function aw(e,t,r){try{r()}catch(n){Ot(e,t,n)}}var RP=!1;function f8(e,t){if(BE=nh,e=lU(),mT(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,a=n.focusNode;n=n.focusOffset;try{r.nodeType,a.nodeType}catch{r=null;break e}var o=0,s=-1,u=-1,l=0,c=0,f=e,d=null;t:for(;;){for(var h;f!==r||i!==0&&f.nodeType!==3||(s=o+i),f!==a||n!==0&&f.nodeType!==3||(u=o+n),f.nodeType===3&&(o+=f.nodeValue.length),(h=f.firstChild)!==null;)d=f,f=h;for(;;){if(f===e)break t;if(d===r&&++l===i&&(s=o),d===a&&++c===n&&(u=o),(h=f.nextSibling)!==null)break;f=d,d=f.parentNode}f=h}r=s===-1||u===-1?null:{start:s,end:u}}else r=null}r=r||{start:0,end:0}}else r=null;for(zE={focusedElem:e,selectionRange:r},nh=!1,ce=t;ce!==null;)if(t=ce,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,ce=e;else for(;ce!==null;){t=ce;try{var p=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(p!==null){var v=p.memoizedProps,_=p.memoizedState,m=t.stateNode,g=m.getSnapshotBeforeUpdate(t.elementType===t.type?v:Fn(t.type,v),_);m.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(X(163))}}catch(S){Ot(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,ce=e;break}ce=t.return}return p=RP,RP=!1,p}function jl(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var a=i.destroy;i.destroy=void 0,a!==void 0&&aw(t,r,a)}i=i.next}while(i!==n)}}function yp(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function ow(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function oB(e){var t=e.alternate;t!==null&&(e.alternate=null,oB(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[di],delete t[cc],delete t[GE],delete t[VV],delete t[YV])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function sB(e){return e.tag===5||e.tag===3||e.tag===4}function TP(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||sB(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function sw(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=oh));else if(n!==4&&(e=e.child,e!==null))for(sw(e,t,r),e=e.sibling;e!==null;)sw(e,t,r),e=e.sibling}function uw(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(uw(e,t,r),e=e.sibling;e!==null;)uw(e,t,r),e=e.sibling}var fr=null,qn=!1;function pa(e,t,r){for(r=r.child;r!==null;)uB(e,t,r),r=r.sibling}function uB(e,t,r){if(mi&&typeof mi.onCommitFiberUnmount=="function")try{mi.onCommitFiberUnmount(fp,r)}catch{}switch(r.tag){case 5:Tr||Ds(r,t);case 6:var n=fr,i=qn;fr=null,pa(e,t,r),fr=n,qn=i,fr!==null&&(qn?(e=fr,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):fr.removeChild(r.stateNode));break;case 18:fr!==null&&(qn?(e=fr,r=r.stateNode,e.nodeType===8?Em(e.parentNode,r):e.nodeType===1&&Em(e,r),ac(e)):Em(fr,r.stateNode));break;case 4:n=fr,i=qn,fr=r.stateNode.containerInfo,qn=!0,pa(e,t,r),fr=n,qn=i;break;case 0:case 11:case 14:case 15:if(!Tr&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var a=i,o=a.destroy;a=a.tag,o!==void 0&&(a&2||a&4)&&aw(r,t,o),i=i.next}while(i!==n)}pa(e,t,r);break;case 1:if(!Tr&&(Ds(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(s){Ot(r,t,s)}pa(e,t,r);break;case 21:pa(e,t,r);break;case 22:r.mode&1?(Tr=(n=Tr)||r.memoizedState!==null,pa(e,t,r),Tr=n):pa(e,t,r);break;default:pa(e,t,r)}}function kP(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new c8),t.forEach(function(n){var i=S8.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function Ln(e,t){var r=t.deletions;if(r!==null)for(var n=0;ni&&(i=o),n&=~a}if(n=i,n=$t()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*h8(n/1960))-n,10e?16:e,Na===null)var n=!1;else{if(e=Na,Na=null,yh=0,ze&6)throw Error(X(331));var i=ze;for(ze|=4,ce=e.current;ce!==null;){var a=ce,o=a.child;if(ce.flags&16){var s=a.deletions;if(s!==null){for(var u=0;u$t()-LT?Mo(e,0):AT|=r),Xr(e,t)}function mB(e,t){t===0&&(e.mode&1?(t=vf,vf<<=1,!(vf&130023424)&&(vf=4194304)):t=1);var r=jr();e=Vi(e,t),e!==null&&(Nc(e,t,r),Xr(e,r))}function y8(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),mB(e,r)}function S8(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(X(314))}n!==null&&n.delete(t),mB(e,r)}var gB;gB=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Kr.current)Qr=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Qr=!1,s8(e,t,r);Qr=!!(e.flags&131072)}else Qr=!1,gt&&t.flags&1048576&&SU(t,ch,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;_d(e,t),e=t.pendingProps;var i=lu(t,Or.current);Js(t,r),i=IT(null,t,n,e,i,r);var a=xT();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Jr(n)?(a=!0,uh(t)):a=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,RT(t),i.updater=gp,t.stateNode=i,i._reactInternals=t,XE(t,n,e,r),t=tw(null,t,n,!0,a,r)):(t.tag=0,gt&&a&&gT(t),Dr(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(_d(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=E8(n),e=Fn(n,e),i){case 0:t=ew(null,t,n,e,r);break e;case 1:t=bP(null,t,n,e,r);break e;case 11:t=yP(null,t,n,e,r);break e;case 14:t=SP(null,t,n,Fn(n.type,e),r);break e}throw Error(X(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Fn(n,i),ew(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Fn(n,i),bP(e,t,n,i,r);case 3:e:{if(eB(t),e===null)throw Error(X(387));n=t.pendingProps,a=t.memoizedState,i=a.element,RU(e,t),hh(t,n,null,r);var o=t.memoizedState;if(n=o.element,a.isDehydrated)if(a={element:n,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){i=hu(Error(X(423)),t),t=EP(e,t,n,r,i);break e}else if(n!==i){i=hu(Error(X(424)),t),t=EP(e,t,n,r,i);break e}else for(an=qa(t.stateNode.containerInfo.firstChild),on=t,gt=!0,Un=null,r=PU(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(cu(),n===i){t=Yi(e,t,r);break e}Dr(e,t,n,r)}t=t.child}return t;case 5:return IU(t),e===null&&QE(t),n=t.type,i=t.pendingProps,a=e!==null?e.memoizedProps:null,o=i.children,HE(n,i)?o=null:a!==null&&HE(n,a)&&(t.flags|=32),ZU(e,t),Dr(e,t,o,r),t.child;case 6:return e===null&&QE(t),null;case 13:return tB(e,t,r);case 4:return TT(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=fu(t,null,n,r):Dr(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Fn(n,i),yP(e,t,n,i,r);case 7:return Dr(e,t,t.pendingProps,r),t.child;case 8:return Dr(e,t,t.pendingProps.children,r),t.child;case 12:return Dr(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,a=t.memoizedProps,o=i.value,ct(fh,n._currentValue),n._currentValue=o,a!==null)if(Jn(a.value,o)){if(a.children===i.children&&!Kr.current){t=Yi(e,t,r);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var s=a.dependencies;if(s!==null){o=a.child;for(var u=s.firstContext;u!==null;){if(u.context===n){if(a.tag===1){u=Fi(-1,r&-r),u.tag=2;var l=a.updateQueue;if(l!==null){l=l.shared;var c=l.pending;c===null?u.next=u:(u.next=c.next,c.next=u),l.pending=u}}a.lanes|=r,u=a.alternate,u!==null&&(u.lanes|=r),KE(a.return,r,t),s.lanes|=r;break}u=u.next}}else if(a.tag===10)o=a.type===t.type?null:a.child;else if(a.tag===18){if(o=a.return,o===null)throw Error(X(341));o.lanes|=r,s=o.alternate,s!==null&&(s.lanes|=r),KE(o,r,t),o=a.sibling}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===t){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}Dr(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,Js(t,r),i=In(i),n=n(i),t.flags|=1,Dr(e,t,n,r),t.child;case 14:return n=t.type,i=Fn(n,t.pendingProps),i=Fn(n.type,i),SP(e,t,n,i,r);case 15:return JU(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Fn(n,i),_d(e,t),t.tag=1,Jr(n)?(e=!0,uh(t)):e=!1,Js(t,r),kU(t,n,i),XE(t,n,i,r),tw(null,t,n,!0,e,r);case 19:return rB(e,t,r);case 22:return XU(e,t,r)}throw Error(X(156,t.tag))};function _B(e,t){return Hq(e,t)}function b8(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Tn(e,t,r,n){return new b8(e,t,r,n)}function qT(e){return e=e.prototype,!(!e||!e.isReactComponent)}function E8(e){if(typeof e=="function")return qT(e)?1:0;if(e!=null){if(e=e.$$typeof,e===aT)return 11;if(e===oT)return 14}return 2}function Ha(e,t){var r=e.alternate;return r===null?(r=Tn(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function bd(e,t,r,n,i,a){var o=2;if(n=e,typeof e=="function")qT(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Rs:return Fo(r.children,i,a,t);case iT:o=8,i|=8;break;case EE:return e=Tn(12,r,t,i|2),e.elementType=EE,e.lanes=a,e;case wE:return e=Tn(13,r,t,i),e.elementType=wE,e.lanes=a,e;case RE:return e=Tn(19,r,t,i),e.elementType=RE,e.lanes=a,e;case Oq:return bp(r,i,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Tq:o=10;break e;case kq:o=9;break e;case aT:o=11;break e;case oT:o=14;break e;case ya:o=16,n=null;break e}throw Error(X(130,e==null?e:typeof e,""))}return t=Tn(o,r,t,i),t.elementType=e,t.type=n,t.lanes=a,t}function Fo(e,t,r,n){return e=Tn(7,e,n,t),e.lanes=r,e}function bp(e,t,r,n){return e=Tn(22,e,n,t),e.elementType=Oq,e.lanes=r,e.stateNode={isHidden:!1},e}function xm(e,t,r){return e=Tn(6,e,null,t),e.lanes=r,e}function Cm(e,t,r){return t=Tn(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function w8(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=fm(0),this.expirationTimes=fm(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=fm(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function UT(e,t,r,n,i,a,o,s,u){return e=new w8(e,t,r,s,u),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Tn(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},RT(a),e}function R8(e,t,r){var n=3"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(EB)}catch(e){console.error(e)}}EB(),Sq.exports=pn;var wB=Sq.exports;const QSe=$u(wB);var RB,TB,NP=wB;TB=NP.createRoot,RB=NP.hydrateRoot;const kB=Object.prototype.toString;function OB(e){switch(kB.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return Qi(e,Error)}}function Lu(e,t){return kB.call(e)===`[object ${t}]`}function WT(e){return Lu(e,"ErrorEvent")}function AP(e){return Lu(e,"DOMError")}function I8(e){return Lu(e,"DOMException")}function Ja(e){return Lu(e,"String")}function PB(e){return e===null||typeof e!="object"&&typeof e!="function"}function Xa(e){return Lu(e,"Object")}function kp(e){return typeof Event<"u"&&Qi(e,Event)}function x8(e){return typeof Element<"u"&&Qi(e,Element)}function C8(e){return Lu(e,"RegExp")}function Fc(e){return!!(e&&e.then&&typeof e.then=="function")}function $8(e){return Xa(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function IB(e){return typeof e=="number"&&e!==e}function Qi(e,t){try{return e instanceof t}catch{return!1}}function xB(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue))}function ji(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function LP(e,t){if(!Array.isArray(e))return"";const r=[];for(let n=0;nD8(e,n,r))}function N8(e,t,r=250,n,i,a,o){if(!a.exception||!a.exception.values||!o||!Qi(o.originalException,Error))return;const s=a.exception.values.length>0?a.exception.values[a.exception.values.length-1]:void 0;s&&(a.exception.values=A8(hw(e,t,i,o.originalException,n,a.exception.values,s,0),r))}function hw(e,t,r,n,i,a,o,s){if(a.length>=r+1)return a;let u=[...a];if(Qi(n[i],Error)){MP(o,s);const l=e(t,n[i]),c=u.length;FP(l,i,c,s),u=hw(e,t,r,n[i],i,[l,...u],l,c)}return Array.isArray(n.errors)&&n.errors.forEach((l,c)=>{if(Qi(l,Error)){MP(o,s);const f=e(t,l),d=u.length;FP(f,`errors[${c}]`,d,s),u=hw(e,t,r,l,i,[f,...u],f,d)}}),u}function MP(e,t){e.mechanism=e.mechanism||{type:"generic",handled:!0},e.mechanism={...e.mechanism,is_exception_group:!0,exception_id:t}}function FP(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}}function A8(e,t){return e.map(r=>(r.value&&(r.value=ji(r.value,t)),r))}function Of(e){return e&&e.Math==Math?e:void 0}const Ye=typeof globalThis=="object"&&Of(globalThis)||typeof window=="object"&&Of(window)||typeof self=="object"&&Of(self)||typeof global=="object"&&Of(global)||function(){return this}()||{};function jc(){return Ye}function Fu(e,t,r){const n=r||Ye,i=n.__SENTRY__=n.__SENTRY__||{};return i[e]||(i[e]=t())}const Ed=jc(),L8=80;function Za(e,t={}){if(!e)return"";try{let r=e;const n=5,i=[];let a=0,o=0;const s=" > ",u=s.length;let l;const c=Array.isArray(t)?t:t.keyAttrs,f=!Array.isArray(t)&&t.maxStringLength||L8;for(;r&&a++1&&o+i.length*u+l.length>=f));)i.push(l),o+=l.length,r=r.parentNode;return i.reverse().join(s)}catch{return""}}function M8(e,t){const r=e,n=[];let i,a,o,s,u;if(!r||!r.tagName)return"";n.push(r.tagName.toLowerCase());const l=t&&t.length?t.filter(f=>r.getAttribute(f)).map(f=>[f,r.getAttribute(f)]):null;if(l&&l.length)l.forEach(f=>{n.push(`[${f[0]}="${f[1]}"]`)});else if(r.id&&n.push(`#${r.id}`),i=r.className,i&&Ja(i))for(a=i.split(/\s+/),u=0;u{const a=Eh[i];r[i]=t[i],t[i]=a});try{return e()}finally{n.forEach(i=>{t[i]=r[i]})}}function U8(){let e=!1;const t={enable:()=>{e=!0},disable:()=>{e=!1},isEnabled:()=>e};return typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__?pw.forEach(r=>{t[r]=(...n)=>{e&&Op(()=>{Ye.console[r](`${q8}[${r}]:`,...n)})}}):pw.forEach(r=>{t[r]=()=>{}}),t}const q=U8(),B8=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function z8(e){return e==="http"||e==="https"}function Pp(e,t=!1){const{host:r,path:n,pass:i,port:a,projectId:o,protocol:s,publicKey:u}=e;return`${s}://${u}${t&&i?`:${i}`:""}@${r}${a?`:${a}`:""}/${n&&`${n}/`}${o}`}function H8(e){const t=B8.exec(e);if(!t){console.error(`Invalid Sentry Dsn: ${e}`);return}const[r,n,i="",a,o="",s]=t.slice(1);let u="",l=s;const c=l.split("/");if(c.length>1&&(u=c.slice(0,-1).join("/"),l=c.pop()),l){const f=l.match(/^\d+/);f&&(l=f[0])}return CB({host:a,pass:i,path:u,projectId:l,port:o,protocol:r,publicKey:n})}function CB(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function W8(e){if(!(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__))return!0;const{port:t,projectId:r,protocol:n}=e;return["protocol","publicKey","host","projectId"].find(o=>e[o]?!1:(q.error(`Invalid Sentry Dsn: ${o} missing`),!0))?!1:r.match(/^\d+$/)?z8(n)?t&&isNaN(parseInt(t,10))?(q.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(q.error(`Invalid Sentry Dsn: Invalid protocol ${n}`),!1):(q.error(`Invalid Sentry Dsn: Invalid projectId ${r}`),!1)}function G8(e){const t=typeof e=="string"?H8(e):CB(e);if(!(!t||!W8(t)))return t}class hi extends Error{constructor(t,r="warn"){super(t),this.message=t,this.name=new.target.prototype.constructor.name,Object.setPrototypeOf(this,new.target.prototype),this.logLevel=r}}function nr(e,t,r){if(!(t in e))return;const n=e[t],i=r(n);typeof i=="function"&&$B(i,n),e[t]=i}function gc(e,t,r){try{Object.defineProperty(e,t,{value:r,writable:!0,configurable:!0})}catch{(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function $B(e,t){try{const r=t.prototype||{};e.prototype=t.prototype=r,gc(e,"__sentry_original__",t)}catch{}}function GT(e){return e.__sentry_original__}function V8(e){return Object.keys(e).map(t=>`${encodeURIComponent(t)}=${encodeURIComponent(e[t])}`).join("&")}function DB(e){if(OB(e))return{message:e.message,name:e.name,stack:e.stack,...qP(e)};if(kp(e)){const t={type:e.type,target:jP(e.target),currentTarget:jP(e.currentTarget),...qP(e)};return typeof CustomEvent<"u"&&Qi(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function jP(e){try{return x8(e)?Za(e):Object.prototype.toString.call(e)}catch{return""}}function qP(e){if(typeof e=="object"&&e!==null){const t={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(t[r]=e[r]);return t}else return{}}function Y8(e,t=40){const r=Object.keys(DB(e));if(r.sort(),!r.length)return"[object has no keys]";if(r[0].length>=t)return ji(r[0],t);for(let n=r.length;n>0;n--){const i=r.slice(0,n).join(", ");if(!(i.length>t))return n===r.length?i:ji(i,t)}return""}function sn(e){return vw(e,new Map)}function vw(e,t){if(Xa(e)){const r=t.get(e);if(r!==void 0)return r;const n={};t.set(e,n);for(const i of Object.keys(e))typeof e[i]<"u"&&(n[i]=vw(e[i],t));return n}if(Array.isArray(e)){const r=t.get(e);if(r!==void 0)return r;const n=[];return t.set(e,n),e.forEach(i=>{n.push(vw(i,t))}),n}return e}function Qe(){const e=Ye,t=e.crypto||e.msCrypto;let r=()=>Math.random()*16;try{if(t&&t.randomUUID)return t.randomUUID().replace(/-/g,"");t&&t.getRandomValues&&(r=()=>t.getRandomValues(new Uint8Array(1))[0])}catch{}return([1e7]+1e3+4e3+8e3+1e11).replace(/[018]/g,n=>(n^(r()&15)>>n/4).toString(16))}function NB(e){return e.exception&&e.exception.values?e.exception.values[0]:void 0}function Ca(e){const{message:t,event_id:r}=e;if(t)return t;const n=NB(e);return n?n.type&&n.value?`${n.type}: ${n.value}`:n.type||n.value||r||"":r||""}function mw(e,t,r){const n=e.exception=e.exception||{},i=n.values=n.values||[],a=i[0]=i[0]||{};a.value||(a.value=t||""),a.type||(a.type=r||"Error")}function _c(e,t){const r=NB(e);if(!r)return;const n={type:"generic",handled:!0},i=r.mechanism;if(r.mechanism={...n,...i,...t},t&&"data"in t){const a={...i&&i.data,...t.data};r.mechanism.data=a}}function UP(e){if(e&&e.__sentry_captured__)return!0;try{gc(e,"__sentry_captured__",!0)}catch{}return!1}function Ip(e){return Array.isArray(e)?e:[e]}const AB=50,BP=/\(error: (.*)\)/,zP=/captureMessage|captureException/;function LB(...e){const t=e.sort((r,n)=>r[0]-n[0]).map(r=>r[1]);return(r,n=0)=>{const i=[],a=r.split(` `);for(let o=n;o1024)continue;const u=BP.test(s)?s.replace(BP,"$1"):s;if(!u.match(/\S*Error: /)){for(const l of t){const c=l(u);if(c){i.push(c);break}}if(i.length>=AB)break}}return K8(i)}}function Q8(e){return Array.isArray(e)?LB(...e):e}function K8(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(t[t.length-1].function||"")&&t.pop(),t.reverse(),zP.test(t[t.length-1].function||"")&&(t.pop(),zP.test(t[t.length-1].function||"")&&t.pop()),t.slice(0,AB).map(r=>({...r,filename:r.filename||t[t.length-1].filename,function:r.function||"?"}))}const $m="";function Ki(e){try{return!e||typeof e!="function"?$m:e.name||$m}catch{return $m}}const gw=jc();function MB(){if(!("fetch"in gw))return!1;try{return new Headers,new Request("http://www.example.com"),new Response,!0}catch{return!1}}function _w(e){return e&&/^function fetch\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function J8(){if(!MB())return!1;if(_w(gw.fetch))return!0;let e=!1;const t=gw.document;if(t&&typeof t.createElement=="function")try{const r=t.createElement("iframe");r.hidden=!0,t.head.appendChild(r),r.contentWindow&&r.contentWindow.fetch&&(e=_w(r.contentWindow.fetch)),t.head.removeChild(r)}catch(r){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return e}const Pf=jc();function X8(){const e=Pf.chrome,t=e&&e.app&&e.app.runtime,r="history"in Pf&&!!Pf.history.pushState&&!!Pf.history.replaceState;return!t&&r}const tr=jc(),Aa="__sentry_xhr_v2__",Bl={},HP={};function Z8(e){if(!HP[e])switch(HP[e]=!0,e){case"console":eY();break;case"dom":lY();break;case"xhr":nY();break;case"fetch":tY();break;case"history":iY();break;case"error":cY();break;case"unhandledrejection":fY();break;default:(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("unknown instrumentation type:",e);return}}function vr(e,t){Bl[e]=Bl[e]||[],Bl[e].push(t),Z8(e)}function Qn(e,t){if(!(!e||!Bl[e]))for(const r of Bl[e]||[])try{r(t)}catch(n){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error(`Error while triggering instrumentation handler. Type: ${e} Name: ${Ki(r)} Error:`,n)}}function eY(){"console"in Ye&&pw.forEach(function(e){e in Ye.console&&nr(Ye.console,e,function(t){return Eh[e]=t,function(...r){Qn("console",{args:r,level:e});const n=Eh[e];n&&n.apply(Ye.console,r)}})})}function tY(){J8()&&nr(Ye,"fetch",function(e){return function(...t){const{method:r,url:n}=rY(t),i={args:t,fetchData:{method:r,url:n},startTimestamp:Date.now()};return Qn("fetch",{...i}),e.apply(Ye,t).then(a=>(Qn("fetch",{...i,endTimestamp:Date.now(),response:a}),a),a=>{throw Qn("fetch",{...i,endTimestamp:Date.now(),error:a}),a})}})}function yw(e,t){return!!e&&typeof e=="object"&&!!e[t]}function WP(e){return typeof e=="string"?e:e?yw(e,"url")?e.url:e.toString?e.toString():"":""}function rY(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[r,n]=e;return{url:WP(r),method:yw(n,"method")?String(n.method).toUpperCase():"GET"}}const t=e[0];return{url:WP(t),method:yw(t,"method")?String(t.method).toUpperCase():"GET"}}function nY(){if(!tr.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;nr(e,"open",function(t){return function(...r){const n=Date.now(),i=r[1],a=this[Aa]={method:Ja(r[0])?r[0].toUpperCase():r[0],url:r[1],request_headers:{}};Ja(i)&&a.method==="POST"&&i.match(/sentry_key/)&&(this.__sentry_own_request__=!0);const o=()=>{const s=this[Aa];if(s&&this.readyState===4){try{s.status_code=this.status}catch{}Qn("xhr",{args:r,endTimestamp:Date.now(),startTimestamp:n,xhr:this})}};return"onreadystatechange"in this&&typeof this.onreadystatechange=="function"?nr(this,"onreadystatechange",function(s){return function(...u){return o(),s.apply(this,u)}}):this.addEventListener("readystatechange",o),nr(this,"setRequestHeader",function(s){return function(...u){const[l,c]=u,f=this[Aa];return f&&(f.request_headers[l.toLowerCase()]=c),s.apply(this,u)}}),t.apply(this,r)}}),nr(e,"send",function(t){return function(...r){const n=this[Aa];return n&&r[0]!==void 0&&(n.body=r[0]),Qn("xhr",{args:r,startTimestamp:Date.now(),xhr:this}),t.apply(this,r)}})}let If;function iY(){if(!X8())return;const e=tr.onpopstate;tr.onpopstate=function(...r){const n=tr.location.href,i=If;if(If=n,Qn("history",{from:i,to:n}),e)try{return e.apply(this,r)}catch{}};function t(r){return function(...n){const i=n.length>2?n[2]:void 0;if(i){const a=If,o=String(i);If=o,Qn("history",{from:a,to:o})}return r.apply(this,n)}}nr(tr.history,"pushState",t),nr(tr.history,"replaceState",t)}const aY=1e3;let GP,Sw,bw;function oY(e){if(e.type!==Sw)return!1;try{if(!e.target||e.target._sentryId!==bw)return!1}catch{}return!0}function sY(e,t){return e!=="keypress"?!1:!t||!t.tagName?!0:!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable)}function uY(e){try{return e.target}catch{return null}}function VP(e,t=!1){return r=>{if(!r||r._sentryCaptured)return;const n=uY(r);if(sY(r.type,n))return;gc(r,"_sentryCaptured",!0),n&&!n._sentryId&&gc(n,"_sentryId",Qe());const i=r.type==="keypress"?"input":r.type;oY(r)||(e({event:r,name:i,global:t}),Sw=r.type,bw=n?n._sentryId:void 0),clearTimeout(GP),GP=tr.setTimeout(()=>{bw=void 0,Sw=void 0},aY)}}function lY(){if(!tr.document)return;const e=Qn.bind(null,"dom"),t=VP(e,!0);tr.document.addEventListener("click",t,!1),tr.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(r=>{const n=tr[r]&&tr[r].prototype;!n||!n.hasOwnProperty||!n.hasOwnProperty("addEventListener")||(nr(n,"addEventListener",function(i){return function(a,o,s){if(a==="click"||a=="keypress")try{const u=this,l=u.__sentry_instrumentation_handlers__=u.__sentry_instrumentation_handlers__||{},c=l[a]=l[a]||{refCount:0};if(!c.handler){const f=VP(e);c.handler=f,i.call(this,a,f,s)}c.refCount++}catch{}return i.call(this,a,o,s)}}),nr(n,"removeEventListener",function(i){return function(a,o,s){if(a==="click"||a=="keypress")try{const u=this,l=u.__sentry_instrumentation_handlers__||{},c=l[a];c&&(c.refCount--,c.refCount<=0&&(i.call(this,a,c.handler,s),c.handler=void 0,delete l[a]),Object.keys(l).length===0&&delete u.__sentry_instrumentation_handlers__)}catch{}return i.call(this,a,o,s)}}))})}let xf=null;function cY(){xf=tr.onerror,tr.onerror=function(e,t,r,n,i){return Qn("error",{column:n,error:i,line:r,msg:e,url:t}),xf&&!xf.__SENTRY_LOADER__?xf.apply(this,arguments):!1},tr.onerror.__SENTRY_INSTRUMENTED__=!0}let Cf=null;function fY(){Cf=tr.onunhandledrejection,tr.onunhandledrejection=function(e){return Qn("unhandledrejection",e),Cf&&!Cf.__SENTRY_LOADER__?Cf.apply(this,arguments):!0},tr.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}function dY(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function hY(){return"npm"}function FB(){return!dY()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function pY(e,t){return e.require(t)}function YP(){return typeof window<"u"&&(!FB()||vY())}function vY(){return Ye.process!==void 0&&Ye.process.type==="renderer"}function mY(){const e=typeof WeakSet=="function",t=e?new WeakSet:[];function r(i){if(e)return t.has(i)?!0:(t.add(i),!1);for(let a=0;ar?jB(e,t-1,r):n}function Ew(e,t,r=1/0,n=1/0,i=mY()){const[a,o]=i;if(t==null||["number","boolean","string"].includes(typeof t)&&!IB(t))return t;const s=gY(e,t);if(!s.startsWith("[object "))return s;if(t.__sentry_skip_normalization__)return t;const u=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:r;if(u===0)return s.replace("object ","");if(a(t))return"[Circular ~]";const l=t;if(l&&typeof l.toJSON=="function")try{const h=l.toJSON();return Ew("",h,u-1,n,i)}catch{}const c=Array.isArray(t)?[]:{};let f=0;const d=DB(t);for(const h in d){if(!Object.prototype.hasOwnProperty.call(d,h))continue;if(f>=n){c[h]="[MaxProperties ~]";break}const p=d[h];c[h]=Ew(h,p,u-1,n,i),f++}return o(t),c}function gY(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(xB(t))return"[VueViewModel]";if($8(t))return"[SyntheticEvent]";if(typeof t=="number"&&t!==t)return"[NaN]";if(typeof t=="function")return`[Function: ${Ki(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const r=_Y(t);return/^HTML(\w*)Element$/.test(r)?`[HTMLElement: ${r}]`:`[object ${r}]`}catch(r){return`**non-serializable** (${r})`}}function _Y(e){const t=Object.getPrototypeOf(e);return t?t.constructor.name:"null prototype"}function yY(e){return~-encodeURI(e).split(/%..|./).length}function SY(e){return yY(JSON.stringify(e))}var Ii;(function(e){e[e.PENDING=0]="PENDING";const r=1;e[e.RESOLVED=r]="RESOLVED";const n=2;e[e.REJECTED=n]="REJECTED"})(Ii||(Ii={}));function eo(e){return new Ar(t=>{t(e)})}function VT(e){return new Ar((t,r)=>{r(e)})}class Ar{constructor(t){Ar.prototype.__init.call(this),Ar.prototype.__init2.call(this),Ar.prototype.__init3.call(this),Ar.prototype.__init4.call(this),this._state=Ii.PENDING,this._handlers=[];try{t(this._resolve,this._reject)}catch(r){this._reject(r)}}then(t,r){return new Ar((n,i)=>{this._handlers.push([!1,a=>{if(!t)n(a);else try{n(t(a))}catch(o){i(o)}},a=>{if(!r)i(a);else try{n(r(a))}catch(o){i(o)}}]),this._executeHandlers()})}catch(t){return this.then(r=>r,t)}finally(t){return new Ar((r,n)=>{let i,a;return this.then(o=>{a=!1,i=o,t&&t()},o=>{a=!0,i=o,t&&t()}).then(()=>{if(a){n(i);return}r(i)})})}__init(){this._resolve=t=>{this._setResult(Ii.RESOLVED,t)}}__init2(){this._reject=t=>{this._setResult(Ii.REJECTED,t)}}__init3(){this._setResult=(t,r)=>{if(this._state===Ii.PENDING){if(Fc(r)){r.then(this._resolve,this._reject);return}this._state=t,this._value=r,this._executeHandlers()}}}__init4(){this._executeHandlers=()=>{if(this._state===Ii.PENDING)return;const t=this._handlers.slice();this._handlers=[],t.forEach(r=>{r[0]||(this._state===Ii.RESOLVED&&r[1](this._value),this._state===Ii.REJECTED&&r[2](this._value),r[0]=!0)})}}}function bY(e){const t=[];function r(){return e===void 0||t.lengthn(s)).then(null,()=>n(s).then(null,()=>{})),s}function a(o){return new Ar((s,u)=>{let l=t.length;if(!l)return s(!0);const c=setTimeout(()=>{o&&o>0&&s(!1)},o);t.forEach(f=>{eo(f).then(()=>{--l||(clearTimeout(c),s(!0))},u)})})}return{$:t,add:i,drain:a}}function Dm(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const 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}}const EY=["fatal","error","warning","log","info","debug"];function wY(e){return e==="warn"?"warning":EY.includes(e)?e:"log"}const qB=jc(),ww={nowSeconds:()=>Date.now()/1e3};function RY(){const{performance:e}=qB;if(!e||!e.now)return;const t=Date.now()-e.now();return{now:()=>e.now(),timeOrigin:t}}function TY(){try{return pY(module,"perf_hooks").performance}catch{return}}const Nm=FB()?TY():RY(),QP=Nm===void 0?ww:{nowSeconds:()=>(Nm.timeOrigin+Nm.now())/1e3},sa=ww.nowSeconds.bind(ww),Xn=QP.nowSeconds.bind(QP),Zn=(()=>{const{performance:e}=qB;if(!e||!e.now)return;const t=3600*1e3,r=e.now(),n=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+r-n):t,a=i{const a=KP(i);return{...n,...a}},{});else{if(!e)return;t=KP(e)}const r=Object.entries(t).reduce((n,[i,a])=>{if(i.match(kY)){const o=i.slice(UB.length);n[o]=a}return n},{});if(Object.keys(r).length>0)return r}function Tw(e){if(!e)return;const t=Object.entries(e).reduce((r,[n,i])=>(i&&(r[`${UB}${n}`]=i),r),{});return IY(t)}function KP(e){return e.split(",").map(t=>t.split("=").map(r=>decodeURIComponent(r.trim()))).reduce((t,[r,n])=>(t[r]=n,t),{})}function IY(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[r,n],i)=>{const a=`${encodeURIComponent(r)}=${encodeURIComponent(n)}`,o=i===0?a:`${t},${a}`;return o.length>OY?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Not adding key: ${r} with val: ${n} to baggage header due to exceeding baggage size limits.`),t):o},"")}const xY=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function CY(e){if(!e)return;const t=e.match(xY);if(!t)return;let r;return t[3]==="1"?r=!0:t[3]==="0"&&(r=!1),{traceId:t[1],parentSampled:r,parentSpanId:t[2]}}function $Y(e,t){const r=CY(e),n=PY(t),{traceId:i,parentSpanId:a,parentSampled:o}=r||{},s={traceId:i||Qe(),spanId:Qe().substring(16),sampled:o};return a&&(s.parentSpanId=a),n&&(s.dsc=n),{traceparentData:r,dynamicSamplingContext:n,propagationContext:s}}function YT(e=Qe(),t=Qe().substring(16),r){let n="";return r!==void 0&&(n=r?"-1":"-0"),`${e}-${t}${n}`}function ju(e,t=[]){return[e,t]}function DY(e,t){const[r,n]=e;return[r,[...n,t]]}function JP(e,t){const r=e[1];for(const n of r){const i=n[0].type;if(t(n,i))return!0}return!1}function kw(e,t){return(t||new TextEncoder).encode(e)}function NY(e,t){const[r,n]=e;let i=JSON.stringify(r);function a(o){typeof i=="string"?i=typeof o=="string"?i+o:[kw(i,t),o]:i.push(typeof o=="string"?kw(o,t):o)}for(const o of n){const[s,u]=o;if(a(` ${JSON.stringify(s)} `),typeof u=="string"||u instanceof Uint8Array)a(u);else{let l;try{l=JSON.stringify(u)}catch{l=JSON.stringify(kr(u))}a(l)}}return typeof i=="string"?i:AY(i)}function AY(e){const t=e.reduce((i,a)=>i+a.length,0),r=new Uint8Array(t);let n=0;for(const i of e)r.set(i,n),n+=i.length;return r}function LY(e,t){const r=typeof e.data=="string"?kw(e.data,t):e.data;return[sn({type:"attachment",length:r.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType}),r]}const MY={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",statsd:"unknown"};function XP(e){return MY[e]}function QT(e){if(!e||!e.sdk)return;const{name:t,version:r}=e.sdk;return{name:t,version:r}}function BB(e,t,r,n){const i=e.sdkProcessingMetadata&&e.sdkProcessingMetadata.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!r&&n&&{dsn:Pp(n)},...i&&{trace:sn({...i})}}}function FY(e,t,r){const n=[{type:"client_report"},{timestamp:r||sa(),discarded_events:e}];return ju(t?{dsn:t}:{},[n])}const jY=60*1e3;function qY(e,t=Date.now()){const r=parseInt(`${e}`,10);if(!isNaN(r))return r*1e3;const n=Date.parse(`${e}`);return isNaN(n)?jY:n-t}function UY(e,t){return e[t]||e.all||0}function zB(e,t,r=Date.now()){return UY(e,t)>r}function HB(e,{statusCode:t,headers:r},n=Date.now()){const i={...e},a=r&&r["x-sentry-rate-limits"],o=r&&r["retry-after"];if(a)for(const s of a.trim().split(",")){const[u,l]=s.split(":",2),c=parseInt(u,10),f=(isNaN(c)?60:c)*1e3;if(!l)i.all=n+f;else for(const d of l.split(";"))i[d]=n+f}else o?i.all=n+qY(o,n):t===429&&(i.all=n+60*1e3);return i}const KT="production";function JT(){return Fu("globalEventProcessors",()=>[])}function BY(e){JT().push(e)}function wh(e,t,r,n=0){return new Ar((i,a)=>{const o=e[n];if(t===null||typeof o!="function")i(t);else{const s=o({...t},r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&o.id&&s===null&&q.log(`Event processor "${o.id}" dropped event`),Fc(s)?s.then(u=>wh(e,u,r,n+1).then(i)).then(null,a):wh(e,s,r,n+1).then(i).then(null,a)}})}function zY(e){const t=Xn(),r={sid:Qe(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>WY(r)};return e&&vu(r,e),r}function vu(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||Xn(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:Qe()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r: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),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function HY(e,t){let r={};t?r={status:t}:e.status==="ok"&&(r={status:"exited"}),vu(e,r)}function WY(e){return sn({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}const GY=100;let Ow=class wd{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=ZP()}static clone(t){const r=new wd;return t&&(r._breadcrumbs=[...t._breadcrumbs],r._tags={...t._tags},r._extra={...t._extra},r._contexts={...t._contexts},r._user=t._user,r._level=t._level,r._span=t._span,r._session=t._session,r._transactionName=t._transactionName,r._fingerprint=t._fingerprint,r._eventProcessors=[...t._eventProcessors],r._requestSession=t._requestSession,r._attachments=[...t._attachments],r._sdkProcessingMetadata={...t._sdkProcessingMetadata},r._propagationContext={...t._propagationContext}),r}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{},this._session&&vu(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this._tags={...this._tags,[t]:r},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;if(typeof t=="function"){const r=t(this);return r instanceof wd?r:this}return t instanceof wd?(this._tags={...this._tags,...t._tags},this._extra={...this._extra,...t._extra},this._contexts={...this._contexts,...t._contexts},t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession),t._propagationContext&&(this._propagationContext=t._propagationContext)):Xa(t)&&(t=t,this._tags={...this._tags,...t.tags},this._extra={...this._extra,...t.extra},this._contexts={...this._contexts,...t.contexts},t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession),t.propagationContext&&(this._propagationContext=t.propagationContext)),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._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=ZP(),this}addBreadcrumb(t,r){const n=typeof r=="number"?r:GY;if(n<=0)return this;const i={timestamp:sa(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>n?a.slice(-n):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this._attachments}clearAttachments(){return this._attachments=[],this}applyToEvent(t,r={},n){if(this._extra&&Object.keys(this._extra).length&&(t.extra={...this._extra,...t.extra}),this._tags&&Object.keys(this._tags).length&&(t.tags={...this._tags,...t.tags}),this._user&&Object.keys(this._user).length&&(t.user={...this._user,...t.user}),this._contexts&&Object.keys(this._contexts).length&&(t.contexts={...this._contexts,...t.contexts}),this._level&&(t.level=this._level),this._transactionName&&(t.transaction=this._transactionName),this._span){t.contexts={trace:this._span.getTraceContext(),...t.contexts};const o=this._span.transaction;if(o){t.sdkProcessingMetadata={dynamicSamplingContext:o.getDynamicSamplingContext(),...t.sdkProcessingMetadata};const s=o.name;s&&(t.tags={transaction:s,...t.tags})}}this._applyFingerprint(t);const i=this._getBreadcrumbs(),a=[...t.breadcrumbs||[],...i];return t.breadcrumbs=a.length>0?a:void 0,t.sdkProcessingMetadata={...t.sdkProcessingMetadata,...this._sdkProcessingMetadata,propagationContext:this._propagationContext},wh([...n||[],...JT(),...this._eventProcessors],t,r)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}_getBreadcrumbs(){return this._breadcrumbs}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}_applyFingerprint(t){t.fingerprint=t.fingerprint?Ip(t.fingerprint):[],this._fingerprint&&(t.fingerprint=t.fingerprint.concat(this._fingerprint)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}};function ZP(){return{traceId:Qe(),spanId:Qe().substring(16)}}const WB=4,VY=100;let GB=class{constructor(t,r=new Ow,n=WB){this._version=n,this._stack=[{scope:r}],t&&this.bindClient(t)}isOlderThan(t){return this._version{a.captureException(t,{originalException:t,syntheticException:i,...r,event_id:n},o)}),n}captureMessage(t,r,n){const i=this._lastEventId=n&&n.event_id?n.event_id:Qe(),a=new Error(t);return this._withClient((o,s)=>{o.captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i},s)}),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:Qe();return t.type||(this._lastEventId=n),this._withClient((i,a)=>{i.captureEvent(t,{...r,event_id:n},a)}),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,r){const{scope:n,client:i}=this.getStackTop();if(!i)return;const{beforeBreadcrumb:a=null,maxBreadcrumbs:o=VY}=i.getOptions&&i.getOptions()||{};if(o<=0)return;const u={timestamp:sa(),...t},l=a?Op(()=>a(u,r)):u;l!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",l,r),n.addBreadcrumb(l,o))}setUser(t){this.getScope().setUser(t)}setTags(t){this.getScope().setTags(t)}setExtras(t){this.getScope().setExtras(t)}setTag(t,r){this.getScope().setTag(t,r)}setExtra(t,r){this.getScope().setExtra(t,r)}setContext(t,r){this.getScope().setContext(t,r)}configureScope(t){const{scope:r,client:n}=this.getStackTop();n&&t(r)}run(t){const r=eI(this);try{t(this)}finally{eI(r)}}getIntegration(t){const r=this.getClient();if(!r)return null;try{return r.getIntegration(t)}catch{return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,r){const n=this._callExtensionMethod("startTransaction",t,r);if((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&!n){const i=this.getClient();console.warn(i?`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init': Sentry.addTracingExtensions(); Sentry.init({...}); `:"Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")}return n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const r=this.getStackTop().scope,n=r.getSession();n&&HY(n),this._sendSessionUpdate(),r.setSession()}startSession(t){const{scope:r,client:n}=this.getStackTop(),{release:i,environment:a=KT}=n&&n.getOptions()||{},{userAgent:o}=Ye.navigator||{},s=zY({release:i,environment:a,user:r.getUser(),...o&&{userAgent:o},...t}),u=r.getSession&&r.getSession();return u&&u.status==="ok"&&vu(u,{status:"exited"}),this.endSession(),r.setSession(s),s}shouldSendDefaultPii(){const t=this.getClient(),r=t&&t.getOptions();return!!(r&&r.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:r}=this.getStackTop(),n=t.getSession();n&&r&&r.captureSession&&r.captureSession(n)}_withClient(t){const{scope:r,client:n}=this.getStackTop();n&&t(n,r)}_callExtensionMethod(t,...r){const i=xp().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Extension method ${t} couldn't be found, doing nothing.`)}};function xp(){return Ye.__SENTRY__=Ye.__SENTRY__||{extensions:{},hub:void 0},Ye}function eI(e){const t=xp(),r=Pw(t);return VB(t,e),r}function Pr(){const e=xp();if(e.__SENTRY__&&e.__SENTRY__.acs){const t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return YY(e)}function YY(e=xp()){return(!QY(e)||Pw(e).isOlderThan(WB))&&VB(e,new GB),Pw(e)}function QY(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Pw(e){return Fu("hub",()=>new GB,e)}function VB(e,t){if(!e)return!1;const r=e.__SENTRY__=e.__SENTRY__||{};return r.hub=t,!0}function KY(e,t,r){const n=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:a}=r&&r.getUser()||{},o=sn({environment:n.environment||KT,release:n.release,user_segment:a,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",o),o}function JY(e,t){return t&&(e.sdk=e.sdk||{},e.sdk.name=e.sdk.name||t.name,e.sdk.version=e.sdk.version||t.version,e.sdk.integrations=[...e.sdk.integrations||[],...t.integrations||[]],e.sdk.packages=[...e.sdk.packages||[],...t.packages||[]]),e}function XY(e,t,r,n){const i=QT(r),a={sent_at:new Date().toISOString(),...i&&{sdk:i},...!!n&&t&&{dsn:Pp(t)}},o="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return ju(a,[o])}function ZY(e,t,r,n){const i=QT(r),a=e.type&&e.type!=="replay_event"?e.type:"event";JY(e,r&&r.sdk);const o=BB(e,i,n,t);return delete e.sdkProcessingMetadata,ju(o,[[{type:a},e]])}function eQ(e,t){return Pr().captureException(e,{captureContext:t})}function tQ(e){Pr().withScope(e)}const rQ="7";function nQ(e){const t=e.protocol?`${e.protocol}:`:"",r=e.port?`:${e.port}`:"";return`${t}//${e.host}${r}${e.path?`/${e.path}`:""}/api/`}function iQ(e){return`${nQ(e)}${e.projectId}/envelope/`}function aQ(e,t){return V8({sentry_key:e.publicKey,sentry_version:rQ,...t&&{sentry_client:`${t.name}/${t.version}`}})}function oQ(e,t={}){const r=typeof t=="string"?t:t.tunnel,n=typeof t=="string"||!t._metadata?void 0:t._metadata.sdk;return r||`${iQ(e)}?${aQ(e,n)}`}const tI=[];function sQ(e){const t={};return e.forEach(r=>{const{name:n}=r,i=t[n];i&&!i.isDefaultInstance&&r.isDefaultInstance||(t[n]=r)}),Object.keys(t).map(r=>t[r])}function uQ(e){const t=e.defaultIntegrations||[],r=e.integrations;t.forEach(o=>{o.isDefaultInstance=!0});let n;Array.isArray(r)?n=[...t,...r]:typeof r=="function"?n=Ip(r(t)):n=t;const i=sQ(n),a=cQ(i,o=>o.name==="Debug");if(a!==-1){const[o]=i.splice(a,1);i.push(o)}return i}function lQ(e,t){const r={};return t.forEach(n=>{n&&YB(e,n,r)}),r}function YB(e,t,r){if(r[t.name]=t,tI.indexOf(t.name)===-1&&(t.setupOnce(BY,Pr),tI.push(t.name)),e.on&&typeof t.preprocessEvent=="function"){const n=t.preprocessEvent.bind(t);e.on("preprocessEvent",(i,a)=>n(i,a,e))}if(e.addEventProcessor&&typeof t.processEvent=="function"){const n=t.processEvent.bind(t),i=Object.assign((a,o)=>n(a,o,e),{id:t.name});e.addEventProcessor(i)}(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`Integration installed: ${t.name}`)}function cQ(e,t){for(let r=0;rd.name);dQ(s,e),vQ(s,u),t.type===void 0&&hQ(s,e.stackParser);let l=n;r.captureContext&&(l=Ow.clone(l).update(r.captureContext));let c=eo(s);const f=i&&i.getEventProcessors?i.getEventProcessors():[];if(l){if(l.getAttachments){const d=[...r.attachments||[],...l.getAttachments()];d.length&&(r.attachments=d)}c=l.applyToEvent(s,r,f)}else c=wh([...f,...JT()],s,r);return c.then(d=>(d&&pQ(d),typeof a=="number"&&a>0?mQ(d,a,o):d))}function dQ(e,t){const{environment:r,release:n,dist:i,maxValueLength:a=250}=t;"environment"in e||(e.environment="environment"in t?r:KT),e.release===void 0&&n!==void 0&&(e.release=n),e.dist===void 0&&i!==void 0&&(e.dist=i),e.message&&(e.message=ji(e.message,a));const o=e.exception&&e.exception.values&&e.exception.values[0];o&&o.value&&(o.value=ji(o.value,a));const s=e.request;s&&s.url&&(s.url=ji(s.url,a))}const rI=new WeakMap;function hQ(e,t){const r=Ye._sentryDebugIds;if(!r)return;let n;const i=rI.get(t);i?n=i:(n=new Map,rI.set(t,n));const a=Object.keys(r).reduce((o,s)=>{let u;const l=n.get(s);l?u=l:(u=t(s),n.set(s,u));for(let c=u.length-1;c>=0;c--){const f=u[c];if(f.filename){o[f.filename]=r[s];break}}return o},{});try{e.exception.values.forEach(o=>{o.stacktrace.frames.forEach(s=>{s.filename&&(s.debug_id=a[s.filename])})})}catch{}}function pQ(e){const t={};try{e.exception.values.forEach(n=>{n.stacktrace.frames.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const r=e.debug_meta.images;Object.keys(t).forEach(n=>{r.push({type:"sourcemap",code_file:n,debug_id:t[n]})})}function vQ(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function mQ(e,t,r){if(!e)return null;const n={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:kr(i.data,t,r)}}))},...e.user&&{user:kr(e.user,t,r)},...e.contexts&&{contexts:kr(e.contexts,t,r)},...e.extra&&{extra:kr(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=kr(e.contexts.trace.data,t,r))),e.spans&&(n.spans=e.spans.map(i=>(i.data&&(i.data=kr(i.data,t,r)),i))),n}const nI="Not capturing exception because it's already been captured.";class gQ{constructor(t){if(this._options=t,this._integrations={},this._integrationsInitialized=!1,this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],t.dsn?this._dsn=G8(t.dsn):(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("No DSN provided, client will not send events."),this._dsn){const r=oQ(this._dsn,t);this._transport=t.transport({recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:r})}}captureException(t,r,n){if(UP(t)){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(nI);return}let i=r&&r.event_id;return this._process(this.eventFromException(t,r).then(a=>this._captureEvent(a,r,n)).then(a=>{i=a})),i}captureMessage(t,r,n,i){let a=n&&n.event_id;const o=PB(t)?this.eventFromMessage(String(t),r,n):this.eventFromException(t,n);return this._process(o.then(s=>this._captureEvent(s,n,i)).then(s=>{a=s})),a}captureEvent(t,r,n){if(r&&r.originalException&&UP(r.originalException)){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(nI);return}let i=r&&r.event_id;return this._process(this._captureEvent(t,r,n).then(a=>{i=a})),i}captureSession(t){typeof t.release!="string"?(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Discarded session because of missing or non-string release"):(this.sendSession(t),vu(t,{init:!1}))}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}flush(t){const r=this._transport;return r?this._isClientDoneProcessing(t).then(n=>r.flush(t).then(i=>n&&i)):eo(!0)}close(t){return this.flush(t).then(r=>(this.getOptions().enabled=!1,r))}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}setupIntegrations(t){(t&&!this._integrationsInitialized||this._isEnabled()&&!this._integrationsInitialized)&&(this._integrations=lQ(this,this._options.integrations),this._integrationsInitialized=!0)}getIntegrationById(t){return this._integrations[t]}getIntegration(t){try{return this._integrations[t.id]||null}catch{return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Cannot retrieve integration ${t.id} from the current Client`),null}}addIntegration(t){YB(this,t,this._integrations)}sendEvent(t,r={}){this.emit("beforeSendEvent",t,r);let n=ZY(t,this._dsn,this._options._metadata,this._options.tunnel);for(const a of r.attachments||[])n=DY(n,LY(a,this._options.transportOptions&&this._options.transportOptions.textEncoder));const i=this._sendEnvelope(n);i&&i.then(a=>this.emit("afterSendEvent",t,a),null)}sendSession(t){const r=XY(t,this._dsn,this._options._metadata,this._options.tunnel);this._sendEnvelope(r)}recordDroppedEvent(t,r,n){if(this._options.sendClientReports){const i=`${t}:${r}`;(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`Adding outcome: "${i}"`),this._outcomes[i]=this._outcomes[i]+1||1}}on(t,r){this._hooks[t]||(this._hooks[t]=[]),this._hooks[t].push(r)}emit(t,...r){this._hooks[t]&&this._hooks[t].forEach(n=>n(...r))}_updateSessionFromEvent(t,r){let n=!1,i=!1;const a=r.exception&&r.exception.values;if(a){i=!0;for(const u of a){const l=u.mechanism;if(l&&l.handled===!1){n=!0;break}}}const o=t.status==="ok";(o&&t.errors===0||o&&n)&&(vu(t,{...n&&{status:"crashed"},errors:t.errors||Number(i||n)}),this.captureSession(t))}_isClientDoneProcessing(t){return new Ar(r=>{let n=0;const i=1,a=setInterval(()=>{this._numProcessing==0?(clearInterval(a),r(!0)):(n+=i,t&&n>=t&&(clearInterval(a),r(!1)))},i)})}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,r,n){const i=this.getOptions(),a=Object.keys(this._integrations);return!r.integrations&&a.length>0&&(r.integrations=a),this.emit("preprocessEvent",t,r),fQ(i,t,r,n,this).then(o=>{if(o===null)return o;const{propagationContext:s}=o.sdkProcessingMetadata||{};if(!(o.contexts&&o.contexts.trace)&&s){const{traceId:l,spanId:c,parentSpanId:f,dsc:d}=s;o.contexts={trace:{trace_id:l,span_id:c,parent_span_id:f},...o.contexts};const h=d||KY(l,this,n);o.sdkProcessingMetadata={dynamicSamplingContext:h,...o.sdkProcessingMetadata}}return o})}_captureEvent(t,r={},n){return this._processEvent(t,r,n).then(i=>i.event_id,i=>{if(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__){const a=i;a.logLevel==="log"?q.log(a.message):q.warn(a)}})}_processEvent(t,r,n){const i=this.getOptions(),{sampleRate:a}=i,o=KB(t),s=QB(t),u=t.type||"error",l=`before send for type \`${u}\``;if(s&&typeof a=="number"&&Math.random()>a)return this.recordDroppedEvent("sample_rate","error",t),VT(new hi(`Discarding event because it's not included in the random sample (sampling rate = ${a})`,"log"));const c=u==="replay_event"?"replay":u;return this._prepareEvent(t,r,n).then(f=>{if(f===null)throw this.recordDroppedEvent("event_processor",c,t),new hi("An event processor returned `null`, will not send event.","log");if(r.data&&r.data.__sentry__===!0)return f;const h=yQ(i,f,r);return _Q(h,l)}).then(f=>{if(f===null)throw this.recordDroppedEvent("before_send",c,t),new hi(`${l} returned \`null\`, will not send event.`,"log");const d=n&&n.getSession();!o&&d&&this._updateSessionFromEvent(d,f);const h=f.transaction_info;if(o&&h&&f.transaction!==t.transaction){const p="custom";f.transaction_info={...h,source:p}}return this.sendEvent(f,r),f}).then(null,f=>{throw f instanceof hi?f:(this.captureException(f,{data:{__sentry__:!0},originalException:f}),new hi(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. Reason: ${f}`))})}_process(t){this._numProcessing++,t.then(r=>(this._numProcessing--,r),r=>(this._numProcessing--,r))}_sendEnvelope(t){if(this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport)return this._transport.send(t).then(null,r=>{(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("Error while sending event:",r)});(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("Transport disabled")}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.keys(t).map(r=>{const[n,i]=r.split(":");return{reason:n,category:i,quantity:t[r]}})}}function _Q(e,t){const r=`${t} must return \`null\` or a valid event.`;if(Fc(e))return e.then(n=>{if(!Xa(n)&&n!==null)throw new hi(r);return n},n=>{throw new hi(`${t} rejected with ${n}`)});if(!Xa(e)&&e!==null)throw new hi(r);return e}function yQ(e,t,r){const{beforeSend:n,beforeSendTransaction:i}=e;return QB(t)&&n?n(t,r):KB(t)&&i?i(t,r):t}function QB(e){return e.type===void 0}function KB(e){return e.type==="transaction"}function SQ(e,t){t.debug===!0&&(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__?q.enable():console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle."));const r=Pr();r.getScope().update(t.initialScope);const i=new e(t);r.bindClient(i)}const bQ=30;function JB(e,t,r=bY(e.bufferSize||bQ)){let n={};const i=o=>r.drain(o);function a(o){const s=[];if(JP(o,(f,d)=>{const h=XP(d);if(zB(n,h)){const p=iI(f,d);e.recordDroppedEvent("ratelimit_backoff",h,p)}else s.push(f)}),s.length===0)return eo();const u=ju(o[0],s),l=f=>{JP(u,(d,h)=>{const p=iI(d,h);e.recordDroppedEvent(f,XP(h),p)})},c=()=>t({body:NY(u,e.textEncoder)}).then(f=>(f.statusCode!==void 0&&(f.statusCode<200||f.statusCode>=300)&&(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Sentry responded with status code ${f.statusCode} to sent event.`),n=HB(n,f),f),f=>{throw l("network_error"),f});return r.add(c).then(f=>f,f=>{if(f instanceof hi)return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("Skipped sending event because buffer is full."),l("queue_overflow"),eo();throw f})}return a.__sentry__baseTransport__=!0,{send:a,flush:i}}function iI(e,t){if(!(t!=="event"&&t!=="transaction"))return Array.isArray(e)?e[1]:void 0}const Rh="7.80.1";let aI;class Cp{static __initStatic(){this.id="FunctionToString"}constructor(){this.name=Cp.id}setupOnce(){aI=Function.prototype.toString;try{Function.prototype.toString=function(...t){const r=GT(this)||this;return aI.apply(r,t)}}catch{}}}Cp.__initStatic();const EQ=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/],wQ=[/^.*\/healthcheck$/,/^.*\/healthy$/,/^.*\/live$/,/^.*\/ready$/,/^.*\/heartbeat$/,/^.*\/health$/,/^.*\/healthz$/];class $p{static __initStatic(){this.id="InboundFilters"}constructor(t={}){this.name=$p.id,this._options=t}setupOnce(t,r){}processEvent(t,r,n){const i=n.getOptions(),a=RQ(this._options,i);return TQ(t,a)?null:t}}$p.__initStatic();function RQ(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:EQ],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[],...e.disableTransactionDefaults?[]:wQ],ignoreInternal:e.ignoreInternal!==void 0?e.ignoreInternal:!0}}function TQ(e,t){return t.ignoreInternal&&CQ(e)?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Event dropped due to being internal Sentry Error. Event: ${Ca(e)}`),!0):kQ(e,t.ignoreErrors)?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Event dropped due to being matched by \`ignoreErrors\` option. Event: ${Ca(e)}`),!0):OQ(e,t.ignoreTransactions)?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. Event: ${Ca(e)}`),!0):PQ(e,t.denyUrls)?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Event dropped due to being matched by \`denyUrls\` option. Event: ${Ca(e)}. Url: ${Th(e)}`),!0):IQ(e,t.allowUrls)?!1:((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Event dropped due to not being matched by \`allowUrls\` option. Event: ${Ca(e)}. Url: ${Th(e)}`),!0)}function kQ(e,t){return e.type||!t||!t.length?!1:xQ(e).some(r=>Mu(r,t))}function OQ(e,t){if(e.type!=="transaction"||!t||!t.length)return!1;const r=e.transaction;return r?Mu(r,t):!1}function PQ(e,t){if(!t||!t.length)return!1;const r=Th(e);return r?Mu(r,t):!1}function IQ(e,t){if(!t||!t.length)return!0;const r=Th(e);return r?Mu(r,t):!0}function xQ(e){const t=[];e.message&&t.push(e.message);let r;try{r=e.exception.values[e.exception.values.length-1]}catch{}return r&&r.value&&(t.push(r.value),r.type&&t.push(`${r.type}: ${r.value}`)),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&t.length===0&&q.error(`Could not extract message for event ${Ca(e)}`),t}function CQ(e){try{return e.exception.values[0].type==="SentryError"}catch{}return!1}function $Q(e=[]){for(let t=e.length-1;t>=0;t--){const r=e[t];if(r&&r.filename!==""&&r.filename!=="[native code]")return r.filename||null}return null}function Th(e){try{let t;try{t=e.exception.values[0].stacktrace.frames}catch{}return t?$Q(t):null}catch{return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error(`Cannot extract url for event ${Ca(e)}`),null}}const nt=Ye;let Iw=0;function XB(){return Iw>0}function DQ(){Iw++,setTimeout(()=>{Iw--})}function mu(e,t={},r){if(typeof e!="function")return e;try{const i=e.__sentry_wrapped__;if(i)return i;if(GT(e))return e}catch{return e}const n=function(){const i=Array.prototype.slice.call(arguments);try{r&&typeof r=="function"&&r.apply(this,arguments);const a=i.map(o=>mu(o,t));return e.apply(this,a)}catch(a){throw DQ(),tQ(o=>{o.addEventProcessor(s=>(t.mechanism&&(mw(s,void 0,void 0),_c(s,t.mechanism)),s.extra={...s.extra,arguments:i},s)),eQ(a)}),a}};try{for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&(n[i]=e[i])}catch{}$B(n,e),gc(e,"__sentry_wrapped__",n);try{Object.getOwnPropertyDescriptor(n,"name").configurable&&Object.defineProperty(n,"name",{get(){return e.name}})}catch{}return n}function ZB(e,t){const r=XT(e,t),n={type:t&&t.name,value:MQ(t)};return r.length&&(n.stacktrace={frames:r}),n.type===void 0&&n.value===""&&(n.value="Unrecoverable error caught"),n}function NQ(e,t,r,n){const a=Pr().getClient(),o=a&&a.getOptions().normalizeDepth,s={exception:{values:[{type:kp(t)?t.constructor.name:n?"UnhandledRejection":"Error",value:qQ(t,{isUnhandledRejection:n})}]},extra:{__serialized__:jB(t,o)}};if(r){const u=XT(e,r);u.length&&(s.exception.values[0].stacktrace={frames:u})}return s}function Am(e,t){return{exception:{values:[ZB(e,t)]}}}function XT(e,t){const r=t.stacktrace||t.stack||"",n=LQ(t);try{return e(r,n)}catch{}return[]}const AQ=/Minified React error #\d+;/i;function LQ(e){if(e){if(typeof e.framesToPop=="number")return e.framesToPop;if(AQ.test(e.message))return 1}return 0}function MQ(e){const t=e&&e.message;return t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function FQ(e,t,r,n){const i=r&&r.syntheticException||void 0,a=ZT(e,t,i,n);return _c(a),a.level="error",r&&r.event_id&&(a.event_id=r.event_id),eo(a)}function jQ(e,t,r="info",n,i){const a=n&&n.syntheticException||void 0,o=xw(e,t,a,i);return o.level=r,n&&n.event_id&&(o.event_id=n.event_id),eo(o)}function ZT(e,t,r,n,i){let a;if(WT(t)&&t.error)return Am(e,t.error);if(AP(t)||I8(t)){const o=t;if("stack"in t)a=Am(e,t);else{const s=o.name||(AP(o)?"DOMError":"DOMException"),u=o.message?`${s}: ${o.message}`:s;a=xw(e,u,r,n),mw(a,u)}return"code"in o&&(a.tags={...a.tags,"DOMException.code":`${o.code}`}),a}return OB(t)?Am(e,t):Xa(t)||kp(t)?(a=NQ(e,t,r,i),_c(a,{synthetic:!0}),a):(a=xw(e,t,r,n),mw(a,`${t}`,void 0),_c(a,{synthetic:!0}),a)}function xw(e,t,r,n){const i={message:t};if(n&&r){const a=XT(e,r);a.length&&(i.exception={values:[{value:t,stacktrace:{frames:a}}]})}return i}function qQ(e,{isUnhandledRejection:t}){const r=Y8(e),n=t?"promise rejection":"exception";return WT(e)?`Event \`ErrorEvent\` captured as ${n} with message \`${e.message}\``:kp(e)?`Event \`${UQ(e)}\` (type=${e.type}) captured as ${n}`:`Object captured as ${n} with keys: ${r}`}function UQ(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function BQ(e,{metadata:t,tunnel:r,dsn:n}){const i={event_id:e.event_id,sent_at:new Date().toISOString(),...t&&t.sdk&&{sdk:{name:t.sdk.name,version:t.sdk.version}},...!!r&&!!n&&{dsn:Pp(n)}},a=zQ(e);return ju(i,[a])}function zQ(e){return[{type:"user_report"},e]}class HQ extends gQ{constructor(t){const r=nt.SENTRY_SDK_SOURCE||hY();t._metadata=t._metadata||{},t._metadata.sdk=t._metadata.sdk||{name:"sentry.javascript.browser",packages:[{name:`${r}:@sentry/browser`,version:Rh}],version:Rh},super(t),t.sendClientReports&&nt.document&&nt.document.addEventListener("visibilitychange",()=>{nt.document.visibilityState==="hidden"&&this._flushOutcomes()})}eventFromException(t,r){return FQ(this._options.stackParser,t,r,this._options.attachStacktrace)}eventFromMessage(t,r="info",n){return jQ(this._options.stackParser,t,r,n,this._options.attachStacktrace)}captureUserFeedback(t){if(!this._isEnabled()){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("SDK not enabled, will not capture user feedback.");return}const r=BQ(t,{metadata:this.getSdkMetadata(),dsn:this.getDsn(),tunnel:this.getOptions().tunnel});this._sendEnvelope(r)}_prepareEvent(t,r,n){return t.platform=t.platform||"javascript",super._prepareEvent(t,r,n)}_flushOutcomes(){const t=this._clearOutcomes();if(t.length===0){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("No outcomes to send");return}if(!this._dsn){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("No dsn provided, will not send outcomes");return}(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("Sending outcomes:",t);const r=FY(t,this._options.tunnel&&Pp(this._dsn));this._sendEnvelope(r)}}let Il;function WQ(){if(Il)return Il;if(_w(nt.fetch))return Il=nt.fetch.bind(nt);const e=nt.document;let t=nt.fetch;if(e&&typeof e.createElement=="function")try{const r=e.createElement("iframe");r.hidden=!0,e.head.appendChild(r);const n=r.contentWindow;n&&n.fetch&&(t=n.fetch),e.head.removeChild(r)}catch(r){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",r)}return Il=t.bind(nt)}function GQ(){Il=void 0}function VQ(e,t=WQ()){let r=0,n=0;function i(a){const o=a.body.length;r+=o,n++;const s={body:a.body,method:"POST",referrerPolicy:"origin",headers:e.headers,keepalive:r<=6e4&&n<15,...e.fetchOptions};try{return t(e.url,s).then(u=>(r-=o,n--,{statusCode:u.status,headers:{"x-sentry-rate-limits":u.headers.get("X-Sentry-Rate-Limits"),"retry-after":u.headers.get("Retry-After")}}))}catch(u){return GQ(),r-=o,n--,VT(u)}}return JB(e,i)}const YQ=4;function QQ(e){function t(r){return new Ar((n,i)=>{const a=new XMLHttpRequest;a.onerror=i,a.onreadystatechange=()=>{a.readyState===YQ&&n({statusCode:a.status,headers:{"x-sentry-rate-limits":a.getResponseHeader("X-Sentry-Rate-Limits"),"retry-after":a.getResponseHeader("Retry-After")}})},a.open("POST",e.url);for(const o in e.headers)Object.prototype.hasOwnProperty.call(e.headers,o)&&a.setRequestHeader(o,e.headers[o]);a.send(r.body)})}return JB(e,t)}const Dp="?",KQ=30,JQ=40,XQ=50;function ek(e,t,r,n){const i={filename:e,function:t,in_app:!0};return r!==void 0&&(i.lineno=r),n!==void 0&&(i.colno=n),i}const ZQ=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,e9=/\((\S*)(?::(\d+))(?::(\d+))\)/,t9=e=>{const t=ZQ.exec(e);if(t){if(t[2]&&t[2].indexOf("eval")===0){const a=e9.exec(t[2]);a&&(t[2]=a[1],t[3]=a[2],t[4]=a[3])}const[n,i]=e3(t[1]||Dp,t[2]);return ek(i,n,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}},r9=[KQ,t9],n9=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,i9=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,a9=e=>{const t=n9.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const a=i9.exec(t[3]);a&&(t[1]=t[1]||"eval",t[3]=a[1],t[4]=a[2],t[5]="")}let n=t[3],i=t[1]||Dp;return[i,n]=e3(i,n),ek(n,i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},o9=[XQ,a9],s9=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,u9=e=>{const t=s9.exec(e);return t?ek(t[2],t[1]||Dp,+t[3],t[4]?+t[4]:void 0):void 0},l9=[JQ,u9],c9=[r9,o9,l9],f9=LB(...c9),e3=(e,t)=>{const r=e.indexOf("safari-extension")!==-1,n=e.indexOf("safari-web-extension")!==-1;return r||n?[e.indexOf("@")!==-1?e.split("@")[0]:Dp,r?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]};class qu{static __initStatic(){this.id="GlobalHandlers"}constructor(t){this.name=qu.id,this._options={onerror:!0,onunhandledrejection:!0,...t},this._installFunc={onerror:d9,onunhandledrejection:h9}}setupOnce(){Error.stackTraceLimit=50;const t=this._options;for(const r in t){const n=this._installFunc[r];n&&t[r]&&(m9(r),n(),this._installFunc[r]=void 0)}}}qu.__initStatic();function d9(){vr("error",e=>{const[t,r,n]=n3();if(!t.getIntegration(qu))return;const{msg:i,url:a,line:o,column:s,error:u}=e;if(XB()||u&&u.__sentry_own_request__)return;const l=u===void 0&&Ja(i)?v9(i,a,o,s):t3(ZT(r,u||i,void 0,n,!1),a,o,s);l.level="error",r3(t,u,l,"onerror")})}function h9(){vr("unhandledrejection",e=>{const[t,r,n]=n3();if(!t.getIntegration(qu))return;let i=e;try{"reason"in e?i=e.reason:"detail"in e&&"reason"in e.detail&&(i=e.detail.reason)}catch{}if(XB()||i&&i.__sentry_own_request__)return!0;const a=PB(i)?p9(i):ZT(r,i,void 0,n,!0);a.level="error",r3(t,i,a,"onunhandledrejection")})}function p9(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function v9(e,t,r,n){const i=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;let a=WT(e)?e.message:e,o="Error";const s=a.match(i);return s&&(o=s[1],a=s[2]),t3({exception:{values:[{type:o,value:a}]}},t,r,n)}function t3(e,t,r,n){const i=e.exception=e.exception||{},a=i.values=i.values||[],o=a[0]=a[0]||{},s=o.stacktrace=o.stacktrace||{},u=s.frames=s.frames||[],l=isNaN(parseInt(n,10))?void 0:n,c=isNaN(parseInt(r,10))?void 0:r,f=Ja(t)&&t.length>0?t:F8();return u.length===0&&u.push({colno:l,filename:f,function:"?",in_app:!0,lineno:c}),e}function m9(e){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`Global Handler attached: ${e}`)}function r3(e,t,r,n){_c(r,{handled:!1,type:n}),e.captureEvent(r,{originalException:t})}function n3(){const e=Pr(),t=e.getClient(),r=t&&t.getOptions()||{stackParser:()=>[],attachStacktrace:!1};return[e,r.stackParser,r.attachStacktrace]}const g9=["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"];class Np{static __initStatic(){this.id="TryCatch"}constructor(t){this.name=Np.id,this._options={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,...t}}setupOnce(){this._options.setTimeout&&nr(nt,"setTimeout",oI),this._options.setInterval&&nr(nt,"setInterval",oI),this._options.requestAnimationFrame&&nr(nt,"requestAnimationFrame",_9),this._options.XMLHttpRequest&&"XMLHttpRequest"in nt&&nr(XMLHttpRequest.prototype,"send",y9);const t=this._options.eventTarget;t&&(Array.isArray(t)?t:g9).forEach(S9)}}Np.__initStatic();function oI(e){return function(...t){const r=t[0];return t[0]=mu(r,{mechanism:{data:{function:Ki(e)},handled:!1,type:"instrument"}}),e.apply(this,t)}}function _9(e){return function(t){return e.apply(this,[mu(t,{mechanism:{data:{function:"requestAnimationFrame",handler:Ki(e)},handled:!1,type:"instrument"}})])}}function y9(e){return function(...t){const r=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in r&&typeof r[i]=="function"&&nr(r,i,function(a){const o={mechanism:{data:{function:i,handler:Ki(a)},handled:!1,type:"instrument"}},s=GT(a);return s&&(o.mechanism.data.handler=Ki(s)),mu(a,o)})}),e.apply(this,t)}}function S9(e){const t=nt,r=t[e]&&t[e].prototype;!r||!r.hasOwnProperty||!r.hasOwnProperty("addEventListener")||(nr(r,"addEventListener",function(n){return function(i,a,o){try{typeof a.handleEvent=="function"&&(a.handleEvent=mu(a.handleEvent,{mechanism:{data:{function:"handleEvent",handler:Ki(a),target:e},handled:!1,type:"instrument"}}))}catch{}return n.apply(this,[i,mu(a,{mechanism:{data:{function:"addEventListener",handler:Ki(a),target:e},handled:!1,type:"instrument"}}),o])}}),nr(r,"removeEventListener",function(n){return function(i,a,o){const s=a;try{const u=s&&s.__sentry_wrapped__;u&&n.call(this,i,u,o)}catch{}return n.call(this,i,s,o)}}))}const $f=1024;class Ap{static __initStatic(){this.id="Breadcrumbs"}constructor(t){this.name=Ap.id,this.options={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...t}}setupOnce(){if(this.options.console&&vr("console",w9),this.options.dom&&vr("dom",E9(this.options.dom)),this.options.xhr&&vr("xhr",R9),this.options.fetch&&vr("fetch",T9),this.options.history&&vr("history",k9),this.options.sentry){const t=Pr().getClient();t&&t.on&&t.on("beforeSendEvent",b9)}}}Ap.__initStatic();function b9(e){Pr().addBreadcrumb({category:`sentry.${e.type==="transaction"?"transaction":"event"}`,event_id:e.event_id,level:e.level,message:Ca(e)},{event:e})}function E9(e){function t(r){let n,i=typeof e=="object"?e.serializeAttribute:void 0,a=typeof e=="object"&&typeof e.maxStringLength=="number"?e.maxStringLength:void 0;a&&a>$f&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`\`dom.maxStringLength\` cannot exceed ${$f}, but a value of ${a} was configured. Sentry will use ${$f} instead.`),a=$f),typeof i=="string"&&(i=[i]);try{const o=r.event;n=O9(o)?Za(o.target,{keyAttrs:i,maxStringLength:a}):Za(o,{keyAttrs:i,maxStringLength:a})}catch{n=""}n.length!==0&&Pr().addBreadcrumb({category:`ui.${r.name}`,message:n},{event:r.event,name:r.name,global:r.global})}return t}function w9(e){const t={category:"console",data:{arguments:e.args,logger:"console"},level:wY(e.level),message:LP(e.args," ")};if(e.level==="assert")if(e.args[0]===!1)t.message=`Assertion failed: ${LP(e.args.slice(1)," ")||"console.assert"}`,t.data.arguments=e.args.slice(1);else return;Pr().addBreadcrumb(t,{input:e.args,level:e.level})}function R9(e){const{startTimestamp:t,endTimestamp:r}=e,n=e.xhr[Aa];if(!t||!r||!n)return;const{method:i,url:a,status_code:o,body:s}=n,u={method:i,url:a,status_code:o},l={xhr:e.xhr,input:s,startTimestamp:t,endTimestamp:r};Pr().addBreadcrumb({category:"xhr",data:u,type:"http"},l)}function T9(e){const{startTimestamp:t,endTimestamp:r}=e;if(r&&!(e.fetchData.url.match(/sentry_key/)&&e.fetchData.method==="POST"))if(e.error){const n=e.fetchData,i={data:e.error,input:e.args,startTimestamp:t,endTimestamp:r};Pr().addBreadcrumb({category:"fetch",data:n,level:"error",type:"http"},i)}else{const n={...e.fetchData,status_code:e.response&&e.response.status},i={input:e.args,response:e.response,startTimestamp:t,endTimestamp:r};Pr().addBreadcrumb({category:"fetch",data:n,type:"http"},i)}}function k9(e){let t=e.from,r=e.to;const n=Dm(nt.location.href);let i=Dm(t);const a=Dm(r);i.path||(i=n),n.protocol===a.protocol&&n.host===a.host&&(r=a.relative),n.protocol===i.protocol&&n.host===i.host&&(t=i.relative),Pr().addBreadcrumb({category:"navigation",data:{from:t,to:r}})}function O9(e){return!!e&&!!e.target}const P9="cause",I9=5;class Lp{static __initStatic(){this.id="LinkedErrors"}constructor(t={}){this.name=Lp.id,this._key=t.key||P9,this._limit=t.limit||I9}setupOnce(){}preprocessEvent(t,r,n){const i=n.getOptions();N8(ZB,i.stackParser,i.maxValueLength,this._key,this._limit,t,r)}}Lp.__initStatic();class Mp{static __initStatic(){this.id="HttpContext"}constructor(){this.name=Mp.id}setupOnce(){}preprocessEvent(t){if(!nt.navigator&&!nt.location&&!nt.document)return;const r=t.request&&t.request.url||nt.location&&nt.location.href,{referrer:n}=nt.document||{},{userAgent:i}=nt.navigator||{},a={...t.request&&t.request.headers,...n&&{Referer:n},...i&&{"User-Agent":i}},o={...t.request,...r&&{url:r},headers:a};t.request=o}}Mp.__initStatic();class Fp{static __initStatic(){this.id="Dedupe"}constructor(){this.name=Fp.id}setupOnce(t,r){}processEvent(t){if(t.type)return t;try{if(x9(t,this._previousEvent))return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return this._previousEvent=t}}Fp.__initStatic();function x9(e,t){return t?!!(C9(e,t)||$9(e,t)):!1}function C9(e,t){const r=e.message,n=t.message;return!(!r&&!n||r&&!n||!r&&n||r!==n||!a3(e,t)||!i3(e,t))}function $9(e,t){const r=sI(t),n=sI(e);return!(!r||!n||r.type!==n.type||r.value!==n.value||!a3(e,t)||!i3(e,t))}function i3(e,t){let r=uI(e),n=uI(t);if(!r&&!n)return!0;if(r&&!n||!r&&n||(r=r,n=n,n.length!==r.length))return!1;for(let i=0;i"u"){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Session tracking in non-browser environment with @sentry/browser is not supported.");return}const e=Pr();e.captureSession&&(lI(e),vr("history",({from:t,to:r})=>{t===void 0||t===r||lI(Pr())}))}const o3="production";function tk(){return Fu("globalEventProcessors",()=>[])}function L9(e){tk().push(e)}function kh(e,t,r,n=0){return new Ar((i,a)=>{const o=e[n];if(t===null||typeof o!="function")i(t);else{const s=o({...t},r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&o.id&&s===null&&q.log(`Event processor "${o.id}" dropped event`),Fc(s)?s.then(u=>kh(e,u,r,n+1).then(i)).then(null,a):kh(e,s,r,n+1).then(i).then(null,a)}})}function M9(e){const t=Xn(),r={sid:Qe(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>j9(r)};return e&&jp(r,e),r}function jp(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||Xn(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:Qe()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r: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),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function F9(e,t){let r={};t?r={status:t}:e.status==="ok"&&(r={status:"exited"}),jp(e,r)}function j9(e){return sn({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}const q9=100;let Cw=class Rd{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=cI()}static clone(t){const r=new Rd;return t&&(r._breadcrumbs=[...t._breadcrumbs],r._tags={...t._tags},r._extra={...t._extra},r._contexts={...t._contexts},r._user=t._user,r._level=t._level,r._span=t._span,r._session=t._session,r._transactionName=t._transactionName,r._fingerprint=t._fingerprint,r._eventProcessors=[...t._eventProcessors],r._requestSession=t._requestSession,r._attachments=[...t._attachments],r._sdkProcessingMetadata={...t._sdkProcessingMetadata},r._propagationContext={...t._propagationContext}),r}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{},this._session&&jp(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this._tags={...this._tags,[t]:r},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;if(typeof t=="function"){const r=t(this);return r instanceof Rd?r:this}return t instanceof Rd?(this._tags={...this._tags,...t._tags},this._extra={...this._extra,...t._extra},this._contexts={...this._contexts,...t._contexts},t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession),t._propagationContext&&(this._propagationContext=t._propagationContext)):Xa(t)&&(t=t,this._tags={...this._tags,...t.tags},this._extra={...this._extra,...t.extra},this._contexts={...this._contexts,...t.contexts},t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession),t.propagationContext&&(this._propagationContext=t.propagationContext)),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._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=cI(),this}addBreadcrumb(t,r){const n=typeof r=="number"?r:q9;if(n<=0)return this;const i={timestamp:sa(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>n?a.slice(-n):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this._attachments}clearAttachments(){return this._attachments=[],this}applyToEvent(t,r={},n){if(this._extra&&Object.keys(this._extra).length&&(t.extra={...this._extra,...t.extra}),this._tags&&Object.keys(this._tags).length&&(t.tags={...this._tags,...t.tags}),this._user&&Object.keys(this._user).length&&(t.user={...this._user,...t.user}),this._contexts&&Object.keys(this._contexts).length&&(t.contexts={...this._contexts,...t.contexts}),this._level&&(t.level=this._level),this._transactionName&&(t.transaction=this._transactionName),this._span){t.contexts={trace:this._span.getTraceContext(),...t.contexts};const o=this._span.transaction;if(o){t.sdkProcessingMetadata={dynamicSamplingContext:o.getDynamicSamplingContext(),...t.sdkProcessingMetadata};const s=o.name;s&&(t.tags={transaction:s,...t.tags})}}this._applyFingerprint(t);const i=this._getBreadcrumbs(),a=[...t.breadcrumbs||[],...i];return t.breadcrumbs=a.length>0?a:void 0,t.sdkProcessingMetadata={...t.sdkProcessingMetadata,...this._sdkProcessingMetadata,propagationContext:this._propagationContext},kh([...n||[],...tk(),...this._eventProcessors],t,r)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}_getBreadcrumbs(){return this._breadcrumbs}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}_applyFingerprint(t){t.fingerprint=t.fingerprint?Ip(t.fingerprint):[],this._fingerprint&&(t.fingerprint=t.fingerprint.concat(this._fingerprint)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}};function cI(){return{traceId:Qe(),spanId:Qe().substring(16)}}const s3=4,U9=100;let u3=class{constructor(t,r=new Cw,n=s3){this._version=n,this._stack=[{scope:r}],t&&this.bindClient(t)}isOlderThan(t){return this._version{a.captureException(t,{originalException:t,syntheticException:i,...r,event_id:n},o)}),n}captureMessage(t,r,n){const i=this._lastEventId=n&&n.event_id?n.event_id:Qe(),a=new Error(t);return this._withClient((o,s)=>{o.captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i},s)}),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:Qe();return t.type||(this._lastEventId=n),this._withClient((i,a)=>{i.captureEvent(t,{...r,event_id:n},a)}),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,r){const{scope:n,client:i}=this.getStackTop();if(!i)return;const{beforeBreadcrumb:a=null,maxBreadcrumbs:o=U9}=i.getOptions&&i.getOptions()||{};if(o<=0)return;const u={timestamp:sa(),...t},l=a?Op(()=>a(u,r)):u;l!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",l,r),n.addBreadcrumb(l,o))}setUser(t){this.getScope().setUser(t)}setTags(t){this.getScope().setTags(t)}setExtras(t){this.getScope().setExtras(t)}setTag(t,r){this.getScope().setTag(t,r)}setExtra(t,r){this.getScope().setExtra(t,r)}setContext(t,r){this.getScope().setContext(t,r)}configureScope(t){const{scope:r,client:n}=this.getStackTop();n&&t(r)}run(t){const r=fI(this);try{t(this)}finally{fI(r)}}getIntegration(t){const r=this.getClient();if(!r)return null;try{return r.getIntegration(t)}catch{return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,r){const n=this._callExtensionMethod("startTransaction",t,r);if((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&!n){const i=this.getClient();console.warn(i?`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init': Sentry.addTracingExtensions(); Sentry.init({...}); `:"Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")}return n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const r=this.getStackTop().scope,n=r.getSession();n&&F9(n),this._sendSessionUpdate(),r.setSession()}startSession(t){const{scope:r,client:n}=this.getStackTop(),{release:i,environment:a=o3}=n&&n.getOptions()||{},{userAgent:o}=Ye.navigator||{},s=M9({release:i,environment:a,user:r.getUser(),...o&&{userAgent:o},...t}),u=r.getSession&&r.getSession();return u&&u.status==="ok"&&jp(u,{status:"exited"}),this.endSession(),r.setSession(s),s}shouldSendDefaultPii(){const t=this.getClient(),r=t&&t.getOptions();return!!(r&&r.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:r}=this.getStackTop(),n=t.getSession();n&&r&&r.captureSession&&r.captureSession(n)}_withClient(t){const{scope:r,client:n}=this.getStackTop();n&&t(n,r)}_callExtensionMethod(t,...r){const i=qp().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Extension method ${t} couldn't be found, doing nothing.`)}};function qp(){return Ye.__SENTRY__=Ye.__SENTRY__||{extensions:{},hub:void 0},Ye}function fI(e){const t=qp(),r=$w(t);return l3(t,e),r}function dn(){const e=qp();if(e.__SENTRY__&&e.__SENTRY__.acs){const t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return B9(e)}function B9(e=qp()){return(!z9(e)||$w(e).isOlderThan(s3))&&l3(e,new u3),$w(e)}function z9(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function $w(e){return Fu("hub",()=>new u3,e)}function l3(e,t){if(!e)return!1;const r=e.__SENTRY__=e.__SENTRY__||{};return r.hub=t,!0}function c3(e,t){return dn().captureException(e,{captureContext:t})}function H9(e,t){dn().setContext(e,t)}function W9(e,t,r,n,i){const{normalizeDepth:a=3,normalizeMaxBreadth:o=1e3}=e,s={...t,event_id:t.event_id||r.event_id||Qe(),timestamp:t.timestamp||sa()},u=r.integrations||e.integrations.map(d=>d.name);G9(s,e),Q9(s,u),t.type===void 0&&V9(s,e.stackParser);let l=n;r.captureContext&&(l=Cw.clone(l).update(r.captureContext));let c=eo(s);const f=i&&i.getEventProcessors?i.getEventProcessors():[];if(l){if(l.getAttachments){const d=[...r.attachments||[],...l.getAttachments()];d.length&&(r.attachments=d)}c=l.applyToEvent(s,r,f)}else c=kh([...f,...tk()],s,r);return c.then(d=>(d&&Y9(d),typeof a=="number"&&a>0?K9(d,a,o):d))}function G9(e,t){const{environment:r,release:n,dist:i,maxValueLength:a=250}=t;"environment"in e||(e.environment="environment"in t?r:o3),e.release===void 0&&n!==void 0&&(e.release=n),e.dist===void 0&&i!==void 0&&(e.dist=i),e.message&&(e.message=ji(e.message,a));const o=e.exception&&e.exception.values&&e.exception.values[0];o&&o.value&&(o.value=ji(o.value,a));const s=e.request;s&&s.url&&(s.url=ji(s.url,a))}const dI=new WeakMap;function V9(e,t){const r=Ye._sentryDebugIds;if(!r)return;let n;const i=dI.get(t);i?n=i:(n=new Map,dI.set(t,n));const a=Object.keys(r).reduce((o,s)=>{let u;const l=n.get(s);l?u=l:(u=t(s),n.set(s,u));for(let c=u.length-1;c>=0;c--){const f=u[c];if(f.filename){o[f.filename]=r[s];break}}return o},{});try{e.exception.values.forEach(o=>{o.stacktrace.frames.forEach(s=>{s.filename&&(s.debug_id=a[s.filename])})})}catch{}}function Y9(e){const t={};try{e.exception.values.forEach(n=>{n.stacktrace.frames.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})})}catch{}if(Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const r=e.debug_meta.images;Object.keys(t).forEach(n=>{r.push({type:"sourcemap",code_file:n,debug_id:t[n]})})}function Q9(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function K9(e,t,r){if(!e)return null;const n={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:kr(i.data,t,r)}}))},...e.user&&{user:kr(e.user,t,r)},...e.contexts&&{contexts:kr(e.contexts,t,r)},...e.extra&&{extra:kr(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=kr(e.contexts.trace.data,t,r))),e.spans&&(n.spans=e.spans.map(i=>(i.data&&(i.data=kr(i.data,t,r)),i))),n}function J9(e,t){const r=t.getClient(),n=r&&r.getDsn(),i=r&&r.getOptions().tunnel;return Z9(e,n)||X9(e,i)}function X9(e,t){return t?hI(e)===hI(t):!1}function Z9(e,t){return t?e.includes(t.host):!1}function hI(e){return e[e.length-1]==="/"?e.slice(0,-1):e}const f3="production";function eK(){return Fu("globalEventProcessors",()=>[])}function Dw(e,t,r,n=0){return new Ar((i,a)=>{const o=e[n];if(t===null||typeof o!="function")i(t);else{const s=o({...t},r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&o.id&&s===null&&q.log(`Event processor "${o.id}" dropped event`),Fc(s)?s.then(u=>Dw(e,u,r,n+1).then(i)).then(null,a):Dw(e,s,r,n+1).then(i).then(null,a)}})}function tK(e){const t=Xn(),r={sid:Qe(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>nK(r)};return e&&Up(r,e),r}function Up(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||Xn(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:Qe()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r: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),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function rK(e,t){let r={};t?r={status:t}:e.status==="ok"&&(r={status:"exited"}),Up(e,r)}function nK(e){return sn({sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}})}const iK=100;class Zs{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext=pI()}static clone(t){const r=new Zs;return t&&(r._breadcrumbs=[...t._breadcrumbs],r._tags={...t._tags},r._extra={...t._extra},r._contexts={...t._contexts},r._user=t._user,r._level=t._level,r._span=t._span,r._session=t._session,r._transactionName=t._transactionName,r._fingerprint=t._fingerprint,r._eventProcessors=[...t._eventProcessors],r._requestSession=t._requestSession,r._attachments=[...t._attachments],r._sdkProcessingMetadata={...t._sdkProcessingMetadata},r._propagationContext={...t._propagationContext}),r}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{},this._session&&Up(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}getRequestSession(){return this._requestSession}setRequestSession(t){return this._requestSession=t,this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this._tags={...this._tags,[t]:r},this._notifyScopeListeners(),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSpan(t){return this._span=t,this._notifyScopeListeners(),this}getSpan(){return this._span}getTransaction(){const t=this.getSpan();return t&&t.transaction}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;if(typeof t=="function"){const r=t(this);return r instanceof Zs?r:this}return t instanceof Zs?(this._tags={...this._tags,...t._tags},this._extra={...this._extra,...t._extra},this._contexts={...this._contexts,...t._contexts},t._user&&Object.keys(t._user).length&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint),t._requestSession&&(this._requestSession=t._requestSession),t._propagationContext&&(this._propagationContext=t._propagationContext)):Xa(t)&&(t=t,this._tags={...this._tags,...t.tags},this._extra={...this._extra,...t.extra},this._contexts={...this._contexts,...t.contexts},t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint),t.requestSession&&(this._requestSession=t.requestSession),t.propagationContext&&(this._propagationContext=t.propagationContext)),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._span=void 0,this._session=void 0,this._notifyScopeListeners(),this._attachments=[],this._propagationContext=pI(),this}addBreadcrumb(t,r){const n=typeof r=="number"?r:iK;if(n<=0)return this;const i={timestamp:sa(),...t},a=this._breadcrumbs;return a.push(i),this._breadcrumbs=a.length>n?a.slice(-n):a,this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}getAttachments(){return this._attachments}clearAttachments(){return this._attachments=[],this}applyToEvent(t,r={},n){if(this._extra&&Object.keys(this._extra).length&&(t.extra={...this._extra,...t.extra}),this._tags&&Object.keys(this._tags).length&&(t.tags={...this._tags,...t.tags}),this._user&&Object.keys(this._user).length&&(t.user={...this._user,...t.user}),this._contexts&&Object.keys(this._contexts).length&&(t.contexts={...this._contexts,...t.contexts}),this._level&&(t.level=this._level),this._transactionName&&(t.transaction=this._transactionName),this._span){t.contexts={trace:this._span.getTraceContext(),...t.contexts};const o=this._span.transaction;if(o){t.sdkProcessingMetadata={dynamicSamplingContext:o.getDynamicSamplingContext(),...t.sdkProcessingMetadata};const s=o.name;s&&(t.tags={transaction:s,...t.tags})}}this._applyFingerprint(t);const i=this._getBreadcrumbs(),a=[...t.breadcrumbs||[],...i];return t.breadcrumbs=a.length>0?a:void 0,t.sdkProcessingMetadata={...t.sdkProcessingMetadata,...this._sdkProcessingMetadata,propagationContext:this._propagationContext},Dw([...n||[],...eK(),...this._eventProcessors],t,r)}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata={...this._sdkProcessingMetadata,...t},this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}_getBreadcrumbs(){return this._breadcrumbs}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}_applyFingerprint(t){t.fingerprint=t.fingerprint?Ip(t.fingerprint):[],this._fingerprint&&(t.fingerprint=t.fingerprint.concat(this._fingerprint)),t.fingerprint&&!t.fingerprint.length&&delete t.fingerprint}}function pI(){return{traceId:Qe(),spanId:Qe().substring(16)}}const d3=4,aK=100;class h3{constructor(t,r=new Zs,n=d3){this._version=n,this._stack=[{scope:r}],t&&this.bindClient(t)}isOlderThan(t){return this._version{a.captureException(t,{originalException:t,syntheticException:i,...r,event_id:n},o)}),n}captureMessage(t,r,n){const i=this._lastEventId=n&&n.event_id?n.event_id:Qe(),a=new Error(t);return this._withClient((o,s)=>{o.captureMessage(t,r,{originalException:t,syntheticException:a,...n,event_id:i},s)}),i}captureEvent(t,r){const n=r&&r.event_id?r.event_id:Qe();return t.type||(this._lastEventId=n),this._withClient((i,a)=>{i.captureEvent(t,{...r,event_id:n},a)}),n}lastEventId(){return this._lastEventId}addBreadcrumb(t,r){const{scope:n,client:i}=this.getStackTop();if(!i)return;const{beforeBreadcrumb:a=null,maxBreadcrumbs:o=aK}=i.getOptions&&i.getOptions()||{};if(o<=0)return;const u={timestamp:sa(),...t},l=a?Op(()=>a(u,r)):u;l!==null&&(i.emit&&i.emit("beforeAddBreadcrumb",l,r),n.addBreadcrumb(l,o))}setUser(t){this.getScope().setUser(t)}setTags(t){this.getScope().setTags(t)}setExtras(t){this.getScope().setExtras(t)}setTag(t,r){this.getScope().setTag(t,r)}setExtra(t,r){this.getScope().setExtra(t,r)}setContext(t,r){this.getScope().setContext(t,r)}configureScope(t){const{scope:r,client:n}=this.getStackTop();n&&t(r)}run(t){const r=vI(this);try{t(this)}finally{vI(r)}}getIntegration(t){const r=this.getClient();if(!r)return null;try{return r.getIntegration(t)}catch{return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Cannot retrieve integration ${t.id} from the current Hub`),null}}startTransaction(t,r){const n=this._callExtensionMethod("startTransaction",t,r);if((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&!n){const i=this.getClient();console.warn(i?`Tracing extension 'startTransaction' has not been added. Call 'addTracingExtensions' before calling 'init': Sentry.addTracingExtensions(); Sentry.init({...}); `:"Tracing extension 'startTransaction' is missing. You should 'init' the SDK before calling 'startTransaction'")}return n}traceHeaders(){return this._callExtensionMethod("traceHeaders")}captureSession(t=!1){if(t)return this.endSession();this._sendSessionUpdate()}endSession(){const r=this.getStackTop().scope,n=r.getSession();n&&rK(n),this._sendSessionUpdate(),r.setSession()}startSession(t){const{scope:r,client:n}=this.getStackTop(),{release:i,environment:a=f3}=n&&n.getOptions()||{},{userAgent:o}=Ye.navigator||{},s=tK({release:i,environment:a,user:r.getUser(),...o&&{userAgent:o},...t}),u=r.getSession&&r.getSession();return u&&u.status==="ok"&&Up(u,{status:"exited"}),this.endSession(),r.setSession(s),s}shouldSendDefaultPii(){const t=this.getClient(),r=t&&t.getOptions();return!!(r&&r.sendDefaultPii)}_sendSessionUpdate(){const{scope:t,client:r}=this.getStackTop(),n=t.getSession();n&&r&&r.captureSession&&r.captureSession(n)}_withClient(t){const{scope:r,client:n}=this.getStackTop();n&&t(n,r)}_callExtensionMethod(t,...r){const i=qc().__SENTRY__;if(i&&i.extensions&&typeof i.extensions[t]=="function")return i.extensions[t].apply(this,r);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`Extension method ${t} couldn't be found, doing nothing.`)}}function qc(){return Ye.__SENTRY__=Ye.__SENTRY__||{extensions:{},hub:void 0},Ye}function vI(e){const t=qc(),r=Nw(t);return p3(t,e),r}function gu(){const e=qc();if(e.__SENTRY__&&e.__SENTRY__.acs){const t=e.__SENTRY__.acs.getCurrentHub();if(t)return t}return oK(e)}function oK(e=qc()){return(!sK(e)||Nw(e).isOlderThan(d3))&&p3(e,new h3),Nw(e)}function sK(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function Nw(e){return Fu("hub",()=>new h3,e)}function p3(e,t){if(!e)return!1;const r=e.__SENTRY__=e.__SENTRY__||{};return r.hub=t,!0}function Uc(e){return(e||gu()).getScope().getTransaction()}let mI=!1;function uK(){mI||(mI=!0,vr("error",Aw),vr("unhandledrejection",Aw))}function Aw(){const e=Uc();if(e){const t="internal_error";(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Transaction: ${t} -> Global error occured`),e.setStatus(t)}}Aw.tag="sentry_tracingErrorCallback";class v3{constructor(t=1e3){this._maxlen=t,this.spans=[]}add(t){this.spans.length>this._maxlen?t.spanRecorder=void 0:this.spans.push(t)}}class rk{constructor(t={}){this.traceId=t.traceId||Qe(),this.spanId=t.spanId||Qe().substring(16),this.startTimestamp=t.startTimestamp||Xn(),this.tags=t.tags||{},this.data=t.data||{},this.instrumenter=t.instrumenter||"sentry",this.origin=t.origin||"manual",t.parentSpanId&&(this.parentSpanId=t.parentSpanId),"sampled"in t&&(this.sampled=t.sampled),t.op&&(this.op=t.op),t.description&&(this.description=t.description),t.name&&(this.description=t.name),t.status&&(this.status=t.status),t.endTimestamp&&(this.endTimestamp=t.endTimestamp)}get name(){return this.description||""}set name(t){this.setName(t)}startChild(t){const r=new rk({...t,parentSpanId:this.spanId,sampled:this.sampled,traceId:this.traceId});if(r.spanRecorder=this.spanRecorder,r.spanRecorder&&r.spanRecorder.add(r),r.transaction=this.transaction,(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&r.transaction){const n=t&&t.op||"< unknown op >",i=r.transaction.name||"< unknown name >",a=r.transaction.spanId,o=`[Tracing] Starting '${n}' span on transaction '${i}' (${a}).`;r.transaction.metadata.spanMetadata[r.spanId]={logMessage:o},q.log(o)}return r}setTag(t,r){return this.tags={...this.tags,[t]:r},this}setData(t,r){return this.data={...this.data,[t]:r},this}setStatus(t){return this.status=t,this}setHttpStatus(t){this.setTag("http.status_code",String(t)),this.setData("http.response.status_code",t);const r=lK(t);return r!=="unknown_error"&&this.setStatus(r),this}setName(t){this.description=t}isSuccess(){return this.status==="ok"}finish(t){if((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&this.transaction&&this.transaction.spanId!==this.spanId){const{logMessage:r}=this.transaction.metadata.spanMetadata[this.spanId];r&&q.log(r.replace("Starting","Finishing"))}this.endTimestamp=typeof t=="number"?t:Xn()}toTraceparent(){return YT(this.traceId,this.spanId,this.sampled)}toContext(){return sn({data:this.data,description:this.description,endTimestamp:this.endTimestamp,op:this.op,parentSpanId:this.parentSpanId,sampled:this.sampled,spanId:this.spanId,startTimestamp:this.startTimestamp,status:this.status,tags:this.tags,traceId:this.traceId})}updateWithContext(t){return this.data=t.data||{},this.description=t.description,this.endTimestamp=t.endTimestamp,this.op=t.op,this.parentSpanId=t.parentSpanId,this.sampled=t.sampled,this.spanId=t.spanId||this.spanId,this.startTimestamp=t.startTimestamp||this.startTimestamp,this.status=t.status,this.tags=t.tags||{},this.traceId=t.traceId||this.traceId,this}getTraceContext(){return sn({data:Object.keys(this.data).length>0?this.data:void 0,description:this.description,op:this.op,parent_span_id:this.parentSpanId,span_id:this.spanId,status:this.status,tags:Object.keys(this.tags).length>0?this.tags:void 0,trace_id:this.traceId,origin:this.origin})}toJSON(){return sn({data:Object.keys(this.data).length>0?this.data:void 0,description:this.description,op:this.op,parent_span_id:this.parentSpanId,span_id:this.spanId,start_timestamp:this.startTimestamp,status:this.status,tags:Object.keys(this.tags).length>0?this.tags:void 0,timestamp:this.endTimestamp,trace_id:this.traceId,origin:this.origin})}}function lK(e){if(e<400&&e>=100)return"ok";if(e>=400&&e<500)switch(e){case 401:return"unauthenticated";case 403:return"permission_denied";case 404:return"not_found";case 409:return"already_exists";case 413:return"failed_precondition";case 429:return"resource_exhausted";default:return"invalid_argument"}if(e>=500&&e<600)switch(e){case 501:return"unimplemented";case 503:return"unavailable";case 504:return"deadline_exceeded";default:return"internal_error"}return"unknown_error"}function nk(e,t,r){const n=t.getOptions(),{publicKey:i}=t.getDsn()||{},{segment:a}=r&&r.getUser()||{},o=sn({environment:n.environment||f3,release:n.release,user_segment:a,public_key:i,trace_id:e});return t.emit&&t.emit("createDsc",o),o}class m3 extends rk{constructor(t,r){super(t),delete this.description,this._measurements={},this._contexts={},this._hub=r||gu(),this._name=t.name||"",this.metadata={source:"custom",...t.metadata,spanMetadata:{}},this._trimEnd=t.trimEnd,this.transaction=this;const n=this.metadata.dynamicSamplingContext;n&&(this._frozenDynamicSamplingContext={...n})}get name(){return this._name}set name(t){this.setName(t)}setName(t,r="custom"){this._name=t,this.metadata.source=r}initSpanRecorder(t=1e3){this.spanRecorder||(this.spanRecorder=new v3(t)),this.spanRecorder.add(this)}setContext(t,r){r===null?delete this._contexts[t]:this._contexts[t]=r}setMeasurement(t,r,n=""){this._measurements[t]={value:r,unit:n}}setMetadata(t){this.metadata={...this.metadata,...t}}finish(t){const r=this._finishTransaction(t);if(r)return this._hub.captureEvent(r)}toContext(){const t=super.toContext();return sn({...t,name:this.name,trimEnd:this._trimEnd})}updateWithContext(t){return super.updateWithContext(t),this.name=t.name||"",this._trimEnd=t.trimEnd,this}getDynamicSamplingContext(){if(this._frozenDynamicSamplingContext)return this._frozenDynamicSamplingContext;const t=this._hub||gu(),r=t.getClient();if(!r)return{};const n=t.getScope(),i=nk(this.traceId,r,n),a=this.metadata.sampleRate;a!==void 0&&(i.sample_rate=`${a}`);const o=this.metadata.source;return o&&o!=="url"&&(i.transaction=this.name),this.sampled!==void 0&&(i.sampled=String(this.sampled)),i}setHub(t){this._hub=t}_finishTransaction(t){if(this.endTimestamp!==void 0)return;this.name||((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Transaction has no name, falling back to ``."),this.name=""),super.finish(t);const r=this._hub.getClient();if(r&&r.emit&&r.emit("finishTransaction",this),this.sampled!==!0){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] Discarding transaction because its trace was not chosen to be sampled."),r&&r.recordDroppedEvent("sample_rate","transaction");return}const n=this.spanRecorder?this.spanRecorder.spans.filter(s=>s!==this&&s.endTimestamp):[];this._trimEnd&&n.length>0&&(this.endTimestamp=n.reduce((s,u)=>s.endTimestamp&&u.endTimestamp?s.endTimestamp>u.endTimestamp?s:u:s).endTimestamp);const i=this.metadata,a={contexts:{...this._contexts,trace:this.getTraceContext()},spans:n,start_timestamp:this.startTimestamp,tags:this.tags,timestamp:this.endTimestamp,transaction:this.name,type:"transaction",sdkProcessingMetadata:{...i,dynamicSamplingContext:this.getDynamicSamplingContext()},...i.source&&{transaction_info:{source:i.source}}};return Object.keys(this._measurements).length>0&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding measurements to transaction",JSON.stringify(this._measurements,void 0,2)),a.measurements=this._measurements),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Finishing ${this.op} transaction: ${this.name}.`),a}}const Td={idleTimeout:1e3,finalTimeout:3e4,heartbeatInterval:5e3},cK="finishReason",hs=["heartbeatFailed","idleTimeout","documentHidden","finalTimeout","externalFinish","cancelled"];class fK extends v3{constructor(t,r,n,i){super(i),this._pushActivity=t,this._popActivity=r,this.transactionSpanId=n}add(t){t.spanId!==this.transactionSpanId&&(t.finish=r=>{t.endTimestamp=typeof r=="number"?r:Xn(),this._popActivity(t.spanId)},t.endTimestamp===void 0&&this._pushActivity(t.spanId)),super.add(t)}}class dK extends m3{constructor(t,r,n=Td.idleTimeout,i=Td.finalTimeout,a=Td.heartbeatInterval,o=!1){super(t,r),this._idleHub=r,this._idleTimeout=n,this._finalTimeout=i,this._heartbeatInterval=a,this._onScope=o,this.activities={},this._heartbeatCounter=0,this._finished=!1,this._idleTimeoutCanceledPermanently=!1,this._beforeFinishCallbacks=[],this._finishReason=hs[4],o&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`Setting idle transaction on scope. Span ID: ${this.spanId}`),r.configureScope(s=>s.setSpan(this))),this._restartIdleTimeout(),setTimeout(()=>{this._finished||(this.setStatus("deadline_exceeded"),this._finishReason=hs[3],this.finish())},this._finalTimeout)}finish(t=Xn()){if(this._finished=!0,this.activities={},this.op==="ui.action.click"&&this.setTag(cK,this._finishReason),this.spanRecorder){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] finishing IdleTransaction",new Date(t*1e3).toISOString(),this.op);for(const r of this._beforeFinishCallbacks)r(this,t);this.spanRecorder.spans=this.spanRecorder.spans.filter(r=>{if(r.spanId===this.spanId)return!0;r.endTimestamp||(r.endTimestamp=t,r.setStatus("cancelled"),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] cancelling span since transaction ended early",JSON.stringify(r,void 0,2)));const n=r.startTimestamp"u"||__SENTRY_DEBUG__){const o=JSON.stringify(r,void 0,2);n?a||q.log("[Tracing] discarding Span since it finished after Transaction final timeout",o):q.log("[Tracing] discarding Span since it happened after Transaction was finished",o)}return n&&a}),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] flushing IdleTransaction")}else(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] No active IdleTransaction");if(this._onScope){const r=this._idleHub.getScope();r.getTransaction()===this&&r.setSpan(void 0)}return super.finish(t)}registerBeforeFinishCallback(t){this._beforeFinishCallbacks.push(t)}initSpanRecorder(t){if(!this.spanRecorder){const r=i=>{this._finished||this._pushActivity(i)},n=i=>{this._finished||this._popActivity(i)};this.spanRecorder=new fK(r,n,this.spanId,t),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("Starting heartbeat"),this._pingHeartbeat()}this.spanRecorder.add(this)}cancelIdleTimeout(t,{restartOnChildSpanChange:r}={restartOnChildSpanChange:!0}){this._idleTimeoutCanceledPermanently=r===!1,this._idleTimeoutID&&(clearTimeout(this._idleTimeoutID),this._idleTimeoutID=void 0,Object.keys(this.activities).length===0&&this._idleTimeoutCanceledPermanently&&(this._finishReason=hs[5],this.finish(t)))}setFinishReason(t){this._finishReason=t}_restartIdleTimeout(t){this.cancelIdleTimeout(),this._idleTimeoutID=setTimeout(()=>{!this._finished&&Object.keys(this.activities).length===0&&(this._finishReason=hs[1],this.finish(t))},this._idleTimeout)}_pushActivity(t){this.cancelIdleTimeout(void 0,{restartOnChildSpanChange:!this._idleTimeoutCanceledPermanently}),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] pushActivity: ${t}`),this.activities[t]=!0,(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] new activities count",Object.keys(this.activities).length)}_popActivity(t){if(this.activities[t]&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] popActivity ${t}`),delete this.activities[t],(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] new activities count",Object.keys(this.activities).length)),Object.keys(this.activities).length===0){const r=Xn();this._idleTimeoutCanceledPermanently?(this._finishReason=hs[5],this.finish(r)):this._restartIdleTimeout(r+this._idleTimeout/1e3)}}_beat(){if(this._finished)return;const t=Object.keys(this.activities).join("");t===this._prevHeartbeatString?this._heartbeatCounter++:this._heartbeatCounter=1,this._prevHeartbeatString=t,this._heartbeatCounter>=3?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] Transaction finished because of no change for 3 heart beats"),this.setStatus("deadline_exceeded"),this._finishReason=hs[0],this.finish()):this._pingHeartbeat()}_pingHeartbeat(){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`pinging Heartbeat -> current counter: ${this._heartbeatCounter}`),setTimeout(()=>{this._beat()},this._heartbeatInterval)}}function ik(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=gu().getClient(),r=e||t&&t.getOptions();return!!r&&(r.enableTracing||"tracesSampleRate"in r||"tracesSampler"in r)}function g3(e,t,r){if(!ik(t))return e.sampled=!1,e;if(e.sampled!==void 0)return e.setMetadata({sampleRate:Number(e.sampled)}),e;let n;return typeof t.tracesSampler=="function"?(n=t.tracesSampler(r),e.setMetadata({sampleRate:Number(n)})):r.parentSampled!==void 0?n=r.parentSampled:typeof t.tracesSampleRate<"u"?(n=t.tracesSampleRate,e.setMetadata({sampleRate:Number(n)})):(n=1,e.setMetadata({sampleRate:n})),hK(n)?n?(e.sampled=Math.random()"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] starting ${e.op} transaction - ${e.name}`),e):((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(n)})`),e)):((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Discarding transaction because ${typeof t.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),e.sampled=!1,e):((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Tracing] Discarding transaction because of invalid sample rate."),e.sampled=!1,e)}function hK(e){return IB(e)||!(typeof e=="number"||typeof e=="boolean")?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.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)}.`),!1):e<0||e>1?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`[Tracing] Given sample rate is invalid. Sample rate must be between 0 and 1. Got ${e}.`),!1):!0}function pK(){const t=this.getScope().getSpan();return t?{"sentry-trace":t.toTraceparent()}:{}}function vK(e,t){const r=this.getClient(),n=r&&r.getOptions()||{},i=n.instrumenter||"sentry",a=e.instrumenter||"sentry";i!==a&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error(`A transaction was started with instrumenter=\`${a}\`, but the SDK is configured with the \`${i}\` instrumenter. The transaction will not be sampled. Please use the ${i} instrumentation to start transactions.`),e.sampled=!1);let o=new m3(e,this);return o=g3(o,n,{parentSampled:e.parentSampled,transactionContext:e,...t}),o.sampled&&o.initSpanRecorder(n._experiments&&n._experiments.maxSpans),r&&r.emit&&r.emit("startTransaction",o),o}function gI(e,t,r,n,i,a,o){const s=e.getClient(),u=s&&s.getOptions()||{};let l=new dK(t,e,r,n,o,i);return l=g3(l,u,{parentSampled:t.parentSampled,transactionContext:t,...a}),l.sampled&&l.initSpanRecorder(u._experiments&&u._experiments.maxSpans),s&&s.emit&&s.emit("startTransaction",l),l}function mK(){const e=qc();e.__SENTRY__&&(e.__SENTRY__.extensions=e.__SENTRY__.extensions||{},e.__SENTRY__.extensions.startTransaction||(e.__SENTRY__.extensions.startTransaction=vK),e.__SENTRY__.extensions.traceHeaders||(e.__SENTRY__.extensions.traceHeaders=pK),uK())}const at=Ye;function gK(){at&&at.document?at.document.addEventListener("visibilitychange",()=>{const e=Uc();if(at.document.hidden&&e){const t="cancelled";(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Transaction: ${t} -> since tab moved to the background, op: ${e.op}`),e.status||e.setStatus(t),e.setTag("visibilitychange","document.hidden"),e.finish()}}):(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const ak=(e,t,r)=>{let n,i;return a=>{t.value>=0&&(a||r)&&(i=t.value-(n||0),(i||n===void 0)&&(n=t.value,t.delta=i,e(t)))}},_K=()=>`v3-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,yK=()=>{const e=at.performance.timing,t=at.performance.navigation.type,r={entryType:"navigation",startTime:0,type:t==2?"back_forward":t===1?"reload":"navigate"};for(const n in e)n!=="navigationStart"&&n!=="toJSON"&&(r[n]=Math.max(e[n]-e.navigationStart,0));return r},_3=()=>at.__WEB_VITALS_POLYFILL__?at.performance&&(performance.getEntriesByType&&performance.getEntriesByType("navigation")[0]||yK()):at.performance&&performance.getEntriesByType&&performance.getEntriesByType("navigation")[0],y3=()=>{const e=_3();return e&&e.activationStart||0},ok=(e,t)=>{const r=_3();let n="navigate";return r&&(at.document.prerendering||y3()>0?n="prerender":n=r.type.replace(/_/g,"-")),{name:e,value:typeof t>"u"?-1:t,rating:"good",delta:0,entries:[],id:_K(),navigationType:n}},Bp=(e,t,r)=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const n=new PerformanceObserver(i=>{t(i.getEntries())});return n.observe(Object.assign({type:e,buffered:!0},r||{})),n}}catch{}},zp=(e,t)=>{const r=n=>{(n.type==="pagehide"||at.document.visibilityState==="hidden")&&(e(n),t&&(removeEventListener("visibilitychange",r,!0),removeEventListener("pagehide",r,!0)))};addEventListener("visibilitychange",r,!0),addEventListener("pagehide",r,!0)},SK=e=>{const t=ok("CLS",0);let r,n=0,i=[];const a=s=>{s.forEach(u=>{if(!u.hadRecentInput){const l=i[0],c=i[i.length-1];n&&i.length!==0&&u.startTime-c.startTime<1e3&&u.startTime-l.startTime<5e3?(n+=u.value,i.push(u)):(n=u.value,i=[u]),n>t.value&&(t.value=n,t.entries=i,r&&r())}})},o=Bp("layout-shift",a);if(o){r=ak(e,t);const s=()=>{a(o.takeRecords()),r(!0)};return zp(s),s}};let kd=-1;const bK=()=>at.document.visibilityState==="hidden"&&!at.document.prerendering?0:1/0,EK=()=>{zp(({timeStamp:e})=>{kd=e},!0)},sk=()=>(kd<0&&(kd=bK(),EK()),{get firstHiddenTime(){return kd}}),wK=e=>{const t=sk(),r=ok("FID");let n;const i=s=>{s.startTime{s.forEach(i)},o=Bp("first-input",a);n=ak(e,r),o&&zp(()=>{a(o.takeRecords()),o.disconnect()},!0)},_I={},RK=e=>{const t=sk(),r=ok("LCP");let n;const i=o=>{const s=o[o.length-1];if(s){const u=Math.max(s.startTime-y3(),0);u{_I[r.id]||(i(a.takeRecords()),a.disconnect(),_I[r.id]=!0,n(!0))};return["keydown","click"].forEach(s=>{addEventListener(s,o,{once:!0,capture:!0})}),zp(o,!0),o}},zl={},Oh={};let S3,b3,E3;function TK(e){return uk("cls",e,OK,S3)}function w3(e){return uk("lcp",e,IK,E3)}function kK(e){return uk("fid",e,PK,b3)}function Hp(e,t){return R3(e,t),Oh[e]||(xK(e),Oh[e]=!0),T3(e,t)}function Wp(e,t){const r=zl[e];if(!(!r||!r.length))for(const n of r)try{n(t)}catch(i){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error(`Error while triggering instrumentation handler. Type: ${e} Name: ${Ki(n)} Error:`,i)}}function OK(){SK(e=>{Wp("cls",{metric:e}),S3=e})}function PK(){wK(e=>{Wp("fid",{metric:e}),b3=e})}function IK(){RK(e=>{Wp("lcp",{metric:e}),E3=e})}function uk(e,t,r,n){return R3(e,t),Oh[e]||(r(),Oh[e]=!0),n&&t({metric:n}),T3(e,t)}function xK(e){const t={};e==="event"&&(t.durationThreshold=0),Bp(e,r=>{Wp(e,{entries:r})},t)}function R3(e,t){zl[e]=zl[e]||[],zl[e].push(t)}function T3(e,t){return()=>{const r=zl[e];if(!r)return;const n=r.indexOf(t);n!==-1&&r.splice(n,1)}}function Lm(e){return typeof e=="number"&&isFinite(e)}function _u(e,{startTimestamp:t,...r}){return t&&e.startTimestamp>t&&(e.startTimestamp=t),e.startChild({startTimestamp:t,...r})}function zt(e){return e/1e3}function k3(){return at&&at.addEventListener&&at.performance}let yI=0,kt={},li,Hl;function CK(){const e=k3();if(e&&Zn){e.mark&&at.performance.mark("sentry-tracing-init");const t=LK(),r=NK(),n=AK();return()=>{t(),r(),n()}}return()=>{}}function $K(){Hp("longtask",({entries:e})=>{for(const t of e){const r=Uc();if(!r)return;const n=zt(Zn+t.startTime),i=zt(t.duration);r.startChild({description:"Main UI thread blocked",op:"ui.long-task",origin:"auto.ui.browser.metrics",startTimestamp:n,endTimestamp:n+i})}})}function DK(){Hp("event",({entries:e})=>{for(const t of e){const r=Uc();if(!r)return;if(t.name==="click"){const n=zt(Zn+t.startTime),i=zt(t.duration);r.startChild({description:Za(t.target),op:`ui.interaction.${t.name}`,origin:"auto.ui.browser.metrics",startTimestamp:n,endTimestamp:n+i})}}})}function NK(){return TK(({metric:e})=>{const t=e.entries.pop();t&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding CLS"),kt.cls={value:e.value,unit:""},Hl=t)})}function AK(){return w3(({metric:e})=>{const t=e.entries.pop();t&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding LCP"),kt.lcp={value:e.value,unit:"millisecond"},li=t)})}function LK(){return kK(({metric:e})=>{const t=e.entries.pop();if(!t)return;const r=zt(Zn),n=zt(t.startTime);(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding FID"),kt.fid={value:e.value,unit:"millisecond"},kt["mark.fid"]={value:r+n,unit:"second"}})}function MK(e){const t=k3();if(!t||!at.performance.getEntries||!Zn)return;(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Tracing] Adding & adjusting spans using Performance API");const r=zt(Zn),n=t.getEntries();let i,a;if(n.slice(yI).forEach(o=>{const s=zt(o.startTime),u=zt(o.duration);if(!(e.op==="navigation"&&r+s"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding FP"),kt.fp={value:o.startTime,unit:"millisecond"}),o.name==="first-contentful-paint"&&c&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding FCP"),kt.fcp={value:o.startTime,unit:"millisecond"});break}case"resource":{const l=o.name.replace(at.location.origin,"");UK(e,o,l,s,u,r);break}}}),yI=Math.max(n.length-1,0),BK(e),e.op==="pageload"){typeof i=="number"&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding TTFB"),kt.ttfb={value:(i-e.startTimestamp)*1e3,unit:"millisecond"},typeof a=="number"&&a<=i&&(kt["ttfb.requestTime"]={value:(i-a)*1e3,unit:"millisecond"})),["fcp","fp","lcp"].forEach(s=>{if(!kt[s]||r>=e.startTimestamp)return;const u=kt[s].value,l=r+zt(u),c=Math.abs((l-e.startTimestamp)*1e3),f=c-u;(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Measurements] Normalized ${s} from ${u} to ${c} (${f})`),kt[s].value=c});const o=kt["mark.fid"];o&&kt.fid&&(_u(e,{description:"first input delay",endTimestamp:o.value+zt(kt.fid.value),op:"ui.action",origin:"auto.ui.browser.metrics",startTimestamp:o.value}),delete kt["mark.fid"]),"fcp"in kt||delete kt.cls,Object.keys(kt).forEach(s=>{e.setMeasurement(s,kt[s].value,kt[s].unit)}),zK(e)}li=void 0,Hl=void 0,kt={}}function FK(e,t,r,n,i){const a=i+r,o=a+n;return _u(e,{description:t.name,endTimestamp:o,op:t.entryType,origin:"auto.resource.browser.metrics",startTimestamp:a}),a}function jK(e,t,r){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(n=>{Df(e,t,n,r)}),Df(e,t,"secureConnection",r,"TLS/SSL","connectEnd"),Df(e,t,"fetch",r,"cache","domainLookupStart"),Df(e,t,"domainLookup",r,"DNS"),qK(e,t,r)}function Df(e,t,r,n,i,a){const o=a?t[a]:t[`${r}End`],s=t[`${r}Start`];!s||!o||_u(e,{op:"browser",origin:"auto.browser.browser.metrics",description:i||r,startTimestamp:n+zt(s),endTimestamp:n+zt(o)})}function qK(e,t,r){_u(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"request",startTimestamp:r+zt(t.requestStart),endTimestamp:r+zt(t.responseEnd)}),_u(e,{op:"browser",origin:"auto.browser.browser.metrics",description:"response",startTimestamp:r+zt(t.responseStart),endTimestamp:r+zt(t.responseEnd)})}function UK(e,t,r,n,i,a){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const o={};"transferSize"in t&&(o["http.response_transfer_size"]=t.transferSize),"encodedBodySize"in t&&(o["http.response_content_length"]=t.encodedBodySize),"decodedBodySize"in t&&(o["http.decoded_response_content_length"]=t.decodedBodySize),"renderBlockingStatus"in t&&(o["resource.render_blocking_status"]=t.renderBlockingStatus);const s=a+n,u=s+i;_u(e,{description:r,endTimestamp:u,op:t.initiatorType?`resource.${t.initiatorType}`:"resource.other",origin:"auto.resource.browser.metrics",startTimestamp:s,data:o})}function BK(e){const t=at.navigator;if(!t)return;const r=t.connection;r&&(r.effectiveType&&e.setTag("effectiveConnectionType",r.effectiveType),r.type&&e.setTag("connectionType",r.type),Lm(r.rtt)&&(kt["connection.rtt"]={value:r.rtt,unit:"millisecond"})),Lm(t.deviceMemory)&&e.setTag("deviceMemory",`${t.deviceMemory} GB`),Lm(t.hardwareConcurrency)&&e.setTag("hardwareConcurrency",String(t.hardwareConcurrency))}function zK(e){li&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding LCP Data"),li.element&&e.setTag("lcp.element",Za(li.element)),li.id&&e.setTag("lcp.id",li.id),li.url&&e.setTag("lcp.url",li.url.trim().slice(0,200)),e.setTag("lcp.size",li.size)),Hl&&Hl.sources&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Measurements] Adding CLS Data"),Hl.sources.forEach((t,r)=>e.setTag(`cls.source.${r+1}`,Za(t.node))))}const Lw=["localhost",/^\/(?!\/)/],Mw={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,tracingOrigins:Lw,tracePropagationTargets:Lw};function HK(e){const{traceFetch:t,traceXHR:r,tracePropagationTargets:n,tracingOrigins:i,shouldCreateSpanForRequest:a,enableHTTPTimings:o}={traceFetch:Mw.traceFetch,traceXHR:Mw.traceXHR,...e},s=typeof a=="function"?a:c=>!0,u=c=>YK(c,n||i),l={};t&&vr("fetch",c=>{const f=QK(c,s,u,l);o&&f&&SI(f)}),r&&vr("xhr",c=>{const f=JK(c,s,u,l);o&&f&&SI(f)})}function WK(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.initiatorType==="xmlhttprequest")}function SI(e){const t=e.data.url;if(!t)return;const r=Hp("resource",({entries:n})=>{n.forEach(i=>{WK(i)&&i.name.endsWith(t)&&(VK(i).forEach(o=>e.setData(...o)),setTimeout(r))})})}function GK(e){let t="unknown",r="unknown",n="";for(const i of e){if(i==="/"){[t,r]=e.split("/");break}if(!isNaN(Number(i))){t=n==="h"?"http":n,r=e.split(n)[1];break}n+=i}return n===e&&(t=n),{name:t,version:r}}function ai(e=0){return((Zn||performance.timeOrigin)+e)/1e3}function VK(e){const{name:t,version:r}=GK(e.nextHopProtocol),n=[];return n.push(["network.protocol.version",r],["network.protocol.name",t]),Zn?[...n,["http.request.redirect_start",ai(e.redirectStart)],["http.request.fetch_start",ai(e.fetchStart)],["http.request.domain_lookup_start",ai(e.domainLookupStart)],["http.request.domain_lookup_end",ai(e.domainLookupEnd)],["http.request.connect_start",ai(e.connectStart)],["http.request.secure_connection_start",ai(e.secureConnectionStart)],["http.request.connection_end",ai(e.connectEnd)],["http.request.request_start",ai(e.requestStart)],["http.request.response_start",ai(e.responseStart)],["http.request.response_end",ai(e.responseEnd)]]:n}function YK(e,t){return Mu(e,t||Lw)}function QK(e,t,r,n){if(!ik()||!e.fetchData)return;const i=t(e.fetchData.url);if(e.endTimestamp&&i){const d=e.fetchData.__span;if(!d)return;const h=n[d];if(h){if(e.response){h.setHttpStatus(e.response.status);const p=e.response&&e.response.headers&&e.response.headers.get("content-length"),v=parseInt(p);v>0&&h.setData("http.response_content_length",v)}else e.error&&h.setStatus("internal_error");h.finish(),delete n[d]}return}const a=gu(),o=a.getScope(),s=a.getClient(),u=o.getSpan(),{method:l,url:c}=e.fetchData,f=i&&u?u.startChild({data:{url:c,type:"fetch","http.method":l},description:`${l} ${c}`,op:"http.client",origin:"auto.http.browser"}):void 0;if(f&&(e.fetchData.__span=f.spanId,n[f.spanId]=f),r(e.fetchData.url)&&s){const d=e.args[0];e.args[1]=e.args[1]||{};const h=e.args[1];h.headers=KK(d,s,o,h,f)}return f}function KK(e,t,r,n,i){const a=i||r.getSpan(),o=a&&a.transaction,{traceId:s,sampled:u,dsc:l}=r.getPropagationContext(),c=a?a.toTraceparent():YT(s,void 0,u),f=o?o.getDynamicSamplingContext():l||nk(s,t,r),d=Tw(f),h=typeof Request<"u"&&Qi(e,Request)?e.headers:n.headers;if(h)if(typeof Headers<"u"&&Qi(h,Headers)){const p=new Headers(h);return p.append("sentry-trace",c),d&&p.append(Rw,d),p}else if(Array.isArray(h)){const p=[...h,["sentry-trace",c]];return d&&p.push([Rw,d]),p}else{const p="baggage"in h?h.baggage:void 0,v=[];return Array.isArray(p)?v.push(...p):p&&v.push(p),d&&v.push(d),{...h,"sentry-trace":c,baggage:v.length>0?v.join(","):void 0}}else return{"sentry-trace":c,baggage:d}}function JK(e,t,r,n){const i=e.xhr,a=i&&i[Aa];if(!ik()||i&&i.__sentry_own_request__||!i||!a)return;const o=t(a.url);if(e.endTimestamp&&o){const f=i.__sentry_xhr_span_id__;if(!f)return;const d=n[f];d&&(d.setHttpStatus(a.status_code),d.finish(),delete n[f]);return}const s=gu(),u=s.getScope(),l=u.getSpan(),c=o&&l?l.startChild({data:{...a.data,type:"xhr","http.method":a.method,url:a.url},description:`${a.method} ${a.url}`,op:"http.client",origin:"auto.http.browser"}):void 0;if(c&&(i.__sentry_xhr_span_id__=c.spanId,n[i.__sentry_xhr_span_id__]=c),i.setRequestHeader&&r(a.url))if(c){const f=c&&c.transaction,d=f&&f.getDynamicSamplingContext(),h=Tw(d);bI(i,c.toTraceparent(),h)}else{const f=s.getClient(),{traceId:d,sampled:h,dsc:p}=u.getPropagationContext(),v=YT(d,void 0,h),_=p||(f?nk(d,f,u):void 0),m=Tw(_);bI(i,v,m)}return c}function bI(e,t,r){try{e.setRequestHeader("sentry-trace",t),r&&e.setRequestHeader(Rw,r)}catch{}}function XK(e,t=!0,r=!0){if(!at||!at.location){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Could not initialize routing instrumentation due to invalid location");return}let n=at.location.href,i;t&&(i=e({name:at.location.pathname,startTimestamp:Zn?Zn/1e3:void 0,op:"pageload",origin:"auto.pageload.browser",metadata:{source:"url"}})),r&&vr("history",({to:a,from:o})=>{if(o===void 0&&n&&n.indexOf(a)!==-1){n=void 0;return}o!==a&&(n=void 0,i&&((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Finishing current transaction with op: ${i.op}`),i.finish()),i=e({name:at.location.pathname,op:"navigation",origin:"auto.navigation.browser",metadata:{source:"url"}}))})}const ZK="BrowserTracing",e6={...Td,markBackgroundTransactions:!0,routingInstrumentation:XK,startTransactionOnLocationChange:!0,startTransactionOnPageLoad:!0,enableLongTask:!0,_experiments:{},...Mw};class t6{constructor(t){this.name=ZK,this._hasSetTracePropagationTargets=!1,mK(),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&(this._hasSetTracePropagationTargets=!!(t&&(t.tracePropagationTargets||t.tracingOrigins))),this.options={...e6,...t},this.options._experiments.enableLongTask!==void 0&&(this.options.enableLongTask=this.options._experiments.enableLongTask),t&&!t.tracePropagationTargets&&t.tracingOrigins&&(this.options.tracePropagationTargets=t.tracingOrigins),this._collectWebVitals=CK(),this.options.enableLongTask&&$K(),this.options._experiments.enableInteractions&&DK()}setupOnce(t,r){this._getCurrentHub=r;const i=r().getClient(),a=i&&i.getOptions(),{routingInstrumentation:o,startTransactionOnLocationChange:s,startTransactionOnPageLoad:u,markBackgroundTransactions:l,traceFetch:c,traceXHR:f,shouldCreateSpanForRequest:d,enableHTTPTimings:h,_experiments:p}=this.options,v=a&&a.tracePropagationTargets,_=v||this.options.tracePropagationTargets;(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&this._hasSetTracePropagationTargets&&v&&q.warn("[Tracing] The `tracePropagationTargets` option was set in the BrowserTracing integration and top level `Sentry.init`. The top level `Sentry.init` value is being used."),o(m=>{const g=this._createRouteTransaction(m);return this.options._experiments.onStartRouteTransaction&&this.options._experiments.onStartRouteTransaction(g,m,r),g},u,s),l&&gK(),p.enableInteractions&&this._registerInteractionListener(),HK({traceFetch:c,traceXHR:f,tracePropagationTargets:_,shouldCreateSpanForRequest:d,enableHTTPTimings:h})}_createRouteTransaction(t){if(!this._getCurrentHub){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`[Tracing] Did not create ${t.op} transaction because _getCurrentHub is invalid.`);return}const r=this._getCurrentHub(),{beforeNavigate:n,idleTimeout:i,finalTimeout:a,heartbeatInterval:o}=this.options,s=t.op==="pageload",u=s?EI("sentry-trace"):"",l=s?EI("baggage"):"",{traceparentData:c,dynamicSamplingContext:f,propagationContext:d}=$Y(u,l),h={...t,...c,metadata:{...t.metadata,dynamicSamplingContext:c&&!f?{}:f},trimEnd:!0},p=typeof n=="function"?n(h):h,v=p===void 0?{...h,sampled:!1}:p;v.metadata=v.name!==h.name?{...v.metadata,source:"custom"}:v.metadata,this._latestRouteName=v.name,this._latestRouteSource=v.metadata&&v.metadata.source,v.sampled===!1&&(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Will not send ${v.op} transaction because of beforeNavigate.`),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log(`[Tracing] Starting ${v.op} transaction on scope`);const{location:_}=at,m=gI(r,v,i,a,!0,{location:_},o),g=r.getScope();return s&&c?g.setPropagationContext(d):g.setPropagationContext({traceId:m.traceId,spanId:m.spanId,parentSpanId:m.parentSpanId,sampled:m.sampled}),m.registerBeforeFinishCallback(y=>{this._collectWebVitals(),MK(y)}),m}_registerInteractionListener(){let t;const r=()=>{const{idleTimeout:n,finalTimeout:i,heartbeatInterval:a}=this.options,o="ui.action.click",s=Uc();if(s&&s.op&&["navigation","pageload"].includes(s.op)){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`[Tracing] Did not create ${o} transaction because a pageload or navigation transaction is in progress.`);return}if(t&&(t.setFinishReason("interactionInterrupted"),t.finish(),t=void 0),!this._getCurrentHub){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`[Tracing] Did not create ${o} transaction because _getCurrentHub is invalid.`);return}if(!this._latestRouteName){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn(`[Tracing] Did not create ${o} transaction because _latestRouteName is missing.`);return}const u=this._getCurrentHub(),{location:l}=at,c={name:this._latestRouteName,op:o,trimEnd:!0,metadata:{source:this._latestRouteSource||"url"}};t=gI(u,c,n,i,!0,{location:l},a)};["click"].forEach(n=>{addEventListener(n,r,{once:!1,capture:!0})})}}function EI(e){const t=j8(`meta[name=${e}]`);return t?t.getAttribute("content"):void 0}const lt=Ye,lk="sentryReplaySession",r6="replay_event",ck="Unable to send Replay",n6=3e5,i6=9e5,a6=5e3,o6=5500,s6=6e4,u6=5e3,l6=3,wI=15e4,Nf=5e3,c6=3e3,f6=300,fk=2e7,d6=4999,h6=15e3,RI=36e5;var Ht;(function(e){e[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"})(Ht||(Ht={}));function p6(e){return e.nodeType===e.ELEMENT_NODE}function Wl(e){const t=e==null?void 0:e.host;return(t==null?void 0:t.shadowRoot)===e}function Gl(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function v6(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(" background-clip: text;"," -webkit-background-clip: text; background-clip: text;")),e}function m6(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const 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(" ")+";"}function Ph(e){try{const t=e.rules||e.cssRules;return t?v6(Array.from(t,O3).join("")):null}catch{return null}}function O3(e){let t;if(_6(e))try{t=Ph(e.styleSheet)||m6(e)}catch{}else if(y6(e)&&e.selectorText.includes(":"))return g6(e.cssText);return t||e.cssText}function g6(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function _6(e){return"styleSheet"in e}function y6(e){return"selectorText"in e}class P3{constructor(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}getId(t){var r;if(!t)return-1;const n=(r=this.getMeta(t))===null||r===void 0?void 0:r.id;return n??-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const r=this.getId(t);this.idNodeMap.delete(r),t.childNodes&&t.childNodes.forEach(n=>this.removeNodeFromMap(n))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,r){const n=r.id;this.idNodeMap.set(n,t),this.nodeMetaMap.set(t,r)}replace(t,r){const n=this.getNode(t);if(n){const i=this.nodeMetaMap.get(n);i&&this.nodeMetaMap.set(r,i)}this.idNodeMap.set(t,r)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function S6(){return new P3}function Gp({maskInputOptions:e,tagName:t,type:r}){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||r&&e[r]||r==="password"||t==="INPUT"&&!r&&e.text)}function yc({isMasked:e,element:t,value:r,maskInputFn:n}){let i=r||"";return e?(n&&(i=n(i,t)),"*".repeat(i.length)):i}function yu(e){return e.toLowerCase()}function Fw(e){return e.toUpperCase()}const TI="__rrweb_original__";function b6(e){const t=e.getContext("2d");if(!t)return!0;const r=50;for(let n=0;nu!==0))return!1}return!0}function dk(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?yu(t):null}function Ih(e,t,r){return t==="INPUT"&&(r==="radio"||r==="checkbox")?e.getAttribute("value")||"":e.value}let E6=1;const w6=new RegExp("[^a-z0-9-_:]"),Sc=-2;function hk(){return E6++}function R6(e){if(e instanceof HTMLFormElement)return"form";const t=yu(e.tagName);return w6.test(t)?"div":t}function T6(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let ps,kI;const k6=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,O6=/^(?:[a-z+]+:)?\/\//i,P6=/^www\..*/i,I6=/^(data:)([^,]*),(.*)/i;function xh(e,t){return(e||"").replace(k6,(r,n,i,a,o,s)=>{const u=i||o||s,l=n||a||"";if(!u)return r;if(O6.test(u)||P6.test(u))return`url(${l}${u}${l})`;if(I6.test(u))return`url(${l}${u}${l})`;if(u[0]==="/")return`url(${l}${T6(t)+u}${l})`;const c=t.split("/"),f=u.split("/");c.pop();for(const d of f)d!=="."&&(d===".."?c.pop():c.push(d));return`url(${l}${c.join("/")}${l})`})}const x6=/^[^ \t\n\r\u000c]+/,C6=/^[, \t\n\r\u000c]+/;function $6(e,t){if(t.trim()==="")return t;let r=0;function n(a){let o;const s=a.exec(t.substring(r));return s?(o=s[0],r+=o.length,o):""}const i=[];for(;n(C6),!(r>=t.length);){let a=n(x6);if(a.slice(-1)===",")a=As(e,a.substring(0,a.length-1)),i.push(a);else{let o="";a=As(e,a);let s=!1;for(;;){const u=t.charAt(r);if(u===""){i.push((a+o).trim());break}else if(s)u===")"&&(s=!1);else if(u===","){r+=1,i.push((a+o).trim());break}else u==="("&&(s=!0);o+=u,r+=1}}}return i.join(", ")}function As(e,t){if(!t||t.trim()==="")return t;const r=e.createElement("a");return r.href=t,r.href}function D6(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function pk(){const e=document.createElement("a");return e.href="",e.href}function I3(e,t,r,n,i,a){return n&&(r==="src"||r==="href"&&!(t==="use"&&n[0]==="#")||r==="xlink:href"&&n[0]!=="#"||r==="background"&&(t==="table"||t==="td"||t==="th")?As(e,n):r==="srcset"?$6(e,n):r==="style"?xh(n,pk()):t==="object"&&r==="data"?As(e,n):typeof a=="function"?a(r,n,i):n)}function x3(e,t,r){return(e==="video"||e==="audio")&&t==="autoplay"}function N6(e,t,r,n){try{if(n&&e.matches(n))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let i=e.classList.length;i--;){const a=e.classList[i];if(t.test(a))return!0}if(r)return e.matches(r)}catch{}return!1}function A6(e,t){for(let r=e.classList.length;r--;){const n=e.classList[r];if(t.test(n))return!0}return!1}function $o(e,t,r=1/0,n=0){return!e||e.nodeType!==e.ELEMENT_NODE||n>r?-1:t(e)?n:$o(e.parentNode,t,r,n+1)}function Ls(e,t){return r=>{const n=r;if(n===null)return!1;if(e){if(typeof e=="string"){if(n.matches(`.${e}`))return!0}else if(A6(n,e))return!0}return!!(t&&n.matches(t))}}function Su(e,t,r,n,i,a){try{const o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(o===null)return!1;let s=-1,u=-1;if(a){if(u=$o(o,Ls(n,i)),u<0)return!0;s=$o(o,Ls(t,r),u>=0?u:1/0)}else{if(s=$o(o,Ls(t,r)),s<0)return!1;u=$o(o,Ls(n,i),s>=0?s:1/0)}return s>=0?u>=0?s<=u:!0:u>=0?!1:!!a}catch{}return!!a}function L6(e,t,r){const n=e.contentWindow;if(!n)return;let i=!1,a;try{a=n.document.readyState}catch{return}if(a!=="complete"){const s=setTimeout(()=>{i||(t(),i=!0)},r);e.addEventListener("load",()=>{clearTimeout(s),i=!0,t()});return}const o="about:blank";if(n.location.href!==o||e.src===o||e.src==="")return setTimeout(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function M6(e,t,r){let n=!1,i;try{i=e.sheet}catch{return}if(i)return;const a=setTimeout(()=>{n||(t(),n=!0)},r);e.addEventListener("load",()=>{clearTimeout(a),n=!0,t()})}function F6(e,t){const{doc:r,mirror:n,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:s,maskAttributeFn:u,maskTextClass:l,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:d,inlineStylesheet:h,maskInputOptions:p={},maskTextFn:v,maskInputFn:_,dataURLOptions:m={},inlineImages:g,recordCanvas:y,keepIframeSrcFn:S,newlyAddedElement:b=!1}=t,E=j6(r,n);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Ht.Document,childNodes:[],compatMode:e.compatMode}:{type:Ht.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Ht.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:E};case e.ELEMENT_NODE:return U6(e,{doc:r,blockClass:i,blockSelector:a,unblockSelector:o,inlineStylesheet:h,maskAttributeFn:u,maskInputOptions:p,maskInputFn:_,dataURLOptions:m,inlineImages:g,recordCanvas:y,keepIframeSrcFn:S,newlyAddedElement:b,rootId:E,maskAllText:s,maskTextClass:l,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:d});case e.TEXT_NODE:return q6(e,{maskAllText:s,maskTextClass:l,unmaskTextClass:c,maskTextSelector:f,unmaskTextSelector:d,maskTextFn:v,maskInputOptions:p,maskInputFn:_,rootId:E});case e.CDATA_SECTION_NODE:return{type:Ht.CDATA,textContent:"",rootId:E};case e.COMMENT_NODE:return{type:Ht.Comment,textContent:e.textContent||"",rootId:E};default:return!1}}function j6(e,t){if(!t.hasNode(e))return;const r=t.getId(e);return r===1?void 0:r}function q6(e,t){var r;const{maskAllText:n,maskTextClass:i,unmaskTextClass:a,maskTextSelector:o,unmaskTextSelector:s,maskTextFn:u,maskInputOptions:l,maskInputFn:c,rootId:f}=t,d=e.parentNode&&e.parentNode.tagName;let h=e.textContent;const p=d==="STYLE"?!0:void 0,v=d==="SCRIPT"?!0:void 0,_=d==="TEXTAREA"?!0:void 0;if(p&&h){try{e.nextSibling||e.previousSibling||!((r=e.parentNode.sheet)===null||r===void 0)&&r.cssRules&&(h=Ph(e.parentNode.sheet))}catch(g){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${g}`,e)}h=xh(h,pk())}v&&(h="SCRIPT_PLACEHOLDER");const m=Su(e,i,o,a,s,n);if(!p&&!v&&!_&&h&&m&&(h=u?u(h):h.replace(/[\S]/g,"*")),_&&h&&(l.textarea||m)&&(h=c?c(h,e.parentNode):h.replace(/[\S]/g,"*")),d==="OPTION"&&h){const g=Gp({type:null,tagName:d,maskInputOptions:l});h=yc({isMasked:Su(e,i,o,a,s,g),element:e,value:h,maskInputFn:c})}return{type:Ht.Text,textContent:h||"",isStyle:p,rootId:f}}function U6(e,t){const{doc:r,blockClass:n,blockSelector:i,unblockSelector:a,inlineStylesheet:o,maskInputOptions:s={},maskAttributeFn:u,maskInputFn:l,dataURLOptions:c={},inlineImages:f,recordCanvas:d,keepIframeSrcFn:h,newlyAddedElement:p=!1,rootId:v,maskAllText:_,maskTextClass:m,unmaskTextClass:g,maskTextSelector:y,unmaskTextSelector:S}=t,b=N6(e,n,i,a),E=R6(e);let w={};const R=e.attributes.length;for(let k=0;kT.href===e.href);let C=null;k&&(C=Ph(k)),C&&(delete w.rel,delete w.href,w._cssText=xh(C,k.href))}if(E==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const k=Ph(e.sheet);k&&(w._cssText=xh(k,pk()))}if(E==="input"||E==="textarea"||E==="select"||E==="option"){const k=e,C=dk(k),T=Ih(k,Fw(E),C),$=k.checked;if(C!=="submit"&&C!=="button"&&T){const L=Su(k,m,y,g,S,Gp({type:C,tagName:Fw(E),maskInputOptions:s}));w.value=yc({isMasked:L,element:k,value:T,maskInputFn:l})}$&&(w.checked=$)}if(E==="option"&&(e.selected&&!s.select?w.selected=!0:delete w.selected),E==="canvas"&&d){if(e.__context==="2d")b6(e)||(w.rr_dataURL=e.toDataURL(c.type,c.quality));else if(!("__context"in e)){const k=e.toDataURL(c.type,c.quality),C=document.createElement("canvas");C.width=e.width,C.height=e.height;const T=C.toDataURL(c.type,c.quality);k!==T&&(w.rr_dataURL=k)}}if(E==="img"&&f){ps||(ps=r.createElement("canvas"),kI=ps.getContext("2d"));const k=e,C=k.crossOrigin;k.crossOrigin="anonymous";const T=()=>{k.removeEventListener("load",T);try{ps.width=k.naturalWidth,ps.height=k.naturalHeight,kI.drawImage(k,0,0),w.rr_dataURL=ps.toDataURL(c.type,c.quality)}catch($){console.warn(`Cannot inline img src=${k.currentSrc}! Error: ${$}`)}C?w.crossOrigin=C:k.removeAttribute("crossorigin")};k.complete&&k.naturalWidth!==0?T():k.addEventListener("load",T)}if((E==="audio"||E==="video")&&(w.rr_mediaState=e.paused?"paused":"played",w.rr_mediaCurrentTime=e.currentTime),p||(e.scrollLeft&&(w.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(w.rr_scrollTop=e.scrollTop)),b){const{width:k,height:C}=e.getBoundingClientRect();w={class:w.class,rr_width:`${k}px`,rr_height:`${C}px`}}E==="iframe"&&!h(w.src)&&(e.contentDocument||(w.rr_src=w.src),delete w.src);let O;try{customElements.get(E)&&(O=!0)}catch{}return{type:Ht.Element,tagName:E,attributes:w,childNodes:[],isSVG:D6(e)||void 0,needBlock:b,rootId:v,isCustom:O}}function ut(e){return e==null?"":e.toLowerCase()}function B6(e,t){if(t.comment&&e.type===Ht.Comment)return!0;if(e.type===Ht.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")&&e.attributes.as==="script"||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&e.attributes.href.endsWith(".js")))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(ut(e.attributes.name).match(/^msapplication-tile(image|color)$/)||ut(e.attributes.name)==="application-name"||ut(e.attributes.rel)==="icon"||ut(e.attributes.rel)==="apple-touch-icon"||ut(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&ut(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(ut(e.attributes.property).match(/^(og|twitter|fb):/)||ut(e.attributes.name).match(/^(og|twitter):/)||ut(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(ut(e.attributes.name)==="robots"||ut(e.attributes.name)==="googlebot"||ut(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(ut(e.attributes.name)==="author"||ut(e.attributes.name)==="generator"||ut(e.attributes.name)==="framework"||ut(e.attributes.name)==="publisher"||ut(e.attributes.name)==="progid"||ut(e.attributes.property).match(/^article:/)||ut(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(ut(e.attributes.name)==="google-site-verification"||ut(e.attributes.name)==="yandex-verification"||ut(e.attributes.name)==="csrf-token"||ut(e.attributes.name)==="p:domain_verify"||ut(e.attributes.name)==="verify-v1"||ut(e.attributes.name)==="verification"||ut(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function Ms(e,t){const{doc:r,mirror:n,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:s,maskTextClass:u,unmaskTextClass:l,maskTextSelector:c,unmaskTextSelector:f,skipChild:d=!1,inlineStylesheet:h=!0,maskInputOptions:p={},maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOMOptions:g,dataURLOptions:y={},inlineImages:S=!1,recordCanvas:b=!1,onSerialize:E,onIframeLoad:w,iframeLoadTimeout:R=5e3,onStylesheetLoad:O,stylesheetLoadTimeout:k=5e3,keepIframeSrcFn:C=()=>!1,newlyAddedElement:T=!1}=t;let{preserveWhiteSpace:$=!0}=t;const L=F6(e,{doc:r,mirror:n,blockClass:i,blockSelector:a,maskAllText:s,unblockSelector:o,maskTextClass:u,unmaskTextClass:l,maskTextSelector:c,unmaskTextSelector:f,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,dataURLOptions:y,inlineImages:S,recordCanvas:b,keepIframeSrcFn:C,newlyAddedElement:T});if(!L)return console.warn(e,"not serialized"),null;let G;n.hasNode(e)?G=n.getId(e):B6(L,g)||!$&&L.type===Ht.Text&&!L.isStyle&&!L.textContent.replace(/^\s+|\s+$/gm,"").length?G=Sc:G=hk();const Y=Object.assign(L,{id:G});if(n.add(e,Y),G===Sc)return null;E&&E(e);let B=!d;if(Y.type===Ht.Element){B=B&&!Y.needBlock,delete Y.needBlock;const D=e.shadowRoot;D&&Gl(D)&&(Y.isShadowHost=!0)}if((Y.type===Ht.Document||Y.type===Ht.Element)&&B){g.headWhitespace&&Y.type===Ht.Element&&Y.tagName==="head"&&($=!1);const D={doc:r,mirror:n,blockClass:i,blockSelector:a,maskAllText:s,unblockSelector:o,maskTextClass:u,unmaskTextClass:l,maskTextSelector:c,unmaskTextSelector:f,skipChild:d,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOMOptions:g,dataURLOptions:y,inlineImages:S,recordCanvas:b,preserveWhiteSpace:$,onSerialize:E,onIframeLoad:w,iframeLoadTimeout:R,onStylesheetLoad:O,stylesheetLoadTimeout:k,keepIframeSrcFn:C};for(const F of Array.from(e.childNodes)){const z=Ms(F,D);z&&Y.childNodes.push(z)}if(p6(e)&&e.shadowRoot)for(const F of Array.from(e.shadowRoot.childNodes)){const z=Ms(F,D);z&&(Gl(e.shadowRoot)&&(z.isShadow=!0),Y.childNodes.push(z))}}return e.parentNode&&Wl(e.parentNode)&&Gl(e.parentNode)&&(Y.isShadow=!0),Y.type===Ht.Element&&Y.tagName==="iframe"&&L6(e,()=>{const D=e.contentDocument;if(D&&w){const F=Ms(D,{doc:D,mirror:n,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:s,maskTextClass:u,unmaskTextClass:l,maskTextSelector:c,unmaskTextSelector:f,skipChild:!1,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOMOptions:g,dataURLOptions:y,inlineImages:S,recordCanvas:b,preserveWhiteSpace:$,onSerialize:E,onIframeLoad:w,iframeLoadTimeout:R,onStylesheetLoad:O,stylesheetLoadTimeout:k,keepIframeSrcFn:C});F&&w(e,F)}},R),Y.type===Ht.Element&&Y.tagName==="link"&&Y.attributes.rel==="stylesheet"&&M6(e,()=>{if(O){const D=Ms(e,{doc:r,mirror:n,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:s,maskTextClass:u,unmaskTextClass:l,maskTextSelector:c,unmaskTextSelector:f,skipChild:!1,inlineStylesheet:h,maskInputOptions:p,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOMOptions:g,dataURLOptions:y,inlineImages:S,recordCanvas:b,preserveWhiteSpace:$,onSerialize:E,onIframeLoad:w,iframeLoadTimeout:R,onStylesheetLoad:O,stylesheetLoadTimeout:k,keepIframeSrcFn:C});D&&O(e,D)}},k),Y}function z6(e,t){const{mirror:r=new P3,blockClass:n="rr-block",blockSelector:i=null,unblockSelector:a=null,maskAllText:o=!1,maskTextClass:s="rr-mask",unmaskTextClass:u=null,maskTextSelector:l=null,unmaskTextSelector:c=null,inlineStylesheet:f=!0,inlineImages:d=!1,recordCanvas:h=!1,maskAllInputs:p=!1,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOM:g=!1,dataURLOptions:y,preserveWhiteSpace:S,onSerialize:b,onIframeLoad:E,iframeLoadTimeout:w,onStylesheetLoad:R,stylesheetLoadTimeout:O,keepIframeSrcFn:k=()=>!1}=t||{};return Ms(e,{doc:e,mirror:r,blockClass:n,blockSelector:i,unblockSelector:a,maskAllText:o,maskTextClass:s,unmaskTextClass:u,maskTextSelector:l,unmaskTextSelector:c,skipChild:!1,inlineStylesheet:f,maskInputOptions:p===!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}:p===!1?{}:p,maskAttributeFn:v,maskTextFn:_,maskInputFn:m,slimDOMOptions:g===!0||g==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:g==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:g===!1?{}:g,dataURLOptions:y,inlineImages:d,recordCanvas:h,preserveWhiteSpace:S,onSerialize:b,onIframeLoad:E,iframeLoadTimeout:w,onStylesheetLoad:R,stylesheetLoadTimeout:O,keepIframeSrcFn:k,newlyAddedElement:!1})}function Mr(e,t,r=document){const n={capture:!0,passive:!0};return r.addEventListener(e,t,n),()=>r.removeEventListener(e,t,n)}const Ss=`Please stop import mirror directly. Instead of that,\r now you can use replayer.getMirror() to access the mirror instance of a replayer,\r or you can use record.mirror to access the mirror instance during recording.`;let OI={map:{},getId(){return console.error(Ss),-1},getNode(){return console.error(Ss),null},removeNodeFromMap(){console.error(Ss)},has(){return console.error(Ss),!1},reset(){console.error(Ss)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(OI=new Proxy(OI,{get(e,t,r){return t==="map"&&console.error(Ss),Reflect.get(e,t,r)}}));function bc(e,t,r={}){let n=null,i=0;return function(...a){const o=Date.now();!i&&r.leading===!1&&(i=o);const s=t-(o-i),u=this;s<=0||s>t?(n&&(clearTimeout(n),n=null),i=o,e.apply(u,a)):!n&&r.trailing!==!1&&(n=setTimeout(()=>{i=r.leading===!1?0:Date.now(),n=null,e.apply(u,a)},s))}}function C3(e,t,r,n,i=window){const a=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,n?r:{set(o){setTimeout(()=>{r.set.call(this,o)},0),a&&a.set&&a.set.call(this,o)}}),()=>C3(e,t,a||{},!0)}function vk(e,t,r){try{if(!(t in e))return()=>{};const n=e[t],i=r(n);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:n}})),e[t]=i,()=>{e[t]=n}}catch{return()=>{}}}let Ch=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(Ch=()=>new Date().getTime());function $3(e){var t,r,n,i,a,o;const s=e.document;return{left:s.scrollingElement?s.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:(s==null?void 0:s.documentElement.scrollLeft)||((r=(t=s==null?void 0:s.body)===null||t===void 0?void 0:t.parentElement)===null||r===void 0?void 0:r.scrollLeft)||((n=s==null?void 0:s.body)===null||n===void 0?void 0:n.scrollLeft)||0,top:s.scrollingElement?s.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:(s==null?void 0:s.documentElement.scrollTop)||((a=(i=s==null?void 0:s.body)===null||i===void 0?void 0:i.parentElement)===null||a===void 0?void 0:a.scrollTop)||((o=s==null?void 0:s.body)===null||o===void 0?void 0:o.scrollTop)||0}}function D3(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function N3(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function Hn(e,t,r,n,i){if(!e)return!1;const a=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(!a)return!1;const o=Ls(t,r);if(!i){const l=n&&a.matches(n);return o(a)&&!l}const s=$o(a,o);let u=-1;return s<0?!1:(n&&(u=$o(a,Ls(null,n))),s>-1&&u<0?!0:s{let r=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===r)return!0;while(r=r&&r.parentNode);return!1})}function L3(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function M3(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}function qw(e){return!!(e!=null&&e.shadowRoot)}class G6{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){var r;return(r=this.styleIDMap.get(t))!==null&&r!==void 0?r:-1}has(t){return this.styleIDMap.has(t)}add(t,r){if(this.has(t))return this.getId(t);let n;return r===void 0?n=this.id++:n=r,this.styleIDMap.set(t,n),this.idStyleMap.set(n,t),n}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function F3(e){var t,r;let n=null;return((r=(t=e.getRootNode)===null||t===void 0?void 0:t.call(e))===null||r===void 0?void 0:r.nodeType)===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(n=e.getRootNode().host),n}function V6(e){let t=e,r;for(;r=F3(t);)t=r;return t}function Y6(e){const t=e.ownerDocument;if(!t)return!1;const r=V6(e);return t.contains(r)}function j3(e){const t=e.ownerDocument;return t?t.contains(e)||Y6(e):!1}var Ne=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(Ne||{}),Ce=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(Ce||{}),$r=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))($r||{}),ki=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(ki||{});function PI(e){return"__ln"in e}class Q6{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let r=this.head;for(let n=0;n`${e}@${t}`;class K6{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],r=new Set,n=new Q6,i=u=>{let l=u,c=Sc;for(;c===Sc;)l=l&&l.nextSibling,c=l&&this.mirror.getId(l);return c},a=u=>{if(!u.parentNode||!j3(u))return;const l=Wl(u.parentNode)?this.mirror.getId(F3(u)):this.mirror.getId(u.parentNode),c=i(u);if(l===-1||c===-1)return n.addNode(u);const f=Ms(u,{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:d=>{L3(d,this.mirror)&&this.iframeManager.addIframe(d),M3(d,this.mirror)&&this.stylesheetManager.trackLinkElement(d),qw(u)&&this.shadowDomManager.addShadowRoot(u.shadowRoot,this.doc)},onIframeLoad:(d,h)=>{this.iframeManager.attachIframe(d,h),this.shadowDomManager.observeAttachShadow(d)},onStylesheetLoad:(d,h)=>{this.stylesheetManager.attachLinkElement(d,h)}});f&&(t.push({parentId:l,nextId:c,node:f}),r.add(f.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const u of this.movedSet)xI(this.removes,u,this.mirror)&&!this.movedSet.has(u.parentNode)||a(u);for(const u of this.addedSet)!CI(this.droppedSet,u)&&!xI(this.removes,u,this.mirror)||CI(this.movedSet,u)?a(u):this.droppedSet.add(u);let o=null;for(;n.length;){let u=null;if(o){const l=this.mirror.getId(o.value.parentNode),c=i(o.value);l!==-1&&c!==-1&&(u=o)}if(!u){let l=n.tail;for(;l;){const c=l;if(l=l.previous,c){const f=this.mirror.getId(c.value.parentNode);if(i(c.value)===-1)continue;if(f!==-1){u=c;break}else{const h=c.value;if(h.parentNode&&h.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const p=h.parentNode.host;if(this.mirror.getId(p)!==-1){u=c;break}}}}}}if(!u){for(;n.head;)n.removeNode(n.head.value);break}o=u.previous,n.removeNode(u.value),a(u.value)}const s={texts:this.texts.map(u=>({id:this.mirror.getId(u.node),value:u.value})).filter(u=>!r.has(u.id)).filter(u=>this.mirror.has(u.id)),attributes:this.attributes.map(u=>{const{attributes:l}=u;if(typeof l.style=="string"){const c=JSON.stringify(u.styleDiff),f=JSON.stringify(u._unchangedStyles);c.length!r.has(u.id)).filter(u=>this.mirror.has(u.id)),removes:this.removes,adds:t};!s.texts.length&&!s.attributes.length&&!s.removes.length&&!s.adds.length||(this.texts=[],this.attributes=[],this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(s))},this.processMutation=t=>{if(Mm(t.target,this.mirror))return;let r;try{r=document.implementation.createHTMLDocument()}catch{r=this.doc}switch(t.type){case"characterData":{const n=t.target.textContent;!Hn(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:Su(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let i=t.attributeName,a=t.target.getAttribute(i);if(i==="value"){const s=dk(n),u=n.tagName;a=Ih(n,u,s);const l=Gp({maskInputOptions:this.maskInputOptions,tagName:u,type:s}),c=Su(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,l);a=yc({isMasked:c,element:n,value:a,maskInputFn:this.maskInputFn})}if(Hn(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||a===t.oldValue)return;let o=this.attributes.find(s=>s.node===t.target);if(n.tagName==="IFRAME"&&i==="src"&&!this.keepIframeSrcFn(a))if(!n.contentDocument)i="rr_src";else return;if(o||(o={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(o)),i==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!x3(n.tagName,i)&&(o.attributes[i]=I3(this.doc,yu(n.tagName),yu(i),a,n,this.maskAttributeFn),i==="style")){const s=r.createElement("span");t.oldValue&&s.setAttribute("style",t.oldValue);for(const u of Array.from(n.style)){const l=n.style.getPropertyValue(u),c=n.style.getPropertyPriority(u);l!==s.style.getPropertyValue(u)||c!==s.style.getPropertyPriority(u)?c===""?o.styleDiff[u]=l:o.styleDiff[u]=[l,c]:o._unchangedStyles[u]=[l,c]}for(const u of Array.from(s.style))n.style.getPropertyValue(u)===""&&(o.styleDiff[u]=!1)}break}case"childList":{if(Hn(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const i=this.mirror.getId(n),a=Wl(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);Hn(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||Mm(n,this.mirror)||!H6(n,this.mirror)||(this.addedSet.has(n)?(Uw(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&i===-1||A3(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[II(i,a)]?Uw(this.movedSet,n):this.removes.push({parentId:a,id:i,isShadow:Wl(t.target)&&Gl(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,r)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(Mm(t,this.mirror))return;this.movedSet.add(t);let n=null;r&&this.mirror.hasNode(r)&&(n=this.mirror.getId(r)),n&&n!==-1&&(this.movedMap[II(this.mirror.getId(t),n)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);Hn(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes.forEach(n=>this.genAdds(n)),qw(t)&&t.shadowRoot.childNodes.forEach(n=>{this.processedNodeManager.add(n,this),this.genAdds(n,t)}))}}}init(t){["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(r=>{this[r]=t[r]})}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 Uw(e,t){e.delete(t),t.childNodes.forEach(r=>Uw(e,r))}function xI(e,t,r){return e.length===0?!1:q3(e,t,r)}function q3(e,t,r){const{parentNode:n}=t;if(!n)return!1;const i=r.getId(n);return e.some(a=>a.id===i)?!0:q3(e,n,r)}function CI(e,t){return e.size===0?!1:U3(e,t)}function U3(e,t){const{parentNode:r}=t;return r?e.has(r)?!0:U3(e,r):!1}let Vl;function J6(e){Vl=e}function X6(){Vl=void 0}const je=e=>Vl?(...r)=>{try{return e(...r)}catch(n){if(Vl&&Vl(n)===!0)return()=>{};throw n}}:e,Fs=[];function Bc(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function B3(e,t){var r,n;const i=new K6;Fs.push(i),i.init(e);let a=window.MutationObserver||window.__rrMutationObserver;const o=(n=(r=window==null?void 0:window.Zone)===null||r===void 0?void 0:r.__symbol__)===null||n===void 0?void 0:n.call(r,"MutationObserver");o&&window[o]&&(a=window[o]);const s=new a(je(u=>{e.onMutation&&e.onMutation(u)===!1||i.processMutations.bind(i)(u)}));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function Z6({mousemoveCb:e,sampling:t,doc:r,mirror:n}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,a=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],s;const u=bc(je(f=>{const d=Date.now()-s;e(o.map(h=>(h.timeOffset-=d,h)),f),o=[],s=null}),a),l=je(bc(je(f=>{const d=Bc(f),{clientX:h,clientY:p}=jw(f)?f.changedTouches[0]:f;s||(s=Ch()),o.push({x:h,y:p,id:n.getId(d),timeOffset:Ch()-s}),u(typeof DragEvent<"u"&&f instanceof DragEvent?Ce.Drag:f instanceof MouseEvent?Ce.MouseMove:Ce.TouchMove)}),i,{trailing:!1})),c=[Mr("mousemove",l,r),Mr("touchmove",l,r),Mr("drag",l,r)];return je(()=>{c.forEach(f=>f())})}function e2({mouseInteractionCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:a,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const s=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,u=[];let l=null;const c=f=>d=>{const h=Bc(d);if(Hn(h,n,i,a,!0))return;let p=null,v=f;if("pointerType"in d){switch(d.pointerType){case"mouse":p=ki.Mouse;break;case"touch":p=ki.Touch;break;case"pen":p=ki.Pen;break}p===ki.Touch?$r[f]===$r.MouseDown?v="TouchStart":$r[f]===$r.MouseUp&&(v="TouchEnd"):ki.Pen}else jw(d)&&(p=ki.Touch);p!==null?(l=p,(v.startsWith("Touch")&&p===ki.Touch||v.startsWith("Mouse")&&p===ki.Mouse)&&(p=null)):$r[f]===$r.Click&&(p=l,l=null);const _=jw(d)?d.changedTouches[0]:d;if(!_)return;const m=r.getId(h),{clientX:g,clientY:y}=_;je(e)(Object.assign({type:$r[v],id:m,x:g,y},p!==null&&{pointerType:p}))};return Object.keys($r).filter(f=>Number.isNaN(Number(f))&&!f.endsWith("_Departed")&&s[f]!==!1).forEach(f=>{let d=yu(f);const h=c(f);if(window.PointerEvent)switch($r[f]){case $r.MouseDown:case $r.MouseUp:d=d.replace("mouse","pointer");break;case $r.TouchStart:case $r.TouchEnd:return}u.push(Mr(d,h,t))}),je(()=>{u.forEach(f=>f())})}function z3({scrollCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:a,sampling:o}){const s=je(bc(je(u=>{const l=Bc(u);if(!l||Hn(l,n,i,a,!0))return;const c=r.getId(l);if(l===t&&t.defaultView){const f=$3(t.defaultView);e({id:c,x:f.left,y:f.top})}else e({id:c,x:l.scrollLeft,y:l.scrollTop})}),o.scroll||100));return Mr("scroll",s,t)}function t2({viewportResizeCb:e},{win:t}){let r=-1,n=-1;const i=je(bc(je(()=>{const a=D3(),o=N3();(r!==a||n!==o)&&(e({width:Number(o),height:Number(a)}),r=a,n=o)}),200));return Mr("resize",i,t)}const r2=["INPUT","TEXTAREA","SELECT"],$I=new WeakMap;function n2({inputCb:e,doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:a,ignoreClass:o,ignoreSelector:s,maskInputOptions:u,maskInputFn:l,sampling:c,userTriggeredOnInput:f,maskTextClass:d,unmaskTextClass:h,maskTextSelector:p,unmaskTextSelector:v}){function _(w){let R=Bc(w);const O=w.isTrusted,k=R&&Fw(R.tagName);if(k==="OPTION"&&(R=R.parentElement),!R||!k||r2.indexOf(k)<0||Hn(R,n,i,a,!0))return;const C=R;if(C.classList.contains(o)||s&&C.matches(s))return;const T=dk(R);let $=Ih(C,k,T),L=!1;const G=Gp({maskInputOptions:u,tagName:k,type:T}),Y=Su(R,d,p,h,v,G);(T==="radio"||T==="checkbox")&&(L=R.checked),$=yc({isMasked:Y,element:R,value:$,maskInputFn:l}),m(R,f?{text:$,isChecked:L,userTriggered:O}:{text:$,isChecked:L});const B=R.name;T==="radio"&&B&&L&&t.querySelectorAll(`input[type="radio"][name="${B}"]`).forEach(D=>{if(D!==R){const F=yc({isMasked:Y,element:D,value:Ih(D,k,T),maskInputFn:l});m(D,f?{text:F,isChecked:!L,userTriggered:!1}:{text:F,isChecked:!L})}})}function m(w,R){const O=$I.get(w);if(!O||O.text!==R.text||O.isChecked!==R.isChecked){$I.set(w,R);const k=r.getId(w);je(e)(Object.assign(Object.assign({},R),{id:k}))}}const y=(c.input==="last"?["change"]:["input","change"]).map(w=>Mr(w,je(_),t)),S=t.defaultView;if(!S)return()=>{y.forEach(w=>w())};const b=S.Object.getOwnPropertyDescriptor(S.HTMLInputElement.prototype,"value"),E=[[S.HTMLInputElement.prototype,"value"],[S.HTMLInputElement.prototype,"checked"],[S.HTMLSelectElement.prototype,"value"],[S.HTMLTextAreaElement.prototype,"value"],[S.HTMLSelectElement.prototype,"selectedIndex"],[S.HTMLOptionElement.prototype,"selected"]];return b&&b.set&&y.push(...E.map(w=>C3(w[0],w[1],{set(){je(_)({target:this,isTrusted:!1})}},!1,S))),je(()=>{y.forEach(w=>w())})}function $h(e){const t=[];function r(n,i){if(Af("CSSGroupingRule")&&n.parentRule instanceof CSSGroupingRule||Af("CSSMediaRule")&&n.parentRule instanceof CSSMediaRule||Af("CSSSupportsRule")&&n.parentRule instanceof CSSSupportsRule||Af("CSSConditionRule")&&n.parentRule instanceof CSSConditionRule){const o=Array.from(n.parentRule.cssRules).indexOf(n);i.unshift(o)}else if(n.parentStyleSheet){const o=Array.from(n.parentStyleSheet.cssRules).indexOf(n);i.unshift(o)}return i}return r(e,t)}function ba(e,t,r){let n,i;return e?(e.ownerNode?n=t.getId(e.ownerNode):i=r.getId(e),{styleId:i,id:n}):{}}function i2({styleSheetRuleCb:e,mirror:t,stylesheetManager:r},{win:n}){if(!n.CSSStyleSheet||!n.CSSStyleSheet.prototype)return()=>{};const i=n.CSSStyleSheet.prototype.insertRule;n.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:je((c,f,d)=>{const[h,p]=d,{id:v,styleId:_}=ba(f,t,r.styleMirror);return(v&&v!==-1||_&&_!==-1)&&e({id:v,styleId:_,adds:[{rule:h,index:p}]}),c.apply(f,d)})});const a=n.CSSStyleSheet.prototype.deleteRule;n.CSSStyleSheet.prototype.deleteRule=new Proxy(a,{apply:je((c,f,d)=>{const[h]=d,{id:p,styleId:v}=ba(f,t,r.styleMirror);return(p&&p!==-1||v&&v!==-1)&&e({id:p,styleId:v,removes:[{index:h}]}),c.apply(f,d)})});let o;n.CSSStyleSheet.prototype.replace&&(o=n.CSSStyleSheet.prototype.replace,n.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:je((c,f,d)=>{const[h]=d,{id:p,styleId:v}=ba(f,t,r.styleMirror);return(p&&p!==-1||v&&v!==-1)&&e({id:p,styleId:v,replace:h}),c.apply(f,d)})}));let s;n.CSSStyleSheet.prototype.replaceSync&&(s=n.CSSStyleSheet.prototype.replaceSync,n.CSSStyleSheet.prototype.replaceSync=new Proxy(s,{apply:je((c,f,d)=>{const[h]=d,{id:p,styleId:v}=ba(f,t,r.styleMirror);return(p&&p!==-1||v&&v!==-1)&&e({id:p,styleId:v,replaceSync:h}),c.apply(f,d)})}));const u={};Lf("CSSGroupingRule")?u.CSSGroupingRule=n.CSSGroupingRule:(Lf("CSSMediaRule")&&(u.CSSMediaRule=n.CSSMediaRule),Lf("CSSConditionRule")&&(u.CSSConditionRule=n.CSSConditionRule),Lf("CSSSupportsRule")&&(u.CSSSupportsRule=n.CSSSupportsRule));const l={};return Object.entries(u).forEach(([c,f])=>{l[c]={insertRule:f.prototype.insertRule,deleteRule:f.prototype.deleteRule},f.prototype.insertRule=new Proxy(l[c].insertRule,{apply:je((d,h,p)=>{const[v,_]=p,{id:m,styleId:g}=ba(h.parentStyleSheet,t,r.styleMirror);return(m&&m!==-1||g&&g!==-1)&&e({id:m,styleId:g,adds:[{rule:v,index:[...$h(h),_||0]}]}),d.apply(h,p)})}),f.prototype.deleteRule=new Proxy(l[c].deleteRule,{apply:je((d,h,p)=>{const[v]=p,{id:_,styleId:m}=ba(h.parentStyleSheet,t,r.styleMirror);return(_&&_!==-1||m&&m!==-1)&&e({id:_,styleId:m,removes:[{index:[...$h(h),v]}]}),d.apply(h,p)})})}),je(()=>{n.CSSStyleSheet.prototype.insertRule=i,n.CSSStyleSheet.prototype.deleteRule=a,o&&(n.CSSStyleSheet.prototype.replace=o),s&&(n.CSSStyleSheet.prototype.replaceSync=s),Object.entries(u).forEach(([c,f])=>{f.prototype.insertRule=l[c].insertRule,f.prototype.deleteRule=l[c].deleteRule})})}function H3({mirror:e,stylesheetManager:t},r){var n,i,a;let o=null;r.nodeName==="#document"?o=e.getId(r):o=e.getId(r.host);const s=r.nodeName==="#document"?(n=r.defaultView)===null||n===void 0?void 0:n.Document:(a=(i=r.ownerDocument)===null||i===void 0?void 0:i.defaultView)===null||a===void 0?void 0:a.ShadowRoot,u=s!=null&&s.prototype?Object.getOwnPropertyDescriptor(s==null?void 0:s.prototype,"adoptedStyleSheets"):void 0;return o===null||o===-1||!s||!u?()=>{}:(Object.defineProperty(r,"adoptedStyleSheets",{configurable:u.configurable,enumerable:u.enumerable,get(){var l;return(l=u.get)===null||l===void 0?void 0:l.call(this)},set(l){var c;const f=(c=u.set)===null||c===void 0?void 0:c.call(this,l);if(o!==null&&o!==-1)try{t.adoptStyleSheets(l,o)}catch{}return f}}),je(()=>{Object.defineProperty(r,"adoptedStyleSheets",{configurable:u.configurable,enumerable:u.enumerable,get:u.get,set:u.set})}))}function a2({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:r,stylesheetManager:n},{win:i}){const a=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(a,{apply:je((s,u,l)=>{var c;const[f,d,h]=l;if(r.has(f))return a.apply(u,[f,d,h]);const{id:p,styleId:v}=ba((c=u.parentRule)===null||c===void 0?void 0:c.parentStyleSheet,t,n.styleMirror);return(p&&p!==-1||v&&v!==-1)&&e({id:p,styleId:v,set:{property:f,value:d,priority:h},index:$h(u.parentRule)}),s.apply(u,l)})});const o=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:je((s,u,l)=>{var c;const[f]=l;if(r.has(f))return o.apply(u,[f]);const{id:d,styleId:h}=ba((c=u.parentRule)===null||c===void 0?void 0:c.parentStyleSheet,t,n.styleMirror);return(d&&d!==-1||h&&h!==-1)&&e({id:d,styleId:h,remove:{property:f},index:$h(u.parentRule)}),s.apply(u,l)})}),je(()=>{i.CSSStyleDeclaration.prototype.setProperty=a,i.CSSStyleDeclaration.prototype.removeProperty=o})}function o2({mediaInteractionCb:e,blockClass:t,blockSelector:r,unblockSelector:n,mirror:i,sampling:a,doc:o}){const s=je(l=>bc(je(c=>{const f=Bc(c);if(!f||Hn(f,t,r,n,!0))return;const{currentTime:d,volume:h,muted:p,playbackRate:v}=f;e({type:l,id:i.getId(f),currentTime:d,volume:h,muted:p,playbackRate:v})}),a.media||500)),u=[Mr("play",s(0),o),Mr("pause",s(1),o),Mr("seeked",s(2),o),Mr("volumechange",s(3),o),Mr("ratechange",s(4),o)];return je(()=>{u.forEach(l=>l())})}function s2({fontCb:e,doc:t}){const r=t.defaultView;if(!r)return()=>{};const n=[],i=new WeakMap,a=r.FontFace;r.FontFace=function(u,l,c){const f=new a(u,l,c);return i.set(f,{family:u,buffer:typeof l!="string",descriptors:c,fontSource:typeof l=="string"?l:JSON.stringify(Array.from(new Uint8Array(l)))}),f};const o=vk(t.fonts,"add",function(s){return function(u){return setTimeout(je(()=>{const l=i.get(u);l&&(e(l),i.delete(u))}),0),s.apply(this,[u])}});return n.push(()=>{r.FontFace=a}),n.push(o),je(()=>{n.forEach(s=>s())})}function u2(e){const{doc:t,mirror:r,blockClass:n,blockSelector:i,unblockSelector:a,selectionCb:o}=e;let s=!0;const u=je(()=>{const l=t.getSelection();if(!l||s&&(l!=null&&l.isCollapsed))return;s=l.isCollapsed||!1;const c=[],f=l.rangeCount||0;for(let d=0;d{}:vk(r.customElements,"define",function(i){return function(a,o,s){try{t({define:{name:a}})}catch{}return i.apply(this,[a,o,s])}})}function c2(e,t={}){const r=e.doc.defaultView;if(!r)return()=>{};const n=B3(e,e.doc),i=Z6(e),a=e2(e),o=z3(e),s=t2(e,{win:r}),u=n2(e),l=o2(e),c=i2(e,{win:r}),f=H3(e,e.doc),d=a2(e,{win:r}),h=e.collectFonts?s2(e):()=>{},p=u2(e),v=l2(e);return je(()=>{Fs.forEach(_=>_.reset()),n.disconnect(),i(),a(),o(),s(),u(),l(),c(),f(),d(),h(),p(),v()})}function Af(e){return typeof window[e]<"u"}function Lf(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Bw{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,r,n,i){const a=n||this.getIdToRemoteIdMap(t),o=i||this.getRemoteIdToIdMap(t);let s=a.get(r);return s||(s=this.generateIdFn(),a.set(r,s),o.set(s,r)),s}getIds(t,r){const n=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return r.map(a=>this.getId(t,a,n,i))}getRemoteId(t,r,n){const i=n||this.getRemoteIdToIdMap(t);if(typeof r!="number")return r;const a=i.get(r);return a||-1}getRemoteIds(t,r){const n=this.getRemoteIdToIdMap(t);return r.map(i=>this.getRemoteId(t,i,n))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let r=this.iframeIdToRemoteIdMap.get(t);return r||(r=new Map,this.iframeIdToRemoteIdMap.set(t,r)),r}getRemoteIdToIdMap(t){let r=this.iframeRemoteIdToIdMap.get(t);return r||(r=new Map,this.iframeRemoteIdToIdMap.set(t,r)),r}}class f2{constructor(){this.crossOriginIframeMirror=new Bw(hk),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class d2{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Bw(hk),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Bw(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,r){var n;this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:r}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),(n=this.loadListener)===null||n===void 0||n.call(this,t),t.contentDocument&&t.contentDocument.adoptedStyleSheets&&t.contentDocument.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(t.contentDocument.adoptedStyleSheets,this.mirror.getId(t.contentDocument))}handleMessage(t){const r=t;if(r.data.type!=="rrweb"||r.origin!==r.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const a=this.transformCrossOriginEvent(i,r.data.event);a&&this.wrappedEmit(a,r.data.isCheckout)}transformCrossOriginEvent(t,r){var n;switch(r.type){case Ne.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(r.data.node,t);const i=r.data.node.id;return this.crossOriginIframeRootIdMap.set(t,i),this.patchRootIdOnNode(r.data.node,i),{timestamp:r.timestamp,type:Ne.IncrementalSnapshot,data:{source:Ce.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:r.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case Ne.Meta:case Ne.Load:case Ne.DomContentLoaded:return!1;case Ne.Plugin:return r;case Ne.Custom:return this.replaceIds(r.data.payload,t,["id","parentId","previousId","nextId"]),r;case Ne.IncrementalSnapshot:switch(r.data.source){case Ce.Mutation:return r.data.adds.forEach(i=>{this.replaceIds(i,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(i.node,t);const a=this.crossOriginIframeRootIdMap.get(t);a&&this.patchRootIdOnNode(i.node,a)}),r.data.removes.forEach(i=>{this.replaceIds(i,t,["parentId","id"])}),r.data.attributes.forEach(i=>{this.replaceIds(i,t,["id"])}),r.data.texts.forEach(i=>{this.replaceIds(i,t,["id"])}),r;case Ce.Drag:case Ce.TouchMove:case Ce.MouseMove:return r.data.positions.forEach(i=>{this.replaceIds(i,t,["id"])}),r;case Ce.ViewportResize:return!1;case Ce.MediaInteraction:case Ce.MouseInteraction:case Ce.Scroll:case Ce.CanvasMutation:case Ce.Input:return this.replaceIds(r.data,t,["id"]),r;case Ce.StyleSheetRule:case Ce.StyleDeclaration:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleId"]),r;case Ce.Font:return r;case Ce.Selection:return r.data.ranges.forEach(i=>{this.replaceIds(i,t,["start","end"])}),r;case Ce.AdoptedStyleSheet:return this.replaceIds(r.data,t,["id"]),this.replaceStyleIds(r.data,t,["styleIds"]),(n=r.data.styles)===null||n===void 0||n.forEach(i=>{this.replaceStyleIds(i,t,["styleId"])}),r}}return!1}replace(t,r,n,i){for(const a of i)!Array.isArray(r[a])&&typeof r[a]!="number"||(Array.isArray(r[a])?r[a]=t.getIds(n,r[a]):r[a]=t.getId(n,r[a]));return r}replaceIds(t,r,n){return this.replace(this.crossOriginIframeMirror,t,r,n)}replaceStyleIds(t,r,n){return this.replace(this.crossOriginIframeStyleMirror,t,r,n)}replaceIdOnNode(t,r){this.replaceIds(t,r,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(n=>{this.replaceIdOnNode(n,r)})}patchRootIdOnNode(t,r){t.type!==Ht.Document&&!t.rootId&&(t.rootId=r),"childNodes"in t&&t.childNodes.forEach(n=>{this.patchRootIdOnNode(n,r)})}}class h2{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class p2{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,r){if(!Gl(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t);const n=B3(Object.assign(Object.assign({},this.bypassOptions),{doc:r,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this}),t);this.restoreHandlers.push(()=>n.disconnect()),this.restoreHandlers.push(z3(Object.assign(Object.assign({},this.bypassOptions),{scrollCb:this.scrollCb,doc:t,mirror:this.mirror}))),setTimeout(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(H3({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){!t.contentWindow||!t.contentDocument||this.patchAttachShadow(t.contentWindow.Element,t.contentDocument)}patchAttachShadow(t,r){const n=this;this.restoreHandlers.push(vk(t.prototype,"attachShadow",function(i){return function(a){const o=i.call(this,a);return this.shadowRoot&&j3(this)&&n.addShadowRoot(this.shadowRoot,r),o}}))}reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet}}class v2{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}}class m2{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new G6,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,r){"_cssText"in r.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:r.id,attributes:r.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,r){if(t.length===0)return;const n={id:r,styleIds:[]},i=[];for(const a of t){let o;this.styleMirror.has(a)?o=this.styleMirror.getId(a):(o=this.styleMirror.add(a),i.push({styleId:o,rules:Array.from(a.rules||CSSRule,(s,u)=>({rule:O3(s),index:u}))})),n.styleIds.push(o)}i.length>0&&(n.styles=i),this.adoptedStyleSheetCb(n)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class g2{constructor(){this.nodeMap=new WeakMap,this.loop=!0,this.periodicallyClear()}periodicallyClear(){requestAnimationFrame(()=>{this.clear(),this.loop&&this.periodicallyClear()})}inOtherBuffer(t,r){const n=this.nodeMap.get(t);return n&&Array.from(n).some(i=>i!==r)}add(t,r){this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(r))}clear(){this.nodeMap=new WeakMap}destroy(){this.loop=!1}}function Jt(e){const t=e;return t.timestamp=Ch(),t}let Dh;const Oi=S6();function Wa(e={}){const{emit:t,checkoutEveryNms:r,checkoutEveryNth:n,blockClass:i="rr-block",blockSelector:a=null,unblockSelector:o=null,ignoreClass:s="rr-ignore",ignoreSelector:u=null,maskAllText:l=!1,maskTextClass:c="rr-mask",unmaskTextClass:f=null,maskTextSelector:d=null,unmaskTextSelector:h=null,inlineStylesheet:p=!0,maskAllInputs:v,maskInputOptions:_,slimDOMOptions:m,maskAttributeFn:g,maskInputFn:y,maskTextFn:S,packFn:b,sampling:E={},dataURLOptions:w={},mousemoveWait:R,recordCanvas:O=!1,recordCrossOriginIframes:k=!1,recordAfter:C=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:T=!1,collectFonts:$=!1,inlineImages:L=!1,keepIframeSrcFn:G=()=>!1,ignoreCSSAttributes:Y=new Set([]),errorHandler:B,onMutation:D,getCanvasManager:F}=e;J6(B);const z=k?window.parent===window:!0;let ee=!1;if(!z)try{window.parent.document&&(ee=!1)}catch{ee=!0}if(z&&!t)throw new Error("emit function is required");R!==void 0&&E.mousemove===void 0&&(E.mousemove=R),Oi.reset();const Z=v===!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?_:{},W=m===!0||m==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:m==="all",headMetaDescKeywords:m==="all"}:m||{};W6();let Q,ae=0;const re=we=>(b&&!ee&&(we=b(we)),we),ie=(we,We)=>{var ue;if(!((ue=Fs[0])===null||ue===void 0)&&ue.isFrozen()&&we.type!==Ne.FullSnapshot&&!(we.type===Ne.IncrementalSnapshot&&we.data.source===Ce.Mutation)&&Fs.forEach(_e=>_e.unfreeze()),z)t==null||t(re(we),We);else if(ee){const _e={type:"rrweb",event:re(we),origin:window.location.origin,isCheckout:We};window.parent.postMessage(_e,"*")}if(we.type===Ne.FullSnapshot)Q=we,ae=0;else if(we.type===Ne.IncrementalSnapshot){if(we.data.source===Ce.Mutation&&we.data.isAttachIframe)return;ae++;const _e=n&&ae>=n,ye=r&&we.timestamp-Q.timestamp>r;(_e||ye)&&st(!0)}},Ee=we=>{ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.Mutation},we)}))},Ie=we=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.Scroll},we)})),Pe=we=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.CanvasMutation},we)})),$e=we=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.AdoptedStyleSheet},we)})),De=new m2({mutationCb:Ee,adoptedStyleSheetCb:$e}),He=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new f2:new d2({mirror:Oi,mutationCb:Ee,stylesheetManager:De,recordCrossOriginIframes:k,wrappedEmit:ie}),Je=new g2,et=F?F({recordCanvas:O,blockClass:i,blockSelector:a,unblockSelector:o,sampling:E.canvas,dataURLOptions:w}):new v2,ot=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new h2:new p2({mutationCb:Ee,scrollCb:Ie,bypassOptions:{onMutation:D,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:l,maskTextClass:c,unmaskTextClass:f,maskTextSelector:d,unmaskTextSelector:h,inlineStylesheet:p,maskInputOptions:Z,dataURLOptions:w,maskAttributeFn:g,maskTextFn:S,maskInputFn:y,recordCanvas:O,inlineImages:L,sampling:E,slimDOMOptions:W,iframeManager:He,stylesheetManager:De,canvasManager:et,keepIframeSrcFn:G,processedNodeManager:Je},mirror:Oi}),st=(we=!1)=>{ie(Jt({type:Ne.Meta,data:{href:window.location.href,width:N3(),height:D3()}}),we),De.reset(),ot.init(),Fs.forEach(ue=>ue.lock());const We=z6(document,{mirror:Oi,blockClass:i,blockSelector:a,unblockSelector:o,maskAllText:l,maskTextClass:c,unmaskTextClass:f,maskTextSelector:d,unmaskTextSelector:h,inlineStylesheet:p,maskAllInputs:Z,maskAttributeFn:g,maskInputFn:y,maskTextFn:S,slimDOM:W,dataURLOptions:w,recordCanvas:O,inlineImages:L,onSerialize:ue=>{L3(ue,Oi)&&He.addIframe(ue),M3(ue,Oi)&&De.trackLinkElement(ue),qw(ue)&&ot.addShadowRoot(ue.shadowRoot,document)},onIframeLoad:(ue,_e)=>{He.attachIframe(ue,_e),ot.observeAttachShadow(ue)},onStylesheetLoad:(ue,_e)=>{De.attachLinkElement(ue,_e)},keepIframeSrcFn:G});if(!We)return console.warn("Failed to snapshot the document");ie(Jt({type:Ne.FullSnapshot,data:{node:We,initialOffset:$3(window)}}),we),Fs.forEach(ue=>ue.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&De.adoptStyleSheets(document.adoptedStyleSheets,Oi.getId(document))};Dh=st;try{const we=[],We=_e=>je(c2)({onMutation:D,mutationCb:Ee,mousemoveCb:(ye,It)=>ie(Jt({type:Ne.IncrementalSnapshot,data:{source:It,positions:ye}})),mouseInteractionCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.MouseInteraction},ye)})),scrollCb:Ie,viewportResizeCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.ViewportResize},ye)})),inputCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.Input},ye)})),mediaInteractionCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.MediaInteraction},ye)})),styleSheetRuleCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.StyleSheetRule},ye)})),styleDeclarationCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.StyleDeclaration},ye)})),canvasMutationCb:Pe,fontCb:ye=>ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.Font},ye)})),selectionCb:ye=>{ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.Selection},ye)}))},customElementCb:ye=>{ie(Jt({type:Ne.IncrementalSnapshot,data:Object.assign({source:Ce.CustomElement},ye)}))},blockClass:i,ignoreClass:s,ignoreSelector:u,maskAllText:l,maskTextClass:c,unmaskTextClass:f,maskTextSelector:d,unmaskTextSelector:h,maskInputOptions:Z,inlineStylesheet:p,sampling:E,recordCanvas:O,inlineImages:L,userTriggeredOnInput:T,collectFonts:$,doc:_e,maskAttributeFn:g,maskInputFn:y,maskTextFn:S,keepIframeSrcFn:G,blockSelector:a,unblockSelector:o,slimDOMOptions:W,dataURLOptions:w,mirror:Oi,iframeManager:He,stylesheetManager:De,shadowDomManager:ot,processedNodeManager:Je,canvasManager:et,ignoreCSSAttributes:Y,plugins:[]},{});He.addLoadListener(_e=>{try{we.push(We(_e.contentDocument))}catch(ye){console.warn(ye)}});const ue=()=>{st(),we.push(We(document))};return document.readyState==="interactive"||document.readyState==="complete"?ue():(we.push(Mr("DOMContentLoaded",()=>{ie(Jt({type:Ne.DomContentLoaded,data:{}})),C==="DOMContentLoaded"&&ue()})),we.push(Mr("load",()=>{ie(Jt({type:Ne.Load,data:{}})),C==="load"&&ue()},window))),()=>{we.forEach(_e=>_e()),Je.destroy(),Dh=void 0,X6()}}catch(we){console.warn(we)}}function _2(e){if(!Dh)throw new Error("please take full snapshot after start recording");Dh(e)}Wa.mirror=Oi;Wa.takeFullSnapshot=_2;const y2=3,S2=5;function mk(e){return e>9999999999?e:e*1e3}function Fm(e){return e>9999999999?e/1e3:e}function Vp(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>(e.throttledAddEvent({type:Ne.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:kr(t,10,1e3)}}),t.category==="console")))}const b2="button,a";function W3(e){return e.closest(b2)||e}function G3(e){const t=V3(e);return!t||!(t instanceof Element)?t:W3(t)}function V3(e){return E2(e)?e.target:e}function E2(e){return typeof e=="object"&&!!e&&"target"in e}let Ea;function w2(e){return Ea||(Ea=[],R2()),Ea.push(e),()=>{const t=Ea?Ea.indexOf(e):-1;t>-1&&Ea.splice(t,1)}}function R2(){nr(lt,"open",function(e){return function(...t){if(Ea)try{Ea.forEach(r=>r())}catch{}return e.apply(lt,t)}})}function T2(e,t,r){e.handleClick(t,r)}class k2{constructor(t,r,n=Vp){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=r.timeout/1e3,this._threshold=r.threshold/1e3,this._scollTimeout=r.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=r.ignoreSelector,this._addBreadcrumbEvent=n}addListeners(){const t=w2(()=>{this._lastMutation=DI()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,r){if(P2(r,this._ignoreSelector)||!I2(t))return;const n={timestamp:Fm(t.timestamp),clickBreadcrumb:t,clickCount:0,node:r};this._clicks.some(i=>i.node===n.node&&Math.abs(i.timestamp-n.timestamp)<1)||(this._clicks.push(n),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=Fm(t)}registerScroll(t=Date.now()){this._lastScroll=Fm(t)}registerClick(t){const r=W3(t);this._handleMultiClick(r)}_handleMultiClick(t){this._getClicks(t).forEach(r=>{r.clickCount++})}_getClicks(t){return this._clicks.filter(r=>r.node===t)}_checkClicks(){const t=[],r=DI();this._clicks.forEach(n=>{!n.mutationAfter&&this._lastMutation&&(n.mutationAfter=n.timestamp<=this._lastMutation?this._lastMutation-n.timestamp:void 0),!n.scrollAfter&&this._lastScroll&&(n.scrollAfter=n.timestamp<=this._lastScroll?this._lastScroll-n.timestamp:void 0),n.timestamp+this._timeout<=r&&t.push(n)});for(const n of t){const i=this._clicks.indexOf(n);i>-1&&(this._generateBreadcrumbs(n),this._clicks.splice(i,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const r=this._replay,n=t.scrollAfter&&t.scrollAfter<=this._scollTimeout,i=t.mutationAfter&&t.mutationAfter<=this._threshold,a=!n&&!i,{clickCount:o,clickBreadcrumb:s}=t;if(a){const u=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,l=u1){const u={type:"default",message:s.message,timestamp:s.timestamp,category:"ui.multiClick",data:{...s.data,url:lt.location.href,route:r.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(r,u)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=setTimeout(()=>this._checkClicks(),1e3)}}const O2=["A","BUTTON","INPUT"];function P2(e,t){return!!(!O2.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function I2(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function DI(){return Date.now()/1e3}function x2(e,t){try{if(!C2(t))return;const{source:r}=t.data;if(r===Ce.Mutation&&e.registerMutation(t.timestamp),r===Ce.Scroll&&e.registerScroll(t.timestamp),$2(t)){const{type:n,id:i}=t.data,a=Wa.mirror.getNode(i);a instanceof HTMLElement&&n===$r.Click&&e.registerClick(a)}}catch{}}function C2(e){return e.type===y2}function $2(e){return e.data.source===Ce.MouseInteraction}function Ni(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Nh;(function(e){e[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"})(Nh||(Nh={}));const D2=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled"]);function N2(e){const t={};for(const r in e)if(D2.has(r)){let n=r;(r==="data-testid"||r==="data-test-id")&&(n="testId"),t[n]=e[r]}return t}const A2=e=>t=>{if(!e.isEnabled())return;const r=L2(t);if(!r)return;const n=t.name==="click",i=n&&t.event;n&&e.clickDetector&&i&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&T2(e.clickDetector,r,G3(t.event)),Vp(e,r)};function Y3(e,t){const r=Wa.mirror.getId(e),n=r&&Wa.mirror.getNode(r),i=n&&Wa.mirror.getMeta(n),a=i&&F2(i)?i:null;return{message:t,data:a?{nodeId:r,node:{id:r,tagName:a.tagName,textContent:Array.from(a.childNodes).map(o=>o.type===Nh.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:N2(a.attributes)}}:{}}}function L2(e){const{target:t,message:r}=M2(e);return Ni({category:`ui.${e.name}`,...Y3(t,r)})}function M2(e){const t=e.name==="click";let r,n=null;try{n=t?G3(e.event):V3(e.event),r=Za(n,{maxStringLength:200})||""}catch{r=""}return{target:n,message:r}}function F2(e){return e.type===Nh.Element}function j2(e,t){if(!e.isEnabled())return;e.updateUserActivity();const r=q2(t);r&&Vp(e,r)}function q2(e){const{metaKey:t,shiftKey:r,ctrlKey:n,altKey:i,key:a,target:o}=e;if(!o||U2(o)||!a)return null;const s=t||n||i,u=a.length===1;if(!s&&u)return null;const l=Za(o,{maxStringLength:200})||"",c=Y3(o,l);return Ni({category:"ui.keyDown",message:l,data:{...c.data,metaKey:t,shiftKey:r,ctrlKey:n,altKey:i,key:a}})}function U2(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const NI={resource:G2,paint:H2,navigation:W2};function B2(e){return e.map(z2).filter(Boolean)}function z2(e){return NI[e.entryType]?NI[e.entryType](e):null}function bu(e){return((Zn||lt.performance.timeOrigin)+e)/1e3}function H2(e){const{duration:t,entryType:r,name:n,startTime:i}=e,a=bu(i);return{type:r,name:n,start:a,end:a+t,data:void 0}}function W2(e){const{entryType:t,name:r,decodedBodySize:n,duration:i,domComplete:a,encodedBodySize:o,domContentLoadedEventStart:s,domContentLoadedEventEnd:u,domInteractive:l,loadEventStart:c,loadEventEnd:f,redirectCount:d,startTime:h,transferSize:p,type:v}=e;return i===0?null:{type:`${t}.${v}`,start:bu(h),end:bu(a),name:r,data:{size:p,decodedBodySize:n,encodedBodySize:o,duration:i,domInteractive:l,domContentLoadedEventStart:s,domContentLoadedEventEnd:u,loadEventStart:c,loadEventEnd:f,domComplete:a,redirectCount:d}}}function G2(e){const{entryType:t,initiatorType:r,name:n,responseEnd:i,startTime:a,decodedBodySize:o,encodedBodySize:s,responseStatus:u,transferSize:l}=e;return["fetch","xmlhttprequest"].includes(r)?null:{type:`${t}.${r}`,start:bu(a),end:bu(i),name:n,data:{size:l,statusCode:u,decodedBodySize:o,encodedBodySize:s}}}function V2(e){const t=e.entries,r=t[t.length-1],n=r?r.element:void 0,i=e.value,a=bu(i);return{type:"largest-contentful-paint",name:"largest-contentful-paint",start:a,end:a,data:{value:i,size:i,nodeId:n?Wa.mirror.getId(n):void 0}}}function Y2(e){function t(i){e.performanceEntries.includes(i)||e.performanceEntries.push(i)}function r({entries:i}){i.forEach(t)}const n=[];return["navigation","paint","resource"].forEach(i=>{n.push(Hp(i,r))}),n.push(w3(({metric:i})=>{e.replayPerformanceEntries.push(V2(i))})),()=>{n.forEach(i=>i())}}const Q2='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<>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>h]=l}else for(o=new n(i),a=0;a>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;ad&&(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<e))break;p+=m-(1<>=y;p>0;){var M=o[a].s;g[M]=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>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var a=0;a4&&!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+(X15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=p,P=g,Q=y,R=w;for(B=0;B255){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,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>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}}},L=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<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;$Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;Pnt&&(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&&(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)},O=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},j=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(L(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}();function q(t,n){n||(n={});var r=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e>>8;t=r},d:function(){return~t}}}(),e=t.length;r.p(t);var i,a=L(t,n,10+((i=n).filename?i.filename.length+1:0),8),s=a.length;return 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&&O(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)}}(a,n),O(a,s-8,r.d()),O(a,s-4,e),a}var B=function(){function t(t,n){this.c=S(),this.v=1,j.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),j.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=L(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=S();i.p(n.dictionary),O(t,2,i.d())}}(r,this.o),this.v=0),n&&O(r,r.length-4,this.c.d()),this.ondata(r,n)},t}(),G="undefined"!=typeof TextEncoder&&new TextEncoder,H="undefined"!=typeof TextDecoder&&new TextDecoder;try{H.decode(F,{stream:!0})}catch(t){}var J=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(K(t),this.d=n||!1)},t}();function K(n,r){if(r){for(var e=new t(n.length),i=0;i>1)),o=0,f=function(t){s[o++]=t};for(i=0;is.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)}const N=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(let r=0,e=t.length;r{this._deflatedData.push(t)},this.stream=new J(((t,n)=>{this.deflate.push(t,n)})),this.stream.push("[")}},P={clear:()=>{N.clear()},addEvent:t=>N.addEvent(t),finish:()=>N.finish(),compress:t=>function(t){return q(K(t))}(t)};addEventListener("message",(function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in P&&"function"==typeof P[n])try{const t=P[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});';function K2(){const e=new Blob([Q2]);return URL.createObjectURL(e)}function Nr(e,t){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&(q.info(e),t&&Q3(e))}function eu(e,t){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&(q.info(e),t&&setTimeout(()=>{Q3(e)},0))}function Q3(e){dn().addBreadcrumb({category:"console",data:{logger:"replay"},level:"info",message:e},{level:"info"})}class gk extends Error{constructor(){super(`Event buffer exceeded maximum size of ${fk}.`)}}class K3{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(t){const r=JSON.stringify(t).length;if(this._totalSize+=r,this._totalSize>fk)throw new gk;this.events.push(t)}finish(){return new Promise(t=>{const r=this.events;this.clear(),t(JSON.stringify(r))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(r=>r.timestamp).sort()[0];return t?mk(t):null}}class J2{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,r)=>{this._worker.addEventListener("message",({data:n})=>{n.success?t():r()},{once:!0}),this._worker.addEventListener("error",n=>{r(n)},{once:!0})}),this._ensureReadyPromise)}destroy(){Nr("[Replay] Destroying compression worker"),this._worker.terminate()}postMessage(t,r){const n=this._getAndIncrementId();return new Promise((i,a)=>{const o=({data:s})=>{const u=s;if(u.method===t&&u.id===n){if(this._worker.removeEventListener("message",o),!u.success){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay]",u.response),a(new Error("Error in compression worker"));return}i(u.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:n,method:t,arg:r})})}_getAndIncrementId(){return this._id++}}class X2{constructor(t){this._worker=new J2(t),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(t){const r=mk(t.timestamp);(!this._earliestTimestamp||rfk?Promise.reject(new gk):this._sendEventToWorker(n)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear")}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class Z2{constructor(t){this._fallback=new K3,this._compression=new X2(t),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(t){this._used.hasCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch{Nr("[Replay] Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:r}=this._fallback,n=[];for(const i of t)n.push(this._compression.addEvent(i));this._compression.hasCheckout=r,this._used=this._compression;try{await Promise.all(n)}catch(i){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Replay] Failed to add events when switching buffers.",i)}}}function e7({useCompression:e,workerUrl:t}){if(e&&window.Worker){const r=t7(t);if(r)return r}return Nr("[Replay] Using simple buffer"),new K3}function t7(e){try{const t=e||r7();if(!t)return;Nr(`[Replay] Using compression worker${e?` from ${e}`:""}`);const r=new Worker(t);return new Z2(r)}catch{Nr("[Replay] Failed to create compression worker")}}function r7(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?K2():""}function _k(){try{return"sessionStorage"in lt&&!!lt.sessionStorage}catch{return!1}}function n7(e){i7(),e.session=void 0}function i7(){if(_k())try{lt.sessionStorage.removeItem(lk)}catch{}}function J3(e){return e===void 0?!1:Math.random()"u"||__SENTRY_DEBUG__)&&q.error(n),await e.stop({reason:i});const a=dn().getClient();a&&a.recordDroppedEvent("internal_sdk_error","replay")}}function rz(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const r=mk(t.timestamp);return r+e.timeouts.sessionIdlePausee.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(Nr(`[Replay] Skipping event with timestamp ${r} because it is after maxReplayDuration`,e.getOptions()._experiments.traceInternals),!1):!0}function l7(e,t){try{if(typeof t=="function"&&s7(e))return t(e)}catch(r){return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay] An error occured in the `beforeAddRecordingEvent` callback, skipping the event...",r),null}return e}function nz(e){return!e.type}function Hw(e){return e.type==="transaction"}function c7(e){return e.type==="replay_event"}function LI(e){return e.type==="feedback"}function iz(e){const t=h7();return(r,n)=>{if(!e.isEnabled()||!nz(r)&&!Hw(r))return;const i=n&&n.statusCode;if(!(t&&(!i||i<200||i>=300))){if(Hw(r)){f7(e,r);return}d7(e,r)}}}function f7(e,t){const 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)}function d7(e,t){const r=e.getContext();if(t.event_id&&r.errorIds.size<100&&r.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:n}=e.getOptions();typeof n=="function"&&!n(t)||setTimeout(()=>{e.sendBufferedReplayOrFlush()})}function h7(){const e=dn().getClient();if(!e)return!1;const t=e.getTransport();return t&&t.send.__sentry__baseTransport__||!1}function p7(e,t){return e.type||!e.exception||!e.exception.values||!e.exception.values.length?!1:!!(t.originalException&&t.originalException.__rrweb__)}function v7(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:Ne.Custom,timestamp:t.timestamp*1e3,data:{timestamp:t.timestamp,tag:"breadcrumb",payload:{category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function m7(e,t){return e.recordingMode!=="buffer"||t.message===ck||!t.exception||t.type?!1:J3(e.getOptions().errorSampleRate)}function g7(e,t=!1){const r=t?iz(e):void 0;return Object.assign((n,i)=>e.isEnabled()?c7(n)?(delete n.breadcrumbs,n):!nz(n)&&!Hw(n)&&!LI(n)||!e.checkAndHandleExpiredSession()?n:LI(n)?(v7(e,n),n):p7(n,i)&&!e.getOptions()._experiments.captureExceptions?((typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.log("[Replay] Ignoring error from rrweb internals",n),null):((m7(e,n)||e.recordingMode==="session")&&(n.tags={...n.tags,replayId:e.getSessionId()}),r&&r(n,{statusCode:200}),n):n,{id:"Replay"})}function Yp(e,t){return t.map(({type:r,start:n,end:i,name:a,data:o})=>{const s=e.throttledAddEvent({type:Ne.Custom,timestamp:n,data:{tag:"performanceSpan",payload:{op:r,description:a,startTimestamp:n,endTimestamp:i,data:o}}});return typeof s=="string"?Promise.resolve(null):s})}function _7(e){const{from:t,to:r}=e,n=Date.now()/1e3;return{type:"navigation.push",start:n,end:n,name:r,data:{previous:t}}}function y7(e){return t=>{if(!e.isEnabled())return;const r=_7(t);r!==null&&(e.getContext().urls.push(r.name),e.triggerUserActivity(),e.addUpdate(()=>(Yp(e,[r]),!1)))}}function S7(e,t){return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&e.getOptions()._experiments.traceInternals?!1:J9(t,dn())}function Qp(e,t){e.isEnabled()&&t!==null&&(S7(e,t.name)||e.addUpdate(()=>(Yp(e,[t]),!0)))}function b7(e){const{startTimestamp:t,endTimestamp:r,fetchData:n,response:i}=e;if(!r)return null;const{method:a,url:o}=n;return{type:"resource.fetch",start:t/1e3,end:r/1e3,name:o,data:{method:a,statusCode:i?i.status:void 0}}}function E7(e){return t=>{if(!e.isEnabled())return;const r=b7(t);Qp(e,r)}}function w7(e){const{startTimestamp:t,endTimestamp:r,xhr:n}=e,i=n[Aa];if(!t||!r||!i)return null;const{method:a,url:o,status_code:s}=i;return o===void 0?null:{type:"resource.xhr",name:o,start:t/1e3,end:r/1e3,data:{method:a,statusCode:s}}}function R7(e){return t=>{if(!e.isEnabled())return;const r=w7(t);Qp(e,r)}}function Ah(e,t){if(e)try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const r=sz(e);return t.encode(r).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function az(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function bk(e){try{if(typeof e=="string")return e;if(e instanceof URLSearchParams)return e.toString();if(e instanceof FormData)return sz(e)}catch{(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Replay] Failed to serialize body",e)}}function oz(e,t){if(!t)return null;const{startTimestamp:r,endTimestamp:n,url:i,method:a,statusCode:o,request:s,response:u}=t;return{type:e,start:r/1e3,end:n/1e3,name:i,data:sn({method:a,statusCode:o,request:s,response:u})}}function Ec(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function La(e,t,r){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!r)return{headers:e,size:t};const n={headers:e,size:t},{body:i,warnings:a}=T7(r);return n.body=i,a&&a.length>0&&(n._meta={warnings:a}),n}function Ww(e,t){return Object.keys(e).reduce((r,n)=>{const i=n.toLowerCase();return t.includes(i)&&e[n]&&(r[i]=e[n]),r},{})}function sz(e){return new URLSearchParams(e).toString()}function T7(e){if(!e||typeof e!="string")return{body:e};const t=e.length>wI,r=k7(e);if(t){const n=e.slice(0,wI);return r?{body:n,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${n}…`,warnings:["TEXT_TRUNCATED"]}}if(r)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function k7(e){const t=e[0],r=e[e.length-1];return t==="["&&r==="]"||t==="{"&&r==="}"}function Lh(e,t){const r=O7(e);return Mu(r,t)}function O7(e,t=lt.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(lt.location.origin))return e;const r=new URL(e,t);if(r.origin!==new URL(t).origin)return e;const n=r.href;return!e.endsWith("/")&&n.endsWith("/")?n.slice(0,-1):n}async function P7(e,t,r){try{const n=await x7(e,t,r),i=oz("resource.fetch",n);Qp(r.replay,i)}catch(n){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay] Failed to capture fetch breadcrumb",n)}}function I7(e,t,r){const{input:n,response:i}=t,a=n?uz(n):void 0,o=Ah(a,r.textEncoder),s=i?az(i.headers.get("content-length")):void 0;o!==void 0&&(e.data.request_body_size=o),s!==void 0&&(e.data.response_body_size=s)}async function x7(e,t,r){const n=Date.now(),{startTimestamp:i=n,endTimestamp:a=n}=t,{url:o,method:s,status_code:u=0,request_body_size:l,response_body_size:c}=e.data,f=Lh(o,r.networkDetailAllowUrls)&&!Lh(o,r.networkDetailDenyUrls),d=f?C7(r,t.input,l):Ec(l),h=await $7(f,r,t.response,c);return{startTimestamp:i,endTimestamp:a,url:o,method:s,statusCode:u,request:d,response:h}}function C7({networkCaptureBodies:e,networkRequestHeaders:t},r,n){const i=r?N7(r,t):{};if(!e)return La(i,n,void 0);const a=uz(r),o=bk(a);return La(i,n,o)}async function $7(e,{networkCaptureBodies:t,textEncoder:r,networkResponseHeaders:n},i,a){if(!e&&a!==void 0)return Ec(a);const o=i?lz(i.headers,n):{};if(!i||!t&&a!==void 0)return La(o,a,void 0);try{const s=i.clone(),u=await D7(s),l=u&&u.length&&a===void 0?Ah(u,r):a;return e?t?La(o,l,u):La(o,l,void 0):Ec(l)}catch(s){return(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Replay] Failed to serialize response body",s),La(o,a,void 0)}}async function D7(e){try{return await e.text()}catch{return}}function uz(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function lz(e,t){const r={};return t.forEach(n=>{e.get(n)&&(r[n]=e.get(n))}),r}function N7(e,t){return e.length===1&&typeof e[0]!="string"?MI(e[0],t):e.length===2?MI(e[1],t):{}}function MI(e,t){if(!e)return{};const r=e.headers;return r?r instanceof Headers?lz(r,t):Array.isArray(r)?{}:Ww(r,t):{}}async function A7(e,t,r){try{const n=M7(e,t,r),i=oz("resource.xhr",n);Qp(r.replay,i)}catch(n){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay] Failed to capture xhr breadcrumb",n)}}function L7(e,t,r){const{xhr:n,input:i}=t;if(!n)return;const a=Ah(i,r.textEncoder),o=n.getResponseHeader("content-length")?az(n.getResponseHeader("content-length")):Ah(n.response,r.textEncoder);a!==void 0&&(e.data.request_body_size=a),o!==void 0&&(e.data.response_body_size=o)}function M7(e,t,r){const n=Date.now(),{startTimestamp:i=n,endTimestamp:a=n,input:o,xhr:s}=t,{url:u,method:l,status_code:c=0,request_body_size:f,response_body_size:d}=e.data;if(!u)return null;if(!s||!Lh(u,r.networkDetailAllowUrls)||Lh(u,r.networkDetailDenyUrls)){const S=Ec(f),b=Ec(d);return{startTimestamp:i,endTimestamp:a,url:u,method:l,statusCode:c,request:S,response:b}}const h=s[Aa],p=h?Ww(h.request_headers,r.networkRequestHeaders):{},v=Ww(F7(s),r.networkResponseHeaders),_=r.networkCaptureBodies?bk(o):void 0,m=r.networkCaptureBodies?j7(s):void 0,g=La(p,f,_),y=La(v,d,m);return{startTimestamp:i,endTimestamp:a,url:u,method:l,statusCode:c,request:g,response:y}}function F7(e){const t=e.getAllResponseHeaders();return t?t.split(`\r `).reduce((r,n)=>{const[i,a]=n.split(": ");return r[i.toLowerCase()]=a,r},{}):{}}function j7(e){try{return e.responseText}catch{}try{const t=e.response;return bk(t)}catch{}}function q7(e){const t=dn().getClient();try{const r=new TextEncoder,{networkDetailAllowUrls:n,networkDetailDenyUrls:i,networkCaptureBodies:a,networkRequestHeaders:o,networkResponseHeaders:s}=e.getOptions(),u={replay:e,textEncoder:r,networkDetailAllowUrls:n,networkDetailDenyUrls:i,networkCaptureBodies:a,networkRequestHeaders:o,networkResponseHeaders:s};t&&t.on?t.on("beforeAddBreadcrumb",(l,c)=>U7(u,l,c)):(vr("fetch",E7(e)),vr("xhr",R7(e)))}catch{}}function U7(e,t,r){if(t.data)try{B7(t)&&H7(r)&&(L7(t,r,e),A7(t,r,e)),z7(t)&&W7(r)&&(I7(t,r,e),P7(t,r,e))}catch{(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("Error when enriching network breadcrumb")}}function B7(e){return e.category==="xhr"}function z7(e){return e.category==="fetch"}function H7(e){return e&&e.xhr}function W7(e){return e&&e.response}let FI=null;function G7(e){return!!e.category}const V7=e=>t=>{if(!e.isEnabled())return;const r=Y7(t);r&&Vp(e,r)};function Y7(e){const t=e.getLastBreadcrumb&&e.getLastBreadcrumb();return FI===t||!t||(FI=t,!G7(t)||["fetch","xhr","sentry.event","sentry.transaction"].includes(t.category)||t.category.startsWith("ui."))?null:t.category==="console"?Q7(t):Ni(t)}function Q7(e){const t=e.data&&e.data.arguments;if(!Array.isArray(t)||t.length===0)return Ni(e);let r=!1;const n=t.map(i=>{if(!i)return i;if(typeof i=="string")return i.length>Nf?(r=!0,`${i.slice(0,Nf)}…`):i;if(typeof i=="object")try{const a=kr(i,7);return JSON.stringify(a).length>Nf?(r=!0,`${JSON.stringify(a,null,2).slice(0,Nf)}…`):a}catch{}return i});return Ni({...e,data:{...e.data,arguments:n,...r?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function K7(e){const t=dn().getScope(),r=dn().getClient();t.addScopeListener(V7(e)),vr("dom",A2(e)),vr("history",y7(e)),q7(e);const n=g7(e,!jI(r));r&&r.addEventProcessor?r.addEventProcessor(n):L9(n),jI(r)&&(r.on("afterSendEvent",iz(e)),r.on("createDsc",i=>{const a=e.getSessionId();a&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(i.replay_id=a)}),r.on("startTransaction",i=>{e.lastTransaction=i}),r.on("finishTransaction",i=>{e.lastTransaction=i}))}function jI(e){return!!(e&&e.on)}async function J7(e){try{return Promise.all(Yp(e,[X7(lt.performance.memory)]))}catch{return[]}}function X7(e){const{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}}}}function Z7(e,t,r){let n,i,a;const o=r&&r.maxWait?Math.max(r.maxWait,t):0;function s(){return u(),n=e(),n}function u(){i!==void 0&&clearTimeout(i),a!==void 0&&clearTimeout(a),i=a=void 0}function l(){return i!==void 0||a!==void 0?s():n}function c(){return i&&clearTimeout(i),i=setTimeout(s,t),o&&a===void 0&&(a=setTimeout(s,o)),n}return c.cancel=u,c.flush=l,c}function eJ(e){let t=!1;return(r,n)=>{if(!e.checkAndHandleExpiredSession()){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.warn("[Replay] Received replay event after session expired.");return}const i=n||!t;t=!0,e.clickDetector&&x2(e.clickDetector,r),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&i&&e.setInitialState(),!Sk(e,r,i))return!0;if(!i)return!1;if(rJ(e,i),e.session&&e.session.previousSessionId)return!0;if(e.recordingMode==="buffer"&&e.session&&e.eventBuffer){const a=e.eventBuffer.getEarliestTimestamp();a&&(Nr(`[Replay] Updating session start time to earliest event in buffer to ${new Date(a)}`,e.getOptions()._experiments.traceInternals),e.session.started=a,e.getOptions().stickySession&&yk(e.session))}return e.recordingMode==="session"&&e.flush(),!0})}}function tJ(e){const t=e.getOptions();return{type:Ne.Custom,timestamp:Date.now(),data:{tag:"options",payload:{sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:e.eventBuffer?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function rJ(e,t){!t||!e.session||e.session.segmentId!==0||Sk(e,tJ(e),!1)}function nJ(e,t,r,n){return ju(BB(e,QT(e),n,r),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function iJ({recordingData:e,headers:t}){let r;const n=`${JSON.stringify(t)} `;if(typeof e=="string")r=`${n}${e}`;else{const a=new TextEncoder().encode(n);r=new Uint8Array(a.length+e.length),r.set(a),r.set(e,a.length)}return r}async function aJ({client:e,scope:t,replayId:r,event:n}){const i=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,a={event_id:r,integrations:i};e.emit&&e.emit("preprocessEvent",n,a);const o=await W9(e.getOptions(),n,a,t,e);if(!o)return null;o.platform=o.platform||"javascript";const s=e.getSdkMetadata&&e.getSdkMetadata(),{name:u,version:l}=s&&s.sdk||{};return o.sdk={...o.sdk,name:u||"sentry.javascript.unknown",version:l||"0.0.0"},o}async function oJ({recordingData:e,replayId:t,segmentId:r,eventContext:n,timestamp:i,session:a}){const o=iJ({recordingData:e,headers:{segment_id:r}}),{urls:s,errorIds:u,traceIds:l,initialTimestamp:c}=n,f=dn(),d=f.getClient(),h=f.getScope(),p=d&&d.getTransport(),v=d&&d.getDsn();if(!d||!p||!v||!a.sampled)return;const _={type:r6,replay_start_timestamp:c/1e3,timestamp:i/1e3,error_ids:u,trace_ids:l,urls:s,replay_id:t,segment_id:r,replay_type:a.sampled},m=await aJ({scope:h,client:d,replayId:t,event:_});if(!m){d.recordDroppedEvent("event_processor","replay",_),Nr("An event processor returned `null`, will not send event.");return}delete m.sdkProcessingMetadata;const g=nJ(m,o,v,d.getOptions().tunnel);let y;try{y=await p.send(g)}catch(b){const E=new Error(ck);try{E.cause=b}catch{}throw E}if(!y)return y;if(typeof y.statusCode=="number"&&(y.statusCode<200||y.statusCode>=300))throw new cz(y.statusCode);const S=HB({},y);if(zB(S,"replay"))throw new fz(S);return y}class cz extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class fz extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function dz(e,t={count:0,interval:u6}){const{recordingData:r,options:n}=e;if(r.length)try{return await oJ(e),!0}catch(i){if(i instanceof cz||i instanceof fz)throw i;if(H9("Replays",{_retryCount:t.count}),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&n._experiments&&n._experiments.captureExceptions&&c3(i),t.count>=l6){const a=new Error(`${ck} - max retries exceeded`);try{a.cause=i}catch{}throw a}return t.interval*=++t.count,new Promise((a,o)=>{setTimeout(async()=>{try{await dz(e,t),a(!0)}catch(s){o(s)}},t.interval)})}}const hz="__THROTTLED",sJ="__SKIPPED";function uJ(e,t,r){const n=new Map,i=s=>{const u=s-r;n.forEach((l,c)=>{c[...n.values()].reduce((s,u)=>s+u,0);let o=!1;return(...s)=>{const u=Math.floor(Date.now()/1e3);if(i(u),a()>=t){const c=o;return o=!0,c?sJ:hz}o=!1;const l=n.get(u)||0;return n.set(u,l+1),e(...s)}}class wa{constructor({options:t,recordingOptions:r}){wa.prototype.__init.call(this),wa.prototype.__init2.call(this),wa.prototype.__init3.call(this),wa.prototype.__init4.call(this),wa.prototype.__init5.call(this),wa.prototype.__init6.call(this),this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:n6,sessionIdleExpire:i6},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=r,this._options=t,this._debouncedFlush=Z7(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=uJ((o,s)=>u7(this,o,s),300,5);const{slowClickTimeout:n,slowClickIgnoreSelectors:i}=this.getOptions(),a=n?{threshold:Math.min(c6,n),timeout:n,scrollTimeout:f6,ignoreSelector:i?i.join(","):""}:void 0;a&&(this.clickDetector=new k2(this,a))}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}getOptions(){return this._options}initializeSampling(t){const{errorSampleRate:r,sessionSampleRate:n}=this._options;if(!(r<=0&&n<=0)){if(this._initializeSessionForSampling(t),!this.session){this._handleException(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",eu(`[Replay] Starting replay in ${this.recordingMode} mode`,this._options._experiments.traceInternals),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session")throw new Error("Replay recording is already in progress");if(this._isEnabled&&this.recordingMode==="buffer")throw new Error("Replay buffering is in progress, call `flush()` to save the replay");eu("[Replay] Starting replay in session mode",this._options._experiments.traceInternals);const t=jm({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire,traceInternals:this._options._experiments.traceInternals},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this._initializeRecording()}startBuffering(){if(this._isEnabled)throw new Error("Replay recording is already in progress");eu("[Replay] Starting replay in buffer mode",this._options._experiments.traceInternals);const t=jm({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,traceInternals:this._options._experiments.traceInternals},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{this._stopRecording=Wa({...this._recordingOptions,...this.recordingMode==="buffer"&&{checkoutEveryNms:s6},emit:eJ(this),onMutation:this._onMutationHandler})}catch(t){this._handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this._handleException(t),!1}}async stop({forceFlush:t=!1,reason:r}={}){if(this._isEnabled){this._isEnabled=!1;try{Nr(`[Replay] Stopping Replay${r?` triggered by ${r}`:""}`,this._options._experiments.traceInternals),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer&&this.eventBuffer.destroy(),this.eventBuffer=null,n7(this)}catch(n){this._handleException(n)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),Nr("[Replay] Pausing replay",this._options._experiments.traceInternals))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),Nr("[Replay] Resuming replay",this._options._experiments.traceInternals))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const r=Date.now();Nr("[Replay] Converting buffer to session",this._options._experiments.traceInternals),await this.flushImmediate();const n=this.stopRecording();!t||!n||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this._updateUserActivity(r),this._updateSessionActivity(r),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const r=t();this.recordingMode!=="buffer"&&r!==!0&&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 this.recordingMode==="buffer"?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&&zw(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${lt.location.pathname}${lt.location.hash}${lt.location.search}`,r=`${lt.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=r,this._context.initialTimestamp=Date.now(),this._context.urls.push(r)}throttledAddEvent(t,r){const n=this._throttledAddEvent(t,r);if(n===hz){const i=Ni({category:"replay.throttled"});this.addUpdate(()=>!Sk(this,{type:S2,timestamp:i.timestamp||0,data:{tag:"breadcrumb",payload:i,metric:!0}}))}return n}getCurrentRoute(){const t=this.lastTransaction||dn().getScope().getTransaction();if(!(!t||!["route","custom"].includes(t.metadata.source)))return t.name}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=e7({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_handleException(t){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay]",t),(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&this._options._experiments&&this._options._experiments.captureExceptions&&c3(t)}_initializeSessionForSampling(t){const r=this._options.errorSampleRate>0,n=jm({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,traceInternals:this._options._experiments.traceInternals,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:r});this.session=n}_checkSession(){if(!this.session)return!1;const t=this.session;return ez(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{lt.document.addEventListener("visibilitychange",this._handleVisibilityChange),lt.addEventListener("blur",this._handleWindowBlur),lt.addEventListener("focus",this._handleWindowFocus),lt.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(K7(this),this._hasInitializedCoreListeners=!0)}catch(t){this._handleException(t)}this._performanceCleanupCallback=Y2(this)}_removeListeners(){try{lt.document.removeEventListener("visibilitychange",this._handleVisibilityChange),lt.removeEventListener("blur",this._handleWindowBlur),lt.removeEventListener("focus",this._handleWindowFocus),lt.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this._handleException(t)}}__init(){this._handleVisibilityChange=()=>{lt.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroundTasks()}}__init2(){this._handleWindowBlur=()=>{const t=Ni({category:"ui.blur"});this._doChangeToBackgroundTasks(t)}}__init3(){this._handleWindowFocus=()=>{const t=Ni({category:"ui.focus"});this._doChangeToForegroundTasks(t)}}__init4(){this._handleKeyboardEvent=t=>{j2(this,t)}}_doChangeToBackgroundTasks(t){!this.session||Z3(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){Nr("[Replay] Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:Ne.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){const t=B2(this.performanceEntries).concat(this.replayPerformanceEntries);return this.performanceEntries=[],this.replayPerformanceEntries=[],Promise.all(Yp(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:r}=this;if(!t||!r||t.segmentId)return;const n=r.getEarliestTimestamp();n&&n"u"||__SENTRY_DEBUG__)&&q.error("[Replay] No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!(!this.eventBuffer||!this.eventBuffer.hasEvents)&&(await J7(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const r=Date.now();if(r-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const n=this._popEventContext(),i=this.session.segmentId++;this._maybeSaveSession();const a=await this.eventBuffer.finish();await dz({replayId:t,recordingData:a,segmentId:i,eventContext:n,session:this.session,options:this.getOptions(),timestamp:r})}catch(r){this._handleException(r),this.stop({reason:"sendReplay"});const n=dn().getClient();n&&n.recordDroppedEvent("send_error","replay")}}__init5(){this._flush=async({force:t=!1}={})=>{if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error("[Replay] Attempting to finish replay event after session expired.");return}if(!this.session)return;const r=this.session.started,i=Date.now()-r;this._debouncedFlush.cancel();const a=ithis._options.maxReplayDuration+5e3;if(a||o){Nr(`[Replay] Session duration (${Math.floor(i/1e3)}s) is too ${a?"short":"long"}, not sending replay.`,this._options._experiments.traceInternals),a&&this._debouncedFlush();return}const s=this.eventBuffer;if(s&&this.session.segmentId===0&&!s.hasCheckout&&Nr("[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(u){(typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__)&&q.error(u)}finally{this._debouncedFlush()}}}_maybeSaveSession(){this.session&&this._options.stickySession&&yk(this.session)}__init6(){this._onMutationHandler=t=>{const r=t.length,n=this._options.mutationLimit,i=this._options.mutationBreadcrumbLimit,a=n&&r>n;if(r>i||a){const o=Ni({category:"replay.mutations",data:{count:r,limit:a}});this._createCustomBreadcrumb(o)}return a?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}}function cl(e,t,r,n){const i=typeof n=="string"?n.split(","):[],a=[...e,...i,...t];return typeof r<"u"&&(typeof r=="string"&&a.push(`.${r}`),console.warn("[Replay] You are using a deprecated configuration item for privacy. Read the documentation on how to use the new privacy configuration.")),a.join(",")}function lJ({mask:e,unmask:t,block:r,unblock:n,ignore:i,blockClass:a,blockSelector:o,maskTextClass:s,maskTextSelector:u,ignoreClass:l}){const c=['base[href="/"]'],f=cl(e,[".sentry-mask","[data-sentry-mask]"],s,u),d=cl(t,[".sentry-unmask","[data-sentry-unmask]"]),h={maskTextSelector:f,unmaskTextSelector:d,blockSelector:cl(r,[".sentry-block","[data-sentry-block]",...c],a,o),unblockSelector:cl(n,[".sentry-unblock","[data-sentry-unblock]"]),ignoreSelector:cl(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'],l)};return a instanceof RegExp&&(h.blockClass=a),s instanceof RegExp&&(h.maskTextClass=s),h}function cJ({el:e,key:t,maskAttributes:r,maskAllText:n,privacyOptions:i,value:a}){return!n||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?a:r.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?a.replace(/[\S]/g,"*"):a}const qI='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',fJ=["content-length","content-type","accept"];let UI=!1;class Kp{static __initStatic(){this.id="Replay"}constructor({flushMinDelay:t=a6,flushMaxDelay:r=o6,minReplayDuration:n=d6,maxReplayDuration:i=RI,stickySession:a=!0,useCompression:o=!0,workerUrl:s,_experiments:u={},sessionSampleRate:l,errorSampleRate:c,maskAllText:f=!0,maskAllInputs:d=!0,blockAllMedia:h=!0,mutationBreadcrumbLimit:p=750,mutationLimit:v=1e4,slowClickTimeout:_=7e3,slowClickIgnoreSelectors:m=[],networkDetailAllowUrls:g=[],networkDetailDenyUrls:y=[],networkCaptureBodies:S=!0,networkRequestHeaders:b=[],networkResponseHeaders:E=[],mask:w=[],maskAttributes:R=["title","placeholder"],unmask:O=[],block:k=[],unblock:C=[],ignore:T=[],maskFn:$,beforeAddRecordingEvent:L,beforeErrorSampling:G,blockClass:Y,blockSelector:B,maskInputOptions:D,maskTextClass:F,maskTextSelector:z,ignoreClass:ee}={}){this.name=Kp.id;const Z=lJ({mask:w,unmask:O,block:k,unblock:C,ignore:T,blockClass:Y,blockSelector:B,maskTextClass:F,maskTextSelector:z,ignoreClass:ee});if(this._recordingOptions={maskAllInputs:d,maskAllText:f,maskInputOptions:{...D||{},password:!0},maskTextFn:$,maskInputFn:$,maskAttributeFn:(W,Q,ae)=>cJ({maskAttributes:R,maskAllText:f,privacyOptions:Z,key:W,value:Q,el:ae}),...Z,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:W=>{try{W.__rrweb__=!0}catch{}}},this._initialOptions={flushMinDelay:t,flushMaxDelay:r,minReplayDuration:Math.min(n,h6),maxReplayDuration:Math.min(i,RI),stickySession:a,sessionSampleRate:l,errorSampleRate:c,useCompression:o,workerUrl:s,blockAllMedia:h,maskAllInputs:d,maskAllText:f,mutationBreadcrumbLimit:p,mutationLimit:v,slowClickTimeout:_,slowClickIgnoreSelectors:m,networkDetailAllowUrls:g,networkDetailDenyUrls:y,networkCaptureBodies:S,networkRequestHeaders:BI(b),networkResponseHeaders:BI(E),beforeAddRecordingEvent:L,beforeErrorSampling:G,_experiments:u},typeof l=="number"&&(console.warn(`[Replay] You are passing \`sessionSampleRate\` to the Replay integration. This option is deprecated and will be removed soon. Instead, configure \`replaysSessionSampleRate\` directly in the SDK init options, e.g.: Sentry.init({ replaysSessionSampleRate: ${l} })`),this._initialOptions.sessionSampleRate=l),typeof c=="number"&&(console.warn(`[Replay] You are passing \`errorSampleRate\` to the Replay integration. This option is deprecated and will be removed soon. Instead, configure \`replaysOnErrorSampleRate\` directly in the SDK init options, e.g.: Sentry.init({ replaysOnErrorSampleRate: ${c} })`),this._initialOptions.errorSampleRate=c),this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${qI}`:qI),this._isInitialized&&YP())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return UI}set _isInitialized(t){UI=t}setupOnce(){YP()&&(this._setup(),setTimeout(()=>this._initialize()))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return!this._replay||!this._replay.isEnabled()?Promise.resolve():this._replay.sendBufferedReplayOrFlush(t)}getReplayId(){if(!(!this._replay||!this._replay.isEnabled()))return this._replay.getSessionId()}_initialize(){this._replay&&this._replay.initializeSampling()}_setup(){const t=dJ(this._initialOptions);this._replay=new wa({options:t,recordingOptions:this._recordingOptions})}}Kp.__initStatic();function dJ(e){const t=dn().getClient(),r=t&&t.getOptions(),n={sessionSampleRate:0,errorSampleRate:0,...sn(e)};return r?(e.sessionSampleRate==null&&e.errorSampleRate==null&&r.replaysSessionSampleRate==null&&r.replaysOnErrorSampleRate==null&&console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set."),typeof r.replaysSessionSampleRate=="number"&&(n.sessionSampleRate=r.replaysSessionSampleRate),typeof r.replaysOnErrorSampleRate=="number"&&(n.errorSampleRate=r.replaysOnErrorSampleRate),n):(console.warn("SDK client is not available."),n)}function BI(e){return[...fJ,...e.map(t=>t.toLowerCase())]}function hJ(e){const t={_metadata:{},...e};t._metadata.sdk=t._metadata.sdk||{name:"sentry.javascript.react",packages:[{name:"npm:@sentry/react",version:Rh}],version:Rh},N9(t)}function zI(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function ke(e){for(var t=1;t=0||(c[u]=o[u]);return c}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(n=0;n=0||Object.prototype.propertyIsEnumerable.call(e,r)&&(i[r]=e[r])}return i}function vJ(e,t){if(t&&(typeof t=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(r){if(r===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return r}(e)}function vz(e){var t=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var r,n=Mh(e);if(t){var i=Mh(this).constructor;r=Reflect.construct(n,arguments,i)}else r=n.apply(this,arguments);return vJ(this,r)}}function Ji(e,t){return function(r){if(Array.isArray(r))return r}(e)||function(r,n){var i=r==null?null:typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(i!=null){var a,o,s=[],u=!0,l=!1;try{for(i=i.call(r);!(u=(a=i.next()).done)&&(s.push(a.value),!n||s.length!==n);u=!0);}catch(c){l=!0,o=c}finally{try{u||i.return==null||i.return()}finally{if(l)throw o}}return s}}(e,t)||Ek(e,t)||function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Vw(e){return function(t){if(Array.isArray(t))return Yw(t)}(e)||function(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}(e)||Ek(e)||function(){throw new TypeError(`Invalid attempt to spread non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}()}function Ek(e,t){if(e){if(typeof e=="string")return Yw(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Yw(e,t):void 0}}function Yw(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r=e.length?{done:!0}:{done:!1,value:e[n++]}},e:function(u){throw u},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var a,o=!0,s=!1;return{s:function(){r=r.call(e)},n:function(){var u=r.next();return o=u.done,u},e:function(u){s=!0,a=u},f:function(){try{o||r.return==null||r.return()}finally{if(s)throw a}}}}var Pn={DEBUG:!1,LIB_VERSION:"1.81.0"},mz=Array.prototype,gz=Object.prototype,wk=gz.toString,mJ=gz.hasOwnProperty,he=typeof window<"u"?window:{},Eo=he.navigator||{userAgent:""},Ct=he.document||{},jn=Eo.userAgent,gJ=["localhost","127.0.0.1"],WI=mz.forEach,GI=mz.indexOf,_J=Array.isArray,Rk={},Ge={log:function(){if(Pn.DEBUG&&!kn(window.console)&&window.console){for(var e=("__rrweb_original__"in window.console.log)?window.console.log.__rrweb_original__:window.console.log,t=arguments.length,r=new Array(t),n=0;n1?t-1:0),n=1;n0&&(t[n]=r)}),t},SJ=["$performance_raw"];function bJ(e,t){return r=e,n=function(a,o){return o&&SJ.indexOf(o)>-1?a:typeof a=="string"&&t!==null?a.slice(0,t):a},i=new Set,function a(o,s){return o!==Object(o)?n?n(o,s):o:i.has(o)?void 0:(i.add(o),Ci(o)?(u=[],qi(o,function(l){u.push(a(l))})):(u={},it(o,function(l,c){i.has(l)||(u[c]=a(l,c))})),u);var u}(r);var r,n,i}function Tk(e){var t,r,n,i,a,o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",s=0,u=0,l="",c=[];if(!e)return e;e=EJ(e);do t=(a=e.charCodeAt(s++)<<16|e.charCodeAt(s++)<<8|e.charCodeAt(s++))>>18&63,r=a>>12&63,n=a>>6&63,i=63&a,c[u++]=o.charAt(t)+o.charAt(r)+o.charAt(n)+o.charAt(i);while(s127&&o<2048?String.fromCharCode(o>>6|192,63&o|128):String.fromCharCode(o>>12|224,o>>6&63|128,63&o|128),s!==null&&(r>t&&(a+=e.substring(t,r)),a+=s,t=r=i+1)}return r>t&&(a+=e.substring(t,e.length)),a},wJ=["ahrefsbot","applebot","baiduspider","bingbot","bingpreview","bot.htm","bot.php","crawler","duckduckbot","facebookexternal","facebookcatalog","gptbot","hubspot","linkedinbot","mj12bot","petalbot","pinterest","prerender","rogerbot","screaming frog","semrushbot","sitebulb","twitterbot","yahoo! slurp","yandexbot","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleweblight","mediapartners-google","storebot-google"],RJ=function(e,t){return wJ.concat(t).some(function(r){return e.includes?e.includes(r):e.indexOf(r)!==-1})},VI=function(e,t){var r=t.replace(/[[]/,"\\[").replace(/[\]]/,"\\]"),n=new RegExp("[\\?&]"+r+"=([^&#]*)").exec(e);if(n===null||n&&typeof n[1]!="string"&&n[1].length)return"";var i=n[1];try{i=decodeURIComponent(i)}catch{Ge.error("Skipping decoding for malformed query param: "+i)}return i.replace(/\+/g," ")},YI=function(e,t){var r=e.match(new RegExp(t+"=([^&]*)"));return r?r[1]:null},Yl=function(){function e(t){return t&&(t.preventDefault=e.preventDefault,t.stopPropagation=e.stopPropagation),t}return e.preventDefault=function(){this.returnValue=!1},e.stopPropagation=function(){this.cancelBubble=!0},function(t,r,n,i,a){if(t)if(t.addEventListener&&!i)t.addEventListener(r,n,!!a);else{var o="on"+r,s=t[o];t[o]=function(u,l,c){return function(f){if(f=f||e(window.event)){var d,h=!0;_z(c)&&(d=c(f));var p=l.call(u,f);return d!==!1&&p!==!1||(h=!1),h}}}(t,n,s)}else Ge.error("No valid element provided to register_event")}}();function Fh(e,t){var r=function(){var n=Ct.createElement("script");n.type="text/javascript",n.src=e,n.onload=function(o){return t(void 0,o)},n.onerror=function(o){return t(o)};var i,a=Ct.querySelectorAll("body > script");a.length>0?(i=a[0].parentNode)===null||i===void 0||i.insertBefore(n,a[0]):Ct.body.appendChild(n)};Ct.body?r():Ct.addEventListener("DOMContentLoaded",r)}var dr={campaignParams:function(e){var t=["utm_source","utm_medium","utm_campaign","utm_content","utm_term","gclid","fbclid","msclkid"].concat(e||[]),r={};return it(t,function(n){var i=VI(Ct.URL,n);i.length&&(r[n]=i)}),r},searchEngine:function(){var e=Ct.referrer;return e?e.search("https?://(.*)google.([^/?]*)")===0?"google":e.search("https?://(.*)bing.com")===0?"bing":e.search("https?://(.*)yahoo.com")===0?"yahoo":e.search("https?://(.*)duckduckgo.com")===0?"duckduckgo":null:null},searchInfo:function(){var e=dr.searchEngine(),t=e!="yahoo"?"q":"p",r={};if(e!==null){r.$search_engine=e;var n=VI(Ct.referrer,t);n.length&&(r.ph_keyword=n)}return r},browser:function(e,t,r){return t=t||"",r||rt(e," OPR/")?rt(e,"Mini")?"Opera Mini":"Opera":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":rt(e,"IEMobile")||rt(e,"WPDesktop")?"Internet Explorer Mobile":rt(e,"SamsungBrowser/")?"Samsung Internet":rt(e,"Edge")||rt(e,"Edg/")?"Microsoft Edge":rt(e,"FBIOS")?"Facebook Mobile":rt(e,"Chrome")?"Chrome":rt(e,"CriOS")?"Chrome iOS":rt(e,"UCWEB")||rt(e,"UCBrowser")?"UC Browser":rt(e,"FxiOS")?"Firefox iOS":rt(t,"Apple")?rt(e,"Mobile")?"Mobile Safari":"Safari":rt(e,"Android")?"Android Mobile":rt(e,"Konqueror")?"Konqueror":rt(e,"Firefox")?"Firefox":rt(e,"MSIE")||rt(e,"Trident/")?"Internet Explorer":rt(e,"Gecko")?"Mozilla":""},browserVersion:function(e,t,r){var n={"Internet Explorer Mobile":/rv:(\d+(\.\d+)?)/,"Microsoft Edge":/Edge?\/(\d+(\.\d+)?)/,Chrome:/Chrome\/(\d+(\.\d+)?)/,"Chrome iOS":/CriOS\/(\d+(\.\d+)?)/,"UC Browser":/(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/,Safari:/Version\/(\d+(\.\d+)?)/,"Mobile Safari":/Version\/(\d+(\.\d+)?)/,Opera:/(Opera|OPR)\/(\d+(\.\d+)?)/,Firefox:/Firefox\/(\d+(\.\d+)?)/,"Firefox iOS":/FxiOS\/(\d+(\.\d+)?)/,Konqueror:/Konqueror:(\d+(\.\d+)?)/,BlackBerry:/BlackBerry (\d+(\.\d+)?)/,"Android Mobile":/android\s(\d+(\.\d+)?)/,"Samsung Internet":/SamsungBrowser\/(\d+(\.\d+)?)/,"Internet Explorer":/(rv:|MSIE )(\d+(\.\d+)?)/,Mozilla:/rv:(\d+(\.\d+)?)/}[dr.browser(e,t,r)];if(n===void 0)return null;var i=e.match(n);return i?parseFloat(i[i.length-2]):null},browserLanguage:function(){return Eo.language||Eo.userLanguage},os:function(e){if(/Windows/i.test(e)){if(/Phone/.test(e)||/WPDesktop/.test(e))return{os_name:"Windows Phone",os_version:""};var t=/Windows NT ([0-9.]+)/i.exec(e);return t&&t[1]?{os_name:"Windows",os_version:t[1]}:{os_name:"Windows",os_version:""}}if(/(iPhone|iPad|iPod)/.test(e)){var r=/OS (\d+)_(\d+)_?(\d+)?/i.exec(e);return r&&r[1]?{os_name:"iOS",os_version:[r[1],r[2],r[3]||"0"].join(".")}:{os_name:"iOS",os_version:""}}if(/Android/.test(e)){var n=/Android (\d+)\.(\d+)\.?(\d+)?/i.exec(e);return n&&n[1]?{os_name:"Android",os_version:[n[1],n[2],n[3]||"0"].join(".")}:{os_name:"Android",os_version:""}}if(/(BlackBerry|PlayBook|BB10)/i.test(e))return{os_name:"BlackBerry",os_version:""};if(/Mac/i.test(e)){var i=/Mac OS X (\d+)[_.](\d+)[_.]?(\d+)?/i.exec(e);return i&&i[1]?{os_name:"Mac OS X",os_version:[i[1],i[2],i[3]||"0"].join(".")}:{os_name:"Mac OS X",os_version:""}}return/Linux/.test(e)?{os_name:"Linux",os_version:""}:/CrOS/.test(e)?{os_name:"Chrome OS",os_version:""}:{os_name:"",os_version:""}},device:function(e){return/Windows Phone/i.test(e)||/WPDesktop/.test(e)?"Windows Phone":/iPad/.test(e)?"iPad":/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":/Android/.test(e)&&!/Mobile/.test(e)?"Android Tablet":/Android/.test(e)?"Android":""},deviceType:function(e){var t=this.device(e);return t==="iPad"||t==="Android Tablet"?"Tablet":t?"Mobile":"Desktop"},referrer:function(){return Ct.referrer||"$direct"},referringDomain:function(){if(!Ct.referrer)return"$direct";var e=Ct.createElement("a");return e.href=Ct.referrer,e.host},properties:function(){var e=dr.os(jn),t=e.os_name,r=e.os_version;return wr(Jw({$os:t,$os_version:r,$browser:dr.browser(jn,Eo.vendor,he.opera),$device:dr.device(jn),$device_type:dr.deviceType(jn)}),{$current_url:he==null?void 0:he.location.href,$host:he==null?void 0:he.location.host,$pathname:he==null?void 0:he.location.pathname,$browser_version:dr.browserVersion(jn,Eo.vendor,he.opera),$browser_language:dr.browserLanguage(),$screen_height:he==null?void 0:he.screen.height,$screen_width:he==null?void 0:he.screen.width,$viewport_height:he==null?void 0:he.innerHeight,$viewport_width:he==null?void 0:he.innerWidth,$lib:"web",$lib_version:Pn.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:Sz()/1e3})},people_properties:function(){var e=dr.os(jn),t=e.os_name,r=e.os_version;return wr(Jw({$os:t,$os_version:r,$browser:dr.browser(jn,Eo.vendor,he.opera)}),{$browser_version:dr.browserVersion(jn,Eo.vendor,he.opera)})}};function jh(e){switch(Ga(e.className)){case"string":return e.className;case"object":return("baseVal"in e.className?e.className.baseVal:null)||e.getAttribute("class")||"";default:return""}}function qh(e){var t="";return Od(e)&&!wz(e)&&e.childNodes&&e.childNodes.length&&it(e.childNodes,function(r){Ez(r)&&r.textContent&&(t+=Qw(r.textContent).split(/(\s+)/).filter(js).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255))}),Qw(t)}function QI(e){return!!e&&e.nodeType===1}function jo(e,t){return!!e&&!!e.tagName&&e.tagName.toLowerCase()===t.toLowerCase()}function Ez(e){return!!e&&e.nodeType===3}function KI(e){return!!e&&e.nodeType===11}var qm=["a","button","form","input","select","textarea","label"];function Od(e){for(var t=e;t.parentNode&&!jo(t,"body");t=t.parentNode){var r=jh(t).split(" ");if(rt(r,"ph-sensitive")||rt(r,"ph-no-capture"))return!1}if(rt(jh(e).split(" "),"ph-include"))return!0;var n=e.type||"";if(typeof n=="string")switch(n.toLowerCase()){case"hidden":case"password":return!1}var i=e.name||e.id||"";return!(typeof i=="string"&&/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(i.replace(/[^a-zA-Z0-9]/g,"")))}function wz(e){return!!(jo(e,"input")&&!["button","checkbox","submit","reset"].includes(e.type)||jo(e,"select")||jo(e,"textarea")||e.getAttribute("contenteditable")==="true")}function js(e){return!(e===null||kn(e)||typeof e=="string"&&(e=Qw(e),/^(?:(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11}))$/.test((e||"").replace(/[- ]/g,""))||/(^\d{3}-?\d{2}-?\d{4}$)/.test(e)))}function JI(e){var t=qh(e);return js(t="".concat(t," ").concat(Rz(e)).trim())?t:""}function Rz(e){var t="";return e&&e.childNodes&&e.childNodes.length&&it(e.childNodes,function(r){var n;if(r&&((n=r.tagName)===null||n===void 0?void 0:n.toLowerCase())==="span")try{var i=qh(r);t="".concat(t," ").concat(i).trim(),r.childNodes&&r.childNodes.length&&(t="".concat(t," ").concat(Rz(r)).trim())}catch(a){console.error(a)}}),t}var TJ=function(){function e(t){Nt(this,e),this.clicks=[],this.enabled=t}return At(e,[{key:"isRageClick",value:function(t,r,n){if(!this.enabled)return!1;var i=this.clicks[this.clicks.length-1];if(i&&Math.abs(t-i.x)+Math.abs(r-i.y)<30&&n-i.timestamp<1e3){if(this.clicks.push({x:t,y:r,timestamp:n}),this.clicks.length===3)return!0}else this.clicks=[{x:t,y:r,timestamp:n}];return!1}}]),e}(),Tz="$people_distinct_id",Pd="__alias",xl="__timers",XI="$autocapture_disabled_server_side",Xw="$session_recording_enabled_server_side",ZI="$console_log_recording_enabled_server_side",ex="$session_recording_recorder_version_server_side",Uh="$sesid",qs="$enabled_feature_flags",Zw="$early_access_features",Us="$stored_person_properties",Ra="$stored_group_properties",eR="$surveys",Bh="$flag_call_reported",tR="$user_state",rR="$posthog_quota_limited",kJ=[Tz,Pd,"__cmpns",xl,Xw,Uh,qs,tR,rR,Zw,Ra,Us,eR,Bh];function Um(e,t){return t.length>e?t.slice(0,e)+"...":t}var $a={_initializedTokens:[],_isDisabledServerSide:null,_isAutocaptureEnabled:!1,_setIsAutocaptureEnabled:function(e){var t,r=this._isDisabledServerSide===null?!((t=e.persistence)===null||t===void 0||!t.props[XI]):this._isDisabledServerSide,n=!!e.get_config("autocapture");this._isAutocaptureEnabled=n&&!r},_previousElementSibling:function(e){if(e.previousElementSibling)return e.previousElementSibling;var t=e;do t=t.previousSibling;while(t&&!QI(t));return t},_getAugmentPropertiesFromElement:function(e){if(!Od(e))return{};var t={};return it(e.attributes,function(r){if(r.name.indexOf("data-ph-capture-attribute")===0){var n=r.name.replace("data-ph-capture-attribute-",""),i=r.value;n&&i&&js(i)&&(t[n]=i)}}),t},_getPropertiesFromElement:function(e,t,r){var n,i=e.tagName.toLowerCase(),a={tag_name:i};qm.indexOf(i)>-1&&!r&&(i.toLowerCase()==="a"||i.toLowerCase()==="button"?a.$el_text=Um(1024,JI(e)):a.$el_text=Um(1024,qh(e)));var o=jh(e);o.length>0&&(a.classes=o.split(" ").filter(function(f){return f!==""}));var s=(n=this.config)===null||n===void 0?void 0:n.element_attribute_ignorelist;it(e.attributes,function(f){var d;wz(e)&&["name","id","class"].indexOf(f.name)===-1||s!=null&&s.includes(f.name)||!t&&js(f.value)&&(typeof(d=f.name)!="string"||d.substring(0,10)!=="_ngcontent"&&d.substring(0,7)!=="_nghost")&&(a["attr__"+f.name]=Um(1024,f.value))});for(var u=1,l=1,c=e;c=this._previousElementSibling(c);)u++,c.tagName===e.tagName&&l++;return a.nth_child=u,a.nth_of_type=l,a},_getDefaultProperties:function(e){return{$event_type:e,$ce_version:1}},_extractCustomPropertyValue:function(e){var t=[];return it(document.querySelectorAll(e.css_selector),function(r){var n;["input","select"].indexOf(r.tagName.toLowerCase())>-1?n=r.value:r.textContent&&(n=r.textContent),js(n)&&t.push(n)}),t.join(", ")},_getCustomProperties:function(e){var t=this,r={};return it(this._customProperties,function(n){it(n.event_selectors,function(i){it(document.querySelectorAll(i),function(a){rt(e,a)&&Od(a)&&(r[n.name]=t._extractCustomPropertyValue(n))})})}),r},_getEventTarget:function(e){return e.target===void 0?e.srcElement||null:(t=e.target)!==null&&t!==void 0&&t.shadowRoot?e.composedPath()[0]||null:e.target||null;var t},_captureEvent:function(e,t){var r,n=this,i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"$autocapture",a=this._getEventTarget(e);if(Ez(a)&&(a=a.parentNode||null),i==="$autocapture"&&e.type==="click"&&e instanceof MouseEvent&&(r=this.rageclicks)!==null&&r!==void 0&&r.isRageClick(e.clientX,e.clientY,new Date().getTime())&&this._captureEvent(e,t,"$rageclick"),a&&function(v,_){var m=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0;if(!v||jo(v,"html")||!QI(v))return!1;if(m!=null&&m.url_allowlist){var g=window.location.href,y=m.url_allowlist;if(y&&!y.some(function(L){return g.match(L)}))return!1}if(m!=null&&m.dom_event_allowlist){var S=m.dom_event_allowlist;if(S&&!S.some(function(L){return _.type===L}))return!1}if(m!=null&&m.element_allowlist){var b=m.element_allowlist;if(b&&!b.some(function(L){return v.tagName.toLowerCase()===L}))return!1}if(m!=null&&m.css_selector_allowlist){var E=m.css_selector_allowlist;if(E&&!E.some(function(L){return v.matches(L)}))return!1}for(var w=!1,R=[v],O=!0,k=v;k.parentNode&&!jo(k,"body");)if(KI(k.parentNode))R.push(k.parentNode.host),k=k.parentNode.host;else{if(!(O=k.parentNode||!1))break;if(qm.indexOf(O.tagName.toLowerCase())>-1)w=!0;else{var C=window.getComputedStyle(O);C&&C.getPropertyValue("cursor")==="pointer"&&(w=!0)}R.push(O),k=O}var T=window.getComputedStyle(v);if(T&&T.getPropertyValue("cursor")==="pointer"&&_.type==="click")return!0;var $=v.tagName.toLowerCase();switch($){case"html":return!1;case"form":return _.type==="submit";case"input":case"select":case"textarea":return _.type==="change"||_.type==="click";default:return w?_.type==="click":_.type==="click"&&(qm.indexOf($)>-1||v.getAttribute("contenteditable")==="true")}}(a,e,this.config)){for(var o,s,u=[a],l=a;l.parentNode&&!jo(l,"body");)KI(l.parentNode)?(u.push(l.parentNode.host),l=l.parentNode.host):(u.push(l.parentNode),l=l.parentNode);var c,f=[],d={},h=!1;if(it(u,function(v){var _=Od(v);v.tagName.toLowerCase()==="a"&&(c=v.getAttribute("href"),c=_&&js(c)&&c),rt(jh(v).split(" "),"ph-no-capture")&&(h=!0),f.push(n._getPropertiesFromElement(v,t.get_config("mask_all_element_attributes"),t.get_config("mask_all_text")));var m=n._getAugmentPropertiesFromElement(v);wr(d,m)}),t.get_config("mask_all_text")||(a.tagName.toLowerCase()==="a"||a.tagName.toLowerCase()==="button"?f[0].$el_text=JI(a):f[0].$el_text=qh(a)),c&&(f[0].attr__href=c),h)return!1;var p=wr(this._getDefaultProperties(e.type),{$elements:f},(o=f[0])!==null&&o!==void 0&&o.$el_text?{$el_text:(s=f[0])===null||s===void 0?void 0:s.$el_text}:{},this._getCustomProperties(u),d);return t.capture(i,p),!0}},_navigate:function(e){window.location.href=e},_addDomEventHandlers:function(e){var t=this,r=function(n){n=n||window.event,t._captureEvent(n,e)};Yl(document,"submit",r,!1,!0),Yl(document,"change",r,!1,!0),Yl(document,"click",r,!1,!0)},_customProperties:[],rageclicks:null,config:void 0,init:function(e){var t;typeof e.__autocapture!="boolean"&&(this.config=e.__autocapture),(t=this.config)!==null&&t!==void 0&&t.url_allowlist&&(this.config.url_allowlist=this.config.url_allowlist.map(function(r){return new RegExp(r)})),this.rageclicks=new TJ(e.get_config("rageclick"))},afterDecideResponse:function(e,t){var r=t.get_config("token");this._initializedTokens.indexOf(r)>-1?Ge.log('autocapture already initialized for token "'+r+'"'):(t.persistence&&t.persistence.register(me({},XI,!!e.autocapture_opt_out)),this._isDisabledServerSide=!!e.autocapture_opt_out,this._setIsAutocaptureEnabled(t),this._initializedTokens.push(r),e&&e.config&&e.config.enable_collect_everything&&this._isAutocaptureEnabled?(e.custom_properties&&(this._customProperties=e.custom_properties),this._addDomEventHandlers(t)):t.__autocapture=!1)},enabledForProject:function(e,t,r){if(!e)return!0;t=kn(t)?10:t,r=kn(r)?10:r;for(var n=0,i=0;i1&&arguments[1]!==void 0?arguments[1]:{};if(this.instance.decideEndpointWasHit||this.getFlags()&&this.getFlags().length>0){var n,i=this.getFlagVariants()[t],a="".concat(i),o=this.instance.get_property(Bh)||{};return(r.send_event||!("send_event"in r))&&(!(t in o)||!o[t].includes(a))&&(Array.isArray(o[t])?o[t].push(a):o[t]=[a],(n=this.instance.persistence)===null||n===void 0||n.register(me({},Bh,o)),this.instance.capture("$feature_flag_called",{$feature_flag:t,$feature_flag_response:i})),i}console.warn('getFeatureFlag for key "'+t+`" failed. Feature flags didn't load in time.`)}},{key:"getFeatureFlagPayload",value:function(t){return this.getFlagPayloads()[t]}},{key:"isFeatureEnabled",value:function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.instance.decideEndpointWasHit||this.getFlags()&&this.getFlags().length>0)return!!this.getFeatureFlag(t,r);console.warn('isFeatureEnabled for key "'+t+`" failed. Feature flags didn't load in time.`)}},{key:"addFeatureFlagsHandler",value:function(t){this.featureFlagEventHandlers.push(t)}},{key:"removeFeatureFlagsHandler",value:function(t){this.featureFlagEventHandlers=this.featureFlagEventHandlers.filter(function(r){return r!==t})}},{key:"receivedFeatureFlags",value:function(t){if(this.instance.persistence){this.instance.decideEndpointWasHit=!0;var r=this.getFlagVariants(),n=this.getFlagPayloads();(function(i,a){var o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},u=i.featureFlags,l=i.featureFlagPayloads;if(u)if(Array.isArray(u)){var c,f={};if(u)for(var d=0;d1&&arguments[1]!==void 0&&arguments[1],i=this.instance.get_property(Zw);if(i&&!n)return t(i);this.instance._send_request("".concat(this.instance.get_config("api_host"),"/api/early_access_features/?token=").concat(this.instance.get_config("token")),{},{method:"GET"},function(a){var o,s=a.earlyAccessFeatures;return(o=r.instance.persistence)===null||o===void 0||o.register(me({},Zw,s)),t(s)})}},{key:"_prepareFeatureFlagsForCallbacks",value:function(){var t=this.getFlags(),r=this.getFlagVariants();return{flags:t.filter(function(n){return r[n]}),flagVariants:Object.keys(r).filter(function(n){return r[n]}).reduce(function(n,i){return n[i]=r[i],n},{})}}},{key:"_fireFeatureFlagsCallbacks",value:function(){var t=this._prepareFeatureFlagsForCallbacks(),r=t.flags,n=t.flagVariants;this.featureFlagEventHandlers.forEach(function(i){return i(r,n)})}},{key:"setPersonPropertiesForFlags",value:function(t){var r=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],n=this.instance.get_property(Us)||{};this.instance.register(me({},Us,ke(ke({},n),t))),r&&this.instance.reloadFeatureFlags()}},{key:"resetPersonPropertiesForFlags",value:function(){this.instance.unregister(Us)}},{key:"setGroupPropertiesForFlags",value:function(t){var r=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1],n=this.instance.get_property(Ra)||{};Object.keys(n).length!==0&&Object.keys(n).forEach(function(i){n[i]=ke(ke({},n[i]),t[i]),delete t[i]}),this.instance.register(me({},Ra,ke(ke({},n),t))),r&&this.instance.reloadFeatureFlags()}},{key:"resetGroupPropertiesForFlags",value:function(t){if(t){var r=this.instance.get_property(Ra)||{};this.instance.register(me({},Ra,ke(ke({},r),{},me({},t,{}))))}else this.instance.unregister(Ra)}}]),e}(),PJ=/[a-z0-9][a-z0-9-]+\.[a-z.]{2,6}$/i,Ui={is_supported:function(){return!0},error:function(e){Ge.error("cookieStore error: "+e)},get:function(e){try{for(var t=e+"=",r=document.cookie.split(";").filter(function(a){return a.length}),n=0;n1&&arguments[1]!==void 0?arguments[1]:{};Nt(this,e),me(this,"bucketSize",100),me(this,"refillRate",10),me(this,"mutationBuckets",{}),me(this,"loggedTracker",{}),me(this,"refillBuckets",function(){Object.keys(i.mutationBuckets).forEach(function(o){i.mutationBuckets[o]=i.mutationBuckets[o]+i.refillRate,i.mutationBuckets[o]>=i.bucketSize&&delete i.mutationBuckets[o]})}),me(this,"getNodeOrRelevantParent",function(o){var s=i.rrweb.mirror.getNode(o);if((s==null?void 0:s.nodeName)!=="svg"&&s instanceof Element){var u=s.closest("svg");if(u)return[i.rrweb.mirror.getId(u),u]}return[o,s]}),me(this,"numberOfChanges",function(o){var s,u,l,c,f,d,h,p;return((s=(u=o.removes)===null||u===void 0?void 0:u.length)!==null&&s!==void 0?s:0)+((l=(c=o.attributes)===null||c===void 0?void 0:c.length)!==null&&l!==void 0?l:0)+((f=(d=o.texts)===null||d===void 0?void 0:d.length)!==null&&f!==void 0?f:0)+((h=(p=o.adds)===null||p===void 0?void 0:p.length)!==null&&h!==void 0?h:0)}),me(this,"throttleMutations",function(o){if(o.type!==kz||o.data.source!==AJ)return o;var s=o.data,u=i.numberOfChanges(s);s.attributes&&(s.attributes=s.attributes.filter(function(c){var f,d,h,p=Ji(i.getNodeOrRelevantParent(c.id),2),v=p[0],_=p[1];return i.mutationBuckets[v]===0?!1:(i.mutationBuckets[v]=(f=i.mutationBuckets[v])!==null&&f!==void 0?f:i.bucketSize,i.mutationBuckets[v]=Math.max(i.mutationBuckets[v]-1,0),i.mutationBuckets[v]===0&&(i.loggedTracker[v]||(i.loggedTracker[v]=!0,(d=(h=i.options).onBlockedNode)===null||d===void 0||d.call(h,v,_))),c)}));var l=i.numberOfChanges(s);return l!==0||u===l?o:void 0}),this.rrweb=t,this.options=a,this.refillRate=(r=this.options.refillRate)!==null&&r!==void 0?r:this.refillRate,this.bucketSize=(n=this.options.bucketSize)!==null&&n!==void 0?n:this.bucketSize,setInterval(function(){i.refillBuckets()},1e3)}),jJ="/s/";(function(e){e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet"})(ci||(ci={}));var qJ=[ci.MouseMove,ci.MouseInteraction,ci.Scroll,ci.ViewportResize,ci.Input,ci.TouchMove,ci.MediaInteraction,ci.Drag],UJ=function(){function e(t){var r=this;Nt(this,e),me(this,"lastActivityTimestamp",Date.now()),me(this,"isIdle",!1),this.instance=t,this.captureStarted=!1,this.snapshots=[],this.emit=!1,this.endpoint=jJ,this.stopRrweb=void 0,this.windowId=null,this.sessionId=null,this.receivedDecide=!1,window.addEventListener("beforeunload",function(){r._flushBuffer()})}return At(e,[{key:"getSessionManager",value:function(){if(this.instance.sessionManager)return this.instance.sessionManager;Ge.error("Session recording started without valid sessionManager")}},{key:"startRecordingIfEnabled",value:function(){this.isRecordingEnabled()?this.startCaptureAndTrySendingQueuedSnapshots():this.stopRecording()}},{key:"started",value:function(){return this.captureStarted}},{key:"stopRecording",value:function(){this.captureStarted&&this.stopRrweb&&(this.stopRrweb(),this.stopRrweb=void 0,this.captureStarted=!1)}},{key:"isRecordingEnabled",value:function(){var t=!!this.instance.get_property(Xw),r=!this.instance.get_config("disable_session_recording");return t&&r}},{key:"isConsoleLogCaptureEnabled",value:function(){var t=!!this.instance.get_property(ZI),r=this.instance.get_config("enable_recording_console_log");return r??t}},{key:"getRecordingVersion",value:function(){var t,r=this.instance.get_property(ex);return((t=this.instance.get_config("session_recording"))===null||t===void 0?void 0:t.recorderVersion)||r||"v1"}},{key:"afterDecideResponse",value:function(t){var r,n,i,a,o,s;this.receivedDecide=!0,this.instance.persistence&&this.instance.persistence.register((me(o={},Xw,!!t.sessionRecording),me(o,ZI,(i=t.sessionRecording)===null||i===void 0?void 0:i.consoleLogRecordingEnabled),me(o,ex,(a=t.sessionRecording)===null||a===void 0?void 0:a.recorderVersion),o)),(r=t.sessionRecording)!==null&&r!==void 0&&r.endpoint&&(this.endpoint=(s=t.sessionRecording)===null||s===void 0?void 0:s.endpoint),(n=t.sessionRecording)!==null&&n!==void 0&&n.recorderVersion&&(this.recorderVersion=t.sessionRecording.recorderVersion),this.startRecordingIfEnabled()}},{key:"log",value:function(t){var r,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"log";(r=this.instance.sessionRecording)===null||r===void 0||r.onRRwebEmit({type:6,data:{plugin:"rrweb/console@1",payload:{level:n,trace:[],payload:[JSON.stringify(t)]}},timestamp:Sz()})}},{key:"startCaptureAndTrySendingQueuedSnapshots",value:function(){var t=this;this.receivedDecide&&(this.emit=!0,this.snapshots.forEach(function(r){return t._captureSnapshotBuffered(r)})),this._startCapture()}},{key:"_startCapture",value:function(){var t=this,r=this.getSessionManager();if(r&&Object.assign!==void 0&&!this.captureStarted&&!this.instance.get_config("disable_session_recording")){this.captureStarted=!0,r.checkAndGetSessionAndWindowId();var n=this.getRecordingVersion()==="v2"?"recorder-v2.js":"recorder.js";this.instance.__loaded_recorder_version!==this.getRecordingVersion()?Fh(this.instance.get_config("api_host")+"/static/".concat(n,"?v=").concat(Pn.LIB_VERSION),function(i){if(i)return Ge.error("Could not load ".concat(n),i);t._onScriptLoaded()}):this._onScriptLoaded()}}},{key:"_isInteractiveEvent",value:function(t){var r;return t.type===kz&&qJ.indexOf((r=t.data)===null||r===void 0?void 0:r.source)!==-1}},{key:"_updateWindowAndSessionIds",value:function(t){var r=this.getSessionManager();if(r){var n=this._isInteractiveEvent(t);if(n||this.isIdle||t.timestamp-this.lastActivityTimestamp>3e5&&(this.isIdle=!0),n&&(this.lastActivityTimestamp=t.timestamp,this.isIdle&&(this.isIdle=!1,this._tryTakeFullSnapshot())),!this.isIdle){var i=r.checkAndGetSessionAndWindowId(!n,t.timestamp),a=i.windowId,o=i.sessionId;[ix,DJ].indexOf(t.type)!==-1||this.windowId===a&&this.sessionId===o||this._tryTakeFullSnapshot(),this.windowId=a,this.sessionId=o}}}},{key:"_tryTakeFullSnapshot",value:function(){if(!this.captureStarted)return!1;try{var t;return(t=this.rrwebRecord)===null||t===void 0||t.takeFullSnapshot(),!0}catch(r){return Ge.error("Error taking full snapshot.",r),!1}}},{key:"_onScriptLoaded",value:function(){var t,r=this,n={blockClass:"ph-no-capture",blockSelector:void 0,ignoreClass:"ph-ignore-input",maskTextClass:"ph-mask",maskTextSelector:void 0,maskTextFn:void 0,maskAllInputs:!0,maskInputOptions:{},maskInputFn:void 0,slimDOMOptions:{},collectFonts:!1,inlineStylesheet:!0,recordCrossOriginIframes:!1};this.rrwebRecord=window.rrweb?window.rrweb.record:window.rrwebRecord;for(var i=this.instance.get_config("session_recording"),a=0,o=Object.entries(i||{});aLJ){var l,c=Xi(u.matchAll(/data:([\w/\-.]+);(\w+),([^)"]*)/gim));try{for(c.s();!(l=c.n()).done;){var f=l.value;u=f[1].toLocaleLowerCase().slice(0,6)==="image/"?u.replace(f[0],$J):u.replace(f[0],"")}}catch(d){c.e(d)}finally{c.f()}}return{event:JSON.parse(u),size:u.length}}(function(s){var u=s;if(u&&Ga(u)==="object"&&u.type===NJ&&Ga(u.data)==="object"&&u.data.plugin===MJ){u.data.payload.payload.length>10&&(u.data.payload.payload=u.data.payload.payload.slice(0,10),u.data.payload.payload.push("...[truncated]"));for(var l=[],c=0;c2e3?l.push(u.data.payload.payload[c].slice(0,2e3)+"...[truncated]"):l.push(u.data.payload.payload[c]);return u.data.payload.payload=l,s}return s}(r)),i=n.event,a=n.size;if(this._updateWindowAndSessionIds(i),!this.isIdle){var o={$snapshot_bytes:a,$snapshot_data:i,$session_id:this.sessionId,$window_id:this.windowId};this.emit?this._captureSnapshotBuffered(o):this.snapshots.push(o)}}}}},{key:"_flushBuffer",value:function(){return this.flushBufferTimer&&(clearTimeout(this.flushBufferTimer),this.flushBufferTimer=void 0),this.buffer&&this.buffer.data.length!==0&&this._captureSnapshot({$snapshot_bytes:this.buffer.size,$snapshot_data:this.buffer.data,$session_id:this.buffer.sessionId,$window_id:this.buffer.windowId}),this.buffer=void 0,{size:0,data:[],sessionId:this.sessionId,windowId:this.windowId}}},{key:"_captureSnapshotBuffered",value:function(t){var r,n=this,i=2+(((r=this.buffer)===null||r===void 0?void 0:r.data.length)||0);(!this.buffer||this.buffer.size+t.$snapshot_bytes+i>943718.4||this.buffer.sessionId!==this.sessionId)&&(this.buffer=this._flushBuffer()),this.buffer.size+=t.$snapshot_bytes,this.buffer.data.push(t.$snapshot_data),this.flushBufferTimer||(this.flushBufferTimer=setTimeout(function(){n._flushBuffer()},2e3))}},{key:"_captureSnapshot",value:function(t){this.instance.capture("$snapshot",t,{transport:"XHR",method:"POST",endpoint:this.endpoint,_noTruncate:!0,_batchKey:"recordings",_metrics:{rrweb_full_snapshot:t.$snapshot_data.type===ix}})}}]),e}(),oi={entryType:0,timeOrigin:1,name:2,startTime:3,redirectStart:4,redirectEnd:5,workerStart:6,fetchStart:7,domainLookupStart:8,domainLookupEnd:9,connectStart:10,secureConnectionStart:11,connectEnd:12,requestStart:13,responseStart:14,responseEnd:15,decodedBodySize:16,encodedBodySize:17,initiatorType:18,nextHopProtocol:19,renderBlockingStatus:20,responseStatus:21,transferSize:22,element:23,renderTime:24,loadTime:25,size:26,id:27,url:28,domComplete:29,domContentLoadedEvent:30,domInteractive:31,loadEventEnd:32,loadEventStart:33,redirectCount:34,navigationType:35,unloadEventEnd:36,unloadEventStart:37,duration:39,timestamp:40},BJ=["first-input","navigation","paint","resource"],zJ=["/s/","/e/"],HJ=function(){function e(t){Nt(this,e),me(this,"_forceAllowLocalhost",!1),this.instance=t}return At(e,[{key:"startObservingIfEnabled",value:function(){this.isEnabled()?this.startObserving():this.stopObserving()}},{key:"startObserving",value:function(){var t,r,n=this;if(!this.observer)if(((t=window)===null||t===void 0||(r=t.PerformanceObserver)===null||r===void 0?void 0:r.supportedEntryTypes)!==void 0)if(!gJ.includes(location.hostname)||this._forceAllowLocalhost)try{this.observer=new PerformanceObserver(function(a){a.getEntries().forEach(function(o){n._capturePerformanceEvent(o)})});var i=PerformanceObserver.supportedEntryTypes.filter(function(a){return BJ.includes(a)});i.forEach(function(a){var o;(o=n.observer)===null||o===void 0||o.observe({type:a,buffered:!0})})}catch(a){console.error("PostHog failed to start performance observer",a),this.stopObserving()}else Ge.log("PostHog Peformance observer not started because we are on localhost.");else Ge.log("PostHog Performance observer not started because PerformanceObserver is not supported by this browser.")}},{key:"stopObserving",value:function(){this.observer&&(this.observer.disconnect(),this.observer=void 0)}},{key:"isObserving",value:function(){return!!this.observer}},{key:"isEnabled",value:function(){var t,r;return(t=(r=this.instance.get_config("capture_performance"))!==null&&r!==void 0?r:this.remoteEnabled)!==null&&t!==void 0&&t}},{key:"afterDecideResponse",value:function(t){this.remoteEnabled=t.capturePerformance||!1,this.isEnabled()&&this.startObserving()}},{key:"_capturePerformanceEvent",value:function(t){if(t.name.indexOf(this.instance.get_config("api_host"))===0){var r=t.name.replace(this.instance.get_config("api_host"),"");if(zJ.find(function(h){return r.indexOf(h)===0}))return}var n={url:t.name},i=this.instance.get_config("session_recording");if(i.maskNetworkRequestFn&&(n=i.maskNetworkRequestFn(n)),n){var a=t.toJSON();a.name=n.url;var o={},s=Math.floor(Date.now()-performance.now());for(var u in o[oi.timeOrigin]=s,o[oi.timestamp]=Math.floor(s+t.startTime),oi)a[u]!==void 0&&(o[oi[u]]=a[u]);if(this.capturePerformanceEvent(o),WJ(t)){var l,c=Xi(t.serverTiming||[]);try{for(c.s();!(l=c.n()).done;){var f,d=l.value;this.capturePerformanceEvent((me(f={},oi.timeOrigin,s),me(f,oi.timestamp,Math.floor(s+t.startTime)),me(f,oi.name,d.name),me(f,oi.duration,d.duration),me(f,oi.entryType,"serverTiming"),f))}}catch(h){c.e(h)}finally{c.f()}}}}},{key:"capturePerformanceEvent",value:function(t){var r,n=t[oi.timestamp];(r=this.instance.sessionRecording)===null||r===void 0||r.onRRwebEmit({type:6,data:{plugin:"posthog/network@1",payload:t},timestamp:n})}}]),e}(),WJ=function(e){return e.entryType==="navigation"||e.entryType==="resource"},GJ=function(){function e(t){Nt(this,e),this.instance=t,this.instance.decideEndpointWasHit=this.instance._hasBootstrappedFeatureFlags()}return At(e,[{key:"call",value:function(){var t=this,r=Tk(JSON.stringify({token:this.instance.get_config("token"),distinct_id:this.instance.get_distinct_id(),groups:this.instance.getGroups(),person_properties:this.instance.get_property(Us),group_properties:this.instance.get_property(Ra),disable_flags:this.instance.get_config("advanced_disable_feature_flags")||this.instance.get_config("advanced_disable_feature_flags_on_first_load")||void 0}));this.instance._send_request("".concat(this.instance.get_config("api_host"),"/decide/?v=3"),{data:r,verbose:!0},{method:"POST"},function(n){return t.parseDecideResponse(n)})}},{key:"parseDecideResponse",value:function(t){var r,n,i,a,o=this;if(this.instance.featureFlags.setReloadingPaused(!1),this.instance.featureFlags._startReloadTimer(),(t==null?void 0:t.status)!==0){if(!document||!document.body)return console.log("document not ready yet, trying again in 500 milliseconds..."),void setTimeout(function(){o.parseDecideResponse(t)},500);if(this.instance.toolbar.afterDecideResponse(t),(r=this.instance.sessionRecording)===null||r===void 0||r.afterDecideResponse(t),$a.afterDecideResponse(t,this.instance),(n=this.instance.webPerformance)===null||n===void 0||n.afterDecideResponse(t),(i=this.instance.exceptionAutocapture)===null||i===void 0||i.afterDecideResponse(t),this.instance.get_config("advanced_disable_feature_flags_on_first_load")||this.instance.featureFlags.receivedFeatureFlags(t),this.instance.compression={},t.supportedCompression&&!this.instance.get_config("disable_compression")){var s,u={},l=Xi(t.supportedCompression);try{for(l.s();!(s=l.n()).done;)u[s.value]=!0}catch(v){l.e(v)}finally{l.f()}this.instance.compression=u}var c=(a=window)===null||a===void 0?void 0:a.extendPostHogWithSurveys;if(t.surveys&&!c&&Fh(this.instance.get_config("api_host")+"/static/surveys.js",function(v){if(v)return console.error("Could not load surveys script",v);window.extendPostHogWithSurveys(o.instance)}),t.siteApps)if(this.instance.get_config("opt_in_site_apps")){var f,d=this.instance.get_config("api_host"),h=Xi(t.siteApps);try{var p=function(){var v=f.value,_=v.id,m=v.url,g=[d,d[d.length-1]==="/"&&m[0]==="/"?m.substring(1):m].join("");window["__$$ph_site_app_".concat(_)]=o.instance,Fh(g,function(y){y&&console.error("Error while initializing PostHog app with config id ".concat(_),y)})};for(h.s();!(f=h.n()).done;)p()}catch(v){h.e(v)}finally{h.f()}}else t.siteApps.length>0&&console.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}else console.error("Failed to fetch feature flags from PostHog.")}}]),e}(),VJ=["https://app.posthog.com","https://eu.posthog.com"],YJ=["source"],QJ=function(){function e(t){Nt(this,e),this.instance=t}return At(e,[{key:"afterDecideResponse",value:function(t){var r=t.toolbarParams||t.editorParams||(t.toolbarVersion?{toolbarVersion:t.toolbarVersion}:{});t.isAuthenticated&&r.toolbarVersion&&r.toolbarVersion.indexOf("toolbar")===0&&this.loadToolbar(ke({},r))}},{key:"maybeLoadToolbar",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.location,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:window.history;try{if(!r){try{window.localStorage.setItem("test","test"),window.localStorage.removeItem("test")}catch{return!1}r=window.localStorage}var i,a=YI(t.hash,"__posthog")||YI(t.hash,"state"),o=a?JSON.parse(decodeURIComponent(a)):null;return o&&o.action==="ph_authorize"?((i=o).source="url",i&&Object.keys(i).length>0&&(o.desiredHash?t.hash=o.desiredHash:n?n.replaceState("",document.title,t.pathname+t.search):t.hash="")):((i=JSON.parse(r.getItem("_postHogToolbarParams")||"{}")).source="localstorage",delete i.userIntent),!(!i.token||this.instance.get_config("token")!==i.token)&&(this.loadToolbar(i),!0)}catch{return!1}}},{key:"loadToolbar",value:function(t){var r=this;if(window._postHogToolbarLoaded)return!1;window._postHogToolbarLoaded=!0;var n=this.instance.get_config("api_host"),i=3e5,a=Math.floor(Date.now()/i)*i,o="".concat(n).concat(n.endsWith("/")?"":"/","static/toolbar.js?t=").concat(a),s=!VJ.includes(this.instance.get_config("api_host"))&&this.instance.get_config("advanced_disable_toolbar_metrics"),u=ke(ke({token:this.instance.get_config("token")},t),{},{apiURL:n},s?{instrument:!1}:{});u.source;var l=pJ(u,YJ);return window.localStorage.setItem("_postHogToolbarParams",JSON.stringify(l)),Fh(o,function(c){c?Ge.error("Failed to load toolbar",c):(window.ph_load_toolbar||window.ph_load_editor)(u,r.instance)}),Yl(window,"turbolinks:load",function(){window._postHogToolbarLoaded=!1,r.loadToolbar(u)}),!0}},{key:"_loadEditor",value:function(t){return this.loadToolbar(t)}},{key:"maybeLoadEditor",value:function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.location,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:window.history;return this.maybeLoadToolbar(t,r,n)}}]),e}(),KJ="__ph_opt_in_out_";function JJ(e,t){Pz(!0,e,t)}function XJ(e,t){Pz(!1,e,t)}function ZJ(e,t){return Oz(e,t)==="1"}function ax(e,t){return!!function(r){if(r&&r.respectDnt){var n=r&&r.window||he,i=n.navigator||{},a=!1;return it([i.doNotTrack,i.msDoNotTrack,n.doNotTrack],function(o){rt([!0,1,"1","yes"],o)&&(a=!0)}),a}return!1}(t)||Oz(e,t)==="0"}function eX(e,t){kk(t=t||{}).remove(Ok(e,t),!!t.crossSubdomainCookie)}function kk(e){return(e=e||{}).persistenceType==="localStorage"?Mt:e.persistenceType==="localStorage+cookie"?nR:Ui}function Ok(e,t){return((t=t||{}).persistencePrefix||KJ)+e}function Oz(e,t){return kk(t).get(Ok(e,t))}function Pz(e,t,r){yz(t)&&t.length?(kk(r=r||{}).set(Ok(t,r),e?1:0,yJ(r.cookieExpiration)?r.cookieExpiration:null,r.crossSubdomainCookie,r.secureCookie),r.capture&&e&&r.capture(r.captureEventName||"$opt_in",r.captureProperties||{},{send_instantly:!0})):console.error("gdpr."+(e?"optIn":"optOut")+" called with an invalid token")}var Iz=function(){function e(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:3e3;Nt(this,e),this.isPolling=!0,this._event_queue=[],this._empty_queue_count=0,this._poller=void 0,this._pollInterval=t}return At(e,[{key:"setPollInterval",value:function(t){this._pollInterval=t,this.isPolling&&this.poll()}},{key:"poll",value:function(){}},{key:"unload",value:function(){}},{key:"getTime",value:function(){return new Date().getTime()}}]),e}(),tX=function(e){pz(r,Iz);var t=vz(r);function r(n){var i,a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:3e3;return Nt(this,r),(i=t.call(this,a)).handlePollRequest=n,i}return At(r,[{key:"enqueue",value:function(n,i,a){this._event_queue.push({url:n,data:i,options:a}),this.isPolling||(this.isPolling=!0,this.poll())}},{key:"poll",value:function(){var n=this;clearTimeout(this._poller),this._poller=setTimeout(function(){if(n._event_queue.length>0){var i=n.formatQueue(),a=function(s){var u=i[s],l=u.url,c=u.data,f=u.options;it(c,function(d,h){c[h].offset=Math.abs(c[h].timestamp-n.getTime()),delete c[h].timestamp}),n.handlePollRequest(l,c,f)};for(var o in i)a(o);n._event_queue.length=0,n._empty_queue_count=0}else n._empty_queue_count++;n._empty_queue_count>4&&(n.isPolling=!1,n._empty_queue_count=0),n.isPolling&&n.poll()},this._pollInterval)}},{key:"unload",value:function(){var n=this;clearTimeout(this._poller);var i=this._event_queue.length>0?this.formatQueue():{};this._event_queue.length=0;var a=Object.values(i);[].concat(Vw(a.filter(function(o){return o.url.indexOf("/e")===0})),Vw(a.filter(function(o){return o.url.indexOf("/e")!==0}))).map(function(o){var s=o.url,u=o.data,l=o.options;n.handlePollRequest(s,u,ke(ke({},l),{},{transport:"sendBeacon"}))})}},{key:"formatQueue",value:function(){var n={};return it(this._event_queue,function(i){var a=i.url,o=i.data,s=i.options,u=(s?s._batchKey:null)||a;n[u]===void 0&&(n[u]={data:[],url:a,options:s}),s&&n[u].options&&n[u].options._metrics&&!n[u].options._metrics.rrweb_full_snapshot&&(n[u].options._metrics.rrweb_full_snapshot=s._metrics.rrweb_full_snapshot),n[u].data.push(o)}),n}}]),r}(),un=Uint8Array,Fr=Uint16Array,Eu=Uint32Array,Pk=new un([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]),Ik=new un([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]),ox=new un([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),xz=function(e,t){for(var r=new Fr(31),n=0;n<31;++n)r[n]=t+=1<>>1|(21845&pt)<<1;_o=(61680&(_o=(52428&_o)>>>2|(13107&_o)<<2))>>>4|(3855&_o)<<4,aR[pt]=((65280&_o)>>>8|(255&_o)<<8)>>>1}var Ql=function(e,t,r){for(var n=e.length,i=0,a=new Fr(t);i>>u]=l}else for(o=new Fr(n),i=0;i>>15-e[i];return o},Yo=new un(288);for(pt=0;pt<144;++pt)Yo[pt]=8;for(pt=144;pt<256;++pt)Yo[pt]=9;for(pt=256;pt<280;++pt)Yo[pt]=7;for(pt=280;pt<288;++pt)Yo[pt]=8;var zh=new un(32);for(pt=0;pt<32;++pt)zh[pt]=5;var To,nX=Ql(Yo,9,0),iX=Ql(zh,5,0),$z=function(e){return(e/8>>0)+(7&e&&1)},Dz=function(e,t,r){(t==null||t<0)&&(t=0),(r==null||r>e.length)&&(r=e.length);var n=new(e instanceof Fr?Fr:e instanceof Eu?Eu:un)(r-t);return n.set(e.subarray(t,r)),n},Ti=function(e,t,r){r<<=7&t;var n=t/8>>0;e[n]|=r,e[n+1]|=r>>>8},fl=function(e,t,r){r<<=7&t;var n=t/8>>0;e[n]|=r,e[n+1]|=r>>>8,e[n+2]|=r>>>16},Hm=function(e,t){for(var r=[],n=0;nd&&(d=a[n].s);var h=new Fr(d+1),p=aX(r[c-1],h,0);if(p>t){n=0;var v=0,_=p-t,m=1<<_;for(a.sort(function(b,E){return h[E.s]-h[b.s]||b.f-E.f});nt))break;v+=m-(1<>>=_;v>0;){var y=a[n].s;h[y]=0&&v;--n){var S=a[n].s;h[S]==t&&(--h[S],++v)}p=t}return[new un(h),p]},aX=function e(t,r,n){return t.s==-1?Math.max(e(t.l,r,n+1),e(t.r,r,n+1)):r[t.s]=n},ux=function(e){for(var t=e.length;t&&!e[--t];);for(var r=new Fr(++t),n=0,i=e[0],a=1,o=function(u){r[n++]=u},s=1;s<=t;++s)if(e[s]==i&&s!=t)++a;else{if(!i&&a>2){for(;a>138;a-=138)o(32754);a>2&&(o(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(o(i),--a;a>6;a-=6)o(8304);a>2&&(o(a-3<<5|8208),a=0)}for(;a--;)o(i);a=1,i=e[s]}return[r.subarray(0,n),t]},dl=function(e,t){for(var r=0,n=0;n>>8,e[i+2]=255^e[i],e[i+3]=255^e[i+1];for(var a=0;a4&&!k[ox[T-1]];--T);var $,L,G,Y,B=l+5<<3,D=dl(i,Yo)+dl(a,zh)+o,F=dl(i,d)+dl(a,v)+o+14+3*T+dl(w,k)+(2*w[16]+3*w[17]+7*w[18]);if(B<=D&&B<=F)return Id(t,c,e.subarray(u,u+l));if(Ti(t,c,1+(F15&&(Ti(t,c,W[R]>>>5&127),c+=W[R]>>>12)}}}else $=nX,L=Yo,G=iX,Y=zh;for(R=0;R255){Q=n[R]>>>18&31,fl(t,c,$[Q+257]),c+=L[Q+257],Q>7&&(Ti(t,c,n[R]>>>23&31),c+=Pk[Q]);var ae=31&n[R];fl(t,c,G[ae]),c+=Y[ae],ae>3&&(fl(t,c,n[R]>>>5&8191),c+=Ik[ae])}else fl(t,c,$[n[R]]),c+=L[n[R]];return fl(t,c,$[256]),c+L[256]},oX=new Eu([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),sX=new un(0),uX=function(){for(var e=new Eu(256),t=0;t<256;++t){for(var r=t,n=9;--n;)r=(1&r&&3988292384)^r>>>1;e[t]=r}return e}(),lX=function(){var e=4294967295;return{p:function(t){for(var r=e,n=0;n>>8;e=r},d:function(){return 4294967295^e}}},cX=function(e,t,r,n,i){return function(a,o,s,u,l,c){var f=a.length,d=new un(u+f+5*(1+Math.floor(f/7e3))+l),h=d.subarray(u,d.length-l),p=0;if(!o||f<8)for(var v=0;v<=f;v+=65535){var _=v+65535;_>>13,y=8191&m,S=(1<7e3||G>24576)&&ee>423){p=lx(a,h,0,k,C,T,L,G,B,v-B,p),G=$=L=0,B=v;for(var Z=0;Z<286;++Z)C[Z]=0;for(Z=0;Z<30;++Z)T[Z]=0}var W=2,Q=0,ae=y,re=F-z&32767;if(ee>2&&D==O(v-re))for(var ie=Math.min(g,ee)-1,Ee=Math.min(32767,v),Ie=Math.min(258,ee);re<=Ee&&--ae&&F!=z;){if(a[v+W]==a[v+W-re]){for(var Pe=0;PeW){if(W=Pe,Q=re,Pe>ie)break;var $e=Math.min(re,Pe-2),De=0;for(Z=0;Z<$e;++Z){var He=v-re+Z+32768&32767,Je=He-b[He]+32768&32767;Je>De&&(De=Je,z=He)}}}re+=(F=z)-(z=b[F])+32768&32767}if(Q){k[G++]=268435456|iR[W]<<18|sx[Q];var et=31&iR[W],ot=31&sx[Q];L+=Pk[et]+Ik[ot],++C[257+et],++T[ot],Y=v+W,++$}else k[G++]=a[v],++C[a[v]]}}p=lx(a,h,c,k,C,T,L,G,B,v-B,p),c||(p=Id(h,p,sX))}return Dz(d,0,u+$z(p)+l)}(e,t.level==null?6:t.level,t.mem==null?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(e.length)))):12+t.mem,r,n,!i)},oR=function(e,t,r){for(;r;++t)e[t]=r,r>>>=8},fX=function(e,t){var r=t.filename;if(e[0]=31,e[1]=139,e[2]=8,e[8]=t.level<2?4:t.level==9?2:0,e[9]=3,t.mtime!=0&&oR(e,4,Math.floor(new Date(t.mtime||Date.now())/1e3)),r){e[3]=8;for(var n=0;n<=r.length;++n)e[n+10]=r.charCodeAt(n)}},dX=function(e){return 10+(e.filename&&e.filename.length+1||0)};function hX(e,t){t===void 0&&(t={});var r=lX(),n=e.length;r.p(e);var i=cX(e,t,dX(t),8),a=i.length;return fX(i,t),oR(i,a-8,r.d()),oR(i,a-4,n),i}function pX(e,t){var r=e.length;if(!t&&typeof TextEncoder<"u")return new TextEncoder().encode(e);for(var n=new un(e.length+(e.length>>>1)),i=0,a=function(l){n[i++]=l},o=0;on.length){var s=new un(i+8+(r-o<<1));s.set(n),n=s}var u=e.charCodeAt(o);u<128||t?a(u):u<2048?(a(192|u>>>6),a(128|63&u)):u>55295&&u<57344?(a(240|(u=65536+(1047552&u)|1023&e.charCodeAt(++o))>>>18),a(128|u>>>12&63),a(128|u>>>6&63),a(128|63&u)):(a(224|u>>>12),a(128|u>>>6&63),a(128|63&u))}return Dz(n,0,i)}(function(e){e.GZipJS="gzip-js",e.Base64="base64"})(To||(To={}));var vX=function(e,t,r){var n=t||{};n.ip=r.ip?1:0,n._=new Date().getTime().toString(),n.ver=Pn.LIB_VERSION;var i=e.split("?");if(i.length>1){var a,o=Xi(i[1].split("&"));try{for(o.s();!(a=o.n()).done;){var s=a.value.split("=")[0];n[s]&&delete n[s]}}catch(l){o.e(l)}finally{o.f()}}var u=e.indexOf("?")>-1?"&":"?";return e+u+function(l){var c,f,d=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"&",h=[];return it(l,function(p,v){c=encodeURIComponent(p.toString()),f=encodeURIComponent(v),h[h.length]=f+"="+c}),h.join(d)}(n)},xk=function e(t,r){if(r.blob&&t.buffer)return new Blob([t.buffer],{type:"text/plain"});if(r.sendBeacon||r.blob){var n=e(t,{method:"POST"});return new Blob([n],{type:"application/x-www-form-urlencoded"})}if(r.method!=="POST")return null;var i,a;return i=Array.isArray(t)||(a=t,Object.prototype.toString.call(a)==="[object Uint8Array]")?"data="+encodeURIComponent(t):"data="+encodeURIComponent(t.data),"compression"in t&&t.compression&&(i+="&compression="+t.compression),i},Nz=function(e){var t=e.url,r=e.data,n=e.headers,i=e.options,a=e.callback,o=e.retriesPerformedSoFar,s=e.retryQueue,u=e.onXHRError,l=e.timeout,c=l===void 0?6e4:l,f=e.onResponse,d=new XMLHttpRequest;d.open(i.method||"GET",t,!0);var h=xk(r,i);it(n,function(p,v){d.setRequestHeader(v,p)}),i.method!=="POST"||i.blob||d.setRequestHeader("Content-Type","application/x-www-form-urlencoded"),d.timeout=c,d.withCredentials=!0,d.onreadystatechange=function(){if(d.readyState===4)if(f==null||f(d),d.status===200){if(a){var p;try{p=JSON.parse(d.responseText)}catch(v){return void Ge.error(v)}a(p)}}else typeof u=="function"&&u(d),(d.status<400||d.status>500)&&s.enqueue({url:t,data:r,options:i,headers:n,retriesPerformedSoFar:(o||0)+1,callback:a}),a==null||a({status:0})},d.send(h)},mX=18e5,gX=function(e){pz(r,Iz);var t=vz(r);function r(n,i){var a;return Nt(this,r),(a=t.call(this)).isPolling=!1,a.queue=[],a.areWeOnline=!0,a.onXHRError=n,a.rateLimiter=i,typeof window<"u"&&"onLine"in window.navigator&&(a.areWeOnline=window.navigator.onLine,window.addEventListener("online",function(){a._handleWeAreNowOnline()}),window.addEventListener("offline",function(){a.areWeOnline=!1})),a}return At(r,[{key:"enqueue",value:function(n){var i=n.retriesPerformedSoFar||0;if(!(i>=10)){var a=function(s){var u=3e3*Math.pow(2,s),l=u/2,c=Math.min(mX,u),f=(Math.random()-.5)*(c-l);return Math.ceil(c+f)}(i),o=new Date(Date.now()+a);this.queue.push({retryAt:o,requestData:n}),console.warn("Enqueued failed request for retry in ".concat(a)),this.isPolling||(this.isPolling=!0,this.poll())}}},{key:"poll",value:function(){var n=this;this._poller&&clearTimeout(this._poller),this._poller=setTimeout(function(){n.areWeOnline&&n.queue.length>0&&n.flush(),n.poll()},this._pollInterval)}},{key:"flush",value:function(){var n=new Date(Date.now()),i=this.queue.filter(function(u){return u.retryAt0){this.queue=this.queue.filter(function(u){return u.retryAt>=n});var a,o=Xi(i);try{for(o.s();!(a=o.n()).done;){var s=a.value.requestData;this._executeXhrRequest(s)}}catch(u){o.e(u)}finally{o.f()}}}},{key:"unload",value:function(){this._poller&&(clearTimeout(this._poller),this._poller=void 0);var n,i=Xi(this.queue);try{for(i.s();!(n=i.n()).done;){var a=n.value.requestData,o=a.url,s=a.data,u=a.options;if(this.rateLimiter.isRateLimited(u._batchKey))Pn.DEBUG&&console.warn("[PostHog RetryQueue] is quota limited. Dropping request.");else try{window.navigator.sendBeacon(o,xk(s,ke(ke({},u),{},{sendBeacon:!0})))}catch(l){Pn.DEBUG&&console.error(l)}}}catch(l){i.e(l)}finally{i.f()}this.queue=[]}},{key:"_executeXhrRequest",value:function(n){var i=n.url,a=n.data,o=n.options,s=n.headers,u=n.callback,l=n.retriesPerformedSoFar;this.rateLimiter.isRateLimited(o._batchKey)||Nz({url:i,data:a||{},options:o||{},headers:s||{},retriesPerformedSoFar:l||0,callback:u,retryQueue:this,onXHRError:this.onXHRError,onResponse:this.rateLimiter.checkForLimiting})}},{key:"_handleWeAreNowOnline",value:function(){this.areWeOnline=!0,this.flush()}}]),r}();/** * uuidv7: An experimental implementation of the proposed UUID Version 7 * * @license Apache-2.0 * @copyright 2021-2023 LiosK * @packageDocumentation * * from https://github.com/LiosK/uuidv7/blob/e501462ea3d23241de13192ceae726956f9b3b7d/src/index.ts */Math.trunc||(Math.trunc=function(e){return e<0?Math.ceil(e):Math.floor(e)}),Number.isInteger||(Number.isInteger=function(e){return typeof e=="number"&&isFinite(e)&&Math.floor(e)===e});var cx="0123456789abcdef",_X=function(){function e(t){if(Nt(this,e),this.bytes=t,t.length!==16)throw new TypeError("not 128-bit length")}return At(e,[{key:"toString",value:function(){for(var t="",r=0;r>>4)+cx.charAt(15&this.bytes[r]),r!==3&&r!==5&&r!==7&&r!==9||(t+="-");if(t.length!==36)throw new Error("Invalid UUIDv7 was generated");return t}},{key:"clone",value:function(){return new e(this.bytes.slice(0))}},{key:"equals",value:function(t){return this.compareTo(t)===0}},{key:"compareTo",value:function(t){for(var r=0;r<16;r++){var n=this.bytes[r]-t.bytes[r];if(n!==0)return Math.sign(n)}return 0}}],[{key:"fromFieldsV7",value:function(t,r,n,i){if(!Number.isInteger(t)||!Number.isInteger(r)||!Number.isInteger(n)||!Number.isInteger(i)||t<0||r<0||n<0||i<0||t>0xffffffffffff||r>4095||n>1073741823||i>4294967295)throw new RangeError("invalid field value");var a=new Uint8Array(16);return a[0]=t/Math.pow(2,40),a[1]=t/Math.pow(2,32),a[2]=t/Math.pow(2,24),a[3]=t/Math.pow(2,16),a[4]=t/Math.pow(2,8),a[5]=t,a[6]=112|r>>>8,a[7]=r,a[8]=128|n>>>24,a[9]=n>>>16,a[10]=n>>>8,a[11]=n,a[12]=i>>>24,a[13]=i>>>16,a[14]=i>>>8,a[15]=i,new e(a)}}]),e}(),yX=function(){function e(){Nt(this,e),me(this,"timestamp",0),me(this,"counter",0),me(this,"random",new SX)}return At(e,[{key:"generate",value:function(){var t=this.generateOrAbort();if(t!==void 0)return t;this.timestamp=0;var r=this.generateOrAbort();if(r===void 0)throw new Error("Could not generate UUID after timestamp reset");return r}},{key:"generateOrAbort",value:function(){var t=Date.now();if(t>this.timestamp)this.timestamp=t,this.resetCounter();else{if(!(t+1e4>this.timestamp))return;this.counter++,this.counter>4398046511103&&(this.timestamp++,this.resetCounter())}return _X.fromFieldsV7(this.timestamp,Math.trunc(this.counter/Math.pow(2,30)),this.counter&Math.pow(2,30)-1,this.random.nextUint32())}},{key:"resetCounter",value:function(){this.counter=1024*this.random.nextUint32()+(1023&this.random.nextUint32())}}]),e}(),Az=function(e){if(typeof UUIDV7_DENY_WEAK_RNG<"u"&&UUIDV7_DENY_WEAK_RNG)throw new Error("no cryptographically strong RNG available");for(var t=0;t=this.buffer.length&&(Az(this.buffer),this.cursor=0),this.buffer[this.cursor++]}}]),e}(),Do=function(){return bX().toString()},bX=function(){return(fx||(fx=new yX)).generate()},jf=1800,dx=60,EX=864e5,wX=function(){function e(t,r){Nt(this,e),me(this,"_sessionIdChangedHandlers",[]),this.config=t,this.persistence=r,this._windowId=void 0,this._sessionId=void 0,this._sessionStartTimestamp=null,this._sessionActivityTimestamp=null;var n=t.persistence_name||t.token,i=t.session_idle_timeout_seconds||jf;if(typeof i!="number"?(console.warn("[PostHog] session_idle_timeout_seconds must be a number. Defaulting to 30 minutes."),i=jf):i>jf?console.warn("[PostHog] session_idle_timeout_seconds cannot be greater than 30 minutes. Using 30 minutes instead."):i0&&arguments[0]!==void 0&&arguments[0],r=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:null)||new Date().getTime(),n=Ji(this._getSessionId(),3),i=n[0],a=n[1],o=n[2],s=this._getWindowId(),u=o&&o>0&&Math.abs(r-o)>EX,l=!1;!a||!t&&Math.abs(r-i)>this._sessionTimeoutMs||u?(a=Do(),s=Do(),o=r,l=!0):s||(s=Do(),l=!0);var c=i===0||!t||u?r:i,f=o===0?new Date().getTime():o;return this._setWindowId(s),this._setSessionId(a,c,f),l&&this._sessionIdChangedHandlers.forEach(function(d){return d(a,s)}),{sessionId:a,windowId:s,sessionStartTimestamp:f}}}]),e}(),RX=At(function e(t,r,n,i){Nt(this,e),this.name="posthog-js",this.setupOnce=function(a){a(function(o){var s,u,l,c,f;if(o.level!=="error"||!t.__loaded)return o;o.tags||(o.tags={});var d=t.config.ui_host||t.config.api_host;o.tags["PostHog Person URL"]=d+"/person/"+t.get_distinct_id(),t.sessionRecordingStarted()&&(o.tags["PostHog Recording URL"]=t.get_session_replay_url({withTimestamp:!0}));var h=((s=o.exception)===null||s===void 0?void 0:s.values)||[],p={$exception_message:(u=h[0])===null||u===void 0?void 0:u.value,$exception_type:(l=h[0])===null||l===void 0?void 0:l.type,$exception_personURL:d+"/person/"+t.get_distinct_id(),$sentry_event_id:o.event_id,$sentry_exception:o.exception,$sentry_exception_message:(c=h[0])===null||c===void 0?void 0:c.value,$sentry_exception_type:(f=h[0])===null||f===void 0?void 0:f.type,$sentry_tags:o.tags};return r&&n&&(p.$sentry_url=(i||"https://sentry.io/organizations/")+r+"/issues/?project="+n+"&query="+o.event_id),t.capture("$exception",p),o})}}),TX=function(e){Promise&&Promise.resolve||console.warn("This browser does not have Promise support, and can not use the segment integration");var t=function(r,n){r.event.userId||r.event.anonymousId===e.get_distinct_id()||e.reset(),r.event.userId&&r.event.userId!==e.get_distinct_id()&&(e.register({distinct_id:r.event.userId}),e.reloadFeatureFlags());var i=e._calculate_event_properties(n,r.event.properties);return r.event.properties=Object.assign({},i,r.event.properties),r};return{name:"PostHog JS",type:"enrichment",version:"1.0.0",isLoaded:function(){return!0},load:function(){return Promise.resolve()},track:function(r){return t(r,r.event.event)},page:function(r){return t(r,"$pageview")},identify:function(r){return t(r,"$identify")},screen:function(r){return t(r,"$screen")}}},kX=function(){function e(){var t=this;Nt(this,e),me(this,"_hasSeenPageView",!1),me(this,"_updateScrollData",function(){var r,n,i,a;t._pageViewData||(t._pageViewData=t._createPageViewData());var o=t._pageViewData,s=t._scrollY(),u=t._scrollHeight(),l=t._contentY(),c=t._contentHeight();o.lastScrollY=s,o.maxScrollY=Math.max(s,(r=o.maxScrollY)!==null&&r!==void 0?r:0),o.maxScrollHeight=Math.max(u,(n=o.maxScrollHeight)!==null&&n!==void 0?n:0),o.lastContentY=l,o.maxContentY=Math.max(l,(i=o.maxContentY)!==null&&i!==void 0?i:0),o.maxContentHeight=Math.max(c,(a=o.maxContentHeight)!==null&&a!==void 0?a:0)})}return At(e,[{key:"_createPageViewData",value:function(){return{pathname:he.location.pathname}}},{key:"doPageView",value:function(){var t,r;return this._hasSeenPageView?(r=this._pageViewData,this._pageViewData=this._createPageViewData()):(this._hasSeenPageView=!0,r=void 0,this._pageViewData||(this._pageViewData=this._createPageViewData())),setTimeout(this._updateScrollData,0),ke({$prev_pageview_pathname:(t=r)===null||t===void 0?void 0:t.pathname},this._calculatePrevPageScrollProperties(r))}},{key:"doPageLeave",value:function(){var t=this._pageViewData;return ke({$prev_pageview_pathname:t==null?void 0:t.pathname},this._calculatePrevPageScrollProperties(t))}},{key:"_calculatePrevPageScrollProperties",value:function(t){if(!t||t.maxScrollHeight==null||t.lastScrollY==null||t.maxScrollY==null||t.maxContentHeight==null||t.lastContentY==null||t.maxContentY==null)return{};var r=t.maxScrollHeight,n=t.lastScrollY,i=t.maxScrollY,a=t.maxContentHeight,o=t.lastContentY,s=t.maxContentY;return r=Math.ceil(r),n=Math.ceil(n),i=Math.ceil(i),a=Math.ceil(a),o=Math.ceil(o),s=Math.ceil(s),{$prev_pageview_last_scroll:n,$prev_pageview_last_scroll_percentage:r<=1?1:qf(n/r,0,1),$prev_pageview_max_scroll:i,$prev_pageview_max_scroll_percentage:r<=1?1:qf(i/r,0,1),$prev_pageview_last_content:o,$prev_pageview_last_content_percentage:a<=1?1:qf(o/a,0,1),$prev_pageview_max_content:s,$prev_pageview_max_content_percentage:a<=1?1:qf(s/a,0,1)}}},{key:"startMeasuringScrollPosition",value:function(){he.addEventListener("scroll",this._updateScrollData),he.addEventListener("scrollend",this._updateScrollData),he.addEventListener("resize",this._updateScrollData)}},{key:"stopMeasuringScrollPosition",value:function(){he.removeEventListener("scroll",this._updateScrollData),he.removeEventListener("scrollend",this._updateScrollData),he.removeEventListener("resize",this._updateScrollData)}},{key:"_scrollHeight",value:function(){return Math.max(0,he.document.documentElement.scrollHeight-he.document.documentElement.clientHeight)}},{key:"_scrollY",value:function(){return he.scrollY||he.pageYOffset||he.document.documentElement.scrollTop||0}},{key:"_contentHeight",value:function(){return he.document.documentElement.scrollHeight||0}},{key:"_contentY",value:function(){var t=he.document.documentElement.clientHeight||0;return this._scrollY()+t}}]),e}();function qf(e,t,r){return Math.max(t,Math.min(e,r))}function hx(e){return typeof Event<"u"&&Lz(e,Event)}function Lz(e,t){try{return e instanceof t}catch{return!1}}function px(e){return e===null||Ga(e)!=="object"&&typeof e!="function"}function xd(e,t){return Object.prototype.toString.call(e)==="[object ".concat(t,"]")}function Wm(e){return xd(e,"DOMError")}var vx=/\(error: (.*)\)/,mx=50,Cd="?";function Gm(e,t,r,n){var i={filename:e,function:t,in_app:!0};return r!==void 0&&(i.lineno=r),n!==void 0&&(i.colno=n),i}var OX=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,PX=/\((\S*)(?::(\d+))(?::(\d+))\)/,IX=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,xX=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,CX=/^\s*at (?:((?:\[object object\])?.+) )?\(?((?:[-a-z]+):.*?):(\d+)(?::(\d+))?\)?\s*$/i,$X=(function(){for(var e=arguments.length,t=new Array(e),r=0;r1&&arguments[1]!==void 0?arguments[1]:0,o=[],s=i.split(` `),u=a;u1024)){var c=vx.test(l)?l.replace(vx,"$1"):l;if(!c.match(/\S*Error: /)){var f,d=Xi(n);try{for(d.s();!(f=d.n()).done;){var h=(0,f.value)(c);if(h){o.push(h);break}}}catch(p){d.e(p)}finally{d.f()}if(o.length>=mx)break}}}return function(p){if(!p.length)return[];var v=p.slice(0,mx);return v.reverse(),v.map(function(_){return ke(ke({},_),{},{filename:_.filename||v[v.length-1].filename,function:_.function||"?"})})}(o)}}).apply(void 0,[[30,function(e){var t=OX.exec(e);if(t){if(t[2]&&t[2].indexOf("eval")===0){var r=PX.exec(t[2]);r&&(t[2]=r[1],t[3]=r[2],t[4]=r[3])}var n=Ji(gx(t[1]||Cd,t[2]),2),i=n[0];return Gm(n[1],i,t[3]?+t[3]:void 0,t[4]?+t[4]:void 0)}}],[50,function(e){var t=IX.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){var r=xX.exec(t[3]);r&&(t[1]=t[1]||"eval",t[3]=r[1],t[4]=r[2],t[5]="")}var n=t[3],i=t[1]||Cd,a=Ji(gx(i,n),2);return i=a[0],Gm(n=a[1],i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}}],[40,function(e){var t=CX.exec(e);return t?Gm(t[2],t[1]||Cd,+t[3],t[4]?+t[4]:void 0):void 0}]]),gx=function(e,t){var r=e.indexOf("safari-extension")!==-1,n=e.indexOf("safari-web-extension")!==-1;return r||n?[e.indexOf("@")!==-1?e.split("@")[0]:Cd,r?"safari-extension:".concat(t):"safari-web-extension:".concat(t)]:[e,t]},DX=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i,NX=/Minified React error #\d+;/i;function AX(e){var t=e.stacktrace||e.stack||"",r=function(n){if(n){if(typeof n.framesToPop=="number")return n.framesToPop;if(NX.test(n.message))return 1}return 0}(e);try{return $X(t,r)}catch{}return[]}function Vm(e){var t=AX(e);return{$exception_type:e.name,$exception_message:e.message,$exception_stack_trace_raw:JSON.stringify(t)}}function LX(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:40,r=Object.keys(e);if(r.sort(),!r.length)return"[object has no keys]";for(var n=r.length;n>0;n--){var i=r.slice(0,n).join(", ");if(!(i.length>t))return n===r.length||i.length<=t?i:"".concat(i.slice(0,t),"...")}return""}function _x(e){var t=Ji(e,5),r=t[0],n=t[1],i=t[2],a=t[3],o=t[4],s={};if(o===void 0&&typeof r=="string"){var u="Error",l=r,c=r.match(DX);c&&(u=c[1],l=c[2]),s={$exception_type:u,$exception_message:l}}var f=o||r;if(Wm(f)||function(v){return xd(v,"DOMException")}(f)){var d=f;if(function(v){return"stack"in v}(f))s=Vm(f);else{var h=d.name||(Wm(d)?"DOMError":"DOMException"),p=d.message?"".concat(h,": ").concat(d.message):h;s=function(v){return{$exception_type:"Error",$exception_message:v}}(p),s.$exception_type=Wm(d)?"DOMError":"DOMException",s.$exception_message=s.$exception_message||p}"code"in d&&(s.$exception_DOMException_code="".concat(d.code))}else(function(v){return xd(v,"ErrorEvent")})(f)&&f.error?s=Vm(f.error):function(v){switch(Object.prototype.toString.call(v)){case"[object Error]":case"[object Exception]":case"[object DOMException]":return!0;default:return Lz(v,Error)}}(f)?s=Vm(f):function(v){return xd(v,"Object")}(f)||hx(f)?(s=function(v){return{$exception_type:hx(v)?v.constructor.name:"Error",$exception_message:"Non-Error ".concat("exception"," captured with keys: ",LX(v))}}(f),s.$exception_is_synthetic=!0):(s.$exception_type=s.$exception_type||"Error",s.$exception_message=s.$exception_message||f,s.$exception_is_synthetic=!0);return ke(ke(ke(ke({},s),{},{$exception_type:s.$exception_type||"UnknownErrorType",$exception_message:s.$exception_message||""},n?{$exception_source:n}:{}),i?{$exception_lineno:i}:{}),a?{$exception_colno:a}:{})}var wc,Ck,hr,MX=function(){function e(t){Nt(this,e),me(this,"originalOnErrorHandler",void 0),me(this,"originalOnUnhandledRejectionHandler",void 0),me(this,"errorsToIgnore",[]),this.instance=t}return At(e,[{key:"debugLog",value:function(){if(this.instance.get_config("debug")){for(var t,r=arguments.length,n=new Array(r),i=0;i1&&arguments[1]!==void 0&&arguments[1],i=this.instance.get_property(eR);if(i&&!n)return t(i);this.instance._send_request("".concat(this.instance.get_config("api_host"),"/api/surveys/?token=").concat(this.instance.get_config("token")),{},{method:"GET"},function(a){var o,s=a.surveys;return(o=r.instance.persistence)===null||o===void 0||o.register(me({},eR,s)),t(s)})}},{key:"getActiveMatchingSurveys",value:function(t){var r=this,n=arguments.length>1&&arguments[1]!==void 0&&arguments[1];this.getSurveys(function(i){var a=i.filter(function(o){return!(!o.start_date||o.end_date)}).filter(function(o){var s,u;if(!o.conditions)return!0;var l=(s=o.conditions)===null||s===void 0||!s.url||window.location.href.indexOf(o.conditions.url)>-1,c=(u=o.conditions)===null||u===void 0||!u.selector||document.querySelector(o.conditions.selector);return l&&c}).filter(function(o){if(!o.linked_flag_key&&!o.targeting_flag_key)return!0;var s=!o.linked_flag_key||r.instance.featureFlags.isFeatureEnabled(o.linked_flag_key),u=!o.targeting_flag_key||r.instance.featureFlags.isFeatureEnabled(o.targeting_flag_key);return s&&u});return t(a)},n)}}]),e}(),jX=6e4,qX=function(){function e(){var t=this;Nt(this,e),me(this,"limits",{}),me(this,"checkForLimiting",function(r){try{(JSON.parse(r.responseText).quota_limited||[]).forEach(function(n){Ge.log("[PostHog RateLimiter] ".concat(n||"events"," is quota limited.")),t.limits[n]=new Date().getTime()+jX})}catch(n){return void Ge.error(n)}})}return At(e,[{key:"isRateLimited",value:function(t){var r=this.limits[t||"events"]||!1;return r!==!1&&new Date().getTime()1&&arguments[1]!==void 0?arguments[1]:{},o=arguments.length>2?arguments[2]:void 0,s=arguments.length>3?arguments[3]:void 0;this.__loaded=!0,this.config={},this._triggered_notifs=[];var u,l={segmentRegister:!1,syncCode:!1},c=function(S){return function(){l[S]||(l[S]=!0,l.segmentRegister&&l.syncCode&&(s==null||s(i)))}};if(this.set_config(wr({},yx(),a,{name:o,token:t,callback_fn:(o===Gr?o:Gr+"."+o)+"._jsc"})),this._jsc=function(){},(he!=null&&(r=he.rrweb)!==null&&r!==void 0&&r.record||he!=null&&he.rrwebRecord)&&(this.__loaded_recorder_version=he==null||(u=he.rrweb)===null||u===void 0?void 0:u.version),this.persistence=new nx(this.config),this._requestQueue=new tX(this._handle_queued_event.bind(this)),this._retryQueue=new gX(this.get_config("on_xhr_error"),this.rateLimiter),this.__captureHooks=[],this.__request_queue=[],this.sessionManager=new wX(this.config,this.persistence),this.sessionPersistence=this.config.persistence==="sessionStorage"?this.persistence:new nx(ke(ke({},this.config),{},{persistence:"sessionStorage"})),this._gdpr_init(),a.segment?(this.config.get_device_id=function(){return a.segment.user().anonymousId()},a.segment.user().id()&&(this.register({distinct_id:a.segment.user().id()}),this.persistence.set_user_state("identified")),a.segment.register(this.segmentIntegration()).then(c("segmentRegister"))):c("segmentRegister")(),((n=a.bootstrap)===null||n===void 0?void 0:n.distinctID)!==void 0){var f,d,h=this.get_config("get_device_id")(Do()),p=(f=a.bootstrap)!==null&&f!==void 0&&f.isIdentifiedID?h:a.bootstrap.distinctID;this.persistence.set_user_state((d=a.bootstrap)!==null&&d!==void 0&&d.isIdentifiedID?"identified":"anonymous"),this.register({distinct_id:a.bootstrap.distinctID,$device_id:p})}if(this._hasBootstrappedFeatureFlags()){var v,_,m=Object.keys(((v=a.bootstrap)===null||v===void 0?void 0:v.featureFlags)||{}).filter(function(S){var b,E;return!((b=a.bootstrap)===null||b===void 0||(E=b.featureFlags)===null||E===void 0||!E[S])}).reduce(function(S,b){var E,w;return S[b]=((E=a.bootstrap)===null||E===void 0||(w=E.featureFlags)===null||w===void 0?void 0:w[b])||!1,S},{}),g=Object.keys(((_=a.bootstrap)===null||_===void 0?void 0:_.featureFlagPayloads)||{}).filter(function(S){return m[S]}).reduce(function(S,b){var E,w,R,O;return(E=a.bootstrap)!==null&&E!==void 0&&(w=E.featureFlagPayloads)!==null&&w!==void 0&&w[b]&&(S[b]=(R=a.bootstrap)===null||R===void 0||(O=R.featureFlagPayloads)===null||O===void 0?void 0:O[b]),S},{});this.featureFlags.receivedFeatureFlags({featureFlags:m,featureFlagPayloads:g})}if(!this.get_distinct_id()){var y=this.get_config("get_device_id")(Do());this.register_once({distinct_id:y,$device_id:y},""),this.persistence.set_user_state("anonymous")}he.addEventListener&&he.addEventListener("onpagehide"in self?"pagehide":"unload",this._handle_unload.bind(this)),c("syncCode")()}},{key:"_loaded",value:function(){var t=this.get_config("advanced_disable_decide");t||this.featureFlags.setReloadingPaused(!0);try{this.get_config("loaded")(this)}catch(r){console.error("`loaded` function failed",r)}this._start_queue_if_opted_in(),this.get_config("capture_pageview")&&this.capture("$pageview",{title:Ct.title},{send_instantly:!0}),t||(new GJ(this).call(),this.featureFlags.resetRequestQueue())}},{key:"_start_queue_if_opted_in",value:function(){var t;this.has_opted_out_capturing()||this.get_config("request_batching")&&((t=this._requestQueue)===null||t===void 0||t.poll())}},{key:"_dom_loaded",value:function(){var t=this;this.has_opted_out_capturing()||qi(this.__request_queue,function(r){t._send_request.apply(t,Vw(r))}),this.__request_queue=[],this._start_queue_if_opted_in()}},{key:"_prepare_callback",value:function(t,r){if(kn(t))return null;if($d)return function(o){t(o,r)};var n=this._jsc,i=""+Math.floor(1e8*Math.random()),a=this.get_config("callback_fn")+"["+i+"]";return n[i]=function(o){delete n[i],t(o,r)},a}},{key:"_handle_unload",value:function(){var t,r;this.get_config("request_batching")?(this.get_config("capture_pageview")&&this.get_config("capture_pageleave")&&this.capture("$pageleave"),(t=this._requestQueue)===null||t===void 0||t.unload(),(r=this._retryQueue)===null||r===void 0||r.unload()):this.get_config("capture_pageview")&&this.get_config("capture_pageleave")&&this.capture("$pageleave",null,{transport:"sendBeacon"})}},{key:"_handle_queued_event",value:function(t,r,n){var i=JSON.stringify(r);this.__compress_and_send_json_request(t,i,n||Uf,sR)}},{key:"__compress_and_send_json_request",value:function(t,r,n,i){var a=function(l,c,f){return l===To.GZipJS?[hX(pX(c),{mtime:0}),ke(ke({},f),{},{blob:!0,urlQueryArgs:{compression:To.GZipJS}})]:[{data:Tk(c)},f]}(this.compression[To.GZipJS]?To.GZipJS:To.Base64,r,n),o=Ji(a,2),s=o[0],u=o[1];this._send_request(t,s,u,i)}},{key:"_send_request",value:function(t,r,n,i){if(this.__loaded&&this._retryQueue&&!this.rateLimiter.isRateLimited(n._batchKey))if(Mz)this.__request_queue.push([t,r,n,i]);else{var a={method:this.get_config("api_method"),transport:this.get_config("api_transport"),verbose:this.get_config("verbose")};n=wr(a,n||{}),$d||(n.method="GET");var o="sendBeacon"in he.navigator&&n.transport==="sendBeacon";if(t=vX(t,n.urlQueryArgs||{},{ip:this.get_config("ip")}),o)try{he.navigator.sendBeacon(t,xk(r,ke(ke({},n),{},{sendBeacon:!0})))}catch{}else if($d)try{Nz({url:t,data:r,headers:this.get_config("xhr_headers"),options:n,callback:i,retriesPerformedSoFar:0,retryQueue:this._retryQueue,onXHRError:this.get_config("on_xhr_error"),onResponse:this.rateLimiter.checkForLimiting})}catch(c){console.error(c)}else{var s,u=Ct.createElement("script");u.type="text/javascript",u.async=!0,u.defer=!0,u.src=t;var l=Ct.getElementsByTagName("script")[0];(s=l.parentNode)===null||s===void 0||s.insertBefore(u,l)}}}},{key:"_execute_array",value:function(t){var r,n=this,i=[],a=[],o=[];qi(t,function(u){u&&(r=u[0],Ci(r)?o.push(u):typeof u=="function"?u.call(n):Ci(u)&&r==="alias"?i.push(u):Ci(u)&&r.indexOf("capture")!==-1&&typeof n[r]=="function"?o.push(u):a.push(u))});var s=function(u,l){qi(u,function(c){if(Ci(c[0])){var f=l;it(c,function(d){f=f[d[0]].apply(f,d.slice(1))})}else this[c[0]].apply(this,c.slice(1))},l)};s(i,this),s(a,this),s(o,this)}},{key:"_hasBootstrappedFeatureFlags",value:function(){var t,r;return((t=this.config.bootstrap)===null||t===void 0?void 0:t.featureFlags)&&Object.keys((r=this.config.bootstrap)===null||r===void 0?void 0:r.featureFlags).length>0||!1}},{key:"push",value:function(t){this._execute_array([t])}},{key:"captureException",value:function(t,r){var n;(n=this.exceptionAutocapture)===null||n===void 0||n.captureException([t.name,void 0,void 0,void 0,t],r)}},{key:"capture",value:function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Uf;if(!this.__loaded||!this.sessionPersistence||!this._requestQueue)return Ge.unintializedWarning("posthog.capture");if(!function(l,c){var f=!1;try{var d=l.get_config("token"),h=l.get_config("respect_dnt"),p=l.get_config("opt_out_capturing_persistence_type"),v=l.get_config("opt_out_capturing_cookie_prefix")||void 0,_=l.get_config("window");d&&(f=ax(d,{respectDnt:h,persistenceType:p,persistencePrefix:v,window:_}))}catch(m){c||console.error("Unexpected error when checking capturing opt-out status: "+m)}return f}(this,!1)){var i=(n=n||Uf).transport;if(i&&(n.transport=i),kn(t)||typeof t!="string")console.error("No event name provided to posthog.capture");else if(!RJ(jn,this.get_config("custom_blocked_useragents"))){this.sessionPersistence.update_search_keyword(),this.get_config("store_google")&&this.sessionPersistence.update_campaign_params(),this.get_config("save_referrer")&&this.sessionPersistence.update_referrer_info();var a={uuid:Do(),event:t,properties:this._calculate_event_properties(t,r||{})};t==="$identify"&&(a.$set=n.$set,a.$set_once=n.$set_once),(a=bJ(a,n._noTruncate?null:this.get_config("properties_string_max_length"))).timestamp=n.timestamp||new Date,this.get_config("debug")&&Ge.log("PostHog.js send",a);var o=JSON.stringify(a),s=this.get_config("api_host")+(n.endpoint||"/e/"),u=n!==Uf;return!this.get_config("request_batching")||u&&!n._batchKey||n.send_instantly?this.__compress_and_send_json_request(s,o,n):this._requestQueue.enqueue(s,a,n),this._invokeCaptureHooks(t,a),a}}}},{key:"_addCaptureHook",value:function(t){this.__captureHooks.push(t)}},{key:"_invokeCaptureHooks",value:function(t,r){this.config._onCapture(t,r),it(this.__captureHooks,function(n){return n(t)})}},{key:"_calculate_event_properties",value:function(t,r){if(!this.persistence||!this.sessionPersistence)return r;var n=this.persistence.remove_event_timer(t),i=ke({},r);if(i.token=this.get_config("token"),t==="$snapshot"){var a=ke(ke({},this.persistence.properties()),this.sessionPersistence.properties());return i.distinct_id=a.distinct_id,i}var o=dr.properties();if(this.sessionManager){var s=this.sessionManager.checkAndGetSessionAndWindowId(),u=s.sessionId,l=s.windowId;i.$session_id=u,i.$window_id=l}if(this.get_config("__preview_measure_pageview_stats")){var c={};t==="$pageview"?c=this.pageViewManager.doPageView():t==="$pageleave"&&(c=this.pageViewManager.doPageLeave()),i=wr(i,c)}if(t==="$pageview"&&(i.title=Ct.title),t==="$performance_event"){var f=this.persistence.properties();return i.distinct_id=f.distinct_id,i.$current_url=o.$current_url,i}if(n!==void 0){var d=new Date().getTime()-n;i.$duration=parseFloat((d/1e3).toFixed(3))}i=wr({},dr.properties(),this.persistence.properties(),this.sessionPersistence.properties(),i);var h=this.get_config("property_blacklist");Ci(h)?it(h,function(v){delete i[v]}):console.error("Invalid value for property_blacklist config: "+h);var p=this.get_config("sanitize_properties");return p&&(i=p(i,t)),i}},{key:"register",value:function(t,r){var n;(n=this.persistence)===null||n===void 0||n.register(t,r)}},{key:"register_once",value:function(t,r,n){var i;(i=this.persistence)===null||i===void 0||i.register_once(t,r,n)}},{key:"register_for_session",value:function(t){var r;(r=this.sessionPersistence)===null||r===void 0||r.register(t)}},{key:"unregister",value:function(t){var r;(r=this.persistence)===null||r===void 0||r.unregister(t)}},{key:"unregister_for_session",value:function(t){var r;(r=this.sessionPersistence)===null||r===void 0||r.unregister(t)}},{key:"_register_single",value:function(t,r){this.register(me({},t,r))}},{key:"getFeatureFlag",value:function(t,r){return this.featureFlags.getFeatureFlag(t,r)}},{key:"getFeatureFlagPayload",value:function(t){var r=this.featureFlags.getFeatureFlagPayload(t);try{return JSON.parse(r)}catch{return r}}},{key:"isFeatureEnabled",value:function(t,r){return this.featureFlags.isFeatureEnabled(t,r)}},{key:"reloadFeatureFlags",value:function(){this.featureFlags.reloadFeatureFlags()}},{key:"updateEarlyAccessFeatureEnrollment",value:function(t,r){this.featureFlags.updateEarlyAccessFeatureEnrollment(t,r)}},{key:"getEarlyAccessFeatures",value:function(t){var r=arguments.length>1&&arguments[1]!==void 0&&arguments[1];return this.featureFlags.getEarlyAccessFeatures(t,r)}},{key:"onFeatureFlags",value:function(t){return this.featureFlags.onFeatureFlags(t)}},{key:"onSessionId",value:function(t){var r,n;return(r=(n=this.sessionManager)===null||n===void 0?void 0:n.onSessionId(t))!==null&&r!==void 0?r:function(){}}},{key:"getSurveys",value:function(t){var r=arguments.length>1&&arguments[1]!==void 0&&arguments[1];this.surveys.getSurveys(t,r)}},{key:"getActiveMatchingSurveys",value:function(t){var r=arguments.length>1&&arguments[1]!==void 0&&arguments[1];this.surveys.getActiveMatchingSurveys(t,r)}},{key:"identify",value:function(t,r,n){if(!this.__loaded||!this.persistence)return Ge.unintializedWarning("posthog.identify");if(t){var i=this.get_distinct_id();if(this.register({$user_id:t}),!this.get_property("$device_id")){var a=i;this.register_once({$had_persisted_distinct_id:!0,$device_id:a},"")}t!==i&&t!==this.get_property(Pd)&&(this.unregister(Pd),this.register({distinct_id:t}));var o=this.persistence.get_user_state()==="anonymous";t!==i&&o?(this.persistence.set_user_state("identified"),this.setPersonPropertiesForFlags(r||{},!1),this.capture("$identify",{distinct_id:t,$anon_distinct_id:i},{$set:r||{},$set_once:n||{}}),this.featureFlags.setAnonymousDistinctId(i)):(r||n)&&this.setPersonProperties(r,n),t!==i&&(this.reloadFeatureFlags(),this.unregister(Bh))}else console.error("Unique user id has not been set in posthog.identify")}},{key:"setPersonProperties",value:function(t,r){(t||r)&&(this.setPersonPropertiesForFlags(t||{}),this.capture("$set",{$set:t||{},$set_once:r||{}}))}},{key:"group",value:function(t,r,n){if(t&&r){var i=this.getGroups();i[t]!==r&&this.resetGroupPropertiesForFlags(t),this.register({$groups:ke(ke({},i),{},me({},t,r))}),n&&(this.capture("$groupidentify",{$group_type:t,$group_key:r,$group_set:n}),this.setGroupPropertiesForFlags(me({},t,n))),i[t]===r||n||this.reloadFeatureFlags()}else console.error("posthog.group requires a group type and group key")}},{key:"resetGroups",value:function(){this.register({$groups:{}}),this.resetGroupPropertiesForFlags(),this.reloadFeatureFlags()}},{key:"setPersonPropertiesForFlags",value:function(t){var r=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1];this.featureFlags.setPersonPropertiesForFlags(t,r)}},{key:"resetPersonPropertiesForFlags",value:function(){this.featureFlags.resetPersonPropertiesForFlags()}},{key:"setGroupPropertiesForFlags",value:function(t){var r=!(arguments.length>1&&arguments[1]!==void 0)||arguments[1];this.featureFlags.setGroupPropertiesForFlags(t,r)}},{key:"resetGroupPropertiesForFlags",value:function(t){this.featureFlags.resetGroupPropertiesForFlags(t)}},{key:"reset",value:function(t){var r,n,i,a;if(!this.__loaded)return Ge.unintializedWarning("posthog.reset");var o=this.get_property("$device_id");(r=this.persistence)===null||r===void 0||r.clear(),(n=this.sessionPersistence)===null||n===void 0||n.clear(),(i=this.persistence)===null||i===void 0||i.set_user_state("anonymous"),(a=this.sessionManager)===null||a===void 0||a.resetSessionId();var s=this.get_config("get_device_id")(Do());this.register_once({distinct_id:s,$device_id:t?s:o},"")}},{key:"get_distinct_id",value:function(){return this.get_property("distinct_id")}},{key:"getGroups",value:function(){return this.get_property("$groups")||{}}},{key:"get_session_id",value:function(){var t,r;return(t=(r=this.sessionManager)===null||r===void 0?void 0:r.checkAndGetSessionAndWindowId(!0).sessionId)!==null&&t!==void 0?t:""}},{key:"get_session_replay_url",value:function(t){if(!this.sessionManager)return"";var r=this.config.ui_host||this.config.api_host,n=this.sessionManager.checkAndGetSessionAndWindowId(!0),i=n.sessionId,a=n.sessionStartTimestamp,o=r+"/replay/"+i;if(t!=null&&t.withTimestamp&&a){var s,u=(s=t.timestampLookBack)!==null&&s!==void 0?s:10;if(!a)return o;var l=Math.max(Math.floor((new Date().getTime()-a)/1e3)-u,0);o+="?t=".concat(l)}return o}},{key:"alias",value:function(t,r){return t===this.get_property(Tz)?(Ge.critical("Attempting to create alias for existing People user - aborting."),-2):(kn(r)&&(r=this.get_distinct_id()),t!==r?(this._register_single(Pd,t),this.capture("$create_alias",{alias:t,distinct_id:r})):(console.error("alias matches current distinct_id - skipping api call."),this.identify(t),-1))}},{key:"set_config",value:function(t){var r,n,i=ke({},this.config);Kw(t)&&(wr(this.config,t),this.get_config("persistence_name")||(this.config.persistence_name=this.config.cookie_name),this.get_config("disable_persistence")||(this.config.disable_persistence=this.config.disable_cookie),(r=this.persistence)===null||r===void 0||r.update_config(this.config),(n=this.sessionPersistence)===null||n===void 0||n.update_config(this.config),Mt.is_supported()&&Mt.get("ph_debug")==="true"&&(this.config.debug=!0),this.get_config("debug")&&(Pn.DEBUG=!0),this.sessionRecording&&t.disable_session_recording!==void 0&&i.disable_session_recording!==t.disable_session_recording&&(t.disable_session_recording?this.sessionRecording.stopRecording():this.sessionRecording.startRecordingIfEnabled()))}},{key:"startSessionRecording",value:function(){this.set_config({disable_session_recording:!1})}},{key:"stopSessionRecording",value:function(){this.set_config({disable_session_recording:!0})}},{key:"sessionRecordingStarted",value:function(){var t;return!((t=this.sessionRecording)===null||t===void 0||!t.started())}},{key:"loadToolbar",value:function(t){return this.toolbar.loadToolbar(t)}},{key:"get_config",value:function(t){var r;return(r=this.config)===null||r===void 0?void 0:r[t]}},{key:"get_property",value:function(t){var r;return(r=this.persistence)===null||r===void 0?void 0:r.props[t]}},{key:"getSessionProperty",value:function(t){var r;return(r=this.sessionPersistence)===null||r===void 0?void 0:r.props[t]}},{key:"toString",value:function(){var t,r=(t=this.get_config("name"))!==null&&t!==void 0?t:Gr;return r!==Gr&&(r=Gr+"."+r),r}},{key:"_gdpr_init",value:function(){this.get_config("opt_out_capturing_persistence_type")==="localStorage"&&Mt.is_supported()&&(!this.has_opted_in_capturing()&&this.has_opted_in_capturing({persistence_type:"cookie"})&&this.opt_in_capturing({enable_persistence:!1}),!this.has_opted_out_capturing()&&this.has_opted_out_capturing({persistence_type:"cookie"})&&this.opt_out_capturing({clear_persistence:!1}),this.clear_opt_in_out_capturing({persistence_type:"cookie",enable_persistence:!1})),this.has_opted_out_capturing()?this._gdpr_update_persistence({clear_persistence:!0}):this.has_opted_in_capturing()||!this.get_config("opt_out_capturing_by_default")&&!Ui.get("ph_optout")||(Ui.remove("ph_optout"),this.opt_out_capturing({clear_persistence:this.get_config("opt_out_persistence_by_default")}))}},{key:"_gdpr_update_persistence",value:function(t){var r,n,i,a,o;if(t&&t.clear_persistence)i=!0;else{if(!t||!t.enable_persistence)return;i=!1}this.get_config("disable_persistence")||((r=this.persistence)===null||r===void 0?void 0:r.disabled)===i||(a=this.persistence)===null||a===void 0||a.set_disabled(i),this.get_config("disable_persistence")||((n=this.sessionPersistence)===null||n===void 0?void 0:n.disabled)===i||(o=this.sessionPersistence)===null||o===void 0||o.set_disabled(i)}},{key:"_gdpr_call_func",value:function(t,r){return r=wr({capture:this.capture.bind(this),persistence_type:this.get_config("opt_out_capturing_persistence_type"),cookie_prefix:this.get_config("opt_out_capturing_cookie_prefix"),cookie_expiration:this.get_config("cookie_expiration"),cross_subdomain_cookie:this.get_config("cross_subdomain_cookie"),secure_cookie:this.get_config("secure_cookie")},r||{}),Mt.is_supported()||r.persistence_type!=="localStorage"||(r.persistence_type="cookie"),t(this.get_config("token"),{capture:r.capture,captureEventName:r.capture_event_name,captureProperties:r.capture_properties,persistenceType:r.persistence_type,persistencePrefix:r.cookie_prefix,cookieExpiration:r.cookie_expiration,crossSubdomainCookie:r.cross_subdomain_cookie,secureCookie:r.secure_cookie})}},{key:"opt_in_capturing",value:function(t){t=wr({enable_persistence:!0},t||{}),this._gdpr_call_func(JJ,t),this._gdpr_update_persistence(t)}},{key:"opt_out_capturing",value:function(t){var r=wr({clear_persistence:!0},t||{});this._gdpr_call_func(XJ,r),this._gdpr_update_persistence(r)}},{key:"has_opted_in_capturing",value:function(t){return this._gdpr_call_func(ZJ,t)}},{key:"has_opted_out_capturing",value:function(t){return this._gdpr_call_func(ax,t)}},{key:"clear_opt_in_out_capturing",value:function(t){var r=wr({enable_persistence:!0},t??{});this._gdpr_call_func(eX,r),this._gdpr_update_persistence(r)}},{key:"debug",value:function(t){t===!1?(he.console.log("You've disabled debug mode."),localStorage&&localStorage.removeItem("ph_debug"),this.set_config({debug:!1})):(he.console.log("You're now in debug mode. All calls to PostHog will be logged in your console.\nYou can disable this with `posthog.debug(false)`."),localStorage&&localStorage.setItem("ph_debug","true"),this.set_config({debug:!0}))}}]),e}();(function(e,t){for(var r=0;r"u"&&Ym!==void 0?function(e){return typeof e=="function"||e===Ym}:function(e){return typeof e=="function"},Zp={},JX=Ve,sr=!JX(function(){return Object.defineProperty({},1,{get:function(){return 7}})[1]!==7}),XX=Jp,Bf=Function.prototype.call,ur=XX?Bf.bind(Bf):function(){return Bf.apply(Bf,arguments)},zc={},Hz={}.propertyIsEnumerable,Wz=Object.getOwnPropertyDescriptor,ZX=Wz&&!Hz.call({1:2},1);zc.f=ZX?function(t){var r=Wz(this,t);return!!r&&r.enumerable}:Hz;var Bu=function(e,t){return{enumerable:!(e&1),configurable:!(e&2),writable:!(e&4),value:t}},eZ=Ke,tZ=Ve,rZ=Cn,Qm=Object,nZ=eZ("".split),ev=tZ(function(){return!Qm("z").propertyIsEnumerable(0)})?function(e){return rZ(e)==="String"?nZ(e,""):Qm(e)}:Qm,rs=function(e){return e==null},iZ=rs,aZ=TypeError,ei=function(e){if(iZ(e))throw new aZ("Can't call method on "+e);return e},oZ=ev,sZ=ei,_i=function(e){return oZ(sZ(e))},uZ=jt,Ir=function(e){return typeof e=="object"?e!==null:uZ(e)},Gt={},Km=Gt,Jm=ft,lZ=jt,Ex=function(e){return lZ(e)?e:void 0},$n=function(e,t){return arguments.length<2?Ex(Km[e])||Ex(Jm[e]):Km[e]&&Km[e][t]||Jm[e]&&Jm[e][t]},cZ=Ke,mt=cZ({}.isPrototypeOf),fZ=ft,wx=fZ.navigator,Rx=wx&&wx.userAgent,Dk=Rx?String(Rx):"",Gz=ft,Xm=Dk,Tx=Gz.process,kx=Gz.Deno,Ox=Tx&&Tx.versions||kx&&kx.version,Px=Ox&&Ox.v8,Bn,Hh;Px&&(Bn=Px.split("."),Hh=Bn[0]>0&&Bn[0]<4?1:+(Bn[0]+Bn[1]));!Hh&&Xm&&(Bn=Xm.match(/Edge\/(\d+)/),(!Bn||Bn[1]>=74)&&(Bn=Xm.match(/Chrome\/(\d+)/),Bn&&(Hh=+Bn[1])));var Hc=Hh,Ix=Hc,dZ=Ve,hZ=ft,pZ=hZ.String,zu=!!Object.getOwnPropertySymbols&&!dZ(function(){var e=Symbol("symbol detection");return!pZ(e)||!(Object(e)instanceof Symbol)||!Symbol.sham&&Ix&&Ix<41}),vZ=zu,Vz=vZ&&!Symbol.sham&&typeof Symbol.iterator=="symbol",mZ=$n,gZ=jt,_Z=mt,yZ=Vz,SZ=Object,Wc=yZ?function(e){return typeof e=="symbol"}:function(e){var t=mZ("Symbol");return gZ(t)&&_Z(t.prototype,SZ(e))},bZ=String,Hu=function(e){try{return bZ(e)}catch{return"Object"}},EZ=jt,wZ=Hu,RZ=TypeError,Wu=function(e){if(EZ(e))return e;throw new RZ(wZ(e)+" is not a function")},TZ=Wu,kZ=rs,tv=function(e,t){var r=e[t];return kZ(r)?void 0:TZ(r)},Zm=ur,eg=jt,tg=Ir,OZ=TypeError,PZ=function(e,t){var r,n;if(t==="string"&&eg(r=e.toString)&&!tg(n=Zm(r,e))||eg(r=e.valueOf)&&!tg(n=Zm(r,e))||t!=="string"&&eg(r=e.toString)&&!tg(n=Zm(r,e)))return n;throw new OZ("Can't convert object to primitive value")},Yz={exports:{}},Qz=!0,xx=ft,IZ=Object.defineProperty,xZ=function(e,t){try{IZ(xx,e,{value:t,configurable:!0,writable:!0})}catch{xx[e]=t}return t},CZ=ft,$Z=xZ,Cx="__core-js_shared__",$x=Yz.exports=CZ[Cx]||$Z(Cx,{});($x.versions||($x.versions=[])).push({version:"3.38.0",mode:"pure",copyright:"© 2014-2024 Denis Pushkarev (zloirock.ru)",license:"https://github.com/zloirock/core-js/blob/v3.38.0/LICENSE",source:"https://github.com/zloirock/core-js"});var Nk=Yz.exports,Dx=Nk,Gu=function(e,t){return Dx[e]||(Dx[e]=t||{})},DZ=ei,NZ=Object,en=function(e){return NZ(DZ(e))},AZ=Ke,LZ=en,MZ=AZ({}.hasOwnProperty),Vt=Object.hasOwn||function(t,r){return MZ(LZ(t),r)},FZ=Ke,jZ=0,qZ=Math.random(),UZ=FZ(1 .toString),rv=function(e){return"Symbol("+(e===void 0?"":e)+")_"+UZ(++jZ+qZ,36)},BZ=ft,zZ=Gu,Nx=Vt,HZ=rv,WZ=zu,GZ=Vz,Bs=BZ.Symbol,rg=zZ("wks"),VZ=GZ?Bs.for||Bs:Bs&&Bs.withoutSetter||HZ,wt=function(e){return Nx(rg,e)||(rg[e]=WZ&&Nx(Bs,e)?Bs[e]:VZ("Symbol."+e)),rg[e]},YZ=ur,Ax=Ir,Lx=Wc,QZ=tv,KZ=PZ,JZ=wt,XZ=TypeError,ZZ=JZ("toPrimitive"),Kz=function(e,t){if(!Ax(e)||Lx(e))return e;var r=QZ(e,ZZ),n;if(r){if(t===void 0&&(t="default"),n=YZ(r,e,t),!Ax(n)||Lx(n))return n;throw new XZ("Can't convert object to primitive value")}return t===void 0&&(t="number"),KZ(e,t)},eee=Kz,tee=Wc,Ak=function(e){var t=eee(e,"string");return tee(t)?t:t+""},ree=ft,Mx=Ir,cR=ree.document,nee=Mx(cR)&&Mx(cR.createElement),Jz=function(e){return nee?cR.createElement(e):{}},iee=sr,aee=Ve,oee=Jz,Xz=!iee&&!aee(function(){return Object.defineProperty(oee("div"),"a",{get:function(){return 7}}).a!==7}),see=sr,uee=ur,lee=zc,cee=Bu,fee=_i,dee=Ak,hee=Vt,pee=Xz,Fx=Object.getOwnPropertyDescriptor;Zp.f=see?Fx:function(t,r){if(t=fee(t),r=dee(r),pee)try{return Fx(t,r)}catch{}if(hee(t,r))return cee(!uee(lee.f,t,r),t[r])};var vee=Ve,mee=jt,gee=/#|\.prototype\./,Gc=function(e,t){var r=yee[_ee(e)];return r===bee?!0:r===See?!1:mee(t)?vee(t):!!t},_ee=Gc.normalize=function(e){return String(e).replace(gee,".").toLowerCase()},yee=Gc.data={},See=Gc.NATIVE="N",bee=Gc.POLYFILL="P",Eee=Gc,jx=Uu,wee=Wu,Ree=Jp,Tee=jx(jx.bind),uo=function(e,t){return wee(e),t===void 0?e:Ree?Tee(e,t):function(){return e.apply(t,arguments)}},mn={},kee=sr,Oee=Ve,Zz=kee&&Oee(function(){return Object.defineProperty(function(){},"prototype",{value:42,writable:!1}).prototype!==42}),Pee=Ir,Iee=String,xee=TypeError,_r=function(e){if(Pee(e))return e;throw new xee(Iee(e)+" is not an object")},Cee=sr,$ee=Xz,Dee=Zz,zf=_r,qx=Ak,Nee=TypeError,ng=Object.defineProperty,Aee=Object.getOwnPropertyDescriptor,ig="enumerable",ag="configurable",og="writable";mn.f=Cee?Dee?function(t,r,n){if(zf(t),r=qx(r),zf(n),typeof t=="function"&&r==="prototype"&&"value"in n&&og in n&&!n[og]){var i=Aee(t,r);i&&i[og]&&(t[r]=n.value,n={configurable:ag in n?n[ag]:i[ag],enumerable:ig in n?n[ig]:i[ig],writable:!1})}return ng(t,r,n)}:ng:function(t,r,n){if(zf(t),r=qx(r),zf(n),$ee)try{return ng(t,r,n)}catch{}if("get"in n||"set"in n)throw new Nee("Accessors not supported");return"value"in n&&(t[r]=n.value),t};var Lee=sr,Mee=mn,Fee=Bu,Vc=Lee?function(e,t,r){return Mee.f(e,t,Fee(1,r))}:function(e,t,r){return e[t]=r,e},pl=ft,jee=Xp,qee=Uu,Uee=jt,Bee=Zp.f,zee=Eee,vs=Gt,Hee=uo,ms=Vc,Ux=Vt,Wee=function(e){var t=function(r,n,i){if(this instanceof t){switch(arguments.length){case 0:return new e;case 1:return new e(r);case 2:return new e(r,n)}return new e(r,n,i)}return jee(e,this,arguments)};return t.prototype=e.prototype,t},ge=function(e,t){var r=e.target,n=e.global,i=e.stat,a=e.proto,o=n?pl:i?pl[r]:pl[r]&&pl[r].prototype,s=n?vs:vs[r]||ms(vs,r,{})[r],u=s.prototype,l,c,f,d,h,p,v,_,m;for(d in t)l=zee(n?d:r+(i?".":"#")+d,e.forced),c=!l&&o&&Ux(o,d),p=s[d],c&&(e.dontCallGetSet?(m=Bee(o,d),v=m&&m.value):v=o[d]),h=c&&v?v:t[d],!(!l&&!a&&typeof p==typeof h)&&(e.bind&&c?_=Hee(h,pl):e.wrap&&c?_=Wee(h):a&&Uee(h)?_=qee(h):_=h,(e.sham||h&&h.sham||p&&p.sham)&&ms(_,"sham",!0),ms(s,d,_),a&&(f=r+"Prototype",Ux(vs,f)||ms(vs,f,{}),ms(vs[f],d,h),e.real&&u&&(l||!u[d])&&ms(u,d,h)))},Gee=ge,Vee=sr,Bx=mn.f;Gee({target:"Object",stat:!0,forced:Object.defineProperty!==Bx,sham:!Vee},{defineProperty:Bx});var Yee=Gt,eH=Yee.Object,Qee=jz.exports=function(t,r,n){return eH.defineProperty(t,r,n)};eH.defineProperty.sham&&(Qee.sham=!0);var Kee=jz.exports,Jee=Kee,Xee=Jee,Zee=Xee,ete=Zee,tte=ete,rte=tte,tH=rte,xe=tH,nte=wt,ite=nte("toStringTag"),rH={};rH[ite]="z";var Lk=String(rH)==="[object z]",ate=Lk,ote=jt,Nd=Cn,ste=wt,ute=ste("toStringTag"),lte=Object,cte=Nd(function(){return arguments}())==="Arguments",fte=function(e,t){try{return e[t]}catch{}},ns=ate?Nd:function(e){var t,r,n;return e===void 0?"Undefined":e===null?"Null":typeof(r=fte(t=lte(e),ute))=="string"?r:cte?Nd(t):(n=Nd(t))==="Object"&&ote(t.callee)?"Arguments":n},dte=Math.ceil,hte=Math.floor,pte=Math.trunc||function(t){var r=+t;return(r>0?hte:dte)(r)},vte=pte,lo=function(e){var t=+e;return t!==t||t===0?0:vte(t)},mte=lo,gte=Math.min,Yc=function(e){var t=mte(e);return t>0?gte(t,9007199254740991):0},_te=Yc,ti=function(e){return _te(e.length)},yte=Cn,is=Array.isArray||function(t){return yte(t)==="Array"},sg,zx;function Ste(){if(zx)return sg;zx=1;var e=Ke,t=jt,r=Nk,n=e(Function.toString);return t(r.inspectSource)||(r.inspectSource=function(i){return n(i)}),sg=r.inspectSource,sg}var ug,Hx;function nv(){if(Hx)return ug;Hx=1;var e=Ke,t=Ve,r=jt,n=ns,i=$n,a=Ste(),o=function(){},s=i("Reflect","construct"),u=/^\s*(?:class|function)\b/,l=e(u.exec),c=!u.test(o),f=function(p){if(!r(p))return!1;try{return s(o,[],p),!0}catch{return!1}},d=function(p){if(!r(p))return!1;switch(n(p)){case"AsyncFunction":case"GeneratorFunction":case"AsyncGeneratorFunction":return!1}try{return c||!!l(u,a(p))}catch{return!0}};return d.sham=!0,ug=!s||t(function(){var h;return f(f.call)||!f(Object)||!f(function(){h=!0})||h})?d:f,ug}var Wx=is,bte=nv(),Ete=Ir,wte=wt,Rte=wte("species"),Gx=Array,Tte=function(e){var t;return Wx(e)&&(t=e.constructor,bte(t)&&(t===Gx||Wx(t.prototype))?t=void 0:Ete(t)&&(t=t[Rte],t===null&&(t=void 0))),t===void 0?Gx:t},kte=Tte,iv=function(e,t){return new(kte(e))(t===0?0:t)},Ote=uo,Pte=Ke,Ite=ev,xte=en,Cte=ti,$te=iv,Vx=Pte([].push),va=function(e){var t=e===1,r=e===2,n=e===3,i=e===4,a=e===6,o=e===7,s=e===5||a;return function(u,l,c,f){for(var d=xte(u),h=Ite(d),p=Cte(h),v=Ote(l,c),_=0,m=f||$te,g=t?m(u,p):r||o?m(u,0):void 0,y,S;p>_;_++)if((s||_ in h)&&(y=h[_],S=v(y,_,d),e))if(t)g[_]=S;else if(S)switch(e){case 3:return!0;case 5:return y;case 6:return _;case 2:Vx(g,y)}else switch(e){case 4:return!1;case 7:Vx(g,y)}return a?-1:n||i?i:g}},ua={forEach:va(0),map:va(1),filter:va(2),some:va(3),every:va(4),find:va(5),findIndex:va(6),filterReject:va(7)},Dte=Ve,Vu=function(e,t){var r=[][e];return!!r&&Dte(function(){r.call(null,t||function(){return 1},1)})},Nte=ua.forEach,Ate=Vu,Lte=Ate("forEach"),Mte=Lte?[].forEach:function(t){return Nte(this,t,arguments.length>1?arguments[1]:void 0)},Fte=ge,Yx=Mte;Fte({target:"Array",proto:!0,forced:[].forEach!==Yx},{forEach:Yx});var lg,Qx;function Rt(){if(Qx)return lg;Qx=1;var e=ft,t=Gt;return lg=function(r,n){var i=t[r+"Prototype"],a=i&&i[n];if(a)return a;var o=e[r],s=o&&o.prototype;return s&&s[n]},lg}var jte=Rt(),qte=jte("Array","forEach"),Ute=qte,Bte=Ute,zte=ns,Hte=Vt,Wte=mt,Gte=Bte,cg=Array.prototype,Vte={DOMTokenList:!0,NodeList:!0},Yte=function(e){var t=e.forEach;return e===cg||Wte(cg,e)&&t===cg.forEach||Hte(Vte,zte(e))?Gte:t},Qte=Yte,Kte=Qte,Jte=Kte,Xte=Jte,Zte=Xte,av=Zte,ere=lo,tre=Math.max,rre=Math.min,nH=function(e,t){var r=ere(e);return r<0?tre(r+t,0):rre(r,t)},nre=_i,ire=nH,are=ti,Kx=function(e){return function(t,r,n){var i=nre(t),a=are(i);if(a===0)return!e&&-1;var o=ire(n,a),s;if(e&&r!==r){for(;a>o;)if(s=i[o++],s!==s)return!0}else for(;a>o;o++)if((e||o in i)&&i[o]===r)return e||o||0;return!e&&-1}},Mk={includes:Kx(!0),indexOf:Kx(!1)},Qc={},ore=Ke,fg=Vt,sre=_i,ure=Mk.indexOf,lre=Qc,Jx=ore([].push),iH=function(e,t){var r=sre(e),n=0,i=[],a;for(a in r)!fg(lre,a)&&fg(r,a)&&Jx(i,a);for(;t.length>n;)fg(r,a=t[n++])&&(~ure(i,a)||Jx(i,a));return i},Fk=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],cre=iH,fre=Fk,Kc=Object.keys||function(t){return cre(t,fre)},dre=ge,hre=en,aH=Kc,pre=Ve,vre=pre(function(){aH(1)});dre({target:"Object",stat:!0,forced:vre},{keys:function(t){return aH(hre(t))}});var mre=Gt,gre=mre.Object.keys,_re=gre,yre=_re,Sre=yre,bre=Sre,Ere=bre,wre=Ere,Rre=wre,as=Rre,oH={exports:{}};(function(e){function t(r){return r&&r.__esModule?r:{default:r}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(oH);var dt=oH.exports,dg={},Xx;function Tre(){return Xx||(Xx=1,function(e){var t=xe;t(e,"__esModule",{value:!0})}(dg)),dg}var Zx={},eC={},tC={},rC;function sH(){if(rC)return tC;rC=1;var e=ge,t=ft;return e({global:!0,forced:t.globalThis!==t},{globalThis:t}),tC}var nC;function kre(){return nC||(nC=1,sH()),eC}var hg,iC;function Ore(){return iC||(iC=1,sH(),hg=ft),hg}var pg,aC;function Pre(){if(aC)return pg;aC=1;var e=Ore();return pg=e,pg}var vg,oC;function Ire(){if(oC)return vg;oC=1;var e=Pre();return vg=e,vg}var mg,sC;function xre(){if(sC)return mg;sC=1,kre();var e=Ire();return mg=e,mg}var gg,uC;function Cre(){return uC||(uC=1,gg=xre()),gg}var _g,lC;function yi(){return lC||(lC=1,_g=Cre()),_g}var cC;function $re(){if(cC)return Zx;cC=1;var e=dt.default,t=e(yi());return t.default.RWJS_API_GRAPHQL_URL="https://api.landingsite.ai/graphql",t.default.RWJS_API_URL="https://api.landingsite.ai",t.default.__REDWOOD__APP_TITLE="Landingsite",Zx}var yg={},fC;function Dre(){return fC||(fC=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.default=void 0;var n=r(I),i=P;class a extends n.default.Component{constructor(){super(...arguments),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}render(){return this.state.hasError?(0,i.jsx)("h1",{children:"Something went wrong and we are unable to show this page."}):this.props.children}}class o extends n.default.Component{constructor(){super(...arguments),this.state={hasError:!1,error:void 0}}static getDerivedStateFromError(u){return{hasError:!0,error:u}}render(){const{page:u}=this.props;return this.state.hasError?(0,i.jsx)(a,{children:(0,i.jsx)(u,{error:this.state.error})}):this.props.children}}e.default=o}(yg)),yg}var Sg={},bg,dC;function uH(){if(dC)return bg;dC=1;var e=Object.create,t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(p,v)=>{for(var _ in v)t(p,_,{get:v[_],enumerable:!0})},s=(p,v,_,m)=>{if(v&&typeof v=="object"||typeof v=="function")for(let g of n(v))!a.call(p,g)&&g!==_&&t(p,g,{get:()=>v[g],enumerable:!(m=r(v,g))||m.enumerable});return p},u=(p,v,_)=>(_=p!=null?e(i(p)):{},s(v||!p||!p.__esModule?t(_,"default",{value:p,enumerable:!0}):_,p)),l=p=>s(t({},"__esModule",{value:!0}),p),c={};o(c,{createUseAuth:()=>d,useNoAuth:()=>h}),bg=l(c);var f=u(I,1);function d(p){return()=>{const _=f.default.useContext(p);if(!_)throw new Error("useAuth must be used within an AuthProvider");return _}}function h(){return{loading:!1,isAuthenticated:!1,logIn:async()=>{},logOut:async()=>{},signUp:async()=>{},currentUser:null,userMetadata:null,getToken:async()=>null,getCurrentUser:async()=>null,hasRole:()=>!1,reauthenticate:async()=>{},forgotPassword:async()=>{},resetPassword:async()=>{},validateResetToken:async()=>{},type:"default",client:void 0,hasError:!1}}return bg}var Eg,hC;function Nre(){if(hC)return Eg;hC=1;var e=Object.create,t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(h,p)=>{for(var v in p)t(h,v,{get:p[v],enumerable:!0})},s=(h,p,v,_)=>{if(p&&typeof p=="object"||typeof p=="function")for(let m of n(p))!a.call(h,m)&&m!==v&&t(h,m,{get:()=>p[m],enumerable:!(_=r(p,m))||_.enumerable});return h},u=(h,p,v)=>(v=h!=null?e(i(h)):{},s(p||!h||!h.__esModule?t(v,"default",{value:h,enumerable:!0}):v,h)),l=h=>s(t({},"__esModule",{value:!0}),h),c={};o(c,{createAuthContext:()=>d}),Eg=l(c);var f=u(I,1);function d(){return f.default.createContext(void 0)}return Eg}var wg,pC;function lH(){if(pC)return wg;pC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(l,c)=>{for(var f in c)e(l,f,{get:c[f],enumerable:!0})},a=(l,c,f,d)=>{if(c&&typeof c=="object"||typeof c=="function")for(let h of r(c))!n.call(l,h)&&h!==f&&e(l,h,{get:()=>c[h],enumerable:!(d=t(c,h))||d.enumerable});return l},o=l=>a(e({},"__esModule",{value:!0}),l),s={};i(s,{defaultAuthProviderState:()=>u}),wg=o(s);const u={loading:!0,isAuthenticated:!1,userMetadata:null,currentUser:null,hasError:!1};return wg}var Rg,vC;function jk(){if(vC)return Rg;vC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useToken:()=>l}),Rg=o(s);var u=I;const l=c=>(0,u.useCallback)(async()=>{try{return await c.getToken()}catch(f){return console.error("Caught internal:",f),null}},[c]);return Rg}var Tg,mC;function Are(){if(mC)return Tg;mC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(f,d)=>{for(var h in d)e(f,h,{get:d[h],enumerable:!0})},a=(f,d,h,p)=>{if(d&&typeof d=="object"||typeof d=="function")for(let v of r(d))!n.call(f,v)&&v!==h&&e(f,v,{get:()=>d[v],enumerable:!(p=t(d,v))||p.enumerable});return f},o=f=>a(e({},"__esModule",{value:!0}),f),s={};i(s,{useCurrentUser:()=>c}),Tg=o(s);var u=I,l=jk();const c=f=>{const d=(0,l.useToken)(f);return(0,u.useCallback)(async()=>{var v;const h=await d(),p=await globalThis.fetch(globalThis.RWJS_API_GRAPHQL_URL,{method:"POST",credentials:"include",headers:{"content-type":"application/json","auth-provider":f.type,authorization:`Bearer ${h}`},body:JSON.stringify({query:"query __REDWOOD__AUTH_GET_CURRENT_USER { redwood { currentUser } }"})});if(p.ok){const{data:_}=await p.json();return(v=_==null?void 0:_.redwood)==null?void 0:v.currentUser}else throw new Error(`Could not fetch current user: ${p.statusText} (${p.status})`)},[f,d])};return Tg}var kg,gC;function Lre(){if(gC)return kg;gC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useForgotPassword:()=>l}),kg=o(s);var u=I;const l=c=>(0,u.useCallback)(async f=>{if(c.forgotPassword)return await c.forgotPassword(f);throw new Error(`Auth client ${c.type} does not implement this function`)},[c]);return kg}var Og,_C;function Mre(){if(_C)return Og;_C=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useHasRole:()=>l}),Og=o(s);var u=I;const l=c=>(0,u.useCallback)(f=>{var d,h;if(c!=null&&c.roles){if(typeof f=="string"){if(typeof c.roles=="string")return c.roles===f;if(Array.isArray(c.roles))return(d=c.roles)==null?void 0:d.some(p=>f===p)}if(Array.isArray(f)){if(Array.isArray(c.roles))return(h=c.roles)==null?void 0:h.some(p=>f.includes(p));if(typeof c.roles=="string")return f.some(p=>(c==null?void 0:c.roles)===p)}}return!1},[c]);return Og}var Pg,yC;function qk(){if(yC)return Pg;yC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(d,h)=>{for(var p in h)e(d,p,{get:h[p],enumerable:!0})},a=(d,h,p,v)=>{if(h&&typeof h=="object"||typeof h=="function")for(let _ of r(h))!n.call(d,_)&&_!==p&&e(d,_,{get:()=>h[_],enumerable:!(v=t(h,_))||v.enumerable});return d},o=d=>a(e({},"__esModule",{value:!0}),d),s={};i(s,{useReauthenticate:()=>f}),Pg=o(s);var u=I,l=jk();const c={isAuthenticated:!1,currentUser:null,userMetadata:null,loading:!1,hasError:!1},f=(d,h,p,v)=>{const _=(0,l.useToken)(d);return(0,u.useCallback)(async()=>{d.loadWhileReauthenticating&&h(m=>({...m,loading:!0}));try{const m=await d.getUserMetadata();if(m){await _();const g=v?null:await p();h(y=>({...y,userMetadata:m,currentUser:g,isAuthenticated:!0,loading:!1,client:d.client}))}else{let g=!1;d.clientHasLoaded&&(g=!d.clientHasLoaded()),h({...c,loading:g,client:d.client})}}catch(m){h({...c,hasError:!0,error:m})}},[d,_,h,v,p])};return Pg}var Ig,SC;function Fre(){if(SC)return Ig;SC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(d,h)=>{for(var p in h)e(d,p,{get:h[p],enumerable:!0})},a=(d,h,p,v)=>{if(h&&typeof h=="object"||typeof h=="function")for(let _ of r(h))!n.call(d,_)&&_!==p&&e(d,_,{get:()=>h[_],enumerable:!(v=t(h,_))||v.enumerable});return d},o=d=>a(e({},"__esModule",{value:!0}),d),s={};i(s,{useLogIn:()=>f}),Ig=o(s);var u=I,l=lH(),c=qk();const f=(d,h,p,v)=>{const _=(0,c.useReauthenticate)(d,h,p,v);return(0,u.useCallback)(async m=>{h(l.defaultAuthProviderState);const g=await d.login(m);return await _(),g},[d,_,h])};return Ig}var xg,bC;function jre(){if(bC)return xg;bC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useLogOut:()=>l}),xg=o(s);var u=I;const l=(c,f)=>(0,u.useCallback)(async d=>{const h=await c.logout(d);return f({userMetadata:null,currentUser:null,isAuthenticated:!1,hasError:!1,error:void 0,loading:!1}),h},[c,f]);return xg}var Cg,EC;function qre(){if(EC)return Cg;EC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useResetPassword:()=>l}),Cg=o(s);var u=I;const l=c=>(0,u.useCallback)(async f=>{if(c.resetPassword)return await c.resetPassword(f);throw new Error(`Auth client ${c.type} does not implement this function`)},[c]);return Cg}var $g,wC;function Ure(){if(wC)return $g;wC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(f,d)=>{for(var h in d)e(f,h,{get:d[h],enumerable:!0})},a=(f,d,h,p)=>{if(d&&typeof d=="object"||typeof d=="function")for(let v of r(d))!n.call(f,v)&&v!==h&&e(f,v,{get:()=>d[v],enumerable:!(p=t(d,v))||p.enumerable});return f},o=f=>a(e({},"__esModule",{value:!0}),f),s={};i(s,{useSignUp:()=>c}),$g=o(s);var u=I,l=qk();const c=(f,d,h,p)=>{const v=(0,l.useReauthenticate)(f,d,h,p);return(0,u.useCallback)(async _=>{const m=await f.signup(_);return await v(),m},[f,v])};return $g}var Dg,RC;function Bre(){if(RC)return Dg;RC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{useValidateResetToken:()=>l}),Dg=o(s);var u=I;const l=c=>(0,u.useCallback)(async f=>{if(c.validateResetToken)return await c.validateResetToken(f);throw new Error(`Auth client ${c.type} does not implement this function`)},[c]);return Dg}var Ng,TC;function zre(){if(TC)return Ng;TC=1;var e=Object.create,t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(R,O)=>{for(var k in O)t(R,k,{get:O[k],enumerable:!0})},s=(R,O,k,C)=>{if(O&&typeof O=="object"||typeof O=="function")for(let T of n(O))!a.call(R,T)&&T!==k&&t(R,T,{get:()=>O[T],enumerable:!(C=r(O,T))||C.enumerable});return R},u=(R,O,k)=>(k=R!=null?e(i(R)):{},s(O||!R||!R.__esModule?t(k,"default",{value:R,enumerable:!0}):k,R)),l=R=>s(t({},"__esModule",{value:!0}),R),c={};o(c,{createAuthProvider:()=>w}),Ng=l(c);var f=u(I,1),d=lH(),h=Are(),p=Lre(),v=Mre(),_=Fre(),m=jre(),g=qk(),y=qre(),S=Ure(),b=jk(),E=Bre();function w(R,O,k){return({children:T,skipFetchCurrentUser:$})=>{const[L,G]=(0,f.useState)(d.defaultAuthProviderState),Y=(0,b.useToken)(O),B=k!=null&&k.useCurrentUser?k.useCurrentUser:(0,h.useCurrentUser)(O),D=(0,g.useReauthenticate)(O,G,B,$),F=k!=null&&k.useHasRole?k.useHasRole(L.currentUser):(0,v.useHasRole)(L.currentUser),z=(0,S.useSignUp)(O,G,B,$),ee=(0,_.useLogIn)(O,G,B,$),Z=(0,m.useLogOut)(O,G),W=(0,p.useForgotPassword)(O),Q=(0,y.useResetPassword)(O),ae=(0,E.useValidateResetToken)(O),re=O.type,ie=O.client;return(0,f.useEffect)(()=>{async function Ee(){var Ie;await((Ie=O.restoreAuthState)==null?void 0:Ie.call(O)),D()}Ee()},[D]),f.default.createElement(R.Provider,{value:{...L,signUp:z,logIn:ee,logOut:Z,getToken:Y,getCurrentUser:B,hasRole:F,reauthenticate:D,forgotPassword:W,resetPassword:Q,validateResetToken:ae,client:ie,type:re}},T)}}return Ng}var Ag,kC;function Hre(){if(kC)return Ag;kC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(d,h)=>{for(var p in h)e(d,p,{get:h[p],enumerable:!0})},a=(d,h,p,v)=>{if(h&&typeof h=="object"||typeof h=="function")for(let _ of r(h))!n.call(d,_)&&_!==p&&e(d,_,{get:()=>h[_],enumerable:!(v=t(h,_))||v.enumerable});return d},o=d=>a(e({},"__esModule",{value:!0}),d),s={};i(s,{createAuthentication:()=>f}),Ag=o(s);var u=Nre(),l=zre(),c=uH();function f(d,h){const p=(0,u.createAuthContext)(),v=(0,c.createUseAuth)(p),_=(0,l.createAuthProvider)(p,d,h);return{AuthContext:p,AuthProvider:_,useAuth:v}}return Ag}var Lg,OC;function ov(){if(OC)return Lg;OC=1;var e=Object.defineProperty,t=Object.getOwnPropertyDescriptor,r=Object.getOwnPropertyNames,n=Object.prototype.hasOwnProperty,i=(c,f)=>{for(var d in f)e(c,d,{get:f[d],enumerable:!0})},a=(c,f,d,h)=>{if(f&&typeof f=="object"||typeof f=="function")for(let p of r(f))!n.call(c,p)&&p!==d&&e(c,p,{get:()=>f[p],enumerable:!(h=t(f,p))||h.enumerable});return c},o=c=>a(e({},"__esModule",{value:!0}),c),s={};i(s,{createAuthentication:()=>l.createAuthentication,useNoAuth:()=>u.useNoAuth}),Lg=o(s);var u=uH(),l=Hre();return Lg}var PC;function cH(){return PC||(PC=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.useFetchConfig=e.getApiGraphQLUrl=e.FetchConfigProvider=e.FetchConfigContext=void 0;var n=r(yi()),i=r(I),a=ov(),o=P;const s=()=>n.default.RWJS_API_GRAPHQL_URL;e.getApiGraphQLUrl=s;const u=e.FetchConfigContext=i.default.createContext({uri:s()}),l=f=>{let{useAuth:d=a.useNoAuth,...h}=f;const{isAuthenticated:p,type:v}=d();return p?(0,o.jsx)(u.Provider,{value:{uri:s(),headers:{"auth-provider":v}},...h}):(0,o.jsx)(u.Provider,{value:{uri:s()},...h})};e.FetchConfigProvider=l;const c=()=>i.default.useContext(u);e.useFetchConfig=c}(Sg)),Sg}var Mg={},IC;function Uk(){return IC||(IC=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.GraphQLHooksProvider=e.GraphQLHooksContext=void 0,e.useMutation=u,e.useQuery=s,e.useSubscription=l;var n=r(I),i=P;const a=e.GraphQLHooksContext=n.default.createContext({useQuery:()=>{throw new Error("You must register a useQuery hook via the `GraphQLHooksProvider`")},useMutation:()=>{throw new Error("You must register a useMutation hook via the `GraphQLHooksProvider`")},useSubscription:()=>{throw new Error("You must register a useSubscription hook via the `GraphQLHooksProvider`")}}),o=c=>{let{useQuery:f,useMutation:d,useSubscription:h,children:p}=c;return(0,i.jsx)(a.Provider,{value:{useQuery:f,useMutation:d,useSubscription:h},children:p})};e.GraphQLHooksProvider=o;function s(c,f){return n.default.useContext(a).useQuery(c,f)}function u(c,f){return n.default.useContext(a).useMutation(c,f)}function l(c,f){return n.default.useContext(a).useSubscription(c,f)}}(Mg)),Mg}var Fg={},fH={exports:{}},dH={exports:{}},Wre=TypeError,Gre=9007199254740991,hH=function(e){if(e>Gre)throw Wre("Maximum allowed index exceeded");return e},Vre=sr,Yre=mn,Qre=Bu,sv=function(e,t,r){Vre?Yre.f(e,t,Qre(0,r)):e[t]=r},Kre=Ve,Jre=wt,Xre=Hc,Zre=Jre("species"),uv=function(e){return Xre>=51||!Kre(function(){var t=[],r=t.constructor={};return r[Zre]=function(){return{foo:1}},t[e](Boolean).foo!==1})},ene=ge,tne=Ve,rne=is,nne=Ir,ine=en,ane=ti,xC=hH,CC=sv,one=iv,sne=uv,une=wt,lne=Hc,pH=une("isConcatSpreadable"),cne=lne>=51||!tne(function(){var e=[];return e[pH]=!1,e.concat()[0]!==e}),fne=function(e){if(!nne(e))return!1;var t=e[pH];return t!==void 0?!!t:rne(e)},dne=!cne||!sne("concat");ene({target:"Array",proto:!0,arity:1,forced:dne},{concat:function(t){var r=ine(this),n=one(r,0),i=0,a,o,s,u,l;for(a=-1,s=arguments.length;ao;)gne.f(t,s=i[o++],n[s]);return t};var bne=$n,Ene=bne("document","documentElement"),wne=Gu,Rne=rv,$C=wne("keys"),lv=function(e){return $C[e]||($C[e]=Rne(e))},Tne=_r,kne=Bk,DC=Fk,One=Qc,Pne=Ene,Ine=Jz,xne=lv,NC=">",AC="<",fR="prototype",dR="script",vH=xne("IE_PROTO"),jg=function(){},mH=function(e){return AC+dR+NC+e+AC+"/"+dR+NC},LC=function(e){e.write(mH("")),e.close();var t=e.parentWindow.Object;return e=null,t},Cne=function(){var e=Ine("iframe"),t="java"+dR+":",r;return e.style.display="none",Pne.appendChild(e),e.src=String(t),r=e.contentWindow.document,r.open(),r.write(mH("document.F=Object")),r.close(),r.F},Hf,Ad=function(){try{Hf=new ActiveXObject("htmlfile")}catch{}Ad=typeof document<"u"?document.domain&&Hf?LC(Hf):Cne():LC(Hf);for(var e=DC.length;e--;)delete Ad[fR][DC[e]];return Ad()};One[vH]=!0;var cv=Object.create||function(t,r){var n;return t!==null?(jg[fR]=Tne(t),n=new jg,jg[fR]=null,n[vH]=t):n=Ad(),r===void 0?n:kne.f(n,r)},fv={},$ne=iH,Dne=Fk,Nne=Dne.concat("length","prototype");fv.f=Object.getOwnPropertyNames||function(t){return $ne(t,Nne)};var zk={},qg,MC;function Yu(){if(MC)return qg;MC=1;var e=Ke;return qg=e([].slice),qg}var Ane=Cn,Lne=_i,gH=fv.f,Mne=Yu(),_H=typeof window=="object"&&window&&Object.getOwnPropertyNames?Object.getOwnPropertyNames(window):[],Fne=function(e){try{return gH(e)}catch{return Mne(_H)}};zk.f=function(t){return _H&&Ane(t)==="Window"?Fne(t):gH(Lne(t))};var dv={};dv.f=Object.getOwnPropertySymbols;var jne=Vc,os=function(e,t,r,n){return n&&n.enumerable?e[t]=r:jne(e,t,r),e},qne=mn,Hk=function(e,t,r){return qne.f(e,t,r)},hv={},Une=wt;hv.f=Une;var FC=Gt,Bne=Vt,zne=hv,Hne=mn.f,Tt=function(e){var t=FC.Symbol||(FC.Symbol={});Bne(t,e)||Hne(t,e,{value:zne.f(e)})},Wne=ur,Gne=$n,Vne=wt,Yne=os,yH=function(){var e=Gne("Symbol"),t=e&&e.prototype,r=t&&t.valueOf,n=Vne("toPrimitive");t&&!t[n]&&Yne(t,n,function(i){return Wne(r,this)},{arity:1})},Qne=Lk,Kne=ns,Jne=Qne?{}.toString:function(){return"[object "+Kne(this)+"]"},Xne=Lk,Zne=mn.f,eie=Vc,tie=Vt,rie=Jne,nie=wt,jC=nie("toStringTag"),la=function(e,t,r,n){var i=r?e:e&&e.prototype;i&&(tie(i,jC)||Zne(i,jC,{configurable:!0,value:t}),n&&!Xne&&eie(i,"toString",rie))},iie=ft,aie=jt,qC=iie.WeakMap,SH=aie(qC)&&/native code/.test(String(qC)),oie=SH,bH=ft,sie=Ir,uie=Vc,Ug=Vt,Bg=Nk,lie=lv,cie=Qc,UC="Object already initialized",hR=bH.TypeError,fie=bH.WeakMap,Wh,Tc,Gh,die=function(e){return Gh(e)?Tc(e):Wh(e,{})},hie=function(e){return function(t){var r;if(!sie(t)||(r=Tc(t)).type!==e)throw new hR("Incompatible receiver, "+e+" required");return r}};if(oie||Bg.state){var si=Bg.state||(Bg.state=new fie);si.get=si.get,si.has=si.has,si.set=si.set,Wh=function(e,t){if(si.has(e))throw new hR(UC);return t.facade=e,si.set(e,t),t},Tc=function(e){return si.get(e)||{}},Gh=function(e){return si.has(e)}}else{var gs=lie("state");cie[gs]=!0,Wh=function(e,t){if(Ug(e,gs))throw new hR(UC);return t.facade=e,uie(e,gs,t),t},Tc=function(e){return Ug(e,gs)?e[gs]:{}},Gh=function(e){return Ug(e,gs)}}var ca={set:Wh,get:Tc,has:Gh,enforce:die,getterFor:hie},pv=ge,Jc=ft,Wk=ur,pie=Ke,wu=sr,Ru=zu,vie=Ve,rr=Vt,mie=mt,pR=_r,vv=_i,Gk=Ak,gie=yr,vR=Bu,Tu=cv,EH=Kc,_ie=fv,wH=zk,yie=dv,RH=Zp,TH=mn,Sie=Bk,kH=zc,BC=os,bie=Hk,Vk=Gu,Eie=lv,OH=Qc,zC=rv,wie=wt,Rie=hv,Tie=Tt,kie=yH,Oie=la,PH=ca,mv=ua.forEach,Yr=Eie("hidden"),gv="Symbol",kc="prototype",Pie=PH.set,HC=PH.getterFor(gv),Wn=Object[kc],qo=Jc.Symbol,Cl=qo&&qo[kc],Iie=Jc.RangeError,xie=Jc.TypeError,zg=Jc.QObject,IH=RH.f,Uo=TH.f,xH=wH.f,Cie=kH.f,CH=pie([].push),Zi=Vk("symbols"),Xc=Vk("op-symbols"),$ie=Vk("wks"),mR=!zg||!zg[kc]||!zg[kc].findChild,$H=function(e,t,r){var n=IH(Wn,t);n&&delete Wn[t],Uo(e,t,r),n&&e!==Wn&&Uo(Wn,t,n)},gR=wu&&vie(function(){return Tu(Uo({},"a",{get:function(){return Uo(this,"a",{value:7}).a}})).a!==7})?$H:Uo,Hg=function(e,t){var r=Zi[e]=Tu(Cl);return Pie(r,{type:gv,tag:e,description:t}),wu||(r.description=t),r},_v=function(t,r,n){t===Wn&&_v(Xc,r,n),pR(t);var i=Gk(r);return pR(n),rr(Zi,i)?(n.enumerable?(rr(t,Yr)&&t[Yr][i]&&(t[Yr][i]=!1),n=Tu(n,{enumerable:vR(0,!1)})):(rr(t,Yr)||Uo(t,Yr,vR(1,Tu(null))),t[Yr][i]=!0),gR(t,i,n)):Uo(t,i,n)},Yk=function(t,r){pR(t);var n=vv(r),i=EH(n).concat(LH(n));return mv(i,function(a){(!wu||Wk(DH,n,a))&&_v(t,a,n[a])}),t},Die=function(t,r){return r===void 0?Tu(t):Yk(Tu(t),r)},DH=function(t){var r=Gk(t),n=Wk(Cie,this,r);return this===Wn&&rr(Zi,r)&&!rr(Xc,r)?!1:n||!rr(this,r)||!rr(Zi,r)||rr(this,Yr)&&this[Yr][r]?n:!0},NH=function(t,r){var n=vv(t),i=Gk(r);if(!(n===Wn&&rr(Zi,i)&&!rr(Xc,i))){var a=IH(n,i);return a&&rr(Zi,i)&&!(rr(n,Yr)&&n[Yr][i])&&(a.enumerable=!0),a}},AH=function(t){var r=xH(vv(t)),n=[];return mv(r,function(i){!rr(Zi,i)&&!rr(OH,i)&&CH(n,i)}),n},LH=function(e){var t=e===Wn,r=xH(t?Xc:vv(e)),n=[];return mv(r,function(i){rr(Zi,i)&&(!t||rr(Wn,i))&&CH(n,Zi[i])}),n};Ru||(qo=function(){if(mie(Cl,this))throw new xie("Symbol is not a constructor");var t=!arguments.length||arguments[0]===void 0?void 0:gie(arguments[0]),r=zC(t),n=function(i){var a=this===void 0?Jc:this;a===Wn&&Wk(n,Xc,i),rr(a,Yr)&&rr(a[Yr],r)&&(a[Yr][r]=!1);var o=vR(1,i);try{gR(a,r,o)}catch(s){if(!(s instanceof Iie))throw s;$H(a,r,o)}};return wu&&mR&&gR(Wn,r,{configurable:!0,set:n}),Hg(r,t)},Cl=qo[kc],BC(Cl,"toString",function(){return HC(this).tag}),BC(qo,"withoutSetter",function(e){return Hg(zC(e),e)}),kH.f=DH,TH.f=_v,Sie.f=Yk,RH.f=NH,_ie.f=wH.f=AH,yie.f=LH,Rie.f=function(e){return Hg(wie(e),e)},wu&&bie(Cl,"description",{configurable:!0,get:function(){return HC(this).description}}));pv({global:!0,constructor:!0,wrap:!0,forced:!Ru,sham:!Ru},{Symbol:qo});mv(EH($ie),function(e){Tie(e)});pv({target:gv,stat:!0,forced:!Ru},{useSetter:function(){mR=!0},useSimple:function(){mR=!1}});pv({target:"Object",stat:!0,forced:!Ru,sham:!wu},{create:Die,defineProperty:_v,defineProperties:Yk,getOwnPropertyDescriptor:NH});pv({target:"Object",stat:!0,forced:!Ru},{getOwnPropertyNames:AH});kie();Oie(qo,gv);OH[Yr]=!0;var Nie=zu,MH=Nie&&!!Symbol.for&&!!Symbol.keyFor,Aie=ge,Lie=$n,Mie=Vt,Fie=yr,FH=Gu,jie=MH,Wg=FH("string-to-symbol-registry"),qie=FH("symbol-to-string-registry");Aie({target:"Symbol",stat:!0,forced:!jie},{for:function(e){var t=Fie(e);if(Mie(Wg,t))return Wg[t];var r=Lie("Symbol")(t);return Wg[t]=r,qie[r]=t,r}});var Uie=ge,Bie=Vt,zie=Wc,Hie=Hu,Wie=Gu,Gie=MH,WC=Wie("symbol-to-string-registry");Uie({target:"Symbol",stat:!0,forced:!Gie},{keyFor:function(t){if(!zie(t))throw new TypeError(Hie(t)+" is not a symbol");if(Bie(WC,t))return WC[t]}});var GC={},Gg,VC;function Vie(){if(VC)return Gg;VC=1;var e=Ke,t=is,r=jt,n=Cn,i=yr,a=e([].push);return Gg=function(o){if(r(o))return o;if(t(o)){for(var s=o.length,u=[],l=0;l=t.length)return e.target=void 0,Vf(void 0,!0);switch(e.kind){case"keys":return Vf(r,!1);case"values":return Vf(t[r],!1)}return Vf([r,t[r]],!1)},"values");t$.Arguments=t$.Array;var noe={CSSRuleList:0,CSSStyleDeclaration:0,CSSValueList:0,ClientRectList:0,DOMRectList:0,DOMStringList:0,DOMTokenList:1,DataTransferItemList:0,FileList:0,HTMLAllCollection:0,HTMLCollection:0,HTMLFormElement:0,HTMLSelectElement:0,MediaList:0,MimeTypeArray:0,NamedNodeMap:0,NodeList:1,PaintRequestList:0,Plugin:0,PluginArray:0,SVGLengthList:0,SVGNumberList:0,SVGPathSegList:0,SVGPointList:0,SVGStringList:0,SVGTransformList:0,SourceBufferList:0,StyleSheetList:0,TextTrackCueList:0,TextTrackList:0,TouchList:0},ioe=noe,aoe=ft,ooe=la,r$=Qu;for(var Kg in ioe)ooe(aoe[Kg],Kg),r$[Kg]=r$.Array;var soe=_ae,uoe=soe,loe=wt,coe=mn.f,n$=loe("metadata"),i$=Function.prototype;i$[n$]===void 0&&coe(i$,n$,{value:null});var foe=Tt;foe("asyncDispose");var doe=Tt;doe("dispose");var hoe=Tt;hoe("metadata");var poe=uoe,voe=poe,moe=$n,goe=Ke,Xk=moe("Symbol"),_oe=Xk.keyFor,yoe=goe(Xk.prototype.valueOf),QH=Xk.isRegisteredSymbol||function(t){try{return _oe(yoe(t))!==void 0}catch{return!1}},Soe=ge,boe=QH;Soe({target:"Symbol",stat:!0},{isRegisteredSymbol:boe});var Eoe=Gu,KH=$n,woe=Ke,Roe=Wc,Toe=wt,Vh=KH("Symbol"),a$=Vh.isWellKnownSymbol,JH=KH("Object","getOwnPropertyNames"),koe=woe(Vh.prototype.valueOf),o$=Eoe("wks");for(var Jg=0,s$=JH(Vh),Ooe=s$.length;Jg=a?e?"":void 0:(o=l$(n,i),o<55296||o>56319||i+1===a||(s=l$(n,i+1))<56320||s>57343?e?Goe(n,i):o:e?Voe(n,i,i+2):(o-55296<<10)+(s-56320)+65536)}},Sv={codeAt:c$(!1),charAt:c$(!0)},Yoe=Sv.charAt,Qoe=yr,ZH=ca,Koe=GH,f$=yv,e4="String Iterator",Joe=ZH.set,Xoe=ZH.getterFor(e4);Koe(String,"String",function(e){Joe(this,{type:e4,string:Qoe(e),index:0})},function(){var t=Xoe(this),r=t.string,n=t.index,i;return n>=r.length?f$(void 0,!0):(i=Yoe(r,n),t.index+=i.length,f$(i,!1))});var Zoe=hv,ese=Zoe.f("iterator"),tse=ese,rse=tse,nse=rse,ise=nse,ase=ise,ose=ase,sse=ose;(function(e){var t=Boe,r=sse;function n(i){"@babel/helpers - typeof";return e.exports=n=typeof t=="function"&&typeof r=="symbol"?function(a){return typeof a}:function(a){return a&&typeof t=="function"&&a.constructor===t&&a!==t.prototype?"symbol":typeof a},e.exports.__esModule=!0,e.exports.default=e.exports,n(i)}e.exports=n,e.exports.__esModule=!0,e.exports.default=e.exports})(dH);var use=dH.exports,lse=Ve,t4=!lse(function(){return Object.isExtensible(Object.preventExtensions({}))}),cse=os,eO=function(e,t,r){for(var n in t)r&&r.unsafe&&e[n]?e[n]=t[n]:cse(e,n,t[n],r);return e},r4={exports:{}},fse=Ve,dse=fse(function(){if(typeof ArrayBuffer=="function"){var e=new ArrayBuffer(8);Object.isExtensible(e)&&Object.defineProperty(e,"a",{value:8})}}),hse=Ve,pse=Ir,vse=Cn,d$=dse,Ld=Object.isExtensible,mse=hse(function(){Ld(1)}),gse=mse||d$?function(t){return!pse(t)||d$&&vse(t)==="ArrayBuffer"?!1:Ld?Ld(t):!0}:Ld,_se=ge,yse=Ke,Sse=Qc,bse=Ir,tO=Vt,Ese=mn.f,h$=fv,wse=zk,rO=gse,Rse=rv,Tse=t4,n4=!1,ea=Rse("meta"),kse=0,nO=function(e){Ese(e,ea,{value:{objectID:"O"+kse++,weakData:{}}})},Ose=function(e,t){if(!bse(e))return typeof e=="symbol"?e:(typeof e=="string"?"S":"P")+e;if(!tO(e,ea)){if(!rO(e))return"F";if(!t)return"E";nO(e)}return e[ea].objectID},Pse=function(e,t){if(!tO(e,ea)){if(!rO(e))return!0;if(!t)return!1;nO(e)}return e[ea].weakData},Ise=function(e){return Tse&&n4&&rO(e)&&!tO(e,ea)&&nO(e),e},xse=function(){Cse.enable=function(){},n4=!0;var e=h$.f,t=yse([].splice),r={};r[ea]=1,e(r).length&&(h$.f=function(n){for(var i=e(n),a=0,o=i.length;af;f++)if(h=m(e[f]),h&&m$(_$,h))return h;return new Md(!1)}l=tue(e,c)}for(p=a?e.next:l.next;!(v=Kse(p,l)).done;){try{h=m(v.value)}catch(g){g$(l,"throw",g)}if(typeof h=="object"&&h&&m$(_$,h))return h}return new Md(!1)},iue=mt,aue=TypeError,wv=function(e,t){if(iue(t,e))return e;throw new aue("Incorrect invocation")},oue=ge,sue=ft,uue=iO,lue=Ve,cue=Vc,fue=Ev,due=wv,hue=jt,pue=Ir,vue=rs,mue=la,gue=mn.f,_ue=ua.forEach,yue=sr,o4=ca,Sue=o4.set,bue=o4.getterFor,Eue=function(e,t,r){var n=e.indexOf("Map")!==-1,i=e.indexOf("Weak")!==-1,a=n?"set":"add",o=sue[e],s=o&&o.prototype,u={},l;if(!yue||!hue(o)||!(i||s.forEach&&!lue(function(){new o().entries().next()})))l=r.getConstructor(t,e,n,a),uue.enable();else{l=t(function(d,h){Sue(due(d,c),{type:e,collection:new o}),vue(h)||fue(h,d[a],{that:d,AS_ENTRIES:n})});var c=l.prototype,f=bue(e);_ue(["add","clear","delete","forEach","get","has","set","keys","values","entries"],function(d){var h=d==="add"||d==="set";d in s&&!(i&&d==="clear")&&cue(c,d,function(p,v){var _=f(this).collection;if(!h&&i&&!pue(p))return d==="get"?void 0:!1;var m=_[d](p===0?0:p,v);return h?this:m})}),i||gue(c,"size",{configurable:!0,get:function(){return f(this).collection.size}})}return mue(l,e,!1,!0),u[e]=l,oue({global:!0,forced:!0},u),i||r.setStrong(l,e,n),l},wue=Ke,y$=eO,Yf=iO.getWeakData,Rue=wv,Tue=_r,kue=rs,Xg=Ir,Oue=Ev,s4=ua,S$=Vt,u4=ca,Pue=u4.set,Iue=u4.getterFor,xue=s4.find,Cue=s4.findIndex,$ue=wue([].splice),Due=0,Qf=function(e){return e.frozen||(e.frozen=new l4)},l4=function(){this.entries=[]},Zg=function(e,t){return xue(e.entries,function(r){return r[0]===t})};l4.prototype={get:function(e){var t=Zg(this,e);if(t)return t[1]},has:function(e){return!!Zg(this,e)},set:function(e,t){var r=Zg(this,e);r?r[1]=t:this.entries.push([e,t])},delete:function(e){var t=Cue(this.entries,function(r){return r[0]===e});return~t&&$ue(this.entries,t,1),!!~t}};var Nue={getConstructor:function(e,t,r,n){var i=e(function(u,l){Rue(u,a),Pue(u,{type:t,id:Due++,frozen:void 0}),kue(l)||Oue(l,u[n],{that:u,AS_ENTRIES:r})}),a=i.prototype,o=Iue(t),s=function(u,l,c){var f=o(u),d=Yf(Tue(l),!0);return d===!0?Qf(f).set(l,c):d[f.id]=c,u};return y$(a,{delete:function(u){var l=o(this);if(!Xg(u))return!1;var c=Yf(u);return c===!0?Qf(l).delete(u):c&&S$(c,l.id)&&delete c[l.id]},has:function(l){var c=o(this);if(!Xg(l))return!1;var f=Yf(l);return f===!0?Qf(c).has(l):f&&S$(f,c.id)}}),y$(a,r?{get:function(l){var c=o(this);if(Xg(l)){var f=Yf(l);return f===!0?Qf(c).get(l):f?f[c.id]:void 0}},set:function(l,c){return s(this,l,c)}}:{add:function(l){return s(this,l,!0)}}),i}},Aue=t4,b$=ft,Fd=Ke,E$=eO,Lue=iO,Mue=Eue,c4=Nue,Kf=Ir,Jf=ca.enforce,Fue=Ve,jue=SH,Zc=Object,que=Array.isArray,Xf=Zc.isExtensible,f4=Zc.isFrozen,Uue=Zc.isSealed,d4=Zc.freeze,Bue=Zc.seal,zue=!b$.ActiveXObject&&"ActiveXObject"in b$,vl,h4=function(e){return function(){return e(this,arguments.length?arguments[0]:void 0)}},p4=Mue("WeakMap",h4,c4),bs=p4.prototype,jd=Fd(bs.set),Hue=function(){return Aue&&Fue(function(){var e=d4([]);return jd(new p4,e,1),!f4(e)})};if(jue)if(zue){vl=c4.getConstructor(h4,"WeakMap",!0),Lue.enable();var w$=Fd(bs.delete),Zf=Fd(bs.has),R$=Fd(bs.get);E$(bs,{delete:function(e){if(Kf(e)&&!Xf(e)){var t=Jf(this);return t.frozen||(t.frozen=new vl),w$(this,e)||t.frozen.delete(e)}return w$(this,e)},has:function(t){if(Kf(t)&&!Xf(t)){var r=Jf(this);return r.frozen||(r.frozen=new vl),Zf(this,t)||r.frozen.has(t)}return Zf(this,t)},get:function(t){if(Kf(t)&&!Xf(t)){var r=Jf(this);return r.frozen||(r.frozen=new vl),Zf(this,t)?R$(this,t):r.frozen.get(t)}return R$(this,t)},set:function(t,r){if(Kf(t)&&!Xf(t)){var n=Jf(this);n.frozen||(n.frozen=new vl),Zf(this,t)?jd(this,t,r):n.frozen.set(t,r)}else jd(this,t,r);return this}})}else Hue()&&E$(bs,{set:function(t,r){var n;return que(t)&&(f4(t)?n=d4:Uue(t)&&(n=Bue)),jd(this,t,r),n&&n(t),this}});var Wue=Gt,Gue=Wue.WeakMap,Vue=Gue,Yue=Vue,Que=Yue,Kue=Que,Jue=Hu,Xue=TypeError,v4=function(e){if(typeof e=="object"&&"has"in e&&"get"in e&&"set"in e)return e;throw new Xue(Jue(e)+" is not a weakmap")},Zue=function(e,t){return t===1?function(r,n){return r[e](n)}:function(r,n,i){return r[e](n,i)}},ele=$n,ed=Zue,Rv={WeakMap:ele("WeakMap"),set:ed("set",2),get:ed("get",1),has:ed("has",1),remove:ed("delete",1)},tle=ge,rle=v4,oO=Rv,nle=oO.get,ile=oO.has,T$=oO.set;tle({target:"WeakMap",proto:!0,real:!0,forced:!0},{emplace:function(t,r){var n=rle(this),i,a;return ile(n,t)?(i=nle(n,t),"update"in r&&(i=r.update(i,t,n),T$(n,t,i)),i):(a=r.insert(t,n),T$(n,t,a),a)}});var ale=uo,ole=_r,sle=en,ule=Ev,lle=function(e,t,r){return function(i){var a=sle(i),o=arguments.length,s=o>1?arguments[1]:void 0,u=s!==void 0,l=u?ale(s,o>2?arguments[2]:void 0):void 0,c=new e,f=0;return ule(a,function(d){var h=u?l(d,f++):d;r?t(c,ole(h)[0],h[1]):t(c,h)}),c}},cle=ge,k$=Rv,fle=lle;cle({target:"WeakMap",stat:!0,forced:!0},{from:fle(k$.WeakMap,k$.set,!0)});var dle=_r,hle=function(e,t,r){return function(){for(var i=new e,a=arguments.length,o=0;o2?arguments[2]:void 0,u;if(!rd(r)&&!rd(s))throw new Sle("At least one callback required");return td(a,n,t)?(u=td(i,n,t),rd(r)&&(u=r(u),td(o,n,t,u))):rd(s)&&(u=s(),td(o,n,t,u)),u},Ele=ge,wle=ble;Ele({target:"WeakMap",proto:!0,real:!0,forced:!0},{upsert:wle});var Rle=Kue,Tle=Rle,kle=Tle,m4={exports:{}},Ole=ge,Ple=Ve,Ile=_i,g4=Zp.f,_4=sr,xle=!_4||Ple(function(){g4(1)});Ole({target:"Object",stat:!0,forced:xle,sham:!_4},{getOwnPropertyDescriptor:function(t,r){return g4(Ile(t),r)}});var Cle=Gt,y4=Cle.Object,$le=m4.exports=function(t,r){return y4.getOwnPropertyDescriptor(t,r)};y4.getOwnPropertyDescriptor.sham&&($le.sham=!0);var Dle=m4.exports,Nle=Dle,Ale=Nle,Lle=Ale,Mle=Lle,Fle=Mle,jle=Fle,qle=jle;(function(e){var t=use.default,r=kle,n=tH,i=qle;function a(s){if(typeof r!="function")return null;var u=new r,l=new r;return(a=function(f){return f?l:u})(s)}function o(s,u){if(!u&&s&&s.__esModule)return s;if(s===null||t(s)!="object"&&typeof s!="function")return{default:s};var l=a(u);if(l&&l.has(s))return l.get(s);var c={__proto__:null},f=n&&i;for(var d in s)if(d!=="default"&&{}.hasOwnProperty.call(s,d)){var h=f?i(s,d):null;h&&(h.get||h.set)?n(c,d,h):c[d]=s[d]}return c.default=s,l&&l.set(s,c),c}e.exports=o,e.exports.__esModule=!0,e.exports.default=e.exports})(fH);var Dn=fH.exports,P$;function S4(){return P$||(P$=1,function(e){var t=xe,r=Dn.default;t(e,"__esModule",{value:!0}),e.CellCacheContextProvider=void 0,e.useCellCacheContext=s;var n=r(I),i=P;const a=(0,n.createContext)(void 0),o=u=>{let{queryCache:l,children:c}=u;return(0,i.jsx)(a.Provider,{value:{queryCache:l},children:c})};e.CellCacheContextProvider=o;function s(){const u=(0,n.useContext)(a);if(!u)throw new Error("useCellCacheContext must be used within a CellCacheContextProvider");return u}}(Fg)),Fg}var t_={},I$={},x$;function Ule(){if(x$)return I$;x$=1;var e=ge,t=is;return e({target:"Array",stat:!0},{isArray:t}),I$}var r_,C$;function Ble(){if(C$)return r_;C$=1,Ule();var e=Gt;return r_=e.Array.isArray,r_}var n_,$$;function zle(){if($$)return n_;$$=1;var e=Ble();return n_=e,n_}var i_,D$;function Hle(){if(D$)return i_;D$=1;var e=zle();return i_=e,i_}var a_,N$;function Wle(){if(N$)return a_;N$=1;var e=Hle();return a_=e,a_}var o_,A$;function Gle(){return A$||(A$=1,o_=Wle()),o_}var s_,L$;function Tv(){return L$||(L$=1,s_=Gle()),s_}var M$={},F$;function Vle(){if(F$)return M$;F$=1;var e=ge,t=ua.every,r=Vu,n=r("every");return e({target:"Array",proto:!0,forced:!n},{every:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),M$}var u_,j$;function Yle(){if(j$)return u_;j$=1,Vle();var e=Rt();return u_=e("Array","every"),u_}var l_,q$;function Qle(){if(q$)return l_;q$=1;var e=mt,t=Yle(),r=Array.prototype;return l_=function(n){var i=n.every;return n===r||e(r,n)&&i===r.every?t:i},l_}var c_,U$;function Kle(){if(U$)return c_;U$=1;var e=Qle();return c_=e,c_}var f_,B$;function Jle(){if(B$)return f_;B$=1;var e=Kle();return f_=e,f_}var d_,z$;function Xle(){if(z$)return d_;z$=1;var e=Jle();return d_=e,d_}var h_,H$;function Zle(){return H$||(H$=1,h_=Xle()),h_}var p_,W$;function b4(){return W$||(W$=1,p_=Zle()),p_}var G$={},v_,V$;function E4(){if(V$)return v_;V$=1;var e=sr,t=Ve,r=Ke,n=Kk,i=Kc,a=_i,o=zc.f,s=r(o),u=r([].push),l=e&&t(function(){var f=Object.create(null);return f[2]=2,!s(f,2)}),c=function(f){return function(d){for(var h=a(d),p=i(h),v=l&&n(h)===null,_=p.length,m=0,g=[],y;_>m;)y=p[m++],(!e||(v?y in h:s(h,y)))&&u(g,f?[y,h[y]]:h[y]);return g}};return v_={entries:c(!0),values:c(!1)},v_}var Y$;function ece(){if(Y$)return G$;Y$=1;var e=ge,t=E4().values;return e({target:"Object",stat:!0},{values:function(n){return t(n)}}),G$}var m_,Q$;function tce(){if(Q$)return m_;Q$=1,ece();var e=Gt;return m_=e.Object.values,m_}var g_,K$;function rce(){if(K$)return g_;K$=1;var e=tce();return g_=e,g_}var __,J$;function nce(){if(J$)return __;J$=1;var e=rce();return __=e,__}var y_,X$;function ice(){if(X$)return y_;X$=1;var e=nce();return y_=e,y_}var S_,Z$;function ace(){return Z$||(Z$=1,S_=ice()),S_}var b_,eD;function kv(){return eD||(eD=1,b_=ace()),b_}var tD={},E_,rD;function oce(){if(rD)return E_;rD=1;var e=lo,t=yr,r=ei,n=RangeError;return E_=function(a){var o=t(r(this)),s="",u=e(a);if(u<0||u===1/0)throw new n("Wrong number of repetitions");for(;u>0;(u>>>=1)&&(o+=o))u&1&&(s+=o);return s},E_}var w_,nD;function sce(){if(nD)return w_;nD=1;var e=Ke,t=Yc,r=yr,n=oce(),i=ei,a=e(n),o=e("".slice),s=Math.ceil,u=function(l){return function(c,f,d){var h=r(i(c)),p=t(f),v=h.length,_=d===void 0?" ":r(d),m,g;return p<=v||_===""?h:(m=p-v,g=a(_,s(m/_.length)),g.length>m&&(g=o(g,0,m)),l?h+g:g+h)}};return w_={start:u(!1),end:u(!0)},w_}var R_,iD;function uce(){if(iD)return R_;iD=1;var e=Ke,t=Ve,r=sce().start,n=RangeError,i=isFinite,a=Math.abs,o=Date.prototype,s=o.toISOString,u=e(o.getTime),l=e(o.getUTCDate),c=e(o.getUTCFullYear),f=e(o.getUTCHours),d=e(o.getUTCMilliseconds),h=e(o.getUTCMinutes),p=e(o.getUTCMonth),v=e(o.getUTCSeconds);return R_=t(function(){return s.call(new Date(-5e13-1))!=="0385-07-25T07:06:39.999Z"})||!t(function(){s.call(new Date(NaN))})?function(){if(!i(u(this)))throw new n("Invalid time value");var m=this,g=c(m),y=d(m),S=g<0?"-":g>9999?"+":"";return S+r(a(g),S?6:4,0)+"-"+r(p(m)+1,2,0)+"-"+r(l(m),2,0)+"T"+r(f(m),2,0)+":"+r(h(m),2,0)+":"+r(v(m),2,0)+"."+r(y,3,0)+"Z"}:s,R_}var aD;function lce(){if(aD)return tD;aD=1;var e=ge,t=ur,r=en,n=Kz,i=uce(),a=Cn,o=Ve,s=o(function(){return new Date(NaN).toJSON()!==null||t(Date.prototype.toJSON,{toISOString:function(){return 1}})!==1});return e({target:"Date",proto:!0,forced:s},{toJSON:function(l){var c=r(this),f=n(c,"number");return typeof f=="number"&&!isFinite(f)?null:!("toISOString"in c)&&a(c)==="Date"?t(i,c):c.toISOString()}}),tD}var T_,oD;function cce(){if(oD)return T_;oD=1,lce(),jH();var e=Gt,t=Xp;return e.JSON||(e.JSON={stringify:JSON.stringify}),T_=function(n,i,a){return t(e.JSON.stringify,null,arguments)},T_}var k_,sD;function fce(){if(sD)return k_;sD=1;var e=cce();return k_=e,k_}var O_,uD;function dce(){if(uD)return O_;uD=1;var e=fce();return O_=e,O_}var P_,lD;function hce(){if(lD)return P_;lD=1;var e=dce();return P_=e,P_}var I_,cD;function pce(){return cD||(cD=1,I_=hce()),I_}var x_,fD;function vce(){return fD||(fD=1,x_=pce()),x_}var sO={},dD={},hD;function mce(){if(hD)return dD;hD=1;var e=ge,t=ua.map,r=uv,n=r("map");return e({target:"Array",proto:!0,forced:!n},{map:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),dD}var C_,pD;function gce(){if(pD)return C_;pD=1,mce();var e=Rt();return C_=e("Array","map"),C_}var $_,vD;function _ce(){if(vD)return $_;vD=1;var e=mt,t=gce(),r=Array.prototype;return $_=function(n){var i=n.map;return n===r||e(r,n)&&i===r.map?t:i},$_}var D_,mD;function yce(){if(mD)return D_;mD=1;var e=_ce();return D_=e,D_}var N_,gD;function Sce(){if(gD)return N_;gD=1;var e=yce();return N_=e,N_}var A_,_D;function bce(){if(_D)return A_;_D=1;var e=Sce();return A_=e,A_}var L_,yD;function Ece(){return yD||(yD=1,L_=bce()),L_}var M_,SD;function Ov(){return SD||(SD=1,M_=Ece()),M_}var F_,bD;function wce(){if(bD)return F_;bD=1;var e=Rt();return F_=e("Array","concat"),F_}var j_,ED;function Rce(){if(ED)return j_;ED=1;var e=mt,t=wce(),r=Array.prototype;return j_=function(n){var i=n.concat;return n===r||e(r,n)&&i===r.concat?t:i},j_}var q_,wD;function Tce(){if(wD)return q_;wD=1;var e=Rce();return q_=e,q_}var U_,RD;function kce(){if(RD)return U_;RD=1;var e=Tce();return U_=e,U_}var B_,TD;function Oce(){if(TD)return B_;TD=1;var e=kce();return B_=e,B_}var z_,kD;function Pce(){return kD||(kD=1,z_=Oce()),z_}var H_,OD;function Ice(){return OD||(OD=1,H_=Pce()),H_}var bR=function(e,t){return bR=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(r,n){r.__proto__=n}||function(r,n){for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(r[i]=n[i])},bR(e,t)};function Si(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");bR(e,t);function r(){this.constructor=e}e.prototype=t===null?Object.create(t):(r.prototype=t.prototype,new r)}var x=function(){return x=Object.assign||function(t){for(var r,n=1,i=arguments.length;n0&&a[a.length-1])&&(l[0]===6||l[0]===2)){r=0;continue}if(l[0]===3&&(!a||l[1]>a[0]&&l[1]=ER){var t=console[e]||console.log;return t.apply(console,arguments)}}}(function(e){e.debug=nd("debug"),e.log=nd("log"),e.warn=nd("warn"),e.error=nd("error")})(ko||(ko={}));function Cce(e){var t=Yh[ER];return ER=Math.max(0,Yh.indexOf(e)),t}var uO="3.9.9";function Rn(e){try{return e()}catch{}}const wR=Rn(function(){return globalThis})||Rn(function(){return window})||Rn(function(){return self})||Rn(function(){return global})||Rn(function(){return Rn.constructor("return this")()});var ID=new Map;function Qh(e){var t=ID.get(e)||1;return ID.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}function lO(e,t){t===void 0&&(t=0);var r=Qh("stringifyForDisplay");return JSON.stringify(e,function(n,i){return i===void 0?r:i},t).split(JSON.stringify(r)).join("")}function id(e){return function(t){for(var r=[],n=1;n=t)break;r=i.index+i[0].length,n+=1}return{line:n,column:t+1-r}}function Lce(e){return T4(e.source,RR(e.source,e.start))}function T4(e,t){const r=e.locationOffset.column-1,n="".padStart(r)+e.body,i=t.line-1,a=e.locationOffset.line-1,o=t.line+a,s=t.line===1?r:0,u=t.column+s,l=`${e.name}:${o}:${u} `,c=n.split(/\r\n|[\n\r]/g),f=c[i];if(f.length>120){const d=Math.floor(u/80),h=u%80,p=[];for(let v=0;v["|",v]),["|","^".padStart(h)],["|",p[d+1]]])}return l+CD([[`${o-1} |`,c[i-1]],[`${o} |`,f],["|","^".padStart(u)],[`${o+1} |`,c[i+1]]])}function CD(e){const t=e.filter(([n,i])=>i!==void 0),r=Math.max(...t.map(([n])=>n.length));return t.map(([n,i])=>n.padStart(r)+(i?" "+i:"")).join(` `)}function Mce(e){const t=e[0];return t==null||"kind"in t||"length"in t?{nodes:t,source:e[1],positions:e[2],path:e[3],originalError:e[4],extensions:e[5]}:t}class dO extends Error{constructor(t,...r){var n,i,a;const{nodes:o,source:s,positions:u,path:l,originalError:c,extensions:f}=Mce(r);super(t),this.name="GraphQLError",this.path=l??void 0,this.originalError=c??void 0,this.nodes=$D(Array.isArray(o)?o:o?[o]:void 0);const d=$D((n=this.nodes)===null||n===void 0?void 0:n.map(p=>p.loc).filter(p=>p!=null));this.source=s??(d==null||(i=d[0])===null||i===void 0?void 0:i.source),this.positions=u??(d==null?void 0:d.map(p=>p.start)),this.locations=u&&s?u.map(p=>RR(s,p)):d==null?void 0:d.map(p=>RR(p.source,p.start));const h=Dce(c==null?void 0:c.extensions)?c==null?void 0:c.extensions:void 0;this.extensions=(a=f??h)!==null&&a!==void 0?a:Object.create(null),Object.defineProperties(this,{message:{writable:!0,enumerable:!0},name:{enumerable:!1},nodes:{enumerable:!1},source:{enumerable:!1},positions:{enumerable:!1},originalError:{enumerable:!1}}),c!=null&&c.stack?Object.defineProperty(this,"stack",{value:c.stack,writable:!0,configurable:!0}):Error.captureStackTrace?Error.captureStackTrace(this,dO):Object.defineProperty(this,"stack",{value:Error().stack,writable:!0,configurable:!0})}get[Symbol.toStringTag](){return"GraphQLError"}toString(){let t=this.message;if(this.nodes)for(const r of this.nodes)r.loc&&(t+=` `+Lce(r.loc));else if(this.source&&this.locations)for(const r of this.locations)t+=` `+T4(this.source,r);return t}toJSON(){const t={message:this.message};return this.locations!=null&&(t.locations=this.locations),this.path!=null&&(t.path=this.path),this.extensions!=null&&Object.keys(this.extensions).length>0&&(t.extensions=this.extensions),t}}function $D(e){return e===void 0||e.length===0?void 0:e}function er(e,t,r){return new dO(`Syntax Error: ${r}`,{source:e,positions:[t]})}class Fce{constructor(t,r,n){this.start=t.start,this.end=r.end,this.startToken=t,this.endToken=r,this.source=n}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}}class k4{constructor(t,r,n,i,a,o){this.kind=t,this.start=r,this.end=n,this.line=i,this.column=a,this.value=o,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}const O4={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},jce=new Set(Object.keys(O4));function DD(e){const t=e==null?void 0:e.kind;return typeof t=="string"&&jce.has(t)}var zs;(function(e){e.QUERY="query",e.MUTATION="mutation",e.SUBSCRIPTION="subscription"})(zs||(zs={}));var TR;(function(e){e.QUERY="QUERY",e.MUTATION="MUTATION",e.SUBSCRIPTION="SUBSCRIPTION",e.FIELD="FIELD",e.FRAGMENT_DEFINITION="FRAGMENT_DEFINITION",e.FRAGMENT_SPREAD="FRAGMENT_SPREAD",e.INLINE_FRAGMENT="INLINE_FRAGMENT",e.VARIABLE_DEFINITION="VARIABLE_DEFINITION",e.SCHEMA="SCHEMA",e.SCALAR="SCALAR",e.OBJECT="OBJECT",e.FIELD_DEFINITION="FIELD_DEFINITION",e.ARGUMENT_DEFINITION="ARGUMENT_DEFINITION",e.INTERFACE="INTERFACE",e.UNION="UNION",e.ENUM="ENUM",e.ENUM_VALUE="ENUM_VALUE",e.INPUT_OBJECT="INPUT_OBJECT",e.INPUT_FIELD_DEFINITION="INPUT_FIELD_DEFINITION"})(TR||(TR={}));var de;(function(e){e.NAME="Name",e.DOCUMENT="Document",e.OPERATION_DEFINITION="OperationDefinition",e.VARIABLE_DEFINITION="VariableDefinition",e.SELECTION_SET="SelectionSet",e.FIELD="Field",e.ARGUMENT="Argument",e.FRAGMENT_SPREAD="FragmentSpread",e.INLINE_FRAGMENT="InlineFragment",e.FRAGMENT_DEFINITION="FragmentDefinition",e.VARIABLE="Variable",e.INT="IntValue",e.FLOAT="FloatValue",e.STRING="StringValue",e.BOOLEAN="BooleanValue",e.NULL="NullValue",e.ENUM="EnumValue",e.LIST="ListValue",e.OBJECT="ObjectValue",e.OBJECT_FIELD="ObjectField",e.DIRECTIVE="Directive",e.NAMED_TYPE="NamedType",e.LIST_TYPE="ListType",e.NON_NULL_TYPE="NonNullType",e.SCHEMA_DEFINITION="SchemaDefinition",e.OPERATION_TYPE_DEFINITION="OperationTypeDefinition",e.SCALAR_TYPE_DEFINITION="ScalarTypeDefinition",e.OBJECT_TYPE_DEFINITION="ObjectTypeDefinition",e.FIELD_DEFINITION="FieldDefinition",e.INPUT_VALUE_DEFINITION="InputValueDefinition",e.INTERFACE_TYPE_DEFINITION="InterfaceTypeDefinition",e.UNION_TYPE_DEFINITION="UnionTypeDefinition",e.ENUM_TYPE_DEFINITION="EnumTypeDefinition",e.ENUM_VALUE_DEFINITION="EnumValueDefinition",e.INPUT_OBJECT_TYPE_DEFINITION="InputObjectTypeDefinition",e.DIRECTIVE_DEFINITION="DirectiveDefinition",e.SCHEMA_EXTENSION="SchemaExtension",e.SCALAR_TYPE_EXTENSION="ScalarTypeExtension",e.OBJECT_TYPE_EXTENSION="ObjectTypeExtension",e.INTERFACE_TYPE_EXTENSION="InterfaceTypeExtension",e.UNION_TYPE_EXTENSION="UnionTypeExtension",e.ENUM_TYPE_EXTENSION="EnumTypeExtension",e.INPUT_OBJECT_TYPE_EXTENSION="InputObjectTypeExtension"})(de||(de={}));function kR(e){return e===9||e===32}function Oc(e){return e>=48&&e<=57}function P4(e){return e>=97&&e<=122||e>=65&&e<=90}function I4(e){return P4(e)||e===95}function qce(e){return P4(e)||Oc(e)||e===95}function Uce(e){var t;let r=Number.MAX_SAFE_INTEGER,n=null,i=-1;for(let o=0;os===0?o:o.slice(r)).slice((t=n)!==null&&t!==void 0?t:0,i+1)}function Bce(e){let t=0;for(;t1&&n.slice(1).every(h=>h.length===0||kR(h.charCodeAt(0))),o=r.endsWith('\\"""'),s=e.endsWith('"')&&!o,u=e.endsWith("\\"),l=s||u,c=!(t!=null&&t.minimize)&&(!i||e.length>70||l||a||o);let f="";const d=i&&kR(e.charCodeAt(0));return(c&&!d||a)&&(f+=` `),f+=r,(c||l)&&(f+=` `),'"""'+f+'"""'}var H;(function(e){e.SOF="",e.EOF="",e.BANG="!",e.DOLLAR="$",e.AMP="&",e.PAREN_L="(",e.PAREN_R=")",e.SPREAD="...",e.COLON=":",e.EQUALS="=",e.AT="@",e.BRACKET_L="[",e.BRACKET_R="]",e.BRACE_L="{",e.PIPE="|",e.BRACE_R="}",e.NAME="Name",e.INT="Int",e.FLOAT="Float",e.STRING="String",e.BLOCK_STRING="BlockString",e.COMMENT="Comment"})(H||(H={}));class Hce{constructor(t){const r=new k4(H.SOF,0,0,0,0);this.source=t,this.lastToken=r,this.token=r,this.line=1,this.lineStart=0}get[Symbol.toStringTag](){return"Lexer"}advance(){return this.lastToken=this.token,this.token=this.lookahead()}lookahead(){let t=this.token;if(t.kind!==H.EOF)do if(t.next)t=t.next;else{const r=Gce(this,t.end);t.next=r,r.prev=t,t=r}while(t.kind===H.COMMENT);return t}}function Wce(e){return e===H.BANG||e===H.DOLLAR||e===H.AMP||e===H.PAREN_L||e===H.PAREN_R||e===H.SPREAD||e===H.COLON||e===H.EQUALS||e===H.AT||e===H.BRACKET_L||e===H.BRACKET_R||e===H.BRACE_L||e===H.PIPE||e===H.BRACE_R}function Ku(e){return e>=0&&e<=55295||e>=57344&&e<=1114111}function Pv(e,t){return x4(e.charCodeAt(t))&&C4(e.charCodeAt(t+1))}function x4(e){return e>=55296&&e<=56319}function C4(e){return e>=56320&&e<=57343}function Qo(e,t){const r=e.source.body.codePointAt(t);if(r===void 0)return H.EOF;if(r>=32&&r<=126){const n=String.fromCodePoint(r);return n==='"'?`'"'`:`"${n}"`}return"U+"+r.toString(16).toUpperCase().padStart(4,"0")}function Lt(e,t,r,n,i){const a=e.line,o=1+r-e.lineStart;return new k4(t,r,n,a,o,i)}function Gce(e,t){const r=e.source.body,n=r.length;let i=t;for(;i=48&&e<=57?e-48:e>=65&&e<=70?e-55:e>=97&&e<=102?e-87:-1}function Xce(e,t){const r=e.source.body;switch(r.charCodeAt(t+1)){case 34:return{value:'"',size:2};case 92:return{value:"\\",size:2};case 47:return{value:"/",size:2};case 98:return{value:"\b",size:2};case 102:return{value:"\f",size:2};case 110:return{value:` `,size:2};case 114:return{value:"\r",size:2};case 116:return{value:" ",size:2}}throw er(e.source,t,`Invalid character escape sequence: "${r.slice(t,t+2)}".`)}function Zce(e,t){const r=e.source.body,n=r.length;let i=e.lineStart,a=t+3,o=a,s="";const u=[];for(;a$4?"["+ofe(e)+"]":"{ "+r.map(([i,a])=>i+": "+Iv(a,t)).join(", ")+" }"}function afe(e,t){if(e.length===0)return"[]";if(t.length>$4)return"[Array]";const r=Math.min(tfe,e.length),n=e.length-r,i=[];for(let a=0;a1&&i.push(`... ${n} more items`),"["+i.join(", ")+"]"}function ofe(e){const t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor=="function"){const r=e.constructor.name;if(typeof r=="string"&&r!=="")return r}return t}const sfe=globalThis.process?function(t,r){return t instanceof r}:function(t,r){if(t instanceof r)return!0;if(typeof t=="object"&&t!==null){var n;const i=r.prototype[Symbol.toStringTag],a=Symbol.toStringTag in t?t[Symbol.toStringTag]:(n=t.constructor)===null||n===void 0?void 0:n.name;if(i===a){const o=hO(t);throw new Error(`Cannot use ${i} "${o}" from another module or realm. Ensure that there is only one instance of "graphql" in the node_modules directory. If different versions of "graphql" are the dependencies of other relied on modules, use "resolutions" to ensure only one version is installed. https://yarnpkg.com/en/docs/selective-version-resolutions Duplicate "graphql" modules cannot be used at the same time since different versions may have different capabilities and behavior. The data from one version used in the function from another could produce confusing and spurious results.`)}}return!1};class D4{constructor(t,r="GraphQL request",n={line:1,column:1}){typeof t=="string"||qd(!1,`Body must be a string. Received: ${hO(t)}.`),this.body=t,this.name=r,this.locationOffset=n,this.locationOffset.line>0||qd(!1,"line in locationOffset is 1-indexed and must be positive."),this.locationOffset.column>0||qd(!1,"column in locationOffset is 1-indexed and must be positive.")}get[Symbol.toStringTag](){return"Source"}}function ufe(e){return sfe(e,D4)}function lfe(e,t){return new cfe(e,t).parseDocument()}class cfe{constructor(t,r={}){const n=ufe(t)?t:new D4(t);this._lexer=new Hce(n),this._options=r,this._tokenCounter=0}parseName(){const t=this.expectToken(H.NAME);return this.node(t,{kind:de.NAME,value:t.value})}parseDocument(){return this.node(this._lexer.token,{kind:de.DOCUMENT,definitions:this.many(H.SOF,this.parseDefinition,H.EOF)})}parseDefinition(){if(this.peek(H.BRACE_L))return this.parseOperationDefinition();const t=this.peekDescription(),r=t?this._lexer.lookahead():this._lexer.token;if(r.kind===H.NAME){switch(r.value){case"schema":return this.parseSchemaDefinition();case"scalar":return this.parseScalarTypeDefinition();case"type":return this.parseObjectTypeDefinition();case"interface":return this.parseInterfaceTypeDefinition();case"union":return this.parseUnionTypeDefinition();case"enum":return this.parseEnumTypeDefinition();case"input":return this.parseInputObjectTypeDefinition();case"directive":return this.parseDirectiveDefinition()}if(t)throw er(this._lexer.source,this._lexer.token.start,"Unexpected description, descriptions are supported only on type definitions.");switch(r.value){case"query":case"mutation":case"subscription":return this.parseOperationDefinition();case"fragment":return this.parseFragmentDefinition();case"extend":return this.parseTypeSystemExtension()}}throw this.unexpected(r)}parseOperationDefinition(){const t=this._lexer.token;if(this.peek(H.BRACE_L))return this.node(t,{kind:de.OPERATION_DEFINITION,operation:zs.QUERY,name:void 0,variableDefinitions:[],directives:[],selectionSet:this.parseSelectionSet()});const r=this.parseOperationType();let n;return this.peek(H.NAME)&&(n=this.parseName()),this.node(t,{kind:de.OPERATION_DEFINITION,operation:r,name:n,variableDefinitions:this.parseVariableDefinitions(),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseOperationType(){const t=this.expectToken(H.NAME);switch(t.value){case"query":return zs.QUERY;case"mutation":return zs.MUTATION;case"subscription":return zs.SUBSCRIPTION}throw this.unexpected(t)}parseVariableDefinitions(){return this.optionalMany(H.PAREN_L,this.parseVariableDefinition,H.PAREN_R)}parseVariableDefinition(){return this.node(this._lexer.token,{kind:de.VARIABLE_DEFINITION,variable:this.parseVariable(),type:(this.expectToken(H.COLON),this.parseTypeReference()),defaultValue:this.expectOptionalToken(H.EQUALS)?this.parseConstValueLiteral():void 0,directives:this.parseConstDirectives()})}parseVariable(){const t=this._lexer.token;return this.expectToken(H.DOLLAR),this.node(t,{kind:de.VARIABLE,name:this.parseName()})}parseSelectionSet(){return this.node(this._lexer.token,{kind:de.SELECTION_SET,selections:this.many(H.BRACE_L,this.parseSelection,H.BRACE_R)})}parseSelection(){return this.peek(H.SPREAD)?this.parseFragment():this.parseField()}parseField(){const t=this._lexer.token,r=this.parseName();let n,i;return this.expectOptionalToken(H.COLON)?(n=r,i=this.parseName()):i=r,this.node(t,{kind:de.FIELD,alias:n,name:i,arguments:this.parseArguments(!1),directives:this.parseDirectives(!1),selectionSet:this.peek(H.BRACE_L)?this.parseSelectionSet():void 0})}parseArguments(t){const r=t?this.parseConstArgument:this.parseArgument;return this.optionalMany(H.PAREN_L,r,H.PAREN_R)}parseArgument(t=!1){const r=this._lexer.token,n=this.parseName();return this.expectToken(H.COLON),this.node(r,{kind:de.ARGUMENT,name:n,value:this.parseValueLiteral(t)})}parseConstArgument(){return this.parseArgument(!0)}parseFragment(){const t=this._lexer.token;this.expectToken(H.SPREAD);const r=this.expectOptionalKeyword("on");return!r&&this.peek(H.NAME)?this.node(t,{kind:de.FRAGMENT_SPREAD,name:this.parseFragmentName(),directives:this.parseDirectives(!1)}):this.node(t,{kind:de.INLINE_FRAGMENT,typeCondition:r?this.parseNamedType():void 0,directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentDefinition(){const t=this._lexer.token;return this.expectKeyword("fragment"),this._options.allowLegacyFragmentVariables===!0?this.node(t,{kind:de.FRAGMENT_DEFINITION,name:this.parseFragmentName(),variableDefinitions:this.parseVariableDefinitions(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()}):this.node(t,{kind:de.FRAGMENT_DEFINITION,name:this.parseFragmentName(),typeCondition:(this.expectKeyword("on"),this.parseNamedType()),directives:this.parseDirectives(!1),selectionSet:this.parseSelectionSet()})}parseFragmentName(){if(this._lexer.token.value==="on")throw this.unexpected();return this.parseName()}parseValueLiteral(t){const r=this._lexer.token;switch(r.kind){case H.BRACKET_L:return this.parseList(t);case H.BRACE_L:return this.parseObject(t);case H.INT:return this.advanceLexer(),this.node(r,{kind:de.INT,value:r.value});case H.FLOAT:return this.advanceLexer(),this.node(r,{kind:de.FLOAT,value:r.value});case H.STRING:case H.BLOCK_STRING:return this.parseStringLiteral();case H.NAME:switch(this.advanceLexer(),r.value){case"true":return this.node(r,{kind:de.BOOLEAN,value:!0});case"false":return this.node(r,{kind:de.BOOLEAN,value:!1});case"null":return this.node(r,{kind:de.NULL});default:return this.node(r,{kind:de.ENUM,value:r.value})}case H.DOLLAR:if(t)if(this.expectToken(H.DOLLAR),this._lexer.token.kind===H.NAME){const n=this._lexer.token.value;throw er(this._lexer.source,r.start,`Unexpected variable "$${n}" in constant value.`)}else throw this.unexpected(r);return this.parseVariable();default:throw this.unexpected()}}parseConstValueLiteral(){return this.parseValueLiteral(!0)}parseStringLiteral(){const t=this._lexer.token;return this.advanceLexer(),this.node(t,{kind:de.STRING,value:t.value,block:t.kind===H.BLOCK_STRING})}parseList(t){const r=()=>this.parseValueLiteral(t);return this.node(this._lexer.token,{kind:de.LIST,values:this.any(H.BRACKET_L,r,H.BRACKET_R)})}parseObject(t){const r=()=>this.parseObjectField(t);return this.node(this._lexer.token,{kind:de.OBJECT,fields:this.any(H.BRACE_L,r,H.BRACE_R)})}parseObjectField(t){const r=this._lexer.token,n=this.parseName();return this.expectToken(H.COLON),this.node(r,{kind:de.OBJECT_FIELD,name:n,value:this.parseValueLiteral(t)})}parseDirectives(t){const r=[];for(;this.peek(H.AT);)r.push(this.parseDirective(t));return r}parseConstDirectives(){return this.parseDirectives(!0)}parseDirective(t){const r=this._lexer.token;return this.expectToken(H.AT),this.node(r,{kind:de.DIRECTIVE,name:this.parseName(),arguments:this.parseArguments(t)})}parseTypeReference(){const t=this._lexer.token;let r;if(this.expectOptionalToken(H.BRACKET_L)){const n=this.parseTypeReference();this.expectToken(H.BRACKET_R),r=this.node(t,{kind:de.LIST_TYPE,type:n})}else r=this.parseNamedType();return this.expectOptionalToken(H.BANG)?this.node(t,{kind:de.NON_NULL_TYPE,type:r}):r}parseNamedType(){return this.node(this._lexer.token,{kind:de.NAMED_TYPE,name:this.parseName()})}peekDescription(){return this.peek(H.STRING)||this.peek(H.BLOCK_STRING)}parseDescription(){if(this.peekDescription())return this.parseStringLiteral()}parseSchemaDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("schema");const n=this.parseConstDirectives(),i=this.many(H.BRACE_L,this.parseOperationTypeDefinition,H.BRACE_R);return this.node(t,{kind:de.SCHEMA_DEFINITION,description:r,directives:n,operationTypes:i})}parseOperationTypeDefinition(){const t=this._lexer.token,r=this.parseOperationType();this.expectToken(H.COLON);const n=this.parseNamedType();return this.node(t,{kind:de.OPERATION_TYPE_DEFINITION,operation:r,type:n})}parseScalarTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("scalar");const n=this.parseName(),i=this.parseConstDirectives();return this.node(t,{kind:de.SCALAR_TYPE_DEFINITION,description:r,name:n,directives:i})}parseObjectTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("type");const n=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:de.OBJECT_TYPE_DEFINITION,description:r,name:n,interfaces:i,directives:a,fields:o})}parseImplementsInterfaces(){return this.expectOptionalKeyword("implements")?this.delimitedMany(H.AMP,this.parseNamedType):[]}parseFieldsDefinition(){return this.optionalMany(H.BRACE_L,this.parseFieldDefinition,H.BRACE_R)}parseFieldDefinition(){const t=this._lexer.token,r=this.parseDescription(),n=this.parseName(),i=this.parseArgumentDefs();this.expectToken(H.COLON);const a=this.parseTypeReference(),o=this.parseConstDirectives();return this.node(t,{kind:de.FIELD_DEFINITION,description:r,name:n,arguments:i,type:a,directives:o})}parseArgumentDefs(){return this.optionalMany(H.PAREN_L,this.parseInputValueDef,H.PAREN_R)}parseInputValueDef(){const t=this._lexer.token,r=this.parseDescription(),n=this.parseName();this.expectToken(H.COLON);const i=this.parseTypeReference();let a;this.expectOptionalToken(H.EQUALS)&&(a=this.parseConstValueLiteral());const o=this.parseConstDirectives();return this.node(t,{kind:de.INPUT_VALUE_DEFINITION,description:r,name:n,type:i,defaultValue:a,directives:o})}parseInterfaceTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("interface");const n=this.parseName(),i=this.parseImplementsInterfaces(),a=this.parseConstDirectives(),o=this.parseFieldsDefinition();return this.node(t,{kind:de.INTERFACE_TYPE_DEFINITION,description:r,name:n,interfaces:i,directives:a,fields:o})}parseUnionTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("union");const n=this.parseName(),i=this.parseConstDirectives(),a=this.parseUnionMemberTypes();return this.node(t,{kind:de.UNION_TYPE_DEFINITION,description:r,name:n,directives:i,types:a})}parseUnionMemberTypes(){return this.expectOptionalToken(H.EQUALS)?this.delimitedMany(H.PIPE,this.parseNamedType):[]}parseEnumTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("enum");const n=this.parseName(),i=this.parseConstDirectives(),a=this.parseEnumValuesDefinition();return this.node(t,{kind:de.ENUM_TYPE_DEFINITION,description:r,name:n,directives:i,values:a})}parseEnumValuesDefinition(){return this.optionalMany(H.BRACE_L,this.parseEnumValueDefinition,H.BRACE_R)}parseEnumValueDefinition(){const t=this._lexer.token,r=this.parseDescription(),n=this.parseEnumValueName(),i=this.parseConstDirectives();return this.node(t,{kind:de.ENUM_VALUE_DEFINITION,description:r,name:n,directives:i})}parseEnumValueName(){if(this._lexer.token.value==="true"||this._lexer.token.value==="false"||this._lexer.token.value==="null")throw er(this._lexer.source,this._lexer.token.start,`${ad(this._lexer.token)} is reserved and cannot be used for an enum value.`);return this.parseName()}parseInputObjectTypeDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("input");const n=this.parseName(),i=this.parseConstDirectives(),a=this.parseInputFieldsDefinition();return this.node(t,{kind:de.INPUT_OBJECT_TYPE_DEFINITION,description:r,name:n,directives:i,fields:a})}parseInputFieldsDefinition(){return this.optionalMany(H.BRACE_L,this.parseInputValueDef,H.BRACE_R)}parseTypeSystemExtension(){const t=this._lexer.lookahead();if(t.kind===H.NAME)switch(t.value){case"schema":return this.parseSchemaExtension();case"scalar":return this.parseScalarTypeExtension();case"type":return this.parseObjectTypeExtension();case"interface":return this.parseInterfaceTypeExtension();case"union":return this.parseUnionTypeExtension();case"enum":return this.parseEnumTypeExtension();case"input":return this.parseInputObjectTypeExtension()}throw this.unexpected(t)}parseSchemaExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("schema");const r=this.parseConstDirectives(),n=this.optionalMany(H.BRACE_L,this.parseOperationTypeDefinition,H.BRACE_R);if(r.length===0&&n.length===0)throw this.unexpected();return this.node(t,{kind:de.SCHEMA_EXTENSION,directives:r,operationTypes:n})}parseScalarTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("scalar");const r=this.parseName(),n=this.parseConstDirectives();if(n.length===0)throw this.unexpected();return this.node(t,{kind:de.SCALAR_TYPE_EXTENSION,name:r,directives:n})}parseObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("type");const r=this.parseName(),n=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:de.OBJECT_TYPE_EXTENSION,name:r,interfaces:n,directives:i,fields:a})}parseInterfaceTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("interface");const r=this.parseName(),n=this.parseImplementsInterfaces(),i=this.parseConstDirectives(),a=this.parseFieldsDefinition();if(n.length===0&&i.length===0&&a.length===0)throw this.unexpected();return this.node(t,{kind:de.INTERFACE_TYPE_EXTENSION,name:r,interfaces:n,directives:i,fields:a})}parseUnionTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("union");const r=this.parseName(),n=this.parseConstDirectives(),i=this.parseUnionMemberTypes();if(n.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:de.UNION_TYPE_EXTENSION,name:r,directives:n,types:i})}parseEnumTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("enum");const r=this.parseName(),n=this.parseConstDirectives(),i=this.parseEnumValuesDefinition();if(n.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:de.ENUM_TYPE_EXTENSION,name:r,directives:n,values:i})}parseInputObjectTypeExtension(){const t=this._lexer.token;this.expectKeyword("extend"),this.expectKeyword("input");const r=this.parseName(),n=this.parseConstDirectives(),i=this.parseInputFieldsDefinition();if(n.length===0&&i.length===0)throw this.unexpected();return this.node(t,{kind:de.INPUT_OBJECT_TYPE_EXTENSION,name:r,directives:n,fields:i})}parseDirectiveDefinition(){const t=this._lexer.token,r=this.parseDescription();this.expectKeyword("directive"),this.expectToken(H.AT);const n=this.parseName(),i=this.parseArgumentDefs(),a=this.expectOptionalKeyword("repeatable");this.expectKeyword("on");const o=this.parseDirectiveLocations();return this.node(t,{kind:de.DIRECTIVE_DEFINITION,description:r,name:n,arguments:i,repeatable:a,locations:o})}parseDirectiveLocations(){return this.delimitedMany(H.PIPE,this.parseDirectiveLocation)}parseDirectiveLocation(){const t=this._lexer.token,r=this.parseName();if(Object.prototype.hasOwnProperty.call(TR,r.value))return r;throw this.unexpected(t)}node(t,r){return this._options.noLocation!==!0&&(r.loc=new Fce(t,this._lexer.lastToken,this._lexer.source)),r}peek(t){return this._lexer.token.kind===t}expectToken(t){const r=this._lexer.token;if(r.kind===t)return this.advanceLexer(),r;throw er(this._lexer.source,r.start,`Expected ${N4(t)}, found ${ad(r)}.`)}expectOptionalToken(t){return this._lexer.token.kind===t?(this.advanceLexer(),!0):!1}expectKeyword(t){const r=this._lexer.token;if(r.kind===H.NAME&&r.value===t)this.advanceLexer();else throw er(this._lexer.source,r.start,`Expected "${t}", found ${ad(r)}.`)}expectOptionalKeyword(t){const r=this._lexer.token;return r.kind===H.NAME&&r.value===t?(this.advanceLexer(),!0):!1}unexpected(t){const r=t??this._lexer.token;return er(this._lexer.source,r.start,`Unexpected ${ad(r)}.`)}any(t,r,n){this.expectToken(t);const i=[];for(;!this.expectOptionalToken(n);)i.push(r.call(this));return i}optionalMany(t,r,n){if(this.expectOptionalToken(t)){const i=[];do i.push(r.call(this));while(!this.expectOptionalToken(n));return i}return[]}many(t,r,n){this.expectToken(t);const i=[];do i.push(r.call(this));while(!this.expectOptionalToken(n));return i}delimitedMany(t,r){this.expectOptionalToken(t);const n=[];do n.push(r.call(this));while(this.expectOptionalToken(t));return n}advanceLexer(){const{maxTokens:t}=this._options,r=this._lexer.advance();if(t!==void 0&&r.kind!==H.EOF&&(++this._tokenCounter,this._tokenCounter>t))throw er(this._lexer.source,r.start,`Document contains more that ${t} tokens. Parsing aborted.`)}}function ad(e){const t=e.value;return N4(e.kind)+(t!=null?` "${t}"`:"")}function N4(e){return Wce(e)?`"${e}"`:e}function ffe(e){return`"${e.replace(dfe,hfe)}"`}const dfe=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function hfe(e){return pfe[e.charCodeAt(0)]}const pfe=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],pO=Object.freeze({});function hn(e,t,r=O4){const n=new Map;for(const m of Object.values(de))n.set(m,vfe(t,m));let i,a=Array.isArray(e),o=[e],s=-1,u=[],l=e,c,f;const d=[],h=[];do{s++;const m=s===o.length,g=m&&u.length!==0;if(m){if(c=h.length===0?void 0:d[d.length-1],l=f,f=h.pop(),g)if(a){l=l.slice();let S=0;for(const[b,E]of u){const w=b-S;E===null?(l.splice(w,1),S++):l[w]=E}}else{l=Object.defineProperties({},Object.getOwnPropertyDescriptors(l));for(const[S,b]of u)l[S]=b}s=i.index,o=i.keys,u=i.edits,a=i.inArray,i=i.prev}else if(f){if(c=a?s:o[s],l=f[c],l==null)continue;d.push(c)}let y;if(!Array.isArray(l)){var p,v;DD(l)||qd(!1,`Invalid AST Node: ${hO(l)}.`);const S=m?(p=n.get(l.kind))===null||p===void 0?void 0:p.leave:(v=n.get(l.kind))===null||v===void 0?void 0:v.enter;if(y=S==null?void 0:S.call(t,l,c,f,d,h),y===pO)break;if(y===!1){if(!m){d.pop();continue}}else if(y!==void 0&&(u.push([c,y]),!m))if(DD(y))l=y;else{d.pop();continue}}if(y===void 0&&g&&u.push([c,l]),m)d.pop();else{var _;i={inArray:a,index:s,keys:o,edits:u,prev:i},a=Array.isArray(l),o=a?l:(_=r[l.kind])!==null&&_!==void 0?_:[],s=-1,u=[],f&&h.push(f),f=l}}while(i!==void 0);return u.length!==0?u[u.length-1][1]:e}function vfe(e,t){const r=e[t];return typeof r=="object"?r:typeof r=="function"?{enter:r,leave:void 0}:{enter:e.enter,leave:e.leave}}function A4(e){return hn(e,gfe)}const mfe=80,gfe={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>pe(e.definitions,` `)},OperationDefinition:{leave(e){const t=Le("(",pe(e.variableDefinitions,", "),")"),r=pe([e.operation,pe([e.name,t]),pe(e.directives," ")]," ");return(r==="query"?"":r+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:r,directives:n})=>e+": "+t+Le(" = ",r)+Le(" ",pe(n," "))},SelectionSet:{leave:({selections:e})=>Mn(e)},Field:{leave({alias:e,name:t,arguments:r,directives:n,selectionSet:i}){const a=Le("",e,": ")+t;let o=a+Le("(",pe(r,", "),")");return o.length>mfe&&(o=a+Le(`( `,Ud(pe(r,` `)),` )`)),pe([o,pe(n," "),i]," ")}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,directives:t})=>"..."+e+Le(" ",pe(t," "))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:r})=>pe(["...",Le("on ",e),pe(t," "),r]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:r,directives:n,selectionSet:i})=>`fragment ${e}${Le("(",pe(r,", "),")")} on ${t} ${Le("",pe(n," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?zce(e):ffe(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>"["+pe(e,", ")+"]"},ObjectValue:{leave:({fields:e})=>"{"+pe(e,", ")+"}"},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+Le("(",pe(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:r})=>Le("",e,` `)+pe(["schema",pe(t," "),Mn(r)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:r})=>Le("",e,` `)+pe(["scalar",t,pe(r," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:r,directives:n,fields:i})=>Le("",e,` `)+pe(["type",t,Le("implements ",pe(r," & ")),pe(n," "),Mn(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:r,type:n,directives:i})=>Le("",e,` `)+t+(AD(r)?Le(`( `,Ud(pe(r,` `)),` )`):Le("(",pe(r,", "),")"))+": "+n+Le(" ",pe(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:r,defaultValue:n,directives:i})=>Le("",e,` `)+pe([t+": "+r,Le("= ",n),pe(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:r,directives:n,fields:i})=>Le("",e,` `)+pe(["interface",t,Le("implements ",pe(r," & ")),pe(n," "),Mn(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:r,types:n})=>Le("",e,` `)+pe(["union",t,pe(r," "),Le("= ",pe(n," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:r,values:n})=>Le("",e,` `)+pe(["enum",t,pe(r," "),Mn(n)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:r})=>Le("",e,` `)+pe([t,pe(r," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:r,fields:n})=>Le("",e,` `)+pe(["input",t,pe(r," "),Mn(n)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:r,repeatable:n,locations:i})=>Le("",e,` `)+"directive @"+t+(AD(r)?Le(`( `,Ud(pe(r,` `)),` )`):Le("(",pe(r,", "),")"))+(n?" repeatable":"")+" on "+pe(i," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>pe(["extend schema",pe(e," "),Mn(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>pe(["extend scalar",e,pe(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:r,fields:n})=>pe(["extend type",e,Le("implements ",pe(t," & ")),pe(r," "),Mn(n)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:r,fields:n})=>pe(["extend interface",e,Le("implements ",pe(t," & ")),pe(r," "),Mn(n)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:r})=>pe(["extend union",e,pe(t," "),Le("= ",pe(r," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:r})=>pe(["extend enum",e,pe(t," "),Mn(r)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:r})=>pe(["extend input",e,pe(t," "),Mn(r)]," ")}};function pe(e,t=""){var r;return(r=e==null?void 0:e.filter(n=>n).join(t))!==null&&r!==void 0?r:""}function Mn(e){return Le(`{ `,Ud(pe(e,` `)),` }`)}function Le(e,t,r=""){return t!=null&&t!==""?e+t+r:""}function Ud(e){return Le(" ",e.replace(/\n/g,` `))}function AD(e){var t;return(t=e==null?void 0:e.some(r=>r.includes(` `)))!==null&&t!==void 0?t:!1}const _fe=Object.freeze(Object.defineProperty({__proto__:null,print:A4},Symbol.toStringTag,{value:"Module"}));function LD(e){return e.kind===de.FIELD||e.kind===de.FRAGMENT_SPREAD||e.kind===de.INLINE_FRAGMENT}function Ju(e,t){var r=e.directives;return!r||!r.length?!0:M4(r).every(function(n){var i=n.directive,a=n.ifArgument,o=!1;return a.value.kind==="Variable"?(o=t&&t[a.value.name.value],se(o!==void 0,67,i.name.value)):o=a.value.value,i.name.value==="skip"?!o:o})}function yfe(e){var t=[];return hn(e,{Directive:function(r){t.push(r.name.value)}}),t}var Sfe=function(e,t){return to(e,t,!1)},bfe=function(e,t){return to(e,t,!0)};function to(e,t,r){var n=new Set(e),i=n.size;return hn(t,{Directive:function(a){if(n.delete(a.name.value)&&(!r||!n.size))return pO}}),r?!n.size:n.sizeObject.create(null),{forEach:Rfe,slice:MD}=Array.prototype,{hasOwnProperty:Tfe}=Object.prototype;let ss=class F4{constructor(t=!0,r=wfe){this.weakness=t,this.makeData=r}lookup(){return this.lookupArray(arguments)}lookupArray(t){let r=this;return Rfe.call(t,n=>r=r.getChildTrie(n)),Tfe.call(r,"data")?r.data:r.data=this.makeData(MD.call(t))}peek(){return this.peekArray(arguments)}peekArray(t){let r=this;for(let n=0,i=t.length;r&&n=0})||!1,q4=j4&&!Ofe;function yt(e){return e!==null&&typeof e=="object"}function U4(e){return e!==null&&typeof e=="object"&&(Object.getPrototypeOf(e)===Object.prototype||Object.getPrototypeOf(e)===null)}function B4(e,t){var r=t,n=[];e.definitions.forEach(function(a){if(a.kind==="OperationDefinition")throw Ur(71,a.operation,a.name?" named '".concat(a.name.value,"'"):"");a.kind==="FragmentDefinition"&&n.push(a)}),typeof r>"u"&&(se(n.length===1,72,n.length),r=n[0].name.value);var i=x(x({},e),{definitions:Dt([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:r}}]}}],e.definitions,!0)});return i}function tf(e){e===void 0&&(e=[]);var t={};return e.forEach(function(r){t[r.name.value]=r}),t}function rf(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":{var r=e.name.value;if(typeof t=="function")return t(r);var n=t&&t[r];return se(n,73,r),n||null}default:return null}}function Pfe(){}class OR{constructor(t=1/0,r=Pfe){this.max=t,this.dispose=r,this.map=new Map,this.newest=null,this.oldest=null}has(t){return this.map.has(t)}get(t){const r=this.getNode(t);return r&&r.value}get size(){return this.map.size}getNode(t){const r=this.map.get(t);if(r&&r!==this.newest){const{older:n,newer:i}=r;i&&(i.older=n),n&&(n.newer=i),r.older=this.newest,r.older.newer=r,r.newer=null,this.newest=r,r===this.oldest&&(this.oldest=i)}return r}set(t,r){let n=this.getNode(t);return n?n.value=r:(n={key:t,value:r,newer:null,older:this.newest},this.newest&&(this.newest.newer=n),this.newest=n,this.oldest=this.oldest||n,this.map.set(t,n),n.value)}clean(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)}delete(t){const r=this.map.get(t);return r?(r===this.newest&&(this.newest=r.older),r===this.oldest&&(this.oldest=r.newer),r.newer&&(r.newer.older=r.older),r.older&&(r.older.newer=r.newer),this.map.delete(t),this.dispose(r.value,t),!0):!1}}function PR(){}const Ife=PR,xfe=typeof WeakRef<"u"?WeakRef:function(e){return{deref:()=>e}},Cfe=typeof WeakMap<"u"?WeakMap:Map,$fe=typeof FinalizationRegistry<"u"?FinalizationRegistry:function(){return{register:PR,unregister:PR}},Dfe=10024;class ku{constructor(t=1/0,r=Ife){this.max=t,this.dispose=r,this.map=new Cfe,this.newest=null,this.oldest=null,this.unfinalizedNodes=new Set,this.finalizationScheduled=!1,this.size=0,this.finalize=()=>{const n=this.unfinalizedNodes.values();for(let i=0;i0?queueMicrotask(this.finalize):this.finalizationScheduled=!1},this.registry=new $fe(this.deleteNode.bind(this))}has(t){return this.map.has(t)}get(t){const r=this.getNode(t);return r&&r.value}getNode(t){const r=this.map.get(t);if(r&&r!==this.newest){const{older:n,newer:i}=r;i&&(i.older=n),n&&(n.newer=i),r.older=this.newest,r.older.newer=r,r.newer=null,this.newest=r,r===this.oldest&&(this.oldest=i)}return r}set(t,r){let n=this.getNode(t);return n?n.value=r:(n={key:t,value:r,newer:null,older:this.newest},this.newest&&(this.newest.newer=n),this.newest=n,this.oldest=this.oldest||n,this.scheduleFinalization(n),this.map.set(t,n),this.size++,n.value)}clean(){for(;this.oldest&&this.size>this.max;)this.deleteNode(this.oldest)}deleteNode(t){t===this.newest&&(this.newest=t.older),t===this.oldest&&(this.oldest=t.newer),t.newer&&(t.newer.older=t.older),t.older&&(t.older.newer=t.newer),this.size--;const r=t.key||t.keyRef&&t.keyRef.deref();this.dispose(t.value,r),t.keyRef?this.registry.unregister(t):this.unfinalizedNodes.delete(t),r&&this.map.delete(r)}delete(t){const r=this.map.get(t);return r?(this.deleteNode(r),!0):!1}scheduleFinalization(t){this.unfinalizedNodes.add(t),this.finalizationScheduled||(this.finalizationScheduled=!0,queueMicrotask(this.finalize))}}var V_=new WeakSet;function z4(e){V_.has(e)||(V_.add(e),setTimeout(function(){e.clean(),V_.delete(e)},100))}var nf=function(e,t){var r=new ku(e,t);return r.set=function(n,i){return z4(this),ku.prototype.set.call(this,n,i)},r},H4=function(e,t){var r=new OR(e,t);return r.set=function(n,i){return z4(this),OR.prototype.set.call(this,n,i)},r},Nfe=Symbol.for("apollo.cacheSize"),qr=x({},wR[Nfe]),wo={};function mO(e,t){wo[e]=t}var Afe=globalThis.__DEV__!==!1?jfe:void 0,Lfe=globalThis.__DEV__!==!1?qfe:void 0,Mfe=globalThis.__DEV__!==!1?W4:void 0;function Ffe(){var e={parser:1e3,canonicalStringify:1e3,print:2e3,"documentTransform.cache":2e3,"queryManager.getDocumentInfo":2e3,"PersistedQueryLink.persistedQueryHashes":2e3,"fragmentRegistry.transform":2e3,"fragmentRegistry.lookup":1e3,"fragmentRegistry.findFragmentSpreads":4e3,"cache.fragmentQueryDocuments":1e3,"removeTypenameFromVariables.getVariableDefinitions":2e3,"inMemoryCache.maybeBroadcastWatch":5e3,"inMemoryCache.executeSelectionSet":5e4,"inMemoryCache.executeSubSelectedArray":1e4};return Object.fromEntries(Object.entries(e).map(function(t){var r=t[0],n=t[1];return[r,qr[r]||n]}))}function jfe(){var e,t,r,n,i;if(globalThis.__DEV__===!1)throw new Error("only supported in development mode");return{limits:Ffe(),sizes:x({print:(e=wo.print)===null||e===void 0?void 0:e.call(wo),parser:(t=wo.parser)===null||t===void 0?void 0:t.call(wo),canonicalStringify:(r=wo.canonicalStringify)===null||r===void 0?void 0:r.call(wo),links:xR(this.link),queryManager:{getDocumentInfo:this.queryManager.transformCache.size,documentTransforms:V4(this.queryManager.documentTransform)}},(i=(n=this.cache).getMemoryInternals)===null||i===void 0?void 0:i.call(n))}}function W4(){return{cache:{fragmentQueryDocuments:Oa(this.getFragmentDoc)}}}function qfe(){var e=this.config.fragments;return x(x({},W4.apply(this)),{addTypenameDocumentTransform:V4(this.addTypenameTransform),inMemoryCache:{executeSelectionSet:Oa(this.storeReader.executeSelectionSet),executeSubSelectedArray:Oa(this.storeReader.executeSubSelectedArray),maybeBroadcastWatch:Oa(this.maybeBroadcastWatch)},fragmentRegistry:{findFragmentSpreads:Oa(e==null?void 0:e.findFragmentSpreads),lookup:Oa(e==null?void 0:e.lookup),transform:Oa(e==null?void 0:e.transform)}})}function Ufe(e){return!!e&&"dirtyKey"in e}function Oa(e){return Ufe(e)?e.size:void 0}function G4(e){return e!=null}function V4(e){return IR(e).map(function(t){return{cache:t}})}function IR(e){return e?Dt(Dt([Oa(e==null?void 0:e.performWork)],IR(e==null?void 0:e.left),!0),IR(e==null?void 0:e.right),!0).filter(G4):[]}function xR(e){var t;return e?Dt(Dt([(t=e==null?void 0:e.getMemoryInternals)===null||t===void 0?void 0:t.call(e)],xR(e==null?void 0:e.left),!0),xR(e==null?void 0:e.right),!0).filter(G4):[]}var ln=Object.assign(function(t){return JSON.stringify(t,Bfe)},{reset:function(){Hs=new H4(qr.canonicalStringify||1e3)}});globalThis.__DEV__!==!1&&mO("canonicalStringify",function(){return Hs.size});var Hs;ln.reset();function Bfe(e,t){if(t&&typeof t=="object"){var r=Object.getPrototypeOf(t);if(r===Object.prototype||r===null){var n=Object.keys(t);if(n.every(zfe))return t;var i=JSON.stringify(n),a=Hs.get(i);if(!a){n.sort();var o=JSON.stringify(n);a=Hs.get(o)||n,Hs.set(i,a),Hs.set(o,a)}var s=Object.create(r);return a.forEach(function(u){s[u]=t[u]}),s}}return t}function zfe(e,t,r){return t===0||r[t-1]<=e}function zi(e){return{__ref:String(e)}}function Be(e){return!!(e&&typeof e=="object"&&typeof e.__ref=="string")}function Y4(e){return yt(e)&&e.kind==="Document"&&Array.isArray(e.definitions)}function Hfe(e){return e.kind==="StringValue"}function Wfe(e){return e.kind==="BooleanValue"}function Gfe(e){return e.kind==="IntValue"}function Vfe(e){return e.kind==="FloatValue"}function Yfe(e){return e.kind==="Variable"}function Qfe(e){return e.kind==="ObjectValue"}function Kfe(e){return e.kind==="ListValue"}function Jfe(e){return e.kind==="EnumValue"}function Xfe(e){return e.kind==="NullValue"}function Ko(e,t,r,n){if(Gfe(r)||Vfe(r))e[t.value]=Number(r.value);else if(Wfe(r)||Hfe(r))e[t.value]=r.value;else if(Qfe(r)){var i={};r.fields.map(function(o){return Ko(i,o.name,o.value,n)}),e[t.value]=i}else if(Yfe(r)){var a=(n||{})[r.name.value];e[t.value]=a}else if(Kfe(r))e[t.value]=r.values.map(function(o){var s={};return Ko(s,t,o,n),s[t.value]});else if(Jfe(r))e[t.value]=r.value;else if(Xfe(r))e[t.value]=null;else throw Ur(82,t.value,r.kind)}function Q4(e,t){var r=null;e.directives&&(r={},e.directives.forEach(function(i){r[i.name.value]={},i.arguments&&i.arguments.forEach(function(a){var o=a.name,s=a.value;return Ko(r[i.name.value],o,s,t)})}));var n=null;return e.arguments&&e.arguments.length&&(n={},e.arguments.forEach(function(i){var a=i.name,o=i.value;return Ko(n,a,o,t)})),gO(e.name.value,n,r)}var Zfe=["connection","include","skip","client","rest","export","nonreactive"],ml=ln,gO=Object.assign(function(e,t,r){if(t&&r&&r.connection&&r.connection.key)if(r.connection.filter&&r.connection.filter.length>0){var n=r.connection.filter?r.connection.filter:[];n.sort();var i={};return n.forEach(function(s){i[s]=t[s]}),"".concat(r.connection.key,"(").concat(ml(i),")")}else return r.connection.key;var a=e;if(t){var o=ml(t);a+="(".concat(o,")")}return r&&Object.keys(r).forEach(function(s){Zfe.indexOf(s)===-1&&(r[s]&&Object.keys(r[s]).length?a+="@".concat(s,"(").concat(ml(r[s]),")"):a+="@".concat(s))}),a},{setStringify:function(e){var t=ml;return ml=e,t}});function af(e,t){if(e.arguments&&e.arguments.length){var r={};return e.arguments.forEach(function(n){var i=n.name,a=n.value;return Ko(r,i,a,t)}),r}return null}function ta(e){return e.alias?e.alias.value:e.name.value}function Kh(e,t,r){for(var n,i=0,a=t.selections;iObject.create(null),{forEach:tde,slice:rde}=Array.prototype,{hasOwnProperty:nde}=Object.prototype;class yO{constructor(t=!0,r=ede){this.weakness=t,this.makeData=r}lookup(...t){return this.lookupArray(t)}lookupArray(t){let r=this;return tde.call(t,n=>r=r.getChildTrie(n)),nde.call(r,"data")?r.data:r.data=this.makeData(rde.call(t))}peek(...t){return this.peekArray(t)}peekArray(t){let r=this;for(let n=0,i=t.length;r&&nclass{constructor(){this.id=["slot",ide++,Date.now(),Math.random().toString(36).slice(2)].join(":")}hasValue(){for(let t=cr;t;t=t.parent)if(this.id in t.slots){const r=t.slots[this.id];if(r===jD)break;return t!==cr&&(cr.slots[this.id]=r),!0}return cr&&(cr.slots[this.id]=jD),!1}getValue(){if(this.hasValue())return cr.slots[this.id]}withValue(t,r,n,i){const a={__proto__:null,[this.id]:t},o=cr;cr={parent:o,slots:a};try{return r.apply(i,n)}finally{cr=o}}static bind(t){const r=cr;return function(){const n=cr;try{return cr=r,t.apply(this,arguments)}finally{cr=n}}}static noContext(t,r,n){if(cr){const i=cr;try{return cr=null,t.apply(n,r)}finally{cr=i}}else return t.apply(n,r)}};function qD(e){try{return e()}catch{}}const Y_="@wry/context:Slot",ode=qD(()=>globalThis)||qD(()=>global)||Object.create(null),UD=ode,X4=UD[Y_]||Array[Y_]||function(e){try{Object.defineProperty(UD,Y_,{value:e,enumerable:!1,writable:!1,configurable:!0})}finally{return e}}(ade()),$v=new X4,{hasOwnProperty:sde}=Object.prototype,SO=Array.from||function(e){const t=[];return e.forEach(r=>t.push(r)),t};function Xh(e){const{unsubscribe:t}=e;typeof t=="function"&&(e.unsubscribe=void 0,t())}const Pc=[],ude=100;function Ou(e,t){if(!e)throw new Error(t||"assertion failure")}function Z4(e,t){const r=e.length;return r>0&&r===t.length&&e[r-1]===t[r-1]}function eW(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}function tW(e){return e.slice(0)}class Dv{constructor(t){this.fn=t,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++Dv.count}peek(){if(this.value.length===1&&!ro(this))return BD(this),this.value[0]}recompute(t){return Ou(!this.recomputing,"already recomputing"),BD(this),ro(this)?lde(this,t):eW(this.value)}setDirty(){this.dirty||(this.dirty=!0,rW(this),Xh(this))}dispose(){this.setDirty(),sW(this),bO(this,(t,r)=>{t.setDirty(),uW(t,this)})}forget(){this.dispose()}dependOn(t){t.add(this),this.deps||(this.deps=Pc.pop()||new Set),this.deps.add(t)}forgetDeps(){this.deps&&(SO(this.deps).forEach(t=>t.delete(this)),this.deps.clear(),Pc.push(this.deps),this.deps=null)}}Dv.count=0;function BD(e){const t=$v.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),ro(e)?iW(t,e):aW(t,e),t}function lde(e,t){return sW(e),$v.withValue(e,cde,[e,t]),dde(e,t)&&fde(e),eW(e.value)}function cde(e,t){e.recomputing=!0;const{normalizeResult:r}=e;let n;r&&e.value.length===1&&(n=tW(e.value)),e.value.length=0;try{if(e.value[0]=e.fn.apply(null,t),r&&n&&!Z4(n,e.value))try{e.value[0]=r(e.value[0],n[0])}catch{}}catch(i){e.value[1]=i}e.recomputing=!1}function ro(e){return e.dirty||!!(e.dirtyChildren&&e.dirtyChildren.size)}function fde(e){e.dirty=!1,!ro(e)&&nW(e)}function rW(e){bO(e,iW)}function nW(e){bO(e,aW)}function bO(e,t){const r=e.parents.size;if(r){const n=SO(e.parents);for(let i=0;i0&&e.childValues.forEach((t,r)=>{uW(e,r)}),e.forgetDeps(),Ou(e.dirtyChildren===null)}function uW(e,t){t.parents.delete(e),e.childValues.delete(t),oW(e,t)}function dde(e,t){if(typeof e.subscribe=="function")try{Xh(e),e.unsubscribe=e.subscribe.apply(null,t)}catch{return e.setDirty(),!1}return!0}const hde={setDirty:!0,dispose:!0,forget:!0};function lW(e){const t=new Map,r=e&&e.subscribe;function n(i){const a=$v.getValue();if(a){let o=t.get(i);o||t.set(i,o=new Set),a.dependOn(o),typeof r=="function"&&(Xh(o),o.unsubscribe=r(i))}}return n.dirty=function(a,o){const s=t.get(a);if(s){const u=o&&sde.call(hde,o)?o:"setDirty";SO(s).forEach(l=>l[u]()),t.delete(a),Xh(s)}},n}let zD;function pde(...e){return(zD||(zD=new yO(typeof WeakMap=="function"))).lookupArray(e)}const Q_=new Set;function Va(e,{max:t=Math.pow(2,16),keyArgs:r,makeCacheKey:n=pde,normalizeResult:i,subscribe:a,cache:o=OR}=Object.create(null)){const s=typeof o=="function"?new o(t,d=>d.dispose()):o,u=function(){const d=n.apply(null,r?r.apply(null,arguments):arguments);if(d===void 0)return e.apply(null,arguments);let h=s.get(d);h||(s.set(d,h=new Dv(e)),h.normalizeResult=i,h.subscribe=a,h.forget=()=>s.delete(d));const p=h.recompute(Array.prototype.slice.call(arguments));return s.set(d,h),Q_.add(s),$v.hasValue()||(Q_.forEach(v=>v.clean()),Q_.clear()),p};Object.defineProperty(u,"size",{get:()=>s.size,configurable:!1,enumerable:!1}),Object.freeze(u.options={max:t,keyArgs:r,makeCacheKey:n,normalizeResult:i,subscribe:a,cache:s});function l(d){const h=d&&s.get(d);h&&h.setDirty()}u.dirtyKey=l,u.dirty=function(){l(n.apply(null,arguments))};function c(d){const h=d&&s.get(d);if(h)return h.peek()}u.peekKey=c,u.peek=function(){return c(n.apply(null,arguments))};function f(d){return d?s.delete(d):!1}return u.forgetKey=f,u.forget=function(){return f(n.apply(null,arguments))},u.makeCacheKey=n,u.getKey=r?function(){return n.apply(null,r.apply(null,arguments))}:n,Object.freeze(u)}function vde(e){return e}var Nv=function(){function e(t,r){r===void 0&&(r=Object.create(null)),this.resultCache=vO?new WeakSet:new Set,this.transform=t,r.getCacheKey&&(this.getCacheKey=r.getCacheKey),this.cached=r.cache!==!1,this.resetCache()}return e.prototype.getCacheKey=function(t){return[t]},e.identity=function(){return new e(vde,{cache:!1})},e.split=function(t,r,n){return n===void 0&&(n=e.identity()),Object.assign(new e(function(i){var a=t(i)?r:n;return a.transformDocument(i)},{cache:!1}),{left:r,right:n})},e.prototype.resetCache=function(){var t=this;if(this.cached){var r=new ss(fa);this.performWork=Va(e.prototype.performWork.bind(this),{makeCacheKey:function(n){var i=t.getCacheKey(n);if(i)return se(Array.isArray(i),66),r.lookupArray(i)},max:qr["documentTransform.cache"],cache:ku})}},e.prototype.performWork=function(t){return us(t),this.transform(t)},e.prototype.transformDocument=function(t){if(this.resultCache.has(t))return t;var r=this.performWork(t);return this.resultCache.add(r),r},e.prototype.concat=function(t){var r=this;return Object.assign(new e(function(n){return t.transformDocument(r.transformDocument(n))},{cache:!1}),{left:this,right:t})},e}(),Kl,Zu=Object.assign(function(e){var t=Kl.get(e);return t||(t=A4(e),Kl.set(e,t)),t},{reset:function(){Kl=new nf(qr.print||2e3)}});Zu.reset();globalThis.__DEV__!==!1&&mO("print",function(){return Kl?Kl.size:0});var St=Array.isArray;function or(e){return Array.isArray(e)&&e.length>0}var HD={kind:de.FIELD,name:{kind:de.NAME,value:"__typename"}};function cW(e,t){return!e||e.selectionSet.selections.every(function(r){return r.kind===de.FRAGMENT_SPREAD&&cW(t[r.name.value],t)})}function EO(e){return cW(ls(e)||J4(e),tf(Jo(e)))?null:e}function mde(e){var t=new Map,r=new Map;return e.forEach(function(n){n&&(n.name?t.set(n.name,n):n.test&&r.set(n.test,n))}),function(n){var i=t.get(n.name.value);return!i&&r.size&&r.forEach(function(a,o){o(n)&&(i=a)}),i}}function WD(e){var t=new Map;return function(n){n===void 0&&(n=e);var i=t.get(n);return i||t.set(n,i={variables:new Set,fragmentSpreads:new Set}),i}}function Av(e,t){us(t);for(var r=WD(""),n=WD(""),i=function(m){for(var g=0,y=void 0;g=0;--o)t.definitions[o].kind===de.OPERATION_DEFINITION&&++a;var s=mde(e),u=function(m){return or(m)&&m.map(s).some(function(g){return g&&g.remove})},l=new Map,c=!1,f={enter:function(m){if(u(m.directives))return c=!0,null}},d=hn(t,{Field:f,InlineFragment:f,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(m,g,y,S,b){var E=i(b);E&&E.variables.add(m.name.value)}},FragmentSpread:{enter:function(m,g,y,S,b){if(u(m.directives))return c=!0,null;var E=i(b);E&&E.fragmentSpreads.add(m.name.value)}},FragmentDefinition:{enter:function(m,g,y,S){l.set(JSON.stringify(S),m)},leave:function(m,g,y,S){var b=l.get(JSON.stringify(S));if(m===b)return m;if(a>0&&m.selectionSet.selections.every(function(E){return E.kind===de.FIELD&&E.name.value==="__typename"}))return n(m.name.value).removed=!0,c=!0,null}},Directive:{leave:function(m){if(s(m))return c=!0,null}}});if(!c)return t;var h=function(m){return m.transitiveVars||(m.transitiveVars=new Set(m.variables),m.removed||m.fragmentSpreads.forEach(function(g){h(n(g)).transitiveVars.forEach(function(y){m.transitiveVars.add(y)})})),m},p=new Set;d.definitions.forEach(function(m){m.kind===de.OPERATION_DEFINITION?h(r(m.name&&m.name.value)).fragmentSpreads.forEach(function(g){p.add(g)}):m.kind===de.FRAGMENT_DEFINITION&&a===0&&!n(m.name.value).removed&&p.add(m.name.value)}),p.forEach(function(m){h(n(m)).fragmentSpreads.forEach(function(g){p.add(g)})});var v=function(m){return!!(!p.has(m)||n(m).removed)},_={enter:function(m){if(v(m.name.value))return null}};return EO(hn(d,{FragmentSpread:_,FragmentDefinition:_,OperationDefinition:{leave:function(m){if(m.variableDefinitions){var g=h(r(m.name&&m.name.value)).transitiveVars;if(g.size1)for(var n=new na,i=1;i1&&o===s&&(o="");var u=t.pageInfo||{},l=u.startCursor,c=u.endCursor;return x(x({},K_(t)),{edges:a,pageInfo:x(x({},t.pageInfo),{startCursor:l||o,endCursor:c||s})})},merge:function(t,r,n){var i=n.args,a=n.isReference,o=n.readField;if(t||(t=Cde()),!r)return t;var s=r.edges?r.edges.map(function(R){return a(R=x({},R))&&(R.cursor=o("cursor",R)),R}):[];if(r.pageInfo){var u=r.pageInfo,l=u.startCursor,c=u.endCursor,f=s[0],d=s[s.length-1];f&&l&&(f.cursor=l),d&&c&&(d.cursor=c);var h=f&&f.cursor;h&&!l&&(r=Ic(r,{pageInfo:{startCursor:h}}));var p=d&&d.cursor;p&&!c&&(r=Ic(r,{pageInfo:{endCursor:p}}))}var v=t.edges,_=[];if(i&&i.after){var m=v.findIndex(function(R){return R.cursor===i.after});m>=0&&(v=v.slice(0,m+1))}else if(i&&i.before){var m=v.findIndex(function(O){return O.cursor===i.before});_=m<0?v:v.slice(m),v=[]}else r.edges&&(v=[]);var g=Dt(Dt(Dt([],v,!0),s,!0),_,!0),y=x(x({},r.pageInfo),t.pageInfo);if(r.pageInfo){var S=r.pageInfo,b=S.hasPreviousPage,E=S.hasNextPage,l=S.startCursor,c=S.endCursor,w=Zr(S,["hasPreviousPage","hasNextPage","startCursor","endCursor"]);Object.assign(y,w),v.length||(b!==void 0&&(y.hasPreviousPage=b),l!==void 0&&(y.startCursor=l)),_.length||(E!==void 0&&(y.hasNextPage=E),c!==void 0&&(y.endCursor=c))}return x(x(x({},K_(t)),K_(r)),{edges:g,pageInfo:y})}}}var K_=function(e){return Zr(e,xde)},xde=["edges","pageInfo"];function Cde(){return{edges:[],pageInfo:{hasPreviousPage:!1,hasNextPage:!0,startCursor:"",endCursor:""}}}function $de(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r)return(r=r.call(e)).next.bind(r);if(Array.isArray(e)||(r=Dde(e))||t&&e&&typeof e.length=="number"){r&&(e=r);var n=0;return function(){return n>=e.length?{done:!0}:{done:!1,value:e[n++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Dde(e,t){if(e){if(typeof e=="string")return GD(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return GD(e,t)}}function GD(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r1,s=!1,u=arguments[1],l=u;return new a(function(c){return i.subscribe({next:function(f){var d=!s;if(s=!0,!d||o)try{l=n(l,f)}catch(h){return c.error(h)}else l=f},error:function(f){c.error(f)},complete:function(){if(!s&&!o)return c.error(new TypeError("Cannot reduce an empty sequence"));c.next(l),c.complete()}})})},t.concat=function(){for(var n=this,i=arguments.length,a=new Array(i),o=0;o=0&&s.splice(d,1),l()}});s.push(f)},error:function(c){o.error(c)},complete:function(){l()}});function l(){u.closed&&s.length===0&&o.complete()}return function(){s.forEach(function(c){return c.unsubscribe()}),u.unsubscribe()}})},t[CR]=function(){return this},e.from=function(n){var i=typeof this=="function"?this:e;if(n==null)throw new TypeError(n+" is not an object");var a=Zh(n,CR);if(a){var o=a.call(n);if(Object(o)!==o)throw new TypeError(o+" is not an object");return Ade(o)&&o.constructor===i?o:new i(function(s){return o.subscribe(s)})}if(OO("iterator")&&(a=Zh(n,Nde),a))return new i(function(s){Bd(function(){if(!s.closed){for(var u=$de(a.call(n)),l;!(l=u()).done;){var c=l.value;if(s.next(c),s.closed)return}s.complete()}})});if(Array.isArray(n))return new i(function(s){Bd(function(){if(!s.closed){for(var u=0;u=0;--s){var u=o[s],l=!isNaN(+u),c=l?[]:{};c[u]=a,a=c}r=n.merge(r,a)}),r}function Jl(e){var t=ep(e);return or(t)}function ep(e){var t=or(e.errors)?e.errors.slice(0):[];return Bo(e)&&or(e.incremental)&&e.incremental.forEach(function(r){r.errors&&t.push.apply(t,r.errors)}),t}function ia(){for(var e=[],t=0;t-1;){if(_=void 0,w=[s.slice(0,v),s.slice(v+o.length)],_=w[0],s=w[1],m=_.indexOf(`\r \r `),g=hhe(_.slice(0,m)),y=g["content-type"],y&&y.toLowerCase().indexOf("application/json")===-1)throw new Error("Unsupported patch content type: application/json is required.");if(S=_.slice(m),S){if(b=EW(e,S),Object.keys(b).length>1||"data"in b||"incremental"in b||"errors"in b||"payload"in b)if(yW(b)){if(E={},"payload"in b){if(Object.keys(b).length===1&&b.payload===null)return[2];E=x({},b.payload)}"errors"in b&&(E=x(x({},E),{extensions:x(x({},"extensions"in E?E.extensions:null),(R={},R[NO]=b.errors,R))})),t(E)}else t(b);else if(Object.keys(b).length===1&&"hasNext"in b&&!b.hasNext)return[2]}v=s.indexOf(o)}return[3,1];case 3:return[2]}})})}function hhe(e){var t={};return e.split(` `).forEach(function(r){var n=r.indexOf(":");if(n>-1){var i=r.slice(0,n).trim().toLowerCase(),a=r.slice(n+1).trim();t[i]=a}}),t}function EW(e,t){if(e.status>=300){var r=function(){try{return JSON.parse(t)}catch{return t}};DO(e,r(),"Response not successful: Received status code ".concat(e.status))}try{return JSON.parse(t)}catch(i){var n=i;throw n.name="ServerParseError",n.response=e,n.statusCode=e.status,n.bodyText=t,n}}function phe(e,t){e.result&&e.result.errors&&e.result.data&&t.next(e.result),t.error(e)}function wW(e){return function(t){return t.text().then(function(r){return EW(t,r)}).then(function(r){return!Array.isArray(r)&&!JD.call(r,"data")&&!JD.call(r,"errors")&&DO(t,r,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(n){return n.operationName}):e.operationName,"'.")),r})}}var rp=function(e,t){var r;try{r=JSON.stringify(e)}catch(i){var n=Ur(39,t,i.message);throw n.parseError=i,n}return r},vhe={includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},mhe={accept:"*/*","content-type":"application/json"},ghe={method:"POST"},RW={http:vhe,headers:mhe,options:ghe},AO=function(e,t){return t(e)};function _he(e,t){for(var r=[],n=2;n"u")throw Ur(37)},She=function(){if(typeof AbortController>"u")return{controller:!1,signal:!1};var e=new AbortController,t=e.signal;return{controller:e,signal:t}},kW=function(e,t){var r=e.getContext(),n=r.uri;return n||(typeof t=="function"?t(e):t||"/graphql")};function OW(e,t){var r=[],n=function(f,d){r.push("".concat(f,"=").concat(encodeURIComponent(d)))};if("query"in t&&n("query",t.query),t.operationName&&n("operationName",t.operationName),t.variables){var i=void 0;try{i=rp(t.variables,"Variables map")}catch(f){return{parseError:f}}n("variables",i)}if(t.extensions){var a=void 0;try{a=rp(t.extensions,"Extensions map")}catch(f){return{parseError:f}}n("extensions",a)}var o="",s=e,u=e.indexOf("#");u!==-1&&(o=e.substr(u),s=e.substr(0,u));var l=s.indexOf("?")===-1?"?":"&",c=s+l+r.join("&")+o;return{newURI:c}}var XD=Rn(function(){return fetch}),PW=function(e){e===void 0&&(e={});var t=e.uri,r=t===void 0?"/graphql":t,n=e.fetch,i=e.print,a=i===void 0?AO:i,o=e.includeExtensions,s=e.preserveHeaderCase,u=e.useGETForQueries,l=e.includeUnusedVariables,c=l===void 0?!1:l,f=Zr(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);globalThis.__DEV__!==!1&&TW(n||XD);var d={http:{includeExtensions:o,preserveHeaderCase:s},options:f.fetchOptions,credentials:f.credentials,headers:f.headers};return new Nn(function(h){var p=kW(h,r),v=h.getContext(),_={};if(v.clientAwareness){var m=v.clientAwareness,g=m.name,y=m.version;g&&(_["apollographql-client-name"]=g),y&&(_["apollographql-client-version"]=y)}var S=x(x({},_),v.headers),b={http:v.http,options:v.fetchOptions,credentials:v.credentials,headers:S};if(to(["client"],h.query)){var E=wO(h.query);if(!E)return Wd(new Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));h.query=E}var w=LO(h,a,RW,d,b),R=w.options,O=w.body;O.variables&&!c&&(O.variables=Qde(O.variables,h.query));var k;!R.signal&&typeof AbortController<"u"&&(k=new AbortController,R.signal=k.signal);var C=function(F){return F.kind==="OperationDefinition"&&F.operation==="mutation"},T=function(F){return F.kind==="OperationDefinition"&&F.operation==="subscription"},$=T(Xu(h.query)),L=to(["defer"],h.query);if(u&&!h.query.definitions.some(C)&&(R.method="GET"),L||$){R.headers=R.headers||{};var G="multipart/mixed;";$&&L&&globalThis.__DEV__!==!1&&se.warn(38),$?G+="boundary=graphql;subscriptionSpec=1.0,application/json":L&&(G+="deferSpec=20220824,application/json"),R.headers.accept=G}if(R.method==="GET"){var Y=OW(p,O),B=Y.newURI,D=Y.parseError;if(D)return Wd(D);p=B}else try{R.body=rp(O,"Payload")}catch(F){return Wd(F)}return new Xe(function(F){var z=n||Rn(function(){return fetch})||XD,ee=F.next.bind(F);return z(p,R).then(function(Z){var W;h.setContext({response:Z});var Q=(W=Z.headers)===null||W===void 0?void 0:W.get("content-type");return Q!==null&&/^multipart\/mixed/i.test(Q)?dhe(Z,ee):wW(h)(Z).then(ee)}).then(function(){k=void 0,F.complete()}).catch(function(Z){k=void 0,phe(Z,F)}),function(){k&&k.abort()}})})},IW=function(e){Si(t,e);function t(r){r===void 0&&(r={});var n=e.call(this,PW(r).request)||this;return n.options=r,n}return t}(Nn);const{toString:ZD,hasOwnProperty:bhe}=Object.prototype,eN=Function.prototype.toString,AR=new Map;function Ae(e,t){try{return LR(e,t)}finally{AR.clear()}}function LR(e,t){if(e===t)return!0;const r=ZD.call(e),n=ZD.call(t);if(r!==n)return!1;switch(r){case"[object Array]":if(e.length!==t.length)return!1;case"[object Object]":{if(rN(e,t))return!0;const i=tN(e),a=tN(t),o=i.length;if(o!==a.length)return!1;for(let s=0;s=0&&e.indexOf(t,r)===r}function rN(e,t){let r=AR.get(e);if(r){if(r.has(t))return!0}else AR.set(e,r=new Set);return r.add(t),!1}var Mv=function(){function e(){this.assumeImmutableResults=!1,this.getFragmentDoc=Va(B4,{max:qr["cache.fragmentQueryDocuments"]||1e3,cache:ku})}return e.prototype.batch=function(t){var r=this,n=typeof t.optimistic=="string"?t.optimistic:t.optimistic===!1?null:void 0,i;return this.performTransaction(function(){return i=t.update(r)},n),i},e.prototype.recordOptimisticTransaction=function(t,r){this.performTransaction(t,r)},e.prototype.transformDocument=function(t){return t},e.prototype.transformForLink=function(t){return t},e.prototype.identify=function(t){},e.prototype.gc=function(){return[]},e.prototype.modify=function(t){return!1},e.prototype.readQuery=function(t,r){return r===void 0&&(r=!!t.optimistic),this.read(x(x({},t),{rootId:t.id||"ROOT_QUERY",optimistic:r}))},e.prototype.readFragment=function(t,r){return r===void 0&&(r=!!t.optimistic),this.read(x(x({},t),{query:this.getFragmentDoc(t.fragment,t.fragmentName),rootId:t.id,optimistic:r}))},e.prototype.writeQuery=function(t){var r=t.id,n=t.data,i=Zr(t,["id","data"]);return this.write(Object.assign(i,{dataId:r||"ROOT_QUERY",result:n}))},e.prototype.writeFragment=function(t){var r=t.id,n=t.data,i=t.fragment,a=t.fragmentName,o=Zr(t,["id","data","fragment","fragmentName"]);return this.write(Object.assign(o,{query:this.getFragmentDoc(i,a),dataId:r,result:n}))},e.prototype.updateQuery=function(t,r){return this.batch({update:function(n){var i=n.readQuery(t),a=r(i);return a==null?i:(n.writeQuery(x(x({},t),{data:a})),a)}})},e.prototype.updateFragment=function(t,r){return this.batch({update:function(n){var i=n.readFragment(t),a=r(i);return a==null?i:(n.writeFragment(x(x({},t),{data:a})),a)}})},e}();globalThis.__DEV__!==!1&&(Mv.prototype.getMemoryInternals=Mfe);var np;np||(np={});var Fv=function(e){Si(t,e);function t(r,n,i,a){var o,s=e.call(this,r)||this;if(s.message=r,s.path=n,s.query=i,s.variables=a,Array.isArray(s.path)){s.missing=s.message;for(var u=s.path.length-1;u>=0;--u)s.missing=(o={},o[s.path[u]]=s.missing,o)}else s.missing=s.path;return s.__proto__=t.prototype,s}return t}(Error),Xt=Object.prototype.hasOwnProperty;function yl(e){return e==null}function jv(e,t){var r=e.__typename,n=e.id,i=e._id;if(typeof r=="string"&&(t&&(t.keyObject=yl(n)?yl(i)?void 0:{_id:i}:{id:n}),yl(n)&&!yl(i)&&(n=i),!yl(n)))return"".concat(r,":").concat(typeof n=="number"||typeof n=="string"?n:JSON.stringify(n))}var xW={dataIdFromObject:jv,addTypename:!0,resultCaching:!0,canonizeResults:!1};function The(e){return ia(xW,e)}function CW(e){var t=e.canonizeResults;return t===void 0?xW.canonizeResults:t}function khe(e,t){return Be(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var $W=/^[_a-z][_0-9a-z]*/i;function aa(e){var t=e.match($W);return t?t[0]:e}function MR(e,t,r){return yt(t)?St(t)?t.every(function(n){return MR(e,n,r)}):e.selections.every(function(n){if(ra(n)&&Ju(n,r)){var i=ta(n);return Xt.call(t,i)&&(!n.selectionSet||MR(n.selectionSet,t[i],r))}return!0}):!1}function Ws(e){return yt(e)&&!Be(e)&&!St(e)}function Ohe(){return new na}function DW(e,t){var r=tf(Jo(e));return{fragmentMap:r,lookupFragment:function(n){var i=r[n];return!i&&t&&(i=t.lookup(n)),i||null}}}var Gd=Object.create(null),X_=function(){return Gd},nN=Object.create(null),xu=function(){function e(t,r){var n=this;this.policies=t,this.group=r,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(i,a){return Iu(Be(i)?n.get(i.__ref,a):i&&i[a])},this.canRead=function(i){return Be(i)?n.has(i.__ref):typeof i=="object"},this.toReference=function(i,a){if(typeof i=="string")return zi(i);if(Be(i))return i;var o=n.policies.identify(i)[0];if(o){var s=zi(o);return a&&n.merge(o,i),s}}}return e.prototype.toObject=function(){return x({},this.data)},e.prototype.has=function(t){return this.lookup(t,!0)!==void 0},e.prototype.get=function(t,r){if(this.group.depend(t,r),Xt.call(this.data,t)){var n=this.data[t];if(n&&Xt.call(n,r))return n[r]}if(r==="__typename"&&Xt.call(this.policies.rootTypenamesById,t))return this.policies.rootTypenamesById[t];if(this instanceof _a)return this.parent.get(t,r)},e.prototype.lookup=function(t,r){if(r&&this.group.depend(t,"__exists"),Xt.call(this.data,t))return this.data[t];if(this instanceof _a)return this.parent.lookup(t,r);if(this.policies.rootTypenamesById[t])return Object.create(null)},e.prototype.merge=function(t,r){var n=this,i;Be(t)&&(t=t.__ref),Be(r)&&(r=r.__ref);var a=typeof t=="string"?this.lookup(i=t):t,o=typeof r=="string"?this.lookup(i=r):r;if(o){se(typeof i=="string",1);var s=new na(Ihe).merge(a,o);if(this.data[i]=s,s!==a&&(delete this.refs[i],this.group.caching)){var u=Object.create(null);a||(u.__exists=1),Object.keys(o).forEach(function(l){if(!a||a[l]!==s[l]){u[l]=1;var c=aa(l);c!==l&&!n.policies.hasKeyArgs(s.__typename,c)&&(u[c]=1),s[l]===void 0&&!(n instanceof _a)&&delete s[l]}}),u.__typename&&!(a&&a.__typename)&&this.policies.rootTypenamesById[i]===s.__typename&&delete u.__typename,Object.keys(u).forEach(function(l){return n.group.dirty(i,l)})}}},e.prototype.modify=function(t,r){var n=this,i=this.lookup(t);if(i){var a=Object.create(null),o=!1,s=!0,u={DELETE:Gd,INVALIDATE:nN,isReference:Be,toReference:this.toReference,canRead:this.canRead,readField:function(l,c){return n.policies.readField(typeof l=="string"?{fieldName:l,from:c||zi(t)}:l,{store:n})}};if(Object.keys(i).forEach(function(l){var c=aa(l),f=i[l];if(f!==void 0){var d=typeof r=="function"?r:r[l]||r[c];if(d){var h=d===X_?Gd:d(Iu(f),x(x({},u),{fieldName:c,storeFieldName:l,storage:n.getStorage(t,l)}));if(h===nN)n.group.dirty(t,l);else if(h===Gd&&(h=void 0),h!==f&&(a[l]=h,o=!0,f=h,globalThis.__DEV__!==!1)){var p=function(b){if(n.lookup(b.__ref)===void 0)return globalThis.__DEV__!==!1&&se.warn(2,b),!0};if(Be(h))p(h);else if(Array.isArray(h))for(var v=!1,_=void 0,m=0,g=h;m0){var r=--this.rootIds[t];return r||delete this.rootIds[t],r}return 0},e.prototype.getRootIdSet=function(t){return t===void 0&&(t=new Set),Object.keys(this.rootIds).forEach(t.add,t),this instanceof _a?this.parent.getRootIdSet(t):Object.keys(this.policies.rootTypenamesById).forEach(t.add,t),t},e.prototype.gc=function(){var t=this,r=this.getRootIdSet(),n=this.toObject();r.forEach(function(o){Xt.call(n,o)&&(Object.keys(t.findChildRefIds(o)).forEach(r.add,r),delete n[o])});var i=Object.keys(n);if(i.length){for(var a=this;a instanceof _a;)a=a.parent;i.forEach(function(o){return a.delete(o)})}return i},e.prototype.findChildRefIds=function(t){if(!Xt.call(this.refs,t)){var r=this.refs[t]=Object.create(null),n=this.data[t];if(!n)return r;var i=new Set([n]);i.forEach(function(a){Be(a)&&(r[a.__ref]=!0),yt(a)&&Object.keys(a).forEach(function(o){var s=a[o];yt(s)&&i.add(s)})})}return this.refs[t]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),NW=function(){function e(t,r){r===void 0&&(r=null),this.caching=t,this.parent=r,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?lW():null,this.keyMaker=new ss(fa)},e.prototype.depend=function(t,r){if(this.d){this.d(Z_(t,r));var n=aa(r);n!==r&&this.d(Z_(t,n)),this.parent&&this.parent.depend(t,r)}},e.prototype.dirty=function(t,r){this.d&&this.d.dirty(Z_(t,r),r==="__exists"?"forget":"setDirty")},e}();function Z_(e,t){return t+"#"+e}function iN(e,t){Xl(e)&&e.group.depend(t,"__exists")}(function(e){var t=function(r){Si(n,r);function n(i){var a=i.policies,o=i.resultCaching,s=o===void 0?!0:o,u=i.seed,l=r.call(this,a,new NW(s))||this;return l.stump=new Phe(l),l.storageTrie=new ss(fa),u&&l.replace(u),l}return n.prototype.addLayer=function(i,a){return this.stump.addLayer(i,a)},n.prototype.removeLayer=function(){return this},n.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},n}(e);e.Root=t})(xu||(xu={}));var _a=function(e){Si(t,e);function t(r,n,i,a){var o=e.call(this,n.policies,a)||this;return o.id=r,o.parent=n,o.replay=i,o.group=a,i(o),o}return t.prototype.addLayer=function(r,n){return new t(r,this,n,this.group)},t.prototype.removeLayer=function(r){var n=this,i=this.parent.removeLayer(r);return r===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(a){var o=n.data[a],s=i.lookup(a);s?o?o!==s&&Object.keys(o).forEach(function(u){Ae(o[u],s[u])||n.group.dirty(a,u)}):(n.group.dirty(a,"__exists"),Object.keys(s).forEach(function(u){n.group.dirty(a,u)})):n.delete(a)}),i):i===this.parent?this:i.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return x(x({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(r){var n=this.parent.findChildRefIds(r);return Xt.call(this.data,r)?x(x({},n),e.prototype.findChildRefIds.call(this,r)):n},t.prototype.getStorage=function(){for(var r=this.parent;r.parent;)r=r.parent;return r.getStorage.apply(r,arguments)},t}(xu),Phe=function(e){Si(t,e);function t(r){return e.call(this,"EntityStore.Stump",r,function(){},new NW(r.group.caching,r.group))||this}return t.prototype.removeLayer=function(){return this},t.prototype.merge=function(r,n){return this.parent.merge(r,n)},t}(_a);function Ihe(e,t,r){var n=e[r],i=t[r];return Ae(n,i)?n:i}function Xl(e){return!!(e instanceof xu&&e.group.caching)}function xhe(e){return yt(e)?St(e)?e.slice(0):x({__proto__:Object.getPrototypeOf(e)},e):e}var aN=function(){function e(){this.known=new(vO?WeakSet:Set),this.pool=new ss(fa),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(t){return yt(t)&&this.known.has(t)},e.prototype.pass=function(t){if(yt(t)){var r=xhe(t);return this.passes.set(r,t),r}return t},e.prototype.admit=function(t){var r=this;if(yt(t)){var n=this.passes.get(t);if(n)return n;var i=Object.getPrototypeOf(t);switch(i){case Array.prototype:{if(this.known.has(t))return t;var a=t.map(this.admit,this),o=this.pool.lookupArray(a);return o.array||(this.known.add(o.array=a),globalThis.__DEV__!==!1&&Object.freeze(a)),o.array}case null:case Object.prototype:{if(this.known.has(t))return t;var s=Object.getPrototypeOf(t),u=[s],l=this.sortedKeys(t);u.push(l.json);var c=u.length;l.sorted.forEach(function(h){u.push(r.admit(t[h]))});var o=this.pool.lookupArray(u);if(!o.object){var f=o.object=Object.create(s);this.known.add(f),l.sorted.forEach(function(h,p){f[h]=u[c+p]}),globalThis.__DEV__!==!1&&Object.freeze(f)}return o.object}}}return t},e.prototype.sortedKeys=function(t){var r=Object.keys(t),n=this.pool.lookupArray(r);if(!n.keys){r.sort();var i=JSON.stringify(r);(n.keys=this.keysByJSON.get(i))||this.keysByJSON.set(i,n.keys={sorted:r,json:i})}return n.keys},e}();function oN(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var Che=function(){function e(t){var r=this;this.knownResults=new(fa?WeakMap:Map),this.config=ia(t,{addTypename:t.addTypename!==!1,canonizeResults:CW(t)}),this.canon=t.canon||new aN,this.executeSelectionSet=Va(function(n){var i,a=n.context.canonizeResults,o=oN(n);o[3]=!a;var s=(i=r.executeSelectionSet).peek.apply(i,o);return s?a?x(x({},s),{result:r.canon.admit(s.result)}):s:(iN(n.context.store,n.enclosingRef.__ref),r.execSelectionSetImpl(n))},{max:this.config.resultCacheMaxSize||qr["inMemoryCache.executeSelectionSet"]||5e4,keyArgs:oN,makeCacheKey:function(n,i,a,o){if(Xl(a.store))return a.store.makeCacheKey(n,Be(i)?i.__ref:i,a.varString,o)}}),this.executeSubSelectedArray=Va(function(n){return iN(n.context.store,n.enclosingRef.__ref),r.execSubSelectedArrayImpl(n)},{max:this.config.resultCacheMaxSize||qr["inMemoryCache.executeSubSelectedArray"]||1e4,makeCacheKey:function(n){var i=n.field,a=n.array,o=n.context;if(Xl(o.store))return o.store.makeCacheKey(i,a,o.varString)}})}return e.prototype.resetCanon=function(){this.canon=new aN},e.prototype.diffQueryAgainstStore=function(t){var r=t.store,n=t.query,i=t.rootId,a=i===void 0?"ROOT_QUERY":i,o=t.variables,s=t.returnPartialData,u=s===void 0?!0:s,l=t.canonizeResults,c=l===void 0?this.config.canonizeResults:l,f=this.config.cache.policies;o=x(x({},Cv(_O(n))),o);var d=zi(a),h=this.executeSelectionSet({selectionSet:Xu(n).selectionSet,objectOrReference:d,enclosingRef:d,context:x({store:r,query:n,policies:f,variables:o,varString:ln(o),canonizeResults:c},DW(n,this.config.fragments))}),p;if(h.missing&&(p=[new Fv($he(h.missing),h.missing,n,o)],!u))throw p[0];return{result:h.result,complete:!p,missing:p}},e.prototype.isFresh=function(t,r,n,i){if(Xl(i.store)&&this.knownResults.get(t)===n){var a=this.executeSelectionSet.peek(n,r,i,this.canon.isKnown(t));if(a&&t===a.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(t){var r=this,n=t.selectionSet,i=t.objectOrReference,a=t.enclosingRef,o=t.context;if(Be(i)&&!o.policies.rootTypenamesById[i.__ref]&&!o.store.has(i.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(i.__ref," object")};var s=o.variables,u=o.policies,l=o.store,c=l.getFieldValue(i,"__typename"),f=[],d,h=new na;this.config.addTypename&&typeof c=="string"&&!u.rootIdsByTypename[c]&&f.push({__typename:c});function p(y,S){var b;return y.missing&&(d=h.merge(d,(b={},b[S]=y.missing,b))),y.result}var v=new Set(n.selections);v.forEach(function(y){var S,b;if(Ju(y,s))if(ra(y)){var E=u.readField({fieldName:y.name.value,field:y,variables:o.variables,from:i},o),w=ta(y);E===void 0?Lv.added(y)||(d=h.merge(d,(S={},S[w]="Can't find field '".concat(y.name.value,"' on ").concat(Be(i)?i.__ref+" object":"object "+JSON.stringify(i,null,2)),S))):St(E)?E=p(r.executeSubSelectedArray({field:y,array:E,enclosingRef:a,context:o}),w):y.selectionSet?E!=null&&(E=p(r.executeSelectionSet({selectionSet:y.selectionSet,objectOrReference:E,enclosingRef:Be(E)?E:a,context:o}),w)):o.canonizeResults&&(E=r.canon.pass(E)),E!==void 0&&f.push((b={},b[w]=E,b))}else{var R=rf(y,o.lookupFragment);if(!R&&y.kind===de.FRAGMENT_SPREAD)throw Ur(9,y.name.value);R&&u.fragmentMatches(R,c)&&R.selectionSet.selections.forEach(v.add,v)}});var _=of(f),m={result:_,missing:d},g=o.canonizeResults?this.canon.admit(m):Iu(m);return g.result&&this.knownResults.set(g.result,n),g},e.prototype.execSubSelectedArrayImpl=function(t){var r=this,n=t.field,i=t.array,a=t.enclosingRef,o=t.context,s,u=new na;function l(c,f){var d;return c.missing&&(s=u.merge(s,(d={},d[f]=c.missing,d))),c.result}return n.selectionSet&&(i=i.filter(o.store.canRead)),i=i.map(function(c,f){return c===null?null:St(c)?l(r.executeSubSelectedArray({field:n,array:c,enclosingRef:a,context:o}),f):n.selectionSet?l(r.executeSelectionSet({selectionSet:n.selectionSet,objectOrReference:c,enclosingRef:Be(c)?c:a,context:o}),f):(globalThis.__DEV__!==!1&&Dhe(o.store,n,c),c)}),{result:o.canonizeResults?this.canon.admit(i):i,missing:s}},e}();function $he(e){try{JSON.stringify(e,function(t,r){if(typeof r=="string")throw r;return r})}catch(t){return t}}function Dhe(e,t,r){if(!t.selectionSet){var n=new Set([r]);n.forEach(function(i){yt(i)&&(se(!Be(i),10,khe(e,i),t.name.value),Object.values(i).forEach(n.add,n))})}}var qv=new X4,sN=new WeakMap;function Zl(e){var t=sN.get(e);return t||sN.set(e,t={vars:new Set,dep:lW()}),t}function uN(e){Zl(e).vars.forEach(function(t){return t.forgetCache(e)})}function Nhe(e){Zl(e).vars.forEach(function(t){return t.attachCache(e)})}function MO(e){var t=new Set,r=new Set,n=function(a){if(arguments.length>0){if(e!==a){e=a,t.forEach(function(u){Zl(u).dep.dirty(n),Ahe(u)});var o=Array.from(r);r.clear(),o.forEach(function(u){return u(e)})}}else{var s=qv.getValue();s&&(i(s),Zl(s).dep(n))}return e};n.onNextChange=function(a){return r.add(a),function(){r.delete(a)}};var i=n.attachCache=function(a){return t.add(a),Zl(a).vars.add(n),n};return n.forgetCache=function(a){return t.delete(a)},n}function Ahe(e){e.broadcastWatches&&e.broadcastWatches()}var lN=Object.create(null);function FO(e){var t=JSON.stringify(e);return lN[t]||(lN[t]=Object.create(null))}function cN(e){var t=FO(e);return t.keyFieldsFn||(t.keyFieldsFn=function(r,n){var i=function(o,s){return n.readField(s,o)},a=n.keyObject=jO(e,function(o){var s=ru(n.storeObject,o,i);return s===void 0&&r!==n.storeObject&&Xt.call(r,o[0])&&(s=ru(r,o,LW)),se(s!==void 0,4,o.join("."),r),s});return"".concat(n.typename,":").concat(JSON.stringify(a))})}function fN(e){var t=FO(e);return t.keyArgsFn||(t.keyArgsFn=function(r,n){var i=n.field,a=n.variables,o=n.fieldName,s=jO(e,function(l){var c=l[0],f=c.charAt(0);if(f==="@"){if(i&&or(i.directives)){var d=c.slice(1),h=i.directives.find(function(m){return m.name.value===d}),p=h&&af(h,a);return p&&ru(p,l.slice(1))}return}if(f==="$"){var v=c.slice(1);if(a&&Xt.call(a,v)){var _=l.slice(0);return _[0]=v,ru(a,_)}return}if(r)return ru(r,l)}),u=JSON.stringify(s);return(r||u!=="{}")&&(o+=":"+u),o})}function jO(e,t){var r=new na;return AW(e).reduce(function(n,i){var a,o=t(i);if(o!==void 0){for(var s=i.length-1;s>=0;--s)o=(a={},a[i[s]]=o,a);n=r.merge(n,o)}return n},Object.create(null))}function AW(e){var t=FO(e);if(!t.paths){var r=t.paths=[],n=[];e.forEach(function(i,a){St(i)?(AW(i).forEach(function(o){return r.push(n.concat(o))}),n.length=0):(n.push(i),St(e[a+1])||(r.push(n.slice(0)),n.length=0))})}return t.paths}function LW(e,t){return e[t]}function ru(e,t,r){return r=r||LW,MW(t.reduce(function n(i,a){return St(i)?i.map(function(o){return n(o,a)}):i&&r(i,a)},e))}function MW(e){return yt(e)?St(e)?e.map(MW):jO(Object.keys(e).sort(),function(t){return ru(e,t)}):e}function FR(e){return e.args!==void 0?e.args:e.field?af(e.field,e.variables):null}var Lhe=function(){},dN=function(e,t){return t.fieldName},hN=function(e,t,r){var n=r.mergeObjects;return n(e,t)},pN=function(e,t){return t},FW=function(){function e(t){this.config=t,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=x({dataIdFromObject:jv},t),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),t.possibleTypes&&this.addPossibleTypes(t.possibleTypes),t.typePolicies&&this.addTypePolicies(t.typePolicies)}return e.prototype.identify=function(t,r){var n,i=this,a=r&&(r.typename||((n=r.storeObject)===null||n===void 0?void 0:n.__typename))||t.__typename;if(a===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];for(var o=r&&r.storeObject||t,s=x(x({},r),{typename:a,storeObject:o,readField:r&&r.readField||function(){var d=qO(arguments,o);return i.readField(d,{store:i.cache.data,variables:d.variables})}}),u,l=a&&this.getTypePolicy(a),c=l&&l.keyFn||this.config.dataIdFromObject;c;){var f=c(x(x({},t),o),s);if(St(f))c=cN(f);else{u=f;break}}return u=u?String(u):void 0,s.keyObject?[u,s.keyObject]:[u]},e.prototype.addTypePolicies=function(t){var r=this;Object.keys(t).forEach(function(n){var i=t[n],a=i.queryType,o=i.mutationType,s=i.subscriptionType,u=Zr(i,["queryType","mutationType","subscriptionType"]);a&&r.setRootTypename("Query",n),o&&r.setRootTypename("Mutation",n),s&&r.setRootTypename("Subscription",n),Xt.call(r.toBeAdded,n)?r.toBeAdded[n].push(u):r.toBeAdded[n]=[u]})},e.prototype.updateTypePolicy=function(t,r){var n=this,i=this.getTypePolicy(t),a=r.keyFields,o=r.fields;function s(u,l){u.merge=typeof l=="function"?l:l===!0?hN:l===!1?pN:u.merge}s(i,r.merge),i.keyFn=a===!1?Lhe:St(a)?cN(a):typeof a=="function"?a:i.keyFn,o&&Object.keys(o).forEach(function(u){var l=n.getFieldPolicy(t,u,!0),c=o[u];if(typeof c=="function")l.read=c;else{var f=c.keyArgs,d=c.read,h=c.merge;l.keyFn=f===!1?dN:St(f)?fN(f):typeof f=="function"?f:l.keyFn,typeof d=="function"&&(l.read=d),s(l,h)}l.read&&l.merge&&(l.keyFn=l.keyFn||dN)})},e.prototype.setRootTypename=function(t,r){r===void 0&&(r=t);var n="ROOT_"+t.toUpperCase(),i=this.rootTypenamesById[n];r!==i&&(se(!i||i===t,5,t),i&&delete this.rootIdsByTypename[i],this.rootIdsByTypename[r]=n,this.rootTypenamesById[n]=r)},e.prototype.addPossibleTypes=function(t){var r=this;this.usingPossibleTypes=!0,Object.keys(t).forEach(function(n){r.getSupertypeSet(n,!0),t[n].forEach(function(i){r.getSupertypeSet(i,!0).add(n);var a=i.match($W);(!a||a[0]!==i)&&r.fuzzySubtypes.set(i,new RegExp(i))})})},e.prototype.getTypePolicy=function(t){var r=this;if(!Xt.call(this.typePolicies,t)){var n=this.typePolicies[t]=Object.create(null);n.fields=Object.create(null);var i=this.supertypeMap.get(t);!i&&this.fuzzySubtypes.size&&(i=this.getSupertypeSet(t,!0),this.fuzzySubtypes.forEach(function(o,s){if(o.test(t)){var u=r.supertypeMap.get(s);u&&u.forEach(function(l){return i.add(l)})}})),i&&i.size&&i.forEach(function(o){var s=r.getTypePolicy(o),u=s.fields,l=Zr(s,["fields"]);Object.assign(n,l),Object.assign(n.fields,u)})}var a=this.toBeAdded[t];return a&&a.length&&a.splice(0).forEach(function(o){r.updateTypePolicy(t,o)}),this.typePolicies[t]},e.prototype.getFieldPolicy=function(t,r,n){if(t){var i=this.getTypePolicy(t).fields;return i[r]||n&&(i[r]=Object.create(null))}},e.prototype.getSupertypeSet=function(t,r){var n=this.supertypeMap.get(t);return!n&&r&&this.supertypeMap.set(t,n=new Set),n},e.prototype.fragmentMatches=function(t,r,n,i){var a=this;if(!t.typeCondition)return!0;if(!r)return!1;var o=t.typeCondition.name.value;if(r===o)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(o))for(var s=this.getSupertypeSet(r,!0),u=[s],l=function(p){var v=a.getSupertypeSet(p,!1);v&&v.size&&u.indexOf(v)<0&&u.push(v)},c=!!(n&&this.fuzzySubtypes.size),f=!1,d=0;d1?i:t}:(o=x({},n),Xt.call(o,"from")||(o.from=t)),globalThis.__DEV__!==!1&&o.from===void 0&&globalThis.__DEV__!==!1&&se.warn(7,lO(Array.from(e))),o.variables===void 0&&(o.variables=r),o}function jW(e){return function(r,n){if(St(r)||St(n))throw Ur(8);if(yt(r)&&yt(n)){var i=e.getFieldValue(r,"__typename"),a=e.getFieldValue(n,"__typename"),o=i&&a&&i!==a;if(o)return n;if(Be(r)&&Ws(n))return e.merge(r.__ref,n),r;if(Ws(r)&&Be(n))return e.merge(r,n.__ref),n;if(Ws(r)&&Ws(n))return x(x({},r),n)}return n}}function ey(e,t,r){var n="".concat(t).concat(r),i=e.flavors.get(n);return i||e.flavors.set(n,i=e.clientOnly===t&&e.deferred===r?e:x(x({},e),{clientOnly:t,deferred:r})),i}var Mhe=function(){function e(t,r,n){this.cache=t,this.reader=r,this.fragments=n}return e.prototype.writeToStore=function(t,r){var n=this,i=r.query,a=r.result,o=r.dataId,s=r.variables,u=r.overwrite,l=ls(i),c=Ohe();s=x(x({},Cv(l)),s);var f=x(x({store:t,written:Object.create(null),merge:function(h,p){return c.merge(h,p)},variables:s,varString:ln(s)},DW(i,this.fragments)),{overwrite:!!u,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),d=this.processSelectionSet({result:a||Object.create(null),dataId:o,selectionSet:l.selectionSet,mergeTree:{map:new Map},context:f});if(!Be(d))throw Ur(11,a);return f.incomingById.forEach(function(h,p){var v=h.storeObject,_=h.mergeTree,m=h.fieldNodeSet,g=zi(p);if(_&&_.map.size){var y=n.applyMerges(_,g,v,f);if(Be(y))return;v=y}if(globalThis.__DEV__!==!1&&!f.overwrite){var S=Object.create(null);m.forEach(function(w){w.selectionSet&&(S[w.name.value]=!0)});var b=function(w){return S[aa(w)]===!0},E=function(w){var R=_&&_.map.get(w);return!!(R&&R.info&&R.info.merge)};Object.keys(v).forEach(function(w){b(w)&&!E(w)&&Fhe(g,v,w,f.store)})}t.merge(p,v)}),t.retain(d.__ref),d},e.prototype.processSelectionSet=function(t){var r=this,n=t.dataId,i=t.result,a=t.selectionSet,o=t.context,s=t.mergeTree,u=this.cache.policies,l=Object.create(null),c=n&&u.rootTypenamesById[n]||Kh(i,a,o.fragmentMap)||n&&o.store.get(n,"__typename");typeof c=="string"&&(l.__typename=c);var f=function(){var y=qO(arguments,l,o.variables);if(Be(y.from)){var S=o.incomingById.get(y.from.__ref);if(S){var b=u.readField(x(x({},y),{from:S.storeObject}),o);if(b!==void 0)return b}}return u.readField(y,o)},d=new Set;this.flattenFields(a,i,o,c).forEach(function(y,S){var b,E=ta(S),w=i[E];if(d.add(S),w!==void 0){var R=u.getStoreFieldName({typename:c,fieldName:S.name.value,field:S,variables:y.variables}),O=mN(s,R),k=r.processFieldValue(w,S,S.selectionSet?ey(y,!1,!1):y,O),C=void 0;S.selectionSet&&(Be(k)||Ws(k))&&(C=f("__typename",k));var T=u.getMergeFunction(c,S.name.value,C);T?O.info={field:S,typename:c,merge:T}:gN(s,R),l=y.merge(l,(b={},b[R]=k,b))}else globalThis.__DEV__!==!1&&!y.clientOnly&&!y.deferred&&!Lv.added(S)&&!u.getReadFunction(c,S.name.value)&&globalThis.__DEV__!==!1&&se.error(12,ta(S),i)});try{var h=u.identify(i,{typename:c,selectionSet:a,fragmentMap:o.fragmentMap,storeObject:l,readField:f}),p=h[0],v=h[1];n=n||p,v&&(l=o.merge(l,v))}catch(y){if(!n)throw y}if(typeof n=="string"){var _=zi(n),m=o.written[n]||(o.written[n]=[]);if(m.indexOf(a)>=0||(m.push(a),this.reader&&this.reader.isFresh(i,_,a,o)))return _;var g=o.incomingById.get(n);return g?(g.storeObject=o.merge(g.storeObject,l),g.mergeTree=jR(g.mergeTree,s),d.forEach(function(y){return g.fieldNodeSet.add(y)})):o.incomingById.set(n,{storeObject:l,mergeTree:ip(s)?void 0:s,fieldNodeSet:d}),_}return l},e.prototype.processFieldValue=function(t,r,n,i){var a=this;return!r.selectionSet||t===null?globalThis.__DEV__!==!1?xO(t):t:St(t)?t.map(function(o,s){var u=a.processFieldValue(o,r,n,mN(i,s));return gN(i,s),u}):this.processSelectionSet({result:t,selectionSet:r.selectionSet,context:n,mergeTree:i})},e.prototype.flattenFields=function(t,r,n,i){i===void 0&&(i=Kh(r,t,n.fragmentMap));var a=new Map,o=this.cache.policies,s=new ss(!1);return function u(l,c){var f=s.lookup(l,c.clientOnly,c.deferred);f.visited||(f.visited=!0,l.selections.forEach(function(d){if(Ju(d,n.variables)){var h=c.clientOnly,p=c.deferred;if(!(h&&p)&&or(d.directives)&&d.directives.forEach(function(m){var g=m.name.value;if(g==="client"&&(h=!0),g==="defer"){var y=af(m,n.variables);(!y||y.if!==!1)&&(p=!0)}}),ra(d)){var v=a.get(d);v&&(h=h&&v.clientOnly,p=p&&v.deferred),a.set(d,ey(n,h,p))}else{var _=rf(d,n.lookupFragment);if(!_&&d.kind===de.FRAGMENT_SPREAD)throw Ur(13,d.name.value);_&&o.fragmentMatches(_,i,r,n.variables)&&u(_.selectionSet,ey(n,h,p))}}}))}(t,n),a},e.prototype.applyMerges=function(t,r,n,i,a){var o,s=this;if(t.map.size&&!Be(n)){var u=!St(n)&&(Be(r)||Ws(r))?r:void 0,l=n;u&&!a&&(a=[Be(u)?u.__ref:u]);var c,f=function(d,h){return St(d)?typeof h=="number"?d[h]:void 0:i.store.getFieldValue(d,String(h))};t.map.forEach(function(d,h){var p=f(u,h),v=f(l,h);if(v!==void 0){a&&a.push(h);var _=s.applyMerges(d,p,v,i,a);_!==v&&(c=c||new Map,c.set(h,_)),a&&se(a.pop()===h)}}),c&&(n=St(l)?l.slice(0):x({},l),c.forEach(function(d,h){n[h]=d}))}return t.info?this.cache.policies.runMergeFunction(r,n,t.info,i,a&&(o=i.store).getStorage.apply(o,a)):n},e}(),qW=[];function mN(e,t){var r=e.map;return r.has(t)||r.set(t,qW.pop()||{map:new Map}),r.get(t)}function jR(e,t){if(e===t||!t||ip(t))return e;if(!e||ip(e))return t;var r=e.info&&t.info?x(x({},e.info),t.info):e.info||t.info,n=e.map.size&&t.map.size,i=n?new Map:e.map.size?e.map:t.map,a={info:r,map:i};if(n){var o=new Set(t.map.keys());e.map.forEach(function(s,u){a.map.set(u,jR(s,t.map.get(u))),o.delete(u)}),o.forEach(function(s){a.map.set(s,jR(t.map.get(s),e.map.get(s)))})}return a}function ip(e){return!e||!(e.info||e.map.size)}function gN(e,t){var r=e.map,n=r.get(t);n&&ip(n)&&(qW.push(n),r.delete(t))}var _N=new Set;function Fhe(e,t,r,n){var i=function(f){var d=n.getFieldValue(f,r);return typeof d=="object"&&d},a=i(e);if(a){var o=i(t);if(o&&!Be(a)&&!Ae(a,o)&&!Object.keys(a).every(function(f){return n.getFieldValue(o,f)!==void 0})){var s=n.getFieldValue(e,"__typename")||n.getFieldValue(t,"__typename"),u=aa(r),l="".concat(s,".").concat(u);if(!_N.has(l)){_N.add(l);var c=[];!St(a)&&!St(o)&&[a,o].forEach(function(f){var d=n.getFieldValue(f,"__typename");typeof d=="string"&&!c.includes(d)&&c.push(d)}),globalThis.__DEV__!==!1&&se.warn(14,u,s,c.length?"either ensure all objects of type "+c.join(" and ")+" have an ID or a custom merge function, or ":"",l,a,o)}}}}var UO=function(e){Si(t,e);function t(r){r===void 0&&(r={});var n=e.call(this)||this;return n.watches=new Set,n.addTypenameTransform=new Nv(Lv),n.assumeImmutableResults=!0,n.makeVar=MO,n.txCount=0,n.config=The(r),n.addTypename=!!n.config.addTypename,n.policies=new FW({cache:n,dataIdFromObject:n.config.dataIdFromObject,possibleTypes:n.config.possibleTypes,typePolicies:n.config.typePolicies}),n.init(),n}return t.prototype.init=function(){var r=this.data=new xu.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=r.stump,this.resetResultCache()},t.prototype.resetResultCache=function(r){var n=this,i=this.storeReader,a=this.config.fragments;this.storeWriter=new Mhe(this,this.storeReader=new Che({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:CW(this.config),canon:r?void 0:i&&i.canon,fragments:a}),a),this.maybeBroadcastWatch=Va(function(o,s){return n.broadcastWatch(o,s)},{max:this.config.resultCacheMaxSize||qr["inMemoryCache.maybeBroadcastWatch"]||5e3,makeCacheKey:function(o){var s=o.optimistic?n.optimisticData:n.data;if(Xl(s)){var u=o.optimistic,l=o.id,c=o.variables;return s.makeCacheKey(o.query,o.callback,ln({optimistic:u,id:l,variables:c}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(o){return o.resetCaching()})},t.prototype.restore=function(r){return this.init(),r&&this.data.replace(r),this},t.prototype.extract=function(r){return r===void 0&&(r=!1),(r?this.optimisticData:this.data).extract()},t.prototype.read=function(r){var n=r.returnPartialData,i=n===void 0?!1:n;try{return this.storeReader.diffQueryAgainstStore(x(x({},r),{store:r.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:i})).result||null}catch(a){if(a instanceof Fv)return null;throw a}},t.prototype.write=function(r){try{return++this.txCount,this.storeWriter.writeToStore(this.data,r)}finally{!--this.txCount&&r.broadcast!==!1&&this.broadcastWatches()}},t.prototype.modify=function(r){if(Xt.call(r,"id")&&!r.id)return!1;var n=r.optimistic?this.optimisticData:this.data;try{return++this.txCount,n.modify(r.id||"ROOT_QUERY",r.fields)}finally{!--this.txCount&&r.broadcast!==!1&&this.broadcastWatches()}},t.prototype.diff=function(r){return this.storeReader.diffQueryAgainstStore(x(x({},r),{store:r.optimistic?this.optimisticData:this.data,rootId:r.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(r){var n=this;return this.watches.size||Nhe(this),this.watches.add(r),r.immediate&&this.maybeBroadcastWatch(r),function(){n.watches.delete(r)&&!n.watches.size&&uN(n),n.maybeBroadcastWatch.forget(r)}},t.prototype.gc=function(r){var n;ln.reset(),Zu.reset(),this.addTypenameTransform.resetCache(),(n=this.config.fragments)===null||n===void 0||n.resetCaches();var i=this.optimisticData.gc();return r&&!this.txCount&&(r.resetResultCache?this.resetResultCache(r.resetResultIdentities):r.resetResultIdentities&&this.storeReader.resetCanon()),i},t.prototype.retain=function(r,n){return(n?this.optimisticData:this.data).retain(r)},t.prototype.release=function(r,n){return(n?this.optimisticData:this.data).release(r)},t.prototype.identify=function(r){if(Be(r))return r.__ref;try{return this.policies.identify(r)[0]}catch(n){globalThis.__DEV__!==!1&&se.warn(n)}},t.prototype.evict=function(r){if(!r.id){if(Xt.call(r,"id"))return!1;r=x(x({},r),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(r,this.data)}finally{!--this.txCount&&r.broadcast!==!1&&this.broadcastWatches()}},t.prototype.reset=function(r){var n=this;return this.init(),ln.reset(),r&&r.discardWatches?(this.watches.forEach(function(i){return n.maybeBroadcastWatch.forget(i)}),this.watches.clear(),uN(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(r){var n=this.optimisticData.removeLayer(r);n!==this.optimisticData&&(this.optimisticData=n,this.broadcastWatches())},t.prototype.batch=function(r){var n=this,i=r.update,a=r.optimistic,o=a===void 0?!0:a,s=r.removeOptimistic,u=r.onWatchUpdated,l,c=function(d){var h=n,p=h.data,v=h.optimisticData;++n.txCount,d&&(n.data=n.optimisticData=d);try{return l=i(n)}finally{--n.txCount,n.data=p,n.optimisticData=v}},f=new Set;return u&&!this.txCount&&this.broadcastWatches(x(x({},r),{onWatchUpdated:function(d){return f.add(d),!1}})),typeof o=="string"?this.optimisticData=this.optimisticData.addLayer(o,c):o===!1?c(this.data):c(),typeof s=="string"&&(this.optimisticData=this.optimisticData.removeLayer(s)),u&&f.size?(this.broadcastWatches(x(x({},r),{onWatchUpdated:function(d,h){var p=u.call(this,d,h);return p!==!1&&f.delete(d),p}})),f.size&&f.forEach(function(d){return n.maybeBroadcastWatch.dirty(d)})):this.broadcastWatches(r),l},t.prototype.performTransaction=function(r,n){return this.batch({update:r,optimistic:n||n!==null})},t.prototype.transformDocument=function(r){return this.addTypenameToDocument(this.addFragmentsToDocument(r))},t.prototype.broadcastWatches=function(r){var n=this;this.txCount||this.watches.forEach(function(i){return n.maybeBroadcastWatch(i,r)})},t.prototype.addFragmentsToDocument=function(r){var n=this.config.fragments;return n?n.transform(r):r},t.prototype.addTypenameToDocument=function(r){return this.addTypename?this.addTypenameTransform.transformDocument(r):r},t.prototype.broadcastWatch=function(r,n){var i=r.lastDiff,a=this.diff(r);n&&(r.optimistic&&typeof n.optimistic=="string"&&(a.fromOptimisticTransaction=!0),n.onWatchUpdated&&n.onWatchUpdated.call(this,r,a,i)===!1)||(!i||!Ae(i.result,a.result))&&r.callback(r.lastDiff=a,i)},t}(Mv);globalThis.__DEV__!==!1&&(UO.prototype.getMemoryInternals=Lfe);function jhe(){for(var e=[],t=0;t0},t.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(r){return r.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},t.prototype.transformDocument=function(r){return this.queryManager.transform(r)},t}(Xe);CO(ap);function UW(e){var t=e.options,r=t.fetchPolicy,n=t.nextFetchPolicy;return r==="cache-and-network"||r==="network-only"?e.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(i,a){return this.nextFetchPolicy=n,typeof this.nextFetchPolicy=="function"?this.nextFetchPolicy(i,a):r}}):e.reobserve()}function Whe(e){globalThis.__DEV__!==!1&&se.error(23,e.message,e.stack)}function BW(e){globalThis.__DEV__!==!1&&e&&globalThis.__DEV__!==!1&&se.debug(24,e)}function ty(e){return e==="network-only"||e==="no-cache"||e==="standby"}var zW=function(){function e(t){var r=t.cache,n=t.client,i=t.resolvers,a=t.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=r,n&&(this.client=n),i&&this.addResolvers(i),a&&this.setFragmentMatcher(a)}return e.prototype.addResolvers=function(t){var r=this;this.resolvers=this.resolvers||{},Array.isArray(t)?t.forEach(function(n){r.resolvers=Ic(r.resolvers,n)}):this.resolvers=Ic(this.resolvers,t)},e.prototype.setResolvers=function(t){this.resolvers={},this.addResolvers(t)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(t){return Ta(this,arguments,void 0,function(r){var n=r.document,i=r.remoteResult,a=r.context,o=r.variables,s=r.onlyRunForcedResolvers,u=s===void 0?!1:s;return ka(this,function(l){return n?[2,this.resolveDocument(n,i.data,a,o,this.fragmentMatcher,u).then(function(c){return x(x({},i),{data:c.result})})]:[2,i]})})},e.prototype.setFragmentMatcher=function(t){this.fragmentMatcher=t},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(t){return to(["client"],t)&&this.resolvers?t:null},e.prototype.serverQuery=function(t){return wO(t)},e.prototype.prepareContext=function(t){var r=this.cache;return x(x({},t),{cache:r,getCacheKey:function(n){return r.identify(n)}})},e.prototype.addExportedVariables=function(t){return Ta(this,arguments,void 0,function(r,n,i){return n===void 0&&(n={}),i===void 0&&(i={}),ka(this,function(a){return r?[2,this.resolveDocument(r,this.buildRootValueFromCache(r,n)||{},this.prepareContext(i),n).then(function(o){return x(x({},n),o.exportedVariables)})]:[2,x({},n)]})})},e.prototype.shouldForceResolvers=function(t){var r=!1;return hn(t,{Directive:{enter:function(n){if(n.name.value==="client"&&n.arguments&&(r=n.arguments.some(function(i){return i.name.value==="always"&&i.value.kind==="BooleanValue"&&i.value.value===!0}),r))return pO}}}),r},e.prototype.buildRootValueFromCache=function(t,r){return this.cache.diff({query:fW(t),variables:r,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(t,r){return Ta(this,arguments,void 0,function(n,i,a,o,s,u){var l,c,f,d,h,p,v,_,m,g,y;return a===void 0&&(a={}),o===void 0&&(o={}),s===void 0&&(s=function(){return!0}),u===void 0&&(u=!1),ka(this,function(S){return l=Xu(n),c=Jo(n),f=tf(c),d=this.collectSelectionsToResolve(l,f),h=l.operation,p=h?h.charAt(0).toUpperCase()+h.slice(1):"Query",v=this,_=v.cache,m=v.client,g={fragmentMap:f,context:x(x({},a),{cache:_,client:m}),variables:o,fragmentMatcher:s,defaultOperationType:p,exportedVariables:{},selectionsToResolve:d,onlyRunForcedResolvers:u},y=!1,[2,this.resolveSelectionSet(l.selectionSet,y,i,g).then(function(b){return{result:b,exportedVariables:g.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(t,r,n,i){return Ta(this,void 0,void 0,function(){var a,o,s,u,l,c=this;return ka(this,function(f){return a=i.fragmentMap,o=i.context,s=i.variables,u=[n],l=function(d){return Ta(c,void 0,void 0,function(){var h,p;return ka(this,function(v){return!r&&!i.selectionsToResolve.has(d)?[2]:Ju(d,s)?ra(d)?[2,this.resolveField(d,r,n,i).then(function(_){var m;typeof _<"u"&&u.push((m={},m[ta(d)]=_,m))})]:(K4(d)?h=d:(h=a[d.name.value],se(h,18,d.name.value)),h&&h.typeCondition&&(p=h.typeCondition.name.value,i.fragmentMatcher(n,p,o))?[2,this.resolveSelectionSet(h.selectionSet,r,n,i).then(function(_){u.push(_)})]:[2]):[2]})})},[2,Promise.all(t.selections.map(l)).then(function(){return of(u)})]})})},e.prototype.resolveField=function(t,r,n,i){return Ta(this,void 0,void 0,function(){var a,o,s,u,l,c,f,d,h,p=this;return ka(this,function(v){return n?(a=i.variables,o=t.name.value,s=ta(t),u=o!==s,l=n[s]||n[o],c=Promise.resolve(l),(!i.onlyRunForcedResolvers||this.shouldForceResolvers(t))&&(f=n.__typename||i.defaultOperationType,d=this.resolvers&&this.resolvers[f],d&&(h=d[u?o:s],h&&(c=Promise.resolve(qv.withValue(this.cache,h,[n,af(t,a),i.context,{field:t,fragmentMap:i.fragmentMap}]))))),[2,c.then(function(_){var m,g;if(_===void 0&&(_=l),t.directives&&t.directives.forEach(function(S){S.name.value==="export"&&S.arguments&&S.arguments.forEach(function(b){b.name.value==="as"&&b.value.kind==="StringValue"&&(i.exportedVariables[b.value.value]=_)})}),!t.selectionSet||_==null)return _;var y=(g=(m=t.directives)===null||m===void 0?void 0:m.some(function(S){return S.name.value==="client"}))!==null&&g!==void 0?g:!1;if(Array.isArray(_))return p.resolveSubSelectedArray(t,r||y,_,i);if(t.selectionSet)return p.resolveSelectionSet(t.selectionSet,r||y,_,i)})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(t,r,n,i){var a=this;return Promise.all(n.map(function(o){if(o===null)return null;if(Array.isArray(o))return a.resolveSubSelectedArray(t,r,o,i);if(t.selectionSet)return a.resolveSelectionSet(t.selectionSet,r,o,i)}))},e.prototype.collectSelectionsToResolve=function(t,r){var n=function(o){return!Array.isArray(o)},i=this.selectionsToResolveCache;function a(o){if(!i.has(o)){var s=new Set;i.set(o,s),hn(o,{Directive:function(u,l,c,f,d){u.name.value==="client"&&d.forEach(function(h){n(h)&&LD(h)&&s.add(h)})},FragmentSpread:function(u,l,c,f,d){var h=r[u.name.value];se(h,19,u.name.value);var p=a(h);p.size>0&&(d.forEach(function(v){n(v)&&LD(v)&&s.add(v)}),s.add(u),p.forEach(function(v){s.add(v)}))}})}return i.get(o)}return a(t)},e}(),Gs=new(fa?WeakMap:Map);function ry(e,t){var r=e[t];typeof r=="function"&&(e[t]=function(){return Gs.set(e,(Gs.get(e)+1)%1e15),r.apply(this,arguments)})}function EN(e){e.notifyTimeout&&(clearTimeout(e.notifyTimeout),e.notifyTimeout=void 0)}var ny=function(){function e(t,r){r===void 0&&(r=t.generateQueryId()),this.queryId=r,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.stopped=!1,this.dirty=!1,this.observableQuery=null;var n=this.cache=t.cache;Gs.has(n)||(Gs.set(n,0),ry(n,"evict"),ry(n,"modify"),ry(n,"reset"))}return e.prototype.init=function(t){var r=t.networkStatus||Me.loading;return this.variables&&this.networkStatus!==Me.loading&&!Ae(this.variables,t.variables)&&(r=Me.setVariables),Ae(t.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:t.document,variables:t.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:r}),t.observableQuery&&this.setObservableQuery(t.observableQuery),t.lastRequestId&&(this.lastRequestId=t.lastRequestId),this},e.prototype.reset=function(){EN(this),this.dirty=!1},e.prototype.resetDiff=function(){this.lastDiff=void 0},e.prototype.getDiff=function(){var t=this.getDiffOptions();if(this.lastDiff&&Ae(t,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var r=this.observableQuery;if(r&&r.options.fetchPolicy==="no-cache")return{complete:!1};var n=this.cache.diff(t);return this.updateLastDiff(n,t),n},e.prototype.updateLastDiff=function(t,r){this.lastDiff=t?{diff:t,options:r||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(t){var r;return t===void 0&&(t=this.variables),{query:this.document,variables:t,returnPartialData:!0,optimistic:!0,canonizeResults:(r=this.observableQuery)===null||r===void 0?void 0:r.options.canonizeResults}},e.prototype.setDiff=function(t){var r=this,n,i=this.lastDiff&&this.lastDiff.diff;t&&!t.complete&&!(!((n=this.observableQuery)===null||n===void 0)&&n.options.returnPartialData)&&!(i&&i.complete)||(this.updateLastDiff(t),!this.dirty&&!Ae(i&&i.result,t&&t.result)&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return r.notify()},0))))},e.prototype.setObservableQuery=function(t){var r=this;t!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=t,t?(t.queryInfo=this,this.listeners.add(this.oqListener=function(){var n=r.getDiff();n.fromOptimisticTransaction?t.observe():UW(t)})):delete this.oqListener)},e.prototype.notify=function(){var t=this;EN(this),this.shouldNotify()&&this.listeners.forEach(function(r){return r(t)}),this.dirty=!1},e.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return!1;if(xc(this.networkStatus)&&this.observableQuery){var t=this.observableQuery.options.fetchPolicy;if(t!=="cache-only"&&t!=="cache-and-network")return!1}return!0},e.prototype.stop=function(){if(!this.stopped){this.stopped=!0,this.reset(),this.cancel(),this.cancel=e.prototype.cancel;var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){},e.prototype.updateWatch=function(t){var r=this;t===void 0&&(t=this.variables);var n=this.observableQuery;if(!(n&&n.options.fetchPolicy==="no-cache")){var i=x(x({},this.getDiffOptions(t)),{watcher:this,callback:function(a){return r.setDiff(a)}});(!this.lastWatch||!Ae(i,this.lastWatch))&&(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=i))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(t,r){var n=this.lastWrite;return!(n&&n.dmCount===Gs.get(this.cache)&&Ae(r,n.variables)&&Ae(t.data,n.result.data))},e.prototype.markResult=function(t,r,n,i){var a=this,o=new na,s=or(t.errors)?t.errors.slice(0):[];if(this.reset(),"incremental"in t&&or(t.incremental)){var u=$O(this.getDiff().result,t);t.data=u}else if("hasNext"in t&&t.hasNext){var l=this.getDiff();t.data=o.merge(l.result,t.data)}this.graphQLErrors=s,n.fetchPolicy==="no-cache"?this.updateLastDiff({result:t.data,complete:!0},this.getDiffOptions(n.variables)):i!==0&&(qR(t,n.errorPolicy)?this.cache.performTransaction(function(c){if(a.shouldWrite(t,n.variables))c.writeQuery({query:r,data:t.data,variables:n.variables,overwrite:i===1}),a.lastWrite={result:t,variables:n.variables,dmCount:Gs.get(a.cache)};else if(a.lastDiff&&a.lastDiff.diff.complete){t.data=a.lastDiff.diff.result;return}var f=a.getDiffOptions(n.variables),d=c.diff(f);!a.stopped&&Ae(a.variables,n.variables)&&a.updateWatch(n.variables),a.updateLastDiff(d,f),d.complete&&(t.data=d.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=Me.ready},e.prototype.markError=function(t){return this.networkStatus=Me.error,this.lastWrite=void 0,this.reset(),t.graphQLErrors&&(this.graphQLErrors=t.graphQLErrors),t.networkError&&(this.networkError=t.networkError),t},e}();function qR(e,t){t===void 0&&(t="none");var r=t==="ignore"||t==="all",n=!Jl(e);return!n&&r&&e.data&&(n=!0),n}var Ghe=Object.prototype.hasOwnProperty,wN=Object.create(null),Vhe=function(){function e(t){var r=t.cache,n=t.link,i=t.defaultOptions,a=t.documentTransform,o=t.queryDeduplication,s=o===void 0?!1:o,u=t.onBroadcast,l=t.ssrMode,c=l===void 0?!1:l,f=t.clientAwareness,d=f===void 0?{}:f,h=t.localState,p=t.assumeImmutableResults,v=p===void 0?!!r.assumeImmutableResults:p,_=t.defaultContext,m=this;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new nf(qr["queryManager.getDocumentInfo"]||2e3),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new ss(!1);var g=new Nv(function(y){return m.cache.transformDocument(y)},{cache:!1});this.cache=r,this.link=n,this.defaultOptions=i||Object.create(null),this.queryDeduplication=s,this.clientAwareness=d,this.localState=h||new zW({cache:r}),this.ssrMode=c,this.assumeImmutableResults=v,this.documentTransform=a?g.concat(a).concat(g):g,this.defaultContext=_||Object.create(null),(this.onBroadcast=u)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var t=this;this.queries.forEach(function(r,n){t.stopQueryNoBroadcast(n)}),this.cancelPendingFetches(Ur(25))},e.prototype.cancelPendingFetches=function(t){this.fetchCancelFns.forEach(function(r){return r(t)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(t){return Ta(this,arguments,void 0,function(r){var n,i,a,o,s,u,l,c=r.mutation,f=r.variables,d=r.optimisticResponse,h=r.updateQueries,p=r.refetchQueries,v=p===void 0?[]:p,_=r.awaitRefetchQueries,m=_===void 0?!1:_,g=r.update,y=r.onQueryUpdated,S=r.fetchPolicy,b=S===void 0?((u=this.defaultOptions.mutate)===null||u===void 0?void 0:u.fetchPolicy)||"network-only":S,E=r.errorPolicy,w=E===void 0?((l=this.defaultOptions.mutate)===null||l===void 0?void 0:l.errorPolicy)||"none":E,R=r.keepRootFields,O=r.context;return ka(this,function(k){switch(k.label){case 0:return se(c,26),se(b==="network-only"||b==="no-cache",27),n=this.generateMutationId(),c=this.cache.transformForLink(this.transform(c)),i=this.getDocumentInfo(c).hasClientExports,f=this.getVariables(c,f),i?[4,this.localState.addExportedVariables(c,f,O)]:[3,2];case 1:f=k.sent(),k.label=2;case 2:return a=this.mutationStore&&(this.mutationStore[n]={mutation:c,variables:f,loading:!0,error:null}),o=d&&this.markMutationOptimistic(d,{mutationId:n,document:c,variables:f,fetchPolicy:b,errorPolicy:w,context:O,updateQueries:h,update:g,keepRootFields:R}),this.broadcastQueries(),s=this,[2,new Promise(function(C,T){return Hd(s.getObservableFromLink(c,x(x({},O),{optimisticResponse:o?d:void 0}),f,!1),function($){if(Jl($)&&w==="none")throw new zn({graphQLErrors:ep($)});a&&(a.loading=!1,a.error=null);var L=x({},$);return typeof v=="function"&&(v=v(L)),w==="ignore"&&Jl(L)&&delete L.errors,s.markMutationResult({mutationId:n,result:L,document:c,variables:f,fetchPolicy:b,errorPolicy:w,context:O,update:g,updateQueries:h,awaitRefetchQueries:m,refetchQueries:v,removeOptimistic:o?n:void 0,onQueryUpdated:y,keepRootFields:R})}).subscribe({next:function($){s.broadcastQueries(),(!("hasNext"in $)||$.hasNext===!1)&&C($)},error:function($){a&&(a.loading=!1,a.error=$),o&&s.cache.removeOptimistic(n),s.broadcastQueries(),T($ instanceof zn?$:new zn({networkError:$}))}})})]}})})},e.prototype.markMutationResult=function(t,r){var n=this;r===void 0&&(r=this.cache);var i=t.result,a=[],o=t.fetchPolicy==="no-cache";if(!o&&qR(i,t.errorPolicy)){if(Bo(i)||a.push({result:i.data,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}),Bo(i)&&or(i.incremental)){var s=r.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0}),u=void 0;s.result&&(u=$O(s.result,i)),typeof u<"u"&&(i.data=u,a.push({result:u,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}))}var l=t.updateQueries;l&&this.queries.forEach(function(f,d){var h=f.observableQuery,p=h&&h.queryName;if(!(!p||!Ghe.call(l,p))){var v=l[p],_=n.queries.get(d),m=_.document,g=_.variables,y=r.diff({query:m,variables:g,returnPartialData:!0,optimistic:!1}),S=y.result,b=y.complete;if(b&&S){var E=v(S,{mutationResult:i,queryName:m&&Jh(m)||void 0,queryVariables:g});E&&a.push({result:E,dataId:"ROOT_QUERY",query:m,variables:g})}}})}if(a.length>0||(t.refetchQueries||"").length>0||t.update||t.onQueryUpdated||t.removeOptimistic){var c=[];if(this.refetchQueries({updateCache:function(f){o||a.forEach(function(v){return f.write(v)});var d=t.update,h=!_W(i)||Bo(i)&&!i.hasNext;if(d){if(!o){var p=f.diff({id:"ROOT_MUTATION",query:n.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0});p.complete&&(i=x(x({},i),{data:p.result}),"incremental"in i&&delete i.incremental,"hasNext"in i&&delete i.hasNext)}h&&d(f,i,{context:t.context,variables:t.variables})}!o&&!t.keepRootFields&&h&&f.modify({id:"ROOT_MUTATION",fields:function(v,_){var m=_.fieldName,g=_.DELETE;return m==="__typename"?v:g}})},include:t.refetchQueries,optimistic:!1,removeOptimistic:t.removeOptimistic,onQueryUpdated:t.onQueryUpdated||null}).forEach(function(f){return c.push(f)}),t.awaitRefetchQueries||t.onQueryUpdated)return Promise.all(c).then(function(){return i})}return Promise.resolve(i)},e.prototype.markMutationOptimistic=function(t,r){var n=this,i=typeof t=="function"?t(r.variables,{IGNORE:wN}):t;return i===wN?!1:(this.cache.recordOptimisticTransaction(function(a){try{n.markMutationResult(x(x({},r),{result:{data:i}}),a)}catch(o){globalThis.__DEV__!==!1&&se.error(o)}},r.mutationId),!0)},e.prototype.fetchQuery=function(t,r,n){return this.fetchConcastWithInfo(t,r,n).concast.promise},e.prototype.getQueryStore=function(){var t=Object.create(null);return this.queries.forEach(function(r,n){t[n]={variables:r.variables,networkStatus:r.networkStatus,networkError:r.networkError,graphQLErrors:r.graphQLErrors}}),t},e.prototype.resetErrors=function(t){var r=this.queries.get(t);r&&(r.networkError=void 0,r.graphQLErrors=[])},e.prototype.transform=function(t){return this.documentTransform.transformDocument(t)},e.prototype.getDocumentInfo=function(t){var r=this.transformCache;if(!r.has(t)){var n={hasClientExports:L4(t),hasForcedResolvers:this.localState.shouldForceResolvers(t),hasNonreactiveDirective:to(["nonreactive"],t),clientQuery:this.localState.clientQuery(t),serverQuery:Av([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"}],t),defaultVars:Cv(ls(t)),asQuery:x(x({},t),{definitions:t.definitions.map(function(i){return i.kind==="OperationDefinition"&&i.operation!=="query"?x(x({},i),{operation:"query"}):i})})};r.set(t,n)}return r.get(t)},e.prototype.getVariables=function(t,r){return x(x({},this.getDocumentInfo(t).defaultVars),r)},e.prototype.watchQuery=function(t){var r=this.transform(t.query);t=x(x({},t),{variables:this.getVariables(r,t.variables)}),typeof t.notifyOnNetworkStatusChange>"u"&&(t.notifyOnNetworkStatusChange=!1);var n=new ny(this),i=new ap({queryManager:this,queryInfo:n,options:t});return i.lastQuery=r,this.queries.set(i.queryId,n),n.init({document:r,observableQuery:i,variables:i.variables}),i},e.prototype.query=function(t,r){var n=this;return r===void 0&&(r=this.generateQueryId()),se(t.query,28),se(t.query.kind==="Document",29),se(!t.returnPartialData,30),se(!t.pollInterval,31),this.fetchQuery(r,x(x({},t),{query:this.transform(t.query)})).finally(function(){return n.stopQuery(r)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(t){this.stopQueryInStoreNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(t){var r=this.queries.get(t);r&&r.stop()},e.prototype.clearStore=function(t){return t===void 0&&(t={discardWatches:!0}),this.cancelPendingFetches(Ur(32)),this.queries.forEach(function(r){r.observableQuery?r.networkStatus=Me.loading:r.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(t)},e.prototype.getObservableQueries=function(t){var r=this;t===void 0&&(t="active");var n=new Map,i=new Map,a=new Set;return Array.isArray(t)&&t.forEach(function(o){typeof o=="string"?i.set(o,!1):Y4(o)?i.set(r.transform(o),!1):yt(o)&&o.query&&a.add(o)}),this.queries.forEach(function(o,s){var u=o.observableQuery,l=o.document;if(u){if(t==="all"){n.set(s,u);return}var c=u.queryName,f=u.options.fetchPolicy;if(f==="standby"||t==="active"&&!u.hasObservers())return;(t==="active"||c&&i.has(c)||l&&i.has(l))&&(n.set(s,u),c&&i.set(c,!0),l&&i.set(l,!0))}}),a.size&&a.forEach(function(o){var s=Qh("legacyOneTimeQuery"),u=r.getQuery(s).init({document:o.query,variables:o.variables}),l=new ap({queryManager:r,queryInfo:u,options:x(x({},o),{fetchPolicy:"network-only"})});se(l.queryId===s),u.setObservableQuery(l),n.set(s,l)}),globalThis.__DEV__!==!1&&i.size&&i.forEach(function(o,s){o||globalThis.__DEV__!==!1&&se.warn(typeof s=="string"?33:34,s)}),n},e.prototype.reFetchObservableQueries=function(t){var r=this;t===void 0&&(t=!1);var n=[];return this.getObservableQueries(t?"all":"active").forEach(function(i,a){var o=i.options.fetchPolicy;i.resetLastResults(),(t||o!=="standby"&&o!=="cache-only")&&n.push(i.refetch()),r.getQuery(a).setDiff(null)}),this.broadcastQueries(),Promise.all(n)},e.prototype.setObservableQuery=function(t){this.getQuery(t.queryId).setObservableQuery(t)},e.prototype.startGraphQLSubscription=function(t){var r=this,n=t.query,i=t.fetchPolicy,a=t.errorPolicy,o=a===void 0?"none":a,s=t.variables,u=t.context,l=u===void 0?{}:u;n=this.transform(n),s=this.getVariables(n,s);var c=function(d){return r.getObservableFromLink(n,l,d).map(function(h){i!=="no-cache"&&(qR(h,o)&&r.cache.write({query:n,result:h.data,dataId:"ROOT_SUBSCRIPTION",variables:d}),r.broadcastQueries());var p=Jl(h),v=che(h);if(p||v){var _={};if(p&&(_.graphQLErrors=h.errors),v&&(_.protocolErrors=h.extensions[NO]),o==="none"||v)throw new zn(_)}return o==="ignore"&&delete h.errors,h})};if(this.getDocumentInfo(n).hasClientExports){var f=this.localState.addExportedVariables(n,s,l).then(c);return new Xe(function(d){var h=null;return f.then(function(p){return h=p.subscribe(d)},d.error),function(){return h&&h.unsubscribe()}})}return c(s)},e.prototype.stopQuery=function(t){this.stopQueryNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(t){this.stopQueryInStoreNoBroadcast(t),this.removeQuery(t)},e.prototype.removeQuery=function(t){this.fetchCancelFns.delete(t),this.queries.has(t)&&(this.getQuery(t).stop(),this.queries.delete(t))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(t){return t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(t,r,n,i){var a=this,o;i===void 0&&(i=(o=r==null?void 0:r.queryDeduplication)!==null&&o!==void 0?o:this.queryDeduplication);var s,u=this.getDocumentInfo(t),l=u.serverQuery,c=u.clientQuery;if(l){var f=this,d=f.inFlightLinkObservables,h=f.link,p={query:l,variables:n,operationName:Jh(l)||void 0,context:this.prepareContext(x(x({},r),{forceFetch:!i}))};if(r=p.context,i){var v=Zu(l),_=ln(n),m=d.lookup(v,_);if(s=m.observable,!s){var g=new Oo([tp(h,p)]);s=m.observable=g,g.beforeNext(function(){d.remove(v,_)})}}else s=new Oo([tp(h,p)])}else s=new Oo([Xe.of({data:{}})]),r=this.prepareContext(r);return c&&(s=Hd(s,function(y){return a.localState.runResolvers({document:c,remoteResult:y,context:r,variables:n})})),s},e.prototype.getResultsFromLink=function(t,r,n){var i=t.lastRequestId=this.generateRequestId(),a=this.cache.transformForLink(n.query);return Hd(this.getObservableFromLink(a,n.context,n.variables),function(o){var s=ep(o),u=s.length>0;if(i>=t.lastRequestId){if(u&&n.errorPolicy==="none")throw t.markError(new zn({graphQLErrors:s}));t.markResult(o,a,n,r),t.markReady()}var l={data:o.data,loading:!1,networkStatus:Me.ready};return u&&n.errorPolicy!=="ignore"&&(l.errors=s,l.networkStatus=Me.error),l},function(o){var s=bW(o)?o:new zn({networkError:o});throw i>=t.lastRequestId&&t.markError(s),s})},e.prototype.fetchConcastWithInfo=function(t,r,n,i){var a=this;n===void 0&&(n=Me.loading),i===void 0&&(i=r.query);var o=this.getVariables(i,r.variables),s=this.getQuery(t),u=this.defaultOptions.watchQuery,l=r.fetchPolicy,c=l===void 0?u&&u.fetchPolicy||"cache-first":l,f=r.errorPolicy,d=f===void 0?u&&u.errorPolicy||"none":f,h=r.returnPartialData,p=h===void 0?!1:h,v=r.notifyOnNetworkStatusChange,_=v===void 0?!1:v,m=r.context,g=m===void 0?{}:m,y=Object.assign({},r,{query:i,variables:o,fetchPolicy:c,errorPolicy:d,returnPartialData:p,notifyOnNetworkStatusChange:_,context:g}),S=function(O){y.variables=O;var k=a.fetchQueryByPolicy(s,y,n);return y.fetchPolicy!=="standby"&&k.sources.length>0&&s.observableQuery&&s.observableQuery.applyNextFetchPolicy("after-fetch",r),k},b=function(){return a.fetchCancelFns.delete(t)};this.fetchCancelFns.set(t,function(O){b(),setTimeout(function(){return E.cancel(O)})});var E,w;if(this.getDocumentInfo(y.query).hasClientExports)E=new Oo(this.localState.addExportedVariables(y.query,y.variables,y.context).then(S).then(function(O){return O.sources})),w=!0;else{var R=S(y.variables);w=R.fromLink,E=new Oo(R.sources)}return E.promise.then(b,b),{concast:E,fromLink:w}},e.prototype.refetchQueries=function(t){var r=this,n=t.updateCache,i=t.include,a=t.optimistic,o=a===void 0?!1:a,s=t.removeOptimistic,u=s===void 0?o?Qh("refetchQueries"):void 0:s,l=t.onQueryUpdated,c=new Map;i&&this.getObservableQueries(i).forEach(function(d,h){c.set(h,{oq:d,lastDiff:r.getQuery(h).getDiff()})});var f=new Map;return n&&this.cache.batch({update:n,optimistic:o&&u||!1,removeOptimistic:u,onWatchUpdated:function(d,h,p){var v=d.watcher instanceof ny&&d.watcher.observableQuery;if(v){if(l){c.delete(v.queryId);var _=l(v,h,p);return _===!0&&(_=v.refetch()),_!==!1&&f.set(v,_),_}l!==null&&c.set(v.queryId,{oq:v,lastDiff:p,diff:h})}}}),c.size&&c.forEach(function(d,h){var p=d.oq,v=d.lastDiff,_=d.diff,m;if(l){if(!_){var g=p.queryInfo;g.reset(),_=g.getDiff()}m=l(p,_,v)}(!l||m===!0)&&(m=p.refetch()),m!==!1&&f.set(p,m),h.indexOf("legacyOneTimeQuery")>=0&&r.stopQueryNoBroadcast(h)}),u&&this.cache.removeOptimistic(u),f},e.prototype.fetchQueryByPolicy=function(t,r,n){var i=this,a=r.query,o=r.variables,s=r.fetchPolicy,u=r.refetchWritePolicy,l=r.errorPolicy,c=r.returnPartialData,f=r.context,d=r.notifyOnNetworkStatusChange,h=t.networkStatus;t.init({document:a,variables:o,networkStatus:n});var p=function(){return t.getDiff()},v=function(S,b){b===void 0&&(b=t.networkStatus||Me.loading);var E=S.result;globalThis.__DEV__!==!1&&!c&&!Ae(E,{})&&BW(S.missing);var w=function(R){return Xe.of(x({data:R,loading:xc(b),networkStatus:b},S.complete?null:{partial:!0}))};return E&&i.getDocumentInfo(a).hasForcedResolvers?i.localState.runResolvers({document:a,remoteResult:{data:E},context:f,variables:o,onlyRunForcedResolvers:!0}).then(function(R){return w(R.data||void 0)}):l==="none"&&b===Me.refetch&&Array.isArray(S.missing)?w(void 0):w(E)},_=s==="no-cache"?0:n===Me.refetch&&u!=="merge"?1:2,m=function(){return i.getResultsFromLink(t,_,{query:a,variables:o,context:f,fetchPolicy:s,errorPolicy:l})},g=d&&typeof h=="number"&&h!==n&&xc(n);switch(s){default:case"cache-first":{var y=p();return y.complete?{fromLink:!1,sources:[v(y,t.markReady())]}:c||g?{fromLink:!0,sources:[v(y),m()]}:{fromLink:!0,sources:[m()]}}case"cache-and-network":{var y=p();return y.complete||c||g?{fromLink:!0,sources:[v(y),m()]}:{fromLink:!0,sources:[m()]}}case"cache-only":return{fromLink:!1,sources:[v(p(),t.markReady())]};case"network-only":return g?{fromLink:!0,sources:[v(p()),m()]}:{fromLink:!0,sources:[m()]};case"no-cache":return g?{fromLink:!0,sources:[v(t.getDiff()),m()]}:{fromLink:!0,sources:[m()]};case"standby":return{fromLink:!1,sources:[]}}},e.prototype.getQuery=function(t){return t&&!this.queries.has(t)&&this.queries.set(t,new ny(this,t)),this.queries.get(t)},e.prototype.prepareContext=function(t){t===void 0&&(t={});var r=this.localState.prepareContext(t);return x(x(x({},this.defaultContext),r),{clientAwareness:this.clientAwareness})},e}(),RN=!1,HW=function(){function e(t){var r=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!t.cache)throw Ur(15);var n=t.uri,i=t.credentials,a=t.headers,o=t.cache,s=t.documentTransform,u=t.ssrMode,l=u===void 0?!1:u,c=t.ssrForceFetchDelay,f=c===void 0?0:c,d=t.connectToDevTools,h=d===void 0?typeof window=="object"&&!window.__APOLLO_CLIENT__&&globalThis.__DEV__!==!1:d,p=t.queryDeduplication,v=p===void 0?!0:p,_=t.defaultOptions,m=t.defaultContext,g=t.assumeImmutableResults,y=g===void 0?o.assumeImmutableResults:g,S=t.resolvers,b=t.typeDefs,E=t.fragmentMatcher,w=t.name,R=t.version,O=t.link;O||(O=n?new IW({uri:n,credentials:i,headers:a}):Nn.empty()),this.link=O,this.cache=o,this.disableNetworkFetches=l||f>0,this.queryDeduplication=v,this.defaultOptions=_||Object.create(null),this.typeDefs=b,f&&setTimeout(function(){return r.disableNetworkFetches=!1},f),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version=uO,this.localState=new zW({cache:o,client:this,resolvers:S,fragmentMatcher:E}),this.queryManager=new Vhe({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,defaultContext:m,documentTransform:s,queryDeduplication:v,ssrMode:l,clientAwareness:{name:w,version:R},localState:this.localState,assumeImmutableResults:y,onBroadcast:h?function(){r.devToolsHookCb&&r.devToolsHookCb({action:{},state:{queries:r.queryManager.getQueryStore(),mutations:r.queryManager.mutationStore||{}},dataWithOptimisticResults:r.cache.extract(!0)})}:void 0}),h&&this.connectToDevTools()}return e.prototype.connectToDevTools=function(){if(typeof window=="object"){var t=window,r=Symbol.for("apollo.devtools");(t[r]=t[r]||[]).push(this),t.__APOLLO_CLIENT__=this}!RN&&globalThis.__DEV__!==!1&&(RN=!0,setTimeout(function(){if(typeof window<"u"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var n=window.navigator,i=n&&n.userAgent,a=void 0;typeof i=="string"&&(i.indexOf("Chrome/")>-1?a="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":i.indexOf("Firefox/")>-1&&(a="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),a&&globalThis.__DEV__!==!1&&se.log("Download the Apollo DevTools for a better development experience: %s",a)}},1e4))},Object.defineProperty(e.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform},enumerable:!1,configurable:!0}),e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(t){return this.defaultOptions.watchQuery&&(t=Hi(this.defaultOptions.watchQuery,t)),this.disableNetworkFetches&&(t.fetchPolicy==="network-only"||t.fetchPolicy==="cache-and-network")&&(t=x(x({},t),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(t)},e.prototype.query=function(t){return this.defaultOptions.query&&(t=Hi(this.defaultOptions.query,t)),se(t.fetchPolicy!=="cache-and-network",16),this.disableNetworkFetches&&t.fetchPolicy==="network-only"&&(t=x(x({},t),{fetchPolicy:"cache-first"})),this.queryManager.query(t)},e.prototype.mutate=function(t){return this.defaultOptions.mutate&&(t=Hi(this.defaultOptions.mutate,t)),this.queryManager.mutate(t)},e.prototype.subscribe=function(t){return this.queryManager.startGraphQLSubscription(t)},e.prototype.readQuery=function(t,r){return r===void 0&&(r=!1),this.cache.readQuery(t,r)},e.prototype.readFragment=function(t,r){return r===void 0&&(r=!1),this.cache.readFragment(t,r)},e.prototype.writeQuery=function(t){var r=this.cache.writeQuery(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),r},e.prototype.writeFragment=function(t){var r=this.cache.writeFragment(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),r},e.prototype.__actionHookForDevTools=function(t){this.devToolsHookCb=t},e.prototype.__requestRaw=function(t){return tp(this.link,t)},e.prototype.resetStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(t.resetStoreCallbacks.map(function(r){return r()}))}).then(function(){return t.reFetchObservableQueries()})},e.prototype.clearStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(t.clearStoreCallbacks.map(function(r){return r()}))})},e.prototype.onResetStore=function(t){var r=this;return this.resetStoreCallbacks.push(t),function(){r.resetStoreCallbacks=r.resetStoreCallbacks.filter(function(n){return n!==t})}},e.prototype.onClearStore=function(t){var r=this;return this.clearStoreCallbacks.push(t),function(){r.clearStoreCallbacks=r.clearStoreCallbacks.filter(function(n){return n!==t})}},e.prototype.reFetchObservableQueries=function(t){return this.queryManager.reFetchObservableQueries(t)},e.prototype.refetchQueries=function(t){var r=this.queryManager.refetchQueries(t),n=[],i=[];r.forEach(function(o,s){n.push(s),i.push(o)});var a=Promise.all(i);return a.queries=n,a.results=i,a.catch(function(o){globalThis.__DEV__!==!1&&se.debug(17,o)}),a},e.prototype.getObservableQueries=function(t){return t===void 0&&(t="active"),this.queryManager.getObservableQueries(t)},e.prototype.extract=function(t){return this.cache.extract(t)},e.prototype.restore=function(t){return this.cache.restore(t)},e.prototype.addResolvers=function(t){this.localState.addResolvers(t)},e.prototype.setResolvers=function(t){this.localState.setResolvers(t)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(t){this.localState.setFragmentMatcher(t)},e.prototype.setLink=function(t){this.link=this.queryManager.link=t},Object.defineProperty(e.prototype,"defaultContext",{get:function(){return this.queryManager.defaultContext},enumerable:!1,configurable:!0}),e}();globalThis.__DEV__!==!1&&(HW.prototype.getMemoryInternals=Afe);var Yd=new Map,UR=new Map,WW=!0,op=!1;function GW(e){return e.replace(/[\s,]+/g," ").trim()}function Yhe(e){return GW(e.source.body.substring(e.start,e.end))}function Qhe(e){var t=new Set,r=[];return e.definitions.forEach(function(n){if(n.kind==="FragmentDefinition"){var i=n.name.value,a=Yhe(n.loc),o=UR.get(i);o&&!o.has(a)?WW&&console.warn("Warning: fragment with name "+i+` already exists. graphql-tag enforces all fragment names across your application to be unique; read more about this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):o||UR.set(i,o=new Set),o.add(a),t.has(a)||(t.add(a),r.push(n))}else r.push(n)}),x(x({},e),{definitions:r})}function Khe(e){var t=new Set(e.definitions);t.forEach(function(n){n.loc&&delete n.loc,Object.keys(n).forEach(function(i){var a=n[i];a&&typeof a=="object"&&t.add(a)})});var r=e.loc;return r&&(delete r.startToken,delete r.endToken),e}function Jhe(e){var t=GW(e);if(!Yd.has(t)){var r=lfe(e,{experimentalFragmentVariables:op,allowLegacyFragmentVariables:op});if(!r||r.kind!=="Document")throw new Error("Not a valid GraphQL document.");Yd.set(t,Khe(Qhe(r)))}return Yd.get(t)}function Xo(e){for(var t=[],r=1;r0?new zn({graphQLErrors:b}):void 0,w=l.onError||((g=o.current.options)===null||g===void 0?void 0:g.onError);if(E&&w&&w(E,_),v===o.current.mutationId&&!_.ignoreResults){var R={called:!0,loading:!1,data:S,error:E,client:p};o.current.isMounted&&!Ae(o.current.result,R)&&a(o.current.result=R)}var O=l.onCompleted||((y=o.current.options)===null||y===void 0?void 0:y.onCompleted);return E||O==null||O(m.data,_),m}).catch(function(m){var g;if(v===o.current.mutationId&&o.current.isMounted){var y={loading:!1,error:m,data:void 0,called:!0,client:p};Ae(o.current.result,y)||a(o.current.result=y)}var S=l.onError||((g=o.current.options)===null||g===void 0?void 0:g.onError);if(S)return S(m,_),{data:void 0,errors:m};throw m})},[]),u=oe.useCallback(function(){if(o.current.isMounted){var l={called:!1,loading:!1,client:r};Object.assign(o.current,{mutationId:0,result:l}),a(l)}},[]);return oe.useEffect(function(){return o.current.isMounted=!0,function(){o.current.isMounted=!1}},[]),[s,x({reset:u},i)]}function mpe(e,t){var r=oe.useRef(!1),n=gn(t==null?void 0:t.client);Bv(e,cn.Subscription);var i=oe.useState({loading:!(t!=null&&t.skip),error:void 0,data:void 0,variables:t==null?void 0:t.variables}),a=i[0],o=i[1];r.current||(r.current=!0,t!=null&&t.onSubscriptionData&&globalThis.__DEV__!==!1&&se.warn(t.onData?52:53),t!=null&&t.onSubscriptionComplete&&globalThis.__DEV__!==!1&&se.warn(t.onComplete?54:55));var s=oe.useState(function(){return t!=null&&t.skip?null:n.subscribe({query:e,variables:t==null?void 0:t.variables,fetchPolicy:t==null?void 0:t.fetchPolicy,context:t==null?void 0:t.context})}),u=s[0],l=s[1],c=oe.useRef(!1);oe.useEffect(function(){return function(){c.current=!0}},[]);var f=oe.useRef({client:n,subscription:e,options:t});return oe.useEffect(function(){var d,h,p,v,_=t==null?void 0:t.shouldResubscribe;typeof _=="function"&&(_=!!_(t)),t!=null&&t.skip?(!(t!=null&&t.skip)!=!(!((d=f.current.options)===null||d===void 0)&&d.skip)||c.current)&&(o({loading:!1,data:void 0,error:void 0,variables:t==null?void 0:t.variables}),l(null),c.current=!1):(_!==!1&&(n!==f.current.client||e!==f.current.subscription||(t==null?void 0:t.fetchPolicy)!==((h=f.current.options)===null||h===void 0?void 0:h.fetchPolicy)||!(t!=null&&t.skip)!=!(!((p=f.current.options)===null||p===void 0)&&p.skip)||!Ae(t==null?void 0:t.variables,(v=f.current.options)===null||v===void 0?void 0:v.variables))||c.current)&&(o({loading:!0,data:void 0,error:void 0,variables:t==null?void 0:t.variables}),l(n.subscribe({query:e,variables:t==null?void 0:t.variables,fetchPolicy:t==null?void 0:t.fetchPolicy,context:t==null?void 0:t.context})),c.current=!1),Object.assign(f.current,{client:n,subscription:e,options:t})},[n,e,t,c.current]),oe.useEffect(function(){if(u){var d=!1,h=u.subscribe({next:function(p){var v,_;if(!d){var m={loading:!1,data:p.data,error:void 0,variables:t==null?void 0:t.variables};o(m),!((v=f.current.options)===null||v===void 0)&&v.onData?f.current.options.onData({client:n,data:m}):!((_=f.current.options)===null||_===void 0)&&_.onSubscriptionData&&f.current.options.onSubscriptionData({client:n,subscriptionData:m})}},error:function(p){var v,_;d||(o({loading:!1,data:void 0,error:p,variables:t==null?void 0:t.variables}),(_=(v=f.current.options)===null||v===void 0?void 0:v.onError)===null||_===void 0||_.call(v,p))},complete:function(){var p,v;d||(!((p=f.current.options)===null||p===void 0)&&p.onComplete?f.current.options.onComplete():!((v=f.current.options)===null||v===void 0)&&v.onSubscriptionComplete&&f.current.options.onSubscriptionComplete())}});return function(){d=!0,setTimeout(function(){h.unsubscribe()})}}},[u]),a}function gpe(e){return Uv(oe.useCallback(function(t){return e.onNextChange(function r(){t(),e.onNextChange(r)})},[e]),e,e)}function _pe(e){return sf("useFragment",ype,gn(e.client))(e)}function ype(e){var t=gn(e.client).cache,r=XW(function(){var a=e.fragment,o=e.fragmentName,s=e.from,u=e.optimistic,l=u===void 0?!0:u,c=Zr(e,["fragment","fragmentName","from","optimistic"]);return x(x({},c),{returnPartialData:!0,id:typeof s=="string"?s:t.identify(s),query:t.getFragmentDoc(a,o),optimistic:l})},[e]),n=ape(function(){return oy(t.diff(r))});oe.useMemo(function(){n.current=oy(t.diff(r))},[r,t]);var i=oe.useCallback(function(){return n.current},[]);return Uv(oe.useCallback(function(a){var o=0,s=t.watch(x(x({},r),{immediate:!0,callback:function(u){Ae(u.result,n.current.data)||(n.current=oy(u),clearTimeout(o),o=setTimeout(a))}}));return function(){s(),clearTimeout(o)}},[t,r]),i,i)}function oy(e){var t={data:e.result,complete:!!e.complete};return e.missing&&(t.missing=of(e.missing.map(function(r){return r.missing}))),t}var t5=Symbol(),HO=Symbol();function pi(e){var t,r=(t={toPromise:function(){return WO(r).then(function(){return r})}},t[t5]=e,t[HO]=e.promise,t);return r}function WO(e){var t=tl(e);return t.promise.status==="fulfilled"?t.promise:e[HO]}function tl(e){return e[t5]}function Cc(e,t){e[HO]=t}var Spe=["canonizeResults","context","errorPolicy","fetchPolicy","refetchWritePolicy","returnPartialData"],r5=function(){function e(t,r){var n=this;this.key={},this.listeners=new Set,this.references=0,this.softReferences=0,this.handleNext=this.handleNext.bind(this),this.handleError=this.handleError.bind(this),this.dispose=this.dispose.bind(this),this.observable=t,r.onDispose&&(this.onDispose=r.onDispose),this.setResult(),this.subscribeToQuery();var i=function(){var a;n.references||(n.autoDisposeTimeoutId=setTimeout(n.dispose,(a=r.autoDisposeTimeoutMs)!==null&&a!==void 0?a:3e4))};this.promise.then(i,i)}return Object.defineProperty(e.prototype,"disposed",{get:function(){return this.subscription.closed},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"watchQueryOptions",{get:function(){return this.observable.options},enumerable:!1,configurable:!0}),e.prototype.reinitialize=function(){var t=this.observable,r=this.watchQueryOptions.fetchPolicy;try{if(r!=="no-cache"?(t.resetLastResults(),t.silentSetOptions({fetchPolicy:"cache-first"})):t.silentSetOptions({fetchPolicy:"standby"}),this.subscribeToQuery(),r==="no-cache")return;t.resetDiff(),this.setResult()}finally{t.silentSetOptions({fetchPolicy:r})}},e.prototype.retain=function(){var t=this;this.references++,clearTimeout(this.autoDisposeTimeoutId);var r=!1;return function(){r||(r=!0,t.references--,setTimeout(function(){t.references||t.dispose()}))}},e.prototype.softRetain=function(){var t=this;this.softReferences++;var r=!1;return function(){r||(r=!0,t.softReferences--,setTimeout(function(){!t.softReferences&&!t.references&&t.dispose()}))}},e.prototype.didChangeOptions=function(t){var r=this;return Spe.some(function(n){return n in t&&!Ae(r.watchQueryOptions[n],t[n])})},e.prototype.applyOptions=function(t){var r=this.watchQueryOptions,n=r.fetchPolicy,i=r.canonizeResults;return n==="standby"&&n!==t.fetchPolicy?this.initiateFetch(this.observable.reobserve(t)):(this.observable.silentSetOptions(t),i!==t.canonizeResults&&(this.result=x(x({},this.result),this.observable.getCurrentResult()),this.promise=zd(this.result))),this.promise},e.prototype.listen=function(t){var r=this;return this.listeners.add(t),function(){r.listeners.delete(t)}},e.prototype.refetch=function(t){return this.initiateFetch(this.observable.refetch(t))},e.prototype.fetchMore=function(t){return this.initiateFetch(this.observable.fetchMore(t))},e.prototype.dispose=function(){this.subscription.unsubscribe(),this.onDispose()},e.prototype.onDispose=function(){},e.prototype.handleNext=function(t){var r;switch(this.promise.status){case"pending":{t.data===void 0&&(t.data=this.result.data),this.result=t,(r=this.resolve)===null||r===void 0||r.call(this,t);break}default:{if(t.data===this.result.data&&t.networkStatus===this.result.networkStatus)return;t.data===void 0&&(t.data=this.result.data),this.result=t,this.promise=zd(t),this.deliver(this.promise);break}}},e.prototype.handleError=function(t){var r;switch(this.subscription.unsubscribe(),this.subscription=this.observable.resubscribeAfterError(this.handleNext,this.handleError),this.promise.status){case"pending":{(r=this.reject)===null||r===void 0||r.call(this,t);break}default:this.promise=vW(t),this.deliver(this.promise)}},e.prototype.deliver=function(t){this.listeners.forEach(function(r){return r(t)})},e.prototype.initiateFetch=function(t){var r=this;return this.promise=this.createPendingPromise(),this.promise.catch(function(){}),t.then(function(){setTimeout(function(){var n;r.promise.status==="pending"&&(r.result=r.observable.getCurrentResult(),(n=r.resolve)===null||n===void 0||n.call(r,r.result))})}).catch(function(){}),t},e.prototype.subscribeToQuery=function(){var t=this;this.subscription=this.observable.filter(function(r){return!Ae(r.data,{})&&!Ae(r,t.result)}).subscribe(this.handleNext,this.handleError)},e.prototype.setResult=function(){var t=this.observable.getCurrentResult(!1);Ae(t,this.result)||(this.result=t,this.promise=t.data&&(!t.partial||this.watchQueryOptions.returnPartialData)?zd(t):this.createPendingPromise())},e.prototype.createPendingPromise=function(){var t=this;return IO(new Promise(function(r,n){t.resolve=r,t.reject=n}))},e}(),bpe=function(){function e(t){t===void 0&&(t=Object.create(null)),this.queryRefs=new ss(fa),this.options=t}return e.prototype.getQueryRef=function(t,r){var n=this.queryRefs.lookupArray(t);return n.current||(n.current=new r5(r(),{autoDisposeTimeoutMs:this.options.autoDisposeTimeoutMs,onDispose:function(){delete n.current}})),n.current},e}(),sy=Symbol.for("apollo.suspenseCache");function GO(e){var t;return e[sy]||(e[sy]=new bpe((t=e.defaultOptions.react)===null||t===void 0?void 0:t.suspense)),e[sy]}var n5=Symbol.for("apollo.skipToken");function Epe(e,t){return t===void 0&&(t=Object.create(null)),sf("useSuspenseQuery",wpe,gn(typeof t=="object"?t.client:void 0))(e,t)}function wpe(e,t){var r=gn(t.client),n=GO(r),i=VO({client:r,query:e,options:t}),a=i.fetchPolicy,o=i.variables,s=t.queryKey,u=s===void 0?[]:s,l=Dt([e,ln(o)],[].concat(u),!0),c=n.getQueryRef(l,function(){return r.watchQuery(i)}),f=oe.useState([c.key,c.promise]),d=f[0],h=f[1];d[0]!==c.key&&(d[0]=c.key,d[1]=c.promise);var p=d[1];c.didChangeOptions(i)&&(d[1]=p=c.applyOptions(i)),oe.useEffect(function(){var S=c.retain(),b=c.listen(function(E){h([c.key,E])});return function(){b(),S()}},[c]);var v=oe.useMemo(function(){var S=zR(c.result);return{loading:!1,data:c.result.data,networkStatus:S?Me.error:Me.ready,error:S}},[c.result]),_=a==="standby"?v:ZW(p),m=oe.useCallback(function(S){var b=c.fetchMore(S);return h([c.key,c.promise]),b},[c]),g=oe.useCallback(function(S){var b=c.refetch(S);return h([c.key,c.promise]),b},[c]),y=oe.useCallback(function(S){return c.observable.subscribeToMore(S)},[c]);return oe.useMemo(function(){return{client:r,data:_.data,error:zR(_),networkStatus:_.networkStatus,fetchMore:m,refetch:g,subscribeToMore:y}},[r,m,g,_,y])}function Rpe(e){var t=e.query,r=e.fetchPolicy,n=e.returnPartialData;Bv(t,cn.Query),Tpe(r),kpe(r,n)}function Tpe(e){e===void 0&&(e="cache-first");var t=["cache-first","network-only","no-cache","cache-and-network"];se(t.includes(e),56,e)}function kpe(e,t){e==="no-cache"&&t&&globalThis.__DEV__!==!1&&se.warn(57)}function zR(e){return or(e.errors)?new zn({graphQLErrors:e.errors}):e.error}function VO(e){var t=e.client,r=e.query,n=e.options;return XW(function(){var i;if(n===n5)return{query:r,fetchPolicy:"standby"};var a=n.fetchPolicy||((i=t.defaultOptions.watchQuery)===null||i===void 0?void 0:i.fetchPolicy)||"cache-first",o=x(x({},n),{fetchPolicy:a,query:r,notifyOnNetworkStatusChange:!1,nextFetchPolicy:void 0});return globalThis.__DEV__!==!1&&Rpe(o),n.skip&&(o.fetchPolicy="standby"),o},[t,n,r])}function Ope(e,t){return t===void 0&&(t=Object.create(null)),sf("useBackgroundQuery",Ppe,gn(typeof t=="object"?t.client:void 0))(e,t)}function Ppe(e,t){var r=gn(t.client),n=GO(r),i=VO({client:r,query:e,options:t}),a=i.fetchPolicy,o=i.variables,s=t.queryKey,u=s===void 0?[]:s,l=oe.useRef(a!=="standby");l.current||(l.current=a!=="standby");var c=Dt([e,ln(o)],[].concat(u),!0),f=n.getQueryRef(c,function(){return r.watchQuery(i)}),d=oe.useState(pi(f)),h=d[0],p=d[1];if(tl(h)!==f&&p(pi(f)),f.didChangeOptions(i)){var v=f.applyOptions(i);Cc(h,v)}var _=oe.useCallback(function(g){var y=f.fetchMore(g);return p(pi(f)),y},[f]),m=oe.useCallback(function(g){var y=f.refetch(g);return p(pi(f)),y},[f]);return oe.useEffect(function(){return f.softRetain()},[f]),[l.current?h:void 0,{fetchMore:_,refetch:m}]}function Ipe(e,t){t===void 0&&(t=Object.create(null));var r=gn(t.client),n=GO(r),i=VO({client:r,query:e,options:t}),a=t.queryKey,o=a===void 0?[]:a,s=oe.useState(null),u=s[0],l=s[1],c=u&&tl(u);if(u&&(c!=null&&c.didChangeOptions(i))){var f=c.applyOptions(i);Cc(u,f)}var d=ipe(),h=oe.useCallback(function(m){if(!c)throw new Error("The query has not been loaded. Please load the query.");var g=c.fetchMore(m);return l(pi(c)),g},[c]),p=oe.useCallback(function(m){if(!c)throw new Error("The query has not been loaded. Please load the query.");var g=c.refetch(m);return l(pi(c)),g},[c]),v=oe.useCallback(function(){for(var m=[],g=0;g{const[p]=(0,s.getFragmentDefinitions)(h);return p.typeCondition.name.value},l=(h,p)=>{const v={__typename:u(h),id:p};return a.useFragment({fragment:h,from:v})},c=e.fragmentRegistry=(0,o.createFragmentRegistry)(),f=h=>(0,i.default)(h).call(h,d);e.registerFragments=f;const d=h=>{c.register(h);const p=u(h);return{fragment:h,typename:p,getCacheKey:m=>({__typename:p,id:m}),useRegisteredFragment:m=>l(h,m)}};e.registerFragment=d}(ly)),ly}var cy,CN;function Ype(){return CN||(CN=1,cy={}),cy}var fy={},$N;function Qpe(){return $N||($N=1,function(e){var t=xe;t(e,"__esModule",{value:!0}),e.useCache=void 0;var r=YO;const n=()=>{const i=(0,r.useApolloClient)(),a=i.cache,o=function(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return a.extract(d)},s=d=>({id:a.identify(d)});return{cache:a,evict:d=>a.evict(s(d)),extract:o,identify:s,modify:(d,h)=>a.modify({...s(d),fields:h}),resetStore:()=>i.resetStore(),clearStore:()=>i.clearStore()}};e.useCache=n}(fy)),fy}(function(e){var t=xe,r=Dn.default,n=dt.default;t(e,"__esModule",{value:!0}),e.RedwoodApolloProvider=void 0,t(e,"fragmentRegistry",{enumerable:!0,get:function(){return _.fragmentRegistry}}),t(e,"registerFragment",{enumerable:!0,get:function(){return _.registerFragment}}),t(e,"registerFragments",{enumerable:!0,get:function(){return _.registerFragments}}),t(e,"useCache",{enumerable:!0,get:function(){return g.useCache}});var i=n(I),a=n(Ov()),o=n(Ice()),s=n(yi()),u=r(YO),l=Mpe,c=zpe,f=a5,d=Hpe,h=ov();Wpe();var p=cH(),v=Uk(),_=Vpe(),m=Ype(),g=Qpe(),y=P;const{ApolloProvider:S,ApolloClient:b,ApolloLink:E,HttpLink:w,InMemoryCache:R,useQuery:O,useMutation:k,useSubscription:C,setLogVerbosity:T}=u,$=Y=>{var B;let{config:D,children:F,useAuth:z=h.useNoAuth,logLevel:ee}=Y;T(ee);const{getToken:Z,type:W}=z(),Q={mostRecentRequest:void 0,mostRecentResponse:void 0},ae=new E((ue,_e)=>{var ye;const{operationName:It,query:xr,variables:tn}=ue;return Q.mostRecentRequest={},Q.mostRecentRequest.operationName=It,Q.mostRecentRequest.operationKind=xr==null?void 0:xr.kind.toString(),Q.mostRecentRequest.variables=tn,Q.mostRecentRequest.query=xr&&(0,d.print)(ue.query),(0,a.default)(ye=_e(ue)).call(ye,rn=>(Q.mostRecentResponse=rn,rn))}),re=(0,l.setContext)(async()=>({token:await Z()})),{headers:ie,uri:Ee}=(0,p.useFetchConfig)(),Ie=new E((ue,_e)=>{const{token:ye}=ue.getContext(),It=ye?{"auth-provider":W,authorization:`Bearer ${ye}`}:{};return ue.setContext(()=>({headers:{...ue.getContext().headers,...ie,...It}})),_e(ue)}),{httpLinkConfig:Pe,link:$e,...De}=D??{},He=new w({uri:Ee,...Pe}),Je=typeof m.SSELink<"u"?u.split(ue=>{let{query:_e}=ue;const ye=(0,f.getMainDefinition)(_e);return ye.kind==="OperationDefinition"&&ye.operation==="subscription"},new m.SSELink({url:Ee,auth:{authProviderType:W,tokenFn:Z},httpLinkConfig:Pe,headers:ie}),He):He,et=u.split(ue=>{var It;let{query:_e}=ue;const ye=_e;return((It=ye==null?void 0:ye.__meta__)==null?void 0:It.hash)!==void 0},(0,o.default)(B=(0,c.createPersistedQueryLink)({generateHash:ue=>ue.__meta__.hash})).call(B,Je),Je),ot=[{name:"withToken",link:re},{name:"authMiddleware",link:Ie},{name:"updateDataApolloLink",link:ae},{name:"httpLink",link:et}];let st=$e;st??(st=E.from((0,a.default)(ot).call(ot,ue=>ue.link))),typeof st=="function"&&(st=st(ot));const we=new b({defaultOptions:{watchQuery:{fetchPolicy:"cache-and-network",notifyOnNetworkStatusChange:!0}},link:st,...De}),We=(ue,_e)=>{throw ue.mostRecentRequest=Q.mostRecentRequest,ue.mostRecentResponse=Q.mostRecentResponse,ue};return(0,y.jsx)(S,{client:we,children:(0,y.jsx)(L,{onError:We,children:F})})};class L extends i.default.Component{componentDidCatch(){this.setState({}),this.props.onError(...arguments)}render(){return this.props.children}}const G=Y=>{var re;var B;let{graphQLClientConfig:D,fragments:F,useAuth:z=h.useNoAuth,logLevel:ee="debug",children:Z}=Y;const{cacheConfig:W,...Q}=D??{};F&&_.fragmentRegistry.register(...F);const ae=new R({fragments:_.fragmentRegistry,possibleTypes:W==null?void 0:W.possibleTypes,...W}).restore((B=(re=s.default)==null?void 0:re.__REDWOOD__APOLLO_STATE)!==null&&B!==void 0?B:{});return(0,y.jsx)(p.FetchConfigProvider,{useAuth:z,children:(0,y.jsx)($,{config:{cache:ae,...Q},useAuth:z,logLevel:ee,children:(0,y.jsx)(v.GraphQLHooksProvider,{useQuery:O,useMutation:k,useSubscription:C,children:Z})})})};e.RedwoodApolloProvider=G})(sO);var dy={},DN;function o5(){return DN||(DN=1,function(e){var t=xe;t(e,"__esModule",{value:!0}),e.getOperationName=r;function r(n){var i;for(const a of n.definitions)if(a.kind==="OperationDefinition"&&((i=a.name)!=null&&i.value))return a.name.value;return""}}(dy)),dy}var NN;function Kpe(){return NN||(NN=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.createCell=v;var n=r(Tv()),i=r(b4()),a=r(kv()),o=r(yi()),s=r(vce()),u=sO,l=o5(),c=S4(),f=Uk(),d=P;function h(_){return(0,n.default)(_)&&_.length===0}function p(_){var m;return(0,i.default)(m=(0,a.default)(_)).call(m,g=>g===null||h(g))}function v(_){let{QUERY:m,beforeQuery:g=C=>({variables:C,fetchPolicy:"cache-and-network",notifyOnNetworkStatusChange:!0}),afterQuery:y=C=>({...C}),isEmpty:S=p,Loading:b=()=>(0,d.jsx)(d.Fragment,{children:"Loading..."}),Failure:E,Empty:w,Success:R,displayName:O="Cell"}=_;function k(C){var ee,Z,W;const{children:T,...$}=C,L=g($),G=typeof m=="function"?m(L):m;let{error:Y,loading:B,data:D,...F}=(0,f.useQuery)(G,L);if(o.default.__REDWOOD__PRERENDERING){const{queryCache:Q}=(0,c.useCellCacheContext)(),ae=(0,l.getOperationName)(G),re=u.fragmentRegistry.transform(G);let ie;if(ae)ie=ae+"_"+(0,s.default)($);else{const Ie=O==="Cell"?"the cell":O;throw new Error(`The gql query in ${Ie} is missing an operation name. Something like FindBlogPostQuery in \`query FindBlogPostQuery($id: Int!)\``)}const Ee=Q[ie];Ee!=null&&Ee.renderLoading?B=!0:Ee!=null&&Ee.hasProcessed?(B=!1,D=Ee.data,F={variables:$}):Q[ie]||(Q[ie]={query:re,variables:L.variables,hasProcessed:!1})}if(Y)if(E){var z;return(0,d.jsx)(E,{error:Y,errorCode:(z=F.errorCode)!==null&&z!==void 0?z:(W=(Z=(ee=Y.graphQLErrors)==null?void 0:ee[0])==null?void 0:Z.extensions)==null?void 0:W.code,...C,updating:B,queryResult:F})}else throw Y;else if(D){const Q=y(D);return S(D,{isDataEmpty:p})&&w?(0,d.jsx)(w,{...C,...Q,updating:B,queryResult:F}):(0,d.jsx)(R,{...C,...Q,updating:B,queryResult:F})}else{if(B)return(0,d.jsx)(b,{...C,queryResult:F});throw console.warn("If you're using Apollo Client, check for its debug logs here in the console, which may help explain the error."),new Error("Cannot render Cell: reached an unexpected state where the query succeeded but `data` is `null`. If this happened in Storybook, your query could be missing fields; otherwise this is most likely a GraphQL caching bug. Note that adding an `id` field to all the fields on your query may fix the issue.")}}return k.displayName=O,C=>(0,d.jsx)(k,{...C})}}(t_)),t_}var hy={},Jpe=typeof Element<"u",Xpe=typeof Map=="function",Zpe=typeof Set=="function",eve=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function Qd(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var r,n,i;if(Array.isArray(e)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(!Qd(e[n],t[n]))return!1;return!0}var a;if(Xpe&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;for(a=e.entries();!(n=a.next()).done;)if(!Qd(n.value[1],t.get(n.value[0])))return!1;return!0}if(Zpe&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(a=e.entries();!(n=a.next()).done;)if(!t.has(n.value[0]))return!1;return!0}if(eve&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(r=e.length,r!=t.length)return!1;for(n=r;n--!==0;)if(e[n]!==t[n])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!Object.prototype.hasOwnProperty.call(t,i[n]))return!1;if(Jpe&&e instanceof Element)return!1;for(n=r;n--!==0;)if(!((i[n]==="_owner"||i[n]==="__v"||i[n]==="__o")&&e.$$typeof)&&!Qd(e[i[n]],t[i[n]]))return!1;return!0}return e!==e&&t!==t}var tve=function(t,r){try{return Qd(t,r)}catch(n){if((n.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw n}};const rve=$u(tve);var nve=function(e,t,r,n,i,a,o,s){if(!e){var u;if(t===void 0)u=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var l=[r,n,i,a,o,s],c=0;u=new Error(t.replace(/%s/g,function(){return l[c++]})),u.name="Invariant Violation"}throw u.framesToPop=1,u}},ive=nve;const AN=$u(ive);var ave=function(t,r,n,i){var a=n?n.call(i,t,r):void 0;if(a!==void 0)return!!a;if(t===r)return!0;if(typeof t!="object"||!t||typeof r!="object"||!r)return!1;var o=Object.keys(t),s=Object.keys(r);if(o.length!==s.length)return!1;for(var u=Object.prototype.hasOwnProperty.bind(r),l=0;l(e.BASE="base",e.BODY="body",e.HEAD="head",e.HTML="html",e.LINK="link",e.META="meta",e.NOSCRIPT="noscript",e.SCRIPT="script",e.STYLE="style",e.TITLE="title",e.FRAGMENT="Symbol(react.fragment)",e))(s5||{}),py={link:{rel:["amphtml","canonical","alternate"]},script:{type:["application/ld+json"]},meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]}},LN=Object.values(s5),QO={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},sve=Object.entries(QO).reduce((e,[t,r])=>(e[r]=t,e),{}),Gn="data-rh",nu={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},iu=(e,t)=>{for(let r=e.length-1;r>=0;r-=1){const n=e[r];if(Object.prototype.hasOwnProperty.call(n,t))return n[t]}return null},uve=e=>{let t=iu(e,"title");const r=iu(e,nu.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join("")),r&&t)return r.replace(/%s/g,()=>t);const n=iu(e,nu.DEFAULT_TITLE);return t||n||void 0},lve=e=>iu(e,nu.ON_CHANGE_CLIENT_STATE)||(()=>{}),vy=(e,t)=>t.filter(r=>typeof r[e]<"u").map(r=>r[e]).reduce((r,n)=>({...r,...n}),{}),cve=(e,t)=>t.filter(r=>typeof r.base<"u").map(r=>r.base).reverse().reduce((r,n)=>{if(!r.length){const i=Object.keys(n);for(let a=0;aconsole&&typeof console.warn=="function"&&console.warn(e),bl=(e,t,r)=>{const n={};return r.filter(i=>Array.isArray(i[e])?!0:(typeof i[e]<"u"&&fve(`Helmet: ${e} should be of type "Array". Instead found type "${typeof i[e]}"`),!1)).map(i=>i[e]).reverse().reduce((i,a)=>{const o={};a.filter(u=>{let l;const c=Object.keys(u);for(let d=0;di.push(u));const s=Object.keys(o);for(let u=0;u{if(Array.isArray(e)&&e.length){for(let r=0;r({baseTag:cve(["href"],e),bodyAttributes:vy("bodyAttributes",e),defer:iu(e,nu.DEFER),encode:iu(e,nu.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:vy("htmlAttributes",e),linkTags:bl("link",["rel","href"],e),metaTags:bl("meta",["name","charset","http-equiv","property","itemprop"],e),noscriptTags:bl("noscript",["innerHTML"],e),onChangeClientState:lve(e),scriptTags:bl("script",["src","innerHTML"],e),styleTags:bl("style",["cssText"],e),title:uve(e),titleAttributes:vy("titleAttributes",e),prioritizeSeoTags:dve(e,nu.PRIORITIZE_SEO_TAGS)}),u5=e=>Array.isArray(e)?e.join(""):e,pve=(e,t)=>{const r=Object.keys(e);for(let n=0;nArray.isArray(e)?e.reduce((r,n)=>(pve(n,t)?r.priority.push(n):r.default.push(n),r),{priority:[],default:[]}):{default:e,priority:[]},MN=(e,t)=>({...e,[t]:void 0}),vve=["noscript","script","style"],HR=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,"&").replace(//g,">").replace(/"/g,""").replace(/'/g,"'"),l5=e=>Object.keys(e).reduce((t,r)=>{const n=typeof e[r]<"u"?`${r}="${e[r]}"`:`${r}`;return t?`${t} ${n}`:n},""),mve=(e,t,r,n)=>{const i=l5(r),a=u5(t);return i?`<${e} ${Gn}="true" ${i}>${HR(a,n)}`:`<${e} ${Gn}="true">${HR(a,n)}`},gve=(e,t,r=!0)=>t.reduce((n,i)=>{const a=i,o=Object.keys(a).filter(l=>!(l==="innerHTML"||l==="cssText")).reduce((l,c)=>{const f=typeof a[c]>"u"?c:`${c}="${HR(a[c],r)}"`;return l?`${l} ${f}`:f},""),s=a.innerHTML||a.cssText||"",u=vve.indexOf(e)===-1;return`${n}<${e} ${Gn}="true" ${o}${u?"/>":`>${s}`}`},""),c5=(e,t={})=>Object.keys(e).reduce((r,n)=>{const i=QO[n];return r[i||n]=e[n],r},t),_ve=(e,t,r)=>{const n={key:t,[Gn]:!0},i=c5(r,n);return[qe.createElement("title",i,t)]},Kd=(e,t)=>t.map((r,n)=>{const i={key:n,[Gn]:!0};return Object.keys(r).forEach(a=>{const s=QO[a]||a;if(s==="innerHTML"||s==="cssText"){const u=r.innerHTML||r.cssText;i.dangerouslySetInnerHTML={__html:u}}else i[s]=r[a]}),qe.createElement(e,i)}),bn=(e,t,r=!0)=>{switch(e){case"title":return{toComponent:()=>_ve(e,t.title,t.titleAttributes),toString:()=>mve(e,t.title,t.titleAttributes,r)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>c5(t),toString:()=>l5(t)};default:return{toComponent:()=>Kd(e,t),toString:()=>gve(e,t,r)}}},yve=({metaTags:e,linkTags:t,scriptTags:r,encode:n})=>{const i=my(e,py.meta),a=my(t,py.link),o=my(r,py.script);return{priorityMethods:{toComponent:()=>[...Kd("meta",i.priority),...Kd("link",a.priority),...Kd("script",o.priority)],toString:()=>`${bn("meta",i.priority,n)} ${bn("link",a.priority,n)} ${bn("script",o.priority,n)}`},metaTags:i.default,linkTags:a.default,scriptTags:o.default}},Sve=e=>{const{baseTag:t,bodyAttributes:r,encode:n=!0,htmlAttributes:i,noscriptTags:a,styleTags:o,title:s="",titleAttributes:u,prioritizeSeoTags:l}=e;let{linkTags:c,metaTags:f,scriptTags:d}=e,h={toComponent:()=>{},toString:()=>""};return l&&({priorityMethods:h,linkTags:c,metaTags:f,scriptTags:d}=yve(e)),{priority:h,base:bn("base",t,n),bodyAttributes:bn("bodyAttributes",r,n),htmlAttributes:bn("htmlAttributes",i,n),link:bn("link",c,n),meta:bn("meta",f,n),noscript:bn("noscript",a,n),script:bn("script",d,n),style:bn("style",o,n),title:bn("title",{title:s,titleAttributes:u},n)}},WR=Sve,sd=[],f5=!!(typeof window<"u"&&window.document&&window.document.createElement),sp=class{constructor(e,t){Ri(this,"instances",[]);Ri(this,"canUseDOM",f5);Ri(this,"context");Ri(this,"value",{setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?sd:this.instances,add:e=>{(this.canUseDOM?sd:this.instances).push(e)},remove:e=>{const t=(this.canUseDOM?sd:this.instances).indexOf(e);(this.canUseDOM?sd:this.instances).splice(t,1)}}});this.context=e,this.canUseDOM=t||!1,t||(e.helmet=WR({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},bve={},d5=qe.createContext(bve),su,h5=(su=class extends I.Component{constructor(r){super(r);Ri(this,"helmetData");this.helmetData=new sp(this.props.context||{},su.canUseDOM)}render(){return qe.createElement(d5.Provider,{value:this.helmetData.value},this.props.children)}},Ri(su,"canUseDOM",f5),su),_s=(e,t)=>{const r=document.head||document.querySelector("head"),n=r.querySelectorAll(`${e}[${Gn}]`),i=[].slice.call(n),a=[];let o;return t&&t.length&&t.forEach(s=>{const u=document.createElement(e);for(const l in s)if(Object.prototype.hasOwnProperty.call(s,l))if(l==="innerHTML")u.innerHTML=s.innerHTML;else if(l==="cssText")u.styleSheet?u.styleSheet.cssText=s.cssText:u.appendChild(document.createTextNode(s.cssText));else{const c=l,f=typeof s[c]>"u"?"":s[c];u.setAttribute(l,f)}u.setAttribute(Gn,"true"),i.some((l,c)=>(o=c,u.isEqualNode(l)))?i.splice(o,1):a.push(u)}),i.forEach(s=>{var u;return(u=s.parentNode)==null?void 0:u.removeChild(s)}),a.forEach(s=>r.appendChild(s)),{oldTags:i,newTags:a}},GR=(e,t)=>{const r=document.getElementsByTagName(e)[0];if(!r)return;const n=r.getAttribute(Gn),i=n?n.split(","):[],a=[...i],o=Object.keys(t);for(const s of o){const u=t[s]||"";r.getAttribute(s)!==u&&r.setAttribute(s,u),i.indexOf(s)===-1&&i.push(s);const l=a.indexOf(s);l!==-1&&a.splice(l,1)}for(let s=a.length-1;s>=0;s-=1)r.removeAttribute(a[s]);i.length===a.length?r.removeAttribute(Gn):r.getAttribute(Gn)!==o.join(",")&&r.setAttribute(Gn,o.join(","))},Eve=(e,t)=>{typeof e<"u"&&document.title!==e&&(document.title=u5(e)),GR("title",t)},FN=(e,t)=>{const{baseTag:r,bodyAttributes:n,htmlAttributes:i,linkTags:a,metaTags:o,noscriptTags:s,onChangeClientState:u,scriptTags:l,styleTags:c,title:f,titleAttributes:d}=e;GR("body",n),GR("html",i),Eve(f,d);const h={baseTag:_s("base",r),linkTags:_s("link",a),metaTags:_s("meta",o),noscriptTags:_s("noscript",s),scriptTags:_s("script",l),styleTags:_s("style",c)},p={},v={};Object.keys(h).forEach(_=>{const{newTags:m,oldTags:g}=h[_];m.length&&(p[_]=m),g.length&&(v[_]=h[_].oldTags)}),t&&t(),u(e,p,v)},El=null,wve=e=>{El&&cancelAnimationFrame(El),e.defer?El=requestAnimationFrame(()=>{FN(e,()=>{El=null})}):(FN(e),El=null)},Rve=wve,jN=class extends I.Component{constructor(){super(...arguments);Ri(this,"rendered",!1)}shouldComponentUpdate(t){return!ove(t,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:t}=this.props.context;t.remove(this),this.emitChange()}emitChange(){const{helmetInstances:t,setHelmet:r}=this.props.context;let n=null;const i=hve(t.get().map(a=>{const o={...a.props};return delete o.context,o}));h5.canUseDOM?Rve(i):WR&&(n=WR(i)),r(n)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:t}=this.props.context;t.add(this),this.emitChange()}render(){return this.init(),null}},SE,Tve=(SE=class extends I.Component{shouldComponentUpdate(e){return!rve(MN(this.props,"helmetData"),MN(e,"helmetData"))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case"script":case"noscript":return{innerHTML:t};case"style":return{cssText:t};default:throw new Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,r,n){return{...t,[e.type]:[...t[e.type]||[],{...r,...this.mapNestedChildrenToProps(e,n)}]}}mapObjectTypeChildren(e,t,r,n){switch(e.type){case"title":return{...t,[e.type]:n,titleAttributes:{...r}};case"body":return{...t,bodyAttributes:{...r}};case"html":return{...t,htmlAttributes:{...r}};default:return{...t,[e.type]:{...r}}}}mapArrayTypeChildrenToProps(e,t){let r={...t};return Object.keys(e).forEach(n=>{r={...r,[n]:e[n]}}),r}warnOnInvalidChildren(e,t){return AN(LN.some(r=>e.type===r),typeof e.type=="function"?"You may be attempting to nest components within each other, which is not allowed. Refer to our API for more information.":`Only elements types ${LN.join(", ")} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),AN(!t||typeof t=="string"||Array.isArray(t)&&!t.some(r=>typeof r!="string"),`Helmet expects a string as a child of <${e.type}>. Did you forget to wrap your children in braces? ( <${e.type}>{\`\`} ) Refer to our API for more information.`),!0}mapChildrenToProps(e,t){let r={};return qe.Children.forEach(e,n=>{if(!n||!n.props)return;const{children:i,...a}=n.props,o=Object.keys(a).reduce((u,l)=>(u[sve[l]||l]=a[l],u),{});let{type:s}=n;switch(typeof s=="symbol"?s=s.toString():this.warnOnInvalidChildren(n,i),s){case"Symbol(react.fragment)":t=this.mapChildrenToProps(i,t);break;case"link":case"meta":case"noscript":case"script":case"style":r=this.flattenArrayTypeChildren(n,r,o,i);break;default:t=this.mapObjectTypeChildren(n,t,o,i);break}}),this.mapArrayTypeChildrenToProps(r,t)}render(){const{children:e,...t}=this.props;let r={...t},{helmetData:n}=t;if(e&&(r=this.mapChildrenToProps(e,r)),n&&!(n instanceof sp)){const i=n;n=new sp(i.context,!0),delete r.helmetData}return n?qe.createElement(jN,{...r,context:n.value}):qe.createElement(d5.Consumer,null,i=>qe.createElement(jN,{...r,context:i}))}},Ri(SE,"defaultProps",{defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1}),SE);const kve=Object.freeze(Object.defineProperty({__proto__:null,Helmet:Tve,HelmetData:sp,HelmetProvider:h5},Symbol.toStringTag,{value:"Module"})),zv=Zo(kve);var qN;function Ove(){return qN||(qN=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.RedwoodProvider=void 0;var n=r(yi()),i=zv,a=P;const o=s=>{let{children:u,titleTemplate:l}=s;const c=n.default.__REDWOOD__APP_TITLE,f=()=>{if(l){let d=l.replace(/%AppTitle/g,c);return d=d.replace(/%PageTitle/g,"%s"),d}return""};return(0,a.jsxs)(i.HelmetProvider,{context:n.default.__REDWOOD__HELMET_CONTEXT,children:[(0,a.jsx)(i.Helmet,{titleTemplate:f(),defaultTitle:c,children:(0,a.jsx)("title",{children:c})}),u]})};e.RedwoodProvider=o}(hy)),hy}var gy={},UN;function Pve(){return UN||(UN=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.MetaTags=void 0;var n=r(Tv()),i=zv,a=P;const o=s=>{const{tag:u="og:image",ogType:l="website",ogContentUrl:c,robots:f,contentType:d,ogWidth:h,ogHeight:p,ogUrl:v,title:_,locale:m,description:g,author:y,children:S}=s;return(0,a.jsxs)(a.Fragment,{children:[_&&(0,a.jsxs)(i.Helmet,{children:[(0,a.jsx)("title",{children:_}),(0,a.jsx)("meta",{property:"og:title",content:_},"title"),(0,a.jsx)("meta",{property:"twitter:title",content:_})]}),g&&(0,a.jsxs)(i.Helmet,{children:[(0,a.jsx)("meta",{name:"description",content:g}),(0,a.jsx)("meta",{name:"twitter:description",content:g}),(0,a.jsx)("meta",{property:"og:description",content:g})]}),y&&(0,a.jsxs)(i.Helmet,{children:[(0,a.jsx)("meta",{name:"author",content:y}),(0,a.jsx)("meta",{name:"twitter:site",content:y}),(0,a.jsx)("meta",{name:"twitter:creator",content:y})]}),v&&(0,a.jsx)(i.Helmet,{children:(0,a.jsx)("meta",{property:"og:url",content:v})}),m&&(0,a.jsxs)(i.Helmet,{children:[(0,a.jsx)("html",{lang:m}),(0,a.jsx)("meta",{property:"og:locale",content:m})]}),(0,a.jsx)(i.Helmet,{children:(0,a.jsx)("meta",{property:"og:type",content:l})}),c&&(0,a.jsx)(i.Helmet,{children:(0,a.jsx)("meta",{property:u,content:c})}),d&&(0,a.jsx)(i.Helmet,{children:(0,a.jsx)("meta",{property:`${u}:type`,content:d})}),u==="og:image"&&(0,a.jsxs)(i.Helmet,{children:[h&&(0,a.jsx)("meta",{property:"image:width",content:h}),p&&(0,a.jsx)("meta",{property:"image:height",content:p}),(0,a.jsx)("meta",{property:"twitter:card",content:"summary_large_image"}),(0,a.jsx)("meta",{property:"twitter:image",content:c})]}),f&&(0,a.jsx)(i.Helmet,{children:(0,a.jsx)("meta",{name:"robots",content:(0,n.default)(f)?f.join(", "):f})}),S]})};e.MetaTags=o}(gy)),gy}var _y={},BN={},yy,zN;function p5(){if(zN)return yy;zN=1;var e=is,t=ti,r=hH,n=uo,i=function(a,o,s,u,l,c,f,d){for(var h=l,p=0,v=f?n(f,d):!1,_,m;p0&&e(_)?(m=t(_),h=i(a,o,_,m,h,c-1)-1):(r(h+1),a[h]=_),h++),p++;return h};return yy=i,yy}var HN;function Ive(){if(HN)return BN;HN=1;var e=ge,t=p5(),r=Wu,n=en,i=ti,a=iv;return e({target:"Array",proto:!0},{flatMap:function(s){var u=n(this),l=i(u),c;return r(s),c=a(u,0),c.length=t(c,u,u,l,0,1,s,arguments.length>1?arguments[1]:void 0),c}}),BN}var Sy,WN;function xve(){if(WN)return Sy;WN=1,Ive();var e=Rt();return Sy=e("Array","flatMap"),Sy}var by,GN;function Cve(){if(GN)return by;GN=1;var e=mt,t=xve(),r=Array.prototype;return by=function(n){var i=n.flatMap;return n===r||e(r,n)&&i===r.flatMap?t:i},by}var Ey,VN;function $ve(){if(VN)return Ey;VN=1;var e=Cve();return Ey=e,Ey}var wy,YN;function Dve(){if(YN)return wy;YN=1;var e=$ve();return wy=e,wy}var Ry,QN;function Nve(){if(QN)return Ry;QN=1;var e=Dve();return Ry=e,Ry}var Ty,KN;function Ave(){return KN||(KN=1,Ty=Nve()),Ty}var ky,JN;function v5(){return JN||(JN=1,ky=Ave()),ky}var XN={},ZN;function Lve(){if(ZN)return XN;ZN=1;var e=ge,t=ua.filter,r=uv,n=r("filter");return e({target:"Array",proto:!0,forced:!n},{filter:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),XN}var Oy,eA;function Mve(){if(eA)return Oy;eA=1,Lve();var e=Rt();return Oy=e("Array","filter"),Oy}var Py,tA;function Fve(){if(tA)return Py;tA=1;var e=mt,t=Mve(),r=Array.prototype;return Py=function(n){var i=n.filter;return n===r||e(r,n)&&i===r.filter?t:i},Py}var Iy,rA;function jve(){if(rA)return Iy;rA=1;var e=Fve();return Iy=e,Iy}var xy,nA;function qve(){if(nA)return xy;nA=1;var e=jve();return xy=e,xy}var Cy,iA;function Uve(){if(iA)return Cy;iA=1;var e=qve();return Cy=e,Cy}var $y,aA;function Bve(){return aA||(aA=1,$y=Uve()),$y}var Dy,oA;function Hv(){return oA||(oA=1,Dy=Bve()),Dy}var sA={},uA;function zve(){if(uA)return sA;uA=1;var e=ge,t=E4().entries;return e({target:"Object",stat:!0},{entries:function(n){return t(n)}}),sA}var Ny,lA;function Hve(){if(lA)return Ny;lA=1,zve();var e=Gt;return Ny=e.Object.entries,Ny}var Ay,cA;function Wve(){if(cA)return Ay;cA=1;var e=Hve();return Ay=e,Ay}var Ly,fA;function Gve(){if(fA)return Ly;fA=1;var e=Wve();return Ly=e,Ly}var My,dA;function Vve(){if(dA)return My;dA=1;var e=Gve();return My=e,My}var Fy,hA;function Yve(){return hA||(hA=1,Fy=Vve()),Fy}var jy,pA;function KO(){return pA||(pA=1,jy=Yve()),jy}var vA={},mA;function Qve(){if(mA)return vA;mA=1;var e=ge,t=Mk.includes,r=Ve,n=r(function(){return!Array(1).includes()});return e({target:"Array",proto:!0,forced:n},{includes:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),vA}var qy,gA;function Kve(){if(gA)return qy;gA=1,Qve();var e=Rt();return qy=e("Array","includes"),qy}var _A={},Uy,yA;function m5(){if(yA)return Uy;yA=1;var e=Ir,t=Cn,r=wt,n=r("match");return Uy=function(i){var a;return e(i)&&((a=i[n])!==void 0?!!a:t(i)==="RegExp")},Uy}var By,SA;function JO(){if(SA)return By;SA=1;var e=m5(),t=TypeError;return By=function(r){if(e(r))throw new t("The method doesn't accept regular expressions");return r},By}var zy,bA;function XO(){if(bA)return zy;bA=1;var e=wt,t=e("match");return zy=function(r){var n=/./;try{"/./"[r](n)}catch{try{return n[t]=!1,"/./"[r](n)}catch{}}return!1},zy}var EA;function Jve(){if(EA)return _A;EA=1;var e=ge,t=Ke,r=JO(),n=ei,i=yr,a=XO(),o=t("".indexOf);return e({target:"String",proto:!0,forced:!a("includes")},{includes:function(u){return!!~o(i(n(this)),i(r(u)),arguments.length>1?arguments[1]:void 0)}}),_A}var Hy,wA;function Xve(){if(wA)return Hy;wA=1,Jve();var e=Rt();return Hy=e("String","includes"),Hy}var Wy,RA;function Zve(){if(RA)return Wy;RA=1;var e=mt,t=Kve(),r=Xve(),n=Array.prototype,i=String.prototype;return Wy=function(a){var o=a.includes;return a===n||e(n,a)&&o===n.includes?t:typeof a=="string"||a===i||e(i,a)&&o===i.includes?r:o},Wy}var Gy,TA;function eme(){if(TA)return Gy;TA=1;var e=Zve();return Gy=e,Gy}var Vy,kA;function tme(){if(kA)return Vy;kA=1;var e=eme();return Vy=e,Vy}var Yy,OA;function rme(){if(OA)return Yy;OA=1;var e=tme();return Yy=e,Yy}var Qy,PA;function nme(){return PA||(PA=1,Qy=rme()),Qy}var Ky,IA;function ZO(){return IA||(IA=1,Ky=nme()),Ky}var xA={},CA;function ime(){if(CA)return xA;CA=1;var e=ge,t=Ke,r=is,n=t([].reverse),i=[1,2];return e({target:"Array",proto:!0,forced:String(i)===String(i.reverse())},{reverse:function(){return r(this)&&(this.length=this.length),n(this)}}),xA}var Jy,$A;function ame(){if($A)return Jy;$A=1,ime();var e=Rt();return Jy=e("Array","reverse"),Jy}var Xy,DA;function ome(){if(DA)return Xy;DA=1;var e=mt,t=ame(),r=Array.prototype;return Xy=function(n){var i=n.reverse;return n===r||e(r,n)&&i===r.reverse?t:i},Xy}var Zy,NA;function sme(){if(NA)return Zy;NA=1;var e=ome();return Zy=e,Zy}var e0,AA;function ume(){if(AA)return e0;AA=1;var e=sme();return e0=e,e0}var t0,LA;function lme(){if(LA)return t0;LA=1;var e=ume();return t0=e,t0}var r0,MA;function cme(){return MA||(MA=1,r0=lme()),r0}var n0,FA;function fme(){return FA||(FA=1,n0=cme()),n0}var jA={},qA;function dme(){if(qA)return jA;qA=1;var e=ge,t=p5(),r=en,n=ti,i=lo,a=iv;return e({target:"Array",proto:!0},{flat:function(){var s=arguments.length?arguments[0]:void 0,u=r(this),l=n(u),c=a(u,0);return c.length=t(c,u,u,l,0,s===void 0?1:i(s)),c}}),jA}var i0,UA;function hme(){if(UA)return i0;UA=1,dme();var e=Rt();return i0=e("Array","flat"),i0}var a0,BA;function pme(){if(BA)return a0;BA=1;var e=mt,t=hme(),r=Array.prototype;return a0=function(n){var i=n.flat;return n===r||e(r,n)&&i===r.flat?t:i},a0}var o0,zA;function vme(){if(zA)return o0;zA=1;var e=pme();return o0=e,o0}var s0,HA;function mme(){if(HA)return s0;HA=1;var e=vme();return s0=e,s0}var u0,WA;function gme(){if(WA)return u0;WA=1;var e=mme();return u0=e,u0}var l0,GA;function _me(){return GA||(GA=1,l0=gme()),l0}var c0,VA;function yme(){return VA||(VA=1,c0=_me()),c0}var YA;function Sme(){return YA||(YA=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.Metadata=void 0;var n=r(Tv()),i=r(v5()),a=r(Hv()),o=r(KO()),s=r(ZO()),u=r(Ov()),l=r(fme()),c=r(yme()),f=r(I),d=zv,h=P;const p=["charSet"],v=(m,g,y)=>{if((0,n.default)(g))return(0,i.default)(g).call(g,E=>v(m,E,y));if(typeof g=="object"){var S,b;return(0,i.default)(S=(0,a.default)(b=(0,o.default)(g)).call(b,E=>{let[w,R]=E;return R!==null})).call(S,E=>{let[w,R]=E;return v(`${m}:${w}`,R,{attr:"property"})})}else{const E={[y.attr]:m,content:g};return(0,h.jsx)("meta",{...E})}},_=m=>{var g,y,S;const{children:b,...E}=m,w=d.Helmet,R=(0,a.default)(g=(0,i.default)(y=(0,a.default)(S=(0,o.default)(E)).call(S,T=>{let[$,L]=T;return!(0,s.default)(p).call(p,$)&&L!==null&&($!=="og"||L!==!0)})).call(y,T=>{let[$,L]=T;return v($,L,{attr:"name"})})).call(g,T=>!!T);if(E.title){var O,k,C;(0,u.default)(O=(0,l.default)(k=(0,c.default)(C=[E.title]).call(C)).call(k)).call(O,T=>{R.unshift((0,h.jsx)("title",{children:T}))})}return E.charSet&&R.push((0,h.jsx)("meta",{charSet:E.charSet})),E.og&&(E.title&&!E.og.title&&E.og.title!==null&&R.push((0,h.jsx)("meta",{property:"og:title",content:E.title})),E.description&&!E.og.description&&E.og.description!==null&&R.push((0,h.jsx)("meta",{property:"og:description",content:E.description})),!E.og.type&&E.og.type!==null&&R.push((0,h.jsx)("meta",{property:"og:type",content:"website"}))),(0,h.jsxs)(w,{children:[(0,u.default)(R).call(R,(T,$)=>f.default.cloneElement(T,{key:$})),b]})};e.Metadata=_}(_y)),_y}(function(e){var t,r,n,i,a,o=xe,s=av,u=as,l=dt.default;o(e,"__esModule",{value:!0});var c={FatalErrorBoundary:!0,FetchConfigProvider:!0,useFetchConfig:!0,GraphQLHooksProvider:!0,useQuery:!0,useMutation:!0,useSubscription:!0,createCell:!0,CellProps:!0,CellFailureProps:!0,CellLoadingProps:!0,CellSuccessProps:!0,CellSuccessData:!0,Head:!0,Helmet:!0};o(e,"CellFailureProps",{enumerable:!0,get:function(){return v.CellFailureProps}}),o(e,"CellLoadingProps",{enumerable:!0,get:function(){return v.CellLoadingProps}}),o(e,"CellProps",{enumerable:!0,get:function(){return v.CellProps}}),o(e,"CellSuccessData",{enumerable:!0,get:function(){return v.CellSuccessData}}),o(e,"CellSuccessProps",{enumerable:!0,get:function(){return v.CellSuccessProps}}),o(e,"FatalErrorBoundary",{enumerable:!0,get:function(){return f.default}}),o(e,"FetchConfigProvider",{enumerable:!0,get:function(){return d.FetchConfigProvider}}),o(e,"GraphQLHooksProvider",{enumerable:!0,get:function(){return h.GraphQLHooksProvider}}),o(e,"Head",{enumerable:!0,get:function(){return S.Helmet}}),o(e,"Helmet",{enumerable:!0,get:function(){return S.Helmet}}),o(e,"createCell",{enumerable:!0,get:function(){return v.createCell}}),o(e,"useFetchConfig",{enumerable:!0,get:function(){return d.useFetchConfig}}),o(e,"useMutation",{enumerable:!0,get:function(){return h.useMutation}}),o(e,"useQuery",{enumerable:!0,get:function(){return h.useQuery}}),o(e,"useSubscription",{enumerable:!0,get:function(){return h.useSubscription}}),Tre(),$re();var f=l(Dre()),d=cH(),h=Uk(),p=S4();s(t=u(p)).call(t,function(b){b==="default"||b==="__esModule"||Object.prototype.hasOwnProperty.call(c,b)||b in e&&e[b]===p[b]||o(e,b,{enumerable:!0,get:function(){return p[b]}})});var v=Kpe(),_=o5();s(r=u(_)).call(r,function(b){b==="default"||b==="__esModule"||Object.prototype.hasOwnProperty.call(c,b)||b in e&&e[b]===_[b]||o(e,b,{enumerable:!0,get:function(){return _[b]}})});var m=Ove();s(n=u(m)).call(n,function(b){b==="default"||b==="__esModule"||Object.prototype.hasOwnProperty.call(c,b)||b in e&&e[b]===m[b]||o(e,b,{enumerable:!0,get:function(){return m[b]}})});var g=Pve();s(i=u(g)).call(i,function(b){b==="default"||b==="__esModule"||Object.prototype.hasOwnProperty.call(c,b)||b in e&&e[b]===g[b]||o(e,b,{enumerable:!0,get:function(){return g[b]}})});var y=Sme();s(a=u(y)).call(a,function(b){b==="default"||b==="__esModule"||Object.prototype.hasOwnProperty.call(c,b)||b in e&&e[b]===y[b]||o(e,b,{enumerable:!0,get:function(){return y[b]}})});var S=zv})(Rc);var bme=sO;const g5=()=>P.jsxs("main",{children:[P.jsx("style",{dangerouslySetInnerHTML:{__html:` html, body { margin: 0; } html * { box-sizing: border-box; } main { display: flex; align-items: center; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif; text-align: center; background-color: #E2E8F0; height: 100vh; } section { background-color: white; border-radius: 0.25rem; width: 32rem; padding: 1rem; margin: 0 auto; box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06); } section > * + * { margin-top: 10px; } h1 { font-size: 2rem; margin: 0; font-weight: 500; line-height: 1; color: #2D3748; } `}}),P.jsxs("section",{children:[P.jsx("h1",{children:P.jsx("span",{children:"Something went wrong"})}),P.jsx("div",{children:"We've been notified and we'll look into it"}),P.jsx("div",{children:"Please refresh the page"})]})]}),Eme=Object.freeze(Object.defineProperty({__proto__:null,default:g5},Symbol.toStringTag,{value:"Module"})),wme="modulepreload",Rme=function(e){return"/"+e},QA={},be=function(t,r,n){if(!r||r.length===0)return t();const i=document.getElementsByTagName("link");return Promise.all(r.map(a=>{if(a=Rme(a),a in QA)return;QA[a]=!0;const o=a.endsWith(".css"),s=o?'[rel="stylesheet"]':"";if(!!n)for(let c=i.length-1;c>=0;c--){const f=i[c];if(f.href===a&&(!o||f.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${a}"]${s}`))return;const l=document.createElement("link");if(l.rel=o?"stylesheet":wme,o||(l.as="script",l.crossOrigin=""),l.href=a,document.head.appendChild(l),o)return new Promise((c,f)=>{l.addEventListener("load",c),l.addEventListener("error",()=>f(new Error(`Unable to preload CSS for ${a}`)))})})).then(()=>t()).catch(a=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=a,window.dispatchEvent(o),!o.defaultPrevented)throw a})};var f0={},d0={},KA={},JA;function Tme(){if(JA)return KA;JA=1;var e=ge,t=Ke,r=Date,n=t(r.prototype.getTime);return e({target:"Date",stat:!0},{now:function(){return n(new r)}}),KA}var h0,XA;function kme(){if(XA)return h0;XA=1,Tme();var e=Gt;return h0=e.Date.now,h0}var p0,ZA;function Ome(){if(ZA)return p0;ZA=1;var e=kme();return p0=e,p0}var v0,eL;function Pme(){if(eL)return v0;eL=1;var e=Ome();return v0=e,v0}var m0,tL;function Ime(){if(tL)return m0;tL=1;var e=Pme();return m0=e,m0}var g0,rL;function xme(){return rL||(rL=1,g0=Ime()),g0}var _0,nL;function Cme(){return nL||(nL=1,_0=xme()),_0}var iL={},y0,aL;function $me(){if(aL)return y0;aL=1;var e=ft,t=sr,r=Object.getOwnPropertyDescriptor;return y0=function(n){if(!t)return e[n];var i=r(e,n);return i&&i.value},y0}var S0,oL;function Wv(){if(oL)return S0;oL=1;var e=Ve,t=wt,r=sr,n=Qz,i=t("iterator");return S0=!e(function(){var a=new URL("b?a=1&b=2&c=3","https://a"),o=a.searchParams,s=new URLSearchParams("a=1&a=2&b=3"),u="";return a.pathname="c%20d",o.forEach(function(l,c){o.delete("b"),u+=c+l}),s.delete("a",2),s.delete("b",void 0),n&&(!a.toJSON||!s.has("a",1)||s.has("a",2)||!s.has("a",void 0)||s.has("b"))||!o.size&&(n||!r)||!o.sort||a.href!=="https://a/c%20d?a=1&c=3"||o.get("c")!=="3"||String(new URLSearchParams("?a=1"))!=="a=1"||!o[i]||new URL("https://a@b").username!=="a"||new URLSearchParams(new URLSearchParams("a=b")).get("a")!=="b"||new URL("https://тест").host!=="xn--e1aybc"||new URL("https://a#б").hash!=="#%D0%B1"||u!=="a1c3"||new URL("https://x",void 0).host!=="x"}),S0}var b0,sL;function uf(){if(sL)return b0;sL=1;var e=TypeError;return b0=function(t,r){if(t0;)n[u]=n[--u];u!==o++&&(n[u]=s)}else for(var l=t(a/2),c=r(e(n,0,l),i),f=r(e(n,l),i),d=c.length,h=f.length,p=0,v=0;p=N.length)return Re.target=void 0,O(void 0,!0);var te=N[U];switch(Re.kind){case"keys":return O(te.key,!1);case"values":return O(te.value,!1)}return O([te.key,te.value],!1)},!0),rn=function(le){this.entries=[],this.url=null,le!==void 0&&(y(le)?this.parseObject(le):this.parseQuery(typeof le=="string"?Ee(le,0)==="?"?et(le,1):le:S(le)))};rn.prototype={type:L,bindURL:function(le){this.url=le,this.update()},parseObject:function(le){var Re=this.entries,N=R(le),U,te,fe,Se,Te,Ue,tt;if(N)for(U=w(le,N),te=U.next;!(fe=n(te,U)).done;){if(Se=w(g(fe.value)),Te=Se.next,(Ue=n(Te,Se)).done||(tt=n(Te,Se)).done||!n(Te,Se).done)throw new ae("Expected sequence with length 2");Pe(Re,{key:S(Ue.value),value:S(tt.value)})}else for(var Yt in le)v(le,Yt)&&Pe(Re,{key:Yt,value:S(le[Yt])})},parseQuery:function(le){if(le)for(var Re=this.entries,N=Je(le,"&"),U=0,te,fe;U0?arguments[0]:void 0,N=Y(this,new rn(Re));a||(this.size=N.entries.length)},Sr=ri.prototype;if(l(Sr,{append:function(Re,N){var U=B(this);k(arguments.length,2),Pe(U.entries,{key:S(Re),value:S(N)}),a||this.length++,U.updateURL()},delete:function(le){for(var Re=B(this),N=k(arguments.length,1),U=Re.entries,te=S(le),fe=N<2?void 0:arguments[1],Se=fe===void 0?fe:S(fe),Te=0;TeU.key?1:-1}),Re.updateURL()},forEach:function(Re){for(var N=B(this).entries,U=_(Re,arguments.length>1?arguments[1]:void 0),te=0,fe;te1?bi(arguments[1]):{})}}),p(z)){var Hr=function(Re){return h(this,Z),new z(Re,arguments.length>1?bi(arguments[1]):{})};Z.constructor=Hr,Hr.prototype=Z,e({global:!0,constructor:!0,dontCallGetSet:!0,forced:!0},{Request:Hr})}}return w0={URLSearchParams:ri,getState:B},w0}var cL;function Nme(){return cL||(cL=1,_5()),iL}var R0,fL;function y5(){if(fL)return R0;fL=1,Nme();var e=Gt;return R0=e.URLSearchParams,R0}var dL={},hL={},T0,pL;function S5(){if(pL)return T0;pL=1;var e=sr,t=Ke,r=ur,n=Ve,i=Kc,a=dv,o=zc,s=en,u=ev,l=Object.assign,c=Object.defineProperty,f=t([].concat);return T0=!l||n(function(){if(e&&l({b:1},l(c({},"a",{enumerable:!0,get:function(){c(this,"b",{value:3,enumerable:!1})}}),{b:2})).b!==1)return!0;var d={},h={},p=Symbol("assign detection"),v="abcdefghijklmnopqrst";return d[p]=7,v.split("").forEach(function(_){h[_]=_}),l({},d)[p]!==7||i(l({},h)).join("")!==v})?function(h,p){for(var v=s(h),_=arguments.length,m=1,g=a.f,y=o.f;_>m;)for(var S=u(arguments[m++]),b=g?f(i(S),g(S)):i(S),E=b.length,w=0,R;E>w;)R=b[w++],(!e||r(y,S,R))&&(v[R]=S[R]);return v}:l,T0}var k0,vL;function Ame(){if(vL)return k0;vL=1;var e=_r,t=a4;return k0=function(r,n,i,a){try{return a?n(e(i)[0],i[1]):n(i)}catch(o){t(r,"throw",o)}},k0}var O0,mL;function Lme(){if(mL)return O0;mL=1;var e=uo,t=ur,r=en,n=Ame(),i=i4,a=nv(),o=ti,s=sv,u=aO,l=bv,c=Array;return O0=function(d){var h=r(d),p=a(this),v=arguments.length,_=v>1?arguments[1]:void 0,m=_!==void 0;m&&(_=e(_,v>2?arguments[2]:void 0));var g=l(h),y=0,S,b,E,w,R,O;if(g&&!(this===c&&i(g)))for(b=p?new this:[],w=u(h,g),R=w.next;!(E=t(R,w)).done;y++)O=m?n(w,_,[E.value,y],!0):E.value,s(b,y,O);else for(S=o(h),b=p?new this(S):c(S);S>y;y++)O=m?_(h[y],y):h[y],s(b,y,O);return b.length=y,b},O0}var P0,gL;function Mme(){if(gL)return P0;gL=1;var e=Ke,t=2147483647,r=36,n=1,i=26,a=38,o=700,s=72,u=128,l="-",c=/[^\0-\u007E]/,f=/[.\u3002\uFF0E\uFF61]/g,d="Overflow: input needs wider integers to process",h=r-n,p=RangeError,v=e(f.exec),_=Math.floor,m=String.fromCharCode,g=e("".charCodeAt),y=e([].join),S=e([].push),b=e("".replace),E=e("".split),w=e("".toLowerCase),R=function(T){for(var $=[],L=0,G=T.length;L=55296&&Y<=56319&&L>1,T+=_(T/$);T>h*i>>1;)T=_(T/h),G+=r;return _(G+(h+1)*T/(T+a))},C=function(T){var $=[];T=R(T);var L=T.length,G=u,Y=0,B=s,D,F;for(D=0;D=G&&F_((t-Y)/W))throw new p(d);for(Y+=(Z-G)*W,G=Z,D=0;Dt)throw new p(d);if(F===G){for(var Q=Y,ae=r;;){var re=ae<=B?n:ae>=B+i?i:ae-B;if(Q?@[\\\]^|]/,st=/[\0\t\n\r #/:<>?@[\\\]^|]/,we=/^[\u0000-\u0020]+/,We=/(^|[^\u0000-\u0020])[\u0000-\u0020]+$/,ue=/[\t\n\r]/g,_e,ye=function(M){var J=ee(M,"."),j,A,V,Oe,ve,xt,qt;if(J.length&&J[J.length-1]===""&&J.length--,j=J.length,j>4)return M;for(A=[],V=0;V1&&$(Oe,0)==="0"&&(ve=L(De,Oe)?16:8,Oe=Z(Oe,ve===8?1:2)),Oe==="")xt=0;else{if(!L(ve===10?Je:ve===8?He:et,Oe))return M;xt=k(Oe,ve)}D(A,xt)}for(V=0;V=T(256,5-j))return null}else if(xt>255)return null;for(qt=B(A),V=0;V6))return;for(xt=0;Kt();){if(qt=null,xt>0)if(Kt()==="."&&xt<4)V++;else return;if(!L($e,Kt()))return;for(;L($e,Kt());){if(lr=k(Kt(),10),qt===null)qt=lr;else{if(qt===0)return;qt=qt*10+lr}if(qt>255)return;V++}J[j]=J[j]*256+qt,xt++,(xt===2||xt===4)&&j++}if(xt!==4)return;break}else if(Kt()===":"){if(V++,!Kt())return}else if(Kt())return;J[j++]=Oe}if(A!==null)for(Sn=j-A,j=7;j!==0&&Sn>0;)K=J[j],J[j--]=J[A+Sn-1],J[A+--Sn]=K;else if(j!==8)return;return J},xr=function(M){for(var J=null,j=1,A=null,V=0,Oe=0;Oe<8;Oe++)M[Oe]!==0?(V>j&&(J=A,j=V),A=null,V=0):(A===null&&(A=Oe),++V);return V>j?A:J},tn=function(M){var J,j,A,V;if(typeof M=="number"){for(J=[],j=0;j<4;j++)Q(J,M%256),M=C(M/256);return G(J,".")}if(typeof M=="object"){for(J="",A=xr(M),j=0;j<8;j++)V&&M[j]===0||(V&&(V=!1),A===j?(J+=j?":":"::",V=!0):(J+=Y(M[j],16),j<7&&(J+=":")));return"["+J+"]"}return M},rn={},ri=c({},rn,{" ":1,'"':1,"<":1,">":1,"`":1}),Sr=c({},ri,{"#":1,"?":1,"{":1,"}":1}),ho=c({},Sr,{"/":1,":":1,";":1,"=":1,"@":1,"[":1,"\\":1,"]":1,"^":1,"|":1}),_n=function(M,J){var j=h(M,0);return j>32&&j<127&&!l(J,M)?M:encodeURIComponent(M)},bi={ftp:21,file:null,http:80,https:443,ws:80,wss:443},Hr=function(M,J){var j;return M.length===2&&L(Ie,$(M,0))&&((j=$(M,1))===":"||!J&&j==="|")},le=function(M){var J;return M.length>1&&Hr(Z(M,0,2))&&(M.length===2||(J=$(M,2))==="/"||J==="\\"||J==="?"||J==="#")},Re=function(M){return M==="."||W(M)==="%2e"},N=function(M){return M=W(M),M===".."||M==="%2e."||M===".%2e"||M==="%2e%2e"},U={},te={},fe={},Se={},Te={},Ue={},tt={},Yt={},Qt={},An={},po={},ha={},Wr={},vo={},S1={},rm={},cs={},ni={},b1={},mo={},Ei={},nm=function(M,J,j){var A=v(M),V,Oe,ve;if(J){if(Oe=this.parse(A),Oe)throw new O(Oe);this.searchParams=null}else{if(j!==void 0&&(V=new nm(j,!0)),Oe=this.parse(A,null,V),Oe)throw new O(Oe);ve=w(new E),ve.bindURL(this),this.searchParams=ve}};nm.prototype={type:"URL",parse:function(M,J,j){var A=this,V=J||U,Oe=0,ve="",xt=!1,qt=!1,lr=!1,Sn,K,Kt,wi;for(M=v(M),J||(A.scheme="",A.username="",A.password="",A.host=null,A.port=null,A.path=[],A.query=null,A.fragment=null,A.cannotBeABaseURL=!1,M=F(M,we,""),M=F(M,We,"$1")),M=F(M,ue,""),Sn=f(M);Oe<=Sn.length;){switch(K=Sn[Oe],V){case U:if(K&&L(Ie,K))ve+=W(K),V=te;else{if(J)return re;V=fe;continue}break;case te:if(K&&(L(Pe,K)||K==="+"||K==="-"||K==="."))ve+=W(K);else if(K===":"){if(J&&(A.isSpecial()!==l(bi,ve)||ve==="file"&&(A.includesCredentials()||A.port!==null)||A.scheme==="file"&&!A.host))return;if(A.scheme=ve,J){A.isSpecial()&&bi[A.scheme]===A.port&&(A.port=null);return}ve="",A.scheme==="file"?V=vo:A.isSpecial()&&j&&j.scheme===A.scheme?V=Se:A.isSpecial()?V=Yt:Sn[Oe+1]==="/"?(V=Te,Oe++):(A.cannotBeABaseURL=!0,D(A.path,""),V=b1)}else{if(J)return re;ve="",V=fe,Oe=0;continue}break;case fe:if(!j||j.cannotBeABaseURL&&K!=="#")return re;if(j.cannotBeABaseURL&&K==="#"){A.scheme=j.scheme,A.path=d(j.path),A.query=j.query,A.fragment="",A.cannotBeABaseURL=!0,V=Ei;break}V=j.scheme==="file"?vo:Ue;continue;case Se:if(K==="/"&&Sn[Oe+1]==="/")V=Qt,Oe++;else{V=Ue;continue}break;case Te:if(K==="/"){V=An;break}else{V=ni;continue}case Ue:if(A.scheme=j.scheme,K===_e)A.username=j.username,A.password=j.password,A.host=j.host,A.port=j.port,A.path=d(j.path),A.query=j.query;else if(K==="/"||K==="\\"&&A.isSpecial())V=tt;else if(K==="?")A.username=j.username,A.password=j.password,A.host=j.host,A.port=j.port,A.path=d(j.path),A.query="",V=mo;else if(K==="#")A.username=j.username,A.password=j.password,A.host=j.host,A.port=j.port,A.path=d(j.path),A.query=j.query,A.fragment="",V=Ei;else{A.username=j.username,A.password=j.password,A.host=j.host,A.port=j.port,A.path=d(j.path),A.path.length--,V=ni;continue}break;case tt:if(A.isSpecial()&&(K==="/"||K==="\\"))V=Qt;else if(K==="/")V=An;else{A.username=j.username,A.password=j.password,A.host=j.host,A.port=j.port,V=ni;continue}break;case Yt:if(V=Qt,K!=="/"||$(ve,Oe+1)!=="/")continue;Oe++;break;case Qt:if(K!=="/"&&K!=="\\"){V=An;continue}break;case An:if(K==="@"){xt&&(ve="%40"+ve),xt=!0,Kt=f(ve);for(var im=0;im65535)return Ee;A.port=A.isSpecial()&&am===bi[A.scheme]?null:am,ve=""}if(J)return;V=cs;continue}else return Ee;break;case vo:if(A.scheme="file",K==="/"||K==="\\")V=S1;else if(j&&j.scheme==="file")switch(K){case _e:A.host=j.host,A.path=d(j.path),A.query=j.query;break;case"?":A.host=j.host,A.path=d(j.path),A.query="",V=mo;break;case"#":A.host=j.host,A.path=d(j.path),A.query=j.query,A.fragment="",V=Ei;break;default:le(G(d(Sn,Oe),""))||(A.host=j.host,A.path=d(j.path),A.shortenPath()),V=ni;continue}else{V=ni;continue}break;case S1:if(K==="/"||K==="\\"){V=rm;break}j&&j.scheme==="file"&&!le(G(d(Sn,Oe),""))&&(Hr(j.path[0],!0)?D(A.path,j.path[0]):A.host=j.host),V=ni;continue;case rm:if(K===_e||K==="/"||K==="\\"||K==="?"||K==="#"){if(!J&&Hr(ve))V=ni;else if(ve===""){if(A.host="",J)return;V=cs}else{if(wi=A.parseHost(ve),wi)return wi;if(A.host==="localhost"&&(A.host=""),J)return;ve="",V=cs}continue}else ve+=K;break;case cs:if(A.isSpecial()){if(V=ni,K!=="/"&&K!=="\\")continue}else if(!J&&K==="?")A.query="",V=mo;else if(!J&&K==="#")A.fragment="",V=Ei;else if(K!==_e&&(V=ni,K!=="/"))continue;break;case ni:if(K===_e||K==="/"||K==="\\"&&A.isSpecial()||!J&&(K==="?"||K==="#")){if(N(ve)?(A.shortenPath(),K!=="/"&&!(K==="\\"&&A.isSpecial())&&D(A.path,"")):Re(ve)?K!=="/"&&!(K==="\\"&&A.isSpecial())&&D(A.path,""):(A.scheme==="file"&&!A.path.length&&Hr(ve)&&(A.host&&(A.host=""),ve=$(ve,0)+":"),D(A.path,ve)),ve="",A.scheme==="file"&&(K===_e||K==="?"||K==="#"))for(;A.path.length>1&&A.path[0]==="";)z(A.path);K==="?"?(A.query="",V=mo):K==="#"&&(A.fragment="",V=Ei)}else ve+=_n(K,Sr);break;case b1:K==="?"?(A.query="",V=mo):K==="#"?(A.fragment="",V=Ei):K!==_e&&(A.path[0]+=_n(K,rn));break;case mo:!J&&K==="#"?(A.fragment="",V=Ei):K!==_e&&(K==="'"&&A.isSpecial()?A.query+="%27":K==="#"?A.query+="%23":A.query+=_n(K,rn));break;case Ei:K!==_e&&(A.fragment+=_n(K,ri));break}Oe++}},parseHost:function(M){var J,j,A;if($(M,0)==="["){if($(M,M.length-1)!=="]"||(J=It(Z(M,1,-1)),!J))return ie;this.host=J}else if(this.isSpecial()){if(M=p(M),L(ot,M)||(J=ye(M),J===null))return ie;this.host=J}else{if(L(st,M))return ie;for(J="",j=f(M),A=0;A1?arguments[1]:void 0,V=S(j,new nm(J,!1,A));t||(j.href=V.serialize(),j.origin=V.getOrigin(),j.protocol=V.getProtocol(),j.username=V.getUsername(),j.password=V.getPassword(),j.host=V.getHost(),j.hostname=V.getHostname(),j.port=V.getPort(),j.pathname=V.getPathname(),j.search=V.getSearch(),j.searchParams=V.getSearchParams(),j.hash=V.getHash())},Cr=fs.prototype,yn=function(M,J){return{get:function(){return b(this)[M]()},set:J&&function(j){return b(this)[J](j)},configurable:!0,enumerable:!0}};if(t&&(s(Cr,"href",yn("serialize","setHref")),s(Cr,"origin",yn("getOrigin")),s(Cr,"protocol",yn("getProtocol","setProtocol")),s(Cr,"username",yn("getUsername","setUsername")),s(Cr,"password",yn("getPassword","setPassword")),s(Cr,"host",yn("getHost","setHost")),s(Cr,"hostname",yn("getHostname","setHostname")),s(Cr,"port",yn("getPort","setPort")),s(Cr,"pathname",yn("getPathname","setPathname")),s(Cr,"search",yn("getSearch","setSearch")),s(Cr,"searchParams",yn("getSearchParams")),s(Cr,"hash",yn("getHash","setHash"))),o(Cr,"toJSON",function(){return b(this).serialize()},{enumerable:!0}),o(Cr,"toString",function(){return b(this).serialize()},{enumerable:!0}),R){var E1=R.createObjectURL,w1=R.revokeObjectURL;E1&&o(fs,"createObjectURL",i(E1,R)),w1&&o(fs,"revokeObjectURL",i(w1,R))}return _(fs,"URL"),e({global:!0,constructor:!0,forced:!r,sham:!t},{URL:fs}),hL}var yL;function jme(){return yL||(yL=1,Fme()),dL}var SL={},bL;function qme(){if(bL)return SL;bL=1;var e=ge,t=$n,r=Ve,n=uf(),i=yr,a=Wv(),o=t("URL"),s=a&&r(function(){o.canParse()}),u=r(function(){return o.canParse.length!==1});return e({target:"URL",stat:!0,forced:!s||u},{canParse:function(c){var f=n(arguments.length,1),d=i(c),h=f<2||arguments[1]===void 0?void 0:i(arguments[1]);try{return!!new o(d,h)}catch{return!1}}}),SL}var EL={},wL;function Ume(){if(wL)return EL;wL=1;var e=ge,t=$n,r=uf(),n=yr,i=Wv(),a=t("URL");return e({target:"URL",stat:!0,forced:!i},{parse:function(s){var u=r(arguments.length,1),l=n(s),c=u<2||arguments[1]===void 0?void 0:n(arguments[1]);try{return new a(l,c)}catch{return null}}}),EL}var I0,RL;function Bme(){if(RL)return I0;RL=1,y5(),jme(),qme(),Ume();var e=Gt;return I0=e.URL,I0}var x0,TL;function zme(){if(TL)return x0;TL=1;var e=Bme();return x0=e,x0}var C0,kL;function Hme(){if(kL)return C0;kL=1;var e=zme();return C0=e,C0}var $0,OL;function Wme(){if(OL)return $0;OL=1;var e=Hme();return $0=e,$0}var D0,PL;function Gme(){return PL||(PL=1,D0=Wme()),D0}var N0,IL;function Vme(){return IL||(IL=1,N0=Gme()),N0}var xL;function e1(){return xL||(xL=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.navigate=e.gHistory=e.back=void 0;var n=r(Cme()),i=r(yi()),a=r(Vme()),o=r(kv());const s=()=>{const f={};return{listen:d=>{const h="RW_HISTORY_LISTENER_ID_"+(0,n.default)();return f[h]=d,i.default.addEventListener("popstate",d),h},navigate:(d,h)=>{var m,g,y,S,b,E,w,R;const{pathname:p,search:v,hash:_}=new a.default(((g=(m=i.default)==null?void 0:m.location)==null?void 0:g.origin)+d);(((S=(y=i.default)==null?void 0:y.location)==null?void 0:S.pathname)!==p||((E=(b=i.default)==null?void 0:b.location)==null?void 0:E.search)!==v||((R=(w=i.default)==null?void 0:w.location)==null?void 0:R.hash)!==_)&&(h!=null&&h.replace?i.default.history.replaceState({},"",d):i.default.history.pushState({},"",d));for(const O of(0,o.default)(f))O()},back:()=>{i.default.history.back();for(const d of(0,o.default)(f))d()},remove:d=>{if(f[d]){const h=f[d];i.default.removeEventListener("popstate",h),delete f[d]}else console.warn("History Listener with ID: "+d+" does not exist.")}}},u=e.gHistory=s(),{navigate:l,back:c}=u;e.back=c,e.navigate=l}(d0)),d0}var A0={},L0={},M0,CL;function Yme(){if(CL)return M0;CL=1;var e=y5();return M0=e,M0}var F0,$L;function Qme(){if($L)return F0;$L=1;var e=Yme();return F0=e,F0}var j0,DL;function Kme(){if(DL)return j0;DL=1;var e=Qme();return j0=e,j0}var q0,NL;function Jme(){return NL||(NL=1,q0=Kme()),q0}var U0,AL;function b5(){return AL||(AL=1,U0=Jme()),U0}var LL={},ML;function Xme(){if(ML)return LL;ML=1;var e=ge,t=ua.some,r=Vu,n=r("some");return e({target:"Array",proto:!0,forced:!n},{some:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),LL}var B0,FL;function Zme(){if(FL)return B0;FL=1,Xme();var e=Rt();return B0=e("Array","some"),B0}var z0,jL;function ege(){if(jL)return z0;jL=1;var e=mt,t=Zme(),r=Array.prototype;return z0=function(n){var i=n.some;return n===r||e(r,n)&&i===r.some?t:i},z0}var H0,qL;function tge(){if(qL)return H0;qL=1;var e=ege();return H0=e,H0}var W0,UL;function rge(){if(UL)return W0;UL=1;var e=tge();return W0=e,W0}var G0,BL;function nge(){if(BL)return G0;BL=1;var e=rge();return G0=e,G0}var V0,zL;function ige(){return zL||(zL=1,V0=nge()),V0}var Y0,HL;function age(){return HL||(HL=1,Y0=ige()),Y0}var Q0={},WL={},GL;function oge(){if(GL)return WL;GL=1;var e=ge,t=Uu,r=Yc,n=yr,i=JO(),a=ei,o=XO(),s=t("".slice),u=Math.min,l=o("endsWith");return e({target:"String",proto:!0,forced:!l},{endsWith:function(f){var d=n(a(this));i(f);var h=arguments.length>1?arguments[1]:void 0,p=d.length,v=h===void 0?p:u(r(h),p),_=n(f);return s(d,v-_.length,v)===_}}),WL}var K0,VL;function sge(){if(VL)return K0;VL=1,oge();var e=Rt();return K0=e("String","endsWith"),K0}var J0,YL;function uge(){if(YL)return J0;YL=1;var e=mt,t=sge(),r=String.prototype;return J0=function(n){var i=n.endsWith;return typeof n=="string"||n===r||e(r,n)&&i===r.endsWith?t:i},J0}var X0,QL;function lge(){if(QL)return X0;QL=1;var e=uge();return X0=e,X0}var Z0,KL;function cge(){if(KL)return Z0;KL=1;var e=lge();return Z0=e,Z0}var eS,JL;function fge(){if(JL)return eS;JL=1;var e=cge();return eS=e,eS}var tS,XL;function dge(){return XL||(XL=1,tS=fge()),tS}var rS,ZL;function hge(){return ZL||(ZL=1,rS=dge()),rS}var nS={},eM={},tM={},iS,rM;function pge(){if(rM)return iS;rM=1;var e=_r;return iS=function(){var t=e(this),r="";return t.hasIndices&&(r+="d"),t.global&&(r+="g"),t.ignoreCase&&(r+="i"),t.multiline&&(r+="m"),t.dotAll&&(r+="s"),t.unicode&&(r+="u"),t.unicodeSets&&(r+="v"),t.sticky&&(r+="y"),r},iS}var aS,nM;function vge(){if(nM)return aS;nM=1;var e=ur,t=Vt,r=mt,n=pge(),i=RegExp.prototype;return aS=function(a){var o=a.flags;return o===void 0&&!("flags"in i)&&!t(a,"flags")&&r(i,a)?e(n,a):o},aS}var oS,iM;function mge(){if(iM)return oS;iM=1;var e=nv(),t=Hu,r=TypeError;return oS=function(n){if(e(n))return n;throw new r(t(n)+" is not a constructor")},oS}var sS,aM;function gge(){if(aM)return sS;aM=1;var e=_r,t=mge(),r=rs,n=wt,i=n("species");return sS=function(a,o){var s=e(a).constructor,u;return s===void 0||r(u=e(s)[i])?o:t(u)},sS}var uS,oM;function _ge(){if(oM)return uS;oM=1;var e=Sv.charAt;return uS=function(t,r,n){return r+(n?e(t,r).length:1)},uS}var lS,sM;function yge(){return sM||(sM=1,lS=/./.exec),lS}var cS,uM;function Sge(){if(uM)return cS;uM=1;var e=ur,t=_r,r=jt,n=Cn,i=yge(),a=TypeError;return cS=function(o,s){var u=o.exec;if(r(u)){var l=e(u,o,s);return l!==null&&t(l),l}if(n(o)==="RegExp")return e(i,o,s);throw new a("RegExp#exec called on incompatible receiver")},cS}var lM;function E5(){if(lM)return tM;lM=1;var e=ge,t=ur,r=Uu,n=Jk,i=yv,a=ei,o=Yc,s=yr,u=_r,l=rs,c=Cn,f=m5(),d=vge(),h=tv,p=Ve,v=wt,_=gge(),m=_ge(),g=Sge(),y=ca,S=Qz,b=v("matchAll"),E="RegExp String",w=E+" Iterator",R=y.set,O=y.getterFor(w),k=TypeError,C=r("".indexOf),T=r("".matchAll),$=!!T&&!p(function(){T("a",/./)}),L=n(function(B,D,F,z){R(this,{type:w,regexp:B,string:D,global:F,unicode:z,done:!1})},E,function(){var B=O(this);if(B.done)return i(void 0,!0);var D=B.regexp,F=B.string,z=g(D,F);return z===null?(B.done=!0,i(void 0,!0)):B.global?(s(z[0])===""&&(D.lastIndex=m(F,o(D.lastIndex),B.unicode)),i(z,!1)):(B.done=!0,i(z,!1))}),G=function(Y){var B=u(this),D=s(Y),F=_(B,RegExp),z=s(d(B)),ee,Z,W;return ee=new F(F===RegExp?B.source:B,z),Z=!!~C(z,"g"),W=!!~C(z,"u"),ee.lastIndex=o(B.lastIndex),new L(ee,D,Z,W)};return e({target:"String",proto:!0,forced:$},{matchAll:function(B){var D=a(this),F,z,ee,Z;if(l(B)){if($)return T(D,B)}else{if(f(B)&&(F=s(a(d(B))),!~C(F,"g")))throw new k("`.matchAll` does not allow non-global regexes");if($)return T(D,B);if(ee=h(B,b),ee===void 0&&S&&c(B)==="RegExp"&&(ee=G),ee)return t(ee,B,D)}return z=s(D),Z=new RegExp(B,"g"),t(G,Z,z)}}),tM}var cM;function bge(){return cM||(cM=1,E5()),eM}var fS,fM;function Ege(){if(fM)return fS;fM=1,E5();var e=Rt();return fS=e("String","matchAll"),fS}var dS,dM;function wge(){if(dM)return dS;dM=1;var e=mt,t=Ege(),r=String.prototype;return dS=function(n){var i=n.matchAll;return typeof n=="string"||n===r||e(r,n)&&i===r.matchAll?t:i},dS}var hS,hM;function Rge(){if(hM)return hS;hM=1;var e=wge();return hS=e,hS}var pS,pM;function Tge(){if(pM)return pS;pM=1;var e=Rge();return pS=e,pS}var vS,vM;function kge(){if(vM)return vS;vM=1,bge();var e=Tge();return vS=e,vS}var mS,mM;function Oge(){return mM||(mM=1,mS=kge()),mS}var gS,gM;function Pge(){return gM||(gM=1,gS=Oge()),gS}var _M={},yM;function Ige(){if(yM)return _M;yM=1;var e=ge,t=is,r=nv(),n=Ir,i=nH,a=ti,o=_i,s=sv,u=wt,l=uv,c=Yu(),f=l("slice"),d=u("species"),h=Array,p=Math.max;return e({target:"Array",proto:!0,forced:!f},{slice:function(_,m){var g=o(this),y=a(g),S=i(_,y),b=i(m===void 0?y:m,y),E,w,R;if(t(g)&&(E=g.constructor,r(E)&&(E===h||t(E.prototype))?E=void 0:n(E)&&(E=E[d],E===null&&(E=void 0)),E===h||E===void 0))return c(g,S,b);for(w=new(E===void 0?h:E)(p(b-S,0)),R=0;S=0:p>v;v+=_)v in h&&(f=l(f,h[v],v,d));return f}};return TS={left:o(!1),right:o(!0)},TS}var kS,IM;function R5(){if(IM)return kS;IM=1;var e=ft,t=Dk,r=Cn,n=function(i){return t.slice(0,i.length)===i};return kS=function(){return n("Bun/")?"BUN":n("Cloudflare-Workers")?"CLOUDFLARE":n("Deno/")?"DENO":n("Node.js/")?"NODE":e.Bun&&typeof Bun.version=="string"?"BUN":e.Deno&&typeof Deno.version=="object"?"DENO":r(e.process)==="process"?"NODE":e.window&&e.document?"BROWSER":"REST"}(),kS}var OS,xM;function T5(){if(xM)return OS;xM=1;var e=R5();return OS=e==="NODE",OS}var CM;function Mge(){if(CM)return OM;CM=1;var e=ge,t=w5().left,r=Vu,n=Hc,i=T5(),a=!i&&n>79&&n<83,o=a||!r("reduce");return e({target:"Array",proto:!0,forced:o},{reduce:function(u){var l=arguments.length;return t(this,u,l,l>1?arguments[1]:void 0)}}),OM}var PS,$M;function Fge(){if($M)return PS;$M=1,Mge();var e=Rt();return PS=e("Array","reduce"),PS}var IS,DM;function jge(){if(DM)return IS;DM=1;var e=mt,t=Fge(),r=Array.prototype;return IS=function(n){var i=n.reduce;return n===r||e(r,n)&&i===r.reduce?t:i},IS}var xS,NM;function qge(){if(NM)return xS;NM=1;var e=jge();return xS=e,xS}var CS,AM;function Uge(){if(AM)return CS;AM=1;var e=qge();return CS=e,CS}var $S,LM;function Bge(){if(LM)return $S;LM=1;var e=Uge();return $S=e,$S}var DS,MM;function zge(){return MM||(MM=1,DS=Bge()),DS}var NS,FM;function k5(){return FM||(FM=1,NS=zge()),NS}var AS,jM;function Hge(){if(jM)return AS;jM=1;var e=Rt();return AS=e("Array","keys"),AS}var LS,qM;function Wge(){if(qM)return LS;qM=1;var e=Hge();return LS=e,LS}var MS,UM;function Gge(){if(UM)return MS;UM=1;var e=ns,t=Vt,r=mt,n=Wge(),i=Array.prototype,a={DOMTokenList:!0,NodeList:!0};return MS=function(o){var s=o.keys;return o===i||r(i,o)&&s===i.keys||t(a,e(o))?n:s},MS}var FS,BM;function Vge(){if(BM)return FS;BM=1;var e=Gge();return FS=e,FS}var jS,zM;function Yge(){if(zM)return jS;zM=1;var e=Vge();return jS=e,jS}var qS,HM;function Qge(){return HM||(HM=1,qS=Yge()),qS}var US,WM;function Kge(){return WM||(WM=1,US=Qge()),US}var GM={},VM;function Jge(){if(VM)return GM;VM=1;var e=ge,t=Uu,r=Yc,n=yr,i=JO(),a=ei,o=XO(),s=t("".slice),u=Math.min,l=o("startsWith");return e({target:"String",proto:!0,forced:!l},{startsWith:function(f){var d=n(a(this));i(f);var h=r(u(arguments.length>1?arguments[1]:void 0,d.length)),p=n(f);return s(d,h,h+p.length)===p}}),GM}var BS,YM;function Xge(){if(YM)return BS;YM=1,Jge();var e=Rt();return BS=e("String","startsWith"),BS}var zS,QM;function Zge(){if(QM)return zS;QM=1;var e=mt,t=Xge(),r=String.prototype;return zS=function(n){var i=n.startsWith;return typeof n=="string"||n===r||e(r,n)&&i===r.startsWith?t:i},zS}var HS,KM;function e_e(){if(KM)return HS;KM=1;var e=Zge();return HS=e,HS}var WS,JM;function t_e(){if(JM)return WS;JM=1;var e=e_e();return WS=e,WS}var GS,XM;function r_e(){if(XM)return GS;XM=1;var e=t_e();return GS=e,GS}var VS,ZM;function n_e(){return ZM||(ZM=1,VS=r_e()),VS}var YS,eF;function i_e(){return eF||(eF=1,YS=n_e()),YS}var tF={},rF;function a_e(){if(rF)return tF;rF=1;var e=ge,t=Uu,r=Mk.indexOf,n=Vu,i=t([].indexOf),a=!!i&&1/i([1],1,-0)<0,o=a||!n("indexOf");return e({target:"Array",proto:!0,forced:o},{indexOf:function(u){var l=arguments.length>1?arguments[1]:void 0;return a?i(this,u,l)||0:r(this,u,l)}}),tF}var QS,nF;function o_e(){if(nF)return QS;nF=1,a_e();var e=Rt();return QS=e("Array","indexOf"),QS}var KS,iF;function s_e(){if(iF)return KS;iF=1;var e=mt,t=o_e(),r=Array.prototype;return KS=function(n){var i=n.indexOf;return n===r||e(r,n)&&i===r.indexOf?t:i},KS}var JS,aF;function u_e(){if(aF)return JS;aF=1;var e=s_e();return JS=e,JS}var XS,oF;function l_e(){if(oF)return XS;oF=1;var e=u_e();return XS=e,XS}var ZS,sF;function c_e(){if(sF)return ZS;sF=1;var e=l_e();return ZS=e,ZS}var eb,uF;function f_e(){return uF||(uF=1,eb=c_e()),eb}var tb,lF;function d_e(){return lF||(lF=1,tb=f_e()),tb}var cF={},fF;function h_e(){if(fF)return cF;fF=1;var e=ge,t=Ev,r=sv;return e({target:"Object",stat:!0},{fromEntries:function(i){var a={};return t(i,function(o,s){r(a,o,s)},{AS_ENTRIES:!0}),a}}),cF}var rb,dF;function p_e(){if(dF)return rb;dF=1,h_e();var e=Gt;return rb=e.Object.fromEntries,rb}var nb,hF;function v_e(){if(hF)return nb;hF=1;var e=p_e();return nb=e,nb}var ib,pF;function m_e(){if(pF)return ib;pF=1;var e=v_e();return ib=e,ib}var ab,vF;function g_e(){if(vF)return ab;vF=1;var e=m_e();return ab=e,ab}var ob,mF;function __e(){return mF||(mF=1,ob=g_e()),ob}var sb,gF;function y_e(){return gF||(gF=1,sb=__e()),sb}var _F={},yF;function O5(){if(yF)return _F;yF=1;var e=ge,t=en,r=ti,n=lo;return e({target:"Array",proto:!0},{at:function(a){var o=t(this),s=r(o),u=n(a),l=u>=0?u:s+u;return l<0||l>=s?void 0:o[l]}}),_F}var ub,SF;function S_e(){if(SF)return ub;SF=1,O5();var e=Rt();return ub=e("Array","at"),ub}var lb,bF;function b_e(){if(bF)return lb;bF=1;var e=S_e();return lb=e,lb}var cb,EF;function E_e(){if(EF)return cb;EF=1;var e=b_e();return cb=e,cb}var wF={},RF;function w_e(){return RF||(RF=1,O5()),wF}var fb,TF;function R_e(){if(TF)return fb;TF=1;var e=E_e();return w_e(),fb=e,fb}var kF={},OF;function T_e(){if(OF)return kF;OF=1;var e=ge,t=Ke,r=ei,n=lo,i=yr,a=Ve,o=t("".charAt),s=a(function(){return"𠮷".at(-2)!=="\uD842"});return e({target:"String",proto:!0,forced:s},{at:function(l){var c=i(r(this)),f=c.length,d=n(l),h=d>=0?d:f+d;return h<0||h>=f?void 0:o(c,h)}}),kF}var db,PF;function k_e(){if(PF)return db;PF=1,T_e();var e=Rt();return db=e("String","at"),db}var hb,IF;function O_e(){if(IF)return hb;IF=1;var e=k_e();return hb=e,hb}var pb,xF;function P_e(){if(xF)return pb;xF=1;var e=O_e();return pb=e,pb}var CF={},$F;function I_e(){if($F)return CF;$F=1;var e=ge,t=Sv.charAt,r=ei,n=lo,i=yr;return e({target:"String",proto:!0,forced:!0},{at:function(o){var s=i(r(this)),u=s.length,l=n(o),c=l>=0?l:u+l;return c<0||c>=u?void 0:t(s,c)}}),CF}var vb,DF;function x_e(){if(DF)return vb;DF=1,P_e(),I_e();var e=Rt();return vb=e("String","at"),vb}var mb,NF;function C_e(){if(NF)return mb;NF=1;var e=mt,t=R_e(),r=x_e(),n=Array.prototype,i=String.prototype;return mb=function(a){var o=a.at;return a===n||e(n,a)&&o===n.at?t:typeof a=="string"||a===i||e(i,a)&&o===i.at?r:o},mb}var gb,AF;function $_e(){return AF||(AF=1,gb=C_e()),gb}var _b,LF;function D_e(){return LF||(LF=1,_b=$_e()),_b}var yb={},Sb={},MF={},FF;function N_e(){if(FF)return MF;FF=1;var e=ge,t=S5();return e({target:"Object",stat:!0,arity:2,forced:Object.assign!==t},{assign:t}),MF}var bb,jF;function A_e(){if(jF)return bb;jF=1,N_e();var e=Gt;return bb=e.Object.assign,bb}var Eb,qF;function L_e(){if(qF)return Eb;qF=1;var e=A_e();return Eb=e,Eb}var wb,UF;function M_e(){if(UF)return wb;UF=1;var e=L_e();return wb=e,wb}var Rb,BF;function F_e(){if(BF)return Rb;BF=1;var e=M_e();return Rb=e,Rb}var Tb,zF;function j_e(){return zF||(zF=1,Tb=F_e()),Tb}var kb,HF;function q_e(){return HF||(HF=1,kb=j_e()),kb}var WF={},GF;function U_e(){if(GF)return WF;GF=1;var e=ge,t=ua.find,r="find",n=!0;return r in[]&&Array(1)[r](function(){n=!1}),e({target:"Array",proto:!0,forced:n},{find:function(a){return t(this,a,arguments.length>1?arguments[1]:void 0)}}),WF}var Ob,VF;function B_e(){if(VF)return Ob;VF=1,U_e();var e=Rt();return Ob=e("Array","find"),Ob}var Pb,YF;function z_e(){if(YF)return Pb;YF=1;var e=mt,t=B_e(),r=Array.prototype;return Pb=function(n){var i=n.find;return n===r||e(r,n)&&i===r.find?t:i},Pb}var Ib,QF;function H_e(){if(QF)return Ib;QF=1;var e=z_e();return Ib=e,Ib}var xb,KF;function W_e(){if(KF)return xb;KF=1;var e=H_e();return xb=e,xb}var Cb,JF;function G_e(){if(JF)return Cb;JF=1;var e=W_e();return Cb=e,Cb}var $b,XF;function V_e(){return XF||(XF=1,$b=G_e()),$b}var Db,ZF;function Y_e(){return ZF||(ZF=1,Db=V_e()),Db}var ej={},tj;function Q_e(){if(tj)return ej;tj=1;var e=ge,t=w5().right,r=Vu,n=Hc,i=T5(),a=!i&&n>79&&n<83,o=a||!r("reduceRight");return e({target:"Array",proto:!0,forced:o},{reduceRight:function(u){return t(this,u,arguments.length,arguments.length>1?arguments[1]:void 0)}}),ej}var Nb,rj;function K_e(){if(rj)return Nb;rj=1,Q_e();var e=Rt();return Nb=e("Array","reduceRight"),Nb}var Ab,nj;function J_e(){if(nj)return Ab;nj=1;var e=mt,t=K_e(),r=Array.prototype;return Ab=function(n){var i=n.reduceRight;return n===r||e(r,n)&&i===r.reduceRight?t:i},Ab}var Lb,ij;function X_e(){if(ij)return Lb;ij=1;var e=J_e();return Lb=e,Lb}var Mb,aj;function Z_e(){if(aj)return Mb;aj=1;var e=X_e();return Mb=e,Mb}var Fb,oj;function eye(){if(oj)return Fb;oj=1;var e=Z_e();return Fb=e,Fb}var jb,sj;function tye(){return sj||(sj=1,jb=eye()),jb}var qb,uj;function rye(){return uj||(uj=1,qb=tye()),qb}var Ub={},lj={},cj={},Bb,fj;function P5(){if(fj)return Bb;fj=1;var e=ft,t=Xp,r=jt,n=R5(),i=Dk,a=Yu(),o=uf(),s=e.Function,u=/MSIE .\./.test(i)||n==="BUN"&&function(){var l=e.Bun.version.split(".");return l.length<3||l[0]==="0"&&(l[1]<3||l[1]==="3"&&l[2]==="0")}();return Bb=function(l,c){var f=c?2:1;return u?function(d,h){var p=o(arguments.length,1)>f,v=r(d)?d:s(d),_=p?a(arguments,f):[],m=p?function(){t(v,this,_)}:v;return c?l(m,h):l(m)}:l},Bb}var dj;function nye(){if(dj)return cj;dj=1;var e=ge,t=ft,r=P5(),n=r(t.setInterval,!0);return e({global:!0,bind:!0,forced:t.setInterval!==n},{setInterval:n}),cj}var hj={},pj;function iye(){if(pj)return hj;pj=1;var e=ge,t=ft,r=P5(),n=r(t.setTimeout,!0);return e({global:!0,bind:!0,forced:t.setTimeout!==n},{setTimeout:n}),hj}var vj;function aye(){return vj||(vj=1,nye(),iye()),lj}var zb,mj;function oye(){if(mj)return zb;mj=1,aye();var e=Gt;return zb=e.setTimeout,zb}var Hb,gj;function sye(){if(gj)return Hb;gj=1;var e=oye();return Hb=e,Hb}var Wb,_j;function uye(){if(_j)return Wb;_j=1;var e=sye();return Wb=e,Wb}var Gb,yj;function lye(){return yj||(yj=1,Gb=uye()),Gb}var Vb,Sj;function cye(){return Sj||(Sj=1,Vb=lye()),Vb}var Yb={},bj;function fye(){return bj||(bj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.resetFocus=e.getFocus=e.getAnnouncement=void 0;var n=r(yi());const i=()=>{var l,c,f,d,h;const s=(c=(l=n.default)==null?void 0:l.document.querySelectorAll("[data-redwood-route-announcement]"))==null?void 0:c[0];if(s!=null&&s.textContent)return s.textContent;const u=(f=n.default)==null?void 0:f.document.querySelector("h1");return u!=null&&u.textContent?u.textContent:(d=n.default)!=null&&d.document.title?document.title:`new page at ${(h=n.default)==null?void 0:h.location.pathname}`};e.getAnnouncement=i;const a=()=>{var u,l;const s=(l=(u=n.default)==null?void 0:u.document.querySelectorAll("[data-redwood-route-focus]"))==null?void 0:l[0];return!s||!s.children.length||s.children[0].tabIndex<0?null:s.children[0]};e.getFocus=a;const o=()=>{var s,u,l;(s=n.default)==null||s.document.body.setAttribute("tabindex","-1"),(u=n.default)==null||u.document.body.focus(),(l=n.default)==null||l.document.body.removeAttribute("tabindex")};e.resetFocus=o}(Yb)),Yb}var Qb={},Ej;function t1(){return Ej||(Ej=1,function(e){var t=xe;t(e,"__esModule",{value:!0}),e.usePageLoadingContext=e.PageLoadingContextProvider=void 0;var r=I,n=co(),i=P;const a=(0,n.createNamedContext)("PageLoading"),o=u=>{let{children:l,delay:c=1e3}=u;const[f,d]=(0,r.useState)(!1);return(0,i.jsx)(a.Provider,{value:{loading:f,setPageLoadingContext:d,delay:c},children:l})};e.PageLoadingContextProvider=o;const s=()=>{const u=(0,r.useContext)(a);if(!u)throw new Error("usePageLoadingContext must be used within a PageLoadingContext provider");return u};e.usePageLoadingContext=s}(Qb)),Qb}var wj;function dye(){return wj||(wj=1,function(e){var t=xe,r=Dn.default,n=dt.default;t(e,"__esModule",{value:!0}),e.ActiveRouteLoader=void 0;var i=n(cye()),a=n(yi()),o=r(I),s=fye(),u=t1(),l=co(),c=P;let f=!1;if(typeof window<"u"){const v=document.getElementById("redwood-app");v&&v.children.length>0&&(f=!0)}let d=!0;const h=v=>{let{children:_}=v;const{loading:m,setPageLoadingContext:g,delay:y}=(0,u.usePageLoadingContext)();return(0,o.useEffect)(()=>{const S=(0,i.default)(()=>{g(!0)},y);return()=>{clearTimeout(S),g(!1)}},[y,g]),(0,c.jsx)(c.Fragment,{children:m?_:null})},p=v=>{let{spec:_,params:m,whileLoadingPage:g}=v;const y=(0,o.useRef)(null),b=a.default.__REDWOOD__PRERENDERING||f&&d?_.prerenderLoader(_.name).default:_.LazyComponent;return d&&(d=!1),(0,o.useEffect)(()=>{if((0,l.inIframe)())return;y.current&&(y.current.innerText=(0,s.getAnnouncement)());const E=(0,s.getFocus)();E?E.focus():(0,s.resetFocus)()},[_,m]),m&&(delete m.ref,delete m.key),(0,c.jsxs)(o.Suspense,{fallback:(0,c.jsx)(h,{children:g==null?void 0:g()}),children:[(0,c.jsx)(b,{...m}),(0,c.jsx)("div",{id:"redwood-announcer",style:{position:"absolute",top:0,width:1,height:1,padding:0,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:0},role:"alert","aria-live":"assertive","aria-atomic":"true",ref:y})]})};e.ActiveRouteLoader=p}(Ub)),Ub}var Kb={},Jb={},Rj;function Gv(){return Rj||(Rj=1,function(e){var t=xe,r=Dn.default;t(e,"__esModule",{value:!0}),e.useRouterState=e.RouterContextProvider=void 0;var n=r(I),i=ov(),a=P;const o=(0,n.createContext)(void 0),s=l=>{let{useAuth:c,paramTypes:f,routes:d,activeRouteName:h,children:p}=l;const v=(0,n.useMemo)(()=>({useAuth:c||i.useNoAuth,paramTypes:f,routes:d,activeRouteName:h}),[c,f,d,h]);return(0,a.jsx)(o.Provider,{value:v,children:p})};e.RouterContextProvider=s;const u=()=>{const l=(0,n.useContext)(o);if(l===void 0)throw new Error("useRouterState must be used within a RouterContextProvider");return l};e.useRouterState=u}(Jb)),Jb}var Tj;function hye(){return Tj||(Tj=1,function(e){var t=xe,r=Dn.default,n=dt.default;t(e,"__esModule",{value:!0}),e.AuthenticatedRoute=void 0;var i=n(yi()),a=r(I),o=i1(),s=r1(),u=Gv(),l=P;const c=f=>{let{unauthenticated:d,roles:h,whileLoadingAuth:p,children:v}=f;const _=(0,u.useRouterState)(),{loading:m,isAuthenticated:g,hasRole:y}=_.useAuth();if((0,a.useCallback)(()=>!(g&&(!h||y(h))),[g,h,y])()){if(m)return(p==null?void 0:p())||null;{const b=i.default.location.pathname+encodeURIComponent(i.default.location.search);if(!s.routes[d])throw new Error(`We could not find a route named ${d}`);let E;try{E=s.routes[d]()}catch(w){throw w instanceof Error&&/Missing parameter .* for route/.test(w.message)?new Error(`Redirecting to route "${d}" would require route parameters, which currently is not supported. Please choose a different route`):new Error(`Could not redirect to the route named ${d}`)}return(0,l.jsx)(o.Redirect,{to:`${E}?redirectTo=${b}`})}}return(0,l.jsx)(l.Fragment,{children:v})};e.AuthenticatedRoute=c}(Kb)),Kb}var Xb={},kj;function I5(){return kj||(kj=1,function(e){var t=xe,r=Dn.default;t(e,"__esModule",{value:!0}),e.useParams=e.ParamsProvider=e.ParamsContext=void 0;var n=r(I),i=co(),a=P;const o=e.ParamsContext=(0,i.createNamedContext)("Params"),s=l=>{let{allParams:c,children:f}=l;return(0,a.jsx)(o.Provider,{value:{params:{...c}},children:f})};e.ParamsProvider=s;const u=()=>{const l=(0,n.useContext)(o);if(l===void 0)throw new Error("useParams must be used within a ParamsProvider");return l.params};e.useParams=u}(Xb)),Xb}var Zb,Oj;function pye(){return Oj||(Oj=1,Zb={}),Zb}var Pj;function r1(){return Pj||(Pj=1,function(e){var t=xe,r=Dn.default,n=dt.default;t(e,"__esModule",{value:!0}),t(e,"PageType",{enumerable:!0,get:function(){return _.PageType}}),e.Route=E,e.Router=void 0,t(e,"isRoute",{enumerable:!0,get:function(){return _.isValidRoute}}),e.routes=void 0;var i=n(q_e()),a=n(as),o=n(Y_e()),s=n(kv()),u=n(rye()),l=r(I),c=dye(),f=hye(),d=i1(),h=n1(),p=t1(),v=I5(),_=x5(),m=Gv(),g=pye(),y=co(),S=P;const b=e.routes={};function E(k){return(0,S.jsx)(S.Fragment,{})}const w=k=>{let{useAuth:C,paramTypes:T,pageLoadingDelay:$,trailingSlashes:L="never",children:G}=k;return(0,S.jsx)(h.LocationProvider,{trailingSlashes:L,children:(0,S.jsx)(R,{useAuth:C,paramTypes:T,pageLoadingDelay:$,children:G})})};e.Router=w;const R=k=>{let{useAuth:C,paramTypes:T,pageLoadingDelay:$,children:L}=k;const G=(0,h.useLocation)(),Y=(0,l.useMemo)(()=>(0,y.analyzeRoutes)(L,{currentPathName:G.pathname,userParamTypes:T}),[G.pathname,L,T]),{pathRouteMap:B,hasHomeRoute:D,namedRoutesMap:F,NotFoundPage:z,activeRoutePath:ee}=Y;(0,i.default)(b,F);const Z=(0,a.default)(b).length>0;if((!D&&G.pathname==="/"||!Z)&&typeof g.SplashPage<"u")return(0,S.jsx)(g.SplashPage,{hasGeneratedRoutes:Z,allStandardRoutes:B});if(!ee)return z?(0,S.jsx)(m.RouterContextProvider,{useAuth:C,paramTypes:T,routes:Y,children:(0,S.jsx)(v.ParamsProvider,{children:(0,S.jsx)(p.PageLoadingContextProvider,{delay:$,children:(0,S.jsx)(c.ActiveRouteLoader,{spec:(0,y.normalizePage)(z),path:G.pathname})})})}):null;const{path:Q,page:ae,name:re,redirect:ie,whileLoadingPage:Ee,sets:Ie}=B[ee];if(!Q)throw new Error(`Route "${re}" needs to specify a path`);(0,y.validatePath)(Q,re||Q);const{params:Pe}=(0,y.matchPath)(Q,G.pathname,{userParamTypes:T}),De={...(0,y.parseSearch)(G.search),...Pe};let He;if(ie)if(ie[0]==="/")He=(0,y.replaceParams)(ie,De);else{var Je;const et=(0,o.default)(Je=(0,s.default)(B)).call(Je,ot=>ot.name===ie);if(!et)throw new Error(`Redirect target route "${ie}" does not exist for route "${re}"`);He=(0,y.replaceParams)(et.path,De)}return(0,S.jsx)(m.RouterContextProvider,{useAuth:C,paramTypes:T,routes:Y,activeRouteName:re,children:(0,S.jsx)(v.ParamsProvider,{allParams:De,children:(0,S.jsxs)(p.PageLoadingContextProvider,{delay:$,children:[He&&(0,S.jsx)(d.Redirect,{to:He}),!He&&ae&&(0,S.jsx)(O,{sets:Ie,children:(0,S.jsx)(c.ActiveRouteLoader,{path:Q,spec:(0,y.normalizePage)(ae),params:De,whileLoadingPage:Ee})})]})})})},O=(0,l.memo)(k=>{let{sets:C,children:T}=k;return!C||C.length===0?T:(0,u.default)(C).call(C,($,L)=>{var G;let Y=(0,u.default)(G=L.wrappers).call(G,(B,D,F)=>l.default.createElement(D,{...L.props,key:L.id+"-"+F},B),$);if(L.isPrivate){const B=L.props.unauthenticated;if(!B||typeof B!="string")throw new Error("You must specify an `unauthenticated` route when using PrivateSet");Y=(0,S.jsx)(f.AuthenticatedRoute,{...L.props,unauthenticated:B,children:Y})}return Y},T)})}(Sb)),Sb}var Ij;function x5(){return Ij||(Ij=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.isNotFoundRoute=l,e.isRedirectRoute=u,e.isStandardRoute=s,e.isValidRoute=c;var n=r(Hv()),i=I,a=r1();const o=f=>(0,i.isValidElement)(f)&&f.type===a.Route;function s(f){return!f.props.notfound&&!f.props.redirect}function u(f){return!!f.props.redirect}function l(f){return!!f.props.notfound}function c(f){const d=o(f);if(d){var h;const p=f.props.notfound||f.props.redirect,v=(0,n.default)(h=[!f.props.notfound&&"path",!f.props.redirect&&"page",!p&&"name"]).call(h,Boolean),_=(0,n.default)(v).call(v,m=>!(m in f.props));if(_.length>0){const m=f.props.name||f.props.path?`for "${f.props.name||f.props.path}" `:"";throw new Error(`Route element ${m}is missing required props: ${_.join(", ")}`)}}return d}}(yb)),yb}var eE={},xj;function C5(){return xj||(xj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.Private=o,e.PrivateSet=s,e.Set=a,e.isSetNode=e.isPrivateSetNode=e.isPrivateNode=void 0;var n=r(I),i=P;function a(f){return(0,i.jsx)(i.Fragment,{children:f.children})}function o(f){return(0,i.jsx)(i.Fragment,{children:f.children})}function s(f){return(0,i.jsx)(i.Fragment,{children:f.children})}const u=f=>n.default.isValidElement(f)&&(f.type===a||f.type===s||f.type===o)&&f.props.children;e.isSetNode=u;const l=f=>n.default.isValidElement(f)&&f.type===s;e.isPrivateSetNode=l;const c=f=>n.default.isValidElement(f)&&f.type===o;e.isPrivateNode=c}(eE)),eE}var Cj;function co(){return Cj||(Cj=1,function(e){var t=xe,r=Dn.default,n=dt.default;t(e,"__esModule",{value:!0}),e.analyzeRoutes=ee,e.createNamedContext=R,e.flattenAll=O,e.flattenSearchParams=B,e.getRouteRegexAndParams=$,e.inIframe=z,e.isSpec=D,e.matchPath=T,e.normalizePage=F,e.paramsForRoute=k,e.parseSearch=L,e.replaceParams=Y,e.validatePath=G;var i=n(v5()),a=n(Pge()),o=n(Ov()),s=n(Lge()),u=n(k5()),l=n(b5()),c=n(Kge()),f=n(i_e()),d=n(d_e()),h=n(av),p=n(Hv()),v=n(as),_=n(ZO()),m=n(y_e()),g=n(KO()),y=n(Tv()),S=n(D_e()),b=r(I),E=x5(),w=C5();function R(W,Q){const ae=b.default.createContext(Q);return ae.displayName=W,ae}function O(W){const Q=b.Children.toArray(W);return(0,i.default)(Q).call(Q,ae=>(0,b.isValidElement)(ae)&&ae.props.children?[ae,...O(ae.props.children)]:[ae])}function k(W){var Q;const ae=[...(0,a.default)(W).call(W,/\{([^}]+)\}/g)];return(0,o.default)(Q=(0,o.default)(ae).call(ae,re=>re[1])).call(Q,re=>{const ie=re.split(":");let Ee=ie[0];(0,s.default)(Ee).call(Ee,-3)==="..."&&(Ee=(0,s.default)(Ee).call(Ee,0,-3));let Ie=ie[1];return Ie||(Ie=(0,s.default)(re).call(re,-3)==="..."?"Glob":"String"),[Ee,Ie,`{${re}}`]})}const C={String:{match:/[^/]+/},Int:{match:/\d+/,parse:Number},Float:{match:/[-+]?(?:\d*\.?\d+|\d+\.?\d*)(?:[eE][-+]?\d+)?/,parse:Number},Boolean:{match:/true|false/,parse:W=>W==="true"},Glob:{match:/.*/}};function T(W,Q){var ae;let{userParamTypes:re,matchSubPaths:ie}=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{userParamTypes:{},matchSubPaths:!1};const Ee={...C,...re},{matchRegex:Ie,routeParams:Pe}=$(W,{matchSubPaths:ie,allParamTypes:Ee}),$e=[...(0,a.default)(Q).call(Q,Ie)];if($e.length===0)return{match:!1};const De=(0,s.default)(ae=$e[0]).call(ae,1);return Pe.length>0?{match:!0,params:(0,u.default)(De).call(De,(Je,et,ot)=>{const[st,we]=Pe[ot],We=Ee[we];let ue=et;return typeof(We==null?void 0:We.parse)=="function"&&(ue=We.parse(et)),{...Je,[st]:ue}},{})}:{match:!0}}function $(W){var Pe;let{matchSubPaths:Q=!1,allParamTypes:ae=C}=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},re=W;const ie=k(W);for(const[$e,De,He]of ie){const Je=(Pe=ae[De])==null?void 0:Pe.match,et=(Je==null?void 0:Je.source)||"[^/]+";re=re.replace(He,`(${et})`)}const Ee=Q?new RegExp(`^${re}(?:/.*)?$`,"g"):new RegExp(`^${re}$`,"g"),Ie=Q?`^${re}(?:/.*)?$`:`^${re}$`;return{matchRegex:Ee,routeParams:ie,matchRegexString:Ie}}function L(W){var Q;const ae=new l.default(W);return(0,u.default)(Q=[...(0,c.default)(ae).call(ae)]).call(Q,(re,ie)=>({...re,[ie]:ae.get(ie)}),{})}function G(W,Q){if(!(0,f.default)(W).call(W,"/"))throw new Error(`Route path for ${Q} does not begin with a slash: "${W}"`);if((0,d.default)(W).call(W," ")>=0)throw new Error(`Route path for ${Q} contains spaces: "${W}"`);if(/{(?:ref|key)(?::|})/.test(W))throw new Error([`Route for ${Q} contains ref or key as a path parameter: "${W}"`,"`ref` and `key` shouldn't be used as path parameters because they're special React props.","You can fix this by renaming the path parameter."].join(` `));const ae=(0,a.default)(W).call(W,/\{([^}]+)\}/g),re={};for(const ie of ae){const Ee=ie[1].split(":")[0];if(re[Ee])throw new Error(`Route path contains duplicate parameter: "${W}"`);re[Ee]=!0}}function Y(W){var Q;let ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const re=k(W);let ie=W;(0,h.default)(re).call(re,$e=>{const[De,He,Je]=$e,et=ae[De];if(et!==void 0)ie=ie.replace(Je,et);else throw new Error(`Missing parameter '${De}' for route '${W}' when generating a navigation URL.`)});const Ee=(0,o.default)(re).call(re,$e=>$e[0]),Ie=(0,p.default)(Q=(0,v.default)(ae)).call(Q,$e=>!(0,_.default)(Ee).call(Ee,$e)),Pe=[];if((0,h.default)(Ie).call(Ie,$e=>{Pe.push(`${$e}=${ae[$e]}`)}),Ie.length){const $e=(0,m.default)((0,o.default)(Ie).call(Ie,De=>[De,`${ae[De]}`]));ie+=`?${new l.default($e).toString()}`}return ie}function B(W){const Q=[];for(const[ae,re]of(0,g.default)(L(W)))Q.push({[ae]:re});return Q}function D(W){return W.LazyComponent!==void 0}function F(W){return D(W)?W:{name:W.name,prerenderLoader:()=>({default:W}),LazyComponent:W}}function z(){try{return(Ut==null?void 0:Ut.self)!==(Ut==null?void 0:Ut.top)}catch{return!0}}function ee(W,Q){let{currentPathName:ae,userParamTypes:re}=Q;const ie={},Ee={};let Ie=!1,Pe,$e;const De=He=>{let{nodes:Je,whileLoadingPageFromSet:et,sets:ot=[]}=He,st=0;(0,h.default)(Je).call(Je,we=>{if((0,E.isValidRoute)(we)){const We=we;if((0,E.isNotFoundRoute)(We)){Pe=We.props.page;return}if(We.props.path==="/"&&(Ie=!0),(0,E.isRedirectRoute)(We)){const{name:ue,redirect:_e,path:ye}=We.props;G(ye,ue||ye);const{match:It}=T(ye,ae,{userParamTypes:re});It&&!$e&&($e=ye),ie[ye]={redirect:_e,name:ue||null,path:ye,page:null,sets:ot},ue&&(Ee[ue]=function(){let xr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Y(ye,xr)})}if((0,E.isStandardRoute)(We)){const{name:ue,path:_e,page:ye}=We.props;G(_e,ue);const{match:It}=T(_e,ae,{userParamTypes:re});It&&!$e&&($e=_e),ie[_e]={redirect:null,name:ue,path:_e,whileLoadingPage:We.props.whileLoadingPage||et,page:ye,sets:ot},Ee[ue]=function(){let xr=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return Y(_e,xr)}}}if((0,w.isSetNode)(we)){const{children:We,whileLoadingPage:ue,wrap:_e,...ye}=we.props;let It=[];_e&&(It=(0,y.default)(_e)?_e:[_e]),st=st+1,De({nodes:b.Children.toArray(We),whileLoadingPageFromSet:ue||et,sets:[...ot,{id:Z(st,ot),wrappers:It,isPrivate:(0,w.isPrivateSetNode)(we)||(0,w.isPrivateNode)(we)||!!ye.private,props:ye}]})}})};return De({nodes:b.Children.toArray(W)}),{pathRouteMap:ie,namedRoutesMap:Ee,hasHomeRoute:Ie,NotFoundPage:Pe,activeRoutePath:$e}}function Z(W,Q){var re;return Q.length===0?W.toString():((re=(0,S.default)(Q).call(Q,-1))==null?void 0:re.id)+"."+W}}(nS)),nS}var $j;function n1(){return $j||($j=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.useLocation=e.LocationProvider=e.LocationContext=void 0;var n=r(hge()),i=r(yi()),a=r(I),o=e1(),s=co(),u=P;const l=e.LocationContext=(0,s.createNamedContext)("Location");class c extends a.default.Component{constructor(){super(...arguments),this.HISTORY_LISTENER_ID=void 0,this.state={context:this.getContext()}}getContext(){var m,g,y;let h;if(typeof window<"u"){const{pathname:S}=window.location;switch(this.props.trailingSlashes){case"never":(0,n.default)(S).call(S,"/")&&window.history.replaceState({},"",S.substr(0,S.length-1));break;case"always":(0,n.default)(S).call(S,"/")||window.history.replaceState({},"",S+"/");break}h=window.location}else h={pathname:((m=this.context)==null?void 0:m.pathname)||"",search:((g=this.context)==null?void 0:g.search)||"",hash:((y=this.context)==null?void 0:y.hash)||""};const{pathname:p,search:v,hash:_}=this.props.location||h;return{pathname:p,search:v,hash:_}}componentDidMount(){this.HISTORY_LISTENER_ID=o.gHistory.listen(()=>{const h=this.getContext();this.setState(p=>{var v;return(h.pathname!==p.context.pathname||h.search!==p.context.search)&&((v=i.default)==null||v.scrollTo(0,0)),{context:h}})})}componentWillUnmount(){this.HISTORY_LISTENER_ID&&o.gHistory.remove(this.HISTORY_LISTENER_ID)}render(){return(0,u.jsx)(l.Provider,{value:this.state.context,children:this.props.children})}}e.LocationProvider=c,c.contextType=l;const f=()=>{const d=a.default.useContext(l);if(d===void 0)throw new Error("useLocation must be used within a LocationProvider");return d};e.useLocation=f}(Q0)),Q0}var Dj;function $5(){return Dj||(Dj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.useMatch=void 0;var n=r(b5()),i=r(age()),a=r(as),o=r(KO()),s=r(b4()),u=n1(),l=co();const c=(d,h)=>{const p=(0,u.useLocation)();if(!p)return{match:!1};if(h!=null&&h.searchParams){var v;const g=new n.default(p.search);if((0,i.default)(v=h.searchParams).call(v,S=>{if(typeof S=="string")return!g.has(S);var b;return(0,i.default)(b=(0,a.default)(S)).call(b,E=>S[E]!=g.get(E))}))return{match:!1}}const _=(0,l.matchPath)(d,p.pathname,{matchSubPaths:h==null?void 0:h.matchSubPaths});if(!_.match)return{match:!1};const m=(0,o.default)((h==null?void 0:h.routeParams)||{});if(m.length>0){if(!f(_)||!_.params)return{match:!1};if(!(0,s.default)(m).call(m,y=>{let[S,b]=y;return _.params[S]===b}))return{match:!1}}return _};e.useMatch=c;function f(d){return d!==null&&typeof d=="object"&&"params"in d}}(L0)),L0}var Nj;function i1(){return Nj||(Nj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.Redirect=e.NavLink=e.Link=void 0;var n=r(Hv()),i=I,a=e1(),o=$5(),s=co(),u=P;e.Link=(0,i.forwardRef)((c,f)=>{let{to:d,onClick:h,...p}=c;return(0,u.jsx)("a",{href:d,ref:f,...p,onClick:v=>{if(!(v.button!==0||v.altKey||v.ctrlKey||v.metaKey||v.shiftKey))if(v.preventDefault(),h){const _=h(v);(typeof _!="boolean"||_)&&(0,a.navigate)(d)}else(0,a.navigate)(d)}})}),e.NavLink=(0,i.forwardRef)((c,f)=>{var d;let{to:h,activeClassName:p,activeMatchParams:v,matchSubPaths:_,className:m,onClick:g,...y}=c;const[S,b]=h.split("?"),E=v||(0,s.flattenSearchParams)(b),w=(0,o.useMatch)(S,{searchParams:E,matchSubPaths:_}),R=(0,n.default)(d=[m,w.match&&p]).call(d,Boolean).join(" ");return(0,u.jsx)("a",{href:h,ref:f,className:R,...y,onClick:O=>{if(!(O.button!==0||O.altKey||O.ctrlKey||O.metaKey||O.shiftKey))if(O.preventDefault(),g){const k=g(O);(typeof k!="boolean"||k)&&(0,a.navigate)(h)}else(0,a.navigate)(h)}})});const l=c=>{let{to:f,options:d}=c;return(0,i.useEffect)(()=>{(0,a.navigate)(f,d)},[f,d]),null};e.Redirect=l}(A0)),A0}var tE={},Aj;function vye(){return Aj||(Aj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.default=void 0,r(I);var n=P;const i=a=>{let{children:o,visuallyHidden:s=!1,...u}=a;const l={position:"absolute",top:"0",width:"1",height:"1",padding:"0",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0"};return(0,n.jsx)("div",{...u,"data-redwood-route-announcement":!0,style:s?l:{},children:o})};e.default=i}(tE)),tE}var rE={},Lj;function mye(){return Lj||(Lj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.default=void 0,r(I);var n=P;const i=a=>{let{children:o,...s}=a;return(0,n.jsx)("div",{...s,"data-redwood-route-focus":!0,children:o})};e.default=i}(rE)),rE}var nE={},Mj;function D5(){return Mj||(Mj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.useRouteName=s;var n=r(ZO()),i=r(as),a=Gv(),o=N5();function s(){const c=(0,a.useRouterState)().activeRouteName;if(u(c))return c}function u(l){var c;return typeof l=="string"&&(0,n.default)(c=(0,i.default)(o.routes)).call(c,l)}}(nE)),nE}var iE={},Fj;function gye(){return Fj||(Fj=1,function(e){var t=xe,r=dt.default;t(e,"__esModule",{value:!0}),e.useRoutePath=u,e.useRoutePaths=s;var n=r(k5()),i=r(kv()),a=Gv(),o=D5();function s(){var l;const c=(0,a.useRouterState)();return(0,n.default)(l=(0,i.default)(c.routes.pathRouteMap)).call(l,(d,h)=>(h.name&&(d[h.name]=h.path),d),{})}function u(l){const c=(0,o.useRouteName)(),f=s(),d=l||c;if(d)return f[d]}}(iE)),iE}var aE={},jj;function _ye(){return jj||(jj=1,function(e){var t=xe,r=Dn.default;t(e,"__esModule",{value:!0}),e.SkipNavLink=e.SkipNavContent=void 0;var n=r(I),i=P;const a="reach-skip-nav",o=e.SkipNavLink=n.forwardRef(function(l,c){let{as:f="a",children:d="Skip to content",contentId:h,...p}=l;const v=h||a;return(0,i.jsx)(f,{...p,ref:c,href:`#${v}`,"data-reach-skip-link":"","data-reach-skip-nav-link":"",children:d})});o.displayName="SkipNavLink";const s=e.SkipNavContent=n.forwardRef(function(l,c){let{as:f="div",id:d,...h}=l;const p=d||a;return(0,i.jsx)(f,{...h,ref:c,id:p,"data-reach-skip-nav-content":""})});s.displayName="SkipNavContent"}(aE)),aE}var oE={},qj;function yye(){return qj||(qj=1,function(e){var t=xe;t(e,"__esModule",{value:!0})}(oE)),oE}var Uj;function N5(){return Uj||(Uj=1,function(e){var t,r,n,i,a,o,s,u=xe,l=av,c=as,f=Dn.default;u(e,"__esModule",{value:!0});var d={navigate:!0,back:!0,Link:!0,NavLink:!0,Redirect:!0,useLocation:!0,LocationProvider:!0,usePageLoadingContext:!0,PageLoadingContextProvider:!0,useParams:!0,ParamsProvider:!0,ParamsContext:!0,Router:!0,Route:!0,routes:!0,RouteAnnouncement:!0,RouteFocus:!0,parseSearch:!0,getRouteRegexAndParams:!0,matchPath:!0,SkipNavLink:!0,SkipNavContent:!0};u(e,"Link",{enumerable:!0,get:function(){return p.Link}}),u(e,"LocationProvider",{enumerable:!0,get:function(){return v.LocationProvider}}),u(e,"NavLink",{enumerable:!0,get:function(){return p.NavLink}}),u(e,"PageLoadingContextProvider",{enumerable:!0,get:function(){return _.PageLoadingContextProvider}}),u(e,"ParamsContext",{enumerable:!0,get:function(){return m.ParamsContext}}),u(e,"ParamsProvider",{enumerable:!0,get:function(){return m.ParamsProvider}}),u(e,"Redirect",{enumerable:!0,get:function(){return p.Redirect}}),u(e,"Route",{enumerable:!0,get:function(){return g.Route}}),u(e,"RouteAnnouncement",{enumerable:!0,get:function(){return S.default}}),u(e,"RouteFocus",{enumerable:!0,get:function(){return b.default}}),u(e,"Router",{enumerable:!0,get:function(){return g.Router}}),u(e,"SkipNavContent",{enumerable:!0,get:function(){return k.SkipNavContent}}),u(e,"SkipNavLink",{enumerable:!0,get:function(){return k.SkipNavLink}}),u(e,"back",{enumerable:!0,get:function(){return h.back}}),u(e,"getRouteRegexAndParams",{enumerable:!0,get:function(){return O.getRouteRegexAndParams}}),u(e,"matchPath",{enumerable:!0,get:function(){return O.matchPath}}),u(e,"navigate",{enumerable:!0,get:function(){return h.navigate}}),u(e,"parseSearch",{enumerable:!0,get:function(){return O.parseSearch}}),u(e,"routes",{enumerable:!0,get:function(){return g.routes}}),u(e,"useLocation",{enumerable:!0,get:function(){return v.useLocation}}),u(e,"usePageLoadingContext",{enumerable:!0,get:function(){return _.usePageLoadingContext}}),u(e,"useParams",{enumerable:!0,get:function(){return m.useParams}});var h=e1(),p=i1(),v=n1(),_=t1(),m=I5(),g=r1(),y=C5();l(t=c(y)).call(t,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===y[T]||u(e,T,{enumerable:!0,get:function(){return y[T]}})});var S=f(vye());l(r=c(S)).call(r,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===S[T]||u(e,T,{enumerable:!0,get:function(){return S[T]}})});var b=f(mye());l(n=c(b)).call(n,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===b[T]||u(e,T,{enumerable:!0,get:function(){return b[T]}})});var E=D5();l(i=c(E)).call(i,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===E[T]||u(e,T,{enumerable:!0,get:function(){return E[T]}})});var w=gye();l(a=c(w)).call(a,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===w[T]||u(e,T,{enumerable:!0,get:function(){return w[T]}})});var R=$5();l(o=c(R)).call(o,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===R[T]||u(e,T,{enumerable:!0,get:function(){return R[T]}})});var O=co(),k=_ye(),C=yye();l(s=c(C)).call(s,function(T){T==="default"||T==="__esModule"||Object.prototype.hasOwnProperty.call(d,T)||T in e&&e[T]===C[T]||u(e,T,{enumerable:!0,get:function(){return C[T]}})})}(f0)),f0}var ne=N5(),Sye=Object.defineProperty,bye=(e,t,r)=>t in e?Sye(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,sE=(e,t,r)=>(bye(e,typeof t!="symbol"?t+"":t,r),r);let Eye=class{constructor(){sE(this,"current",this.detect()),sE(this,"handoffState","pending"),sE(this,"currentId",0)}set(t){this.current!==t&&(this.handoffState="pending",this.currentId=0,this.current=t)}reset(){this.set(this.detect())}nextId(){return++this.currentId}get isServer(){return this.current==="server"}get isClient(){return this.current==="client"}detect(){return typeof window>"u"||typeof document>"u"?"server":"client"}handoff(){this.handoffState==="pending"&&(this.handoffState="complete")}get isHandoffComplete(){return this.handoffState==="complete"}},Ya=new Eye,no=(e,t)=>{Ya.isServer?I.useEffect(e,t):I.useLayoutEffect(e,t)};function Kn(e){let t=I.useRef(e);return no(()=>{t.current=e},[e]),t}function wye(e){typeof queueMicrotask=="function"?queueMicrotask(e):Promise.resolve().then(e).catch(t=>setTimeout(()=>{throw t}))}function lf(){let e=[],t={addEventListener(r,n,i,a){return r.addEventListener(n,i,a),t.add(()=>r.removeEventListener(n,i,a))},requestAnimationFrame(...r){let n=requestAnimationFrame(...r);return t.add(()=>cancelAnimationFrame(n))},nextFrame(...r){return t.requestAnimationFrame(()=>t.requestAnimationFrame(...r))},setTimeout(...r){let n=setTimeout(...r);return t.add(()=>clearTimeout(n))},microTask(...r){let n={current:!0};return wye(()=>{n.current&&r[0]()}),t.add(()=>{n.current=!1})},style(r,n,i){let a=r.style.getPropertyValue(n);return Object.assign(r.style,{[n]:i}),this.add(()=>{Object.assign(r.style,{[n]:a})})},group(r){let n=lf();return r(n),this.add(()=>n.dispose())},add(r){return e.push(r),()=>{let n=e.indexOf(r);if(n>=0)for(let i of e.splice(n,1))i()}},dispose(){for(let r of e.splice(0))r()}};return t}function A5(){let[e]=I.useState(lf);return I.useEffect(()=>()=>e.dispose(),[e]),e}let Pt=function(e){let t=Kn(e);return qe.useCallback((...r)=>t.current(...r),[t])};function a1(){let[e,t]=I.useState(Ya.isHandoffComplete);return e&&Ya.isHandoffComplete===!1&&t(!1),I.useEffect(()=>{e!==!0&&t(!0)},[e]),I.useEffect(()=>Ya.handoff(),[]),e}var Bj;let au=(Bj=qe.useId)!=null?Bj:function(){let e=a1(),[t,r]=qe.useState(e?()=>Ya.nextId():null);return no(()=>{t===null&&r(Ya.nextId())},[t]),t!=null?""+t:void 0};function ir(e,t,...r){if(e in t){let i=t[e];return typeof i=="function"?i(...r):i}let n=new Error(`Tried to handle "${e}" but there is no handler defined. Only defined handlers are: ${Object.keys(t).map(i=>`"${i}"`).join(", ")}.`);throw Error.captureStackTrace&&Error.captureStackTrace(n,ir),n}function o1(e){return Ya.isServer?null:e instanceof Node?e.ownerDocument:e!=null&&e.hasOwnProperty("current")&&e.current instanceof Node?e.current.ownerDocument:document}let VR=["[contentEditable=true]","[tabindex]","a[href]","area[href]","button:not([disabled])","iframe","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].map(e=>`${e}:not([tabindex='-1'])`).join(",");var Ai=(e=>(e[e.First=1]="First",e[e.Previous=2]="Previous",e[e.Next=4]="Next",e[e.Last=8]="Last",e[e.WrapAround=16]="WrapAround",e[e.NoScroll=32]="NoScroll",e))(Ai||{}),up=(e=>(e[e.Error=0]="Error",e[e.Overflow=1]="Overflow",e[e.Success=2]="Success",e[e.Underflow=3]="Underflow",e))(up||{}),Rye=(e=>(e[e.Previous=-1]="Previous",e[e.Next=1]="Next",e))(Rye||{});function Vv(e=document.body){return e==null?[]:Array.from(e.querySelectorAll(VR)).sort((t,r)=>Math.sign((t.tabIndex||Number.MAX_SAFE_INTEGER)-(r.tabIndex||Number.MAX_SAFE_INTEGER)))}var s1=(e=>(e[e.Strict=0]="Strict",e[e.Loose=1]="Loose",e))(s1||{});function L5(e,t=0){var r;return e===((r=o1(e))==null?void 0:r.body)?!1:ir(t,{0(){return e.matches(VR)},1(){let n=e;for(;n!==null;){if(n.matches(VR))return!0;n=n.parentElement}return!1}})}function tbe(e){e==null||e.focus({preventScroll:!0})}let Tye=["textarea","input"].join(",");function kye(e){var t,r;return(r=(t=e==null?void 0:e.matches)==null?void 0:t.call(e,Tye))!=null?r:!1}function Oye(e,t=r=>r){return e.slice().sort((r,n)=>{let i=t(r),a=t(n);if(i===null||a===null)return 0;let o=i.compareDocumentPosition(a);return o&Node.DOCUMENT_POSITION_FOLLOWING?-1:o&Node.DOCUMENT_POSITION_PRECEDING?1:0})}function Ao(e,t,{sorted:r=!0,relativeTo:n=null,skipElements:i=[]}={}){let a=Array.isArray(e)?e.length>0?e[0].ownerDocument:document:e.ownerDocument,o=Array.isArray(e)?r?Oye(e):e:Vv(e);i.length>0&&o.length>1&&(o=o.filter(h=>!i.includes(h))),n=n??a.activeElement;let s=(()=>{if(t&5)return 1;if(t&10)return-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),u=(()=>{if(t&1)return 0;if(t&2)return Math.max(0,o.indexOf(n))-1;if(t&4)return Math.max(0,o.indexOf(n))+1;if(t&8)return o.length-1;throw new Error("Missing Focus.First, Focus.Previous, Focus.Next or Focus.Last")})(),l=t&32?{preventScroll:!0}:{},c=0,f=o.length,d;do{if(c>=f||c+f<=0)return 0;let h=u+c;if(t&16)h=(h+f)%f;else{if(h<0)return 3;if(h>=f)return 1}d=o[h],d==null||d.focus(l),c+=s}while(d!==a.activeElement);return t&6&&kye(d)&&d.select(),d.hasAttribute("tabindex")||d.setAttribute("tabindex","0"),2}function uE(e,t,r){let n=Kn(t);I.useEffect(()=>{function i(a){n.current(a)}return document.addEventListener(e,i,r),()=>document.removeEventListener(e,i,r)},[e,r])}function Pye(e,t,r=!0){let n=I.useRef(!1);I.useEffect(()=>{requestAnimationFrame(()=>{n.current=r})},[r]);function i(o,s){if(!n.current||o.defaultPrevented)return;let u=function c(f){return typeof f=="function"?c(f()):Array.isArray(f)||f instanceof Set?f:[f]}(e),l=s(o);if(l!==null&&l.getRootNode().contains(l)){for(let c of u){if(c===null)continue;let f=c instanceof HTMLElement?c:c.current;if(f!=null&&f.contains(l)||o.composed&&o.composedPath().includes(f))return}return!L5(l,s1.Loose)&&l.tabIndex!==-1&&o.preventDefault(),t(o,l)}}let a=I.useRef(null);uE("mousedown",o=>{var s,u;n.current&&(a.current=((u=(s=o.composedPath)==null?void 0:s.call(o))==null?void 0:u[0])||o.target)},!0),uE("click",o=>{a.current&&(i(o,()=>a.current),a.current=null)},!0),uE("blur",o=>i(o,()=>window.document.activeElement instanceof HTMLIFrameElement?window.document.activeElement:null),!0)}function zj(e){var t;if(e.type)return e.type;let r=(t=e.as)!=null?t:"button";if(typeof r=="string"&&r.toLowerCase()==="button")return"button"}function Iye(e,t){let[r,n]=I.useState(()=>zj(e));return no(()=>{n(zj(e))},[e.type,e.as]),no(()=>{r||t.current&&t.current instanceof HTMLButtonElement&&!t.current.hasAttribute("type")&&n("button")},[r,t]),r}let M5=Symbol();function xye(e,t=!0){return Object.assign(e,{[M5]:t})}function io(...e){let t=I.useRef(e);I.useEffect(()=>{t.current=e},[e]);let r=Pt(n=>{for(let i of t.current)i!=null&&(typeof i=="function"?i(n):i.current=n)});return e.every(n=>n==null||(n==null?void 0:n[M5]))?void 0:r}function F5(...e){return e.filter(Boolean).join(" ")}var Cu=(e=>(e[e.None=0]="None",e[e.RenderStrategy=1]="RenderStrategy",e[e.Static=2]="Static",e))(Cu||{}),Li=(e=>(e[e.Unmount=0]="Unmount",e[e.Hidden=1]="Hidden",e))(Li||{});function fo({ourProps:e,theirProps:t,slot:r,defaultTag:n,features:i,visible:a=!0,name:o}){let s=j5(t,e);if(a)return ud(s,r,n,o);let u=i??0;if(u&2){let{static:l=!1,...c}=s;if(l)return ud(c,r,n,o)}if(u&1){let{unmount:l=!0,...c}=s;return ir(l?0:1,{0(){return null},1(){return ud({...c,hidden:!0,style:{display:"none"}},r,n,o)}})}return ud(s,r,n,o)}function ud(e,t={},r,n){var i;let{as:a=r,children:o,refName:s="ref",...u}=lE(e,["unmount","static"]),l=e.ref!==void 0?{[s]:e.ref}:{},c=typeof o=="function"?o(t):o;"className"in u&&u.className&&typeof u.className=="function"&&(u.className=u.className(t));let f={};if(t){let d=!1,h=[];for(let[p,v]of Object.entries(t))typeof v=="boolean"&&(d=!0),v===!0&&h.push(p);d&&(f["data-headlessui-state"]=h.join(" "))}if(a===I.Fragment&&Object.keys(Hj(u)).length>0){if(!I.isValidElement(c)||Array.isArray(c)&&c.length>1)throw new Error(['Passing props on "Fragment"!',"",`The current component <${n} /> is rendering a "Fragment".`,"However we need to passthrough the following props:",Object.keys(u).map(p=>` - ${p}`).join(` `),"","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(p=>` - ${p}`).join(` `)].join(` `));let d=F5((i=c.props)==null?void 0:i.className,u.className),h=d?{className:d}:{};return I.cloneElement(c,Object.assign({},j5(c.props,Hj(lE(u,["ref"]))),f,l,Cye(c.ref,l.ref),h))}return I.createElement(a,Object.assign({},lE(u,["ref"]),a!==I.Fragment&&l,a!==I.Fragment&&f),c)}function Cye(...e){return{ref:e.every(t=>t==null)?void 0:t=>{for(let r of e)r!=null&&(typeof r=="function"?r(t):r.current=t)}}}function j5(...e){if(e.length===0)return{};if(e.length===1)return e[0];let t={},r={};for(let n of e)for(let i in n)i.startsWith("on")&&typeof n[i]=="function"?(r[i]!=null||(r[i]=[]),r[i].push(n[i])):t[i]=n[i];if(t.disabled||t["aria-disabled"])return Object.assign(t,Object.fromEntries(Object.keys(r).map(n=>[n,void 0])));for(let n in r)Object.assign(t,{[n](i,...a){let o=r[n];for(let s of o){if((i instanceof Event||(i==null?void 0:i.nativeEvent)instanceof Event)&&i.defaultPrevented)return;s(i,...a)}}});return t}function da(e){var t;return Object.assign(I.forwardRef(e),{displayName:(t=e.displayName)!=null?t:e.name})}function Hj(e){let t=Object.assign({},e);for(let r in t)t[r]===void 0&&delete t[r];return t}function lE(e,t=[]){let r=Object.assign({},e);for(let n of t)n in r&&delete r[n];return r}function q5(e){let t=e.parentElement,r=null;for(;t&&!(t instanceof HTMLFieldSetElement);)t instanceof HTMLLegendElement&&(r=t),t=t.parentElement;let n=(t==null?void 0:t.getAttribute("disabled"))==="";return n&&$ye(r)?!1:n}function $ye(e){if(!e)return!1;let t=e.previousElementSibling;for(;t!==null;){if(t instanceof HTMLLegendElement)return!1;t=t.previousElementSibling}return!0}let Dye="div";var lp=(e=>(e[e.None=1]="None",e[e.Focusable=2]="Focusable",e[e.Hidden=4]="Hidden",e))(lp||{});function Nye(e,t){let{features:r=1,...n}=e,i={ref:t,"aria-hidden":(r&2)===2?!0:void 0,style:{position:"fixed",top:1,left:1,width:1,height:0,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",...(r&4)===4&&(r&2)!==2&&{display:"none"}}};return fo({ourProps:i,theirProps:n,slot:{},defaultTag:Dye,name:"Hidden"})}let YR=da(Nye),u1=I.createContext(null);u1.displayName="OpenClosedContext";var Lr=(e=>(e[e.Open=1]="Open",e[e.Closed=2]="Closed",e[e.Closing=4]="Closing",e[e.Opening=8]="Opening",e))(Lr||{});function Yv(){return I.useContext(u1)}function U5({value:e,children:t}){return qe.createElement(u1.Provider,{value:e},t)}var Pa=(e=>(e.Space=" ",e.Enter="Enter",e.Escape="Escape",e.Backspace="Backspace",e.Delete="Delete",e.ArrowLeft="ArrowLeft",e.ArrowUp="ArrowUp",e.ArrowRight="ArrowRight",e.ArrowDown="ArrowDown",e.Home="Home",e.End="End",e.PageUp="PageUp",e.PageDown="PageDown",e.Tab="Tab",e))(Pa||{});function Aye(e,t,r){let n=Kn(t);I.useEffect(()=>{function i(a){n.current(a)}return window.addEventListener(e,i,r),()=>window.removeEventListener(e,i,r)},[e,r])}var Mi=(e=>(e[e.Forwards=0]="Forwards",e[e.Backwards=1]="Backwards",e))(Mi||{});function B5(){let e=I.useRef(0);return Aye("keydown",t=>{t.key==="Tab"&&(e.current=t.shiftKey?1:0)},!0),e}function z5(){let e=I.useRef(!1);return no(()=>(e.current=!0,()=>{e.current=!1}),[]),e}function l1(...e){return I.useMemo(()=>o1(...e),[...e])}function Lye(e,t,r,n){let i=Kn(r);I.useEffect(()=>{e=e??window;function a(o){i.current(o)}return e.addEventListener(t,a,n),()=>e.removeEventListener(t,a,n)},[e,t,n])}var Mye=(e=>(e[e.Open=0]="Open",e[e.Closed=1]="Closed",e))(Mye||{}),Fye=(e=>(e[e.TogglePopover=0]="TogglePopover",e[e.ClosePopover=1]="ClosePopover",e[e.SetButton=2]="SetButton",e[e.SetButtonId=3]="SetButtonId",e[e.SetPanel=4]="SetPanel",e[e.SetPanelId=5]="SetPanelId",e))(Fye||{});let jye={0:e=>({...e,popoverState:ir(e.popoverState,{0:1,1:0})}),1(e){return e.popoverState===1?e:{...e,popoverState:1}},2(e,t){return e.button===t.button?e:{...e,button:t.button}},3(e,t){return e.buttonId===t.buttonId?e:{...e,buttonId:t.buttonId}},4(e,t){return e.panel===t.panel?e:{...e,panel:t.panel}},5(e,t){return e.panelId===t.panelId?e:{...e,panelId:t.panelId}}},c1=I.createContext(null);c1.displayName="PopoverContext";function Qv(e){let t=I.useContext(c1);if(t===null){let r=new Error(`<${e} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,Qv),r}return t}let f1=I.createContext(null);f1.displayName="PopoverAPIContext";function d1(e){let t=I.useContext(f1);if(t===null){let r=new Error(`<${e} /> is missing a parent component.`);throw Error.captureStackTrace&&Error.captureStackTrace(r,d1),r}return t}let h1=I.createContext(null);h1.displayName="PopoverGroupContext";function H5(){return I.useContext(h1)}let Kv=I.createContext(null);Kv.displayName="PopoverPanelContext";function qye(){return I.useContext(Kv)}function Uye(e,t){return ir(t.type,jye,e,t)}let Bye="div";function zye(e,t){var r;let n=I.useRef(null),i=io(t,xye(T=>{n.current=T})),a=I.useRef([]),o=I.useReducer(Uye,{popoverState:1,buttons:a,button:null,buttonId:null,panel:null,panelId:null,beforePanelSentinel:I.createRef(),afterPanelSentinel:I.createRef()}),[{popoverState:s,button:u,buttonId:l,panel:c,panelId:f,beforePanelSentinel:d,afterPanelSentinel:h},p]=o,v=l1((r=n.current)!=null?r:u),_=I.useMemo(()=>{if(!u||!c)return!1;for(let D of document.querySelectorAll("body > *"))if(Number(D==null?void 0:D.contains(u))^Number(D==null?void 0:D.contains(c)))return!0;let T=Vv(),$=T.indexOf(u),L=($+T.length-1)%T.length,G=($+1)%T.length,Y=T[L],B=T[G];return!c.contains(Y)&&!c.contains(B)},[u,c]),m=Kn(l),g=Kn(f),y=I.useMemo(()=>({buttonId:m,panelId:g,close:()=>p({type:1})}),[m,g,p]),S=H5(),b=S==null?void 0:S.registerPopover,E=Pt(()=>{var T;return(T=S==null?void 0:S.isFocusWithinPopoverGroup())!=null?T:(v==null?void 0:v.activeElement)&&((u==null?void 0:u.contains(v.activeElement))||(c==null?void 0:c.contains(v.activeElement)))});I.useEffect(()=>b==null?void 0:b(y),[b,y]),Lye(v==null?void 0:v.defaultView,"focus",T=>{var $,L,G,Y;s===0&&(E()||u&&c&&T.target!==window&&((L=($=d.current)==null?void 0:$.contains)!=null&&L.call($,T.target)||(Y=(G=h.current)==null?void 0:G.contains)!=null&&Y.call(G,T.target)||p({type:1})))},!0),Pye([u,c],(T,$)=>{p({type:1}),L5($,s1.Loose)||(T.preventDefault(),u==null||u.focus())},s===0);let w=Pt(T=>{p({type:1});let $=(()=>T?T instanceof HTMLElement?T:"current"in T&&T.current instanceof HTMLElement?T.current:u:u)();$==null||$.focus()}),R=I.useMemo(()=>({close:w,isPortalled:_}),[w,_]),O=I.useMemo(()=>({open:s===0,close:w}),[s,w]),k=e,C={ref:i};return qe.createElement(Kv.Provider,{value:null},qe.createElement(c1.Provider,{value:o},qe.createElement(f1.Provider,{value:R},qe.createElement(U5,{value:ir(s,{0:Lr.Open,1:Lr.Closed})},fo({ourProps:C,theirProps:k,slot:O,defaultTag:Bye,name:"Popover"})))))}let Hye="button";function Wye(e,t){let r=au(),{id:n=`headlessui-popover-button-${r}`,...i}=e,[a,o]=Qv("Popover.Button"),{isPortalled:s}=d1("Popover.Button"),u=I.useRef(null),l=`headlessui-focus-sentinel-${au()}`,c=H5(),f=c==null?void 0:c.closeOthers,d=qye()!==null;I.useEffect(()=>{if(!d)return o({type:3,buttonId:n}),()=>{o({type:3,buttonId:null})}},[d,n,o]);let[h]=I.useState(()=>Symbol()),p=io(u,t,d?null:C=>{if(C)a.buttons.current.push(h);else{let T=a.buttons.current.indexOf(h);T!==-1&&a.buttons.current.splice(T,1)}a.buttons.current.length>1&&console.warn("You are already using a but only 1 is supported."),C&&o({type:2,button:C})}),v=io(u,t),_=l1(u),m=Pt(C=>{var T,$,L;if(d){if(a.popoverState===1)return;switch(C.key){case Pa.Space:case Pa.Enter:C.preventDefault(),($=(T=C.target).click)==null||$.call(T),o({type:1}),(L=a.button)==null||L.focus();break}}else switch(C.key){case Pa.Space:case Pa.Enter:C.preventDefault(),C.stopPropagation(),a.popoverState===1&&(f==null||f(a.buttonId)),o({type:0});break;case Pa.Escape:if(a.popoverState!==0)return f==null?void 0:f(a.buttonId);if(!u.current||_!=null&&_.activeElement&&!u.current.contains(_.activeElement))return;C.preventDefault(),C.stopPropagation(),o({type:1});break}}),g=Pt(C=>{d||C.key===Pa.Space&&C.preventDefault()}),y=Pt(C=>{var T,$;q5(C.currentTarget)||e.disabled||(d?(o({type:1}),(T=a.button)==null||T.focus()):(C.preventDefault(),C.stopPropagation(),a.popoverState===1&&(f==null||f(a.buttonId)),o({type:0}),($=a.button)==null||$.focus()))}),S=Pt(C=>{C.preventDefault(),C.stopPropagation()}),b=a.popoverState===0,E=I.useMemo(()=>({open:b}),[b]),w=Iye(e,u),R=d?{ref:v,type:w,onKeyDown:m,onClick:y}:{ref:p,id:a.buttonId,type:w,"aria-expanded":e.disabled?void 0:a.popoverState===0,"aria-controls":a.panel?a.panelId:void 0,onKeyDown:m,onKeyUp:g,onClick:y,onMouseDown:S},O=B5(),k=Pt(()=>{let C=a.panel;if(!C)return;function T(){ir(O.current,{[Mi.Forwards]:()=>Ao(C,Ai.First),[Mi.Backwards]:()=>Ao(C,Ai.Last)})===up.Error&&Ao(Vv().filter($=>$.dataset.headlessuiFocusGuard!=="true"),ir(O.current,{[Mi.Forwards]:Ai.Next,[Mi.Backwards]:Ai.Previous}),{relativeTo:a.button})}T()});return qe.createElement(qe.Fragment,null,fo({ourProps:R,theirProps:i,slot:E,defaultTag:Hye,name:"Popover.Button"}),b&&!d&&s&&qe.createElement(YR,{id:l,features:lp.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:k}))}let Gye="div",Vye=Cu.RenderStrategy|Cu.Static;function Yye(e,t){let r=au(),{id:n=`headlessui-popover-overlay-${r}`,...i}=e,[{popoverState:a},o]=Qv("Popover.Overlay"),s=io(t),u=Yv(),l=(()=>u!==null?(u&Lr.Open)===Lr.Open:a===0)(),c=Pt(d=>{if(q5(d.currentTarget))return d.preventDefault();o({type:1})}),f=I.useMemo(()=>({open:a===0}),[a]);return fo({ourProps:{ref:s,id:n,"aria-hidden":!0,onClick:c},theirProps:i,slot:f,defaultTag:Gye,features:Vye,visible:l,name:"Popover.Overlay"})}let Qye="div",Kye=Cu.RenderStrategy|Cu.Static;function Jye(e,t){let r=au(),{id:n=`headlessui-popover-panel-${r}`,focus:i=!1,...a}=e,[o,s]=Qv("Popover.Panel"),{close:u,isPortalled:l}=d1("Popover.Panel"),c=`headlessui-focus-sentinel-before-${au()}`,f=`headlessui-focus-sentinel-after-${au()}`,d=I.useRef(null),h=io(d,t,w=>{s({type:4,panel:w})}),p=l1(d);no(()=>(s({type:5,panelId:n}),()=>{s({type:5,panelId:null})}),[n,s]);let v=Yv(),_=(()=>v!==null?(v&Lr.Open)===Lr.Open:o.popoverState===0)(),m=Pt(w=>{var R;switch(w.key){case Pa.Escape:if(o.popoverState!==0||!d.current||p!=null&&p.activeElement&&!d.current.contains(p.activeElement))return;w.preventDefault(),w.stopPropagation(),s({type:1}),(R=o.button)==null||R.focus();break}});I.useEffect(()=>{var w;e.static||o.popoverState===1&&((w=e.unmount)==null||w)&&s({type:4,panel:null})},[o.popoverState,e.unmount,e.static,s]),I.useEffect(()=>{if(!i||o.popoverState!==0||!d.current)return;let w=p==null?void 0:p.activeElement;d.current.contains(w)||Ao(d.current,Ai.First)},[i,d,o.popoverState]);let g=I.useMemo(()=>({open:o.popoverState===0,close:u}),[o,u]),y={ref:h,id:n,onKeyDown:m,onBlur:i&&o.popoverState===0?w=>{var R,O,k,C,T;let $=w.relatedTarget;$&&d.current&&((R=d.current)!=null&&R.contains($)||(s({type:1}),((k=(O=o.beforePanelSentinel.current)==null?void 0:O.contains)!=null&&k.call(O,$)||(T=(C=o.afterPanelSentinel.current)==null?void 0:C.contains)!=null&&T.call(C,$))&&$.focus({preventScroll:!0})))}:void 0,tabIndex:-1},S=B5(),b=Pt(()=>{let w=d.current;if(!w)return;function R(){ir(S.current,{[Mi.Forwards]:()=>{var O;Ao(w,Ai.First)===up.Error&&((O=o.afterPanelSentinel.current)==null||O.focus())},[Mi.Backwards]:()=>{var O;(O=o.button)==null||O.focus({preventScroll:!0})}})}R()}),E=Pt(()=>{let w=d.current;if(!w)return;function R(){ir(S.current,{[Mi.Forwards]:()=>{var O;if(!o.button)return;let k=Vv(),C=k.indexOf(o.button),T=k.slice(0,C+1),$=[...k.slice(C+1),...T];for(let L of $.slice())if(L.dataset.headlessuiFocusGuard==="true"||(O=o.panel)!=null&&O.contains(L)){let G=$.indexOf(L);G!==-1&&$.splice(G,1)}Ao($,Ai.First,{sorted:!1})},[Mi.Backwards]:()=>{var O;Ao(w,Ai.Previous)===up.Error&&((O=o.button)==null||O.focus())}})}R()});return qe.createElement(Kv.Provider,{value:n},_&&l&&qe.createElement(YR,{id:c,ref:o.beforePanelSentinel,features:lp.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:b}),fo({ourProps:y,theirProps:a,slot:g,defaultTag:Qye,features:Kye,visible:_,name:"Popover.Panel"}),_&&l&&qe.createElement(YR,{id:f,ref:o.afterPanelSentinel,features:lp.Focusable,"data-headlessui-focus-guard":!0,as:"button",type:"button",onFocus:E}))}let Xye="div";function Zye(e,t){let r=I.useRef(null),n=io(r,t),[i,a]=I.useState([]),o=Pt(p=>{a(v=>{let _=v.indexOf(p);if(_!==-1){let m=v.slice();return m.splice(_,1),m}return v})}),s=Pt(p=>(a(v=>[...v,p]),()=>o(p))),u=Pt(()=>{var p;let v=o1(r);if(!v)return!1;let _=v.activeElement;return(p=r.current)!=null&&p.contains(_)?!0:i.some(m=>{var g,y;return((g=v.getElementById(m.buttonId.current))==null?void 0:g.contains(_))||((y=v.getElementById(m.panelId.current))==null?void 0:y.contains(_))})}),l=Pt(p=>{for(let v of i)v.buttonId.current!==p&&v.close()}),c=I.useMemo(()=>({registerPopover:s,unregisterPopover:o,isFocusWithinPopoverGroup:u,closeOthers:l}),[s,o,u,l]),f=I.useMemo(()=>({}),[]),d=e,h={ref:n};return qe.createElement(h1.Provider,{value:c},fo({ourProps:h,theirProps:d,slot:f,defaultTag:Xye,name:"Popover.Group"}))}let e0e=da(zye),t0e=da(Wye),r0e=da(Yye),n0e=da(Jye),i0e=da(Zye),ou=Object.assign(e0e,{Button:t0e,Overlay:r0e,Panel:n0e,Group:i0e});function a0e(e=0){let[t,r]=I.useState(e),n=I.useCallback(s=>r(u=>u|s),[t]),i=I.useCallback(s=>!!(t&s),[t]),a=I.useCallback(s=>r(u=>u&~s),[r]),o=I.useCallback(s=>r(u=>u^s),[r]);return{flags:t,addFlag:n,hasFlag:i,removeFlag:a,toggleFlag:o}}function o0e(e){let t={called:!1};return(...r)=>{if(!t.called)return t.called=!0,e(...r)}}function cE(e,...t){e&&t.length>0&&e.classList.add(...t)}function fE(e,...t){e&&t.length>0&&e.classList.remove(...t)}function s0e(e,t){let r=lf();if(!e)return r.dispose;let{transitionDuration:n,transitionDelay:i}=getComputedStyle(e),[a,o]=[n,i].map(u=>{let[l=0]=u.split(",").filter(Boolean).map(c=>c.includes("ms")?parseFloat(c):parseFloat(c)*1e3).sort((c,f)=>f-c);return l}),s=a+o;if(s!==0){r.group(l=>{l.setTimeout(()=>{t(),l.dispose()},s),l.addEventListener(e,"transitionrun",c=>{c.target===c.currentTarget&&l.dispose()})});let u=r.addEventListener(e,"transitionend",l=>{l.target===l.currentTarget&&(t(),u())})}else t();return r.add(()=>t()),r.dispose}function u0e(e,t,r,n){let i=r?"enter":"leave",a=lf(),o=n!==void 0?o0e(n):()=>{};i==="enter"&&(e.removeAttribute("hidden"),e.style.display="");let s=ir(i,{enter:()=>t.enter,leave:()=>t.leave}),u=ir(i,{enter:()=>t.enterTo,leave:()=>t.leaveTo}),l=ir(i,{enter:()=>t.enterFrom,leave:()=>t.leaveFrom});return fE(e,...t.enter,...t.enterTo,...t.enterFrom,...t.leave,...t.leaveFrom,...t.leaveTo,...t.entered),cE(e,...s,...l),a.nextFrame(()=>{fE(e,...l),cE(e,...u),s0e(e,()=>(fE(e,...s),cE(e,...t.entered),o()))}),a.dispose}function l0e({container:e,direction:t,classes:r,onStart:n,onStop:i}){let a=z5(),o=A5(),s=Kn(t);no(()=>{let u=lf();o.add(u.dispose);let l=e.current;if(l&&s.current!=="idle"&&a.current)return u.dispose(),n.current(s.current),u.add(u0e(l,r.current,s.current==="enter",()=>{u.dispose(),i.current(s.current)})),u.dispose},[t])}function yo(e=""){return e.split(" ").filter(t=>t.trim().length>1)}let Jv=I.createContext(null);Jv.displayName="TransitionContext";var c0e=(e=>(e.Visible="visible",e.Hidden="hidden",e))(c0e||{});function f0e(){let e=I.useContext(Jv);if(e===null)throw new Error("A is used but it is missing a parent or .");return e}function d0e(){let e=I.useContext(Xv);if(e===null)throw new Error("A is used but it is missing a parent or .");return e}let Xv=I.createContext(null);Xv.displayName="NestingContext";function Zv(e){return"children"in e?Zv(e.children):e.current.filter(({el:t})=>t.current!==null).filter(({state:t})=>t==="visible").length>0}function W5(e,t){let r=Kn(e),n=I.useRef([]),i=z5(),a=A5(),o=Pt((h,p=Li.Hidden)=>{let v=n.current.findIndex(({el:_})=>_===h);v!==-1&&(ir(p,{[Li.Unmount](){n.current.splice(v,1)},[Li.Hidden](){n.current[v].state="hidden"}}),a.microTask(()=>{var _;!Zv(n)&&i.current&&((_=r.current)==null||_.call(r))}))}),s=Pt(h=>{let p=n.current.find(({el:v})=>v===h);return p?p.state!=="visible"&&(p.state="visible"):n.current.push({el:h,state:"visible"}),()=>o(h,Li.Unmount)}),u=I.useRef([]),l=I.useRef(Promise.resolve()),c=I.useRef({enter:[],leave:[],idle:[]}),f=Pt((h,p,v)=>{u.current.splice(0),t&&(t.chains.current[p]=t.chains.current[p].filter(([_])=>_!==h)),t==null||t.chains.current[p].push([h,new Promise(_=>{u.current.push(_)})]),t==null||t.chains.current[p].push([h,new Promise(_=>{Promise.all(c.current[p].map(([m,g])=>g)).then(()=>_())})]),p==="enter"?l.current=l.current.then(()=>t==null?void 0:t.wait.current).then(()=>v(p)):v(p)}),d=Pt((h,p,v)=>{Promise.all(c.current[p].splice(0).map(([_,m])=>m)).then(()=>{var _;(_=u.current.shift())==null||_()}).then(()=>v(p))});return I.useMemo(()=>({children:n,register:s,unregister:o,onStart:f,onStop:d,wait:l,chains:c}),[s,o,n,f,d,c,l])}function h0e(){}let p0e=["beforeEnter","afterEnter","beforeLeave","afterLeave"];function Wj(e){var t;let r={};for(let n of p0e)r[n]=(t=e[n])!=null?t:h0e;return r}function v0e(e){let t=I.useRef(Wj(e));return I.useEffect(()=>{t.current=Wj(e)},[e]),t}let m0e="div",G5=Cu.RenderStrategy;function g0e(e,t){let{beforeEnter:r,afterEnter:n,beforeLeave:i,afterLeave:a,enter:o,enterFrom:s,enterTo:u,entered:l,leave:c,leaveFrom:f,leaveTo:d,...h}=e,p=I.useRef(null),v=io(p,t),_=h.unmount?Li.Unmount:Li.Hidden,{show:m,appear:g,initial:y}=f0e(),[S,b]=I.useState(m?"visible":"hidden"),E=d0e(),{register:w,unregister:R}=E,O=I.useRef(null);I.useEffect(()=>w(p),[w,p]),I.useEffect(()=>{if(_===Li.Hidden&&p.current){if(m&&S!=="visible"){b("visible");return}return ir(S,{hidden:()=>R(p),visible:()=>w(p)})}},[S,p,w,R,m,_]);let k=Kn({enter:yo(o),enterFrom:yo(s),enterTo:yo(u),entered:yo(l),leave:yo(c),leaveFrom:yo(f),leaveTo:yo(d)}),C=v0e({beforeEnter:r,afterEnter:n,beforeLeave:i,afterLeave:a}),T=a1();I.useEffect(()=>{if(T&&S==="visible"&&p.current===null)throw new Error("Did you forget to passthrough the `ref` to the actual DOM node?")},[p,S,T]);let $=y&&!g,L=(()=>!T||$||O.current===m?"idle":m?"enter":"leave")(),G=a0e(0),Y=Pt(ee=>ir(ee,{enter:()=>{G.addFlag(Lr.Opening),C.current.beforeEnter()},leave:()=>{G.addFlag(Lr.Closing),C.current.beforeLeave()},idle:()=>{}})),B=Pt(ee=>ir(ee,{enter:()=>{G.removeFlag(Lr.Opening),C.current.afterEnter()},leave:()=>{G.removeFlag(Lr.Closing),C.current.afterLeave()},idle:()=>{}})),D=W5(()=>{b("hidden"),R(p)},E);l0e({container:p,classes:k,direction:L,onStart:Kn(ee=>{D.onStart(p,ee,Y)}),onStop:Kn(ee=>{D.onStop(p,ee,B),ee==="leave"&&!Zv(D)&&(b("hidden"),R(p))})}),I.useEffect(()=>{$&&(_===Li.Hidden?O.current=null:O.current=m)},[m,$,S]);let F=h,z={ref:v};return g&&m&&Ya.isServer&&(F={...F,className:F5(h.className,...k.current.enter,...k.current.enterFrom)}),qe.createElement(Xv.Provider,{value:D},qe.createElement(U5,{value:ir(S,{visible:Lr.Open,hidden:Lr.Closed})|G.flags},fo({ourProps:z,theirProps:F,defaultTag:m0e,features:G5,visible:S==="visible",name:"Transition.Child"})))}function _0e(e,t){let{show:r,appear:n=!1,unmount:i,...a}=e,o=I.useRef(null),s=io(o,t);a1();let u=Yv();if(r===void 0&&u!==null&&(r=(u&Lr.Open)===Lr.Open),![!0,!1].includes(r))throw new Error("A is used but it is missing a `show={true | false}` prop.");let[l,c]=I.useState(r?"visible":"hidden"),f=W5(()=>{c("hidden")}),[d,h]=I.useState(!0),p=I.useRef([r]);no(()=>{d!==!1&&p.current[p.current.length-1]!==r&&(p.current.push(r),h(!1))},[p,r]);let v=I.useMemo(()=>({show:r,appear:n,initial:d}),[r,n,d]);I.useEffect(()=>{if(r)c("visible");else if(!Zv(f))c("hidden");else{let m=o.current;if(!m)return;let g=m.getBoundingClientRect();g.x===0&&g.y===0&&g.width===0&&g.height===0&&c("hidden")}},[r,f]);let _={unmount:i};return qe.createElement(Xv.Provider,{value:f},qe.createElement(Jv.Provider,{value:v},fo({ourProps:{..._,as:I.Fragment,children:qe.createElement(V5,{ref:s,..._,...a})},theirProps:{},defaultTag:I.Fragment,features:G5,visible:l==="visible",name:"Transition"})))}function y0e(e,t){let r=I.useContext(Jv)!==null,n=Yv()!==null;return qe.createElement(qe.Fragment,null,!r&&n?qe.createElement(QR,{ref:t,...e}):qe.createElement(V5,{ref:t,...e}))}let QR=da(_0e),V5=da(g0e),S0e=da(y0e),Y5=Object.assign(QR,{Child:S0e,Root:QR});function fi(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function"){var i=0;for(n=Object.getOwnPropertySymbols(e);i0&&p[p.length-1])||S[0]!==6&&S[0]!==2)){_=0;continue}if(S[0]===3&&(!p||S[1]>p[0]&&S[1]0?setTimeout(h,y):h(null)}}window.addEventListener("storage",m),c.addToWaiting(m);var g=setTimeout(m,Math.max(0,f-Date.now()))})];case 1:return d.sent(),[2]}})})},c.addToWaiting=function(f){this.removeFromWaiting(f),c.waiters!==void 0&&c.waiters.push(f)},c.removeFromWaiting=function(f){c.waiters!==void 0&&(c.waiters=c.waiters.filter(function(d){return d!==f}))},c.notifyWaiters=function(){c.waiters!==void 0&&c.waiters.slice().forEach(function(f){return f()})},c.prototype.releaseLock=function(f){return r(this,void 0,void 0,function(){return n(this,function(d){switch(d.label){case 0:return[4,this.releaseLock__private__(f)];case 1:return[2,d.sent()]}})})},c.prototype.releaseLock__private__=function(f){return r(this,void 0,void 0,function(){var d,h,p,v;return n(this,function(_){switch(_.label){case 0:return d=this.storageHandler===void 0?o:this.storageHandler,h=a+"-"+f,(p=d.getItemSync(h))===null?[2]:(v=JSON.parse(p)).id!==this.id?[3,2]:[4,Ro.default().lock(v.iat)];case 1:_.sent(),this.acquiredIatSet.delete(v.iat),d.removeItemSync(h),Ro.default().unlock(v.iat),c.notifyWaiters(),_.label=2;case 2:return[2]}})})},c.lockCorrector=function(f){for(var d=Date.now()-5e3,h=f,p=[],v=0;;){var _=h.keySync(v);if(_===null)break;p.push(_),v++}for(var m=!1,g=0;gDate.now();class Rr extends Error{constructor(t,r){super(r),this.error=t,this.error_description=r,Object.setPrototypeOf(this,Rr.prototype)}static fromPayload({error:t,error_description:r}){return new Rr(t,r)}}class m1 extends Rr{constructor(t,r,n,i=null){super(t,r),this.state=n,this.appState=i,Object.setPrototypeOf(this,m1.prototype)}}class $c extends Rr{constructor(){super("timeout","Timeout"),Object.setPrototypeOf(this,$c.prototype)}}class g1 extends $c{constructor(t){super(),this.popup=t,Object.setPrototypeOf(this,g1.prototype)}}class _1 extends Rr{constructor(t){super("cancelled","Popup closed"),this.popup=t,Object.setPrototypeOf(this,_1.prototype)}}class y1 extends Rr{constructor(t,r,n){super(t,r),this.mfa_token=n,Object.setPrototypeOf(this,y1.prototype)}}class em extends Rr{constructor(t,r){super("missing_refresh_token",`Missing Refresh Token (audience: '${Gj(t,["default"])}', scope: '${Gj(r)}')`),this.audience=t,this.scope=r,Object.setPrototypeOf(this,em.prototype)}}function Gj(e,t=[]){return e&&!t.includes(e)?e:""}const Jd=()=>window.crypto,dE=()=>{const e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_~.";let t="";return Array.from(Jd().getRandomValues(new Uint8Array(43))).forEach(r=>t+=e[r%e.length]),t},Vj=e=>btoa(e),KR=e=>{var{clientId:t}=e,r=fi(e,["clientId"]);return new URLSearchParams((n=>Object.keys(n).filter(i=>n[i]!==void 0).reduce((i,a)=>Object.assign(Object.assign({},i),{[a]:n[a]}),{}))(Object.assign({client_id:t},r))).toString()},Yj=e=>(t=>decodeURIComponent(atob(t).split("").map(r=>"%"+("00"+r.charCodeAt(0).toString(16)).slice(-2)).join("")))(e.replace(/_/g,"/").replace(/-/g,"+")),w0e=async(e,t)=>{const r=await fetch(e,t);return{ok:r.ok,json:await r.json()}},R0e=async(e,t,r)=>{const n=new AbortController;let i;return t.signal=n.signal,Promise.race([w0e(e,t),new Promise((a,o)=>{i=setTimeout(()=>{n.abort(),o(new Error("Timeout when executing 'fetch'"))},r)})]).finally(()=>{clearTimeout(i)})},T0e=async(e,t,r,n,i,a,o)=>{return s={auth:{audience:t,scope:r},timeout:i,fetchUrl:e,fetchOptions:n,useFormData:o},u=a,new Promise(function(l,c){const f=new MessageChannel;f.port1.onmessage=function(d){d.data.error?c(new Error(d.data.error)):l(d.data),f.port1.close()},u.postMessage(s,[f.port2])});var s,u},k0e=async(e,t,r,n,i,a,o=1e4)=>i?T0e(e,t,r,n,o,i,a):R0e(e,n,o);async function O0e(e,t){var{baseUrl:r,timeout:n,audience:i,scope:a,auth0Client:o,useFormData:s}=e,u=fi(e,["baseUrl","timeout","audience","scope","auth0Client","useFormData"]);const l=s?KR(u):JSON.stringify(u);return await async function(c,f,d,h,p,v,_){let m,g=null;for(let R=0;R<3;R++)try{m=await k0e(c,d,h,p,v,_,f),g=null;break}catch(O){g=O}if(g)throw g;const y=m.json,{error:S,error_description:b}=y,E=fi(y,["error","error_description"]),{ok:w}=m;if(!w){const R=b||`HTTP error. Unable to fetch ${c}`;throw S==="mfa_required"?new y1(S,R,E.mfa_token):S==="missing_refresh_token"?new em(d,h):new Rr(S||"request_error",R)}return E}(`${r}/oauth/token`,n,i||"default",a,{method:"POST",body:l,headers:{"Content-Type":s?"application/x-www-form-urlencoded":"application/json","Auth0-Client":btoa(JSON.stringify(o||Q5))}},t,s)}const ld=(...e)=>{return(t=e.filter(Boolean).join(" ").trim().split(/\s+/),Array.from(new Set(t))).join(" ");var t};class vi{constructor(t,r="@@auth0spajs@@",n){this.prefix=r,this.suffix=n,this.clientId=t.clientId,this.scope=t.scope,this.audience=t.audience}toKey(){return[this.prefix,this.clientId,this.audience,this.scope,this.suffix].filter(Boolean).join("::")}static fromKey(t){const[r,n,i,a]=t.split("::");return new vi({clientId:n,scope:a,audience:i},r)}static fromCacheEntry(t){const{scope:r,audience:n,client_id:i}=t;return new vi({scope:r,audience:n,clientId:i})}}class P0e{set(t,r){localStorage.setItem(t,JSON.stringify(r))}get(t){const r=window.localStorage.getItem(t);if(r)try{return JSON.parse(r)}catch{return}}remove(t){localStorage.removeItem(t)}allKeys(){return Object.keys(window.localStorage).filter(t=>t.startsWith("@@auth0spajs@@"))}}class J5{constructor(){this.enclosedCache=function(){let t={};return{set(r,n){t[r]=n},get(r){const n=t[r];if(n)return n},remove(r){delete t[r]},allKeys:()=>Object.keys(t)}}()}}class I0e{constructor(t,r,n){this.cache=t,this.keyManifest=r,this.nowProvider=n||K5}async setIdToken(t,r,n){var i;const a=this.getIdTokenCacheKey(t);await this.cache.set(a,{id_token:r,decodedToken:n}),await((i=this.keyManifest)===null||i===void 0?void 0:i.add(a))}async getIdToken(t){const r=await this.cache.get(this.getIdTokenCacheKey(t.clientId));if(!r&&t.scope&&t.audience){const n=await this.get(t);return!n||!n.id_token||!n.decodedToken?void 0:{id_token:n.id_token,decodedToken:n.decodedToken}}if(r)return{id_token:r.id_token,decodedToken:r.decodedToken}}async get(t,r=0){var n;let i=await this.cache.get(t.toKey());if(!i){const s=await this.getCacheKeys();if(!s)return;const u=this.matchExistingCacheKey(t,s);u&&(i=await this.cache.get(u))}if(!i)return;const a=await this.nowProvider(),o=Math.floor(a/1e3);return i.expiresAt-r!t||i.includes(t)).reduce(async(i,a)=>{await i,await this.cache.remove(a)},Promise.resolve()),await((r=this.keyManifest)===null||r===void 0?void 0:r.clear()))}async wrapCacheEntry(t){const r=await this.nowProvider();return{body:t,expiresAt:Math.floor(r/1e3)+t.expires_in}}async getCacheKeys(){var t;return this.keyManifest?(t=await this.keyManifest.get())===null||t===void 0?void 0:t.keys:this.cache.allKeys?this.cache.allKeys():void 0}getIdTokenCacheKey(t){return new vi({clientId:t},"@@auth0spajs@@","@@user@@").toKey()}matchExistingCacheKey(t,r){return r.filter(n=>{var i;const a=vi.fromKey(n),o=new Set(a.scope&&a.scope.split(" ")),s=((i=t.scope)===null||i===void 0?void 0:i.split(" "))||[],u=a.scope&&s.reduce((l,c)=>l&&o.has(c),!0);return a.prefix==="@@auth0spajs@@"&&a.clientId===t.clientId&&a.audience===t.audience&&u})[0]}}class x0e{constructor(t,r,n){this.storage=t,this.clientId=r,this.cookieDomain=n,this.storageKey=`a0.spajs.txs.${this.clientId}`}create(t){this.storage.save(this.storageKey,t,{daysUntilExpire:1,cookieDomain:this.cookieDomain})}get(){return this.storage.get(this.storageKey)}remove(){this.storage.remove(this.storageKey,{cookieDomain:this.cookieDomain})}}const wl=e=>typeof e=="number",C0e=["iss","aud","exp","nbf","iat","jti","azp","nonce","auth_time","at_hash","c_hash","acr","amr","sub_jwk","cnf","sip_from_tag","sip_date","sip_callid","sip_cseq_num","sip_via_branch","orig","dest","mky","events","toe","txn","rph","sid","vot","vtm"],$0e=e=>{if(!e.id_token)throw new Error("ID token is required but missing");const t=(a=>{const o=a.split("."),[s,u,l]=o;if(o.length!==3||!s||!u||!l)throw new Error("ID token could not be decoded");const c=JSON.parse(Yj(u)),f={__raw:a},d={};return Object.keys(c).forEach(h=>{f[h]=c[h],C0e.includes(h)||(d[h]=c[h])}),{encoded:{header:s,payload:u,signature:l},header:JSON.parse(Yj(s)),claims:f,user:d}})(e.id_token);if(!t.claims.iss)throw new Error("Issuer (iss) claim must be a string present in the ID token");if(t.claims.iss!==e.iss)throw new Error(`Issuer (iss) claim mismatch in the ID token; expected "${e.iss}", found "${t.claims.iss}"`);if(!t.user.sub)throw new Error("Subject (sub) claim must be a string present in the ID token");if(t.header.alg!=="RS256")throw new Error(`Signature algorithm of "${t.header.alg}" is not supported. Expected the ID token to be signed with "RS256".`);if(!t.claims.aud||typeof t.claims.aud!="string"&&!Array.isArray(t.claims.aud))throw new Error("Audience (aud) claim must be a string or array of strings present in the ID token");if(Array.isArray(t.claims.aud)){if(!t.claims.aud.includes(e.aud))throw new Error(`Audience (aud) claim mismatch in the ID token; expected "${e.aud}" but was not one of "${t.claims.aud.join(", ")}"`);if(t.claims.aud.length>1){if(!t.claims.azp)throw new Error("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values");if(t.claims.azp!==e.aud)throw new Error(`Authorized Party (azp) claim mismatch in the ID token; expected "${e.aud}", found "${t.claims.azp}"`)}}else if(t.claims.aud!==e.aud)throw new Error(`Audience (aud) claim mismatch in the ID token; expected "${e.aud}" but found "${t.claims.aud}"`);if(e.nonce){if(!t.claims.nonce)throw new Error("Nonce (nonce) claim must be a string present in the ID token");if(t.claims.nonce!==e.nonce)throw new Error(`Nonce (nonce) claim mismatch in the ID token; expected "${e.nonce}", found "${t.claims.nonce}"`)}if(e.max_age&&!wl(t.claims.auth_time))throw new Error("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified");if(t.claims.exp==null||!wl(t.claims.exp))throw new Error("Expiration Time (exp) claim must be a number present in the ID token");if(!wl(t.claims.iat))throw new Error("Issued At (iat) claim must be a number present in the ID token");const r=e.leeway||60,n=new Date(e.now||Date.now()),i=new Date(0);if(i.setUTCSeconds(t.claims.exp+r),n>i)throw new Error(`Expiration Time (exp) claim error in the ID token; current time (${n}) is after expiration time (${i})`);if(t.claims.nbf!=null&&wl(t.claims.nbf)){const a=new Date(0);if(a.setUTCSeconds(t.claims.nbf-r),na)throw new Error(`Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Current time (${n}) is after last auth at ${a}`)}if(e.organization){const a=e.organization.trim();if(a.startsWith("org_")){const o=a;if(!t.claims.org_id)throw new Error("Organization ID (org_id) claim must be a string present in the ID token");if(o!==t.claims.org_id)throw new Error(`Organization ID (org_id) claim mismatch in the ID token; expected "${o}", found "${t.claims.org_id}"`)}else{const o=a.toLowerCase();if(!t.claims.org_name)throw new Error("Organization Name (org_name) claim must be a string present in the ID token");if(o!==t.claims.org_name)throw new Error(`Organization Name (org_name) claim mismatch in the ID token; expected "${o}", found "${t.claims.org_name}"`)}}return t};var Lo=v1(function(e,t){var r=Po&&Po.__assign||function(){return r=Object.assign||function(u){for(var l,c=1,f=arguments.length;c"u")return;const t=sessionStorage.getItem(e);return t!=null?JSON.parse(t):void 0},save(e,t){sessionStorage.setItem(e,JSON.stringify(t))},remove(e){sessionStorage.removeItem(e)}};function L0e(e,t,r){var n=t===void 0?null:t,i=function(u,l){var c=atob(u);if(l){for(var f=new Uint8Array(c.length),d=0,h=c.length;d0?await this.cache.set(this.manifestKey,{keys:[...n]}):await this.cache.remove(this.manifestKey)}}get(){return this.cache.get(this.manifestKey)}clear(){return this.cache.remove(this.manifestKey)}createManifestKeyFrom(t){return`@@auth0spajs@@::${t}`}}const j0e={memory:()=>new J5().enclosedCache,localstorage:()=>new P0e},Xj=e=>j0e[e],Zj=e=>{const{openUrl:t,onRedirect:r}=e,n=fi(e,["openUrl","onRedirect"]);return Object.assign(Object.assign({},n),{openUrl:t===!1||t?t:r})},vE=new b0e;class q0e{constructor(t){let r,n;if(this.userCache=new J5().enclosedCache,this.defaultOptions={authorizationParams:{scope:"openid profile email"},useRefreshTokensFallback:!1,useFormData:!0},this._releaseLockOnPageHide=async()=>{await vE.releaseLock("auth0.lock.getTokenSilently"),window.removeEventListener("pagehide",this._releaseLockOnPageHide)},this.options=Object.assign(Object.assign(Object.assign({},this.defaultOptions),t),{authorizationParams:Object.assign(Object.assign({},this.defaultOptions.authorizationParams),t.authorizationParams)}),typeof window<"u"&&(()=>{if(!Jd())throw new Error("For security reasons, `window.crypto` is required to run `auth0-spa-js`.");if(Jd().subtle===void 0)throw new Error(` auth0-spa-js must run on a secure origin. See https://github.com/auth0/auth0-spa-js/blob/main/FAQ.md#why-do-i-get-auth0-spa-js-must-run-on-a-secure-origin for more information. `)})(),t.cache&&t.cacheLocation&&console.warn("Both `cache` and `cacheLocation` options have been specified in the Auth0Client configuration; ignoring `cacheLocation` and using `cache`."),t.cache)n=t.cache;else{if(r=t.cacheLocation||"memory",!Xj(r))throw new Error(`Invalid cache location "${r}"`);n=Xj(r)()}this.httpTimeoutMs=t.httpTimeoutInSeconds?1e3*t.httpTimeoutInSeconds:1e4,this.cookieStorage=t.legacySameSiteCookie===!1?Es:N0e,this.orgHintCookieName=`auth0.${this.options.clientId}.organization_hint`,this.isAuthenticatedCookieName=(o=>`auth0.${o}.is.authenticated`)(this.options.clientId),this.sessionCheckExpiryDays=t.sessionCheckExpiryDays||1;const i=t.useCookiesForTransactions?this.cookieStorage:A0e;var a;this.scope=ld("openid",this.options.authorizationParams.scope,this.options.useRefreshTokens?"offline_access":""),this.transactionManager=new x0e(i,this.options.clientId,this.options.cookieDomain),this.nowProvider=this.options.nowProvider||K5,this.cacheManager=new I0e(n,n.allKeys?void 0:new F0e(n,this.options.clientId),this.nowProvider),this.domainUrl=(a=this.options.domain,/^https?:\/\//.test(a)?a:`https://${a}`),this.tokenIssuer=((o,s)=>o?o.startsWith("https://")?o:`https://${o}/`:`${s}/`)(this.options.issuer,this.domainUrl),typeof window<"u"&&window.Worker&&this.options.useRefreshTokens&&r==="memory"&&(this.options.workerUrl?this.worker=new Worker(this.options.workerUrl):this.worker=new M0e)}_url(t){const r=encodeURIComponent(btoa(JSON.stringify(this.options.auth0Client||Q5)));return`${this.domainUrl}${t}&auth0Client=${r}`}_authorizeUrl(t){return this._url(`/authorize?${KR(t)}`)}async _verifyIdToken(t,r,n){const i=await this.nowProvider();return $0e({iss:this.tokenIssuer,aud:this.options.clientId,id_token:t,nonce:r,organization:n,leeway:this.options.leeway,max_age:(a=this.options.authorizationParams.max_age,typeof a!="string"?a:parseInt(a,10)||void 0),now:i});var a}_processOrgHint(t){t?this.cookieStorage.save(this.orgHintCookieName,t,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}):this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain})}async _prepareAuthorizeUrl(t,r,n){const i=Vj(dE()),a=Vj(dE()),o=dE(),s=(c=>{const f=new Uint8Array(c);return(d=>{const h={"+":"-","/":"_","=":""};return d.replace(/[+/=]/g,p=>h[p])})(window.btoa(String.fromCharCode(...Array.from(f))))})(await(async c=>await Jd().subtle.digest({name:"SHA-256"},new TextEncoder().encode(c)))(o)),u=((c,f,d,h,p,v,_,m)=>Object.assign(Object.assign(Object.assign({client_id:c.clientId},c.authorizationParams),d),{scope:ld(f,d.scope),response_type:"code",response_mode:m||"query",state:h,nonce:p,redirect_uri:_||c.authorizationParams.redirect_uri,code_challenge:v,code_challenge_method:"S256"}))(this.options,this.scope,t,i,a,s,t.redirect_uri||this.options.authorizationParams.redirect_uri||n,r==null?void 0:r.response_mode),l=this._authorizeUrl(u);return{nonce:a,code_verifier:o,scope:u.scope,audience:u.audience||"default",redirect_uri:u.redirect_uri,state:i,url:l}}async loginWithPopup(t,r){var n;if(t=t||{},!(r=r||{}).popup&&(r.popup=(s=>{const u=window.screenX+(window.innerWidth-400)/2,l=window.screenY+(window.innerHeight-600)/2;return window.open(s,"auth0:authorize:popup",`left=${u},top=${l},width=400,height=600,resizable,scrollbars=yes,status=1`)})(""),!r.popup))throw new Error("Unable to open a popup for loginWithPopup - window.open returned `null`");const i=await this._prepareAuthorizeUrl(t.authorizationParams||{},{response_mode:"web_message"},window.location.origin);r.popup.location.href=i.url;const a=await(s=>new Promise((u,l)=>{let c;const f=setInterval(()=>{s.popup&&s.popup.closed&&(clearInterval(f),clearTimeout(d),window.removeEventListener("message",c,!1),l(new _1(s.popup)))},1e3),d=setTimeout(()=>{clearInterval(f),l(new g1(s.popup)),window.removeEventListener("message",c,!1)},1e3*(s.timeoutInSeconds||60));c=function(h){if(h.data&&h.data.type==="authorization_response"){if(clearTimeout(d),clearInterval(f),window.removeEventListener("message",c,!1),s.popup.close(),h.data.response.error)return l(Rr.fromPayload(h.data.response));u(h.data.response)}},window.addEventListener("message",c)}))(Object.assign(Object.assign({},r),{timeoutInSeconds:r.timeoutInSeconds||this.options.authorizeTimeoutInSeconds||60}));if(i.state!==a.state)throw new Rr("state_mismatch","Invalid state");const o=((n=t.authorizationParams)===null||n===void 0?void 0:n.organization)||this.options.authorizationParams.organization;await this._requestToken({audience:i.audience,scope:i.scope,code_verifier:i.code_verifier,grant_type:"authorization_code",code:a.code,redirect_uri:i.redirect_uri},{nonceIn:i.nonce,organization:o})}async getUser(){var t;const r=await this._getIdTokenFromCache();return(t=r==null?void 0:r.decodedToken)===null||t===void 0?void 0:t.user}async getIdTokenClaims(){var t;const r=await this._getIdTokenFromCache();return(t=r==null?void 0:r.decodedToken)===null||t===void 0?void 0:t.claims}async loginWithRedirect(t={}){var r;const n=Zj(t),{openUrl:i,fragment:a,appState:o}=n,s=fi(n,["openUrl","fragment","appState"]),u=((r=s.authorizationParams)===null||r===void 0?void 0:r.organization)||this.options.authorizationParams.organization,l=await this._prepareAuthorizeUrl(s.authorizationParams||{}),{url:c}=l,f=fi(l,["url"]);this.transactionManager.create(Object.assign(Object.assign(Object.assign({},f),{appState:o}),u&&{organization:u}));const d=a?`${c}#${a}`:c;i?await i(d):window.location.assign(d)}async handleRedirectCallback(t=window.location.href){const r=t.split("?").slice(1);if(r.length===0)throw new Error("There are no query params available for parsing.");const{state:n,code:i,error:a,error_description:o}=(f=>{f.indexOf("#")>-1&&(f=f.substring(0,f.indexOf("#")));const d=new URLSearchParams(f);return{state:d.get("state"),code:d.get("code")||void 0,error:d.get("error")||void 0,error_description:d.get("error_description")||void 0}})(r.join("")),s=this.transactionManager.get();if(!s)throw new Rr("missing_transaction","Invalid state");if(this.transactionManager.remove(),a)throw new m1(a,o||a,n,s.appState);if(!s.code_verifier||s.state&&s.state!==n)throw new Rr("state_mismatch","Invalid state");const u=s.organization,l=s.nonce,c=s.redirect_uri;return await this._requestToken(Object.assign({audience:s.audience,scope:s.scope,code_verifier:s.code_verifier,grant_type:"authorization_code",code:i},c?{redirect_uri:c}:{}),{nonceIn:l,organization:u}),{appState:s.appState}}async checkSession(t){if(!this.cookieStorage.get(this.isAuthenticatedCookieName)){if(!this.cookieStorage.get("auth0.is.authenticated"))return;this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove("auth0.is.authenticated")}try{await this.getTokenSilently(t)}catch{}}async getTokenSilently(t={}){var r;const n=Object.assign(Object.assign({cacheMode:"on"},t),{authorizationParams:Object.assign(Object.assign(Object.assign({},this.options.authorizationParams),t.authorizationParams),{scope:ld(this.scope,(r=t.authorizationParams)===null||r===void 0?void 0:r.scope)})}),i=await((a,o)=>{let s=pE[o];return s||(s=a().finally(()=>{delete pE[o],s=null}),pE[o]=s),s})(()=>this._getTokenSilently(n),`${this.options.clientId}::${n.authorizationParams.audience}::${n.authorizationParams.scope}`);return t.detailedResponse?i:i==null?void 0:i.access_token}async _getTokenSilently(t){const{cacheMode:r}=t,n=fi(t,["cacheMode"]);if(r!=="off"){const i=await this._getEntryFromCache({scope:n.authorizationParams.scope,audience:n.authorizationParams.audience||"default",clientId:this.options.clientId});if(i)return i}if(r!=="cache-only"){if(!await(async(i,a=3)=>{for(let o=0;ovE.acquireLock("auth0.lock.getTokenSilently",5e3),10))throw new $c;try{if(window.addEventListener("pagehide",this._releaseLockOnPageHide),r!=="off"){const l=await this._getEntryFromCache({scope:n.authorizationParams.scope,audience:n.authorizationParams.audience||"default",clientId:this.options.clientId});if(l)return l}const i=this.options.useRefreshTokens?await this._getTokenUsingRefreshToken(n):await this._getTokenFromIFrame(n),{id_token:a,access_token:o,oauthTokenScope:s,expires_in:u}=i;return Object.assign(Object.assign({id_token:a,access_token:o},s?{scope:s}:null),{expires_in:u})}finally{await vE.releaseLock("auth0.lock.getTokenSilently"),window.removeEventListener("pagehide",this._releaseLockOnPageHide)}}}async getTokenWithPopup(t={},r={}){var n;const i=Object.assign(Object.assign({},t),{authorizationParams:Object.assign(Object.assign(Object.assign({},this.options.authorizationParams),t.authorizationParams),{scope:ld(this.scope,(n=t.authorizationParams)===null||n===void 0?void 0:n.scope)})});return r=Object.assign(Object.assign({},E0e),r),await this.loginWithPopup(i,r),(await this.cacheManager.get(new vi({scope:i.authorizationParams.scope,audience:i.authorizationParams.audience||"default",clientId:this.options.clientId}))).access_token}async isAuthenticated(){return!!await this.getUser()}_buildLogoutUrl(t){t.clientId!==null?t.clientId=t.clientId||this.options.clientId:delete t.clientId;const r=t.logoutParams||{},{federated:n}=r,i=fi(r,["federated"]),a=n?"&federated":"";return this._url(`/v2/logout?${KR(Object.assign({clientId:t.clientId},i))}`)+a}async logout(t={}){const r=Zj(t),{openUrl:n}=r,i=fi(r,["openUrl"]);t.clientId===null?await this.cacheManager.clear():await this.cacheManager.clear(t.clientId||this.options.clientId),this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove(this.isAuthenticatedCookieName,{cookieDomain:this.options.cookieDomain}),this.userCache.remove("@@user@@");const a=this._buildLogoutUrl(i);n?await n(a):n!==!1&&window.location.assign(a)}async _getTokenFromIFrame(t){const r=Object.assign(Object.assign({},t.authorizationParams),{prompt:"none"}),n=this.cookieStorage.get(this.orgHintCookieName);n&&!r.organization&&(r.organization=n);const{url:i,state:a,nonce:o,code_verifier:s,redirect_uri:u,scope:l,audience:c}=await this._prepareAuthorizeUrl(r,{response_mode:"web_message"},window.location.origin);try{if(window.crossOriginIsolated)throw new Rr("login_required","The application is running in a Cross-Origin Isolated context, silently retrieving a token without refresh token is not possible.");const f=t.timeoutInSeconds||this.options.authorizeTimeoutInSeconds,d=await((p,v,_=60)=>new Promise((m,g)=>{const y=window.document.createElement("iframe");y.setAttribute("width","0"),y.setAttribute("height","0"),y.style.display="none";const S=()=>{window.document.body.contains(y)&&(window.document.body.removeChild(y),window.removeEventListener("message",b,!1))};let b;const E=setTimeout(()=>{g(new $c),S()},1e3*_);b=function(w){if(w.origin!=v||!w.data||w.data.type!=="authorization_response")return;const R=w.source;R&&R.close(),w.data.response.error?g(Rr.fromPayload(w.data.response)):m(w.data.response),clearTimeout(E),window.removeEventListener("message",b,!1),setTimeout(S,2e3)},window.addEventListener("message",b,!1),window.document.body.appendChild(y),y.setAttribute("src",p)}))(i,this.domainUrl,f);if(a!==d.state)throw new Rr("state_mismatch","Invalid state");const h=await this._requestToken(Object.assign(Object.assign({},t.authorizationParams),{code_verifier:s,code:d.code,grant_type:"authorization_code",redirect_uri:u,timeout:t.authorizationParams.timeout||this.httpTimeoutMs}),{nonceIn:o,organization:r.organization});return Object.assign(Object.assign({},h),{scope:l,oauthTokenScope:h.scope,audience:c})}catch(f){throw f.error==="login_required"&&this.logout({openUrl:!1}),f}}async _getTokenUsingRefreshToken(t){const r=await this.cacheManager.get(new vi({scope:t.authorizationParams.scope,audience:t.authorizationParams.audience||"default",clientId:this.options.clientId}));if(!(r&&r.refresh_token||this.worker)){if(this.options.useRefreshTokensFallback)return await this._getTokenFromIFrame(t);throw new em(t.authorizationParams.audience||"default",t.authorizationParams.scope)}const n=t.authorizationParams.redirect_uri||this.options.authorizationParams.redirect_uri||window.location.origin,i=typeof t.timeoutInSeconds=="number"?1e3*t.timeoutInSeconds:null;try{const a=await this._requestToken(Object.assign(Object.assign(Object.assign({},t.authorizationParams),{grant_type:"refresh_token",refresh_token:r&&r.refresh_token,redirect_uri:n}),i&&{timeout:i}));return Object.assign(Object.assign({},a),{scope:t.authorizationParams.scope,oauthTokenScope:a.scope,audience:t.authorizationParams.audience||"default"})}catch(a){if((a.message.indexOf("Missing Refresh Token")>-1||a.message&&a.message.indexOf("invalid refresh token")>-1)&&this.options.useRefreshTokensFallback)return await this._getTokenFromIFrame(t);throw a}}async _saveEntryInCache(t){const{id_token:r,decodedToken:n}=t,i=fi(t,["id_token","decodedToken"]);this.userCache.set("@@user@@",{id_token:r,decodedToken:n}),await this.cacheManager.setIdToken(this.options.clientId,t.id_token,t.decodedToken),await this.cacheManager.set(i)}async _getIdTokenFromCache(){const t=this.options.authorizationParams.audience||"default",r=await this.cacheManager.getIdToken(new vi({clientId:this.options.clientId,audience:t,scope:this.scope})),n=this.userCache.get("@@user@@");return r&&r.id_token===(n==null?void 0:n.id_token)?n:(this.userCache.set("@@user@@",r),r)}async _getEntryFromCache({scope:t,audience:r,clientId:n}){const i=await this.cacheManager.get(new vi({scope:t,audience:r,clientId:n}),60);if(i&&i.access_token){const{access_token:a,oauthTokenScope:o,expires_in:s}=i,u=await this._getIdTokenFromCache();return u&&Object.assign(Object.assign({id_token:u.id_token,access_token:a},o?{scope:o}:null),{expires_in:s})}}async _requestToken(t,r){const{nonceIn:n,organization:i}=r||{},a=await O0e(Object.assign({baseUrl:this.domainUrl,client_id:this.options.clientId,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs},t),this.worker),o=await this._verifyIdToken(a.id_token,n,i);return await this._saveEntryInCache(Object.assign(Object.assign(Object.assign(Object.assign({},a),{decodedToken:o,scope:t.scope,audience:t.audience||"default"}),a.scope?{oauthTokenScope:a.scope}:null),{client_id:this.options.clientId})),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgHint(i||o.claims.org_id),Object.assign(Object.assign({},a),{decodedToken:o})}}var eG={},mE={},eq;function U0e(){return eq||(eq=1,function(e){var t=xe;t(e,"__esModule",{value:!0}),e.createAuth=n;var r=ov();function n(a,o){const s=i(a);return(0,r.createAuthentication)(s,o)}function i(a){return{type:"auth0",client:a,restoreAuthState:async()=>{var o,s,u,l,c;if((s=(o=Ut==null?void 0:Ut.location)==null?void 0:o.search)!=null&&s.includes("code=")&&((l=(u=Ut==null?void 0:Ut.location)==null?void 0:u.search)!=null&&l.includes("state="))){const{appState:f}=await a.handleRedirectCallback(),d=f&&f.targetUrl?f.targetUrl:window.location.pathname;(c=Ut==null?void 0:Ut.location)==null||c.assign(d)}},login:async o=>a.loginWithRedirect(o),logout:async o=>a.logout(o),signup:async o=>a.loginWithRedirect({...o,authorizationParams:{screen_hint:"signup",prompt:"login"}}),getToken:()=>a.getTokenSilently(),getUserMetadata:async()=>await a.getUser()||null}}}(mE)),mE}(function(e){var t=xe;t(e,"__esModule",{value:!0}),t(e,"createAuth",{enumerable:!0,get:function(){return r.createAuth}});var r=U0e()})(eG);const B0e=new q0e({domain:"landingsite.us.auth0.com",clientId:"fhFKuJDrScHQlR6yv6XpGZ7z4zpnfyAM",authorizationParams:{redirect_uri:"https://app.landingsite.ai/login-success",audience:"https://landingsite.us.auth0.com/api/v2/"},cacheLocation:"localstorage",useRefreshTokens:!0}),{AuthProvider:z0e,useAuth:tm}=eG.createAuth(B0e),H0e=JW` mutation GetStripeCustomerPortalSessionUrlMutation { getStripeCustomerPortalSessionUrl } `,W0e=({children:e})=>{const{loading:t,isAuthenticated:r,logIn:n,signUp:i,logOut:a}=tm(),[o,s]=I.useState(!1),[u]=Rc.useMutation(H0e),l=d=>{d.preventDefault(),n({appState:{targetUrl:`/login-success?redirectTo=${encodeURIComponent(window.location.pathname+window.location.search)}`}})},c=d=>{d.preventDefault(),i({appState:{targetUrl:`/login-success?redirectTo=${encodeURIComponent(window.location.pathname+window.location.search)}`}})},f=async()=>{s(!0);const d=await u();console.log(d),window.location.href=d.data.getStripeCustomerPortalSessionUrl};return P.jsx(P.Fragment,{children:P.jsxs("div",{className:"min-h-full",children:[P.jsx("div",{className:"h-full min-w-full bg-white",children:P.jsx("header",{id:"main-header",className:"py-3",children:P.jsx("div",{className:"px-4 sm:px-6 lg:px-8",children:P.jsxs("div",{className:"flex items-center justify-between",children:[P.jsxs("a",{href:"/",className:"flex items-center text-xl font-bold tracking-tight text-gray-800 sm:text-2xl",children:[P.jsx("img",{src:"/logo_full_black.png",className:"mr-2 inline h-5",alt:"Landingsite"}),"Landingsite.ai"]}),!t&&!r&&P.jsxs("ul",{className:"flex items-center gap-x-8 text-sm text-black",children:[P.jsx("li",{children:P.jsx("a",{className:"hover:underline",href:"/login",onClick:l,children:"Log In"})}),P.jsx("li",{children:P.jsx("a",{className:"rounded bg-lime-400 px-4 py-2 text-sm hover:bg-lime-500",href:"/signup",onClick:c,children:"Sign Up"})})]}),!t&&r&&P.jsx(ou,{className:"relative flex",children:({open:d})=>P.jsxs(P.Fragment,{children:[P.jsxs(ou.Button,{className:` ${d?"":"text-opacity-90"} group inline-flex h-[32px] w-[50px] flex-grow items-center justify-center rounded-lg bg-lime-400 p-2 text-base font-medium text-gray-800 hover:bg-gray-700 hover:text-white focus:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-opacity-75`,children:[P.jsx("i",{className:"fa-solid fa-user mr-1"}),P.jsx("i",{className:"fa-regular fa-chevron-down"})]}),P.jsx(Y5,{as:I.Fragment,enter:"transition ease-out duration-200",enterFrom:"opacity-0 translate-y-1",enterTo:"opacity-100 translate-y-0",leave:"transition ease-in duration-150",leaveFrom:"opacity-100 translate-y-0",leaveTo:"opacity-0 translate-y-1",children:P.jsx(ou.Panel,{className:"absolute -left-3/4 z-[80] mt-10 w-[180px] -translate-x-1/2 transform px-4 sm:w-[140px] sm:px-0",children:P.jsxs("div",{className:"overflow-hidden rounded-lg shadow-lg ring-1 ring-black ring-opacity-5",children:[P.jsxs("a",{href:"/",className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",children:[P.jsx("span",{children:"Dashboard"}),P.jsx("i",{className:"fa-solid fa-user"})]}),P.jsxs("button",{className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",onClick:f,children:[P.jsx("span",{children:"Billing"}),!o&&P.jsx("i",{className:"fa-regular fa-credit-card"}),o&&P.jsx("i",{className:"fa-regular fa-spinner-third animate-spin"})]}),P.jsxs("button",{className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",onClick:()=>{a({logoutParams:{returnTo:"https://www.landingsite.ai/"}})},children:[P.jsx("span",{children:"Log Out"}),P.jsx("i",{className:"fa-solid fa-sign-out"})]})]})})})]})})]})})})}),P.jsx("main",{className:"h-full",children:e})]})})};var tG={},ma={},tq;function ys(){if(tq)return ma;tq=1;let e={data:""},t=_=>typeof window=="object"?((_?_.querySelector("#_goober"):window._goober)||Object.assign((_||document.head).appendChild(document.createElement("style")),{innerHTML:" ",id:"_goober"})).firstChild:_||e,r=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,n=/\/\*[^]*?\*\/| +/g,i=/\n+/g,a=(_,m)=>{let g="",y="",S="";for(let b in _){let E=_[b];b[0]=="@"?b[1]=="i"?g=b+" "+E+";":y+=b[1]=="f"?a(E,b):b+"{"+a(E,b[1]=="k"?"":m)+"}":typeof E=="object"?y+=a(E,m?m.replace(/([^,])+/g,w=>b.replace(/(^:.*)|([^,])+/g,R=>/&/.test(R)?R.replace(/&/g,w):w?w+" "+R:R)):b):E!=null&&(b=/^--/.test(b)?b:b.replace(/[A-Z]/g,"-$&").toLowerCase(),S+=a.p?a.p(b,E):b+":"+E+";")}return g+(m&&S?m+"{"+S+"}":S)+y},o={},s=_=>{if(typeof _=="object"){let m="";for(let g in _)m+=g+s(_[g]);return m}return _},u=(_,m,g,y,S)=>{let b=s(_),E=o[b]||(o[b]=(R=>{let O=0,k=11;for(;O>>0;return"go"+k})(b));if(!o[E]){let R=b!==_?_:(O=>{let k,C,T=[{}];for(;k=r.exec(O.replace(n,""));)k[4]?T.shift():k[3]?(C=k[3].replace(i," ").trim(),T.unshift(T[0][C]=T[0][C]||{})):T[0][k[1]]=k[2].replace(i," ").trim();return T[0]})(_);o[E]=a(S?{["@keyframes "+E]:R}:R,g?"":"."+E)}let w=g&&o.g?o.g:null;return g&&(o.g=o[E]),((R,O,k,C)=>{C?O.data=O.data.replace(C,R):O.data.indexOf(R)===-1&&(O.data=k?R+O.data:O.data+R)})(o[E],m,y,w),E},l=(_,m,g)=>_.reduce((y,S,b)=>{let E=m[b];if(E&&E.call){let w=E(g),R=w&&w.props&&w.props.className||/^go/.test(w)&&w;E=R?"."+R:w&&typeof w=="object"?w.props?"":a(w,""):w===!1?"":w}return y+S+(E??"")},"");function c(_){let m=this||{},g=_.call?_(m.p):_;return u(g.unshift?g.raw?l(g,[].slice.call(arguments,1),m.p):g.reduce((y,S)=>Object.assign(y,S&&S.call?S(m.p):S),{}):g,t(m.target),m.g,m.o,m.k)}let f,d,h,p=c.bind({g:1}),v=c.bind({k:1});return ma.css=c,ma.extractCss=_=>{let m=t(_),g=m.data;return m.data="",g},ma.glob=p,ma.keyframes=v,ma.setup=function(_,m,g,y){a.p=m,f=_,d=g,h=y},ma.styled=function(_,m){let g=this||{};return function(){let y=arguments;function S(b,E){let w=Object.assign({},b),R=w.className||S.className;g.p=Object.assign({theme:d&&d()},w),g.o=/ *go\d+/.test(R),w.className=c.apply(g,y)+(R?" "+R:""),m&&(w.ref=E);let O=_;return _[0]&&(O=w.as||_,delete w.as),h&&O[0]&&h(w),f(O,w)}return m?m(S):S}},ma}var gE,rq;function G0e(){if(rq)return gE;rq=1;var e=Object.create,t=Object.defineProperty,r=Object.getOwnPropertyDescriptor,n=Object.getOwnPropertyNames,i=Object.getPrototypeOf,a=Object.prototype.hasOwnProperty,o=(N,U)=>{for(var te in U)t(N,te,{get:U[te],enumerable:!0})},s=(N,U,te,fe)=>{if(U&&typeof U=="object"||typeof U=="function")for(let Se of n(U))!a.call(N,Se)&&Se!==te&&t(N,Se,{get:()=>U[Se],enumerable:!(fe=r(U,Se))||fe.enumerable});return N},u=(N,U,te)=>(te=N!=null?e(i(N)):{},s(U||!N||!N.__esModule?t(te,"default",{value:N,enumerable:!0}):te,N)),l=N=>s(t({},"__esModule",{value:!0}),N),c={};o(c,{CheckmarkIcon:()=>He,ErrorIcon:()=>re,LoaderIcon:()=>Ie,ToastBar:()=>rn,ToastIcon:()=>we,Toaster:()=>le,default:()=>Re,resolveValue:()=>d,toast:()=>$,useToaster:()=>B,useToasterStore:()=>k}),gE=l(c);var f=N=>typeof N=="function",d=(N,U)=>f(N)?N(U):N,h=(()=>{let N=0;return()=>(++N).toString()})(),p=(()=>{let N;return()=>{if(N===void 0&&typeof window<"u"){let U=matchMedia("(prefers-reduced-motion: reduce)");N=!U||U.matches}return N}})(),v=I,_=20,m=new Map,g=1e3,y=N=>{if(m.has(N))return;let U=setTimeout(()=>{m.delete(N),R({type:4,toastId:N})},g);m.set(N,U)},S=N=>{let U=m.get(N);U&&clearTimeout(U)},b=(N,U)=>{switch(U.type){case 0:return{...N,toasts:[U.toast,...N.toasts].slice(0,_)};case 1:return U.toast.id&&S(U.toast.id),{...N,toasts:N.toasts.map(Te=>Te.id===U.toast.id?{...Te,...U.toast}:Te)};case 2:let{toast:te}=U;return N.toasts.find(Te=>Te.id===te.id)?b(N,{type:1,toast:te}):b(N,{type:0,toast:te});case 3:let{toastId:fe}=U;return fe?y(fe):N.toasts.forEach(Te=>{y(Te.id)}),{...N,toasts:N.toasts.map(Te=>Te.id===fe||fe===void 0?{...Te,visible:!1}:Te)};case 4:return U.toastId===void 0?{...N,toasts:[]}:{...N,toasts:N.toasts.filter(Te=>Te.id!==U.toastId)};case 5:return{...N,pausedAt:U.time};case 6:let Se=U.time-(N.pausedAt||0);return{...N,pausedAt:void 0,toasts:N.toasts.map(Te=>({...Te,pauseDuration:Te.pauseDuration+Se}))}}},E=[],w={toasts:[],pausedAt:void 0},R=N=>{w=b(w,N),E.forEach(U=>{U(w)})},O={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},k=(N={})=>{let[U,te]=(0,v.useState)(w);(0,v.useEffect)(()=>(E.push(te),()=>{let Se=E.indexOf(te);Se>-1&&E.splice(Se,1)}),[U]);let fe=U.toasts.map(Se=>{var Te,Ue;return{...N,...N[Se.type],...Se,duration:Se.duration||((Te=N[Se.type])==null?void 0:Te.duration)||(N==null?void 0:N.duration)||O[Se.type],style:{...N.style,...(Ue=N[Se.type])==null?void 0:Ue.style,...Se.style}}});return{...U,toasts:fe}},C=(N,U="blank",te)=>({createdAt:Date.now(),visible:!0,type:U,ariaProps:{role:"status","aria-live":"polite"},message:N,pauseDuration:0,...te,id:(te==null?void 0:te.id)||h()}),T=N=>(U,te)=>{let fe=C(U,N,te);return R({type:2,toast:fe}),fe.id},$=(N,U)=>T("blank")(N,U);$.error=T("error"),$.success=T("success"),$.loading=T("loading"),$.custom=T("custom"),$.dismiss=N=>{R({type:3,toastId:N})},$.remove=N=>R({type:4,toastId:N}),$.promise=(N,U,te)=>{let fe=$.loading(U.loading,{...te,...te==null?void 0:te.loading});return N.then(Se=>($.success(d(U.success,Se),{id:fe,...te,...te==null?void 0:te.success}),Se)).catch(Se=>{$.error(d(U.error,Se),{id:fe,...te,...te==null?void 0:te.error})}),N};var L=I,G=(N,U)=>{R({type:1,toast:{id:N,height:U}})},Y=()=>{R({type:5,time:Date.now()})},B=N=>{let{toasts:U,pausedAt:te}=k(N);(0,L.useEffect)(()=>{if(te)return;let Te=Date.now(),Ue=U.map(tt=>{if(tt.duration===1/0)return;let Yt=(tt.duration||0)+tt.pauseDuration-(Te-tt.createdAt);if(Yt<0){tt.visible&&$.dismiss(tt.id);return}return setTimeout(()=>$.dismiss(tt.id),Yt)});return()=>{Ue.forEach(tt=>tt&&clearTimeout(tt))}},[U,te]);let fe=(0,L.useCallback)(()=>{te&&R({type:6,time:Date.now()})},[te]),Se=(0,L.useCallback)((Te,Ue)=>{let{reverseOrder:tt=!1,gutter:Yt=8,defaultPosition:Qt}=Ue||{},An=U.filter(Wr=>(Wr.position||Qt)===(Te.position||Qt)&&Wr.height),po=An.findIndex(Wr=>Wr.id===Te.id),ha=An.filter((Wr,vo)=>voWr.visible).slice(...tt?[ha+1]:[0,ha]).reduce((Wr,vo)=>Wr+(vo.height||0)+Yt,0)},[U]);return{toasts:U,handlers:{updateHeight:G,startPause:Y,endPause:fe,calculateOffset:Se}}},D=u(I),F=ys(),z=u(I),ee=ys(),Z=ys(),W=Z.keyframes` from { transform: scale(0) rotate(45deg); opacity: 0; } to { transform: scale(1) rotate(45deg); opacity: 1; }`,Q=Z.keyframes` from { transform: scale(0); opacity: 0; } to { transform: scale(1); opacity: 1; }`,ae=Z.keyframes` from { transform: scale(0) rotate(90deg); opacity: 0; } to { transform: scale(1) rotate(90deg); opacity: 1; }`,re=(0,Z.styled)("div")` width: 20px; opacity: 0; height: 20px; border-radius: 10px; background: ${N=>N.primary||"#ff4b4b"}; position: relative; transform: rotate(45deg); animation: ${W} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; animation-delay: 100ms; &:after, &:before { content: ''; animation: ${Q} 0.15s ease-out forwards; animation-delay: 150ms; position: absolute; border-radius: 3px; opacity: 0; background: ${N=>N.secondary||"#fff"}; bottom: 9px; left: 4px; height: 2px; width: 12px; } &:before { animation: ${ae} 0.15s ease-out forwards; animation-delay: 180ms; transform: rotate(90deg); } `,ie=ys(),Ee=ie.keyframes` from { transform: rotate(0deg); } to { transform: rotate(360deg); } `,Ie=(0,ie.styled)("div")` width: 12px; height: 12px; box-sizing: border-box; border: 2px solid; border-radius: 100%; border-color: ${N=>N.secondary||"#e0e0e0"}; border-right-color: ${N=>N.primary||"#616161"}; animation: ${Ee} 1s linear infinite; `,Pe=ys(),$e=Pe.keyframes` from { transform: scale(0) rotate(45deg); opacity: 0; } to { transform: scale(1) rotate(45deg); opacity: 1; }`,De=Pe.keyframes` 0% { height: 0; width: 0; opacity: 0; } 40% { height: 0; width: 6px; opacity: 1; } 100% { opacity: 1; height: 10px; }`,He=(0,Pe.styled)("div")` width: 20px; opacity: 0; height: 20px; border-radius: 10px; background: ${N=>N.primary||"#61d345"}; position: relative; transform: rotate(45deg); animation: ${$e} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; animation-delay: 100ms; &:after { content: ''; box-sizing: border-box; animation: ${De} 0.2s ease-out forwards; opacity: 0; animation-delay: 200ms; position: absolute; border-right: 2px solid; border-bottom: 2px solid; border-color: ${N=>N.secondary||"#fff"}; bottom: 6px; left: 6px; height: 10px; width: 6px; } `,Je=(0,ee.styled)("div")` position: absolute; `,et=(0,ee.styled)("div")` position: relative; display: flex; justify-content: center; align-items: center; min-width: 20px; min-height: 20px; `,ot=ee.keyframes` from { transform: scale(0.6); opacity: 0.4; } to { transform: scale(1); opacity: 1; }`,st=(0,ee.styled)("div")` position: relative; transform: scale(0.6); opacity: 0.4; min-width: 20px; animation: ${ot} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275) forwards; `,we=({toast:N})=>{let{icon:U,type:te,iconTheme:fe}=N;return U!==void 0?typeof U=="string"?z.createElement(st,null,U):U:te==="blank"?null:z.createElement(et,null,z.createElement(Ie,{...fe}),te!=="loading"&&z.createElement(Je,null,te==="error"?z.createElement(re,{...fe}):z.createElement(He,{...fe})))},We=N=>` 0% {transform: translate3d(0,${N*-200}%,0) scale(.6); opacity:.5;} 100% {transform: translate3d(0,0,0) scale(1); opacity:1;} `,ue=N=>` 0% {transform: translate3d(0,0,-1px) scale(1); opacity:1;} 100% {transform: translate3d(0,${N*-150}%,-1px) scale(.6); opacity:0;} `,_e="0%{opacity:0;} 100%{opacity:1;}",ye="0%{opacity:1;} 100%{opacity:0;}",It=(0,F.styled)("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; `,xr=(0,F.styled)("div")` display: flex; justify-content: center; margin: 4px 10px; color: inherit; flex: 1 1 auto; white-space: pre-line; `,tn=(N,U)=>{let te=N.includes("top")?1:-1,[fe,Se]=p()?[_e,ye]:[We(te),ue(te)];return{animation:U?`${(0,F.keyframes)(fe)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${(0,F.keyframes)(Se)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},rn=D.memo(({toast:N,position:U,style:te,children:fe})=>{let Se=N.height?tn(N.position||U||"top-center",N.visible):{opacity:0},Te=D.createElement(we,{toast:N}),Ue=D.createElement(xr,{...N.ariaProps},d(N.message,N));return D.createElement(It,{className:N.className,style:{...Se,...te,...N.style}},typeof fe=="function"?fe({icon:Te,message:Ue}):D.createElement(D.Fragment,null,Te,Ue))}),ri=ys(),Sr=u(I);(0,ri.setup)(Sr.createElement);var ho=({id:N,className:U,style:te,onHeightUpdate:fe,children:Se})=>{let Te=Sr.useCallback(Ue=>{if(Ue){let tt=()=>{let Yt=Ue.getBoundingClientRect().height;fe(N,Yt)};tt(),new MutationObserver(tt).observe(Ue,{subtree:!0,childList:!0,characterData:!0})}},[N,fe]);return Sr.createElement("div",{ref:Te,className:U,style:te},Se)},_n=(N,U)=>{let te=N.includes("top"),fe=te?{top:0}:{bottom:0},Se=N.includes("center")?{justifyContent:"center"}:N.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:p()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${U*(te?1:-1)}px)`,...fe,...Se}},bi=ri.css` z-index: 9999; > * { pointer-events: auto; } `,Hr=16,le=({reverseOrder:N,position:U="top-center",toastOptions:te,gutter:fe,children:Se,containerStyle:Te,containerClassName:Ue})=>{let{toasts:tt,handlers:Yt}=B(te);return Sr.createElement("div",{style:{position:"fixed",zIndex:9999,top:Hr,left:Hr,right:Hr,bottom:Hr,pointerEvents:"none",...Te},className:Ue,onMouseEnter:Yt.startPause,onMouseLeave:Yt.endPause},tt.map(Qt=>{let An=Qt.position||U,po=Yt.calculateOffset(Qt,{reverseOrder:N,gutter:fe,defaultPosition:U}),ha=_n(An,po);return Sr.createElement(ho,{id:Qt.id,key:Qt.id,onHeightUpdate:Yt.updateHeight,className:Qt.visible?bi:"",style:ha},Qt.type==="custom"?d(Qt.message,Qt):Se?Se(Qt):Sr.createElement(rn,{toast:Qt,position:An}))}))},Re=$;return gE}(function(e){var t,r=xe,n=av,i=as,a=Dn.default;r(e,"__esModule",{value:!0});var o={toast:!0};r(e,"toast",{enumerable:!0,get:function(){return s.default}});var s=a(G0e());n(t=i(s)).call(t,function(u){u==="default"||u==="__esModule"||Object.prototype.hasOwnProperty.call(o,u)||u in e&&e[u]===s[u]||r(e,u,{enumerable:!0,get:function(){return s[u]}})})})(tG);var rG=tG;const V0e=({children:e})=>P.jsxs(P.Fragment,{children:[P.jsx(rG.Toaster,{toastOptions:{className:"rw-toast",duration:6e3}}),e]}),Y0e=JW` mutation GetStripeCustomerPortalSessionUrlMutation { getStripeCustomerPortalSessionUrl } `,Q0e=({children:e})=>{const{loading:t,isAuthenticated:r,logIn:n,signUp:i,logOut:a}=tm(),[o,s]=I.useState(!1),[u]=Rc.useMutation(Y0e),l=d=>{d.preventDefault(),n({appState:{targetUrl:`/login-success?redirectTo=${encodeURIComponent(window.location.pathname+window.location.search)}`}})},c=d=>{d.preventDefault(),i({appState:{targetUrl:`/login-success?redirectTo=${encodeURIComponent(window.location.pathname+window.location.search)}`}})},f=async()=>{s(!0);const d=await u();console.log(d),window.location.href=d.data.getStripeCustomerPortalSessionUrl};return P.jsx(P.Fragment,{children:P.jsxs("div",{className:"min-h-full",children:[P.jsx("div",{className:"h-full min-w-full border border-b-gray-200 bg-white",children:P.jsx("header",{id:"main-header",className:"py-3",children:P.jsx("div",{className:"px-4 sm:px-6 lg:px-8",children:P.jsxs("div",{className:"flex items-center justify-between",children:[P.jsxs("div",{className:"flex items-center space-x-8",children:[P.jsxs("a",{href:"/",className:"inline-block text-xl font-bold tracking-tight text-gray-800 sm:text-2xl",children:[P.jsx("img",{src:"/logo_full_black.png",className:"mr-2 inline h-5",alt:"Landingsite"}),"Landingsite.ai"]}),P.jsx("a",{href:"/fine-tuning/playground",className:"inline-block",children:"Playground"}),P.jsx("a",{href:"/fine-tuning/examples",className:"inline-block",children:"Examples"})]}),!t&&!r&&P.jsxs("ul",{className:"flex items-center gap-x-8 text-sm text-black",children:[P.jsx("li",{children:P.jsx("a",{className:"hover:underline",href:"/login",onClick:l,children:"Log In"})}),P.jsx("li",{children:P.jsx("a",{className:"rounded bg-lime-400 px-4 py-2 text-sm hover:bg-lime-500",href:"/signup",onClick:c,children:"Sign Up"})})]}),!t&&r&&P.jsx(ou,{className:"relative flex",children:({open:d})=>P.jsxs(P.Fragment,{children:[P.jsxs(ou.Button,{className:` ${d?"":"text-opacity-90"} group inline-flex h-[32px] w-[50px] flex-grow items-center justify-center rounded-lg bg-lime-400 p-2 text-base font-medium text-gray-800 hover:bg-gray-700 hover:text-white focus:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-opacity-75`,children:[P.jsx("i",{className:"fa-solid fa-user mr-1"}),P.jsx("i",{className:"fa-regular fa-chevron-down"})]}),P.jsx(Y5,{as:I.Fragment,enter:"transition ease-out duration-200",enterFrom:"opacity-0 translate-y-1",enterTo:"opacity-100 translate-y-0",leave:"transition ease-in duration-150",leaveFrom:"opacity-100 translate-y-0",leaveTo:"opacity-0 translate-y-1",children:P.jsx(ou.Panel,{className:"absolute -left-3/4 z-[80] mt-10 w-[180px] -translate-x-1/2 transform px-4 sm:w-[140px] sm:px-0",children:P.jsxs("div",{className:"overflow-hidden rounded-lg shadow-lg ring-1 ring-black ring-opacity-5",children:[P.jsxs("a",{href:"/",className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",children:[P.jsx("span",{children:"Dashboard"}),P.jsx("i",{className:"fa-solid fa-user"})]}),P.jsxs("button",{className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",onClick:f,children:[P.jsx("span",{children:"Billing"}),!o&&P.jsx("i",{className:"fa-regular fa-credit-card"}),o&&P.jsx("i",{className:"fa-regular fa-spinner-third animate-spin"})]}),P.jsxs("button",{className:"flex w-full items-center justify-between bg-white px-4 py-2 text-sm font-medium text-gray-700 hover:bg-gray-200",onClick:()=>{a({returnTo:"https://www.landingsite.ai/"})},children:[P.jsx("span",{children:"Log Out"}),P.jsx("i",{className:"fa-solid fa-sign-out"})]})]})})})]})})]})})})}),P.jsx("main",{className:"h-full",children:e})]})})},_E=({title:e,titleTo:t,buttonLabel:r,buttonTo:n,children:i})=>P.jsxs("div",{className:"rw-scaffold",children:[P.jsx(rG.Toaster,{toastOptions:{className:"rw-toast",duration:6e3}}),P.jsxs("header",{className:"rw-header",children:[P.jsx("h1",{className:"rw-heading rw-heading-primary",children:P.jsx(ne.Link,{to:ne.routes[t](),className:"rw-link",children:e})}),P.jsxs(ne.Link,{to:ne.routes[n](),className:"rw-button rw-button-green",children:[P.jsx("div",{className:"rw-button-icon",children:"+"})," ",r]})]}),P.jsx("main",{className:"rw-main",children:i})]}),nq=({children:e})=>P.jsx(P.Fragment,{children:P.jsxs("div",{className:"h-screen",children:[P.jsx("div",{className:"min-w-full border border-b-gray-200 bg-white",children:P.jsx("header",{id:"main-header",className:"py-3",children:P.jsx("div",{className:"px-4 sm:px-6 lg:px-8",children:P.jsx("div",{className:"flex items-center justify-between",children:P.jsxs("div",{className:"flex items-center space-x-8",children:[P.jsxs("a",{href:"/",className:"inline-block text-xl font-bold tracking-tight text-gray-800 sm:text-2xl",children:[P.jsx("img",{src:"/logo_full_black.png",className:"mr-2 inline h-5",alt:"Landingsite"}),"Landingsite.ai"]}),P.jsx("a",{href:"/fine-tuning/playground",className:"inline-block",children:"Playground"}),P.jsx("a",{href:"/training-websites",className:"inline-block",children:"Training Websites"}),P.jsx("a",{href:"/template-editor",className:"inline-block",children:"Template Editor"})]})})})})}),P.jsx("main",{className:"h-full",children:e})]})}),iq={name:"BlogEditorPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./BlogEditorPage-f0379d80.js"),[]))},aq={name:"BlogPostEditorPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./BlogPostEditorPage-a3f5bcc2.js"),[]))},K0e={name:"ClaimPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./ClaimPage-18e840c2.js"),[]))};I.lazy(()=>be(()=>Promise.resolve().then(()=>Eme),void 0));const J0e={name:"FineTuningExamplesPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./FineTuningExamplesPage-19a38f2d.js"),["assets/FineTuningExamplesPage-19a38f2d.js","assets/index-ea6eb9da.js","assets/index-be8dd76f.js","assets/dialog-ed67a96f.js"]))},X0e={name:"FineTuningPlaygroundPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./FineTuningPlaygroundPage-4355f868.js"),["assets/FineTuningPlaygroundPage-4355f868.js","assets/index-be8dd76f.js"]))},Z0e={name:"HomePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./HomePage-85476ecd.js"),["assets/HomePage-85476ecd.js","assets/Navbar-3b4c7819.js","assets/IconBase-1b874abb.js","assets/index-a360cee5.js","assets/moment-1d5ea479.js","assets/dialog-ed67a96f.js"]))},eSe={name:"LoginPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./LoginPage-dba1d278.js"),[]))},tSe={name:"LoginSuccessPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./LoginSuccessPage-c55baaad.js"),[]))},rSe={name:"LogoutPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./LogoutPage-3b1d2bbb.js"),[]))},nSe={name:"NotFoundPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./NotFoundPage-d497cdb2.js"),[]))};I.lazy(()=>be(()=>import("./PlansPage-40117672.js"),[]));const iSe={name:"PurchaseSuccessPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./PurchaseSuccessPage-766af576.js"),["assets/PurchaseSuccessPage-766af576.js","assets/Navbar-3b4c7819.js"]))},aSe={name:"RecentSignupsPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./RecentSignupsPage-2caa6e1f.js"),[]))},oSe={name:"SignupPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./SignupPage-fa12ee2b.js"),[]))},sSe={name:"TemplateEditorPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateEditorPage-1ed8d7ec.js"),[]))},uSe={name:"TemplateEightBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateEightBuilderPage-04029d4f.js"),[]))},lSe={name:"TemplateFiveBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateFiveBuilderPage-21c329d3.js"),[]))},cSe={name:"TemplateFourBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateFourBuilderPage-7931bd44.js"),[]))},fSe={name:"TemplateNineBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateNineBuilderPage-a807ea55.js"),[]))},dSe={name:"TemplateOneBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateOneBuilderPage-b0eb8e8a.js"),[]))},hSe={name:"TemplateSectionEditPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateSectionEditPage-01b71927.js"),["assets/TemplateSectionEditPage-01b71927.js","assets/index-ea6eb9da.js","assets/index-be8dd76f.js"]))},pSe={name:"TemplateSectionsPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateSectionsPage-14f11f20.js"),["assets/TemplateSectionsPage-14f11f20.js","assets/index-be8dd76f.js"]))},vSe={name:"TemplateSevenBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateSevenBuilderPage-4707796d.js"),[]))},mSe={name:"TemplateSixBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateSixBuilderPage-67002558.js"),[]))},gSe={name:"TemplateTenBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateTenBuilderPage-b37220be.js"),[]))},_Se={name:"TemplateThreeBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateThreeBuilderPage-f4528e1f.js"),[]))},ySe={name:"TemplateTwoBuilderPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplateTwoBuilderPage-7e46c1fa.js"),[]))},SSe={name:"TrainingWebsitesEditPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TrainingWebsitesEditPage-ceb43b2e.js"),["assets/TrainingWebsitesEditPage-ceb43b2e.js","assets/index-ea6eb9da.js","assets/index-be8dd76f.js","assets/media-832c6fc0.js","assets/index-a360cee5.js"]))},bSe={name:"TrainingWebsitesNewTrainingWebsitePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TrainingWebsitesNewTrainingWebsitePage-ee763464.js"),[]))},ESe={name:"TrainingWebsitesPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TrainingWebsitesPage-06cdb668.js"),[]))},wSe={name:"UpgradePurchaseSuccessPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./UpgradePurchaseSuccessPage-8c0efbed.js"),["assets/UpgradePurchaseSuccessPage-8c0efbed.js","assets/Navbar-3b4c7819.js"]))},oq={name:"WebsiteChatPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./WebsiteChatPage-47a9dc2f.js"),["assets/WebsiteChatPage-47a9dc2f.js","assets/index-a360cee5.js","assets/Card-9b917153.js","assets/PageFrame-36d572c7.js","assets/media-832c6fc0.js","assets/index-be8dd76f.js","assets/initialContent-737ecfee.js","assets/fonts-7f133382.js","assets/IconBase-1b874abb.js","assets/loader-circle-58aeca90.js","assets/Navbar-3b4c7819.js","assets/listbox-703f80af.js","assets/dialog-ed67a96f.js","assets/index-118ebbaa.js","assets/index-c25849ee.js","assets/check-c60ecf02.js","assets/Alert-f4142988.js","assets/index-47aa28e8.js","assets/Input-7300d33a.js"]))},RSe={name:"WebsitePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./WebsitePage-ccffcbe3.js"),["assets/WebsitePage-ccffcbe3.js","assets/index-a360cee5.js","assets/PageFrame-36d572c7.js","assets/media-832c6fc0.js","assets/index-be8dd76f.js","assets/initialContent-737ecfee.js","assets/fonts-7f133382.js","assets/moment-1d5ea479.js","assets/listbox-703f80af.js","assets/dialog-ed67a96f.js","assets/WebsitePage-1092ba8d.css"]))},TSe={name:"WebsitePreviewPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./WebsitePreviewPage-693663fb.js"),["assets/WebsitePreviewPage-693663fb.js","assets/index-be8dd76f.js","assets/initialContent-737ecfee.js","assets/fonts-7f133382.js"]))},Rl={name:"WebsiteSettingsPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./WebsiteSettingsPage-74bcad9b.js"),["assets/WebsiteSettingsPage-74bcad9b.js","assets/index-e2b2e057.js","assets/moment-1d5ea479.js","assets/listbox-703f80af.js","assets/dialog-ed67a96f.js"]))},kSe={name:"DomainDomainAddPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainAddPage-31bdd2e6.js"),["assets/DomainAddPage-31bdd2e6.js","assets/index-e2b2e057.js","assets/Navbar-3b4c7819.js","assets/Alert-f4142988.js","assets/Card-9b917153.js","assets/Input-7300d33a.js","assets/check-c60ecf02.js","assets/loader-circle-58aeca90.js"]))},OSe={name:"DomainDomainConfirmDnsPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainConfirmDnsPage-b0e613bc.js"),["assets/DomainConfirmDnsPage-b0e613bc.js","assets/Navbar-3b4c7819.js","assets/DnsRecordManager-4096636d.js","assets/index-d5457cd0.js","assets/loader-circle-58aeca90.js","assets/Alert-f4142988.js","assets/Card-9b917153.js"]))},PSe={name:"DomainDomainPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainPage-c707ecf3.js"),["assets/DomainPage-c707ecf3.js","assets/Navbar-3b4c7819.js","assets/DnsRecordManager-4096636d.js","assets/index-d5457cd0.js","assets/loader-circle-58aeca90.js"]))},ISe={name:"DomainDomainSearchPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainSearchPage-78c5b509.js"),["assets/DomainSearchPage-78c5b509.js","assets/index-a360cee5.js","assets/Navbar-3b4c7819.js","assets/Card-9b917153.js","assets/Input-7300d33a.js","assets/index-118ebbaa.js","assets/index-c25849ee.js","assets/loader-circle-58aeca90.js","assets/external-link-c97afe48.js"]))},xSe={name:"DomainDomainVerifyNameserversPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainVerifyNameserversPage-8eace579.js"),["assets/DomainVerifyNameserversPage-8eace579.js","assets/Navbar-3b4c7819.js","assets/index-c25849ee.js","assets/index-47aa28e8.js","assets/loader-circle-58aeca90.js","assets/Card-9b917153.js","assets/Alert-f4142988.js","assets/external-link-c97afe48.js"]))},CSe={name:"DomainDomainsPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./DomainsPage-0326492f.js"),["assets/DomainsPage-0326492f.js","assets/Navbar-3b4c7819.js"]))},$Se={name:"AdminChatTemplateChatTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./ChatTemplatePage-74c661c1.js"),[]))},DSe={name:"AdminChatTemplateChatTemplatesPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./ChatTemplatesPage-74e4bce0.js"),["assets/ChatTemplatesPage-74e4bce0.js","assets/formatters-59f317ca.js"]))},NSe={name:"AdminChatTemplateEditChatTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./EditChatTemplatePage-f19c878a.js"),["assets/EditChatTemplatePage-f19c878a.js","assets/ChatTemplateForm-fa8a218c.js","assets/index-d5457cd0.js"]))},ASe={name:"AdminChatTemplateNewChatTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./NewChatTemplatePage-f72d0e3d.js"),["assets/NewChatTemplatePage-f72d0e3d.js","assets/ChatTemplateForm-fa8a218c.js","assets/index-d5457cd0.js"]))},LSe={name:"AdminChatTemplatePreviewChatTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./PreviewChatTemplatePage-a5b2010b.js"),["assets/PreviewChatTemplatePage-a5b2010b.js","assets/index-be8dd76f.js","assets/fonts-7f133382.js"]))},MSe={name:"AdminKVStorageEditKVStoragePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./EditKVStoragePage-83c40743.js"),["assets/EditKVStoragePage-83c40743.js","assets/KVStorageForm-e430d951.js","assets/index-d5457cd0.js"]))},FSe={name:"AdminKVStorageKVStoragePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./KVStoragePage-f066e8ee.js"),["assets/KVStoragePage-f066e8ee.js","assets/formatters-59f317ca.js"]))},jSe={name:"AdminKVStorageKVStoragesPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./KVStoragesPage-4e719678.js"),["assets/KVStoragesPage-4e719678.js","assets/formatters-59f317ca.js"]))},qSe={name:"AdminKVStorageNewKVStoragePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./NewKVStoragePage-ac50f315.js"),["assets/NewKVStoragePage-ac50f315.js","assets/KVStorageForm-e430d951.js","assets/index-d5457cd0.js"]))},USe={name:"AdminTemplateEditTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./EditTemplatePage-7242445d.js"),["assets/EditTemplatePage-7242445d.js","assets/TemplateForm-bbe1f30e.js","assets/index-d5457cd0.js"]))},BSe={name:"AdminTemplateNewTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./NewTemplatePage-36e35472.js"),["assets/NewTemplatePage-36e35472.js","assets/TemplateForm-bbe1f30e.js","assets/index-d5457cd0.js"]))},zSe={name:"AdminTemplateTemplatePage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplatePage-0a94daee.js"),["assets/TemplatePage-0a94daee.js","assets/formatters-59f317ca.js"]))},HSe={name:"AdminTemplateTemplatesPage",prerenderLoader:e=>({default:globalThis.__REDWOOD__PRERENDER_PAGES[e]}),LazyComponent:I.lazy(()=>be(()=>import("./TemplatesPage-04a54678.js"),["assets/TemplatesPage-04a54678.js","assets/formatters-59f317ca.js"]))},WSe=()=>P.jsxs(ne.Router,{useAuth:tm,children:[P.jsx(ne.PrivateSet,{unauthenticated:"login",roles:"admin",children:P.jsxs(ne.Set,{wrap:_E,title:"KvStorages",titleTo:"adminKvStorages",buttonLabel:"New KvStorage",buttonTo:"adminNewKvStorage",children:[P.jsx(ne.Route,{path:"/admin/kv-storages/new",page:qSe,name:"adminNewKvStorage"}),P.jsx(ne.Route,{path:"/admin/kv-storages/{id}/edit",page:MSe,name:"adminEditKvStorage"}),P.jsx(ne.Route,{path:"/admin/kv-storages/{id}",page:FSe,name:"adminKvStorage"}),P.jsx(ne.Route,{path:"/admin/kv-storages",page:jSe,name:"adminKvStorages"})]})}),P.jsx(ne.PrivateSet,{unauthenticated:"login",roles:"admin",children:P.jsxs(ne.Set,{wrap:_E,title:"Templates",titleTo:"adminTemplates",buttonLabel:"New Template",buttonTo:"adminNewTemplate",children:[P.jsx(ne.Route,{path:"/admin/templates/new",page:BSe,name:"adminNewTemplate"}),P.jsx(ne.Route,{path:"/admin/templates/{id}/edit",page:USe,name:"adminEditTemplate"}),P.jsx(ne.Route,{path:"/admin/templates/{id}",page:zSe,name:"adminTemplate"}),P.jsx(ne.Route,{path:"/admin/templates",page:HSe,name:"adminTemplates"})]})}),P.jsxs(ne.PrivateSet,{unauthenticated:"login",roles:"admin",children:[P.jsxs(ne.Set,{wrap:_E,title:"ChatTemplates",titleTo:"adminChatTemplates",buttonLabel:"New Chat Template",buttonTo:"adminNewChatTemplate",children:[P.jsx(ne.Route,{path:"/admin/chat/templates/new",page:ASe,name:"adminNewChatTemplate"}),P.jsx(ne.Route,{path:"/admin/chat/templates/{id}/edit",page:NSe,name:"adminEditChatTemplate"}),P.jsx(ne.Route,{path:"/admin/chat/templates/{id}",page:$Se,name:"adminChatTemplate"}),P.jsx(ne.Route,{path:"/admin/chat/templates",page:DSe,name:"adminChatTemplates"})]}),P.jsx(ne.Route,{path:"/admin/chat/templates/{id}/preview",page:LSe,name:"adminPreviewChatTemplate"})]}),P.jsx(ne.PrivateSet,{unauthenticated:"login",roles:"admin",children:P.jsxs(ne.Set,{wrap:Q0e,children:[P.jsx(ne.Route,{path:"/fine-tuning/playground",page:X0e,name:"fineTuningPlayground"}),P.jsx(ne.Route,{path:"/fine-tuning/examples",page:J0e,name:"fineTuningExamples"})]})}),P.jsx(ne.PrivateSet,{unauthenticated:"login",roles:["admin","training"],children:P.jsxs(ne.Set,{wrap:nq,children:[P.jsx(ne.Route,{path:"/training-websites/new",page:bSe,name:"newTrainingWebsite"}),P.jsx(ne.Route,{path:"/training-websites/{id}",page:SSe,name:"editTrainingWebsite"}),P.jsx(ne.Route,{path:"/training-websites",page:ESe,name:"trainingWebsites"}),P.jsx(ne.Route,{path:"/template-editor",page:sSe,name:"templateEditor"}),P.jsx(ne.Route,{path:"/template-sections",page:pSe,name:"templateSections"}),P.jsx(ne.Route,{path:"/template-sections/{id}/edit",page:hSe,name:"editTemplateSection"})]})}),P.jsx(ne.PrivateSet,{unauthenticated:"login",roles:"admin",children:P.jsx(ne.Set,{wrap:nq,children:P.jsx(ne.Route,{path:"/admin/recent-signups",page:aSe,name:"recentSignups"})})}),P.jsx(ne.Set,{children:P.jsxs(ne.Set,{wrap:V0e,children:[P.jsx(ne.Route,{path:"/website-chat/{id}",page:oq,name:"websiteChat"}),P.jsx(ne.Route,{path:"/website-chat/{id}/{panel}",page:oq,name:"websiteChatPanel"}),P.jsx(ne.Route,{path:"/domains",page:CSe,name:"domains"}),P.jsx(ne.Route,{path:"/domains/add",page:kSe,name:"domainAdd"}),P.jsx(ne.Route,{path:"/domains/{id}/confirm-dns",page:OSe,name:"domainConfirmDns"}),P.jsx(ne.Route,{path:"/domains/{id}/verify-nameservers",page:xSe,name:"domainVerifyNameservers"}),P.jsx(ne.Route,{path:"/domains/search",page:ISe,name:"domainSearch"}),P.jsx(ne.Route,{path:"/domains/{id}",page:PSe,name:"domain"}),P.jsx(ne.Route,{path:"/purchase-success",page:iSe,name:"purchaseSuccess"}),P.jsx(ne.Route,{path:"/upgrade-purchase-success",page:wSe,name:"upgradePurchaseSuccess"})]})}),P.jsx(ne.PrivateSet,{unauthenticated:"login",children:P.jsx(ne.Set,{children:P.jsx(ne.Route,{path:"/",page:Z0e,name:"home"})})}),P.jsxs(ne.Set,{wrap:W0e,children:[P.jsx(ne.Route,{path:"/website/{id}",page:RSe,name:"website"}),P.jsx(ne.Route,{path:"/website/{id}/settings",page:Rl,name:"websiteSettings"}),P.jsx(ne.Route,{path:"/website/{id}/plans",page:Rl,name:"websitePlansSettings"}),P.jsx(ne.Route,{path:"/website/{id}/custom-domain",page:Rl,name:"websiteCustomDomainSettings"}),P.jsx(ne.Route,{path:"/website/{id}/waitlist",page:Rl,name:"websiteWaitlistSettings"}),P.jsx(ne.Route,{path:"/website/{id}/delete-website",page:Rl,name:"websiteDeleteWebsiteSettings"}),P.jsx(ne.Route,{path:"/website/{id}/blog-editor",page:iq,name:"blogEditor"}),P.jsx(ne.Route,{path:"/website/{id}/blog-editor/topics",page:iq,name:"blogEditorTopics"}),P.jsx(ne.Route,{path:"/website/{id}/blog-post-editor/new",page:aq,name:"blogPostEditor"}),P.jsx(ne.Route,{path:"/website/{id}/blog-post-editor/{blogPostId}",page:aq,name:"blogPostEditorNew"})]}),P.jsx(ne.Route,{path:"/template-builder/1",page:dSe,name:"templateOneBuilder"}),P.jsx(ne.Route,{path:"/template-builder/2",page:ySe,name:"templateTwoBuilder"}),P.jsx(ne.Route,{path:"/template-builder/3",page:_Se,name:"templateThreeBuilder"}),P.jsx(ne.Route,{path:"/template-builder/4",page:cSe,name:"templateFourBuilder"}),P.jsx(ne.Route,{path:"/template-builder/5",page:lSe,name:"templateFiveBuilder"}),P.jsx(ne.Route,{path:"/template-builder/6",page:mSe,name:"templateSixBuilder"}),P.jsx(ne.Route,{path:"/template-builder/7",page:vSe,name:"templateSevenBuilder"}),P.jsx(ne.Route,{path:"/template-builder/8",page:uSe,name:"templateEightBuilder"}),P.jsx(ne.Route,{path:"/template-builder/9",page:fSe,name:"templateNineBuilder"}),P.jsx(ne.Route,{path:"/template-builder/10",page:gSe,name:"templateTenBuilder"}),P.jsx(ne.Route,{path:"/website-preview",page:TSe,name:"websitePreview"}),P.jsx(ne.Route,{path:"/login-success",page:tSe,name:"loginSuccess"}),P.jsx(ne.Route,{path:"/logout",page:rSe,name:"logout"}),P.jsx(ne.Route,{path:"/signup",page:oSe,name:"signup"}),P.jsx(ne.Route,{path:"/login",page:eSe,name:"login"}),P.jsx(ne.Route,{path:"/claim",page:K0e,name:"claim"}),P.jsx(ne.Route,{notfound:!0,page:nSe})]});hJ({dsn:"https://4d4ccc012635e517019ecffe578a424e@o4505134687977472.ingest.sentry.io/4506230476177408",integrations:[new t6({tracePropagationTargets:["localhost",/^https:\/\/landingsite\.ai\//]}),new Kp],tracesSampleRate:.2,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1});const GSe={session_recording:{maskAllInputs:!1,maskInputOptions:{password:!0}}},sq=()=>P.jsx(zX,{apiKey:"phc_IS9NHfACBg6Ul9wpMrfnfiBB7DvwFUYn6VPfgoiLi2c",options:GSe,children:P.jsx(Rc.FatalErrorBoundary,{page:g5,children:P.jsx(Rc.RedwoodProvider,{titleTemplate:"%PageTitle | %AppTitle",children:P.jsx(z0e,{children:P.jsx(bme.RedwoodApolloProvider,{useAuth:tm,children:P.jsx(WSe,{})})})})})}),yE=document.getElementById("redwood-app");var uq;((uq=yE.children)==null?void 0:uq.length)>0?RB(yE,P.jsx(sq,{})):TB(yE).render(P.jsx(sq,{}));export{x as $,au as A,YSe as B,lf as C,fo as D,Lye as E,Cu as F,Yv as G,Lr as H,Ao as I,Pye as J,Pa as K,da as L,q5 as M,up as N,XSe as O,ou as P,o1 as Q,qe as R,tbe as S,xye as T,U5 as U,Hj as V,Iye as W,Kn as X,Oye as Y,rG as Z,QSe as _,ne as a,Zr as a0,Dt as a1,L5 as a2,s1 as a3,dt as a4,xe as a5,Dn as a6,as as a7,av as a8,d_e as a9,Ov as aa,ppe as b,vpe as c,Rc as d,$u as e,wB as f,JW as g,B5 as h,ir as i,P as j,Ai as k,a1 as l,YR as m,l1 as n,Pt as o,A5 as p,lp as q,I as r,Mi as s,Y5 as t,tm as u,wye as v,z5 as w,Ya as x,io as y,no as z}; //# sourceMappingURL=index-7f127a2e.js.map