mirror of
https://github.com/pyMC-dev/pyMC_Repeater.git
synced 2026-07-06 01:42:41 +02:00
7 lines
47 KiB
JavaScript
7 lines
47 KiB
JavaScript
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/Setup-CLakpAbC.js","assets/_plugin-vue_export-helper-V-yks4gF.js","assets/index-COnQNCNU.js","assets/runtime-core.esm-bundler-IofF4kUm.js","assets/pinia-BrpcNUEi.js","assets/vue-router-BsDVl_JC.js","assets/useTheme-Dlt6-wEf.js","assets/packets-BgkeSYWF.js","assets/system-CBL1eQwL.js","assets/index-B4rh8qna.css","assets/Setup-DiRq9fgD.css","assets/Login-Blyk2DC-.js","assets/Login-CnKimFst.css","assets/Dashboard-C2KOv1xv.js","assets/chart-DdrINt9G.js","assets/useSignalQuality-Ba7UKIMT.js","assets/preferences-N3Pls1rF.js","assets/Dashboard-DSGgVlK8.css","assets/Neighbors-CweA4a8-.js","assets/chunk-DECur_0Z.js","assets/leaflet-src-BtX0-WJ4.js","assets/Neighbors-Cfo189NY.css","assets/leaflet-vh-t_kPv.css","assets/Statistics-CdCqGf-R.js","assets/chartjs-adapter-date-fns.esm-CONKmChq.js","assets/chartjs-adapter-date-fns-BqJ94ASW.css","assets/plotly.min-Bnm7le34.js","assets/Statistics-2MFwNAp1.css","assets/SystemStats-BAQfEFAL.js","assets/SystemStats-Dnc1_s5j.css","assets/Configuration-wjLY-p5X.js","assets/ConfirmDialog-DTcx-vUm.js","assets/Configuration-zQuuYGWe.css","assets/CADCalibration-DelGuTVC.js","assets/CADCalibration-gZQwotT3.css","assets/Sessions-BNJTLm-h.js","assets/RoomServers-dEkm3wdT.js","assets/MessageDialog-wVRlgpFS.js","assets/Companions-Bwhq-9tt.js","assets/Logs-DBa052V2.js","assets/Terminal-CaqQ_zLY.js","assets/Terminal-tmed9q5z.css","assets/Help-1i4KzGWQ.js"])))=>i.map(i=>d[i]);
|
|
import{n as e}from"./chunk-DECur_0Z.js";import{n as t,t as n}from"./vue-router-BsDVl_JC.js";function r(e,t){return function(){return e.apply(t,arguments)}}var{toString:i}=Object.prototype,{getPrototypeOf:a}=Object,{iterator:o,toStringTag:s}=Symbol,c=(e=>t=>{let n=i.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),l=e=>(e=e.toLowerCase(),t=>c(t)===e),u=e=>t=>typeof t===e,{isArray:d}=Array,f=u(`undefined`);function p(e){return e!==null&&!f(e)&&e.constructor!==null&&!f(e.constructor)&&_(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}var m=l(`ArrayBuffer`);function h(e){let t;return t=typeof ArrayBuffer<`u`&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&m(e.buffer),t}var g=u(`string`),_=u(`function`),v=u(`number`),y=e=>typeof e==`object`&&!!e,ee=e=>e===!0||e===!1,b=e=>{if(c(e)!==`object`)return!1;let t=a(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(s in e)&&!(o in e)},x=e=>{if(!y(e)||p(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},S=l(`Date`),C=l(`File`),te=e=>!!(e&&e.uri!==void 0),ne=e=>e&&e.getParts!==void 0,re=l(`Blob`),ie=l(`FileList`),ae=e=>y(e)&&_(e.pipe);function oe(){return typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:typeof global<`u`?global:{}}var se=oe(),ce=se.FormData===void 0?void 0:se.FormData,le=e=>{let t;return e&&(ce&&e instanceof ce||_(e.append)&&((t=c(e))===`formdata`||t===`object`&&_(e.toString)&&e.toString()===`[object FormData]`))},ue=l(`URLSearchParams`),[de,fe,pe,me]=[`ReadableStream`,`Request`,`Response`,`Headers`].map(l),he=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,``);function w(e,t,{allOwnKeys:n=!1}={}){if(e==null)return;let r,i;if(typeof e!=`object`&&(e=[e]),d(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{if(p(e))return;let i=n?Object.getOwnPropertyNames(e):Object.keys(e),a=i.length,o;for(r=0;r<a;r++)o=i[r],t.call(null,e[o],o,e)}}function ge(e,t){if(p(e))return null;t=t.toLowerCase();let n=Object.keys(e),r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}var T=typeof globalThis<`u`?globalThis:typeof self<`u`?self:typeof window<`u`?window:global,_e=e=>!f(e)&&e!==T;function ve(){let{caseless:e,skipUndefined:t}=_e(this)&&this||{},n={},r=(r,i)=>{if(i===`__proto__`||i===`constructor`||i===`prototype`)return;let a=e&&ge(n,i)||i;b(n[a])&&b(r)?n[a]=ve(n[a],r):b(r)?n[a]=ve({},r):d(r)?n[a]=r.slice():(!t||!f(r))&&(n[a]=r)};for(let e=0,t=arguments.length;e<t;e++)arguments[e]&&w(arguments[e],r);return n}var ye=(e,t,n,{allOwnKeys:i}={})=>(w(t,(t,i)=>{n&&_(t)?Object.defineProperty(e,i,{value:r(t,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,i,{value:t,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:i}),e),be=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),xe=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,`constructor`,{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,`super`,{value:t.prototype}),n&&Object.assign(e.prototype,n)},Se=(e,t,n,r)=>{let i,o,s,c={};if(t||={},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),o=i.length;o-- >0;)s=i[o],(!r||r(s,e,t))&&!c[s]&&(t[s]=e[s],c[s]=!0);e=n!==!1&&a(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Ce=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;let r=e.indexOf(t,n);return r!==-1&&r===n},we=e=>{if(!e)return null;if(d(e))return e;let t=e.length;if(!v(t))return null;let n=Array(t);for(;t-- >0;)n[t]=e[t];return n},Te=(e=>t=>e&&t instanceof e)(typeof Uint8Array<`u`&&a(Uint8Array)),Ee=(e,t)=>{let n=(e&&e[o]).call(e),r;for(;(r=n.next())&&!r.done;){let n=r.value;t.call(e,n[0],n[1])}},De=(e,t)=>{let n,r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},Oe=l(`HTMLFormElement`),ke=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(e,t,n){return t.toUpperCase()+n}),Ae=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),je=l(`RegExp`),Me=(e,t)=>{let n=Object.getOwnPropertyDescriptors(e),r={};w(n,(n,i)=>{let a;(a=t(n,i,e))!==!1&&(r[i]=a||n)}),Object.defineProperties(e,r)},Ne=e=>{Me(e,(t,n)=>{if(_(e)&&[`arguments`,`caller`,`callee`].indexOf(n)!==-1)return!1;let r=e[n];if(_(r)){if(t.enumerable=!1,`writable`in t){t.writable=!1;return}t.set||=()=>{throw Error(`Can not rewrite read-only method '`+n+`'`)}}})},Pe=(e,t)=>{let n={},r=e=>{e.forEach(e=>{n[e]=!0})};return d(e)?r(e):r(String(e).split(t)),n},Fe=()=>{},Ie=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Le(e){return!!(e&&_(e.append)&&e[s]===`FormData`&&e[o])}var Re=e=>{let t=Array(10),n=(e,r)=>{if(y(e)){if(t.indexOf(e)>=0)return;if(p(e))return e;if(!(`toJSON`in e)){t[r]=e;let i=d(e)?[]:{};return w(e,(e,t)=>{let a=n(e,r+1);!f(a)&&(i[t]=a)}),t[r]=void 0,i}}return e};return n(e,0)},ze=l(`AsyncFunction`),Be=e=>e&&(y(e)||_(e))&&_(e.then)&&_(e.catch),Ve=((e,t)=>e?setImmediate:t?((e,t)=>(T.addEventListener(`message`,({source:n,data:r})=>{n===T&&r===e&&t.length&&t.shift()()},!1),n=>{t.push(n),T.postMessage(e,`*`)}))(`axios@${Math.random()}`,[]):e=>setTimeout(e))(typeof setImmediate==`function`,_(T.postMessage)),E={isArray:d,isArrayBuffer:m,isBuffer:p,isFormData:le,isArrayBufferView:h,isString:g,isNumber:v,isBoolean:ee,isObject:y,isPlainObject:b,isEmptyObject:x,isReadableStream:de,isRequest:fe,isResponse:pe,isHeaders:me,isUndefined:f,isDate:S,isFile:C,isReactNativeBlob:te,isReactNative:ne,isBlob:re,isRegExp:je,isFunction:_,isStream:ae,isURLSearchParams:ue,isTypedArray:Te,isFileList:ie,forEach:w,merge:ve,extend:ye,trim:he,stripBOM:be,inherits:xe,toFlatObject:Se,kindOf:c,kindOfTest:l,endsWith:Ce,toArray:we,forEachEntry:Ee,matchAll:De,isHTMLForm:Oe,hasOwnProperty:Ae,hasOwnProp:Ae,reduceDescriptors:Me,freezeMethods:Ne,toObjectSet:Pe,toCamelCase:ke,noop:Fe,toFiniteNumber:Ie,findKey:ge,global:T,isContextDefined:_e,isSpecCompliantForm:Le,toJSONObject:Re,isAsyncFn:ze,isThenable:Be,setImmediate:Ve,asap:typeof queueMicrotask<`u`?queueMicrotask.bind(T):typeof process<`u`&&process.nextTick||Ve,isIterable:e=>e!=null&&_(e[o])},D=class e extends Error{static from(t,n,r,i,a,o){let s=new e(t.message,n||t.code,r,i,a);return s.cause=t,s.name=t.name,t.status!=null&&s.status==null&&(s.status=t.status),o&&Object.assign(s,o),s}constructor(e,t,n,r,i){super(e),Object.defineProperty(this,`message`,{value:e,enumerable:!0,writable:!0,configurable:!0}),this.name=`AxiosError`,this.isAxiosError=!0,t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i,this.status=i.status)}toJSON(){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:E.toJSONObject(this.config),code:this.code,status:this.status}}};D.ERR_BAD_OPTION_VALUE=`ERR_BAD_OPTION_VALUE`,D.ERR_BAD_OPTION=`ERR_BAD_OPTION`,D.ECONNABORTED=`ECONNABORTED`,D.ETIMEDOUT=`ETIMEDOUT`,D.ERR_NETWORK=`ERR_NETWORK`,D.ERR_FR_TOO_MANY_REDIRECTS=`ERR_FR_TOO_MANY_REDIRECTS`,D.ERR_DEPRECATED=`ERR_DEPRECATED`,D.ERR_BAD_RESPONSE=`ERR_BAD_RESPONSE`,D.ERR_BAD_REQUEST=`ERR_BAD_REQUEST`,D.ERR_CANCELED=`ERR_CANCELED`,D.ERR_NOT_SUPPORT=`ERR_NOT_SUPPORT`,D.ERR_INVALID_URL=`ERR_INVALID_URL`;function O(e){return E.isPlainObject(e)||E.isArray(e)}function He(e){return E.endsWith(e,`[]`)?e.slice(0,-2):e}function k(e,t,n){return e?e.concat(t).map(function(e,t){return e=He(e),!n&&t?`[`+e+`]`:e}).join(n?`.`:``):t}function Ue(e){return E.isArray(e)&&!e.some(O)}var We=E.toFlatObject(E,{},null,function(e){return/^is[A-Z]/.test(e)});function A(e,t,n){if(!E.isObject(e))throw TypeError(`target must be an object`);t||=new FormData,n=E.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(e,t){return!E.isUndefined(t[e])});let r=n.metaTokens,i=n.visitor||l,a=n.dots,o=n.indexes,s=(n.Blob||typeof Blob<`u`&&Blob)&&E.isSpecCompliantForm(t);if(!E.isFunction(i))throw TypeError(`visitor must be a function`);function c(e){if(e===null)return``;if(E.isDate(e))return e.toISOString();if(E.isBoolean(e))return e.toString();if(!s&&E.isBlob(e))throw new D(`Blob is not supported. Use a Buffer instead.`);return E.isArrayBuffer(e)||E.isTypedArray(e)?s&&typeof Blob==`function`?new Blob([e]):Buffer.from(e):e}function l(e,n,i){let s=e;if(E.isReactNative(t)&&E.isReactNativeBlob(e))return t.append(k(i,n,a),c(e)),!1;if(e&&!i&&typeof e==`object`){if(E.endsWith(n,`{}`))n=r?n:n.slice(0,-2),e=JSON.stringify(e);else if(E.isArray(e)&&Ue(e)||(E.isFileList(e)||E.endsWith(n,`[]`))&&(s=E.toArray(e)))return n=He(n),s.forEach(function(e,r){!(E.isUndefined(e)||e===null)&&t.append(o===!0?k([n],r,a):o===null?n:n+`[]`,c(e))}),!1}return O(e)?!0:(t.append(k(i,n,a),c(e)),!1)}let u=[],d=Object.assign(We,{defaultVisitor:l,convertValue:c,isVisitable:O});function f(e,n){if(!E.isUndefined(e)){if(u.indexOf(e)!==-1)throw Error(`Circular reference detected in `+n.join(`.`));u.push(e),E.forEach(e,function(e,r){(!(E.isUndefined(e)||e===null)&&i.call(t,e,E.isString(r)?r.trim():r,n,d))===!0&&f(e,n?n.concat(r):[r])}),u.pop()}}if(!E.isObject(e))throw TypeError(`data must be an object`);return f(e),t}function Ge(e){let t={"!":`%21`,"'":`%27`,"(":`%28`,")":`%29`,"~":`%7E`,"%20":`+`,"%00":`\0`};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(e){return t[e]})}function j(e,t){this._pairs=[],e&&A(e,this,t)}var Ke=j.prototype;Ke.append=function(e,t){this._pairs.push([e,t])},Ke.toString=function(e){let t=e?function(t){return e.call(this,t,Ge)}:Ge;return this._pairs.map(function(e){return t(e[0])+`=`+t(e[1])},``).join(`&`)};function qe(e){return encodeURIComponent(e).replace(/%3A/gi,`:`).replace(/%24/g,`$`).replace(/%2C/gi,`,`).replace(/%20/g,`+`)}function Je(e,t,n){if(!t)return e;let r=n&&n.encode||qe,i=E.isFunction(n)?{serialize:n}:n,a=i&&i.serialize,o;if(o=a?a(t,i):E.isURLSearchParams(t)?t.toString():new j(t,i).toString(r),o){let t=e.indexOf(`#`);t!==-1&&(e=e.slice(0,t)),e+=(e.indexOf(`?`)===-1?`?`:`&`)+o}return e}var Ye=class{constructor(){this.handlers=[]}use(e,t,n){return this.handlers.push({fulfilled:e,rejected:t,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&&=[]}forEach(e){E.forEach(this.handlers,function(t){t!==null&&e(t)})}},Xe={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},Ze={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<`u`?URLSearchParams:j,FormData:typeof FormData<`u`?FormData:null,Blob:typeof Blob<`u`?Blob:null},protocols:[`http`,`https`,`file`,`blob`,`url`,`data`]},Qe=e({hasBrowserEnv:()=>$e,hasStandardBrowserEnv:()=>tt,hasStandardBrowserWebWorkerEnv:()=>nt,navigator:()=>et,origin:()=>rt}),$e=typeof window<`u`&&typeof document<`u`,et=typeof navigator==`object`&&navigator||void 0,tt=$e&&(!et||[`ReactNative`,`NativeScript`,`NS`].indexOf(et.product)<0),nt=typeof WorkerGlobalScope<`u`&&self instanceof WorkerGlobalScope&&typeof self.importScripts==`function`,rt=$e&&window.location.href||`http://localhost`,M={...Qe,...Ze};function it(e,t){return A(e,new M.classes.URLSearchParams,{visitor:function(e,t,n,r){return M.isNode&&E.isBuffer(e)?(this.append(t,e.toString(`base64`)),!1):r.defaultVisitor.apply(this,arguments)},...t})}function at(e){return E.matchAll(/\w+|\[(\w*)]/g,e).map(e=>e[0]===`[]`?``:e[1]||e[0])}function ot(e){let t={},n=Object.keys(e),r,i=n.length,a;for(r=0;r<i;r++)a=n[r],t[a]=e[a];return t}function st(e){function t(e,n,r,i){let a=e[i++];if(a===`__proto__`)return!0;let o=Number.isFinite(+a),s=i>=e.length;return a=!a&&E.isArray(r)?r.length:a,s?(E.hasOwnProp(r,a)?r[a]=[r[a],n]:r[a]=n,!o):((!r[a]||!E.isObject(r[a]))&&(r[a]=[]),t(e,n,r[a],i)&&E.isArray(r[a])&&(r[a]=ot(r[a])),!o)}if(E.isFormData(e)&&E.isFunction(e.entries)){let n={};return E.forEachEntry(e,(e,r)=>{t(at(e),r,n,0)}),n}return null}function ct(e,t,n){if(E.isString(e))try{return(t||JSON.parse)(e),E.trim(e)}catch(e){if(e.name!==`SyntaxError`)throw e}return(n||JSON.stringify)(e)}var N={transitional:Xe,adapter:[`xhr`,`http`,`fetch`],transformRequest:[function(e,t){let n=t.getContentType()||``,r=n.indexOf(`application/json`)>-1,i=E.isObject(e);if(i&&E.isHTMLForm(e)&&(e=new FormData(e)),E.isFormData(e))return r?JSON.stringify(st(e)):e;if(E.isArrayBuffer(e)||E.isBuffer(e)||E.isStream(e)||E.isFile(e)||E.isBlob(e)||E.isReadableStream(e))return e;if(E.isArrayBufferView(e))return e.buffer;if(E.isURLSearchParams(e))return t.setContentType(`application/x-www-form-urlencoded;charset=utf-8`,!1),e.toString();let a;if(i){if(n.indexOf(`application/x-www-form-urlencoded`)>-1)return it(e,this.formSerializer).toString();if((a=E.isFileList(e))||n.indexOf(`multipart/form-data`)>-1){let t=this.env&&this.env.FormData;return A(a?{"files[]":e}:e,t&&new t,this.formSerializer)}}return i||r?(t.setContentType(`application/json`,!1),ct(e)):e}],transformResponse:[function(e){let t=this.transitional||N.transitional,n=t&&t.forcedJSONParsing,r=this.responseType===`json`;if(E.isResponse(e)||E.isReadableStream(e))return e;if(e&&E.isString(e)&&(n&&!this.responseType||r)){let n=!(t&&t.silentJSONParsing)&&r;try{return JSON.parse(e,this.parseReviver)}catch(e){if(n)throw e.name===`SyntaxError`?D.from(e,D.ERR_BAD_RESPONSE,this,null,this.response):e}}return e}],timeout:0,xsrfCookieName:`XSRF-TOKEN`,xsrfHeaderName:`X-XSRF-TOKEN`,maxContentLength:-1,maxBodyLength:-1,env:{FormData:M.classes.FormData,Blob:M.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:`application/json, text/plain, */*`,"Content-Type":void 0}}};E.forEach([`delete`,`get`,`head`,`post`,`put`,`patch`],e=>{N.headers[e]={}});var lt=E.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`]),ut=e=>{let t={},n,r,i;return e&&e.split(`
|
|
`).forEach(function(e){i=e.indexOf(`:`),n=e.substring(0,i).trim().toLowerCase(),r=e.substring(i+1).trim(),!(!n||t[n]&<[n])&&(n===`set-cookie`?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+`, `+r:r)}),t},dt=Symbol(`internals`);function P(e){return e&&String(e).trim().toLowerCase()}function F(e){return e===!1||e==null?e:E.isArray(e)?e.map(F):String(e).replace(/[\r\n]+$/,``)}function ft(e){let t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g,r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}var pt=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function mt(e,t,n,r,i){if(E.isFunction(r))return r.call(this,t,n);if(i&&(t=n),E.isString(t)){if(E.isString(r))return t.indexOf(r)!==-1;if(E.isRegExp(r))return r.test(t)}}function ht(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,t,n)=>t.toUpperCase()+n)}function gt(e,t){let n=E.toCamelCase(` `+t);[`get`,`set`,`has`].forEach(r=>{Object.defineProperty(e,r+n,{value:function(e,n,i){return this[r].call(this,t,e,n,i)},configurable:!0})})}var I=class{constructor(e){e&&this.set(e)}set(e,t,n){let r=this;function i(e,t,n){let i=P(t);if(!i)throw Error(`header name must be a non-empty string`);let a=E.findKey(r,i);(!a||r[a]===void 0||n===!0||n===void 0&&r[a]!==!1)&&(r[a||t]=F(e))}let a=(e,t)=>E.forEach(e,(e,n)=>i(e,n,t));if(E.isPlainObject(e)||e instanceof this.constructor)a(e,t);else if(E.isString(e)&&(e=e.trim())&&!pt(e))a(ut(e),t);else if(E.isObject(e)&&E.isIterable(e)){let n={},r,i;for(let t of e){if(!E.isArray(t))throw TypeError(`Object iterator must return a key-value pair`);n[i=t[0]]=(r=n[i])?E.isArray(r)?[...r,t[1]]:[r,t[1]]:t[1]}a(n,t)}else e!=null&&i(t,e,n);return this}get(e,t){if(e=P(e),e){let n=E.findKey(this,e);if(n){let e=this[n];if(!t)return e;if(t===!0)return ft(e);if(E.isFunction(t))return t.call(this,e,n);if(E.isRegExp(t))return t.exec(e);throw TypeError(`parser must be boolean|regexp|function`)}}}has(e,t){if(e=P(e),e){let n=E.findKey(this,e);return!!(n&&this[n]!==void 0&&(!t||mt(this,this[n],n,t)))}return!1}delete(e,t){let n=this,r=!1;function i(e){if(e=P(e),e){let i=E.findKey(n,e);i&&(!t||mt(n,n[i],i,t))&&(delete n[i],r=!0)}}return E.isArray(e)?e.forEach(i):i(e),r}clear(e){let t=Object.keys(this),n=t.length,r=!1;for(;n--;){let i=t[n];(!e||mt(this,this[i],i,e,!0))&&(delete this[i],r=!0)}return r}normalize(e){let t=this,n={};return E.forEach(this,(r,i)=>{let a=E.findKey(n,i);if(a){t[a]=F(r),delete t[i];return}let o=e?ht(i):String(i).trim();o!==i&&delete t[i],t[o]=F(r),n[o]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){let t=Object.create(null);return E.forEach(this,(n,r)=>{n!=null&&n!==!1&&(t[r]=e&&E.isArray(n)?n.join(`, `):n)}),t}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,t])=>e+`: `+t).join(`
|
|
`)}getSetCookie(){return this.get(`set-cookie`)||[]}get[Symbol.toStringTag](){return`AxiosHeaders`}static from(e){return e instanceof this?e:new this(e)}static concat(e,...t){let n=new this(e);return t.forEach(e=>n.set(e)),n}static accessor(e){let t=(this[dt]=this[dt]={accessors:{}}).accessors,n=this.prototype;function r(e){let r=P(e);t[r]||(gt(n,e),t[r]=!0)}return E.isArray(e)?e.forEach(r):r(e),this}};I.accessor([`Content-Type`,`Content-Length`,`Accept`,`Accept-Encoding`,`User-Agent`,`Authorization`]),E.reduceDescriptors(I.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(e){this[n]=e}}}),E.freezeMethods(I);function _t(e,t){let n=this||N,r=t||n,i=I.from(r.headers),a=r.data;return E.forEach(e,function(e){a=e.call(n,a,i.normalize(),t?t.status:void 0)}),i.normalize(),a}function vt(e){return!!(e&&e.__CANCEL__)}var L=class extends D{constructor(e,t,n){super(e??`canceled`,D.ERR_CANCELED,t,n),this.name=`CanceledError`,this.__CANCEL__=!0}};function yt(e,t,n){let r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new D(`Request failed with status code `+n.status,[D.ERR_BAD_REQUEST,D.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function bt(e){let t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||``}function xt(e,t){e||=10;let n=Array(e),r=Array(e),i=0,a=0,o;return t=t===void 0?1e3:t,function(s){let c=Date.now(),l=r[a];o||=c,n[i]=s,r[i]=c;let u=a,d=0;for(;u!==i;)d+=n[u++],u%=e;if(i=(i+1)%e,i===a&&(a=(a+1)%e),c-o<t)return;let f=l&&c-l;return f?Math.round(d*1e3/f):void 0}}function St(e,t){let n=0,r=1e3/t,i,a,o=(t,r=Date.now())=>{n=r,i=null,a&&=(clearTimeout(a),null),e(...t)};return[(...e)=>{let t=Date.now(),s=t-n;s>=r?o(e,t):(i=e,a||=setTimeout(()=>{a=null,o(i)},r-s))},()=>i&&o(i)]}var R=(e,t,n=3)=>{let r=0,i=xt(50,250);return St(n=>{let a=n.loaded,o=n.lengthComputable?n.total:void 0,s=a-r,c=i(s),l=a<=o;r=a,e({loaded:a,total:o,progress:o?a/o:void 0,bytes:s,rate:c||void 0,estimated:c&&o&&l?(o-a)/c:void 0,event:n,lengthComputable:o!=null,[t?`download`:`upload`]:!0})},n)},Ct=(e,t)=>{let n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},wt=e=>(...t)=>E.asap(()=>e(...t)),Tt=M.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,M.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(M.origin),M.navigator&&/(msie|trident)/i.test(M.navigator.userAgent)):()=>!0,Et=M.hasStandardBrowserEnv?{write(e,t,n,r,i,a,o){if(typeof document>`u`)return;let s=[`${e}=${encodeURIComponent(t)}`];E.isNumber(n)&&s.push(`expires=${new Date(n).toUTCString()}`),E.isString(r)&&s.push(`path=${r}`),E.isString(i)&&s.push(`domain=${i}`),a===!0&&s.push(`secure`),E.isString(o)&&s.push(`SameSite=${o}`),document.cookie=s.join(`; `)},read(e){if(typeof document>`u`)return null;let t=document.cookie.match(RegExp(`(?:^|; )`+e+`=([^;]*)`));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,``,Date.now()-864e5,`/`)}}:{write(){},read(){return null},remove(){}};function Dt(e){return typeof e==`string`?/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e):!1}function Ot(e,t){return t?e.replace(/\/?\/$/,``)+`/`+t.replace(/^\/+/,``):e}function kt(e,t,n){let r=!Dt(t);return e&&(r||n==0)?Ot(e,t):t}var At=e=>e instanceof I?{...e}:e;function z(e,t){t||={};let n={};function r(e,t,n,r){return E.isPlainObject(e)&&E.isPlainObject(t)?E.merge.call({caseless:r},e,t):E.isPlainObject(t)?E.merge({},t):E.isArray(t)?t.slice():t}function i(e,t,n,i){if(!E.isUndefined(t))return r(e,t,n,i);if(!E.isUndefined(e))return r(void 0,e,n,i)}function a(e,t){if(!E.isUndefined(t))return r(void 0,t)}function o(e,t){if(!E.isUndefined(t))return r(void 0,t);if(!E.isUndefined(e))return r(void 0,e)}function s(n,i,a){if(a in t)return r(n,i);if(a in e)return r(void 0,n)}let c={url:a,method:a,data:a,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:s,headers:(e,t,n)=>i(At(e),At(t),n,!0)};return E.forEach(Object.keys({...e,...t}),function(r){if(r===`__proto__`||r===`constructor`||r===`prototype`)return;let a=E.hasOwnProp(c,r)?c[r]:i,o=a(e[r],t[r],r);E.isUndefined(o)&&a!==s||(n[r]=o)}),n}var jt=e=>{let t=z({},e),{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:a,headers:o,auth:s}=t;if(t.headers=o=I.from(o),t.url=Je(kt(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),s&&o.set(`Authorization`,`Basic `+btoa((s.username||``)+`:`+(s.password?unescape(encodeURIComponent(s.password)):``))),E.isFormData(n)){if(M.hasStandardBrowserEnv||M.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(E.isFunction(n.getHeaders)){let e=n.getHeaders(),t=[`content-type`,`content-length`];Object.entries(e).forEach(([e,n])=>{t.includes(e.toLowerCase())&&o.set(e,n)})}}if(M.hasStandardBrowserEnv&&(r&&E.isFunction(r)&&(r=r(t)),r||r!==!1&&Tt(t.url))){let e=i&&a&&Et.read(a);e&&o.set(i,e)}return t},Mt=typeof XMLHttpRequest<`u`&&function(e){return new Promise(function(t,n){let r=jt(e),i=r.data,a=I.from(r.headers).normalize(),{responseType:o,onUploadProgress:s,onDownloadProgress:c}=r,l,u,d,f,p;function m(){f&&f(),p&&p(),r.cancelToken&&r.cancelToken.unsubscribe(l),r.signal&&r.signal.removeEventListener(`abort`,l)}let h=new XMLHttpRequest;h.open(r.method.toUpperCase(),r.url,!0),h.timeout=r.timeout;function g(){if(!h)return;let r=I.from(`getAllResponseHeaders`in h&&h.getAllResponseHeaders());yt(function(e){t(e),m()},function(e){n(e),m()},{data:!o||o===`text`||o===`json`?h.responseText:h.response,status:h.status,statusText:h.statusText,headers:r,config:e,request:h}),h=null}`onloadend`in h?h.onloadend=g:h.onreadystatechange=function(){!h||h.readyState!==4||h.status===0&&!(h.responseURL&&h.responseURL.indexOf(`file:`)===0)||setTimeout(g)},h.onabort=function(){h&&=(n(new D(`Request aborted`,D.ECONNABORTED,e,h)),null)},h.onerror=function(t){let r=new D(t&&t.message?t.message:`Network Error`,D.ERR_NETWORK,e,h);r.event=t||null,n(r),h=null},h.ontimeout=function(){let t=r.timeout?`timeout of `+r.timeout+`ms exceeded`:`timeout exceeded`,i=r.transitional||Xe;r.timeoutErrorMessage&&(t=r.timeoutErrorMessage),n(new D(t,i.clarifyTimeoutError?D.ETIMEDOUT:D.ECONNABORTED,e,h)),h=null},i===void 0&&a.setContentType(null),`setRequestHeader`in h&&E.forEach(a.toJSON(),function(e,t){h.setRequestHeader(t,e)}),E.isUndefined(r.withCredentials)||(h.withCredentials=!!r.withCredentials),o&&o!==`json`&&(h.responseType=r.responseType),c&&([d,p]=R(c,!0),h.addEventListener(`progress`,d)),s&&h.upload&&([u,f]=R(s),h.upload.addEventListener(`progress`,u),h.upload.addEventListener(`loadend`,f)),(r.cancelToken||r.signal)&&(l=t=>{h&&=(n(!t||t.type?new L(null,e,h):t),h.abort(),null)},r.cancelToken&&r.cancelToken.subscribe(l),r.signal&&(r.signal.aborted?l():r.signal.addEventListener(`abort`,l)));let _=bt(r.url);if(_&&M.protocols.indexOf(_)===-1){n(new D(`Unsupported protocol `+_+`:`,D.ERR_BAD_REQUEST,e));return}h.send(i||null)})},Nt=(e,t)=>{let{length:n}=e=e?e.filter(Boolean):[];if(t||n){let n=new AbortController,r,i=function(e){if(!r){r=!0,o();let t=e instanceof Error?e:this.reason;n.abort(t instanceof D?t:new L(t instanceof Error?t.message:t))}},a=t&&setTimeout(()=>{a=null,i(new D(`timeout of ${t}ms exceeded`,D.ETIMEDOUT))},t),o=()=>{e&&=(a&&clearTimeout(a),a=null,e.forEach(e=>{e.unsubscribe?e.unsubscribe(i):e.removeEventListener(`abort`,i)}),null)};e.forEach(e=>e.addEventListener(`abort`,i));let{signal:s}=n;return s.unsubscribe=()=>E.asap(o),s}},Pt=function*(e,t){let n=e.byteLength;if(!t||n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},Ft=async function*(e,t){for await(let n of It(e))yield*Pt(n,t)},It=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}let t=e.getReader();try{for(;;){let{done:e,value:n}=await t.read();if(e)break;yield n}}finally{await t.cancel()}},Lt=(e,t,n,r)=>{let i=Ft(e,t),a=0,o,s=e=>{o||(o=!0,r&&r(e))};return new ReadableStream({async pull(e){try{let{done:t,value:r}=await i.next();if(t){s(),e.close();return}let o=r.byteLength;n&&n(a+=o),e.enqueue(new Uint8Array(r))}catch(e){throw s(e),e}},cancel(e){return s(e),i.return()}},{highWaterMark:2})},Rt=64*1024,{isFunction:B}=E,zt=(({Request:e,Response:t})=>({Request:e,Response:t}))(E.global),{ReadableStream:Bt,TextEncoder:Vt}=E.global,Ht=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Ut=e=>{e=E.merge.call({skipUndefined:!0},zt,e);let{fetch:t,Request:n,Response:r}=e,i=t?B(t):typeof fetch==`function`,a=B(n),o=B(r);if(!i)return!1;let s=i&&B(Bt),c=i&&(typeof Vt==`function`?(e=>t=>e.encode(t))(new Vt):async e=>new Uint8Array(await new n(e).arrayBuffer())),l=a&&s&&Ht(()=>{let e=!1,t=new Bt,r=new n(M.origin,{body:t,method:`POST`,get duplex(){return e=!0,`half`}}).headers.has(`Content-Type`);return t.cancel(),e&&!r}),u=o&&s&&Ht(()=>E.isReadableStream(new r(``).body)),d={stream:u&&(e=>e.body)};i&&[`text`,`arrayBuffer`,`blob`,`formData`,`stream`].forEach(e=>{!d[e]&&(d[e]=(t,n)=>{let r=t&&t[e];if(r)return r.call(t);throw new D(`Response type '${e}' is not supported`,D.ERR_NOT_SUPPORT,n)})});let f=async e=>{if(e==null)return 0;if(E.isBlob(e))return e.size;if(E.isSpecCompliantForm(e))return(await new n(M.origin,{method:`POST`,body:e}).arrayBuffer()).byteLength;if(E.isArrayBufferView(e)||E.isArrayBuffer(e))return e.byteLength;if(E.isURLSearchParams(e)&&(e+=``),E.isString(e))return(await c(e)).byteLength},p=async(e,t)=>E.toFiniteNumber(e.getContentLength())??f(t);return async e=>{let{url:i,method:o,data:s,signal:c,cancelToken:f,timeout:m,onDownloadProgress:h,onUploadProgress:g,responseType:_,headers:v,withCredentials:y=`same-origin`,fetchOptions:ee}=jt(e),b=t||fetch;_=_?(_+``).toLowerCase():`text`;let x=Nt([c,f&&f.toAbortSignal()],m),S=null,C=x&&x.unsubscribe&&(()=>{x.unsubscribe()}),te;try{if(g&&l&&o!==`get`&&o!==`head`&&(te=await p(v,s))!==0){let e=new n(i,{method:`POST`,body:s,duplex:`half`}),t;if(E.isFormData(s)&&(t=e.headers.get(`content-type`))&&v.setContentType(t),e.body){let[t,n]=Ct(te,R(wt(g)));s=Lt(e.body,Rt,t,n)}}E.isString(y)||(y=y?`include`:`omit`);let t=a&&`credentials`in n.prototype,c={...ee,signal:x,method:o.toUpperCase(),headers:v.normalize().toJSON(),body:s,duplex:`half`,credentials:t?y:void 0};S=a&&new n(i,c);let f=await(a?b(S,ee):b(i,c)),m=u&&(_===`stream`||_===`response`);if(u&&(h||m&&C)){let e={};[`status`,`statusText`,`headers`].forEach(t=>{e[t]=f[t]});let t=E.toFiniteNumber(f.headers.get(`content-length`)),[n,i]=h&&Ct(t,R(wt(h),!0))||[];f=new r(Lt(f.body,Rt,n,()=>{i&&i(),C&&C()}),e)}_||=`text`;let ne=await d[E.findKey(d,_)||`text`](f,e);return!m&&C&&C(),await new Promise((t,n)=>{yt(t,n,{data:ne,headers:I.from(f.headers),status:f.status,statusText:f.statusText,config:e,request:S})})}catch(t){throw C&&C(),t&&t.name===`TypeError`&&/Load failed|fetch/i.test(t.message)?Object.assign(new D(`Network Error`,D.ERR_NETWORK,e,S,t&&t.response),{cause:t.cause||t}):D.from(t,t&&t.code,e,S,t&&t.response)}}},Wt=new Map,Gt=e=>{let t=e&&e.env||{},{fetch:n,Request:r,Response:i}=t,a=[r,i,n],o=a.length,s,c,l=Wt;for(;o--;)s=a[o],c=l.get(s),c===void 0&&l.set(s,c=o?new Map:Ut(t)),l=c;return c};Gt();var Kt={http:null,xhr:Mt,fetch:{get:Gt}};E.forEach(Kt,(e,t)=>{if(e){try{Object.defineProperty(e,`name`,{value:t})}catch{}Object.defineProperty(e,`adapterName`,{value:t})}});var qt=e=>`- ${e}`,Jt=e=>E.isFunction(e)||e===null||e===!1;function Yt(e,t){e=E.isArray(e)?e:[e];let{length:n}=e,r,i,a={};for(let o=0;o<n;o++){r=e[o];let n;if(i=r,!Jt(r)&&(i=Kt[(n=String(r)).toLowerCase()],i===void 0))throw new D(`Unknown adapter '${n}'`);if(i&&(E.isFunction(i)||(i=i.get(t))))break;a[n||`#`+o]=i}if(!i){let e=Object.entries(a).map(([e,t])=>`adapter ${e} `+(t===!1?`is not supported by the environment`:`is not available in the build`));throw new D(`There is no suitable adapter to dispatch the request `+(n?e.length>1?`since :
|
|
`+e.map(qt).join(`
|
|
`):` `+qt(e[0]):`as no adapter specified`),`ERR_NOT_SUPPORT`)}return i}var Xt={getAdapter:Yt,adapters:Kt};function Zt(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new L(null,e)}function Qt(e){return Zt(e),e.headers=I.from(e.headers),e.data=_t.call(e,e.transformRequest),[`post`,`put`,`patch`].indexOf(e.method)!==-1&&e.headers.setContentType(`application/x-www-form-urlencoded`,!1),Xt.getAdapter(e.adapter||N.adapter,e)(e).then(function(t){return Zt(e),t.data=_t.call(e,e.transformResponse,t),t.headers=I.from(t.headers),t},function(t){return vt(t)||(Zt(e),t&&t.response&&(t.response.data=_t.call(e,e.transformResponse,t.response),t.response.headers=I.from(t.response.headers))),Promise.reject(t)})}var $t=`1.14.0`,V={};[`object`,`boolean`,`number`,`function`,`string`,`symbol`].forEach((e,t)=>{V[e]=function(n){return typeof n===e||`a`+(t<1?`n `:` `)+e}});var en={};V.transitional=function(e,t,n){function r(e,t){return`[Axios v`+$t+`] Transitional option '`+e+`'`+t+(n?`. `+n:``)}return(n,i,a)=>{if(e===!1)throw new D(r(i,` has been removed`+(t?` in `+t:``)),D.ERR_DEPRECATED);return t&&!en[i]&&(en[i]=!0,console.warn(r(i,` has been deprecated since v`+t+` and will be removed in the near future`))),e?e(n,i,a):!0}},V.spelling=function(e){return(t,n)=>(console.warn(`${n} is likely a misspelling of ${e}`),!0)};function tn(e,t,n){if(typeof e!=`object`)throw new D(`options must be an object`,D.ERR_BAD_OPTION_VALUE);let r=Object.keys(e),i=r.length;for(;i-- >0;){let a=r[i],o=t[a];if(o){let t=e[a],n=t===void 0||o(t,a,e);if(n!==!0)throw new D(`option `+a+` must be `+n,D.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new D(`Unknown option `+a,D.ERR_BAD_OPTION)}}var H={assertOptions:tn,validators:V},U=H.validators,W=class{constructor(e){this.defaults=e||{},this.interceptors={request:new Ye,response:new Ye}}async request(e,t){try{return await this._request(e,t)}catch(e){if(e instanceof Error){let t={};Error.captureStackTrace?Error.captureStackTrace(t):t=Error();let n=t.stack?t.stack.replace(/^.+\n/,``):``;try{e.stack?n&&!String(e.stack).endsWith(n.replace(/^.+\n.+\n/,``))&&(e.stack+=`
|
|
`+n):e.stack=n}catch{}}throw e}}_request(e,t){typeof e==`string`?(t||={},t.url=e):t=e||{},t=z(this.defaults,t);let{transitional:n,paramsSerializer:r,headers:i}=t;n!==void 0&&H.assertOptions(n,{silentJSONParsing:U.transitional(U.boolean),forcedJSONParsing:U.transitional(U.boolean),clarifyTimeoutError:U.transitional(U.boolean),legacyInterceptorReqResOrdering:U.transitional(U.boolean)},!1),r!=null&&(E.isFunction(r)?t.paramsSerializer={serialize:r}:H.assertOptions(r,{encode:U.function,serialize:U.function},!0)),t.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls===void 0?t.allowAbsoluteUrls=!0:t.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls),H.assertOptions(t,{baseUrl:U.spelling(`baseURL`),withXsrfToken:U.spelling(`withXSRFToken`)},!0),t.method=(t.method||this.defaults.method||`get`).toLowerCase();let a=i&&E.merge(i.common,i[t.method]);i&&E.forEach([`delete`,`get`,`head`,`post`,`put`,`patch`,`common`],e=>{delete i[e]}),t.headers=I.concat(a,i);let o=[],s=!0;this.interceptors.request.forEach(function(e){if(typeof e.runWhen==`function`&&e.runWhen(t)===!1)return;s&&=e.synchronous;let n=t.transitional||Xe;n&&n.legacyInterceptorReqResOrdering?o.unshift(e.fulfilled,e.rejected):o.push(e.fulfilled,e.rejected)});let c=[];this.interceptors.response.forEach(function(e){c.push(e.fulfilled,e.rejected)});let l,u=0,d;if(!s){let e=[Qt.bind(this),void 0];for(e.unshift(...o),e.push(...c),d=e.length,l=Promise.resolve(t);u<d;)l=l.then(e[u++],e[u++]);return l}d=o.length;let f=t;for(;u<d;){let e=o[u++],t=o[u++];try{f=e(f)}catch(e){t.call(this,e);break}}try{l=Qt.call(this,f)}catch(e){return Promise.reject(e)}for(u=0,d=c.length;u<d;)l=l.then(c[u++],c[u++]);return l}getUri(e){return e=z(this.defaults,e),Je(kt(e.baseURL,e.url,e.allowAbsoluteUrls),e.params,e.paramsSerializer)}};E.forEach([`delete`,`get`,`head`,`options`],function(e){W.prototype[e]=function(t,n){return this.request(z(n||{},{method:e,url:t,data:(n||{}).data}))}}),E.forEach([`post`,`put`,`patch`],function(e){function t(t){return function(n,r,i){return this.request(z(i||{},{method:e,headers:t?{"Content-Type":`multipart/form-data`}:{},url:n,data:r}))}}W.prototype[e]=t(),W.prototype[e+`Form`]=t(!0)});var nn=class e{constructor(e){if(typeof e!=`function`)throw TypeError(`executor must be a function.`);let t;this.promise=new Promise(function(e){t=e});let n=this;this.promise.then(e=>{if(!n._listeners)return;let t=n._listeners.length;for(;t-- >0;)n._listeners[t](e);n._listeners=null}),this.promise.then=e=>{let t,r=new Promise(e=>{n.subscribe(e),t=e}).then(e);return r.cancel=function(){n.unsubscribe(t)},r},e(function(e,r,i){n.reason||(n.reason=new L(e,r,i),t(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;let t=this._listeners.indexOf(e);t!==-1&&this._listeners.splice(t,1)}toAbortSignal(){let e=new AbortController,t=t=>{e.abort(t)};return this.subscribe(t),e.signal.unsubscribe=()=>this.unsubscribe(t),e.signal}static source(){let t;return{token:new e(function(e){t=e}),cancel:t}}};function rn(e){return function(t){return e.apply(null,t)}}function an(e){return E.isObject(e)&&e.isAxiosError===!0}var on={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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(on).forEach(([e,t])=>{on[t]=e});function sn(e){let t=new W(e),n=r(W.prototype.request,t);return E.extend(n,W.prototype,t,{allOwnKeys:!0}),E.extend(n,t,null,{allOwnKeys:!0}),n.create=function(t){return sn(z(e,t))},n}var G=sn(N);G.Axios=W,G.CanceledError=L,G.CancelToken=nn,G.isCancel=vt,G.VERSION=$t,G.toFormData=A,G.AxiosError=D,G.Cancel=G.CanceledError,G.all=function(e){return Promise.all(e)},G.spread=rn,G.isAxiosError=an,G.mergeConfig=z,G.AxiosHeaders=I,G.formToJSON=e=>st(E.isHTMLForm(e)?new FormData(e):e),G.getAdapter=Xt.getAdapter,G.HttpStatusCode=on,G.default=G;var K=`pymc_jwt_token`,cn=`pymc_client_id`;function ln(){let e=localStorage.getItem(cn);return e||(e=`${Date.now()}-${Math.random().toString(36).substring(2,15)}`,localStorage.setItem(cn,e)),e}function q(){return localStorage.getItem(K)}function un(e){localStorage.setItem(K,e)}function J(){localStorage.removeItem(K)}function dn(){return q()!==null}function fn(e){try{let t=e.split(`.`)[1].replace(/-/g,`+`).replace(/_/g,`/`),n=decodeURIComponent(atob(t).split(``).map(e=>`%`+(`00`+e.charCodeAt(0).toString(16)).slice(-2)).join(``));return JSON.parse(n)}catch{return null}}function pn(){let e=q();if(!e)return!0;let t=fn(e);return!t||!t.exp?!0:Date.now()>=t.exp*1e3-3e4}function mn(){let e=q();if(!e)return!1;let t=fn(e);if(!t||!t.exp)return!1;let n=t.exp*1e3-Date.now();return n>0&&n<3e5}function hn(){let e=q();if(!e)return null;let t=fn(e);return!t||!t.sub?null:t.sub}var gn=`modulepreload`,_n=function(e){return`/`+e},vn={},Y=function(e,t,n){let r=Promise.resolve();if(t&&t.length>0){let e=document.getElementsByTagName(`link`),i=document.querySelector(`meta[property=csp-nonce]`),a=i?.nonce||i?.getAttribute(`nonce`);function o(e){return Promise.all(e.map(e=>Promise.resolve(e).then(e=>({status:`fulfilled`,value:e}),e=>({status:`rejected`,reason:e}))))}r=o(t.map(t=>{if(t=_n(t,n),t in vn)return;vn[t]=!0;let r=t.endsWith(`.css`),i=r?`[rel="stylesheet"]`:``;if(n)for(let n=e.length-1;n>=0;n--){let i=e[n];if(i.href===t&&(!r||i.rel===`stylesheet`))return}else if(document.querySelector(`link[href="${t}"]${i}`))return;let o=document.createElement(`link`);if(o.rel=r?`stylesheet`:gn,r||(o.as=`script`),o.crossOrigin=``,o.href=t,a&&o.setAttribute(`nonce`,a),document.head.appendChild(o),r)return new Promise((e,n)=>{o.addEventListener(`load`,e),o.addEventListener(`error`,()=>n(Error(`Unable to preload CSS for ${t}`)))})}))}function i(e){let t=new Event(`vite:preloadError`,{cancelable:!0});if(t.payload=e,window.dispatchEvent(t),!t.defaultPrevented)throw e}return r.then(t=>{for(let e of t||[])e.status===`rejected`&&i(e.reason);return e().catch(i)})},X=n({history:t(`/`),routes:[{path:`/setup`,name:`setup`,component:()=>Y(()=>import(`./Setup-CLakpAbC.js`),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10])),meta:{requiresAuth:!1,requiresSetup:!1}},{path:`/login`,name:`login`,component:()=>Y(()=>import(`./Login-Blyk2DC-.js`),__vite__mapDeps([11,1,2,3,4,5,6,7,8,9,12])),meta:{requiresAuth:!1}},{path:`/`,name:`dashboard`,component:()=>Y(()=>import(`./Dashboard-C2KOv1xv.js`),__vite__mapDeps([13,1,2,3,4,5,6,7,8,9,14,15,16,17])),meta:{requiresAuth:!0}},{path:`/neighbors`,name:`neighbors`,component:()=>Y(()=>import(`./Neighbors-CweA4a8-.js`),__vite__mapDeps([18,1,19,2,3,4,5,6,7,8,9,20,15,16,21,22])),meta:{requiresAuth:!0}},{path:`/statistics`,name:`statistics`,component:()=>Y(()=>import(`./Statistics-CdCqGf-R.js`),__vite__mapDeps([23,1,19,2,3,4,5,6,7,8,9,14,24,25,26,16,27])),meta:{requiresAuth:!0}},{path:`/system-stats`,name:`system-stats`,component:()=>Y(()=>import(`./SystemStats-BAQfEFAL.js`),__vite__mapDeps([28,1,19,14,3,24,25,29])),meta:{requiresAuth:!0}},{path:`/configuration`,name:`configuration`,component:()=>Y(()=>import(`./Configuration-wjLY-p5X.js`),__vite__mapDeps([30,1,19,2,3,4,5,6,7,8,9,31,16,32,22])),meta:{requiresAuth:!0}},{path:`/cad-calibration`,name:`cad-calibration`,component:()=>Y(()=>import(`./CADCalibration-DelGuTVC.js`),__vite__mapDeps([33,1,19,3,26,8,4,34])),meta:{requiresAuth:!0}},{path:`/sessions`,name:`sessions`,component:()=>Y(()=>import(`./Sessions-BNJTLm-h.js`),__vite__mapDeps([35,2,1,3,4,5,6,7,8,9])),meta:{requiresAuth:!0}},{path:`/room-servers`,name:`room-servers`,component:()=>Y(()=>import(`./RoomServers-dEkm3wdT.js`),__vite__mapDeps([36,2,1,3,4,5,6,7,8,9,31,37,16])),meta:{requiresAuth:!0}},{path:`/companions`,name:`companions`,component:()=>Y(()=>import(`./Companions-Bwhq-9tt.js`),__vite__mapDeps([38,2,1,3,4,5,6,7,8,9,31,37])),meta:{requiresAuth:!0}},{path:`/logs`,name:`logs`,component:()=>Y(()=>import(`./Logs-DBa052V2.js`),__vite__mapDeps([39,3])),meta:{requiresAuth:!0}},{path:`/terminal`,name:`terminal`,component:()=>Y(()=>import(`./Terminal-CaqQ_zLY.js`),__vite__mapDeps([40,1,2,3,4,5,6,7,8,9,41])),meta:{requiresAuth:!0}},{path:`/help`,name:`help`,component:()=>Y(()=>import(`./Help-1i4KzGWQ.js`),__vite__mapDeps([42,3])),meta:{requiresAuth:!0}}]});async function yn(){try{let e=await fetch(`/api/needs_setup`,{headers:{Accept:`application/json`}});return e.ok?(await e.json()).needs_setup===!0:(console.error(`Setup check failed:`,e.status),!1)}catch(e){return console.error(`Error checking setup status:`,e),!1}}X.beforeEach(async(e,t,n)=>{let r=e.meta.requiresAuth!==!1,i=dn();if(e.path!==`/setup`&&await yn()){n(`/setup`);return}if(e.path===`/setup`&&!await yn()){n(`/login`);return}r&&!i?n(`/login`):e.path===`/login`&&i?n(`/`):n()});var bn=`/api`,Z=!1,Q=null;async function xn(){return Z&&Q?Q:(Z=!0,Q=(async()=>{try{let e=q();if(!e)throw Error(`No token to refresh`);let t=ln(),n=await G.post(`/auth/refresh`,{client_id:t},{headers:{Authorization:`Bearer ${e}`,"Content-Type":`application/json`}});if(n.data.success&&n.data.token){let e=n.data.token;return un(e),e}else throw Error(`Token refresh failed`)}catch(e){throw console.error(`Token refresh error:`,e),J(),X.push(`/login`),e}finally{Z=!1,Q=null}})(),Q)}var $=G.create({baseURL:bn,timeout:5e3,headers:{"Content-Type":`application/json`}}),Sn=G.create({baseURL:``,timeout:5e3,headers:{"Content-Type":`application/json`}});Sn.interceptors.request.use(async e=>{if(e.url?.includes(`/auth/login`)||e.url?.includes(`/auth/refresh`))return e;let t=q();if(t){if(mn())try{let t=await xn();return e.headers.Authorization=`Bearer ${t}`,e}catch(e){return Promise.reject(e)}if(pn())return J(),X.push(`/login`),Promise.reject(Error(`Token expired`));e.headers.Authorization=`Bearer ${t}`}return e},e=>(console.error(`Auth API Request Error:`,e),Promise.reject(e))),Sn.interceptors.response.use(e=>e,e=>(e.response?.status===401&&(J(),X.currentRoute.value.path!==`/login`&&X.push(`/login`)),console.error(`Auth API Response Error:`,e.response?.data||e.message),Promise.reject(e))),$.interceptors.request.use(async e=>{if(e.url?.includes(`/auth/login`))return e;let t=q();if(t){if(mn())try{let t=await xn();return e.headers.Authorization=`Bearer ${t}`,e}catch(e){return Promise.reject(e)}if(pn())return J(),X.push(`/login`),Promise.reject(Error(`Token expired`));e.headers.Authorization=`Bearer ${t}`}return e},e=>(console.error(`API Request Error:`,e),Promise.reject(e))),$.interceptors.response.use(e=>e,e=>(e.response?.status===401&&(J(),X.currentRoute.value.path!==`/login`&&X.push(`/login`)),console.error(`API Response Error:`,e.response?.data||e.message),Promise.reject(e)));var Cn=class{static async get(e,t){try{return(await $.get(e,{params:t})).data}catch(e){throw this.handleError(e)}}static async post(e,t,n){try{return(await $.post(e,t,n)).data}catch(e){throw this.handleError(e)}}static async put(e,t,n){try{return(await $.put(e,t,n)).data}catch(e){throw this.handleError(e)}}static async delete(e,t){try{return(await $.delete(e,t)).data}catch(e){throw this.handleError(e)}}static async getTransportKeys(){return this.get(`transport_keys`)}static async sendAdvert(){return this.post(`send_advert`,{},{headers:{"Content-Type":`application/json`}})}static async createTransportKey(e,t,n,r,i){let a={name:e,flood_policy:t,parent_id:r,last_used:i};return n!==void 0&&(a.transport_key=n),this.post(`transport_keys`,a)}static async getTransportKey(e){return this.get(`transport_key/${e}`)}static async updateTransportKey(e,t,n,r,i,a){return this.put(`transport_key/${e}`,{name:t,flood_policy:n,transport_key:r,parent_id:i,last_used:a})}static async deleteTransportKey(e){return this.delete(`transport_key/${e}`)}static async updateUnscopedFloodPolicy(e){return this.post(`unscoped_flood_policy`,{unscoped_flood_allow:e})}static async getLogs(){try{return(await $.get(`logs`)).data}catch(e){throw this.handleError(e)}}static async deleteAdvert(e){return this.delete(`advert/${e}`)}static async pingNeighbor(e,t=10){return this.post(`ping_neighbor`,{target_id:e,timeout:t})}static async getIdentities(){return this.get(`identities`)}static async getIdentity(e){return this.get(`identity`,{name:e})}static async createIdentity(e){return this.post(`create_identity`,e)}static async updateIdentity(e){return this.put(`update_identity`,e)}static async deleteIdentity(e,t=`room_server`){let n=new URLSearchParams({name:e});return t===`companion`&&n.set(`type`,`companion`),this.delete(`delete_identity?${n.toString()}`)}static async sendRoomServerAdvert(e){return this.post(`send_room_server_advert`,{name:e})}static async importRepeaterContacts(e){return this.post(`companion/import_repeater_contacts`,e)}static async getACLInfo(){return this.get(`acl_info`)}static async getACLClients(e){return this.get(`acl_clients`,e)}static async removeACLClient(e){return this.post(`acl_remove_client`,e)}static async getACLStats(){return this.get(`acl_stats`)}static async getRoomMessages(e){return this.get(`room_messages`,e)}static async postRoomMessage(e){return this.post(`room_post_message`,e)}static async deleteRoomMessage(e){return this.delete(`room_message?room_name=${encodeURIComponent(e.room_name)}&message_id=${e.message_id}`)}static async clearRoomMessages(e){return this.delete(`room_messages?room_name=${encodeURIComponent(e)}`)}static async getRoomStats(e){return this.get(`room_stats`,e?{room_name:e}:void 0)}static async getRoomClients(e){return this.get(`room_clients`,{room_name:e})}static async exportConfig(e=!1){let t=e?`config_export?include_secrets=true`:`config_export`;return this.get(t)}static async importConfig(e){return this.post(`config_import`,{config:e})}static async exportIdentityKey(){return this.get(`identity_export`)}static async generateVanityKey(e,t=!1){return this.post(`generate_vanity_key`,{prefix:e,apply:t})}static async getDbStats(){return this.get(`db_stats`)}static async purgeTable(e){return this.post(`db_purge`,{tables:e})}static async vacuumDb(){return this.post(`db_vacuum`,{})}static handleError(e){if(G.isAxiosError(e)){if(e.response){let t=e.response.data?.error||e.response.data?.message||`HTTP ${e.response.status}`;return Error(t)}else if(e.request)return Error(`Network error - no response received`)}return Error(e instanceof Error?e.message:`Unknown error occurred`)}};export{J as a,hn as c,Y as i,dn as l,Sn as n,ln as o,X as r,q as s,Cn as t,un as u};
|