UNPKG

@neosjs/request

Version:
12 lines 65.2 kB
(function(P,T){typeof exports=="object"&&typeof module<"u"?T(exports):typeof define=="function"&&define.amd?define(["exports"],T):(P=typeof globalThis<"u"?globalThis:P||self,T(P.NeosRequest={}))})(this,function(P){"use strict";var Ki=Object.defineProperty;var Qi=(P,T,$)=>T in P?Ki(P,T,{enumerable:!0,configurable:!0,writable:!0,value:$}):P[T]=$;var Mr=(P,T,$)=>(Qi(P,typeof T!="symbol"?T+"":T,$),$);/*! * NeosRequest * Version: 2.1.0 * ReleaseTime: 2023-04-24 15:12 * Website: https://docs.neosjs.com/request/ * Copyright 2023 NoesJS */function T(t,e){return function(){return t.apply(e,arguments)}}const{toString:$}=Object.prototype,{getPrototypeOf:We}=Object,He=(t=>e=>{const r=$.call(e);return t[r]||(t[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),D=t=>(t=t.toLowerCase(),e=>He(e)===t),Te=t=>e=>typeof e===t,{isArray:Y}=Array,pe=Te("undefined");function Lr(t){return t!==null&&!pe(t)&&t.constructor!==null&&!pe(t.constructor)&&V(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Ct=D("ArrayBuffer");function kr(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Ct(t.buffer),e}const jr=Te("string"),V=Te("function"),Dt=Te("number"),ze=t=>t!==null&&typeof t=="object",qr=t=>t===!0||t===!1,Ne=t=>{if(He(t)!=="object")return!1;const e=We(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},Wr=D("Date"),Hr=D("File"),zr=D("Blob"),Vr=D("FileList"),Jr=t=>ze(t)&&V(t.pipe),Gr=t=>{const e="[object FormData]";return t&&(typeof FormData=="function"&&t instanceof FormData||$.call(t)===e||V(t.toString)&&t.toString()===e)},Kr=D("URLSearchParams"),Qr=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function de(t,e,{allOwnKeys:r=!1}={}){if(t===null||typeof t>"u")return;let n,o;if(typeof t!="object"&&(t=[t]),Y(t))for(n=0,o=t.length;n<o;n++)e.call(null,t[n],n,t);else{const i=r?Object.getOwnPropertyNames(t):Object.keys(t),a=i.length;let s;for(n=0;n<a;n++)s=i[n],e.call(null,t[s],s,t)}}function Bt(t,e){e=e.toLowerCase();const r=Object.keys(t);let n=r.length,o;for(;n-- >0;)if(o=r[n],e===o.toLowerCase())return o;return null}const It=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),Ut=t=>!pe(t)&&t!==It;function Ve(){const{caseless:t}=Ut(this)&&this||{},e={},r=(n,o)=>{const i=t&&Bt(e,o)||o;Ne(e[i])&&Ne(n)?e[i]=Ve(e[i],n):Ne(n)?e[i]=Ve({},n):Y(n)?e[i]=n.slice():e[i]=n};for(let n=0,o=arguments.length;n<o;n++)arguments[n]&&de(arguments[n],r);return e}const Xr=(t,e,r,{allOwnKeys:n}={})=>(de(e,(o,i)=>{r&&V(o)?t[i]=T(o,r):t[i]=o},{allOwnKeys:n}),t),Yr=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),Zr=(t,e,r,n)=>{t.prototype=Object.create(e.prototype,n),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),r&&Object.assign(t.prototype,r)},en=(t,e,r,n)=>{let o,i,a;const s={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),i=o.length;i-- >0;)a=o[i],(!n||n(a,t,e))&&!s[a]&&(e[a]=t[a],s[a]=!0);t=r!==!1&&We(t)}while(t&&(!r||r(t,e))&&t!==Object.prototype);return e},tn=(t,e,r)=>{t=String(t),(r===void 0||r>t.length)&&(r=t.length),r-=e.length;const n=t.indexOf(e,r);return n!==-1&&n===r},rn=t=>{if(!t)return null;if(Y(t))return t;let e=t.length;if(!Dt(e))return null;const r=new Array(e);for(;e-- >0;)r[e]=t[e];return r},nn=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&We(Uint8Array)),on=(t,e)=>{const n=(t&&t[Symbol.iterator]).call(t);let o;for(;(o=n.next())&&!o.done;){const i=o.value;e.call(t,i[0],i[1])}},an=(t,e)=>{let r;const n=[];for(;(r=t.exec(e))!==null;)n.push(r);return n},sn=D("HTMLFormElement"),cn=t=>t.toLowerCase().replace(/[_-\s]([a-z\d])(\w*)/g,function(r,n,o){return n.toUpperCase()+o}),$t=(({hasOwnProperty:t})=>(e,r)=>t.call(e,r))(Object.prototype),un=D("RegExp"),Mt=(t,e)=>{const r=Object.getOwnPropertyDescriptors(t),n={};de(r,(o,i)=>{e(o,i,t)!==!1&&(n[i]=o)}),Object.defineProperties(t,n)},l={isArray:Y,isArrayBuffer:Ct,isBuffer:Lr,isFormData:Gr,isArrayBufferView:kr,isString:jr,isNumber:Dt,isBoolean:qr,isObject:ze,isPlainObject:Ne,isUndefined:pe,isDate:Wr,isFile:Hr,isBlob:zr,isRegExp:un,isFunction:V,isStream:Jr,isURLSearchParams:Kr,isTypedArray:nn,isFileList:Vr,forEach:de,merge:Ve,extend:Xr,trim:Qr,stripBOM:Yr,inherits:Zr,toFlatObject:en,kindOf:He,kindOfTest:D,endsWith:tn,toArray:rn,forEachEntry:on,matchAll:an,isHTMLForm:sn,hasOwnProperty:$t,hasOwnProp:$t,reduceDescriptors:Mt,freezeMethods:t=>{Mt(t,(e,r)=>{if(V(t)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const n=t[r];if(!!V(n)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},toObjectSet:(t,e)=>{const r={},n=o=>{o.forEach(i=>{r[i]=!0})};return Y(t)?n(t):n(String(t).split(e)),r},toCamelCase:cn,noop:()=>{},toFiniteNumber:(t,e)=>(t=+t,Number.isFinite(t)?t:e),findKey:Bt,global:It,isContextDefined:Ut,toJSONObject:t=>{const e=new Array(10),r=(n,o)=>{if(ze(n)){if(e.indexOf(n)>=0)return;if(!("toJSON"in n)){e[o]=n;const i=Y(n)?[]:{};return de(n,(a,s)=>{const u=r(a,o+1);!pe(u)&&(i[s]=u)}),e[o]=void 0,i}}return n};return r(t,0)}};function v(t,e,r,n,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),r&&(this.config=r),n&&(this.request=n),o&&(this.response=o)}l.inherits(v,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:l.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Lt=v.prototype,kt={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{kt[t]={value:t}}),Object.defineProperties(v,kt),Object.defineProperty(Lt,"isAxiosError",{value:!0}),v.from=(t,e,r,n,o,i)=>{const a=Object.create(Lt);return l.toFlatObject(t,a,function(u){return u!==Error.prototype},s=>s!=="isAxiosError"),v.call(a,t.message,e,r,n,o),a.cause=t,a.name=t.name,i&&Object.assign(a,i),a};function ln(t){var e=t.default;if(typeof e=="function"){var r=function(){return e.apply(this,arguments)};r.prototype=e.prototype}else r={};return Object.defineProperty(r,"__esModule",{value:!0}),Object.keys(t).forEach(function(n){var o=Object.getOwnPropertyDescriptor(t,n);Object.defineProperty(r,n,o.get?o:{enumerable:!0,get:function(){return t[n]}})}),r}var fn=typeof self=="object"?self.FormData:window.FormData;const pn=fn;function Je(t){return l.isPlainObject(t)||l.isArray(t)}function jt(t){return l.endsWith(t,"[]")?t.slice(0,-2):t}function qt(t,e,r){return t?t.concat(e).map(function(o,i){return o=jt(o),!r&&i?"["+o+"]":o}).join(r?".":""):e}function dn(t){return l.isArray(t)&&!t.some(Je)}const yn=l.toFlatObject(l,{},null,function(e){return/^is[A-Z]/.test(e)});function hn(t){return t&&l.isFunction(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator]}function xe(t,e,r){if(!l.isObject(t))throw new TypeError("target must be an object");e=e||new(pn||FormData),r=l.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,b){return!l.isUndefined(b[m])});const n=r.metaTokens,o=r.visitor||f,i=r.dots,a=r.indexes,u=(r.Blob||typeof Blob<"u"&&Blob)&&hn(e);if(!l.isFunction(o))throw new TypeError("visitor must be a function");function c(p){if(p===null)return"";if(l.isDate(p))return p.toISOString();if(!u&&l.isBlob(p))throw new v("Blob is not supported. Use a Buffer instead.");return l.isArrayBuffer(p)||l.isTypedArray(p)?u&&typeof Blob=="function"?new Blob([p]):Buffer.from(p):p}function f(p,m,b){let g=p;if(p&&!b&&typeof p=="object"){if(l.endsWith(m,"{}"))m=n?m:m.slice(0,-2),p=JSON.stringify(p);else if(l.isArray(p)&&dn(p)||l.isFileList(p)||l.endsWith(m,"[]")&&(g=l.toArray(p)))return m=jt(m),g.forEach(function(N,W){!(l.isUndefined(N)||N===null)&&e.append(a===!0?qt([m],W,i):a===null?m:m+"[]",c(N))}),!1}return Je(p)?!0:(e.append(qt(b,m,i),c(p)),!1)}const d=[],y=Object.assign(yn,{defaultVisitor:f,convertValue:c,isVisitable:Je});function h(p,m){if(!l.isUndefined(p)){if(d.indexOf(p)!==-1)throw Error("Circular reference detected in "+m.join("."));d.push(p),l.forEach(p,function(g,A){(!(l.isUndefined(g)||g===null)&&o.call(e,g,l.isString(A)?A.trim():A,m,y))===!0&&h(g,m?m.concat(A):[A])}),d.pop()}}if(!l.isObject(t))throw new TypeError("data must be an object");return h(t),e}function Wt(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(n){return e[n]})}function Ge(t,e){this._pairs=[],t&&xe(t,this,e)}const Ht=Ge.prototype;Ht.append=function(e,r){this._pairs.push([e,r])},Ht.toString=function(e){const r=e?function(n){return e.call(this,n,Wt)}:Wt;return this._pairs.map(function(o){return r(o[0])+"="+r(o[1])},"").join("&")};function mn(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function zt(t,e,r){if(!e)return t;const n=r&&r.encode||mn,o=r&&r.serialize;let i;if(o?i=o(e,r):i=l.isURLSearchParams(e)?e.toString():new Ge(e,r).toString(n),i){const a=t.indexOf("#");a!==-1&&(t=t.slice(0,a)),t+=(t.indexOf("?")===-1?"?":"&")+i}return t}class gn{constructor(){this.handlers=[]}use(e,r,n){return this.handlers.push({fulfilled:e,rejected:r,synchronous:n?n.synchronous:!1,runWhen:n?n.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){l.forEach(this.handlers,function(n){n!==null&&e(n)})}}const Vt=gn,Jt={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Sn=typeof URLSearchParams<"u"?URLSearchParams:Ge,vn=FormData,En=(()=>{let t;return typeof navigator<"u"&&((t=navigator.product)==="ReactNative"||t==="NativeScript"||t==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),bn=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),x={isBrowser:!0,classes:{URLSearchParams:Sn,FormData:vn,Blob},isStandardBrowserEnv:En,isStandardBrowserWebWorkerEnv:bn,protocols:["http","https","file","blob","url","data"]};function wn(t,e){return xe(t,new x.classes.URLSearchParams,Object.assign({visitor:function(r,n,o,i){return x.isNode&&l.isBuffer(r)?(this.append(n,r.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},e))}function Rn(t){return l.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function On(t){const e={},r=Object.keys(t);let n;const o=r.length;let i;for(n=0;n<o;n++)i=r[n],e[i]=t[i];return e}function Gt(t){function e(r,n,o,i){let a=r[i++];const s=Number.isFinite(+a),u=i>=r.length;return a=!a&&l.isArray(o)?o.length:a,u?(l.hasOwnProp(o,a)?o[a]=[o[a],n]:o[a]=n,!s):((!o[a]||!l.isObject(o[a]))&&(o[a]=[]),e(r,n,o[a],i)&&l.isArray(o[a])&&(o[a]=On(o[a])),!s)}if(l.isFormData(t)&&l.isFunction(t.entries)){const r={};return l.forEachEntry(t,(n,o)=>{e(Rn(n),o,r,0)}),r}return null}const An={"Content-Type":void 0};function Pn(t,e,r){if(l.isString(t))try{return(e||JSON.parse)(t),l.trim(t)}catch(n){if(n.name!=="SyntaxError")throw n}return(r||JSON.stringify)(t)}const _e={transitional:Jt,adapter:["xhr","http"],transformRequest:[function(e,r){const n=r.getContentType()||"",o=n.indexOf("application/json")>-1,i=l.isObject(e);if(i&&l.isHTMLForm(e)&&(e=new FormData(e)),l.isFormData(e))return o&&o?JSON.stringify(Gt(e)):e;if(l.isArrayBuffer(e)||l.isBuffer(e)||l.isStream(e)||l.isFile(e)||l.isBlob(e))return e;if(l.isArrayBufferView(e))return e.buffer;if(l.isURLSearchParams(e))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let s;if(i){if(n.indexOf("application/x-www-form-urlencoded")>-1)return wn(e,this.formSerializer).toString();if((s=l.isFileList(e))||n.indexOf("multipart/form-data")>-1){const u=this.env&&this.env.FormData;return xe(s?{"files[]":e}:e,u&&new u,this.formSerializer)}}return i||o?(r.setContentType("application/json",!1),Pn(e)):e}],transformResponse:[function(e){const r=this.transitional||_e.transitional,n=r&&r.forcedJSONParsing,o=this.responseType==="json";if(e&&l.isString(e)&&(n&&!this.responseType||o)){const a=!(r&&r.silentJSONParsing)&&o;try{return JSON.parse(e)}catch(s){if(a)throw s.name==="SyntaxError"?v.from(s,v.ERR_BAD_RESPONSE,this,null,this.response):s}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:x.classes.FormData,Blob:x.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};l.forEach(["delete","get","head"],function(e){_e.headers[e]={}}),l.forEach(["post","put","patch"],function(e){_e.headers[e]=l.merge(An)});const Ke=_e,Tn=l.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Nn=t=>{const e={};let r,n,o;return t&&t.split(` `).forEach(function(a){o=a.indexOf(":"),r=a.substring(0,o).trim().toLowerCase(),n=a.substring(o+1).trim(),!(!r||e[r]&&Tn[r])&&(r==="set-cookie"?e[r]?e[r].push(n):e[r]=[n]:e[r]=e[r]?e[r]+", "+n:n)}),e},Kt=Symbol("internals");function ye(t){return t&&String(t).trim().toLowerCase()}function Fe(t){return t===!1||t==null?t:l.isArray(t)?t.map(Fe):String(t)}function xn(t){const e=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let n;for(;n=r.exec(t);)e[n[1]]=n[2];return e}function _n(t){return/^[-_a-zA-Z]+$/.test(t.trim())}function Qt(t,e,r,n){if(l.isFunction(n))return n.call(this,e,r);if(!!l.isString(e)){if(l.isString(n))return e.indexOf(n)!==-1;if(l.isRegExp(n))return n.test(e)}}function Fn(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,r,n)=>r.toUpperCase()+n)}function Cn(t,e){const r=l.toCamelCase(" "+e);["get","set","has"].forEach(n=>{Object.defineProperty(t,n+r,{value:function(o,i,a){return this[n].call(this,e,o,i,a)},configurable:!0})})}class Ce{constructor(e){e&&this.set(e)}set(e,r,n){const o=this;function i(s,u,c){const f=ye(u);if(!f)throw new Error("header name must be a non-empty string");const d=l.findKey(o,f);(!d||o[d]===void 0||c===!0||c===void 0&&o[d]!==!1)&&(o[d||u]=Fe(s))}const a=(s,u)=>l.forEach(s,(c,f)=>i(c,f,u));return l.isPlainObject(e)||e instanceof this.constructor?a(e,r):l.isString(e)&&(e=e.trim())&&!_n(e)?a(Nn(e),r):e!=null&&i(r,e,n),this}get(e,r){if(e=ye(e),e){const n=l.findKey(this,e);if(n){const o=this[n];if(!r)return o;if(r===!0)return xn(o);if(l.isFunction(r))return r.call(this,o,n);if(l.isRegExp(r))return r.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,r){if(e=ye(e),e){const n=l.findKey(this,e);return!!(n&&(!r||Qt(this,this[n],n,r)))}return!1}delete(e,r){const n=this;let o=!1;function i(a){if(a=ye(a),a){const s=l.findKey(n,a);s&&(!r||Qt(n,n[s],s,r))&&(delete n[s],o=!0)}}return l.isArray(e)?e.forEach(i):i(e),o}clear(){return Object.keys(this).forEach(this.delete.bind(this))}normalize(e){const r=this,n={};return l.forEach(this,(o,i)=>{const a=l.findKey(n,i);if(a){r[a]=Fe(o),delete r[i];return}const s=e?Fn(i):String(i).trim();s!==i&&delete r[i],r[s]=Fe(o),n[s]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const r=Object.create(null);return l.forEach(this,(n,o)=>{n!=null&&n!==!1&&(r[o]=e&&l.isArray(n)?n.join(", "):n)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,r])=>e+": "+r).join(` `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...r){const n=new this(e);return r.forEach(o=>n.set(o)),n}static accessor(e){const n=(this[Kt]=this[Kt]={accessors:{}}).accessors,o=this.prototype;function i(a){const s=ye(a);n[s]||(Cn(o,a),n[s]=!0)}return l.isArray(e)?e.forEach(i):i(e),this}}Ce.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent"]),l.freezeMethods(Ce.prototype),l.freezeMethods(Ce);const B=Ce;function Qe(t,e){const r=this||Ke,n=e||r,o=B.from(n.headers);let i=n.data;return l.forEach(t,function(s){i=s.call(r,i,o.normalize(),e?e.status:void 0)}),o.normalize(),i}function Xt(t){return!!(t&&t.__CANCEL__)}function he(t,e,r){v.call(this,t==null?"canceled":t,v.ERR_CANCELED,e,r),this.name="CanceledError"}l.inherits(he,v,{__CANCEL__:!0});const Dn=null;function Bn(t,e,r){const n=r.config.validateStatus;!r.status||!n||n(r.status)?t(r):e(new v("Request failed with status code "+r.status,[v.ERR_BAD_REQUEST,v.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}const In=x.isStandardBrowserEnv?function(){return{write:function(r,n,o,i,a,s){const u=[];u.push(r+"="+encodeURIComponent(n)),l.isNumber(o)&&u.push("expires="+new Date(o).toGMTString()),l.isString(i)&&u.push("path="+i),l.isString(a)&&u.push("domain="+a),s===!0&&u.push("secure"),document.cookie=u.join("; ")},read:function(r){const n=document.cookie.match(new RegExp("(^|;\\s*)("+r+")=([^;]*)"));return n?decodeURIComponent(n[3]):null},remove:function(r){this.write(r,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function Un(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function $n(t,e){return e?t.replace(/\/+$/,"")+"/"+e.replace(/^\/+/,""):t}function Yt(t,e){return t&&!Un(e)?$n(t,e):e}const Mn=x.isStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),r=document.createElement("a");let n;function o(i){let a=i;return e&&(r.setAttribute("href",a),a=r.href),r.setAttribute("href",a),{href:r.href,protocol:r.protocol?r.protocol.replace(/:$/,""):"",host:r.host,search:r.search?r.search.replace(/^\?/,""):"",hash:r.hash?r.hash.replace(/^#/,""):"",hostname:r.hostname,port:r.port,pathname:r.pathname.charAt(0)==="/"?r.pathname:"/"+r.pathname}}return n=o(window.location.href),function(a){const s=l.isString(a)?o(a):a;return s.protocol===n.protocol&&s.host===n.host}}():function(){return function(){return!0}}();function Ln(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function kn(t,e){t=t||10;const r=new Array(t),n=new Array(t);let o=0,i=0,a;return e=e!==void 0?e:1e3,function(u){const c=Date.now(),f=n[i];a||(a=c),r[o]=u,n[o]=c;let d=i,y=0;for(;d!==o;)y+=r[d++],d=d%t;if(o=(o+1)%t,o===i&&(i=(i+1)%t),c-a<e)return;const h=f&&c-f;return h?Math.round(y*1e3/h):void 0}}function Zt(t,e){let r=0;const n=kn(50,250);return o=>{const i=o.loaded,a=o.lengthComputable?o.total:void 0,s=i-r,u=n(s),c=i<=a;r=i;const f={loaded:i,total:a,progress:a?i/a:void 0,bytes:s,rate:u||void 0,estimated:u&&a&&c?(a-i)/u:void 0,event:o};f[e?"download":"upload"]=!0,t(f)}}const De={http:Dn,xhr:typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(r,n){let o=t.data;const i=B.from(t.headers).normalize(),a=t.responseType;let s;function u(){t.cancelToken&&t.cancelToken.unsubscribe(s),t.signal&&t.signal.removeEventListener("abort",s)}l.isFormData(o)&&(x.isStandardBrowserEnv||x.isStandardBrowserWebWorkerEnv)&&i.setContentType(!1);let c=new XMLHttpRequest;if(t.auth){const h=t.auth.username||"",p=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";i.set("Authorization","Basic "+btoa(h+":"+p))}const f=Yt(t.baseURL,t.url);c.open(t.method.toUpperCase(),zt(f,t.params,t.paramsSerializer),!0),c.timeout=t.timeout;function d(){if(!c)return;const h=B.from("getAllResponseHeaders"in c&&c.getAllResponseHeaders()),m={data:!a||a==="text"||a==="json"?c.responseText:c.response,status:c.status,statusText:c.statusText,headers:h,config:t,request:c};Bn(function(g){r(g),u()},function(g){n(g),u()},m),c=null}if("onloadend"in c?c.onloadend=d:c.onreadystatechange=function(){!c||c.readyState!==4||c.status===0&&!(c.responseURL&&c.responseURL.indexOf("file:")===0)||setTimeout(d)},c.onabort=function(){!c||(n(new v("Request aborted",v.ECONNABORTED,t,c)),c=null)},c.onerror=function(){n(new v("Network Error",v.ERR_NETWORK,t,c)),c=null},c.ontimeout=function(){let p=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";const m=t.transitional||Jt;t.timeoutErrorMessage&&(p=t.timeoutErrorMessage),n(new v(p,m.clarifyTimeoutError?v.ETIMEDOUT:v.ECONNABORTED,t,c)),c=null},x.isStandardBrowserEnv){const h=(t.withCredentials||Mn(f))&&t.xsrfCookieName&&In.read(t.xsrfCookieName);h&&i.set(t.xsrfHeaderName,h)}o===void 0&&i.setContentType(null),"setRequestHeader"in c&&l.forEach(i.toJSON(),function(p,m){c.setRequestHeader(m,p)}),l.isUndefined(t.withCredentials)||(c.withCredentials=!!t.withCredentials),a&&a!=="json"&&(c.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&c.addEventListener("progress",Zt(t.onDownloadProgress,!0)),typeof t.onUploadProgress=="function"&&c.upload&&c.upload.addEventListener("progress",Zt(t.onUploadProgress)),(t.cancelToken||t.signal)&&(s=h=>{!c||(n(!h||h.type?new he(null,t,c):h),c.abort(),c=null)},t.cancelToken&&t.cancelToken.subscribe(s),t.signal&&(t.signal.aborted?s():t.signal.addEventListener("abort",s)));const y=Ln(f);if(y&&x.protocols.indexOf(y)===-1){n(new v("Unsupported protocol "+y+":",v.ERR_BAD_REQUEST,t));return}c.send(o||null)})}};l.forEach(De,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const jn={getAdapter:t=>{t=l.isArray(t)?t:[t];const{length:e}=t;let r,n;for(let o=0;o<e&&(r=t[o],!(n=l.isString(r)?De[r.toLowerCase()]:r));o++);if(!n)throw n===!1?new v(`Adapter ${r} is not supported by the environment`,"ERR_NOT_SUPPORT"):new Error(l.hasOwnProp(De,r)?`Adapter '${r}' is not available in the build`:`Unknown adapter '${r}'`);if(!l.isFunction(n))throw new TypeError("adapter is not a function");return n},adapters:De};function Xe(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new he(null,t)}function er(t){return Xe(t),t.headers=B.from(t.headers),t.data=Qe.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),jn.getAdapter(t.adapter||Ke.adapter)(t).then(function(n){return Xe(t),n.data=Qe.call(t,t.transformResponse,n),n.headers=B.from(n.headers),n},function(n){return Xt(n)||(Xe(t),n&&n.response&&(n.response.data=Qe.call(t,t.transformResponse,n.response),n.response.headers=B.from(n.response.headers))),Promise.reject(n)})}const tr=t=>t instanceof B?t.toJSON():t;function Z(t,e){e=e||{};const r={};function n(c,f,d){return l.isPlainObject(c)&&l.isPlainObject(f)?l.merge.call({caseless:d},c,f):l.isPlainObject(f)?l.merge({},f):l.isArray(f)?f.slice():f}function o(c,f,d){if(l.isUndefined(f)){if(!l.isUndefined(c))return n(void 0,c,d)}else return n(c,f,d)}function i(c,f){if(!l.isUndefined(f))return n(void 0,f)}function a(c,f){if(l.isUndefined(f)){if(!l.isUndefined(c))return n(void 0,c)}else return n(void 0,f)}function s(c,f,d){if(d in e)return n(c,f);if(d in t)return n(void 0,c)}const u={url:i,method:i,data:i,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:s,headers:(c,f)=>o(tr(c),tr(f),!0)};return l.forEach(Object.keys(t).concat(Object.keys(e)),function(f){const d=u[f]||o,y=d(t[f],e[f],f);l.isUndefined(y)&&d!==s||(r[f]=y)}),r}const rr="1.2.2",Ye={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{Ye[t]=function(n){return typeof n===t||"a"+(e<1?"n ":" ")+t}});const nr={};Ye.transitional=function(e,r,n){function o(i,a){return"[Axios v"+rr+"] Transitional option '"+i+"'"+a+(n?". "+n:"")}return(i,a,s)=>{if(e===!1)throw new v(o(a," has been removed"+(r?" in "+r:"")),v.ERR_DEPRECATED);return r&&!nr[a]&&(nr[a]=!0,console.warn(o(a," has been deprecated since v"+r+" and will be removed in the near future"))),e?e(i,a,s):!0}};function qn(t,e,r){if(typeof t!="object")throw new v("options must be an object",v.ERR_BAD_OPTION_VALUE);const n=Object.keys(t);let o=n.length;for(;o-- >0;){const i=n[o],a=e[i];if(a){const s=t[i],u=s===void 0||a(s,i,t);if(u!==!0)throw new v("option "+i+" must be "+u,v.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new v("Unknown option "+i,v.ERR_BAD_OPTION)}}const Ze={assertOptions:qn,validators:Ye},M=Ze.validators;class Be{constructor(e){this.defaults=e,this.interceptors={request:new Vt,response:new Vt}}request(e,r){typeof e=="string"?(r=r||{},r.url=e):r=e||{},r=Z(this.defaults,r);const{transitional:n,paramsSerializer:o,headers:i}=r;n!==void 0&&Ze.assertOptions(n,{silentJSONParsing:M.transitional(M.boolean),forcedJSONParsing:M.transitional(M.boolean),clarifyTimeoutError:M.transitional(M.boolean)},!1),o!==void 0&&Ze.assertOptions(o,{encode:M.function,serialize:M.function},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let a;a=i&&l.merge(i.common,i[r.method]),a&&l.forEach(["delete","get","head","post","put","patch","common"],p=>{delete i[p]}),r.headers=B.concat(a,i);const s=[];let u=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(r)===!1||(u=u&&m.synchronous,s.unshift(m.fulfilled,m.rejected))});const c=[];this.interceptors.response.forEach(function(m){c.push(m.fulfilled,m.rejected)});let f,d=0,y;if(!u){const p=[er.bind(this),void 0];for(p.unshift.apply(p,s),p.push.apply(p,c),y=p.length,f=Promise.resolve(r);d<y;)f=f.then(p[d++],p[d++]);return f}y=s.length;let h=r;for(d=0;d<y;){const p=s[d++],m=s[d++];try{h=p(h)}catch(b){m.call(this,b);break}}try{f=er.call(this,h)}catch(p){return Promise.reject(p)}for(d=0,y=c.length;d<y;)f=f.then(c[d++],c[d++]);return f}getUri(e){e=Z(this.defaults,e);const r=Yt(e.baseURL,e.url);return zt(r,e.params,e.paramsSerializer)}}l.forEach(["delete","get","head","options"],function(e){Be.prototype[e]=function(r,n){return this.request(Z(n||{},{method:e,url:r,data:(n||{}).data}))}}),l.forEach(["post","put","patch"],function(e){function r(n){return function(i,a,s){return this.request(Z(s||{},{method:e,headers:n?{"Content-Type":"multipart/form-data"}:{},url:i,data:a}))}}Be.prototype[e]=r(),Be.prototype[e+"Form"]=r(!0)});const Ie=Be;class et{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(i){r=i});const n=this;this.promise.then(o=>{if(!n._listeners)return;let i=n._listeners.length;for(;i-- >0;)n._listeners[i](o);n._listeners=null}),this.promise.then=o=>{let i;const a=new Promise(s=>{n.subscribe(s),i=s}).then(o);return a.cancel=function(){n.unsubscribe(i)},a},e(function(i,a,s){n.reason||(n.reason=new he(i,a,s),r(n.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const r=this._listeners.indexOf(e);r!==-1&&this._listeners.splice(r,1)}static source(){let e;return{token:new et(function(o){e=o}),cancel:e}}}const Wn=et;function Hn(t){return function(r){return t.apply(null,r)}}function zn(t){return l.isObject(t)&&t.isAxiosError===!0}const tt={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(tt).forEach(([t,e])=>{tt[e]=t});const Vn=tt;function or(t){const e=new Ie(t),r=T(Ie.prototype.request,e);return l.extend(r,Ie.prototype,e,{allOwnKeys:!0}),l.extend(r,e,null,{allOwnKeys:!0}),r.create=function(o){return or(Z(t,o))},r}const E=or(Ke);E.Axios=Ie,E.CanceledError=he,E.CancelToken=Wn,E.isCancel=Xt,E.VERSION=rr,E.toFormData=xe,E.AxiosError=v,E.Cancel=E.CanceledError,E.all=function(e){return Promise.all(e)},E.spread=Hn,E.isAxiosError=zn,E.mergeConfig=Z,E.AxiosHeaders=B,E.formToJSON=t=>Gt(l.isHTMLForm(t)?new FormData(t):t),E.HttpStatusCode=Vn,E.default=E;const J=E;var Jn=function(){if(typeof Symbol!="function"||typeof Object.getOwnPropertySymbols!="function")return!1;if(typeof Symbol.iterator=="symbol")return!0;var e={},r=Symbol("test"),n=Object(r);if(typeof r=="string"||Object.prototype.toString.call(r)!=="[object Symbol]"||Object.prototype.toString.call(n)!=="[object Symbol]")return!1;var o=42;e[r]=o;for(r in e)return!1;if(typeof Object.keys=="function"&&Object.keys(e).length!==0||typeof Object.getOwnPropertyNames=="function"&&Object.getOwnPropertyNames(e).length!==0)return!1;var i=Object.getOwnPropertySymbols(e);if(i.length!==1||i[0]!==r||!Object.prototype.propertyIsEnumerable.call(e,r))return!1;if(typeof Object.getOwnPropertyDescriptor=="function"){var a=Object.getOwnPropertyDescriptor(e,r);if(a.value!==o||a.enumerable!==!0)return!1}return!0},ir=typeof Symbol<"u"&&Symbol,Gn=Jn,Kn=function(){return typeof ir!="function"||typeof Symbol!="function"||typeof ir("foo")!="symbol"||typeof Symbol("bar")!="symbol"?!1:Gn()},Qn="Function.prototype.bind called on incompatible ",rt=Array.prototype.slice,Xn=Object.prototype.toString,Yn="[object Function]",Zn=function(e){var r=this;if(typeof r!="function"||Xn.call(r)!==Yn)throw new TypeError(Qn+r);for(var n=rt.call(arguments,1),o,i=function(){if(this instanceof o){var f=r.apply(this,n.concat(rt.call(arguments)));return Object(f)===f?f:this}else return r.apply(e,n.concat(rt.call(arguments)))},a=Math.max(0,r.length-n.length),s=[],u=0;u<a;u++)s.push("$"+u);if(o=Function("binder","return function ("+s.join(",")+"){ return binder.apply(this,arguments); }")(i),r.prototype){var c=function(){};c.prototype=r.prototype,o.prototype=new c,c.prototype=null}return o},eo=Zn,nt=Function.prototype.bind||eo,to=nt,ro=to.call(Function.call,Object.prototype.hasOwnProperty),S,ee=SyntaxError,ar=Function,te=TypeError,ot=function(t){try{return ar('"use strict"; return ('+t+").constructor;")()}catch{}},G=Object.getOwnPropertyDescriptor;if(G)try{G({},"")}catch{G=null}var it=function(){throw new te},no=G?function(){try{return arguments.callee,it}catch{try{return G(arguments,"callee").get}catch{return it}}}():it,re=Kn(),L=Object.getPrototypeOf||function(t){return t.__proto__},ne={},oo=typeof Uint8Array>"u"?S:L(Uint8Array),oe={"%AggregateError%":typeof AggregateError>"u"?S:AggregateError,"%Array%":Array,"%ArrayBuffer%":typeof ArrayBuffer>"u"?S:ArrayBuffer,"%ArrayIteratorPrototype%":re?L([][Symbol.iterator]()):S,"%AsyncFromSyncIteratorPrototype%":S,"%AsyncFunction%":ne,"%AsyncGenerator%":ne,"%AsyncGeneratorFunction%":ne,"%AsyncIteratorPrototype%":ne,"%Atomics%":typeof Atomics>"u"?S:Atomics,"%BigInt%":typeof BigInt>"u"?S:BigInt,"%Boolean%":Boolean,"%DataView%":typeof DataView>"u"?S:DataView,"%Date%":Date,"%decodeURI%":decodeURI,"%decodeURIComponent%":decodeURIComponent,"%encodeURI%":encodeURI,"%encodeURIComponent%":encodeURIComponent,"%Error%":Error,"%eval%":eval,"%EvalError%":EvalError,"%Float32Array%":typeof Float32Array>"u"?S:Float32Array,"%Float64Array%":typeof Float64Array>"u"?S:Float64Array,"%FinalizationRegistry%":typeof FinalizationRegistry>"u"?S:FinalizationRegistry,"%Function%":ar,"%GeneratorFunction%":ne,"%Int8Array%":typeof Int8Array>"u"?S:Int8Array,"%Int16Array%":typeof Int16Array>"u"?S:Int16Array,"%Int32Array%":typeof Int32Array>"u"?S:Int32Array,"%isFinite%":isFinite,"%isNaN%":isNaN,"%IteratorPrototype%":re?L(L([][Symbol.iterator]())):S,"%JSON%":typeof JSON=="object"?JSON:S,"%Map%":typeof Map>"u"?S:Map,"%MapIteratorPrototype%":typeof Map>"u"||!re?S:L(new Map()[Symbol.iterator]()),"%Math%":Math,"%Number%":Number,"%Object%":Object,"%parseFloat%":parseFloat,"%parseInt%":parseInt,"%Promise%":typeof Promise>"u"?S:Promise,"%Proxy%":typeof Proxy>"u"?S:Proxy,"%RangeError%":RangeError,"%ReferenceError%":ReferenceError,"%Reflect%":typeof Reflect>"u"?S:Reflect,"%RegExp%":RegExp,"%Set%":typeof Set>"u"?S:Set,"%SetIteratorPrototype%":typeof Set>"u"||!re?S:L(new Set()[Symbol.iterator]()),"%SharedArrayBuffer%":typeof SharedArrayBuffer>"u"?S:SharedArrayBuffer,"%String%":String,"%StringIteratorPrototype%":re?L(""[Symbol.iterator]()):S,"%Symbol%":re?Symbol:S,"%SyntaxError%":ee,"%ThrowTypeError%":no,"%TypedArray%":oo,"%TypeError%":te,"%Uint8Array%":typeof Uint8Array>"u"?S:Uint8Array,"%Uint8ClampedArray%":typeof Uint8ClampedArray>"u"?S:Uint8ClampedArray,"%Uint16Array%":typeof Uint16Array>"u"?S:Uint16Array,"%Uint32Array%":typeof Uint32Array>"u"?S:Uint32Array,"%URIError%":URIError,"%WeakMap%":typeof WeakMap>"u"?S:WeakMap,"%WeakRef%":typeof WeakRef>"u"?S:WeakRef,"%WeakSet%":typeof WeakSet>"u"?S:WeakSet},io=function t(e){var r;if(e==="%AsyncFunction%")r=ot("async function () {}");else if(e==="%GeneratorFunction%")r=ot("function* () {}");else if(e==="%AsyncGeneratorFunction%")r=ot("async function* () {}");else if(e==="%AsyncGenerator%"){var n=t("%AsyncGeneratorFunction%");n&&(r=n.prototype)}else if(e==="%AsyncIteratorPrototype%"){var o=t("%AsyncGenerator%");o&&(r=L(o.prototype))}return oe[e]=r,r},sr={"%ArrayBufferPrototype%":["ArrayBuffer","prototype"],"%ArrayPrototype%":["Array","prototype"],"%ArrayProto_entries%":["Array","prototype","entries"],"%ArrayProto_forEach%":["Array","prototype","forEach"],"%ArrayProto_keys%":["Array","prototype","keys"],"%ArrayProto_values%":["Array","prototype","values"],"%AsyncFunctionPrototype%":["AsyncFunction","prototype"],"%AsyncGenerator%":["AsyncGeneratorFunction","prototype"],"%AsyncGeneratorPrototype%":["AsyncGeneratorFunction","prototype","prototype"],"%BooleanPrototype%":["Boolean","prototype"],"%DataViewPrototype%":["DataView","prototype"],"%DatePrototype%":["Date","prototype"],"%ErrorPrototype%":["Error","prototype"],"%EvalErrorPrototype%":["EvalError","prototype"],"%Float32ArrayPrototype%":["Float32Array","prototype"],"%Float64ArrayPrototype%":["Float64Array","prototype"],"%FunctionPrototype%":["Function","prototype"],"%Generator%":["GeneratorFunction","prototype"],"%GeneratorPrototype%":["GeneratorFunction","prototype","prototype"],"%Int8ArrayPrototype%":["Int8Array","prototype"],"%Int16ArrayPrototype%":["Int16Array","prototype"],"%Int32ArrayPrototype%":["Int32Array","prototype"],"%JSONParse%":["JSON","parse"],"%JSONStringify%":["JSON","stringify"],"%MapPrototype%":["Map","prototype"],"%NumberPrototype%":["Number","prototype"],"%ObjectPrototype%":["Object","prototype"],"%ObjProto_toString%":["Object","prototype","toString"],"%ObjProto_valueOf%":["Object","prototype","valueOf"],"%PromisePrototype%":["Promise","prototype"],"%PromiseProto_then%":["Promise","prototype","then"],"%Promise_all%":["Promise","all"],"%Promise_reject%":["Promise","reject"],"%Promise_resolve%":["Promise","resolve"],"%RangeErrorPrototype%":["RangeError","prototype"],"%ReferenceErrorPrototype%":["ReferenceError","prototype"],"%RegExpPrototype%":["RegExp","prototype"],"%SetPrototype%":["Set","prototype"],"%SharedArrayBufferPrototype%":["SharedArrayBuffer","prototype"],"%StringPrototype%":["String","prototype"],"%SymbolPrototype%":["Symbol","prototype"],"%SyntaxErrorPrototype%":["SyntaxError","prototype"],"%TypedArrayPrototype%":["TypedArray","prototype"],"%TypeErrorPrototype%":["TypeError","prototype"],"%Uint8ArrayPrototype%":["Uint8Array","prototype"],"%Uint8ClampedArrayPrototype%":["Uint8ClampedArray","prototype"],"%Uint16ArrayPrototype%":["Uint16Array","prototype"],"%Uint32ArrayPrototype%":["Uint32Array","prototype"],"%URIErrorPrototype%":["URIError","prototype"],"%WeakMapPrototype%":["WeakMap","prototype"],"%WeakSetPrototype%":["WeakSet","prototype"]},me=nt,Ue=ro,ao=me.call(Function.call,Array.prototype.concat),so=me.call(Function.apply,Array.prototype.splice),cr=me.call(Function.call,String.prototype.replace),$e=me.call(Function.call,String.prototype.slice),co=me.call(Function.call,RegExp.prototype.exec),uo=/[^%.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|%$))/g,lo=/\\(\\)?/g,fo=function(e){var r=$e(e,0,1),n=$e(e,-1);if(r==="%"&&n!=="%")throw new ee("invalid intrinsic syntax, expected closing `%`");if(n==="%"&&r!=="%")throw new ee("invalid intrinsic syntax, expected opening `%`");var o=[];return cr(e,uo,function(i,a,s,u){o[o.length]=s?cr(u,lo,"$1"):a||i}),o},po=function(e,r){var n=e,o;if(Ue(sr,n)&&(o=sr[n],n="%"+o[0]+"%"),Ue(oe,n)){var i=oe[n];if(i===ne&&(i=io(n)),typeof i>"u"&&!r)throw new te("intrinsic "+e+" exists, but is not available. Please file an issue!");return{alias:o,name:n,value:i}}throw new ee("intrinsic "+e+" does not exist!")},at=function(e,r){if(typeof e!="string"||e.length===0)throw new te("intrinsic name must be a non-empty string");if(arguments.length>1&&typeof r!="boolean")throw new te('"allowMissing" argument must be a boolean');if(co(/^%?[^%]*%?$/g,e)===null)throw new ee("`%` may not be present anywhere but at the beginning and end of the intrinsic name");var n=fo(e),o=n.length>0?n[0]:"",i=po("%"+o+"%",r),a=i.name,s=i.value,u=!1,c=i.alias;c&&(o=c[0],so(n,ao([0,1],c)));for(var f=1,d=!0;f<n.length;f+=1){var y=n[f],h=$e(y,0,1),p=$e(y,-1);if((h==='"'||h==="'"||h==="`"||p==='"'||p==="'"||p==="`")&&h!==p)throw new ee("property names with quotes must have matching quotes");if((y==="constructor"||!d)&&(u=!0),o+="."+y,a="%"+o+"%",Ue(oe,a))s=oe[a];else if(s!=null){if(!(y in s)){if(!r)throw new te("base intrinsic for "+e+" exists, but the property is not available.");return}if(G&&f+1>=n.length){var m=G(s,y);d=!!m,d&&"get"in m&&!("originalValue"in m.get)?s=m.get:s=s[y]}else d=Ue(s,y),s=s[y];d&&!u&&(oe[a]=s)}}return s},ur={exports:{}};(function(t){var e=nt,r=at,n=r("%Function.prototype.apply%"),o=r("%Function.prototype.call%"),i=r("%Reflect.apply%",!0)||e.call(o,n),a=r("%Object.getOwnPropertyDescriptor%",!0),s=r("%Object.defineProperty%",!0),u=r("%Math.max%");if(s)try{s({},"a",{value:1})}catch{s=null}t.exports=function(d){var y=i(e,o,arguments);if(a&&s){var h=a(y,"length");h.configurable&&s(y,"length",{value:1+u(0,d.length-(arguments.length-1))})}return y};var c=function(){return i(e,n,arguments)};s?s(t.exports,"apply",{value:c}):t.exports.apply=c})(ur);var lr=at,fr=ur.exports,yo=fr(lr("String.prototype.indexOf")),ho=function(e,r){var n=lr(e,!!r);return typeof n=="function"&&yo(e,".prototype.")>-1?fr(n):n};const mo=ln(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));var st=typeof Map=="function"&&Map.prototype,ct=Object.getOwnPropertyDescriptor&&st?Object.getOwnPropertyDescriptor(Map.prototype,"size"):null,Me=st&&ct&&typeof ct.get=="function"?ct.get:null,go=st&&Map.prototype.forEach,ut=typeof Set=="function"&&Set.prototype,lt=Object.getOwnPropertyDescriptor&&ut?Object.getOwnPropertyDescriptor(Set.prototype,"size"):null,Le=ut&&lt&&typeof lt.get=="function"?lt.get:null,So=ut&&Set.prototype.forEach,vo=typeof WeakMap=="function"&&WeakMap.prototype,ge=vo?WeakMap.prototype.has:null,Eo=typeof WeakSet=="function"&&WeakSet.prototype,Se=Eo?WeakSet.prototype.has:null,bo=typeof WeakRef=="function"&&WeakRef.prototype,pr=bo?WeakRef.prototype.deref:null,wo=Boolean.prototype.valueOf,Ro=Object.prototype.toString,Oo=Function.prototype.toString,Ao=String.prototype.match,ft=String.prototype.slice,k=String.prototype.replace,Po=String.prototype.toUpperCase,dr=String.prototype.toLowerCase,yr=RegExp.prototype.test,hr=Array.prototype.concat,_=Array.prototype.join,To=Array.prototype.slice,mr=Math.floor,pt=typeof BigInt=="function"?BigInt.prototype.valueOf:null,dt=Object.getOwnPropertySymbols,yt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Symbol.prototype.toString:null,ie=typeof Symbol=="function"&&typeof Symbol.iterator=="object",O=typeof Symbol=="function"&&Symbol.toStringTag&&(typeof Symbol.toStringTag===ie?"object":"symbol")?Symbol.toStringTag:null,gr=Object.prototype.propertyIsEnumerable,Sr=(typeof Reflect=="function"?Reflect.getPrototypeOf:Object.getPrototypeOf)||([].__proto__===Array.prototype?function(t){return t.__proto__}:null);function vr(t,e){if(t===1/0||t===-1/0||t!==t||t&&t>-1e3&&t<1e3||yr.call(/e/,e))return e;var r=/[0-9](?=(?:[0-9]{3})+(?![0-9]))/g;if(typeof t=="number"){var n=t<0?-mr(-t):mr(t);if(n!==t){var o=String(n),i=ft.call(e,o.length+1);return k.call(o,r,"$&_")+"."+k.call(k.call(i,/([0-9]{3})/g,"$&_"),/_$/,"")}}return k.call(e,r,"$&_")}var ht=mo,Er=ht.custom,br=Or(Er)?Er:null,No=function t(e,r,n,o){var i=r||{};if(j(i,"quoteStyle")&&i.quoteStyle!=="single"&&i.quoteStyle!=="double")throw new TypeError('option "quoteStyle" must be "single" or "double"');if(j(i,"maxStringLength")&&(typeof i.maxStringLength=="number"?i.maxStringLength<0&&i.maxStringLength!==1/0:i.maxStringLength!==null))throw new TypeError('option "maxStringLength", if provided, must be a positive integer, Infinity, or `null`');var a=j(i,"customInspect")?i.customInspect:!0;if(typeof a!="boolean"&&a!=="symbol")throw new TypeError("option \"customInspect\", if provided, must be `true`, `false`, or `'symbol'`");if(j(i,"indent")&&i.indent!==null&&i.indent!==" "&&!(parseInt(i.indent,10)===i.indent&&i.indent>0))throw new TypeError('option "indent" must be "\\t", an integer > 0, or `null`');if(j(i,"numericSeparator")&&typeof i.numericSeparator!="boolean")throw new TypeError('option "numericSeparator", if provided, must be `true` or `false`');var s=i.numericSeparator;if(typeof e>"u")return"undefined";if(e===null)return"null";if(typeof e=="boolean")return e?"true":"false";if(typeof e=="string")return Pr(e,i);if(typeof e=="number"){if(e===0)return 1/0/e>0?"0":"-0";var u=String(e);return s?vr(e,u):u}if(typeof e=="bigint"){var c=String(e)+"n";return s?vr(e,c):c}var f=typeof i.depth>"u"?5:i.depth;if(typeof n>"u"&&(n=0),n>=f&&f>0&&typeof e=="object")return mt(e)?"[Array]":"[Object]";var d=Vo(i,n);if(typeof o>"u")o=[];else if(Ar(o,e)>=0)return"[Circular]";function y(C,z,U){if(z&&(o=To.call(o),o.push(z)),U){var Pe={depth:i.depth};return j(i,"quoteStyle")&&(Pe.quoteStyle=i.quoteStyle),t(C,Pe,n+1,o)}return t(C,i,n+1,o)}if(typeof e=="function"&&!Rr(e)){var h=$o(e),p=ke(e,y);return"[Function"+(h?": "+h:" (anonymous)")+"]"+(p.length>0?" { "+_.call(p,", ")+" }":"")}if(Or(e)){var m=ie?k.call(String(e),/^(Symbol\(.*\))_[^)]*$/,"$1"):yt.call(e);return typeof e=="object"&&!ie?ve(m):m}if(Wo(e)){for(var b="<"+dr.call(String(e.nodeName)),g=e.attributes||[],A=0;A<g.length;A++)b+=" "+g[A].name+"="+wr(xo(g[A].value),"double",i);return b+=">",e.childNodes&&e.childNodes.length&&(b+="..."),b+="</"+dr.call(String(e.nodeName))+">",b}if(mt(e)){if(e.length===0)return"[]";var N=ke(e,y);return d&&!zo(N)?"["+St(N,d)+"]":"[ "+_.call(N,", ")+" ]"}if(Fo(e)){var W=ke(e,y);return!("cause"in Error.prototype)&&"cause"in e&&!gr.call(e,"cause")?"{ ["+String(e)+"] "+_.call(hr.call("[cause]: "+y(e.cause),W),", ")+" }":W.length===0?"["+String(e)+"]":"{ ["+String(e)+"] "+_.call(W,", ")+" }"}if(typeof e=="object"&&a){if(br&&typeof e[br]=="function"&&ht)return ht(e,{depth:f-n});if(a!=="symbol"&&typeof e.inspect=="function")return e.inspect()}if(Mo(e)){var Re=[];return go.call(e,function(C,z){Re.push(y(z,e,!0)+" => "+y(C,e))}),Tr("Map",Me.call(e),Re,d)}if(jo(e)){var Oe=[];return So.call(e,function(C){Oe.push(y(C,e))}),Tr("Set",Le.call(e),Oe,d)}if(Lo(e))return gt("WeakMap");if(qo(e))return gt("WeakSet");if(ko(e))return gt("WeakRef");if(Do(e))return ve(y(Number(e)));if(Io(e))return ve(y(pt.call(e)));if(Bo(e))return ve(wo.call(e));if(Co(e))return ve(y(String(e)));if(!_o(e)&&!Rr(e)){var Q=ke(e,y),Ae=Sr?Sr(e)===Object.prototype:e instanceof Object||e.constructor===Object,H=e instanceof Object?"":"null prototype",le=!Ae&&O&&Object(e)===e&&O in e?ft.call(q(e),8,-1):H?"Object":"",X=Ae||typeof e.constructor!="function"?"":e.constructor.name?e.constructor.name+" ":"",fe=X+(le||H?"["+_.call(hr.call([],le||[],H||[]),": ")+"] ":"");return Q.length===0?fe+"{}":d?fe+"{"+St(Q,d)+"}":fe+"{ "+_.call(Q,", ")+" }"}return String(e)};function wr(t,e,r){var n=(r.quoteStyle||e)==="double"?'"':"'";return n+t+n}function xo(t){return k.call(String(t),/"/g,"&quot;")}function mt(t){return q(t)==="[object Array]"&&(!O||!(typeof t=="object"&&O in t))}function _o(t){return q(t)==="[object Date]"&&(!O||!(typeof t=="object"&&O in t))}function Rr(t){return q(t)==="[object RegExp]"&&(!O||!(typeof t=="object"&&O in t))}function Fo(t){return q(t)==="[object Error]"&&(!O||!(typeof t=="object"&&O in t))}function Co(t){return q(t)==="[object String]"&&(!O||!(typeof t=="object"&&O in t))}function Do(t){return q(t)==="[object Number]"&&(!O||!(typeof t=="object"&&O in t))}function Bo(t){return q(t)==="[object Boolean]"&&(!O||!(typeof t=="object"&&O in t))}function Or(t){if(ie)return t&&typeof t=="object"&&t instanceof Symbol;if(typeof t=="symbol")return!0;if(!t||typeof t!="object"||!yt)return!1;try{return yt.call(t),!0}catch{}return!1}function Io(t){if(!t||typeof t!="object"||!pt)return!1;try{return pt.call(t),!0}catch{}return!1}var Uo=Object.prototype.hasOwnProperty||function(t){return t in this};function j(t,e){return Uo.call(t,e)}function q(t){return Ro.call(t)}function $o(t){if(t.name)return t.name;var e=Ao.call(Oo.call(t),/^function\s*([\w$]+)/);return e?e[1]:null}function Ar(t,e){if(t.indexOf)return t.indexOf(e);for(var r=0,n=t.length;r<n;r++)if(t[r]===e)return r;return-1}function Mo(t){if(!Me||!t||typeof t!="object")return!1;try{Me.call(t);try{Le.call(t)}catch{return!0}return t instanceof Map}catch{}return!1}function Lo(t){if(!ge||!t||typeof t!="object")return!1;try{ge.call(t,ge);try{Se.call(t,Se)}catch{return!0}return t instanceof WeakMap}catch{}return!1}function ko(t){if(!pr||!t||typeof t!="object")return!1;try{return pr.call(t),!0}catch{}return!1}function jo(t){if(!Le||!t||typeof t!="object")return!1;try{Le.call(t);try{Me.call(t)}catch{return!0}return t instanceof Set}catch{}return!1}function qo(t){if(!Se||!t||typeof t!="object")return!1;try{Se.call(t,Se);try{ge.call(t,ge)}catch{return!0}return t instanceof WeakSet}catch{}return!1}function Wo(t){return!t||typeof t!="object"?!1:typeof HTMLElement<"u"&&t instanceof HTMLElement?!0:typeof t.nodeName=="string"&&typeof t.getAttribute=="function"}function Pr(t,e){if(t.length>e.maxStringLength){var r=t.length-e.maxStringLength,n="... "+r+" more character"+(r>1?"s":"");return Pr(ft.call(t,0,e.maxStringLength),e)+n}var o=k.call(k.call(t,/(['\\])/g,"\\$1"),/[\x00-\x1f]/g,Ho);return wr(o,"single",e)}function Ho(t){var e=t.charCodeAt(0),r={8:"b",9:"t",10:"n",12:"f",13:"r"}[e];return r?"\\"+r:"\\x"+(e<16?"0":"")+Po.call(e.toString(16))}function ve(t){return"Object("+t+")"}function gt(t){return t+" { ? }"}function Tr(t,e,r,n){var o=n?St(r,n):_.call(r,", ");return t+" ("+e+") {"+o+"}"}function zo(t){for(var e=0;e<t.length;e++)if(Ar(t[e],` `)>=0)return!1;return!0}function Vo(t,e){var r;if(t.indent===" ")r=" ";else if(typeof t.indent=="number"&&t.indent>0)r=_.call(Array(t.indent+1)," ");else return null;return{base:r,prev:_.call(Array(e+1),r)}}function St(t,e){if(t.length===0)return"";var r=` `+e.prev+e.base;return r+_.call(t,","+r)+` `+e.prev}function ke(t,e){var r=mt(t),n=[];if(r){n.length=t.length;for(var o=0;o<t.length;o++)n[o]=j(t,o)?e(t[o],t):""}var i=typeof dt=="function"?dt(t):[],a;if(ie){a={};for(var s=0;s<i.length;s++)a["$"+i[s]]=i[s]}for(var u in t)!j(t,u)||r&&String(Number(u))===u&&u<t.length||ie&&a["$"+u]instanceof Symbol||(yr.call(/[^\w$]/,u)?n.push(e(u,t)+": "+e(t[u],t)):n.push(u+": "+e(t[u],t)));if(typeof dt=="function")for(var c=0;c<i.length;c++)gr.call(t,i[c])&&n.push("["+e(i[c])+"]: "+e(t[i[c]],t));return n}var vt=at,ae=ho,Jo=No,Go=vt("%TypeError%"),je=vt("%WeakMap%",!0),qe=vt("%Map%",!0),Ko=ae("WeakMap.prototype.get",!0),Qo=ae("WeakMap.prototype.set",!0),Xo=ae("WeakMap.prototype.has",!0),Yo=ae("Map.prototype.get",!0),Zo=ae("Map.prototype.set",!0),ei=ae("Map.prototype.has",!0),Et=function(t,e){for(var r=t,n;(n=r.next)!==null;r=n)if(n.key===e)return r.next=n.next,n.next=t.next,t.next=n,n},ti=function(t,e){var r=Et(t,e);return r&&r.value},ri=function(t,e,r){var n=Et(t,e);n?n.value=r:t.next={key:e,next:t.next,value:r}},ni=function(t,e){return!!Et(t,e)},oi=function(){var e,r,n,o={assert:function(i){if(!o.has(i))throw new Go("Side channel does not contain "+Jo(i))},get:function(i){if(je&&i&&(typeof i=="object"||typeof i=="function")){if(e)return Ko(e,i)}else if(qe){if(r)return Yo(r,i)}else if(n)return ti(n,i)},has:function(i){if(je&&i&&(typeof i=="object"||typeof i=="function")){if(e)return Xo(e,i)}else if(qe){if(r)return ei(r,i)}else if(n)return ni(n,i);return!1},set:function(i,a){je&&i&&(typeof i=="object"||typeof i=="function")?(e||(e=new je),Qo(e,i,a)):qe?(r||(r=new qe),Zo(r,i,a)):(n||(n={key:{},next:null}),ri(n,i,a))}};return o},ii=String.prototype.replace,ai=/%20/g,bt={RFC1738:"RFC1738",RFC3986:"RFC3986"},wt={default:bt.RFC3986,formatters:{RFC1738:function(t){return ii.call(t,ai,"+")},RFC3986:function(t){return String(t)}},RFC1738:bt.RFC1738,RFC3986:bt.RFC3986},si=wt,Rt=Object.prototype.hasOw