* `);returnh.length=0,n===!1?(qt(d),s):d}}returns}function_n(t,e){varn=Object.defineProperties(e,{_vueTypes_name:{value:t,writable:!0},isRequired:{get:function(){returnthis.required=!0,this}},def:{value:function(s){returns!==void0||this.default?Ss(s)||Li(this,s,!0)===!0?(this.default=Es(s)?function(){return[].concat(s)}:ki(s)?function(){returnObject.assign({},s)}:s,this):(qt(this._vueTypes_name+' - invalid default value: "'+s+'"'),this):this}}}),r=n.validator;returnSs(r)&&(n.validator=jh(r,n)),n}functiontr(t,e){varn=_n(t,e);returnObject.defineProperty(n,"validate",{value:function(r){returnSs(this.validator)&&qt(this._vueTypes_name+` - calling .validate() will overwrite the current custom validator function. Validator info:
`+JSON.stringify(this)),this.validator=jh(r,this),this}})}functionPm(t,e,n){varr,s,o=(r=e,s={},Object.getOwnPropertyNames(r).forEach(function(g){s[g]=Object.getOwnPropertyDescriptor(r,g)}),Object.defineProperties({},s));if(o._vueTypes_name=t,!ki(n))returno;varl,c,f=n.validator,h=A_(n,["validator"]);if(Ss(f)){vard=o.validator;d&&(d=(c=(l=d).__original)!==null&&c!==void0?c:l),o.validator=jh(d?function(g){returnd.call(this,g)&&f.call(this,g)}:f,o)}returnObject.assign(o,h)}functionsu(t){returnt.replace(/^(?!\s*$)/gm," ")}varjR=function(){returntr("any",{})},NR=function(){returntr("function",{type:Function})},DR=function(){returntr("boolean",{type:Boolean})},FR=function(){returntr("string",{type:String})},UR=function(){returntr("number",{type:Number})},BR=function(){returntr("array",{type:Array})},HR=function(){returntr("object",{type:Object})},WR=function(){return_n("integer",{type:Number,validator:function(t){returnMR(t)}})},qR=function(){return_n("symbol",{validator:function(t){returntypeoft=="symbol"}})};functionKR(t,e){if(e===void0&&(e="custom validation failed"),typeoft!="function")thrownewTypeError("[VueTypes error]: You must provide a function as argument");return_n(t.name||"<<anonymous function>>",{validator:function(n){varr=t(n);returnr||qt(this._vueTypes_name+" - "+e),r}})}functionzR(t){if(!Es(t))thrownewTypeError("[VueTypes error]: You must provide an array as argument.");vare='oneOf - value should be one of "'+t.join('", "')+'".',n=t.reduce(function(r,s){if(s!=null){varo=s.constructor;r.indexOf(o)===-1&&r.push(o)}returnr},[]);return_n("oneOf",{type:n.length>0?n:void0,validator:function(r){vars=t.indexOf(r)!==-1;returns||qt(e),s}})}functionVR(t){if(!Es(t))thrownewTypeError("[VueTypes error]: You must provide an array as argument");for(vare=!1,n=[],r=0;r<t.length;r+=1){vars=t[r];if(I_(s)){if(Rl(s)&&s._vueTypes_name==="oneOf"){n=n.concat(s.type);continue}if(Ss(s.validator)&&(e=!0),s.type!==!0&&s.type){n=n.concat(s.type);continue}}n.push(s)}returnn=n.filter(function(o,l){returnn.indexOf(o)===l}),_n("oneOfType",e?{type:n,validator:function(o){varl=[],c=t.some(function(f){varh=Li(Rl(f)&&f._vueTypes_name==="oneOf"?f.type||null:f,o,!0);returntypeofh=="string"&&l.push(h),h===!0});returnc||qt("oneOfType - provided value does not match any of the "+l.length+` passed-in validators:
`+su(l.join(`
`))),c}}:{type:n})}functionGR(t){return_n("arrayOf",{type:Array,validator:function(e){varn,r=e.every(function(s){return(n=Li(t,s,!0))===!0});returnr||qt(`arrayOf - value validation error:
`+su(n)),r}})}functionJR(t){return_n("instanceOf",{type:t})}functionYR(t){return_n("objectOf",{type:Object,validator:function(e){varn,r=Object.keys(e).every(function(s){return(n=Li(t,e[s],!0))===!0});returnr||qt(`objectOf - value validation error:
`+su(n)),r}})}functionQR(t){vare=Object.keys(t),n=e.filter(function(s){varo;return!!(!((o=t[s])===null||o===void0)&&o.required)}),r=_n("shape",{type:Object,validator:function(s){varo=this;if(!ki(s))return!1;varl=Object.keys(s);if(n.length>0&&n.some(function(f){returnl.indexOf(f)===-1})){varc=n.filter(function(f){returnl.indexOf(f)===-1});returnqt(c.length===1?'shape - required property "'+c[0]+'" is not defined.':'shape - required properties "'+c.join('", "')+'" are not defined.'),!1}returnl.every(function(f){if(e.indexOf(f)===-1)returno._vueTypes_isLoose===!0||(qt('shape - shape definition does not include a "'+f+'" property. Allowed keys: "'+e.join('", "')+'".'),!1);varh=Li(t[f],s[f],!0);returntypeofh=="string"&&qt('shape - "'+f+`" property validation error:
`+su(h)),h===!0})}});returnObject.defineProperty(r,"_vueTypes_isLoose",{writable:!0,value:!1}),Object.defineProperty(r,"loose",{get:function(){returnthis._vueTypes_isLoose=!0,this}}),r}varJn=function(){functiont(){}returnt.extend=function(e){varn=this;if(Es(e))returne.forEach(function(g){returnn.extend(g)}),this;varr=e.name,s=e.validate,o=s!==void0&&s,l=e.getter,c=l!==void0&&l,f=A_(e,["name","validate","getter"]);if(Do(this,r))thrownewTypeError('[VueTypes error]: Type "'+r+'" already defined');varh,d=f.type;returnRl(d)?(deletef.type,Object.defineProperty(this,r,c?{get:function(){returnPm(r,d,f)}}:{value:function(){varg,m=Pm(r,d,f);returnm.validator&&(m.validator=(g=m.validator).bind.apply(g,[m].concat([].slice.call(arguments)))),m}})):(h=c?{get:function(){varg=Object.assign({},f);returno?tr(r,g):_n(r,g)},enumerable:!0}:{value:function(){varg,m,y=Object.assign({},f);returng=o?tr(r,y):_n(r,y),y.validator&&(g.validator=(m=y.validator).bind.apply(m,[g].concat([].slice.call(arguments)))),g},enumerable:!0},Object.defineProperty(this,r,h))},O_(t,null,[{key:"any",get:function(){returnjR()}},{key:"func",get:function(){returnNR().def(this.defaults.func)}},{key:"bool",get:function(){returnDR().def(this.defaults.bool)}},{key:"string",get:function(){returnFR().def(this.defaults.string)}},{key:"number",get:function(){returnUR().def(this.defaults.number)}},{key:"array",get:function(){returnBR().def(this.defaults.array)}},{key:"object",get:function(){returnHR().def(this.defaults.object)}},{key:"integer",get:function(){returnWR().def(this.defaults.integer)}},{key:"symbol",get:function(){returnqR()}}]),t}();function$_(t){vare;returnt===void0&&(t={func:function(){},bool:!0,string:"",number:0,array:function(){return[]},object:function(){return{}},integer:0}),(e=function(n){functionr(){returnn.apply(this,arguments)||this}returnT_(r,n),O_(r,null,[{key:"sensibleDefaults",get:function(){returnul({},this.defaults)},set:function(s){this.defaults=s!==!1?ul({},s!==!0?s:t):{}}}]),r}(Jn)).defaults=ul({},t),e}Jn.defaults={},Jn.custom=KR,Jn.oneOf=zR,Jn.instanceOf=JR,Jn.oneOfType=VR,Jn.arrayOf=GR,Jn.objectOf=YR,Jn.shape=QR,Jn.utils={validate:function(t,e){returnLi(e,t,!0)===!0},toType:function(t,e,n){returnn===void0&&(n=!1),n?tr(t,e):_n(t,e)}};(function(t){functione(){returnt.apply(this,arguments)||this}returnT_(e,t),e})($_());varL_=$_({func:void0,bool:void0,string:void0,number:void0,array:void0,object:void0,integer:void0});L_.extend([{name:"looseBool",getter:!0,type:Boolean,default:void0},{name:"style",getter:!0,type:[String,Object],default:void0},{name:"VueNode",getter:!0,type:null}]);constRm=L_;varXR=["image","description","imageStyle","class"],M_=ee(kR,null,null),j_=ee(IR,null,null),Is=function(e,n){varr,s=n.slots,o=s===void0?{}:s,l=n.attrs,c=ou("empty",e),f=c.direction,h=c.prefixCls,d=h.value,g=Ie(Ie({},e),l),m=g.image,y=m===void0?M_:m,w=g.description,x=w===void0?((r=o.description)===null||r===void0?void0:r.call(o))||void0:w,k=g.imageStyle,O=g.class,E=O===void0?"":O,R=w_(g,XR);returnee(S_,{componentName:"Empty",children:function(j){varU,F=typeofx<"u"?x:j.description,M=typeofF=="string"?F:"empty",W=null;returntypeofy=="string"?W=ee("img",{alt:M,src:y},null):W=y,ee("div",Ie({class:Go(d,E,(U={},xr(U,"".concat(d,"-normal"),y===j_),xr(U,"".concat(d,"-rtl"),f.value==="rtl"),U))},R),[ee("div",{class:"".concat(d,"-image"),style:k},[W]),F&&ee("p",{class:"".concat(d,"-description")},[F]),o.default&&ee("div",{class:"".concat(d,"-footer")},[Mh(o.default())])])}},null)};Is.displayName="AEmpty";Is.PRESENTED_IMAGE_DEFAULT=M_;Is.PRESENTED_IMAGE_SIMPLE=j_;Is.inheritAttrs=!1;Is.props={prefixCls:String,image:Rm.any,description:Rm.any,imageStyle:{type:Object,default:void0}};constno=b_(Is);varZR=function(e){varn=ou("empty",e),r=n.prefixCls,s=function(l){switch(l){case"Table":case"List":returnee(no,{image:no.PRESENTED_IMAGE_SIMPLE},null);case"Select":case"TreeSelect":case"Cascader":case"Transfer":case"Mentions":returnee(no,{image:no.PRESENTED_IMAGE_SIMPLE,class:"".concat(r.value,"-small")},n
`),"".concat(oI,"-dynamic-theme")):sI(!1,"ConfigProvider","SSR do not support dynamic theme with css variables.")}varhy=Symbol("GlobalFormContextKey"),lI=function(e){Ti(hy,e)},I3=function(){returnNt(hy,{validateMessages:Me(function(){})})},uI=function(){return{getTargetContainer:{type:Function},getPopupContainer:{type:Function},prefixCls:String,getPrefixCls:{type:Function},renderEmpty:{type:Function},transformCellText:{type:Function},csp:{type:Object,default:void0},input:{type:Object},autoInsertSpaceInButton:{type:Boolean,default:void0},locale:{type:Object,default:void0},pageHeader:{type:Object},componentSize:{type:String},direction:{type:String},space:{type:Object},virtual:{type:Boolean,default:void0},dropdownMatchSelectWidth:{type:[Number,Boolean],default:!0},form:{type:Object,default:void0},notUpdateGlobalConfig:Boolean}},cI="ant";functionms(){returngn.prefixCls||cI}varUf=rn({}),dy=rn({}),gn=rn({});Zl(function(){Ri(gn,Uf,dy),gn.prefixCls=ms(),gn.getPrefixCls=function(t,e){returne||(t?"".concat(gn.prefixCls,"-").concat(t):gn.prefixCls)},gn.getRootPrefixCls=function(t,e){returnt||(gn.prefixCls?gn.prefixCls:e&&e.includes("-")?e.replace(/^(.*)-[^-]*$/,"$1"):ms())}});varGc,fI=function(e){Gc&&Gc(),Gc=Zl(function(){Ri(dy,rn(e)),Ri(gn,rn(e))}),e.theme&&aI(ms(),e.theme)},hI=function(){return{getPrefixCls:function(n,r){returnr||(n?"".concat(ms(),"-").concat(n):ms())},getRootPrefixCls:function(n,r){returnn||(gn.prefixCls?gn.prefixCls:r&&r.includes("-")?r.replace(/^(.*)-[^-]*$/,"$1"):ms())}}},wo=qn({compatConfig:{MODE:3},name:"AConfigProvider",inheritAttrs:!1,props:uI(),setup:function(e,n){varr=n.slots,s=function(g,m){vary=e.prefixCls,w=y===void0?"ant":y;returnm||(g?"".concat(w,"-").concat(g):w)},o=function(g){varm=e.renderEmpty||r.renderEmpty||N_;returnm(g)},l=function(g,m){vary=e.prefixCls;if(m)returnm;varw=y||s("");returng?"".concat(w,"-").concat(g):w},c=rn(Ie(Ie({},e),{},{getPrefixCls:l,renderEmpty:o}));Object.keys(e).forEach(function(d){kn(function(){returne[d]},function(){c[d]=e[d]})}),e.notUpdateGlobalConfig||(Ri(Uf,c),kn(c,function(){Ri(Uf,c)}));varf=Me(function(){vard={};if(e.locale){varg,m;d=((g=e.locale.Form)===null||g===void0?void0:g.defaultValidateMessages)||((m=Pl.Form)===null||m===void0?void0:m.defaultValidateMessages)||{}}returne.form&&e.form.validateMessages&&(d=Ie(Ie({},d),e.form.validateMessages)),d});lI({validateMessages:f}),Ti("configProvider",c);varh=function(g){varm;returnee(rk,{locale:e.locale||g,ANT_MARK__:Rf},{default:function(){return[(m=r.default)===null||m===void0?void0:m.call(r)]}})};returnZl(function(){e.direction&&(hl.config({rtl:e.direction==="rtl"}),tI.config({rtl:e.direction==="rtl"}))}),function(){returnee(S_,{children:function(g,m,y){returnh(y)}},null)}}}),dI=rn({getPrefixCls:function(e,n){returnn||(e?"ant-".concat(e):"ant")},renderEmpty:N_,direction:"ltr"});wo.config=fI;wo.install=function(t){t.component(wo.name,wo)};constpy=wo,ou=function(t,e){varn=Nt("configProvider",dI),r=Me(function(){returnn.getPrefixCls(t,e.prefixCls)}),s=Me(function(){varE;return(E=e.direction)!==null&&E!==void0?E:n.direction}),o=Me(function(){returnn.getPrefixCls()}),l=Me(function(){returnn.autoInsertSpaceInButton}),c=Me(function(){returnn.renderEmpty}),f=Me(function(){returnn.space}),h=Me(function(){returnn.pageHeader}),d=Me(function(){returnn.form}),g=Me(function(){returne.getTargetContainer||n.getTargetContainer}),m=Me(function(){returne.getPopupContainer||n.getPopupContainer}),y=Me(function(){varE;return(E=e.dropdownMatchSelectWidth)!==null&&E!==void0?E:n.dropdownMatchSelectWidth}),w=Me(function(){return(e.virtual===void0?n.virtual!==!1:e.virtual!==!1)&&y.value!==!1}),x=Me(function(){returne.size||n.componentSize}),k=Me(function(){varE;returne.autocomplete||((E=n.input)===null||E===void0?void0:E.autocomplete)}),O=Me(function(){returnn.csp});return{configProvider:n,prefixCls:r,direction:s,size:x,getTargetContainer:g,getPopupContainer:m,space:f,pageHeader:h,form:d,autoInsertSpaceInButton:l,renderEmpty:c,virtual:w,dropdownMatchSelectWidth:y,rootPrefi
*vue-routerv4.2.2
*(c)2023EduardoSanMartinMorote
*@licenseMIT
*/const as=typeof window<"u";function pI(t){return t.__esModule||t[Symbol.toStringTag]==="Module"}const Ze=Object.assign;function Jc(t,e){const n={};for(const r in e){const s=e[r];n[r]=Wn(s)?s.map(t):t(s)}return n}const Eo=()=>{},Wn=Array.isArray,gI=/\/$/,mI=t=>t.replace(gI,"");functionYc(t,e,n="/"){letr,s={},o="",l="";constc=e.indexOf("#");letf=e.indexOf("?");returnc<f&&c>=0&&(f=-1),f>-1&&(r=e.slice(0,f),o=e.slice(f+1,c>-1?c:e.length),s=t(o)),c>-1&&(r=r||e.slice(0,c),l=e.slice(c,e.length)),r=bI(r??e,n),{fullPath:r+(o&&"?")+o+l,path:r,query:s,hash:l}}functionvI(t,e){constn=e.query?t(e.query):"";returne.path+(n&&"?")+n+(e.hash||"")}functionsv(t,e){return!e||!t.toLowerCase().startsWith(e.toLowerCase())?t:t.slice(e.length)||"/"}function_I(t,e,n){constr=e.matched.length-1,s=n.matched.length-1;returnr>-1&&r===s&&Cs(e.matched[r],n.matched[s])&&gy(e.params,n.params)&&t(e.query)===t(n.query)&&e.hash===n.hash}functionCs(t,e){return(t.aliasOf||t)===(e.aliasOf||e)}functiongy(t,e){if(Object.keys(t).length!==Object.keys(e).length)return!1;for(constnint)if(!yI(t[n],e[n]))return!1;return!0}functionyI(t,e){returnWn(t)?ov(t,e):Wn(e)?ov(e,t):t===e}functionov(t,e){returnWn(e)?t.length===e.length&&t.every((n,r)=>n===e[r]):t.length===1&&t[0]===e}functionbI(t,e){if(t.startsWith("/"))returnt;if(!t)returne;constn=e.split("/"),r=t.split("/"),s=r[r.length-1];(s===".."||s===".")&&r.push("");leto=n.length-1,l,c;for(l=0;l<r.length;l++)if(c=r[l],c!==".")if(c==="..")o>1&&o--;elsebreak;returnn.slice(0,o).join("/")+"/"+r.slice(l-(l===r.length?1:0)).join("/")}varBo;(function(t){t.pop="pop",t.push="push"})(Bo||(Bo={}));varSo;(function(t){t.back="back",t.forward="forward",t.unknown=""})(So||(So={}));functionwI(t){if(!t)if(as){conste=document.querySelector("base");t=e&&e.getAttribute("href")||"/",t=t.replace(/^\w+:\/\/[^\/]+/,"")}elset="/";returnt[0]!=="/"&&t[0]!=="#"&&(t="/"+t),mI(t)}constEI=/^[^#]+#/;functionSI(t,e){returnt.replace(EI,"#")+e}functionCI(t,e){constn=document.documentElement.getBoundingClientRect(),r=t.getBoundingClientRect();return{behavior:e.behavior,left:r.left-n.left-(e.left||0),top:r.top-n.top-(e.top||0)}}constau=()=>({left:window.pageXOffset,top:window.pageYOffset});functionxI(t){lete;if("el"int){constn=t.el,r=typeofn=="string"&&n.startsWith("#"),s=typeofn=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!s)return;e=CI(s,t)}elsee=t;"scrollBehavior"indocument.documentElement.style?window.scrollTo(e):window.scrollTo(e.left!=null?e.left:window.pageXOffset,e.top!=null?e.top:window.pageYOffset)}functionav(t,e){return(history.state?history.state.position-e:-1)+t}constBf=newMap;functionOI(t,e){Bf.set(t,e)}functionTI(t){conste=Bf.get(t);returnBf.delete(t),e}letAI=()=>location.protocol+"//"+location.host;functionmy(t,e){const{pathname:n,search:r,hash:s}=e,o=t.indexOf("#");if(o>-1){letc=s.includes(t.slice(o))?t.slice(o).length:1,f=s.slice(c);returnf[0]!=="/"&&(f="/"+f),sv(f,"")}returnsv(n,t)+r+s}functionPI(t,e,n,r){lets=[],o=[],l=null;constc=({state:m})=>{consty=my(t,location),w=n.value,x=e.value;letk=0;if(m){if(n.value=y,e.value=m,l&&l===w){l=null;return}k=x?m.position-x.position:0}elser(y);s.forEach(O=>{O(n.value,w,{delta:k,type:Bo.pop,direction:k?k>0?So.forward:So.back:So.unknown})})};functionf(){l=n.value}functionh(m){s.push(m);consty=()=>{constw=s.indexOf(m);w>-1&&s.splice(w,1)};returno.push(y),y}functiond(){const{history:m}=window;m.state&&m.replaceState(Ze({},m.state,{scroll:au()}),"")}functiong(){for(constmofo)m();o=[],window.removeEventListener("popstate",c),window.removeEventListener("beforeunload",d)}returnwindow.addEventListener("popstate",c),window.addEventListener("beforeunload",d,{passive:!0}),{pauseListeners:f,listen:h,destroy:g}}functionlv(t,e,n,r=!1,s=!1){return{back:t,current:e,forward:n,replaced:r,position:window.history.length,scroll:s?au():null}}functionRI(t){const{history:e,location:n}=window,r={value:my(t,n)},s={value:e.state};s.value||o(r.value,{back:null,current:r.value,forward:null,position:e.length-1,replace
\r=`.split(""),lM=(()=>{constt=newArray(128);for(lete=0;e<t.length;e+=1)t[e]=-1;for(lete=0;e<Hv.length;e+=1)t[Hv[e].charCodeAt(0)]=-2;for(lete=0;e<Ml.length;e+=1)t[Ml[e].charCodeAt(0)]=e;returnt})();functionWv(t,e,n){if(t!==null)for(e.queue=e.queue<<8|t,e.queuedBits+=8;e.queuedBits>=6;){constr=e.queue>>e.queuedBits-6&63;n(Ml[r]),e.queuedBits-=6}elseif(e.queuedBits>0)for(e.queue=e.queue<<6-e.queuedBits,e.queuedBits=6;e.queuedBits>=6;){constr=e.queue>>e.queuedBits-6&63;n(Ml[r]),e.queuedBits-=6}}functionmb(t,e,n){constr=lM[t];if(r>-1)for(e.queue=e.queue<<6|r,e.queuedBits+=6;e.queuedBits>=8;)n(e.queue>>e.queuedBits-8&255),e.queuedBits-=8;else{if(r===-2)return;thrownewError(`Invalid Base64-URL character "${String.fromCharCode(t)}"`)}}functionqv(t){conste=[],n=l=>{e.push(String.fromCodePoint(l))},r={utf8seq:0,codepoint:0},s={queue:0,queuedBits:0},o=l=>{fM(l,r,n)};for(letl=0;l<t.length;l+=1)mb(t.charCodeAt(l),s,o);returne.join("")}functionuM(t,e){if(t<=127){e(t);return}elseif(t<=2047){e(192|t>>6),e(128|t&63);return}elseif(t<=65535){e(224|t>>12),e(128|t>>6&63),e(128|t&63);return}elseif(t<=1114111){e(240|t>>18),e(128|t>>12&63),e(128|t>>6&63),e(128|t&63);return}thrownewError(`Unrecognized Unicode codepoint: ${t.toString(16)}`)}functioncM(t,e){for(letn=0;n<t.length;n+=1){letr=t.charCodeAt(n);if(r>55295&&r<=56319){consts=(r-55296)*1024&65535;r=(t.charCodeAt(n+1)-56320&65535|s)+65536,n+=1}uM(r,e)}}functionfM(t,e,n){if(e.utf8seq===0){if(t<=127){n(t);return}for(letr=1;r<6;r+=1)if(!(t>>7-r&1)){e.utf8seq=r;break}if(e.utf8seq===2)e.codepoint=t&31;elseif(e.utf8seq===3)e.codepoint=t&15;elseif(e.utf8seq===4)e.codepoint=t&7;elsethrownewError("Invalid UTF-8 sequence");e.utf8seq-=1}elseif(e.utf8seq>0){if(t<=127)thrownewError("Invalid UTF-8 sequence");e.codepoint=e.codepoint<<6|t&63,e.utf8seq-=1,e.utf8seq===0&&n(e.codepoint)}}functionhM(t){conste=[],n={queue:0,queuedBits:0},r=s=>{e.push(s)};for(lets=0;s<t.length;s+=1)mb(t.charCodeAt(s),n,r);returnnewUint8Array(e)}functiondM(t){conste=[];returncM(t,n=>e.push(n)),newUint8Array(e)}functionpM(t){conste=[],n={queue:0,queuedBits:0},r=s=>{e.push(s)};returnt.forEach(s=>Wv(s,n,r)),Wv(null,n,r),e.join("")}functiongM(t){returnMath.round(Date.now()/1e3)+t}functionmM(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(t){conste=Math.random()*16|0;return(t=="x"?e:e&3|8).toString(16)})}constAn=()=>typeofwindow<"u"&&typeofdocument<"u",mi={tested:!1,writable:!1},vb=()=>{if(!An())return!1;try{if(typeofglobalThis.localStorage!="object")return!1}catch{return!1}if(mi.tested)returnmi.writable;constt=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(t,t),globalThis.localStorage.removeItem(t),mi.tested=!0,mi.writable=!0}catch{mi.tested=!0,mi.writable=!1}returnmi.writable};functionvM(t){conste={},n=newURL(t);if(n.hash&&n.hash[0]==="#")try{newURLSearchParams(n.hash.substring(1)).forEach((s,o)=>{e[o]=s})}catch{}returnn.searchParams.forEach((r,s)=>{e[s]=r}),e}const_b=t=>{lete;returnt?e=t:typeoffetch>"u"?e=(...n)=>Je(()=>Promise.resolve().then(()=>js),void0).then(({default:r})=>r(...n)):e=fetch,(...n)=>e(...n)},_M=t=>typeoft=="object"&&t!==null&&"status"int&&"ok"int&&"json"int&&typeoft.json=="function",us=async(t,e,n)=>{awaitt.setItem(e,JSON.stringify(n))},vi=async(t,e)=>{constn=awaitt.getItem(e);if(!n)returnnull;try{returnJSON.parse(n)}catch{returnn}},Hr=async(t,e)=>{awaitt.removeItem(e)};classbu{constructor(){this.promise=newbu.promiseConstructor((e,n)=>{this.resolve=e,this.reject=n})}}bu.promiseConstructor=Promise;functionlf(t){conste=t.split(".");if(e.length!==3)thrownewah("Invalid JWT structure");for(letr=0;r<e.length;r++)if(!nM.test(e[r]))thrownewah("JWT not in base64url format");return{header:JSON.parse(qv(e[0])),payload:JSON.parse(qv(e[1])),signature:hM(e[2]),raw:{header:e[0],payload:e[1]}}}asyncfunctionyM(t){returnawaitnewPromise(e=>{setTimeout(()=>e(null),t)})}functionbM(t,e){returnnewPromise((r,s)=>{(async()=>{for(leto=0;o<1/0;o++)try{constl=awaitt(o);if(!e(o,null,l
`))throw new Error(`@supabase/auth-js:InvalidSIWEmessagefield"statement".Statementmustnotinclude'\\n'.Providedvalue:${t.statement}`)}const y=bb(t.address),w=d?`${d}://${r}`:r,x=t.statement?`${t.statement}
Resources:`;for(const R of h){if(!R||typeof R!="string")throw new Error(`@supabase/auth-js:InvalidSIWEmessagefield"resources".Everyresourcemustbeavalidstring.Providedvalue:${R}`);E+=`
-${R}`}O+=E}return`${k}
${O}`}UM();const zM={url:Z6,storageKey:eM,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:tM,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1};async function Jv(t,e,n){return await n()}const ss={};class Wo{constructor(e){var n,r;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=Wo.nextInstanceID,Wo.nextInstanceID+=1,this.instanceID>0&&An()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");const s=Object.assign(Object.assign({},zM),e);if(this.logDebugMessages=!!s.debug,typeof s.debug=="function"&&(this.logger=s.debug),this.persistSession=s.persistSession,this.storageKey=s.storageKey,this.autoRefreshToken=s.autoRefreshToken,this.admin=new FM({url:s.url,headers:s.headers,fetch:s.fetch}),this.url=s.url,this.headers=s.headers,this.fetch=_b(s.fetch),this.lock=s.lock||Jv,this.detectSessionInUrl=s.detectSessionInUrl,this.flowType=s.flowType,this.hasCustomAuthorizationHeader=s.hasCustomAuthorizationHeader,s.lock?this.lock=s.lock:An()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=HM:this.lock=Jv,this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=Number.MIN_SAFE_INTEGER),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this)},this.persistSession?(s.storage?this.storage=s.storage:vb()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=Gv(this.memoryStorage)),s.userStorage&&(this.userStorage=s.userStorage)):(this.memoryStorage={},this.storage=Gv(this.memoryStorage)),An()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(o){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",o)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",async o=>{this._debug("received broadcast notification from other tab or client",o),await this._notifyAllSubscribers(o.data.event,o.data.session,!1)})}this.initialize()}get jwks(){var e,n;return(n=(e=ss[this.storageKey])===null||e===void 0?void 0:e.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(e){ss[this.storageKey]=Object.assign(Object.assign({},ss[this.storageKey]),{jwks:e})}get jwks_cached_at(){var e,n;return(n=(e=ss[this.storageKey])===null||e===void 0?void 0:e.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(e){ss[this.storageKey]=Object.assign(Object.assign({},ss[this.storageKey]),{cachedAt:e})}_debug(...e){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID}(${db})${newDate().toISOString()}`,...e),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(-1,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var e;try{const n=vM(window.location.href);let r="none";if(this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce"),An()&&this.detectSessionInUrl&&r!=="none"){const{data:s,error:o}=await this._getSessionFromURL(n,r);if(o){if(this._debug("#_initialize()","error detecting session from URL",o),aM(o)){const f=(e=o.details)===null||e===void 0?void 0:e.code;if(f==="identity_already_exists"||f==="identity_not_found"||f==="single_identity_not_deletable")return{e
`);constU=awaitA.signMessage(newTextEncoder().encode(w),"utf8");if(!U||!(UinstanceofUint8Array))thrownewError("@supabase/auth-js: Wallet signMessage() API returned an recognized value");x=U}}try{const{data:k,error:O}=awaitNe(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:w,signature:pM(x)},!((m=e.options)===null||m===void0)&&m.captchaToken?{gotrue_meta_security:{captcha_token:(y=e.options)===null||y===void0?void0:y.captchaToken}}:null),xform:Yn});if(O)throwO;return!k||!k.session||!k.user?{data:{user:null,session:null},error:newlo}:(k.session&&(awaitthis._saveSession(k.session),awaitthis._notifyAllSubscribers("SIGNED_IN",k.session)),{data:Object.assign({},k),error:O})}catch(k){if(Re(k))return{data:{user:null,session:null},error:k};throwk}}async_exchangeCodeForSession(e){constn=awaitvi(this.storage,`${this.storageKey}-code-verifier`),[r,s]=(n??"").split("/");try{const{data:o,error:l}=awaitNe(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:e,code_verifier:r},xform:Yn});if(awaitHr(this.storage,`${this.storageKey}-code-verifier`),l)throwl;return!o||!o.session||!o.user?{data:{user:null,session:null,redirectType:null},error:newlo}:(o.session&&(awaitthis._saveSession(o.session),awaitthis._notifyAllSubscribers("SIGNED_IN",o.session)),{data:Object.assign(Object.assign({},o),{redirectType:s??null}),error:l})}catch(o){if(Re(o))return{data:{user:null,session:null,redirectType:null},error:o};throwo}}asyncsignInWithIdToken(e){try{const{options:n,provider:r,token:s,access_token:o,nonce:l}=e,c=awaitNe(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:s,access_token:o,nonce:l,gotrue_meta_security:{captcha_token:n==null?void0:n.captchaToken}},xform:Yn}),{data:f,error:h}=c;returnh?{data:{user:null,session:null},error:h}:!f||!f.session||!f.user?{data:{user:null,session:null},error:newlo}:(f.session&&(awaitthis._saveSession(f.session),awaitthis._notifyAllSubscribers("SIGNED_IN",f.session)),{data:f,error:h})}catch(n){if(Re(n))return{data:{user:null,session:null},error:n};thrown}}asyncsignInWithOtp(e){varn,r,s,o,l;try{if("email"ine){const{email:c,options:f}=e;leth=null,d=null;this.flowType==="pkce"&&([h,d]=awaitns(this.storage,this.storageKey));const{error:g}=awaitNe(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:c,data:(n=f==null?void0:f.data)!==null&&n!==void0?n:{},create_user:(r=f==null?void0:f.shouldCreateUser)!==null&&r!==void0?r:!0,gotrue_meta_security:{captcha_token:f==null?void0:f.captchaToken},code_challenge:h,code_challenge_method:d},redirectTo:f==null?void0:f.emailRedirectTo});return{data:{user:null,session:null},error:g}}if("phone"ine){const{phone:c,options:f}=e,{data:h,error:d}=awaitNe(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:c,data:(s=f==null?void0:f.data)!==null&&s!==void0?s:{},create_user:(o=f==null?void0:f.shouldCreateUser)!==null&&o!==void0?o:!0,gotrue_meta_security:{captcha_token:f==null?void0:f.captchaToken},channel:(l=f==null?void0:f.channel)!==null&&l!==void0?l:"sms"}});return{data:{user:null,session:null,messageId:h==null?void0:h.message_id},error:d}}thrownewrl("You must provide either an email or phone number.")}catch(c){if(Re(c))return{data:{user:null,session:null},error:c};throwc}}asyncverifyOtp(e){varn,r;try{lets,o;"options"ine&&(s=(n=e.options)===null||n===void0?void0:n.redirectTo,o=(r=e.options)===null||r===void0?void0:r.captchaToken);const{data:l,error:c}=awaitNe(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},e),{gotrue_meta_security:{captcha_token:o}}),redirectTo:s,xform:Yn});if(c)throwc;if(!l)thrownewError("An error occurred on token verification.");constf=l.session,h=l.user;returnf!=null&&f.access_token&&(awaitthis._saveSession(f),awaitthis._notifyAllSubscribers(e.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",f)),{data:{user:h,session:f},error:null}}catch(s){if(Re(s