UNPKG

wdpapi

Version:

51WORLD WdpApi is a set of programming interfaces developed by JavaScript that is responsible for negotiating between web pages and cloud rendering platforms. Supported by 51Cloud rendering platform, it enables the users to create any HTML5 UI element on

15 lines (13 loc) 1.22 MB
import e from"cloudapi"; /*! ***************************************************************************** Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. ***************************************************************************** */function t(e,t,o,i){return new(o||(o=Promise))(function(n,r){function a(e){try{l(i.next(e))}catch(e){r(e)}}function s(e){try{l(i.throw(e))}catch(e){r(e)}}function l(e){var t;e.done?n(e.value):(t=e.value,t instanceof o?t:new o(function(e){e(t)})).then(a,s)}l((i=i.apply(e,t||[])).next())})}var o,i;!function(e){e[e.API=0]="API",e[e.EVENT=1]="EVENT",e[e.ERROR=2]="ERROR"}(o||(o={})),function(e){e[e.Add=0]="Add",e[e.Remove=1]="Remove",e[e.Clear=2]="Clear"}(i||(i={}));const n=new Map;"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self&&self;function r(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function a(e){if(e.__esModule)return e;var t=e.default;if("function"==typeof t){var o=function e(){if(this instanceof e){var o=[null];return o.push.apply(o,arguments),new(Function.bind.apply(t,o))}return t.apply(this,arguments)};o.prototype=t.prototype}else o={};return Object.defineProperty(o,"__esModule",{value:!0}),Object.keys(e).forEach(function(t){var i=Object.getOwnPropertyDescriptor(e,t);Object.defineProperty(o,t,i.get?i:{enumerable:!0,get:function(){return e[t]}})}),o}var s,l={exports:{}},d=function(e,t){return function(){for(var o=new Array(arguments.length),i=0;i<o.length;i++)o[i]=arguments[i];return e.apply(t,o)}},c=d,u=Object.prototype.toString,v=(s=Object.create(null),function(e){var t=u.call(e);return s[t]||(s[t]=t.slice(8,-1).toLowerCase())});function h(e){return e=e.toLowerCase(),function(t){return v(t)===e}}function m(e){return Array.isArray(e)}function g(e){return void 0===e}var y=h("ArrayBuffer");function f(e){return null!==e&&"object"==typeof e}function b(e){if("object"!==v(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}var p=h("Date"),E=h("File"),w=h("Blob"),I=h("FileList");function j(e){return"[object Function]"===u.call(e)}var S=h("URLSearchParams");function C(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),m(e))for(var o=0,i=e.length;o<i;o++)t.call(null,e[o],o,e);else for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.call(null,e[n],n,e)}var G,O=(G="undefined"!=typeof Uint8Array&&Object.getPrototypeOf(Uint8Array),function(e){return G&&e instanceof G}),$={isArray:m,isArrayBuffer:y,isBuffer:function(e){return null!==e&&!g(e)&&null!==e.constructor&&!g(e.constructor)&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)},isFormData:function(e){var t="[object FormData]";return e&&("function"==typeof FormData&&e instanceof FormData||u.call(e)===t||j(e.toString)&&e.toString()===t)},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&y(e.buffer)},isString:function(e){return"string"==typeof e},isNumber:function(e){return"number"==typeof e},isObject:f,isPlainObject:b,isUndefined:g,isDate:p,isFile:E,isBlob:w,isFunction:j,isStream:function(e){return f(e)&&j(e.pipe)},isURLSearchParams:S,isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&("undefined"!=typeof window&&"undefined"!=typeof document)},forEach:C,merge:function e(){var t={};function o(o,i){b(t[i])&&b(o)?t[i]=e(t[i],o):b(o)?t[i]=e({},o):m(o)?t[i]=o.slice():t[i]=o}for(var i=0,n=arguments.length;i<n;i++)C(arguments[i],o);return t},extend:function(e,t,o){return C(t,function(t,i){e[i]=o&&"function"==typeof t?c(t,o):t}),e},trim:function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e},inherits:function(e,t,o,i){e.prototype=Object.create(t.prototype,i),e.prototype.constructor=e,o&&Object.assign(e.prototype,o)},toFlatObject:function(e,t,o){var i,n,r,a={};t=t||{};do{for(n=(i=Object.getOwnPropertyNames(e)).length;n-- >0;)a[r=i[n]]||(t[r]=e[r],a[r]=!0);e=Object.getPrototypeOf(e)}while(e&&(!o||o(e,t))&&e!==Object.prototype);return t},kindOf:v,kindOfTest:h,endsWith:function(e,t,o){e=String(e),(void 0===o||o>e.length)&&(o=e.length),o-=t.length;var i=e.indexOf(t,o);return-1!==i&&i===o},toArray:function(e){if(!e)return null;var t=e.length;if(g(t))return null;for(var o=new Array(t);t-- >0;)o[t]=e[t];return o},isTypedArray:O,isFileList:I},T=$;function M(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var A=function(e,t,o){if(!t)return e;var i;if(o)i=o(t);else if(T.isURLSearchParams(t))i=t.toString();else{var n=[];T.forEach(t,function(e,t){null!=e&&(T.isArray(e)?t+="[]":e=[e],T.forEach(e,function(e){T.isDate(e)?e=e.toISOString():T.isObject(e)&&(e=JSON.stringify(e)),n.push(M(t)+"="+M(e))}))}),i=n.join("&")}if(i){var r=e.indexOf("#");-1!==r&&(e=e.slice(0,r)),e+=(-1===e.indexOf("?")?"?":"&")+i}return e},D=$;function R(){this.handlers=[]}R.prototype.use=function(e,t,o){return this.handlers.push({fulfilled:e,rejected:t,synchronous:!!o&&o.synchronous,runWhen:o?o.runWhen:null}),this.handlers.length-1},R.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},R.prototype.forEach=function(e){D.forEach(this.handlers,function(t){null!==t&&e(t)})};var N=R,x="undefined"!=typeof global?global:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{};function V(){throw new Error("setTimeout has not been defined")}function P(){throw new Error("clearTimeout has not been defined")}var L=V,k=P;function _(e){if(L===setTimeout)return setTimeout(e,0);if((L===V||!L)&&setTimeout)return L=setTimeout,setTimeout(e,0);try{return L(e,0)}catch(t){try{return L.call(null,e,0)}catch(t){return L.call(this,e,0)}}}"function"==typeof x.setTimeout&&(L=setTimeout),"function"==typeof x.clearTimeout&&(k=clearTimeout);var F,U=[],B=!1,q=-1;function H(){B&&F&&(B=!1,F.length?U=F.concat(U):q=-1,U.length&&z())}function z(){if(!B){var e=_(H);B=!0;for(var t=U.length;t;){for(F=U,U=[];++q<t;)F&&F[q].run();q=-1,t=U.length}F=null,B=!1,function(e){if(k===clearTimeout)return clearTimeout(e);if((k===P||!k)&&clearTimeout)return k=clearTimeout,clearTimeout(e);try{return k(e)}catch(t){try{return k.call(null,e)}catch(t){return k.call(this,e)}}}(e)}}function W(e,t){this.fun=e,this.array=t}W.prototype.run=function(){this.fun.apply(null,this.array)};function Z(){}var Y=Z,Q=Z,J=Z,X=Z,K=Z,ee=Z,te=Z;var oe=x.performance||{},ie=oe.now||oe.mozNow||oe.msNow||oe.oNow||oe.webkitNow||function(){return(new Date).getTime()};var ne=new Date;var re,ae,se={nextTick:function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var o=1;o<arguments.length;o++)t[o-1]=arguments[o];U.push(new W(e,t)),1!==U.length||B||_(z)},title:"browser",browser:!0,env:{},argv:[],version:"",versions:{},on:Y,addListener:Q,once:J,off:X,removeListener:K,removeAllListeners:ee,emit:te,binding:function(e){throw new Error("process.binding is not supported")},cwd:function(){return"/"},chdir:function(e){throw new Error("process.chdir is not supported")},umask:function(){return 0},hrtime:function(e){var t=.001*ie.call(oe),o=Math.floor(t),i=Math.floor(t%1*1e9);return e&&(o-=e[0],(i-=e[1])<0&&(o--,i+=1e9)),[o,i]},platform:"browser",release:{},config:{},uptime:function(){return(new Date-ne)/1e3}},le=$;function de(){if(ae)return re;ae=1;var e=$;function t(e,t,o,i,n){Error.call(this),this.message=e,this.name="AxiosError",t&&(this.code=t),o&&(this.config=o),i&&(this.request=i),n&&(this.response=n)}e.inherits(t,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:this.config,code:this.code,status:this.response&&this.response.status?this.response.status:null}}});var o=t.prototype,i={};return["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"].forEach(function(e){i[e]={value:e}}),Object.defineProperties(t,i),Object.defineProperty(o,"isAxiosError",{value:!0}),t.from=function(i,n,r,a,s,l){var d=Object.create(o);return e.toFlatObject(i,d,function(e){return e!==Error.prototype}),t.call(d,i.message,n,r,a,s),d.name=i.name,l&&Object.assign(d,l),d},re=t}var ce={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},ue=[],ve=[],he="undefined"!=typeof Uint8Array?Uint8Array:Array,me=!1;function ge(){me=!0;for(var e="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",t=0;t<64;++t)ue[t]=e[t],ve[e.charCodeAt(t)]=t;ve["-".charCodeAt(0)]=62,ve["_".charCodeAt(0)]=63}function ye(e){return ue[e>>18&63]+ue[e>>12&63]+ue[e>>6&63]+ue[63&e]}function fe(e,t,o){for(var i,n=[],r=t;r<o;r+=3)i=(e[r]<<16)+(e[r+1]<<8)+e[r+2],n.push(ye(i));return n.join("")}function be(e){var t;me||ge();for(var o=e.length,i=o%3,n="",r=[],a=16383,s=0,l=o-i;s<l;s+=a)r.push(fe(e,s,s+a>l?l:s+a));return 1===i?(t=e[o-1],n+=ue[t>>2],n+=ue[t<<4&63],n+="=="):2===i&&(t=(e[o-2]<<8)+e[o-1],n+=ue[t>>10],n+=ue[t>>4&63],n+=ue[t<<2&63],n+="="),r.push(n),r.join("")}function pe(e,t,o,i,n){var r,a,s=8*n-i-1,l=(1<<s)-1,d=l>>1,c=-7,u=o?n-1:0,v=o?-1:1,h=e[t+u];for(u+=v,r=h&(1<<-c)-1,h>>=-c,c+=s;c>0;r=256*r+e[t+u],u+=v,c-=8);for(a=r&(1<<-c)-1,r>>=-c,c+=i;c>0;a=256*a+e[t+u],u+=v,c-=8);if(0===r)r=1-d;else{if(r===l)return a?NaN:1/0*(h?-1:1);a+=Math.pow(2,i),r-=d}return(h?-1:1)*a*Math.pow(2,r-i)}function Ee(e,t,o,i,n,r){var a,s,l,d=8*r-n-1,c=(1<<d)-1,u=c>>1,v=23===n?Math.pow(2,-24)-Math.pow(2,-77):0,h=i?0:r-1,m=i?1:-1,g=t<0||0===t&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(s=isNaN(t)?1:0,a=c):(a=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-a))<1&&(a--,l*=2),(t+=a+u>=1?v/l:v*Math.pow(2,1-u))*l>=2&&(a++,l/=2),a+u>=c?(s=0,a=c):a+u>=1?(s=(t*l-1)*Math.pow(2,n),a+=u):(s=t*Math.pow(2,u-1)*Math.pow(2,n),a=0));n>=8;e[o+h]=255&s,h+=m,s/=256,n-=8);for(a=a<<n|s,d+=n;d>0;e[o+h]=255&a,h+=m,a/=256,d-=8);e[o+h-m]|=128*g}var we={}.toString,Ie=Array.isArray||function(e){return"[object Array]"==we.call(e)};function je(){return Ce.TYPED_ARRAY_SUPPORT?2147483647:1073741823}function Se(e,t){if(je()<t)throw new RangeError("Invalid typed array length");return Ce.TYPED_ARRAY_SUPPORT?(e=new Uint8Array(t)).__proto__=Ce.prototype:(null===e&&(e=new Ce(t)),e.length=t),e}function Ce(e,t,o){if(!(Ce.TYPED_ARRAY_SUPPORT||this instanceof Ce))return new Ce(e,t,o);if("number"==typeof e){if("string"==typeof t)throw new Error("If encoding is specified then the first argument must be a string");return $e(this,e)}return Ge(this,e,t,o)}function Ge(e,t,o,i){if("number"==typeof t)throw new TypeError('"value" argument must not be a number');return"undefined"!=typeof ArrayBuffer&&t instanceof ArrayBuffer?function(e,t,o,i){if(t.byteLength,o<0||t.byteLength<o)throw new RangeError("'offset' is out of bounds");if(t.byteLength<o+(i||0))throw new RangeError("'length' is out of bounds");t=void 0===o&&void 0===i?new Uint8Array(t):void 0===i?new Uint8Array(t,o):new Uint8Array(t,o,i);Ce.TYPED_ARRAY_SUPPORT?(e=t).__proto__=Ce.prototype:e=Te(e,t);return e}(e,t,o,i):"string"==typeof t?function(e,t,o){"string"==typeof o&&""!==o||(o="utf8");if(!Ce.isEncoding(o))throw new TypeError('"encoding" must be a valid string encoding');var i=0|De(t,o);e=Se(e,i);var n=e.write(t,o);n!==i&&(e=e.slice(0,n));return e}(e,t,o):function(e,t){if(Ae(t)){var o=0|Me(t.length);return 0===(e=Se(e,o)).length||t.copy(e,0,0,o),e}if(t){if("undefined"!=typeof ArrayBuffer&&t.buffer instanceof ArrayBuffer||"length"in t)return"number"!=typeof t.length||(i=t.length)!=i?Se(e,0):Te(e,t);if("Buffer"===t.type&&Ie(t.data))return Te(e,t.data)}var i;throw new TypeError("First argument must be a string, Buffer, ArrayBuffer, Array, or array-like object.")}(e,t)}function Oe(e){if("number"!=typeof e)throw new TypeError('"size" argument must be a number');if(e<0)throw new RangeError('"size" argument must not be negative')}function $e(e,t){if(Oe(t),e=Se(e,t<0?0:0|Me(t)),!Ce.TYPED_ARRAY_SUPPORT)for(var o=0;o<t;++o)e[o]=0;return e}function Te(e,t){var o=t.length<0?0:0|Me(t.length);e=Se(e,o);for(var i=0;i<o;i+=1)e[i]=255&t[i];return e}function Me(e){if(e>=je())throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+je().toString(16)+" bytes");return 0|e}function Ae(e){return!(null==e||!e._isBuffer)}function De(e,t){if(Ae(e))return e.length;if("undefined"!=typeof ArrayBuffer&&"function"==typeof ArrayBuffer.isView&&(ArrayBuffer.isView(e)||e instanceof ArrayBuffer))return e.byteLength;"string"!=typeof e&&(e=""+e);var o=e.length;if(0===o)return 0;for(var i=!1;;)switch(t){case"ascii":case"latin1":case"binary":return o;case"utf8":case"utf-8":case void 0:return ut(e).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*o;case"hex":return o>>>1;case"base64":return vt(e).length;default:if(i)return ut(e).length;t=(""+t).toLowerCase(),i=!0}}function Re(e,t,o){var i=!1;if((void 0===t||t<0)&&(t=0),t>this.length)return"";if((void 0===o||o>this.length)&&(o=this.length),o<=0)return"";if((o>>>=0)<=(t>>>=0))return"";for(e||(e="utf8");;)switch(e){case"hex":return Ze(this,t,o);case"utf8":case"utf-8":return qe(this,t,o);case"ascii":return ze(this,t,o);case"latin1":case"binary":return We(this,t,o);case"base64":return Be(this,t,o);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Ye(this,t,o);default:if(i)throw new TypeError("Unknown encoding: "+e);e=(e+"").toLowerCase(),i=!0}}function Ne(e,t,o){var i=e[t];e[t]=e[o],e[o]=i}function xe(e,t,o,i,n){if(0===e.length)return-1;if("string"==typeof o?(i=o,o=0):o>2147483647?o=2147483647:o<-2147483648&&(o=-2147483648),o=+o,isNaN(o)&&(o=n?0:e.length-1),o<0&&(o=e.length+o),o>=e.length){if(n)return-1;o=e.length-1}else if(o<0){if(!n)return-1;o=0}if("string"==typeof t&&(t=Ce.from(t,i)),Ae(t))return 0===t.length?-1:Ve(e,t,o,i,n);if("number"==typeof t)return t&=255,Ce.TYPED_ARRAY_SUPPORT&&"function"==typeof Uint8Array.prototype.indexOf?n?Uint8Array.prototype.indexOf.call(e,t,o):Uint8Array.prototype.lastIndexOf.call(e,t,o):Ve(e,[t],o,i,n);throw new TypeError("val must be string, number or Buffer")}function Ve(e,t,o,i,n){var r,a=1,s=e.length,l=t.length;if(void 0!==i&&("ucs2"===(i=String(i).toLowerCase())||"ucs-2"===i||"utf16le"===i||"utf-16le"===i)){if(e.length<2||t.length<2)return-1;a=2,s/=2,l/=2,o/=2}function d(e,t){return 1===a?e[t]:e.readUInt16BE(t*a)}if(n){var c=-1;for(r=o;r<s;r++)if(d(e,r)===d(t,-1===c?0:r-c)){if(-1===c&&(c=r),r-c+1===l)return c*a}else-1!==c&&(r-=r-c),c=-1}else for(o+l>s&&(o=s-l),r=o;r>=0;r--){for(var u=!0,v=0;v<l;v++)if(d(e,r+v)!==d(t,v)){u=!1;break}if(u)return r}return-1}function Pe(e,t,o,i){o=Number(o)||0;var n=e.length-o;i?(i=Number(i))>n&&(i=n):i=n;var r=t.length;if(r%2!=0)throw new TypeError("Invalid hex string");i>r/2&&(i=r/2);for(var a=0;a<i;++a){var s=parseInt(t.substr(2*a,2),16);if(isNaN(s))return a;e[o+a]=s}return a}function Le(e,t,o,i){return ht(ut(t,e.length-o),e,o,i)}function ke(e,t,o,i){return ht(function(e){for(var t=[],o=0;o<e.length;++o)t.push(255&e.charCodeAt(o));return t}(t),e,o,i)}function _e(e,t,o,i){return ke(e,t,o,i)}function Fe(e,t,o,i){return ht(vt(t),e,o,i)}function Ue(e,t,o,i){return ht(function(e,t){for(var o,i,n,r=[],a=0;a<e.length&&!((t-=2)<0);++a)i=(o=e.charCodeAt(a))>>8,n=o%256,r.push(n),r.push(i);return r}(t,e.length-o),e,o,i)}function Be(e,t,o){return 0===t&&o===e.length?be(e):be(e.slice(t,o))}function qe(e,t,o){o=Math.min(e.length,o);for(var i=[],n=t;n<o;){var r,a,s,l,d=e[n],c=null,u=d>239?4:d>223?3:d>191?2:1;if(n+u<=o)switch(u){case 1:d<128&&(c=d);break;case 2:128==(192&(r=e[n+1]))&&(l=(31&d)<<6|63&r)>127&&(c=l);break;case 3:r=e[n+1],a=e[n+2],128==(192&r)&&128==(192&a)&&(l=(15&d)<<12|(63&r)<<6|63&a)>2047&&(l<55296||l>57343)&&(c=l);break;case 4:r=e[n+1],a=e[n+2],s=e[n+3],128==(192&r)&&128==(192&a)&&128==(192&s)&&(l=(15&d)<<18|(63&r)<<12|(63&a)<<6|63&s)>65535&&l<1114112&&(c=l)}null===c?(c=65533,u=1):c>65535&&(c-=65536,i.push(c>>>10&1023|55296),c=56320|1023&c),i.push(c),n+=u}return function(e){var t=e.length;if(t<=He)return String.fromCharCode.apply(String,e);var o="",i=0;for(;i<t;)o+=String.fromCharCode.apply(String,e.slice(i,i+=He));return o}(i)}Ce.TYPED_ARRAY_SUPPORT=void 0===x.TYPED_ARRAY_SUPPORT||x.TYPED_ARRAY_SUPPORT,je(),Ce.poolSize=8192,Ce._augment=function(e){return e.__proto__=Ce.prototype,e},Ce.from=function(e,t,o){return Ge(null,e,t,o)},Ce.TYPED_ARRAY_SUPPORT&&(Ce.prototype.__proto__=Uint8Array.prototype,Ce.__proto__=Uint8Array,"undefined"!=typeof Symbol&&Symbol.species&&Ce[Symbol.species]),Ce.alloc=function(e,t,o){return function(e,t,o,i){return Oe(t),t<=0?Se(e,t):void 0!==o?"string"==typeof i?Se(e,t).fill(o,i):Se(e,t).fill(o):Se(e,t)}(null,e,t,o)},Ce.allocUnsafe=function(e){return $e(null,e)},Ce.allocUnsafeSlow=function(e){return $e(null,e)},Ce.isBuffer=function(e){return null!=e&&(!!e._isBuffer||mt(e)||function(e){return"function"==typeof e.readFloatLE&&"function"==typeof e.slice&&mt(e.slice(0,0))}(e))},Ce.compare=function(e,t){if(!Ae(e)||!Ae(t))throw new TypeError("Arguments must be Buffers");if(e===t)return 0;for(var o=e.length,i=t.length,n=0,r=Math.min(o,i);n<r;++n)if(e[n]!==t[n]){o=e[n],i=t[n];break}return o<i?-1:i<o?1:0},Ce.isEncoding=function(e){switch(String(e).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},Ce.concat=function(e,t){if(!Ie(e))throw new TypeError('"list" argument must be an Array of Buffers');if(0===e.length)return Ce.alloc(0);var o;if(void 0===t)for(t=0,o=0;o<e.length;++o)t+=e[o].length;var i=Ce.allocUnsafe(t),n=0;for(o=0;o<e.length;++o){var r=e[o];if(!Ae(r))throw new TypeError('"list" argument must be an Array of Buffers');r.copy(i,n),n+=r.length}return i},Ce.byteLength=De,Ce.prototype._isBuffer=!0,Ce.prototype.swap16=function(){var e=this.length;if(e%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(var t=0;t<e;t+=2)Ne(this,t,t+1);return this},Ce.prototype.swap32=function(){var e=this.length;if(e%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(var t=0;t<e;t+=4)Ne(this,t,t+3),Ne(this,t+1,t+2);return this},Ce.prototype.swap64=function(){var e=this.length;if(e%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(var t=0;t<e;t+=8)Ne(this,t,t+7),Ne(this,t+1,t+6),Ne(this,t+2,t+5),Ne(this,t+3,t+4);return this},Ce.prototype.toString=function(){var e=0|this.length;return 0===e?"":0===arguments.length?qe(this,0,e):Re.apply(this,arguments)},Ce.prototype.equals=function(e){if(!Ae(e))throw new TypeError("Argument must be a Buffer");return this===e||0===Ce.compare(this,e)},Ce.prototype.inspect=function(){var e="";return this.length>0&&(e=this.toString("hex",0,50).match(/.{2}/g).join(" "),this.length>50&&(e+=" ... ")),"<Buffer "+e+">"},Ce.prototype.compare=function(e,t,o,i,n){if(!Ae(e))throw new TypeError("Argument must be a Buffer");if(void 0===t&&(t=0),void 0===o&&(o=e?e.length:0),void 0===i&&(i=0),void 0===n&&(n=this.length),t<0||o>e.length||i<0||n>this.length)throw new RangeError("out of range index");if(i>=n&&t>=o)return 0;if(i>=n)return-1;if(t>=o)return 1;if(this===e)return 0;for(var r=(n>>>=0)-(i>>>=0),a=(o>>>=0)-(t>>>=0),s=Math.min(r,a),l=this.slice(i,n),d=e.slice(t,o),c=0;c<s;++c)if(l[c]!==d[c]){r=l[c],a=d[c];break}return r<a?-1:a<r?1:0},Ce.prototype.includes=function(e,t,o){return-1!==this.indexOf(e,t,o)},Ce.prototype.indexOf=function(e,t,o){return xe(this,e,t,o,!0)},Ce.prototype.lastIndexOf=function(e,t,o){return xe(this,e,t,o,!1)},Ce.prototype.write=function(e,t,o,i){if(void 0===t)i="utf8",o=this.length,t=0;else if(void 0===o&&"string"==typeof t)i=t,o=this.length,t=0;else{if(!isFinite(t))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");t|=0,isFinite(o)?(o|=0,void 0===i&&(i="utf8")):(i=o,o=void 0)}var n=this.length-t;if((void 0===o||o>n)&&(o=n),e.length>0&&(o<0||t<0)||t>this.length)throw new RangeError("Attempt to write outside buffer bounds");i||(i="utf8");for(var r=!1;;)switch(i){case"hex":return Pe(this,e,t,o);case"utf8":case"utf-8":return Le(this,e,t,o);case"ascii":return ke(this,e,t,o);case"latin1":case"binary":return _e(this,e,t,o);case"base64":return Fe(this,e,t,o);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return Ue(this,e,t,o);default:if(r)throw new TypeError("Unknown encoding: "+i);i=(""+i).toLowerCase(),r=!0}},Ce.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};var He=4096;function ze(e,t,o){var i="";o=Math.min(e.length,o);for(var n=t;n<o;++n)i+=String.fromCharCode(127&e[n]);return i}function We(e,t,o){var i="";o=Math.min(e.length,o);for(var n=t;n<o;++n)i+=String.fromCharCode(e[n]);return i}function Ze(e,t,o){var i=e.length;(!t||t<0)&&(t=0),(!o||o<0||o>i)&&(o=i);for(var n="",r=t;r<o;++r)n+=ct(e[r]);return n}function Ye(e,t,o){for(var i=e.slice(t,o),n="",r=0;r<i.length;r+=2)n+=String.fromCharCode(i[r]+256*i[r+1]);return n}function Qe(e,t,o){if(e%1!=0||e<0)throw new RangeError("offset is not uint");if(e+t>o)throw new RangeError("Trying to access beyond buffer length")}function Je(e,t,o,i,n,r){if(!Ae(e))throw new TypeError('"buffer" argument must be a Buffer instance');if(t>n||t<r)throw new RangeError('"value" argument is out of bounds');if(o+i>e.length)throw new RangeError("Index out of range")}function Xe(e,t,o,i){t<0&&(t=65535+t+1);for(var n=0,r=Math.min(e.length-o,2);n<r;++n)e[o+n]=(t&255<<8*(i?n:1-n))>>>8*(i?n:1-n)}function Ke(e,t,o,i){t<0&&(t=4294967295+t+1);for(var n=0,r=Math.min(e.length-o,4);n<r;++n)e[o+n]=t>>>8*(i?n:3-n)&255}function et(e,t,o,i,n,r){if(o+i>e.length)throw new RangeError("Index out of range");if(o<0)throw new RangeError("Index out of range")}function tt(e,t,o,i,n){return n||et(e,0,o,4),Ee(e,t,o,i,23,4),o+4}function ot(e,t,o,i,n){return n||et(e,0,o,8),Ee(e,t,o,i,52,8),o+8}Ce.prototype.slice=function(e,t){var o,i=this.length;if((e=~~e)<0?(e+=i)<0&&(e=0):e>i&&(e=i),(t=void 0===t?i:~~t)<0?(t+=i)<0&&(t=0):t>i&&(t=i),t<e&&(t=e),Ce.TYPED_ARRAY_SUPPORT)(o=this.subarray(e,t)).__proto__=Ce.prototype;else{var n=t-e;o=new Ce(n,void 0);for(var r=0;r<n;++r)o[r]=this[r+e]}return o},Ce.prototype.readUIntLE=function(e,t,o){e|=0,t|=0,o||Qe(e,t,this.length);for(var i=this[e],n=1,r=0;++r<t&&(n*=256);)i+=this[e+r]*n;return i},Ce.prototype.readUIntBE=function(e,t,o){e|=0,t|=0,o||Qe(e,t,this.length);for(var i=this[e+--t],n=1;t>0&&(n*=256);)i+=this[e+--t]*n;return i},Ce.prototype.readUInt8=function(e,t){return t||Qe(e,1,this.length),this[e]},Ce.prototype.readUInt16LE=function(e,t){return t||Qe(e,2,this.length),this[e]|this[e+1]<<8},Ce.prototype.readUInt16BE=function(e,t){return t||Qe(e,2,this.length),this[e]<<8|this[e+1]},Ce.prototype.readUInt32LE=function(e,t){return t||Qe(e,4,this.length),(this[e]|this[e+1]<<8|this[e+2]<<16)+16777216*this[e+3]},Ce.prototype.readUInt32BE=function(e,t){return t||Qe(e,4,this.length),16777216*this[e]+(this[e+1]<<16|this[e+2]<<8|this[e+3])},Ce.prototype.readIntLE=function(e,t,o){e|=0,t|=0,o||Qe(e,t,this.length);for(var i=this[e],n=1,r=0;++r<t&&(n*=256);)i+=this[e+r]*n;return i>=(n*=128)&&(i-=Math.pow(2,8*t)),i},Ce.prototype.readIntBE=function(e,t,o){e|=0,t|=0,o||Qe(e,t,this.length);for(var i=t,n=1,r=this[e+--i];i>0&&(n*=256);)r+=this[e+--i]*n;return r>=(n*=128)&&(r-=Math.pow(2,8*t)),r},Ce.prototype.readInt8=function(e,t){return t||Qe(e,1,this.length),128&this[e]?-1*(255-this[e]+1):this[e]},Ce.prototype.readInt16LE=function(e,t){t||Qe(e,2,this.length);var o=this[e]|this[e+1]<<8;return 32768&o?4294901760|o:o},Ce.prototype.readInt16BE=function(e,t){t||Qe(e,2,this.length);var o=this[e+1]|this[e]<<8;return 32768&o?4294901760|o:o},Ce.prototype.readInt32LE=function(e,t){return t||Qe(e,4,this.length),this[e]|this[e+1]<<8|this[e+2]<<16|this[e+3]<<24},Ce.prototype.readInt32BE=function(e,t){return t||Qe(e,4,this.length),this[e]<<24|this[e+1]<<16|this[e+2]<<8|this[e+3]},Ce.prototype.readFloatLE=function(e,t){return t||Qe(e,4,this.length),pe(this,e,!0,23,4)},Ce.prototype.readFloatBE=function(e,t){return t||Qe(e,4,this.length),pe(this,e,!1,23,4)},Ce.prototype.readDoubleLE=function(e,t){return t||Qe(e,8,this.length),pe(this,e,!0,52,8)},Ce.prototype.readDoubleBE=function(e,t){return t||Qe(e,8,this.length),pe(this,e,!1,52,8)},Ce.prototype.writeUIntLE=function(e,t,o,i){(e=+e,t|=0,o|=0,i)||Je(this,e,t,o,Math.pow(2,8*o)-1,0);var n=1,r=0;for(this[t]=255&e;++r<o&&(n*=256);)this[t+r]=e/n&255;return t+o},Ce.prototype.writeUIntBE=function(e,t,o,i){(e=+e,t|=0,o|=0,i)||Je(this,e,t,o,Math.pow(2,8*o)-1,0);var n=o-1,r=1;for(this[t+n]=255&e;--n>=0&&(r*=256);)this[t+n]=e/r&255;return t+o},Ce.prototype.writeUInt8=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,1,255,0),Ce.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),this[t]=255&e,t+1},Ce.prototype.writeUInt16LE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,2,65535,0),Ce.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):Xe(this,e,t,!0),t+2},Ce.prototype.writeUInt16BE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,2,65535,0),Ce.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):Xe(this,e,t,!1),t+2},Ce.prototype.writeUInt32LE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,4,4294967295,0),Ce.TYPED_ARRAY_SUPPORT?(this[t+3]=e>>>24,this[t+2]=e>>>16,this[t+1]=e>>>8,this[t]=255&e):Ke(this,e,t,!0),t+4},Ce.prototype.writeUInt32BE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,4,4294967295,0),Ce.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):Ke(this,e,t,!1),t+4},Ce.prototype.writeIntLE=function(e,t,o,i){if(e=+e,t|=0,!i){var n=Math.pow(2,8*o-1);Je(this,e,t,o,n-1,-n)}var r=0,a=1,s=0;for(this[t]=255&e;++r<o&&(a*=256);)e<0&&0===s&&0!==this[t+r-1]&&(s=1),this[t+r]=(e/a|0)-s&255;return t+o},Ce.prototype.writeIntBE=function(e,t,o,i){if(e=+e,t|=0,!i){var n=Math.pow(2,8*o-1);Je(this,e,t,o,n-1,-n)}var r=o-1,a=1,s=0;for(this[t+r]=255&e;--r>=0&&(a*=256);)e<0&&0===s&&0!==this[t+r+1]&&(s=1),this[t+r]=(e/a|0)-s&255;return t+o},Ce.prototype.writeInt8=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,1,127,-128),Ce.TYPED_ARRAY_SUPPORT||(e=Math.floor(e)),e<0&&(e=255+e+1),this[t]=255&e,t+1},Ce.prototype.writeInt16LE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,2,32767,-32768),Ce.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8):Xe(this,e,t,!0),t+2},Ce.prototype.writeInt16BE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,2,32767,-32768),Ce.TYPED_ARRAY_SUPPORT?(this[t]=e>>>8,this[t+1]=255&e):Xe(this,e,t,!1),t+2},Ce.prototype.writeInt32LE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,4,2147483647,-2147483648),Ce.TYPED_ARRAY_SUPPORT?(this[t]=255&e,this[t+1]=e>>>8,this[t+2]=e>>>16,this[t+3]=e>>>24):Ke(this,e,t,!0),t+4},Ce.prototype.writeInt32BE=function(e,t,o){return e=+e,t|=0,o||Je(this,e,t,4,2147483647,-2147483648),e<0&&(e=4294967295+e+1),Ce.TYPED_ARRAY_SUPPORT?(this[t]=e>>>24,this[t+1]=e>>>16,this[t+2]=e>>>8,this[t+3]=255&e):Ke(this,e,t,!1),t+4},Ce.prototype.writeFloatLE=function(e,t,o){return tt(this,e,t,!0,o)},Ce.prototype.writeFloatBE=function(e,t,o){return tt(this,e,t,!1,o)},Ce.prototype.writeDoubleLE=function(e,t,o){return ot(this,e,t,!0,o)},Ce.prototype.writeDoubleBE=function(e,t,o){return ot(this,e,t,!1,o)},Ce.prototype.copy=function(e,t,o,i){if(o||(o=0),i||0===i||(i=this.length),t>=e.length&&(t=e.length),t||(t=0),i>0&&i<o&&(i=o),i===o)return 0;if(0===e.length||0===this.length)return 0;if(t<0)throw new RangeError("targetStart out of bounds");if(o<0||o>=this.length)throw new RangeError("sourceStart out of bounds");if(i<0)throw new RangeError("sourceEnd out of bounds");i>this.length&&(i=this.length),e.length-t<i-o&&(i=e.length-t+o);var n,r=i-o;if(this===e&&o<t&&t<i)for(n=r-1;n>=0;--n)e[n+t]=this[n+o];else if(r<1e3||!Ce.TYPED_ARRAY_SUPPORT)for(n=0;n<r;++n)e[n+t]=this[n+o];else Uint8Array.prototype.set.call(e,this.subarray(o,o+r),t);return r},Ce.prototype.fill=function(e,t,o,i){if("string"==typeof e){if("string"==typeof t?(i=t,t=0,o=this.length):"string"==typeof o&&(i=o,o=this.length),1===e.length){var n=e.charCodeAt(0);n<256&&(e=n)}if(void 0!==i&&"string"!=typeof i)throw new TypeError("encoding must be a string");if("string"==typeof i&&!Ce.isEncoding(i))throw new TypeError("Unknown encoding: "+i)}else"number"==typeof e&&(e&=255);if(t<0||this.length<t||this.length<o)throw new RangeError("Out of range index");if(o<=t)return this;var r;if(t>>>=0,o=void 0===o?this.length:o>>>0,e||(e=0),"number"==typeof e)for(r=t;r<o;++r)this[r]=e;else{var a=Ae(e)?e:ut(new Ce(e,i).toString()),s=a.length;for(r=0;r<o-t;++r)this[r+t]=a[r%s]}return this};var it,nt,rt,at,st,lt,dt=/[^+\/0-9A-Za-z-_]/g;function ct(e){return e<16?"0"+e.toString(16):e.toString(16)}function ut(e,t){var o;t=t||1/0;for(var i=e.length,n=null,r=[],a=0;a<i;++a){if((o=e.charCodeAt(a))>55295&&o<57344){if(!n){if(o>56319){(t-=3)>-1&&r.push(239,191,189);continue}if(a+1===i){(t-=3)>-1&&r.push(239,191,189);continue}n=o;continue}if(o<56320){(t-=3)>-1&&r.push(239,191,189),n=o;continue}o=65536+(n-55296<<10|o-56320)}else n&&(t-=3)>-1&&r.push(239,191,189);if(n=null,o<128){if((t-=1)<0)break;r.push(o)}else if(o<2048){if((t-=2)<0)break;r.push(o>>6|192,63&o|128)}else if(o<65536){if((t-=3)<0)break;r.push(o>>12|224,o>>6&63|128,63&o|128)}else{if(!(o<1114112))throw new Error("Invalid code point");if((t-=4)<0)break;r.push(o>>18|240,o>>12&63|128,o>>6&63|128,63&o|128)}}return r}function vt(e){return function(e){var t,o,i,n,r,a;me||ge();var s=e.length;if(s%4>0)throw new Error("Invalid string. Length must be a multiple of 4");r="="===e[s-2]?2:"="===e[s-1]?1:0,a=new he(3*s/4-r),i=r>0?s-4:s;var l=0;for(t=0,o=0;t<i;t+=4,o+=3)n=ve[e.charCodeAt(t)]<<18|ve[e.charCodeAt(t+1)]<<12|ve[e.charCodeAt(t+2)]<<6|ve[e.charCodeAt(t+3)],a[l++]=n>>16&255,a[l++]=n>>8&255,a[l++]=255&n;return 2===r?(n=ve[e.charCodeAt(t)]<<2|ve[e.charCodeAt(t+1)]>>4,a[l++]=255&n):1===r&&(n=ve[e.charCodeAt(t)]<<10|ve[e.charCodeAt(t+1)]<<4|ve[e.charCodeAt(t+2)]>>2,a[l++]=n>>8&255,a[l++]=255&n),a}(function(e){if((e=function(e){return e.trim?e.trim():e.replace(/^\s+|\s+$/g,"")}(e).replace(dt,"")).length<2)return"";for(;e.length%4!=0;)e+="=";return e}(e))}function ht(e,t,o,i){for(var n=0;n<i&&!(n+o>=t.length||n>=e.length);++n)t[n+o]=e[n];return n}function mt(e){return!!e.constructor&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)}function gt(){if(nt)return it;nt=1;var e=$;return it=function(t,o){o=o||new FormData;var i=[];function n(t){return null===t?"":e.isDate(t)?t.toISOString():e.isArrayBuffer(t)||e.isTypedArray(t)?"function"==typeof Blob?new Blob([t]):Ce.from(t):t}return function t(r,a){if(e.isPlainObject(r)||e.isArray(r)){if(-1!==i.indexOf(r))throw Error("Circular reference detected in "+a);i.push(r),e.forEach(r,function(i,r){if(!e.isUndefined(i)){var s,l=a?a+"."+r:r;if(i&&!a&&"object"==typeof i)if(e.endsWith(r,"{}"))i=JSON.stringify(i);else if(e.endsWith(r,"[]")&&(s=e.toArray(i)))return void s.forEach(function(t){!e.isUndefined(t)&&o.append(l,n(t))});t(i,l)}}),i.pop()}else o.append(a,n(r))}(t),o},it}function yt(){if(at)return rt;at=1;var e=de();return rt=function(t,o,i){var n=i.config.validateStatus;i.status&&n&&!n(i.status)?o(new e("Request failed with status code "+i.status,[e.ERR_BAD_REQUEST,e.ERR_BAD_RESPONSE][Math.floor(i.status/100)-4],i.config,i.request,i)):t(i)}}function ft(){if(lt)return st;lt=1;var e=$;return st=e.isStandardBrowserEnv()?{write:function(t,o,i,n,r,a){var s=[];s.push(t+"="+encodeURIComponent(o)),e.isNumber(i)&&s.push("expires="+new Date(i).toGMTString()),e.isString(n)&&s.push("path="+n),e.isString(r)&&s.push("domain="+r),!0===a&&s.push("secure"),document.cookie=s.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}}}var bt,pt,Et,wt,It,jt,St,Ct,Gt,Ot,$t,Tt,Mt=function(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)},At=function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e},Dt=function(e,t){return e&&!Mt(t)?At(e,t):t};function Rt(){if(pt)return bt;pt=1;var e=$,t=["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"];return bt=function(o){var i,n,r,a={};return o?(e.forEach(o.split("\n"),function(o){if(r=o.indexOf(":"),i=e.trim(o.substr(0,r)).toLowerCase(),n=e.trim(o.substr(r+1)),i){if(a[i]&&t.indexOf(i)>=0)return;a[i]="set-cookie"===i?(a[i]?a[i]:[]).concat([n]):a[i]?a[i]+", "+n:n}}),a):a}}function Nt(){if(wt)return Et;wt=1;var e=$;return Et=e.isStandardBrowserEnv()?function(){var t,o=/(msie|trident)/i.test(navigator.userAgent),i=document.createElement("a");function n(e){var t=e;return o&&(i.setAttribute("href",t),t=i.href),i.setAttribute("href",t),{href:i.href,protocol:i.protocol?i.protocol.replace(/:$/,""):"",host:i.host,search:i.search?i.search.replace(/^\?/,""):"",hash:i.hash?i.hash.replace(/^#/,""):"",hostname:i.hostname,port:i.port,pathname:"/"===i.pathname.charAt(0)?i.pathname:"/"+i.pathname}}return t=n(window.location.href),function(o){var i=e.isString(o)?n(o):o;return i.protocol===t.protocol&&i.host===t.host}}():function(){return!0}}function xt(){if(jt)return It;jt=1;var e=de();function t(t){e.call(this,null==t?"canceled":t,e.ERR_CANCELED),this.name="CanceledError"}return $.inherits(t,e,{__CANCEL__:!0}),It=t}function Vt(){return Ct?St:(Ct=1,St=function(e){var t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""})}function Pt(){if(Ot)return Gt;Ot=1;var e=$,t=yt(),o=ft(),i=A,n=Dt,r=Rt(),a=Nt(),s=ce,l=de(),d=xt(),c=Vt();return Gt=function(u){return new Promise(function(v,h){var m,g=u.data,y=u.headers,f=u.responseType;function b(){u.cancelToken&&u.cancelToken.unsubscribe(m),u.signal&&u.signal.removeEventListener("abort",m)}e.isFormData(g)&&e.isStandardBrowserEnv()&&delete y["Content-Type"];var p=new XMLHttpRequest;if(u.auth){var E=u.auth.username||"",w=u.auth.password?unescape(encodeURIComponent(u.auth.password)):"";y.Authorization="Basic "+btoa(E+":"+w)}var I=n(u.baseURL,u.url);function j(){if(p){var e="getAllResponseHeaders"in p?r(p.getAllResponseHeaders()):null,o={data:f&&"text"!==f&&"json"!==f?p.response:p.responseText,status:p.status,statusText:p.statusText,headers:e,config:u,request:p};t(function(e){v(e),b()},function(e){h(e),b()},o),p=null}}if(p.open(u.method.toUpperCase(),i(I,u.params,u.paramsSerializer),!0),p.timeout=u.timeout,"onloadend"in p?p.onloadend=j:p.onreadystatechange=function(){p&&4===p.readyState&&(0!==p.status||p.responseURL&&0===p.responseURL.indexOf("file:"))&&setTimeout(j)},p.onabort=function(){p&&(h(new l("Request aborted",l.ECONNABORTED,u,p)),p=null)},p.onerror=function(){h(new l("Network Error",l.ERR_NETWORK,u,p,p)),p=null},p.ontimeout=function(){var e=u.timeout?"timeout of "+u.timeout+"ms exceeded":"timeout exceeded",t=u.transitional||s;u.timeoutErrorMessage&&(e=u.timeoutErrorMessage),h(new l(e,t.clarifyTimeoutError?l.ETIMEDOUT:l.ECONNABORTED,u,p)),p=null},e.isStandardBrowserEnv()){var S=(u.withCredentials||a(I))&&u.xsrfCookieName?o.read(u.xsrfCookieName):void 0;S&&(y[u.xsrfHeaderName]=S)}"setRequestHeader"in p&&e.forEach(y,function(e,t){void 0===g&&"content-type"===t.toLowerCase()?delete y[t]:p.setRequestHeader(t,e)}),e.isUndefined(u.withCredentials)||(p.withCredentials=!!u.withCredentials),f&&"json"!==f&&(p.responseType=u.responseType),"function"==typeof u.onDownloadProgress&&p.addEventListener("progress",u.onDownloadProgress),"function"==typeof u.onUploadProgress&&p.upload&&p.upload.addEventListener("progress",u.onUploadProgress),(u.cancelToken||u.signal)&&(m=function(e){p&&(h(!e||e&&e.type?new d:e),p.abort(),p=null)},u.cancelToken&&u.cancelToken.subscribe(m),u.signal&&(u.signal.aborted?m():u.signal.addEventListener("abort",m))),g||(g=null);var C=c(I);C&&-1===["http","https","file"].indexOf(C)?h(new l("Unsupported protocol "+C+":",l.ERR_BAD_REQUEST,u)):p.send(g)})},Gt}var Lt=$,kt=function(e,t){le.forEach(e,function(o,i){i!==t&&i.toUpperCase()===t.toUpperCase()&&(e[t]=o,delete e[i])})},_t=de(),Ft=ce,Ut=gt(),Bt={"Content-Type":"application/x-www-form-urlencoded"};function qt(e,t){!Lt.isUndefined(e)&&Lt.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var Ht,zt={transitional:Ft,adapter:(("undefined"!=typeof XMLHttpRequest||"[object process]"===Object.prototype.toString.call(se))&&(Ht=Pt()),Ht),transformRequest:[function(e,t){if(kt(t,"Accept"),kt(t,"Content-Type"),Lt.isFormData(e)||Lt.isArrayBuffer(e)||Lt.isBuffer(e)||Lt.isStream(e)||Lt.isFile(e)||Lt.isBlob(e))return e;if(Lt.isArrayBufferView(e))return e.buffer;if(Lt.isURLSearchParams(e))return qt(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString();var o,i=Lt.isObject(e),n=t&&t["Content-Type"];if((o=Lt.isFileList(e))||i&&"multipart/form-data"===n){var r=this.env&&this.env.FormData;return Ut(o?{"files[]":e}:e,r&&new r)}return i||"application/json"===n?(qt(t,"application/json"),function(e,t,o){if(Lt.isString(e))try{return(t||JSON.parse)(e),Lt.trim(e)}catch(e){if("SyntaxError"!==e.name)throw e}return(o||JSON.stringify)(e)}(e)):e}],transformResponse:[function(e){var t=this.transitional||zt.transitional,o=t&&t.silentJSONParsing,i=t&&t.forcedJSONParsing,n=!o&&"json"===this.responseType;if(n||i&&Lt.isString(e)&&e.length)try{return JSON.parse(e)}catch(e){if(n){if("SyntaxError"===e.name)throw _t.from(e,_t.ERR_BAD_RESPONSE,this,null,this.response);throw e}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Tt?$t:(Tt=1,$t=null)},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Lt.forEach(["delete","get","head"],function(e){zt.headers[e]={}}),Lt.forEach(["post","put","patch"],function(e){zt.headers[e]=Lt.merge(Bt)});var Wt,Zt,Yt=zt,Qt=$,Jt=Yt;function Xt(){return Zt?Wt:(Zt=1,Wt=function(e){return!(!e||!e.__CANCEL__)})}var Kt=$,eo=function(e,t,o){var i=this||Jt;return Qt.forEach(o,function(o){e=o.call(i,e,t)}),e},to=Xt(),oo=Yt,io=xt();function no(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new io}var ro,ao,so=$,lo=function(e,t){t=t||{};var o={};function i(e,t){return so.isPlainObject(e)&&so.isPlainObject(t)?so.merge(e,t):so.isPlainObject(t)?so.merge({},t):so.isArray(t)?t.slice():t}function n(o){return so.isUndefined(t[o])?so.isUndefined(e[o])?void 0:i(void 0,e[o]):i(e[o],t[o])}function r(e){if(!so.isUndefined(t[e]))return i(void 0,t[e])}function a(o){return so.isUndefined(t[o])?so.isUndefined(e[o])?void 0:i(void 0,e[o]):i(void 0,t[o])}function s(o){return o in t?i(e[o],t[o]):o in e?i(void 0,e[o]):void 0}var l={url:r,method:r,data:r,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};return so.forEach(Object.keys(e).concat(Object.keys(t)),function(e){var t=l[e]||n,i=t(e);so.isUndefined(i)&&t!==s||(o[e]=i)}),o};function co(){return ao?ro:(ao=1,ro={version:"0.27.2"})}var uo=co().version,vo=de(),ho={};["object","boolean","number","function","string","symbol"].forEach(function(e,t){ho[e]=function(o){return typeof o===e||"a"+(t<1?"n ":" ")+e}});var mo={};ho.transitional=function(e,t,o){function i(e,t){return"[Axios v"+uo+"] Transitional option '"+e+"'"+t+(o?". "+o:"")}return function(o,n,r){if(!1===e)throw new vo(i(n," has been removed"+(t?" in "+t:"")),vo.ERR_DEPRECATED);return t&&!mo[n]&&(mo[n]=!0,console.warn(i(n," has been deprecated since v"+t+" and will be removed in the near future"))),!e||e(o,n,r)}};var go,yo,fo,bo,po,Eo,wo={assertOptions:function(e,t,o){if("object"!=typeof e)throw new vo("options must be an object",vo.ERR_BAD_OPTION_VALUE);for(var i=Object.keys(e),n=i.length;n-- >0;){var r=i[n],a=t[r];if(a){var s=e[r],l=void 0===s||a(s,r,e);if(!0!==l)throw new vo("option "+r+" must be "+l,vo.ERR_BAD_OPTION_VALUE)}else if(!0!==o)throw new vo("Unknown option "+r,vo.ERR_BAD_OPTION)}},validators:ho},Io=$,jo=A,So=N,Co=function(e){return no(e),e.headers=e.headers||{},e.data=eo.call(e,e.data,e.headers,e.transformRequest),e.headers=Kt.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),Kt.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]}),(e.adapter||oo.adapter)(e).then(function(t){return no(e),t.data=eo.call(e,t.data,t.headers,e.transformResponse),t},function(t){return to(t)||(no(e),t&&t.response&&(t.response.data=eo.call(e,t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})},Go=lo,Oo=Dt,$o=wo,To=$o.validators;function Mo(e){this.defaults=e,this.interceptors={request:new So,response:new So}}Mo.prototype.request=function(e,t){"string"==typeof e?(t=t||{}).url=e:t=e||{},(t=Go(this.defaults,t)).method?t.method=t.method.toLowerCase():this.defaults.method?t.method=this.defaults.method.toLowerCase():t.method="get";var o=t.transitional;void 0!==o&&$o.assertOptions(o,{silentJSONParsing:To.transitional(To.boolean),forcedJSONParsing:To.transitional(To.boolean),clarifyTimeoutError:To.transitional(To.boolean)},!1);var i=[],n=!0;this.interceptors.request.forEach(function(e){"function"==typeof e.runWhen&&!1===e.runWhen(t)||(n=n&&e.synchronous,i.unshift(e.fulfilled,e.rejected))});var r,a=[];if(this.interceptors.response.forEach(function(e){a.push(e.fulfilled,e.rejected)}),!n){var s=[Co,void 0];for(Array.prototype.unshift.apply(s,i),s=s.concat(a),r=Promise.resolve(t);s.length;)r=r.then(s.shift(),s.shift());return r}for(var l=t;i.length;){var d=i.shift(),c=i.shift();try{l=d(l)}catch(e){c(e);break}}try{r=Co(l)}catch(e){return Promise.reject(e)}for(;a.length;)r=r.then(a.shift(),a.shift());return r},Mo.prototype.getUri=function(e){e=Go(this.defaults,e);var t=Oo(e.baseURL,e.url);return jo(t,e.params,e.paramsSerializer)},Io.forEach(["delete","get","head","options"],function(e){Mo.prototype[e]=function(t,o){return this.request(Go(o||{},{method:e,url:t,data:(o||{}).data}))}}),Io.forEach(["post","put","patch"],function(e){function t(t){return function(o,i,n){return this.request(Go(n||{},{method:e,headers:t?{"Content-Type":"multipart/form-data"}:{},url:o,data:i}))}}Mo.prototype[e]=t(),Mo.prototype[e+"Form"]=t(!0)});var Ao=$,Do=d,Ro=Mo,No=lo;var xo=function e(t){var o=new Ro(t),i=Do(Ro.prototype.request,o);return Ao.extend(i,Ro.prototype,o),Ao.extend(i,o),i.create=function(o){return e(No(t,o))},i}(Yt);xo.Axios=Ro,xo.CanceledError=xt(),xo.CancelToken=function(){if(yo)return go;yo=1;var e=xt();function t(t){if("function"!=typeof t)throw new TypeError("executor must be a function.");var o;this.promise=new Promise(function(e){o=e});var i=this;this.promise.then(function(e){if(i._listeners){var t,o=i._listeners.length;for(t=0;t<o;t++)i._listeners[t](e);i._listeners=null}}),this.promise.then=function(e){var t,o=new Promise(function(e){i.subscribe(e),t=e}).then(e);return o.cancel=function(){i.unsubscribe(t)},o},t(function(t){i.reason||(i.reason=new e(t),o(i.reason))})}return t.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},t.prototype.subscribe=function(e){this.reason?e(this.reason):this._listeners?this._listeners.push(e):this._listeners=[e]},t.prototype.unsubscribe=function(e){if(this._listeners){var t=this._listeners.indexOf(e);-1!==t&&this._listeners.splice(t,1)}},t.source=function(){var e;return{token:new t(function(t){e=t}),cancel:e}},go=t}(),xo.isCancel=Xt(),xo.VERSION=co().version,xo.toFormData=gt(),xo.AxiosError=de(),xo.Cancel=xo.CanceledError,xo.all=function(e){return Promise.all(e)},xo.spread=bo?fo:(bo=1,fo=function(e){return function(t){return e.apply(null,t)}}),xo.isAxiosError=function(){if(Eo)return po;Eo=1;var e=$;return po=function(t){return e.isObject(t)&&!0===t.isAxiosError}}(),l.exports=xo,l.exports.default=xo;var Vo=r(l.exports);var Po,Lo={exports:{}},ko=a(Object.freeze({__proto__:null,default:{}}));Po=Lo,function(e){var t,o,i,n,r;e?function(){var i=e.crypto||e.msCrypto;if(!t&&i&&i.getRandomValues)try{var r=new Uint8Array(16);n=t=function(){return i.getRandomValues(r),r},t()}catch(e){}if(!t){var a=new Array(16);o=t=function(){for(var e,t=0;t<16;t++)3&t||(e=4294967296*Math.random()),a[t]=e>>>((3&t)<<3)&255;return a},"undefined"!=typeof console&&console.warn&&console.warn("[SECURITY] node-uuid: crypto not usable, falling back to insecure Math.random()")}}():function(){try{var e=ko.randomBytes;i=t=e&&function(){return e(16)},t()}catch(e){}}();for(var a=Ce,s=[],l={},d=0;d<256;d++)s[d]=(d+256).toString(16).substr(1),l[s[d]]=d;function c(e,t){var o=t||0,i=s;return i[e[o++]]+i[e[o++]]+i[e[o++]]+i[e[o++]]+"-"+i[e[o++]]+i[e[o++]]+"-"+i[e[o++]]+i[e[o++]]+"-"+i[e[o++]]+i[e[o++]]+"-"+i[e[o++]]+i[e[o++]]+i[e[o++]]+i[e[o++]]+i[e[o++]]+i[e[o++]]}var u=t(),v=[1|u[0],u[1],u[2],u[3],u[4],u[5]],h=16383&(u[6]<<8|u[7]),m=0,g=0;function y(e,o,i){var n=o&&i||0;"string"==typeof e&&(o="binary"===e?new a(16):null,e=null);var r=(e=e||{}).random||(e.rng||t)();if(r[6]=15&r[6]|64,r[8]=63&r[8]|128,o)for(var s=0;s<16;s++)o[n+s]=r[s];return o||c(r)}var f=y;f.v1=function(e,t,o){var i=t&&o||0,n=t||[],r=null!=(e=e||{}).clockseq?e.clockseq:h,a=null!=e.msecs?e.msecs:(new Date).getTime(),s=null!=e.nsecs?e.nsecs:g+1,l=a-m+(s-g)/1e4;if(l<0&&null==e.clockseq&&(r=r+1&16383),(l<0||a>m)&&null==e.nsecs&&(s=0),s>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");m=a,g=s,h=r;var d=(1e4*(268435455&(a+=122192928e5))+s)%4294967296;n[i++]=d>>>24&255,n[i++]=d>>>16&255,n[i++]=d>>>8&255,n[i++]=255&d;var u=a/4294967296*1e4&268435455;n[i++]=u>>>8&255,n[i++]=255&u,n[i++]=u>>>24&15|16,n[i++]=u>>>16&255,n[i++]=r>>>8|128,n[i++]=255&r;for(var y=e.node||v,f=0;f<6;f++)n[i+f]=y[f];return t||c(n)},f.v4=y,f.parse=function(e,t,o){var i=t&&o||0,n=0;for(t=t||[],e.toLowerCase().replace(/[0-9a-f]{2}/g,function(e){n<16&&(t[i+n++]=l[e])});n<16;)t[i+n++]=0;return t},f.unparse=c,f.BufferClass=a,f._rng=t,f._mathRNG=o,f._nodeRNG=i,f._whatwgRNG=n,Po.exports?Po.exports=f:(r=e.uuid,f.noConflict=function(){return e.uuid=r,f},e.uuid=f)}("undefined"!=typeof window?window:null);var _o=r(Lo.exports);class Fo{constructor(e){Object.defineProperty(this,"obj",{enumerable:!0,configurable:!0,writable:!0,value:void 0}),this.obj=e}setOptions(e,t){console.log(this.obj.url+this.obj.prefix);return{method:"post",baseURL:this.obj.url+this.obj.prefix,url:e,responseType:"arraybuffer",headers:{"x-request-id":_o.v1(),"X-Requested-With":"XMLHttpRequest","Content-Type":"application/octet-stream"},data:t}}requestFuncProtobuff(e,t){return Vo(this.setOptions(e,t)).then(e=>e.data).catch(e=>(console.log(e),{success:!1,errCode:null==e?void 0:e.code,message:null==e?void 0:e.message,reason:null==e?void 0:e.response}))}requestFunc(e,t){return Vo({method:"post",baseURL:this.obj.url+this.obj.prefix,url:e,responseType:"json",headers:{"x-request-id":_o.v1()},data:t}).then(e=>e.data).catch(e=>(console.log(e),{success:!1,errCode:null==e?void 0:e.code,message:null==e?void 0:e.message,reason:null==e?void 0:e.response}))}requestAction(e,t,o,i={}){const n={method:o,baseURL:this.obj.url+this.obj.prefix,url:e,responseType:"json",headers:i};return"get"===o?n.params=t:n.data=t,n.headers["x-request-id"]=_o.v1(),Vo(n).then(e=>e.data).catch(e=>(console.log(e),{success:!1,errCode:null==e?void 0:e.code,message:null==e?void 0:e.message,reason:null==e?void 0:e.response}))}requestActionForAgent(e,t,o,i={}){const n={method:o,baseURL:this.obj.agentHost,url:e,responseType:"json",headers:i};return"get"===o?n.params=t:n.data=t,n.headers["x-request-id"]=_o.v1(),Vo(n).then(e=>e.data).catch(e=>(console.log(e),{success:!1,errCode:null==e?void 0:e.code,message:null==e?void 0:e.message,reason:null==e?void 0:e.response}))}}class Uo{constructor(){Object.defineProperty(this,"listeners",{enumerable:!0,configurable:!0,writable:!0,value:[]})}static getInstance(){return this.instance||(this.instance=new Uo),this.instance}findListener(e){return this.listeners.find(t=>t.guid==e)}addListener(e){return e.guid=_o.v1(),e.time=(new Date).getTime(),this.listeners.push(e),e.guid}removeListener(e){const t=this.listeners.findIndex(t=>t.guid==e);t>=0&&this.listeners.splice(t,1)}randomString(e){const t=(new Date).getTime();e=e||32;const o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";let i="";for(let t=0;t<e;t++)i+=o.charAt(Math.floor(62*Math.random()));return`${i}_${t}`}}const Bo=new Map([["Point","PointEntity"],["Point2D","Point2DEntity"],["Polygon","PolygonEntity"],["Polygon2D","Polygon2DEntity"],["Polyline","PolylineEntity"],["Polyline2D","Polyline2DEntity"],["Camera","CameraPresetEntity"],["Bound","MoveAlongPathEntity"],["HeatMap","BP_HeatMapEntity_C"],["Particle","ParticleEntity"],["Poi","PoiEntity"],["CustomPoi","CustomPoiEntity"],["Text3D","Text3DEntity"],["ColumnarHeatMap","BP_ColumnarHeatMapEntity_C"],["HighlightArea","BP_HighlightAreaEntity_C"],["Path","BP_PathEntity_C"],["Range","BP_RangeEntity_C"],["Window","WindowEntity"],["Parabola","BP_ParabolaEntity_C"],["Light","LightEntity"],["Static","StaticMeshEntity"],["Hierarchy","HierarchyMeshEntity"],["Viewshed","BP_V